Segmentation fault, can be caused by multiple reasons. 1. you are allocating memory but you are not releasing it, so you ran out of memory, and get null pointer. 2. there is a problem with communication between your program and device driver, you are not checking for this condition, or driver returns unexpected result. 3. you corrupt memory, and that causes segmentation fault, etc. This can be debugged using gdbserver and gdb. As for driver it is located under /lib/modules/<kernel-version>. /dev directory contains special files, which are used to communicate with block or character drivers. In any case check if anything was displayed on the console (dmesg is the command).