diff options
author | Emanuele Giuseppe Esposito <eesposit@redhat.com> | 2022-03-03 10:15:51 -0500 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2022-03-04 18:18:25 +0100 |
commit | 8cc5882c7fe0759f856b2f97a08816353227e8f7 (patch) | |
tree | 3000c18a5fa451d104a1f69c29ff9cfd97cf63f8 /block/block-backend.c | |
parent | 384a48fb7423dfb303023eb504e1fc5e6acb4de4 (diff) |
block/export/fuse.c: allow writable exports to take RESIZE permission
Allow writable exports to get BLK_PERM_RESIZE permission
from creation, in fuse_export_create().
In this way, there is no need to give the permission in
fuse_do_truncate(), which might be run in an iothread.
Permissions should be set only in the main thread, so
in any case if an iothread tries to set RESIZE, it will
be blocked.
Also assert in fuse_do_truncate that if we give the
RESIZE permission we can then restore the original ones.
Signed-off-by: Emanuele Giuseppe Esposito <eesposit@redhat.com>
Reviewed-by: Hanna Reitz <hreitz@redhat.com>
Message-Id: <20220303151616.325444-7-eesposit@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block/block-backend.c')
0 files changed, 0 insertions, 0 deletions