I want to believe that I'm looking at a N-channel MOSFET, but that's not where I would have expected to see the final transistor in the circuit. If those two leaded components in the foreground are resistors that go to ground over on the right, then it almost certainly is an N-channel, and you can find just about any N-channel MOSFET in a SO-8 package that'll work.
Of course, there's two different widths of SO-8 packages (the thingie marked "2901" in the center of the photo is the bigger size), and I could be wrong about the polarity of the FET.
If you're going to throw it away anyway, and if no one else comes forward with a better idea, then amaze yourself by the selection of 40V N-channel, SO-8 FETs on Digikey (there's probably over 10000 different part numbers to choose from). Pick one at random, solder it on, and see if the whole thing bursts into flame.