diff options
author | Fam Zheng | 2013-05-29 13:35:40 +0200 |
---|---|---|
committer | Kevin Wolf | 2013-06-04 12:11:58 +0200 |
commit | b64ec4e4ade581d662753cdeb0d7e0e27aafbf81 (patch) | |
tree | 73a06f4c2528be5cf76830bb9679b4a37e87aa7e /configure | |
parent | qemu-iotests: fix 054 cluster size help output (diff) | |
download | qemu-b64ec4e4ade581d662753cdeb0d7e0e27aafbf81.tar.gz qemu-b64ec4e4ade581d662753cdeb0d7e0e27aafbf81.tar.xz qemu-b64ec4e4ade581d662753cdeb0d7e0e27aafbf81.zip |
block: add block driver read only whitelist
We may want to include a driver in the whitelist for read only tasks
such as diagnosing or exporting guest data (with libguestfs as a good
example). This patch introduces a readonly whitelist option, and for
backward compatibility, the old configure option --block-drv-whitelist
is now an alias to rw whitelist.
Drivers in readonly list is only permitted to open file readonly, and
returns -ENOTSUP for RW opening.
E.g. To include vmdk readonly, and others read+write:
./configure --target-list=x86_64-softmmu \
--block-drv-rw-whitelist=qcow2,raw,file,qed \
--block-drv-ro-whitelist=vmdk
Signed-off-by: Fam Zheng <famz@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 20 |
1 files changed, 15 insertions, 5 deletions
@@ -123,7 +123,8 @@ interp_prefix="/usr/gnemul/qemu-%M" static="no" cross_prefix="" audio_drv_list="" -block_drv_whitelist="" +block_drv_rw_whitelist="" +block_drv_ro_whitelist="" host_cc="cc" libs_softmmu="" libs_tools="" @@ -708,7 +709,9 @@ for opt do ;; --audio-drv-list=*) audio_drv_list="$optarg" ;; - --block-drv-whitelist=*) block_drv_whitelist=`echo "$optarg" | sed -e 's/,/ /g'` + --block-drv-rw-whitelist=*|--block-drv-whitelist=*) block_drv_rw_whitelist=`echo "$optarg" | sed -e 's/,/ /g'` + ;; + --block-drv-ro-whitelist=*) block_drv_ro_whitelist=`echo "$optarg" | sed -e 's/,/ /g'` ;; --enable-debug-tcg) debug_tcg="yes" ;; @@ -1049,7 +1052,12 @@ echo " --disable-cocoa disable Cocoa (Mac OS X only)" echo " --enable-cocoa enable Cocoa (default on Mac OS X)" echo " --audio-drv-list=LIST set audio drivers list:" echo " Available drivers: $audio_possible_drivers" -echo " --block-drv-whitelist=L set block driver whitelist" +echo " --block-drv-whitelist=L Same as --block-drv-rw-whitelist=L" +echo " --block-drv-rw-whitelist=L" +echo " set block driver read-write whitelist" +echo " (affects only QEMU, not qemu-img)" +echo " --block-drv-ro-whitelist=L" +echo " set block driver read-only whitelist" echo " (affects only QEMU, not qemu-img)" echo " --enable-mixemu enable mixer emulation" echo " --disable-xen disable xen backend driver support" @@ -3481,7 +3489,8 @@ echo "curses support $curses" echo "curl support $curl" echo "mingw32 support $mingw32" echo "Audio drivers $audio_drv_list" -echo "Block whitelist $block_drv_whitelist" +echo "Block whitelist (rw) $block_drv_rw_whitelist" +echo "Block whitelist (ro) $block_drv_ro_whitelist" echo "Mixer emulation $mixemu" echo "VirtFS support $virtfs" echo "VNC support $vnc" @@ -3662,7 +3671,8 @@ fi if test "$audio_win_int" = "yes" ; then echo "CONFIG_AUDIO_WIN_INT=y" >> $config_host_mak fi -echo "CONFIG_BDRV_WHITELIST=$block_drv_whitelist" >> $config_host_mak +echo "CONFIG_BDRV_RW_WHITELIST=$block_drv_rw_whitelist" >> $config_host_mak +echo "CONFIG_BDRV_RO_WHITELIST=$block_drv_ro_whitelist" >> $config_host_mak if test "$mixemu" = "yes" ; then echo "CONFIG_MIXEMU=y" >> $config_host_mak fi |