From a6029e1f75bb484c1f5bc68b6a8572e4024795bc Mon Sep 17 00:00:00 2001 From: Namjae Jeon Date: Thu, 13 Oct 2011 00:43:14 +0900 Subject: [PATCH] mmc: fix compile error when CONFIG_BLOCK is not enabled 'DISK_NAME_LEN' is undeclared when CONFIG_BLOCK is disabled; its use was introduced via genhd.h by the general purpose partition patch. To fix, we just add our own MAX_MMC_PART_NAME_LEN macro instead of using DISK_NAME_LEN. Reported-by: Randy Dunlap Signed-off-by: Namjae Jeon Acked-by: Randy Dunlap Acked-by: Andrei Warkentin Signed-off-by: Chris Ball --- include/linux/mmc/card.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/linux/mmc/card.h b/include/linux/mmc/card.h index 1684d92a8015..415f2db414e1 100644 --- a/include/linux/mmc/card.h +++ b/include/linux/mmc/card.h @@ -12,7 +12,6 @@ #include #include -#include struct mmc_cid { unsigned int manfid; @@ -175,6 +174,7 @@ struct sdio_func_tuple; #define MMC_NUM_BOOT_PARTITION 2 #define MMC_NUM_GP_PARTITION 4 #define MMC_NUM_PHY_PARTITION 6 +#define MAX_MMC_PART_NAME_LEN 20 /* * MMC Physical partitions @@ -182,7 +182,7 @@ struct sdio_func_tuple; struct mmc_part { unsigned int size; /* partition size (in bytes) */ unsigned int part_cfg; /* partition type */ - char name[DISK_NAME_LEN]; + char name[MAX_MMC_PART_NAME_LEN]; bool force_ro; /* to make boot parts RO by default */ }; -- GitLab