Profile trim screw length going into plywood walls?

I am about to install my roof Aluminum
and I found a box of 1 5/8 stainless steel screws and I was wondering if this might be too long. My worry is because I will be screwing into the endgrain of plywood which isn't exactly the most stable. Any suggestions on screw length given the material I will be going on? I will be going through the Aluminum trim, the .040 aluminum roof, 1/8" Epoxy hardended masonite, and then the Plywood.
Thanks!

Thanks!