Hi there,
The 'back emf' of a motor has the same polarity as the applied voltage, so a reverse
diode on the output probably will have no effect unless something else is wrong too.
The only thing that might have happened is that the motor generated higher voltage
spikes as someone already mentioned and for this you would use a bigger
cap on the output. If the spike is big enough, the 1N4001 diode should shunt
it around the regulator which is good, but if it is too big it will also then over power
the input to the regulator. 2200uf seems good enough though so i dont see how
this could happen, but if the 2200uf is connected too far from the physical package
of the LM317 it could happen anyway. That means wire the 2200uf close to the
LM317 package, and test that diode to make sure it is not blown too.
Another cap, 0.1uf, is also a good idea right across the input of the LM317 and
maybe one across the output too.
Just to note, i have run motors using this very circuit (without 1N4001) and
have had no problems at all with output adjusted to maybe 5vdc.
There is another problem too though, even once the circuit is back up and running
normally. That is, when the output voltage is low enough and the current draw
from the output is high enough the LM317 will go into thermal cutback. A really
good heatsink is required to keep it running cool, and maybe a little fan too.
You can get little fans pretty cheap that run on 12v dc, at low current like 100ma,
so you could power that from the input dc by using another regulator.