Ported to Linux, tested on Arch Linux 3.11.6