[Qemu-devel] [PATCH] blockdev: enable non-root nodes for transaction drive-backup source

Vladimir Sementsov-Ogievskiy posted 1 patch 6 years, 4 months ago
Test s390x passed
Test checkpatch passed
Test asan passed
Test docker-mingw@fedora passed
Test docker-clang@ubuntu passed
Test FreeBSD passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20190618140804.59214-1-vsementsov@virtuozzo.com
Maintainers: Kevin Wolf <kwolf@redhat.com>, Markus Armbruster <armbru@redhat.com>, Max Reitz <mreitz@redhat.com>
blockdev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[Qemu-devel] [PATCH] blockdev: enable non-root nodes for transaction drive-backup source
Posted by Vladimir Sementsov-Ogievskiy 6 years, 4 months ago
We forget to enable it for transaction .prepare, while it is already
enabled in do_drive_backup since commit a2d665c1bc362
    "blockdev: loosen restrictions on drive-backup source node"

Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
---

Hmm, I've to add John by hand, get_maintainer.pl don't report him.
Shouldn't we include blockdev.c into Block Jobs in MAINTAINERS?
It definitely related to block jobs.

 blockdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/blockdev.c b/blockdev.c
index b5c0fd3c49..4ae81d687a 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -1775,7 +1775,7 @@ static void drive_backup_prepare(BlkActionState *common, Error **errp)
     assert(common->action->type == TRANSACTION_ACTION_KIND_DRIVE_BACKUP);
     backup = common->action->u.drive_backup.data;
 
-    bs = qmp_get_root_bs(backup->device, errp);
+    bs = bdrv_lookup_bs(backup->device, backup->device, errp);
     if (!bs) {
         return;
     }
-- 
2.18.0


Re: [Qemu-devel] [PATCH] blockdev: enable non-root nodes for transaction drive-backup source
Posted by John Snow 6 years, 4 months ago

On 6/18/19 10:08 AM, Vladimir Sementsov-Ogievskiy wrote:
> We forget to enable it for transaction .prepare, while it is already
> enabled in do_drive_backup since commit a2d665c1bc362
>     "blockdev: loosen restrictions on drive-backup source node"
> 
> Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
> ---
> 
> Hmm, I've to add John by hand, get_maintainer.pl don't report him.
> Shouldn't we include blockdev.c into Block Jobs in MAINTAINERS?
> It definitely related to block jobs.
> 
>  blockdev.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/blockdev.c b/blockdev.c
> index b5c0fd3c49..4ae81d687a 100644
> --- a/blockdev.c
> +++ b/blockdev.c
> @@ -1775,7 +1775,7 @@ static void drive_backup_prepare(BlkActionState *common, Error **errp)
>      assert(common->action->type == TRANSACTION_ACTION_KIND_DRIVE_BACKUP);
>      backup = common->action->u.drive_backup.data;
>  
> -    bs = qmp_get_root_bs(backup->device, errp);
> +    bs = bdrv_lookup_bs(backup->device, backup->device, errp);
>      if (!bs) {
>          return;
>      }
> 

Ah, tch. I should extend 256 too in this case. Would you like me to take
care of that?

Jokingly: "drive-backup is a legacy interface, please don't use it!"

--js

Re: [Qemu-devel] [PATCH] blockdev: enable non-root nodes for transaction drive-backup source
Posted by Vladimir Sementsov-Ogievskiy 6 years, 4 months ago
18.06.2019 17:24, John Snow wrote:
> 
> 
> On 6/18/19 10:08 AM, Vladimir Sementsov-Ogievskiy wrote:
>> We forget to enable it for transaction .prepare, while it is already
>> enabled in do_drive_backup since commit a2d665c1bc362
>>      "blockdev: loosen restrictions on drive-backup source node"
>>
>> Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
>> ---
>>
>> Hmm, I've to add John by hand, get_maintainer.pl don't report him.
>> Shouldn't we include blockdev.c into Block Jobs in MAINTAINERS?
>> It definitely related to block jobs.
>>
>>   blockdev.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/blockdev.c b/blockdev.c
>> index b5c0fd3c49..4ae81d687a 100644
>> --- a/blockdev.c
>> +++ b/blockdev.c
>> @@ -1775,7 +1775,7 @@ static void drive_backup_prepare(BlkActionState *common, Error **errp)
>>       assert(common->action->type == TRANSACTION_ACTION_KIND_DRIVE_BACKUP);
>>       backup = common->action->u.drive_backup.data;
>>   
>> -    bs = qmp_get_root_bs(backup->device, errp);
>> +    bs = bdrv_lookup_bs(backup->device, backup->device, errp);
>>       if (!bs) {
>>           return;
>>       }
>>
> 
> Ah, tch. I should extend 256 too in this case. Would you like me to take
> care of that?

It will be great

> 
> Jokingly: "drive-backup is a legacy interface, please don't use it!"
> 
> --js
> 


-- 
Best regards,
Vladimir
Re: [Qemu-devel] [PATCH] blockdev: enable non-root nodes for transaction drive-backup source
Posted by John Snow 6 years, 4 months ago

On 6/18/19 10:08 AM, Vladimir Sementsov-Ogievskiy wrote:
> We forget to enable it for transaction .prepare, while it is already
> enabled in do_drive_backup since commit a2d665c1bc362
>     "blockdev: loosen restrictions on drive-backup source node"
> 
> Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
> ---
> 
> Hmm, I've to add John by hand, get_maintainer.pl don't report him.
> Shouldn't we include blockdev.c into Block Jobs in MAINTAINERS?
> It definitely related to block jobs.
> 
>  blockdev.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/blockdev.c b/blockdev.c
> index b5c0fd3c49..4ae81d687a 100644
> --- a/blockdev.c
> +++ b/blockdev.c
> @@ -1775,7 +1775,7 @@ static void drive_backup_prepare(BlkActionState *common, Error **errp)
>      assert(common->action->type == TRANSACTION_ACTION_KIND_DRIVE_BACKUP);
>      backup = common->action->u.drive_backup.data;
>  
> -    bs = qmp_get_root_bs(backup->device, errp);
> +    bs = bdrv_lookup_bs(backup->device, backup->device, errp);
>      if (!bs) {
>          return;
>      }
> 
I'm half asleep, sorry, this isn't related to the patch that
necessitated 256. This is fine as-is.

Reviewed-by: John Snow <jsnow@redhat.com>

Re: [Qemu-devel] [PATCH] blockdev: enable non-root nodes for transaction drive-backup source
Posted by Max Reitz 6 years, 4 months ago
On 18.06.19 16:08, Vladimir Sementsov-Ogievskiy wrote:
> We forget to enable it for transaction .prepare, while it is already
> enabled in do_drive_backup since commit a2d665c1bc362
>     "blockdev: loosen restrictions on drive-backup source node"
> 
> Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
> ---
> 
> Hmm, I've to add John by hand, get_maintainer.pl don't report him.
> Shouldn't we include blockdev.c into Block Jobs in MAINTAINERS?
> It definitely related to block jobs.
> 
>  blockdev.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Thanks, applied to my block branch:

https://git.xanclic.moe/XanClic/qemu/commits/branch/block

Max