Trying to remap my hardware buttons Since I have a broken back button I have remapped my buttons in such a way that my original volume up button functions as a menu button, and my original menu button as the back button. I've done this by changing the key values in /system/usr/keylayout/generic.kl.

The problem is, I've flashed a new ROM so I had to do it again, but now it doesn't work anymore. The changed values are persistent but my phone ignores it, it seems.

And yes, of course I've rebooted after making the changes again.

Anyone have an idea?
As you wrote you've modified a system file, it's safe to assume your device is rooted. There are several apps available promising to remap keys (see my list of key remapper apps), one of them might solve your issue. I have not tried any of them (had no need), but what sounds promising is Xposed Additions, see this screenshots:

 
Xposed Additions (source: Google Play; click images for larger variants)

On the first screenshot (the module's main screen), the last item reads "Buttons". Tapping that leads to the second screenshot – again look at the very button, and you see it even includes hardware keys (here: the power button). The item just above that would be your back button (soft or hard). So no need to directly tamper with system files – just let Xposed deal with it :)