The whining is a 3-year-old thing. They go through stages of whining and stages of being content. As for the bedtime thing...put him to sleep in his bed as you are doing now and if he comes into your room, carry him back into his room. Settle him there, and if he cries about it you explain that he has a big boy bed just for him, and that Mummy and Daddy need the space in your bed because you are bigger. If it helps, allow him a "snuggle" toy or something comforting that is just his, in his bed.