From 4b8d425215f9a5f04d6ca51769a1d26cbc084aec Mon Sep 17 00:00:00 2001 From: Jan Kara Date: Fri, 9 Feb 2018 12:52:28 +0100 Subject: [PATCH] udf: Convert descriptor index definitions to enum MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Convert index definitions from defines to enum. It is a shorter description and easier to modify. Also remove VDS_POS_VOL_DESC_PTR since it is unused. Acked-by: Pali Rohár Signed-off-by: Jan Kara --- fs/udf/super.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/fs/udf/super.c b/fs/udf/super.c index 456d737fc7ca..7712fa4b5a3d 100644 --- a/fs/udf/super.c +++ b/fs/udf/super.c @@ -64,14 +64,15 @@ #include #include -#define VDS_POS_PRIMARY_VOL_DESC 0 -#define VDS_POS_UNALLOC_SPACE_DESC 1 -#define VDS_POS_LOGICAL_VOL_DESC 2 -#define VDS_POS_PARTITION_DESC 3 -#define VDS_POS_IMP_USE_VOL_DESC 4 -#define VDS_POS_VOL_DESC_PTR 5 -#define VDS_POS_TERMINATING_DESC 6 -#define VDS_POS_LENGTH 7 +enum { + VDS_POS_PRIMARY_VOL_DESC, + VDS_POS_UNALLOC_SPACE_DESC, + VDS_POS_LOGICAL_VOL_DESC, + VDS_POS_PARTITION_DESC, + VDS_POS_IMP_USE_VOL_DESC, + VDS_POS_TERMINATING_DESC, + VDS_POS_LENGTH +}; #define VSD_FIRST_SECTOR_OFFSET 32768 #define VSD_MAX_SECTOR_OFFSET 0x800000 -- 2.30.2