I don't know what problems specifically you're having with the trills, but I suspect that it's fatigue due to not having trained this particular motion.
There are two major components to the hand motion used when articulating tremolos and trills: the action of the fingers, and the action of the wrist. There's nothing special about the fingers; they function in the same capacity that they always have. The wrist, however, can rotate around the axis of your forearm. This action fills two purposes: it reduces the distance that the fingers need to travel, and it adds to the force generated by the finger motion. This does not have to be a large motion to be helpful. With a little experimentation, you'll learn what feels right.
My guess is that you're not using any wrist rotation, and since the 4th and 5th fingers are the weakest in the hand, you're having trouble generating enough force to quickly trill. Adding the wrist motion will help, but in the end, there is no substitute to training those muscles, especially if you're playing on a piano with a heavy action.
In this case, hanon exercises are useful There is another question on this same topic (link here) where I mention a specific exercise and link to a free PDF. Work through the exercise slowly, and avoid tension. Especially when dealing with rapid motions like trills, retaining tension is a bad habit that leads to RSI like carpal tunnel over a decade or so. @J03Bukowski's answer gives fantastic advice on how to avoid retaining tension.
I did my best to tailor this advice specificly to 5-4 trills, but in the end, everything I've said applies equally to trills, to tremolos, to Alberti bass lines, and a myriad of other related figures. It is worth noting that good advice does not need to be unique to the specific situation at hand; on the contrary, there is often no such advice.