lkml.org 
[lkml]   [2003]   [Sep]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH][2.6][CFT] rmmod floppy kills box fixes + default_device_remove
On Tue, 9 Sep 2003, Zwane Mwaikambo wrote:

> > So an empty release() function is the wrong thing to do in 99.99% of the
> > situations in the kernel (the one exception seems to be the mca release
> > function that recently got added for use when the bus is doing probing
> > logic.)
> >
> > Does this help out?
>
> Yes thanks, i was confused over which memory references had to be
> maintained.

Ok i had another look and i can see why you need a seperate release
function, as we don't always do the kobject_cleanup immediately.

John and myself had a look and now we have the following race on
->release() function exit.

my_release_fn()
{
complete(&my_completion);
<== [1] stall anywhere here, e.g. preempt/schedule
}

cleanup_module()
{
wait_for_completion(&my_completion);
<== [1] this task gets scheduled, free()s module text
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:48    [W:0.085 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site