]> git.ipfire.org Git - people/ms/u-boot.git/commitdiff
drivers: mmc: Change buffer type in ALLOC_CACHE_ALIGN_BUFFER macro
authorSuniel Mahesh <sunil.m@techveda.org>
Thu, 5 Oct 2017 06:02:00 +0000 (11:32 +0530)
committerJaehoon Chung <jh80.chung@samsung.com>
Fri, 12 Jan 2018 09:11:03 +0000 (18:11 +0900)
__be32_to_cpu() accepts argument of type __be32. This patch changes
type of the buffer in ALLOC_CACHE_ALIGN_BUFFER macro to __be32, which
is then passed to __be32_to_cpu().
This prevents sparse build warnings.
drivers/mmc/mmc.c: warning: cast to restricted __be32

Signed-off-by: Suniel Mahesh <sunil.m@techveda.org>
Signed-off-by: Karthik Tummala <karthik@techveda.org>
drivers/mmc/mmc.c

index 38d2e07dd51083872e47cf600cd36fdebc8591c5..8716ac7308f8b5c55cecef1699e507dbd3a4f627 100644 (file)
@@ -882,8 +882,8 @@ static int sd_change_freq(struct mmc *mmc)
 {
        int err;
        struct mmc_cmd cmd;
-       ALLOC_CACHE_ALIGN_BUFFER(uint, scr, 2);
-       ALLOC_CACHE_ALIGN_BUFFER(uint, switch_status, 16);
+       ALLOC_CACHE_ALIGN_BUFFER(__be32, scr, 2);
+       ALLOC_CACHE_ALIGN_BUFFER(__be32, switch_status, 16);
        struct mmc_data data;
        int timeout;