Re: Writeback threads and freezable

Rafael J. Wysocki
2013-12-18T22:01:07Z

On Wednesday, December 18, 2013 06:43:43 AM Tejun Heo wrote:

[...]

> If filesystems need an indication that the underlying device is no
> longer functional, please go ahead and add it, but please keep in mind
> all these are completely asynchronous. Nothing guarantees you that
> such events would happen in any specific order. IOW, you can be at
> *ANY* point in your warm unplug path and the device is hot unplugged,
> which essentially forces all the code paths to be ready for the worst,
> and that's exactly why there isn't much effort in trying to separate
> out warm and hot unplug paths.

Yes. Devices can go away at any point without notice. Even PCI devices
that have never been assumed to be hot-removable. Any piece of code in the
kernel needs to be prepared to deal with such situations.

Thanks,
Rafael