diff --git a/lib/bdev/gpt/gpt.h b/lib/bdev/gpt/gpt.h index 54aa35dfa6..093e43ddfd 100644 --- a/lib/bdev/gpt/gpt.h +++ b/lib/bdev/gpt/gpt.h @@ -43,7 +43,7 @@ #define SPDK_GPT_PART_TYPE_GUID SPDK_GPT_GUID(0x7c5222bd, 0x8f5d, 0x4087, 0x9c00, 0xbf9843c7b58c) #define SPDK_GPT_BUFFER_SIZE 32768 /* 32KB */ -#define SPDK_GPT_UUID_EQUAL(x,y) (memcmp(x, y, sizeof(struct spdk_gpt_guid)) == 0) +#define SPDK_GPT_GUID_EQUAL(x,y) (memcmp(x, y, sizeof(struct spdk_gpt_guid)) == 0) struct spdk_gpt { unsigned char *buf; diff --git a/lib/bdev/gpt/vbdev_gpt.c b/lib/bdev/gpt/vbdev_gpt.c index dc087d88a4..effa692c2d 100644 --- a/lib/bdev/gpt/vbdev_gpt.c +++ b/lib/bdev/gpt/vbdev_gpt.c @@ -330,7 +330,7 @@ vbdev_gpt_create_bdevs(struct spdk_gpt_bdev *gpt_bdev) uint64_t lba_start = from_le64(&p->starting_lba); uint64_t lba_end = from_le64(&p->ending_lba); - if (!SPDK_GPT_UUID_EQUAL(&gpt->partitions[i].part_type_guid, + if (!SPDK_GPT_GUID_EQUAL(&gpt->partitions[i].part_type_guid, &SPDK_GPT_PART_TYPE_GUID) || lba_start == 0) { continue; diff --git a/scripts/autotest_common.sh b/scripts/autotest_common.sh index b698fd0ca0..24c2cf8b0c 100755 --- a/scripts/autotest_common.sh +++ b/scripts/autotest_common.sh @@ -32,7 +32,7 @@ config_params='--enable-debug --enable-werror' export UBSAN_OPTIONS='halt_on_error=1:print_stacktrace=1:abort_on_error=1' -export SPDK_GPT_UUID=`grep SPDK_GPT_PART_TYPE_GUID $rootdir/lib/bdev/gpt/gpt.h \ +export SPDK_GPT_GUID=`grep SPDK_GPT_PART_TYPE_GUID $rootdir/lib/bdev/gpt/gpt.h \ | awk -F "(" '{ print $2}' | sed 's/)//g' \ | awk -F ", " '{ print $1 "-" $2 "-" $3 "-" $4 "-" $5}' | sed 's/0x//g'` diff --git a/test/lib/bdev/blockdev.sh b/test/lib/bdev/blockdev.sh index b992c5f7ed..20eb7ba7a7 100755 --- a/test/lib/bdev/blockdev.sh +++ b/test/lib/bdev/blockdev.sh @@ -33,8 +33,8 @@ if [ $(uname -s) = Linux ] && [ -f /usr/sbin/sgdisk ]; then if [ -e /dev/nbd0 ]; then parted -s /dev/nbd0 mklabel gpt mkpart primary '0%' '50%' mkpart primary '50%' '100%' # change the partition type GUID to SPDK GUID value - /usr/sbin/sgdisk -t 1:$SPDK_GPT_UUID /dev/nbd0 - /usr/sbin/sgdisk -t 2:$SPDK_GPT_UUID /dev/nbd0 + /usr/sbin/sgdisk -t 1:$SPDK_GPT_GUID /dev/nbd0 + /usr/sbin/sgdisk -t 2:$SPDK_GPT_GUID /dev/nbd0 fi killprocess $nbd_pid fi