Re: Kernel preemption -- demo does not work

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Mulyadi Santosa wrote:

Hi  Bernd

Sorry for the late reply. I have tried to test your user space test program and the kernel module inside my Qemu virtual machine. And the result is...there is no delay inside the user space test program. The loop is still counting while the kernel module is correctly busy waiting for 10 seconds (10*HZ).

Yes,  I did the test as well, using your code. Same result, it just works.

IMHO, this concludes, something is missing/wrong in your kernel configuration. Here is my kernel config related to kernel preemption:
# CONFIG_PREEMPT_NONE is not set
# CONFIG_PREEMPT_VOLUNTARY is not set
CONFIG_PREEMPT=y
# CONFIG_PREEMPT_BKL is not set
CONFIG_DEBUG_PREEMPT=y

After comparing with yours, I believe you must try to set CONFIG_PREEMPT_BKL as "n". I am not sure what is the correlation between Big kernel Lock and busy waiting (using time_after()/time_before()), but it is worth to test.

This does not hold for me.
With CONFIG_PREEMPT_BKL=y preempt_count actually increments at the same rate, while the module is in busy waiting. So Big Kernel Lock preemption is not the problem. I have no ideas on how to solve your problem.

good luck...

regards

Mulyadi

Bye,

--
Antonio Mancina
PhD Student @ Retis Lab
Scuola Superiore S.Anna - CNR
Pisa, Italy
a.mancina@xxxxxxxx



--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux