]> git.baikalelectronics.ru Git - kernel.git/commit
virtio_blk: allow re-reading config space at runtime
authorChristoph Hellwig <hch@lst.de>
Tue, 1 Feb 2011 20:43:48 +0000 (21:43 +0100)
committerRusty Russell <rusty@rustcorp.com.au>
Mon, 30 May 2011 01:44:13 +0000 (11:14 +0930)
commit5e91166292495426128ee135c899089208d48d72
tree717aba1aab456d252c684abf256afa8e92b7dd96
parentd8292fc11982289718656663b6fb10bea733e8a6
virtio_blk: allow re-reading config space at runtime

Wire up the virtio_driver config_changed method to get notified about
config changes raised by the host.  For now we just re-read the device
size to support online resizing of devices, but once we add more
attributes that might be changeable they could be added as well.

Note that the config_changed method is called from irq context, so
we'll have to use the workqueue infrastructure to provide us a proper
user context for our changes.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
drivers/block/virtio_blk.c