Re: Block device driver: how to terminate the block device if media disappears?

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

 



On 21/12/12 18:23, Ezequiel Garcia wrote:

> On Thu, Dec 13, 2012 at 12:31 PM, John Beard <johnb@xxxxxxxxxxxxxxxx> wrote:
>>
>> What is the right way to terminate requests and delete the gendisk in
>> the case of physically vanished PCI devices (or even devices in general)?
>>
> 
> There are several block driver examples in drivers/block.
> Or you might want to take a loot at mtdblock.c, or perhaps
> this simple ubiblock implementation:
> 
> http://lwn.net/Articles/525957/

Thanks, Ezequiel - sorry for the delay, I haven't had a chance to touch
my development computer over the break. The workqueue-based approach
from ubiblock.c seems to have solved the problem and the device can now
shut down happily once the request queue is emptied in the submit_req
call following device removal.

Thanks again for your help!

John Beard

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


[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