There is a longstanding history in US law of the Government barring firearm ownership to people or classes of people when the gov felt that ban was for the public good. Blacks and Native Americans were the prominent examples, but there were others. Those laws actually predate the 2nd, and come from English common law.
I wouldn't bet against the court dredging that up and using it to justify disarming "dangerous" people being OK under the 2nd.