U seem to be suffering from performance Anxiety. Due to overthinking about ur ability to satisfy ur partner, ur performance goes down, because sex is a mind game, needs to be done under relaxed state, not under any pressure or tension.
Next Steps
Whenever you go for sex, tell ur partner before it that we r going to enjoy foreplay only, so pressure of good performance will be lifted away from yr shoulder. So u can continue foreplay for 20-30 mins, once u start having enough self