[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation
From: |
Sergey Bugaev |
Subject: |
Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation |
Date: |
Thu, 9 Jan 2025 18:36:57 +0300 |
On Thu, Jan 9, 2025 at 6:18 PM Jessica Clarke <jrtc27@jrtc27.com> wrote:
> On 9 Jan 2025, at 15:12, Diego Nieto Cid <dnietoc@gmail.com> wrote:
> > Looking at the types.h header, I see there are HWCAP2_* definitions for
> > bits above 32. Since hwcaps_t is an uint32_t and the defs file claims to
> > return two values (I assume the first for HWCAP_* and the second for
> > HWCAP2_*), I don't see how to get the higher bits of HWCAP2_*.
> >
> > How does that work?
>
> On Linux, FreeBSD and any other OS that implements AT_HWCAP(2), you get
> hwcaps via auxv, and Elf_Auxinfo’s a_un.a_val is a long, so it’s 64-bit
> on 64-bit architectures, which aarch64 is. Making hwcaps_t a uint32_t
> on aarch64 is a mistake.
Hmm. Indeed, that looks like an oversight, indeed both Linux and glibc
define hwcaps to be 64-bit.
Let's say that aarch64-gnu is experimental enough that it's fine to
just change the RPC ABI. I'll remember to switch it to uint64_t the
next time I get to it, or perhaps you want to post a patch now?
Sergey
- [RFC PATCH hurd] Add partial /proc/cpuinfo implementation, dnietoc, 2025/01/07
- Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation, Luca, 2025/01/08
- Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation, Diego Nieto Cid, 2025/01/08
- Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation, Luca, 2025/01/08
- Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation, Sergey Bugaev, 2025/01/09
- Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation, Diego Nieto Cid, 2025/01/09
- Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation, Jessica Clarke, 2025/01/09
- Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation,
Sergey Bugaev <=
- Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation, Samuel Thibault, 2025/01/12
- Re: [RFC PATCH hurd] Add partial /proc/cpuinfo implementation, Sergey Bugaev, 2025/01/13