lkml.org 
[lkml]   [2003]   [Sep]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH][2.6.0-test5] fix oopses is kobject parent is removed before child
On Sun, Sep 14, 2003 at 05:37:04PM +0400, Andrey Borzenkov wrote:
> It is possible that parent is removed before child when child is in use.
> Trivial example is mounted USB storage when you unplug it. The kobject for
> USB device is removed but subordinate SCSI device remains. Then kernel oopses
> on attempt to release child e.g. umount removed USB storage. This patch fixes
> two problems:
>
> - kset_hotplug. It oopses in get_kobj_path_length because child->parent points
> to nowhere - even if parent has not yet been overwritten, its name is already
> freed. Common oops I get is

No, the scsi code should be fixed to prevent this from happening. This
used to happen in the past, but I thought the scsi people fixed it up.
The SCSI code should grab a reference on the parent device which will
prevent it from going away until the SCSI device does, preventing all of
these oopes.

thanks,

greg k-h
-
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.871 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site