A regular allergy pill will do it. Benedryl is a bit strong.
Anti-inflammatory drugs like ibuprofen as well. The erection is a swelling and they are anti-inflamatory. Tylenol is a better choice for just pain (as long as you don’t need anti-inflammatory properties.)
So are any one of these going to make you impotent? Maybe not. But regular, heavy, or combined use of them can potentially cause such problems.
I would not take Benadryl in conjunction with sex performance.
As it turns out, the side affects of many many drugs is ED.