lkml.org 
[lkml]   [2011]   [Jul]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectStopping a kthread in module exit(system hangs!) - linux 2.6.39.1
Hi all,


The kernel version we are using is 2.6.39.1 . In our block device
driver module we create and run a kthread using "kthread_run" during
module_init.This kthread runs until we issue a "kthread_stop" from the
module_exit code.In the thread function we repeatedly check for
"kthread_should_stop" and when the condition is met (due to the
kthread_stop call) we "return 0;". Our thread function wouldn't return
in any other scenario.

Our problem right now is that when we do an "rmmod" the system just
hangs!.This we have identified is due to the kthread_stop. Can you
please give us some pointers/directions regarding the possible
underlying issue.Specifically is there a problem while calling
kthread_stop and waiting on the thread completion in the module exit
code.


Thanks and Regards
Ganesh


\
 
 \ /
  Last update: 2011-07-21 23:17    [W:0.121 / U:0.196 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site