diff options
author | Bradley Bolen <bradleybolen@gmail.com> | 2019-11-17 04:00:45 +0300 |
---|---|---|
committer | Ulf Hansson <ulf.hansson@linaro.org> | 2019-11-18 12:05:38 +0300 |
commit | f3d7c2292d104519195fdb11192daec13229c219 (patch) | |
tree | 040b4395c1952d60bbb8393d1c77a1e16d752f74 /include/linux/mmc | |
parent | c91843463e9e821dc3b48fe37e3155fa38299f6e (diff) | |
download | linux-f3d7c2292d104519195fdb11192daec13229c219.tar.xz |
mmc: core: Fix size overflow for mmc partitions
With large eMMC cards, it is possible to create general purpose
partitions that are bigger than 4GB. The size member of the mmc_part
struct is only an unsigned int which overflows for gp partitions larger
than 4GB. Change this to a u64 to handle the overflow.
Signed-off-by: Bradley Bolen <bradleybolen@gmail.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'include/linux/mmc')
-rw-r--r-- | include/linux/mmc/card.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/mmc/card.h b/include/linux/mmc/card.h index e459b38ef33c..cf3780a6ccc4 100644 --- a/include/linux/mmc/card.h +++ b/include/linux/mmc/card.h @@ -226,7 +226,7 @@ struct mmc_queue_req; * MMC Physical partitions */ struct mmc_part { - unsigned int size; /* partition size (in bytes) */ + u64 size; /* partition size (in bytes) */ unsigned int part_cfg; /* partition type */ char name[MAX_MMC_PART_NAME_LEN]; bool force_ro; /* to make boot parts RO by default */ |