Thanks for query,
There are four stages of sexual act.
Arousal,Erection,Ejeculation & lag period.
You can increase the timing between erection & ejeculation by start stop start technique.
There is always difference between masturbation
act & actual act with girl friend.so do not compare both.
You have to deal with fantasy in masturbation & you are free to apply pressure while in actual sex you have limitation of pressure & there is always performance Anxiety
So nothing to worry for your erection hardness .
Wish you happy marriage life.