Transcend CF pcmcia card no longer works
Quoted 16 lines · Nick Piggin
Quoted 11 lines · Andrew Morton
(Adding bugzilla back to cc)
Quoted 6 lines · Tejun Heo
Quoted 2 lines
I'm not sure that it has been deallocated, rather something has overwritten it, no?
The ldm validation or failure seems irrelevant. From the original bug report.
Looks like you're right.
Quoted 9 lines
It was just odd that the ldm check worked and the msdos one oopsed; both attempt to read the same block in the same manner.
Perhaps it may be that the queue was freed long before then, and only just gets reused for something else and overwritten at this point.
slab debugging might help?
[CC'ing Bartlomiej and linux-ide]
Hello, Bartlomiej.
This thread started by Andrew forwarding bugzilla #5880 to as-iosched related people as the machine oopsed in anticipatory scheduler. After diagnosis, it seems to be premature device release problem of IDE driver. The original bug entry is
http://bugzilla.kernel.org/show_bug.cgi?id=5880
The original bug is about CF device unuseable. The oops occurs after yanking out the CF device during partition check is in progress (all are failing due to IO error).
I've glanced through the IDE code and the problem seems to be in ide_disk_get(). This function doesn't get the IDE generic device (ide_drive_t->gendev) and so if a device is yanked out while it's still open, the gendev doesn't wait for the open fd's to be closed. This results in dangling open block device and thus above oops. I'm not very sure about this analysis and currently don't have access to hot-unpluggable IDE devices.
Can you please confirm this?
Thanks.
Signature · 1 line
tejun
Quoted 52 lines · Tejun Heo
Quoted 18 lines · Nick Piggin
Quoted 13 lines · Andrew Morton
(Adding bugzilla back to cc)
Quoted 8 lines · Tejun Heo
Quoted 3 lines
I'm not sure that it has been deallocated, rather something has overwritten
it, no?The ldm validation or failure seems irrelevant. From the original bug report.
Looks like you're right.
Quoted 9 lines
It was just odd that the ldm check worked and the msdos one oopsed; both attempt to read the same block in the same manner.
Perhaps it may be that the queue was freed long before then, and only just gets reused for something else and overwritten at this point.
slab debugging might help?
[CC'ing Bartlomiej and linux-ide]
Hello, Bartlomiej.
This thread started by Andrew forwarding bugzilla #5880 to as-iosched related people as the machine oopsed in anticipatory scheduler. After diagnosis, it seems to be premature device release problem of IDE driver. The original bug entry is
http://bugzilla.kernel.org/show_bug.cgi?id=5880
The original bug is about CF device unuseable. The oops occurs after yanking out the CF device during partition check is in progress (all are failing due to IO error).
I've glanced through the IDE code and the problem seems to be in
ide_disk_get(). This function doesn't get the IDE generic device (ide_drive_t->gendev) and so if a device is yanked out while it's still open, the gendev doesn't wait for the open fd's to be closed. This results in dangling open block device and thus above oops. I'm not very sure about this analysis and currently don't have access to hot-unpluggable IDE devices.
Quoted 1 line
Can you please confirm this?
Hi Tejun,
Confirmed, we need to get/put generic device in ide_disk_{get,put}() similarly like drivers/scsi/sd.c driver does it (the same also applies to ide-{cd,floppy,tape,scsi} drivers).
I would happily apply a patch fixing it (*hint*, *hint*).
Now back to the original problem ("ghost" slave device):
Pavel, is there any way to recognize this PCMCIA IDE controller in ide-cs driver so we could tell IDE subsystem not to probe slave devices?
Thanks,
Bartlomiej