Spdk/test/unit/lib
Tomasz Zawadzki 68063cd8b6 lib/blob: force md update during decouple parent
Fixes #1933

When decoupling parent the updated parent_id was
not persisted to the blob if it was a snapshot.
Due to having md_ro set to true, blob_set_xattr()
failed.

Later on the incorrect parent_id could cause troubles
like in the github issue, when deleting that snapshot.

This patch adds return code check for blob_set_xattr
and forces md_ro to false during blob md sync.

Since some of code paths are shared between decouple,
inflate and clone operations, the final callback for them
is doing revert of the original md_ro.

Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Change-Id: If017455f72e4d809fe533d9f986e5ae6bb8e2035
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8420
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Community-CI: Mellanox Build Bot
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
2021-07-16 23:25:45 +00:00
..
accel thread: Make the definition of struct spdk_io_channel private 2021-06-25 05:01:45 +00:00
bdev bdev/nvme: Create nvme_bdev_channel for nvme_bdev 2021-07-14 09:15:59 +00:00
blob lib/blob: force md update during decouple parent 2021-07-16 23:25:45 +00:00
blobfs thread: Make the definition of struct spdk_io_channel private 2021-06-25 05:01:45 +00:00
env_dpdk unit: add unit test for the pci event 2021-04-19 12:55:17 +00:00
event scheduler_dynamic: move thread to least busy core 2021-07-12 21:58:56 +00:00
ftl thread: Make the definition of struct spdk_io_channel private 2021-06-25 05:01:45 +00:00
idxd idxd/rpc: Revise the rpc function to use kernel or user driver 2021-07-13 17:22:30 +00:00
init event: Shift subsystem initialization code to a separate library 2021-05-24 10:12:50 +00:00
ioat ut: make use of CUnit macro to reduce duplications 2020-04-02 14:50:12 +00:00
iscsi mk/unit: link with trace library 2021-06-10 10:58:05 +00:00
json json: add spdk_json_free_object() 2020-10-19 10:02:10 +00:00
jsonrpc lib/jsonrpc: remove spdk_ prefix from internal functions. 2020-05-11 12:29:07 +00:00
log log: simplify SPDK_LOG_REGISTER_COMPONENT 2020-10-14 08:00:35 +00:00
lvol thread: Make the definition of struct spdk_io_channel private 2021-06-25 05:01:45 +00:00
notify ut: make use of CUnit macro to reduce duplications 2020-04-02 14:50:12 +00:00
nvme nvme: Fix the bug that assumed ANA group descriptor is 8-bytes aligned 2021-07-14 09:15:59 +00:00
nvmf test/nvmf/tcp: cases for qpair memory resource initialization 2021-07-16 07:13:02 +00:00
reduce test: add generic unlink wrapper 2020-05-06 12:43:57 +00:00
scsi scsi: Delete mutex from spdk_scsi_globals 2021-06-17 08:59:18 +00:00
sock sock: Add sock_map_find_free 2021-04-22 07:29:26 +00:00
thread thread: speed up io_device lookup by using rbtree 2021-07-16 07:11:53 +00:00
util util/crc32c: Add spdk_crc32c_iov_update. 2021-06-02 11:37:17 +00:00
vhost lib/vhost: force cpumask to be subset of application's CPU mask 2021-02-04 08:35:08 +00:00
json_mock.c ut/json_mock: Add spdk_json_write_string_fmt() 2021-02-09 11:29:53 +00:00
Makefile event: Shift subsystem initialization code to a separate library 2021-05-24 10:12:50 +00:00