RE: removable media support on 2.6.x

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

 



> 
> afaik we don't really support hot unplug like this.
> 
> Changes were made a few months ago (make the VFS use file->f_mapping
> rather
> than file->f_dentry->d_inode->i_mapping) which set some of the
> pieces in
> place but I think there's a way to go yet.
> 
> umm, the general idea is that when the disk vanishes your driver
> should
> then return -EIO for all future I/O requests.  The block_device, the
> queue,
> the inode and all that stuff remains in-core.

What we do with our 2.4 version of the driver is something on this
lines. When the media is removed we invalidate the buffers and then
set the card absent bit. Now on when read/write requests arrive we
return error status to the file system since card is absent. This worked
for 2.4.x.

Is there some existing driver which addresses removable media on 2.6.x
Kernel? I would like to see how it addresses this.. then I will have
a better idea to address it with the kernel support we have now.

-Jinu

--
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