summaryrefslogtreecommitdiffstats
path: root/drivers/xen/grant-table.c
diff options
context:
space:
mode:
authorPaul Durrant <pdurrant@amazon.com>2019-12-11 15:29:56 +0000
committerJuergen Gross <jgross@suse.com>2019-12-20 13:44:45 +0100
commitf4eef1b652eeb850a0f44e8f985cc4153a0c0265 (patch)
tree7e3ac85060e8a9e29ba590743eb6161ecf099e4e /drivers/xen/grant-table.c
parent1ee54195a305fae3955642af8528bdf67496d353 (diff)
downloadlinux-stable-f4eef1b652eeb850a0f44e8f985cc4153a0c0265.tar.gz
linux-stable-f4eef1b652eeb850a0f44e8f985cc4153a0c0265.tar.bz2
linux-stable-f4eef1b652eeb850a0f44e8f985cc4153a0c0265.zip
xen-blkback: support dynamic unbind/bind
By simply re-attaching to shared rings during connect_ring() rather than assuming they are freshly allocated (i.e assuming the counters are zero) it is possible for vbd instances to be unbound and re-bound from and to (respectively) a running guest. This has been tested by running: while true; do fio --name=randwrite --ioengine=libaio --iodepth=16 \ --rw=randwrite --bs=4k --direct=1 --size=1G --verify=crc32; done in a PV guest whilst running: while true; do echo vbd-$DOMID-$VBD >unbind; echo unbound; sleep 5; echo vbd-$DOMID-$VBD >bind; echo bound; sleep 3; done in dom0 from /sys/bus/xen-backend/drivers/vbd to continuously unbind and re-bind its system disk image. This is a highly useful feature for a backend module as it allows it to be unloaded and re-loaded (i.e. updated) without requiring domUs to be halted. This was also tested by running: while true; do echo vbd-$DOMID-$VBD >unbind; echo unbound; sleep 5; rmmod xen-blkback; echo unloaded; sleep 1; modprobe xen-blkback; echo bound; cd $(pwd); sleep 3; done in dom0 whilst running the same loop as above in the (single) PV guest. Some (less stressful) testing has also been done using a Windows HVM guest with the latest 9.0 PV drivers installed. Signed-off-by: Paul Durrant <pdurrant@amazon.com> Reviewed-by: Juergen Gross <jgross@suse.com> Reviewed-by: Roger Pau Monné <roger.pau@citrix.com> Signed-off-by: Juergen Gross <jgross@suse.com>
Diffstat (limited to 'drivers/xen/grant-table.c')
0 files changed, 0 insertions, 0 deletions