Make this work with earm kernels. Not sure the test is realy worth it.

Partially from Greg Willatt