[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <180a123c-304e-2e74-fed6-9da463e985b6@physik.fu-berlin.de>
Date: Thu, 23 Sep 2021 17:20:43 +0200
From: John Paul Adrian Glaubitz <glaubitz@...sik.fu-berlin.de>
To: Geert Uytterhoeven <geert+renesas@...der.be>,
Yoshinori Sato <ysato@...rs.sourceforge.jp>,
Rich Felker <dalias@...c.org>,
"Aneesh Kumar K . V" <aneesh.kumar@...ux.ibm.com>,
Andrew Morton <akpm@...ux-foundation.org>
Cc: Jacopo Mondi <jacopo+renesas@...ndi.org>,
Daniel Palmer <daniel@...f.com>, linux-sh@...r.kernel.org,
linux-mm@...ck.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] sh: pgtable-3level: Fix cast to pointer from integer of
different size
Hi Geert!
On 9/15/21 15:50, Geert Uytterhoeven wrote:
> If X2TLB=y (CPU_SHX2=y or CPU_SHX3=y, e.g. migor_defconfig), pgd_t.pgd
> is "unsigned long long", causing:
>
> In file included from arch/sh/include/asm/pgtable.h:13,
> from include/linux/pgtable.h:6,
> from include/linux/mm.h:33,
> from arch/sh/kernel/asm-offsets.c:14:
> arch/sh/include/asm/pgtable-3level.h: In function ‘pud_pgtable’:
> arch/sh/include/asm/pgtable-3level.h:37:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
> 37 | return (pmd_t *)pud_val(pud);
> | ^
>
> Fix this by adding an intermediate cast to "unsigned long", which is
> basically what the old code did before.
Thanks a lot for fixing this. My SH kernel build becomes much less noisy with
your patch. I can also confirm that it doesn't break the boot on my SH-7785LCR
as expected.
Tested-by: John Paul Adrian Glaubitz <glaubitz@...sik.fu-berlin.de>
Adrian
--
.''`. John Paul Adrian Glaubitz
: :' : Debian Developer - glaubitz@...ian.org
`. `' Freie Universitaet Berlin - glaubitz@...sik.fu-berlin.de
`- GPG: 62FF 8A75 84E0 2956 9546 0006 7426 3B37 F5B5 F913
Powered by blists - more mailing lists