]> git.proxmox.com Git - mirror_qemu.git/commit - block/mirror.c
block: Always call bdrv_child_check_perm first
authorFam Zheng <famz@redhat.com>
Tue, 14 Mar 2017 02:30:50 +0000 (10:30 +0800)
committerKevin Wolf <kwolf@redhat.com>
Fri, 17 Mar 2017 11:54:06 +0000 (12:54 +0100)
commitc1cef67251d3e6ae275c0898ccf4cbcfe85d4e0b
treee66118024fe5e6618ffe966901a05862950da8e4
parentfed414df9dc9abef040adfbd8c5956fb610edaa2
block: Always call bdrv_child_check_perm first

bdrv_child_set_perm alone is not very usable because the caller must
call bdrv_child_check_perm first. This is already encapsulated
conveniently in bdrv_child_try_set_perm, so remove the other prototypes
from the header and fix the one wrong caller, block/mirror.c.

Signed-off-by: Fam Zheng <famz@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block.c
block/mirror.c
include/block/block_int.h