[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e661a947f0cefb1651dcd3f7f57855313ad9fd7a.camel@crapouillou.net>
Date: Wed, 24 Dec 2025 14:30:56 +0100
From: Paul Cercueil <paul@...pouillou.net>
To: Krzysztof Kozlowski <krzysztof.kozlowski@....qualcomm.com>, Aubin
Constans <aubin.constans@...rochip.com>, Ulf Hansson
<ulf.hansson@...aro.org>, Nicolas Ferre <nicolas.ferre@...rochip.com>,
Alexandre Belloni <alexandre.belloni@...tlin.com>, Claudiu Beznea
<claudiu.beznea@...on.dev>, Robert Richter <rric@...nel.org>, Andrew
Jeffery <andrew@...econstruct.com.au>, Adrian Hunter
<adrian.hunter@...el.com>, Joel Stanley <joel@....id.au>, Nathan Chancellor
<nathan@...nel.org>, Nick Desaulniers <nick.desaulniers+lkml@...il.com>,
Bill Wendling <morbo@...gle.com>, Justin Stitt <justinstitt@...gle.com>,
linux-mmc@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org, linux-mips@...r.kernel.org,
linux-aspeed@...ts.ozlabs.org, openbmc@...ts.ozlabs.org,
llvm@...ts.linux.dev
Subject: Re: [PATCH 3/4] mmc: jz4740: Fix Wvoid-pointer-to-enum-cast warning
Hi Krzysztof,
Le mercredi 24 décembre 2025 à 13:44 +0100, Krzysztof Kozlowski a
écrit :
> "jz4740" is an enum, thus cast of pointer on 64-bit compile test with
> clang W=1 causes:
>
> jz4740_mmc.c:1055:18: error: cast to smaller integer type 'enum
> jz4740_mmc_version' from 'const void *' [-Werror,-Wvoid-pointer-to-
> enum-cast]
>
> Signed-off-by: Krzysztof Kozlowski
> <krzysztof.kozlowski@....qualcomm.com>
Reviewed-by: Paul Cercueil <paul@...pouillou.net>
Cheers,
-Paul
> ---
> drivers/mmc/host/jz4740_mmc.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mmc/host/jz4740_mmc.c
> b/drivers/mmc/host/jz4740_mmc.c
> index 6a0d0250d47b..6a3c26b7c82d 100644
> --- a/drivers/mmc/host/jz4740_mmc.c
> +++ b/drivers/mmc/host/jz4740_mmc.c
> @@ -1052,7 +1052,7 @@ static int jz4740_mmc_probe(struct
> platform_device* pdev)
> host = mmc_priv(mmc);
>
> /* Default if no match is JZ4740 */
> - host->version = (enum
> jz4740_mmc_version)device_get_match_data(&pdev->dev);
> + host->version = (unsigned long)device_get_match_data(&pdev-
> >dev);
>
> ret = mmc_of_parse(mmc);
> if (ret)
Powered by blists - more mailing lists