Are Homebrew Games Legal?

Are Homebrew Games Legal? Making homebrew is most definitely not illegal. Actually distributing it or running it on hardware is a more sticky issue. All these devices have some form of protection system that necessitates circumvention to run unsigned code. Circumventing copy protection is usually illegal. Is it legal to homebrew a 3DS? But hackers/homebrewers