NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: kern/57320: ATF test case kernel/t_magic_symlinks:machine_arch fails on RPI02W/evbarm only
The following reply was made to PR kern/57320; it has been noted by GNATS.
From: mlelstv%serpens.de@localhost (Michael van Elst)
To: gnats-bugs%netbsd.org@localhost
Cc:
Subject: Re: kern/57320: ATF test case kernel/t_magic_symlinks:machine_arch fails on RPI02W/evbarm only
Date: Wed, 12 Apr 2023 08:45:54 -0000 (UTC)
martin%duskware.de@localhost (Martin Husemann) writes:
> I am confused. uname -p and -m print hw.machine ("evbarm") and
> hw.machine_arch ("earmv6hf") respectively. Those are the values that
> the magic symlinks should use too (and I think they do).
>
> Where does the ABI name ("earm") come into play?
vfs uses the compile time constant MACHINE_ARCH == "earm". It might
better use the variable machine_arch, but that wouldn't change
anything.
MACHINE_ARCH is set in arm/param.h, when not overriden by
build.sh, the kernel only uses earm, arm, earmeb or armeb.
Userland gets more refined values depending on the compiler
target.
sysctl uses (P)->p_md.md_march, which is initially MACHINE_ARCH
but then gets overridden by ep_machine_arch which is the
ELF_NOTE_MARCH_NAME of the executable currently running.
Displaying notes found in: .note.netbsd.march
Owner Data size Description
NetBSD 0x00000009 MARCH <earmv6hf>
Changing vfs to use PROC_MACHINE_ARCH(p) might help, but
PROC_MACHINE_ARCH is a MD thing (arm + mips). sysctl defaults
to use machine_arch if the arch doesn't define the macro.
Home |
Main Index |
Thread Index |
Old Index