How can I patch a subfloor going under an exterior wall?
Removal of as much of the rotted or swollen decking is important.  The external walls I have put up are put in place, then the flooring(underlayment). It would be very difficult to remove the damaged decking under a  wall. I would cut it off at the bottom plate and lay new decking. If the internal walls are non-load bearing, the bottom can be knocked loose moved to the side, and the underlayment removed with new decking installed if the damage is substantial.

If the damage is not so bad I would cut it at the bottom plate and replace. Added: This looks more like light water damage not really rotted now that I am looking on my computer. It could be cut off flush with the wall and new decking added.  You will want to go to the next joist on either side or you will need to add framing for support and nailing.

Looking again, it is hard to tell how deep you dug out it is possible the OSB is an underlayment on top of T&amp;G decking. Keep your fingers crossed.  See if you can peel up the OSB.  Most of the underlayment I put down is 3/8" but thicker material is used.