lkml.org 
[lkml]   [2015]   [Dec]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH v6 09/20] arm64:ilp32: share HWCAP between LP64 and ILP32
Date
On Thursday 17 December 2015 10:54:47 Catalin Marinas wrote:
> > > IIUC, we may have a problem with this. elf_hwcap is 64-bit long while
> > > elf_info[n] is 32-bit (Elf32_Addr), so we truncate AT_HWCAP if we ever
> > > go beyond bit 31. The above may need to look something like:
> > >
> > > #define COMPAT_ELF_HWCAP \
> > > (is_a32_compat_task() \
> > > ? compat_elf_hwcap \
> > > : (u32)elf_hwcap)
> > >
> > > #define COMPAT_ELF_HWCAP2 \
> > > (is_a32_compat_task() \
> > > ? compat_elf_hwcap2 \
> > > : (u32)(elf_hwcap >> 32))
> >
> > Yes, interesting find.
>
> BTW, we need to make sure this series (primarily the ABI) is big-endian
> safe. I know it is not targeted at this initially but given that the
> reason for doing it is legacy networking code, I wouldn't be surprised
> if someone asks for BE at some point in the future.

Yes, I'm sure that will be needed.

Arnd


\
 
 \ /
  Last update: 2015-12-17 15:21    [W:0.107 / U:0.216 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site