lkml.org 
[lkml]   [2021]   [Sep]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] sh: pgtable-3level: Fix cast to pointer from integer of different size
From
Date
On 9/15/21 8:50 AM, Geert Uytterhoeven wrote:
> arch/sh/include/asm/pgtable-3level.h:37:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
...
> The truncation to "unsigned long" has been there since forever, so
> probably it still works fine ;-)

1) Linux is LP64 so sizeof(long) and sizeof(pointer) always match, so it's not
truncating.

2) The sh5 only ever shipped evaluation units, it never had a production run,
and we haven't implemented j64 yet, so all superh targets are currently 32 bit.
(I.E. it's complaining about _expanding_ the pointer, which shouldn't be a
problem as long as endianness is respected.)

Rob

\
 
 \ /
  Last update: 2021-09-17 03:13    [W:0.113 / U:0.092 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site