Applied snq-'s modified patch below and fixed the compilation error on HD2 by tytung http://forum.xda-developers.com/showpost.php?p=12316760&postcount=154
For normal use don't activate it, you need some other stuff for testing.
All credits to Cotulla