From my experience this kid of problem can be caused either by over voltage conditions due to oscillations or ringing in the power output stage of the H-bridge or over current in the output stage.
Standard disclaimer (as I have never used the ROHM BD6222 chip) this is all my speculations based on reading the datasheet after getting interested in this problem.
On paper (or at least in the PDF I am reading) this chip has all kinds of protections including cross-conduction, over current(OCP), thermal shutdown and over voltage (OVP). However, there is a bit of a surprise waiting when one reads the OVP spec and I quote here:
"Also, note that this circuit is supplementary, and thus if it is asserted, the absolute maximum rating will have been exceeded."
OK so the OVP kicks in when the voltage exceeds 30V but the chip is speced to max 18V ?!
Hm, this is what they call protection circuit?
There is also a question of the "Stand-by or idling" mode when both control inputs (FIN, RIN) are low.
In this case the output stage goes into higz (disconnects from the motor) but if the motor has been running like in this case it will generate voltage and current which is now shorted through the chip body diodes. Depending on the motor speed at the moment of entering the idling mode, current generated by the now shorted motor can be way bigger then current during active operation.
I would check code in the motor.c to see if it sets both FIN and RIN low when it is doing the PWM, it actually could be the revers if GPIO buffers are reversing the signal polarity.
One last thought. Using beefier motor might have actually contributed to the destruction of the BD6222 chip as the idling current would have been bigger then current generated by the smaller motor.
Also here is the link to another report of BD6222 burning up
http://www.electro-tech-online.com/elec ... 22hfp.html