سؤال

I am working on a kernel module and a user-space application to test that module.

The problem is that during testing my system hangs/freeze.

I have placed lots of debug prints in the code.

The last message that is printed is just before linux select call in my user-space application. Does select somehow freeze the system?

So, How can i debug that where is problem? whether the problem is on user-space application or kernel module?

هل كانت مفيدة؟

المحلول

As n.m mentioned, your userspace program can't freeze Linux, so its an error in your kernel module. The best way to debug this is to use a kernel debugger, and figure out what your module is doing wrong.

Common errors are uninitialized pointers that your module passes to the kernel or locking issues, so take a close look at those.

نصائح أخرى

A userspace program cannot, by definition, freeze Linux. There's a bug in the kernel.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top