Samuel Kahn has a nice discussion of Kant, On the Philosophical Incoherence of a Duty to Promote the Highest Good (PDF). Kahn is certainly more familiar with the details of the relevant texts than I am, but I am still inclined to think that his argument misses something. In trying to say what this is, I will stay at a fairly general level.
In the Kantian approach to ethics, all ethics is grounded on the necessary moral law, which is a categorical (i.e., unconditional) imperative that reason gives to itself, just by being reason. Since it must be necessary and unconditional, the moral law cannot depend in any way on anything contingent or conditional. This includes human nature and human happiness. Moral law is the standard to which rational beings must hold themselves, even if doing so leads to nothing but misery -- and even if it is literally impossible for a human being to meet that standard. What is more, it is a standard that must be respected in itself, and therefore cannot be correctly upheld unless it is upheld for its own sake, and not for the sake of anything contingent or conditional like happiness.
So far, so good. Human beings, however, are not pure rational spirits; we are animals, and therefore our actions necessarily depend at least to some extent on incentives and pleasures that are united in happiness. Teach an animal that acting will lead to nothing at all but misery, always, at all times, and the animal will stop being motivated to act in that way; indeed, the animal may literally just lay down and die if there is no other option. Our motivations are more complex than this, but as animals we run into the same problem: there is a point beyond which motivation gets very difficult, and a point beyond which it is simply impossible for us.
Given this, one can raise a serious question for Kantian ethics. How are human beings able to live under moral law at all? The latter is unconditional, perfect, and to be done only for its own sake; human action, however, is conditional, imperfect, and done for the sake of happiness. Whether we can conform to moral law does not affect moral law in the slightest, because it is not conditional on our abilities; but whether we can motivate ourselves to do what moral law requires is very obviously conditional on what we take our abilities to be.
We can sharpen this by identifying three motivation problems in particular:
(1) Human action is conditioned by prior causes; perhaps the universe is deterministic and we are determined to violate the moral law.
(2) Human action requires training and development to reach its peak; perhaps life is too short and we will never have enough to time to train and develop in the way following the moral law requires.
(3) Human action is motivated by happiness; perhaps the world is structured in such a way that it is impossible for us to be both moral and happy.
These three in particular are chosen by Kant because they happen to be cases in which Kant's broader philosophical approach gives a peculiar result: Kant doesn't think we have the theoretical resources to determine the solution to these problems. He doesn't think we can either prove or disprove that we have the ability, or the time, or the motivational ground, to live under moral law. Kant's handling of this peculiar situation is famous. Since we cannot prove on theoretical grounds, we must postulate on practical grounds. In particular, since moral law imposes an unconditional requirement to do certain things, and moral law is reason itself giving law to itself, it is always reasonable to assume for practical purposes whatever needs to be assumed in order to be able to motivate ourselves to act as moral law requires. Kant usually calls this something like 'rational faith', but he occasionally refers to it as hope, and I think this is probably the less misleading way to understand it. To try to do something, you don't need proof that it is possible, you just need good reason to hope that it is.
The postulates Kant proposes for the three above motivation problems are Free Will, Immortality, and God, respectively. Again, Kant doesn't think we can prove that any of these three truly exists; but he thinks that moral law requires us to do certain things such that, if we are to motivate ourselves to do what moral law requires, we must hope that at least something like these things truly exist.
The first postulate, Freedom, gets the best discussion in Kant, being in some sense the very foundation of Kant's ethics considered as a human ethics. The second and third postulates involve more tangled issues, and Kant himself seems to struggle sometimes with giving a precise characterization of what he means. Kahn holds that the reasoning Kant uses with respect to the third postulate involves an incoherence, and that this leads Kant to reformulate the problem that the postulate requires.
A world characterized by the non-accidental unity of virtue and happiness is what Kant calls the summum bonum, or highest good of human life. In the summum bonum, we are fully motivated to be fully moral; in the summum bonum we can be both perfectly happy and perfectly good, in such a way that we are happy because we are good and able to follow through on our moral choices because in doing them we are happy. We must aim at this summum bonum because moral law itself requires us to do so. It is important to keep in mind that Kant thinks we can never rightly choose to be moral because it makes us happy; virtue has to be the cause of happiness, not vice versa. The subtle point that takes some work to keep clear here is that we must choose to be moral only for its own sake but that we can do so because we don't have to worry about moral life making us ultimately and irreversably miserable.
Kahn's argument is that Kant does not find a way to navigate this subtlety, and that attempts to improve on Kant's own handling either cannot succeed or can only do so if some key pillar of Kant's philosophy breaks:
But now, without taking a stand on the precise nature of the highest good, the mere fact that it is supposed to include both an agent’s moral perfection, P, and something else, which is not equivalent to P, can be used to note that the content of the highest good exceeds the commands of morality, for the commands of morality end precisely with an agent’s moral perfection. From this it follows that any duty to realize the highest good, or even to promote it, is incoherent.What I think this misses is that the moral law requires moral perfection, but in so doing it in fact also requires us to do what is necessary for moral perfection. Now, a connection between human happiness and moral perfection as such does not need to exist, because moral perfection is in terms of moral law, which does not depend on human beings in any way at all. But the moral perfection of a human being requires that something with human limitations act consistently in accordinance with the moral law, and this means that human beings need the two to be coordinated. The moral law requires human beings to act as if human beings can be morally perfect, which requires us to act as if human beings, whose motivation is tied to happiness, can be motivated to be morally perfect. In human moral perfection, virtue (our human disposition to morality) and happiness (our human motivational ground) cannot be at odds.
The case is analogous (and, I think, related) to the case of maxims. The moral law as Kant conceives it requires us to act according to maxims that are consistent with an unconditional standard; but this does not mean that maxims themselves include only unconditional things. In fact, all maxims have aspects that are entirely contingent and conditional; this is why Kant holds that the maxim involves in some sense the 'material' of the action that must be given 'form' by moral law. Rather, conditional things are included in maxims in such a way that our action involving them will conform to an unconditional standard. Likewise, the moral law itself does not involve human happiness; but it requires human agents to act in ways to which human happiness is important. The two are related in that moral law is not affected by human happiness, but moral law makes requirements on maxims, which in human beings are affected by human happiness.
The postulate of God is the practical assumption that there is a cause that makes the summum bonum possible, so that it is in fact possible for human beings with human motivational conditions to achieve moral perfection. If we didn't hope that there was at least something like this, this would effectively be giving up on our ability actually to achieve moral perfection -- and giving up on your ability to achieve a state required by a standard is always a problem for motivating yourself to follow the standard. This isn't usually a problem, since we would usually just use a different standard; but this is not an option with moral law, which is an unconditional standard. To act as moral law requires us to act, to be as moral law requires us to be, we must keep alive the hope that we can do so.