There seems to be a case of crossed wires going on between some posters. The essential issue in this type of situation is consent. Any sexual practice is acceptable as long as all the people participating have consented. Thus, things that might be considered brutal and violent without consent - being tied up, whipping, etc - are all just another form of sex play when everyone genuinely consents freely and when everyone has the opportunity to withdraw consent at any time.
Thus, if your partner knows you like being touched in your sleep, and knows that you will genuinely enjoy being woken up by sex and he does that, then it isn't rape, it's just another form of sex play that both partners have enjoyed. The essential thing is, your partner knows you are ok with it. Really, the only way to know in this sort of situation, ie when one partner is asleep, is to ask in advance, ie to say "How would you feel if I woke you up by being inside you?"
If the partner doesn't ask in advance and just does it, they are running a massive risk. Any person with any ounce of decency would realise that. The idea that a normal, caring man would look at their sleeping partner and not worry that just entering them would upset them is really hard to imagine. A genuinely loving partner would wake the other partner up, perhaps with some touching, and see if the other person was in the mood before starting. Just assuming that the other person is ok with sex and then just going ahead without even checking first is a bizarre thing to do, and not a mistake you would expect a caring person to make. There are some feeble reasons that might explain this behaviour but they're all so unlikely that unfortunately in this instance the most probable thing was that the OP's partner just felt like sex and took it and didn't care about the OP's feelings.
I'm so sorry that happened to you OP and I hope, if you are still reading the thread, that you are doing ok.