Page MenuHomeFreeBSD

Add rudimentary support for building FreeBSD/arm64 with COMPAT_FREEBSD32.
ClosedPublic

Authored by ed on Nov 18 2017, 1:03 PM.
Referenced Files
Unknown Object (File)
Mon, Apr 22, 10:17 AM
Unknown Object (File)
Jan 30 2024, 11:24 PM
Unknown Object (File)
Dec 23 2023, 2:46 AM
Unknown Object (File)
Dec 2 2023, 11:05 PM
Unknown Object (File)
Nov 14 2023, 9:24 AM
Unknown Object (File)
Sep 6 2023, 6:36 PM
Unknown Object (File)
Sep 6 2023, 6:20 PM
Unknown Object (File)
Sep 1 2023, 12:55 PM
Subscribers

Details

Summary

Right now I'm using two Raspberry Pi's (2 and 3) to test CloudABI
support for armv6, armv7 and aarch64. It would be nice if I could
restrict this to just a single instance when testing smaller changes.
This is why I'd like to get COMPAT_CLOUDABI32 to work on arm64.

As COMPAT_CLOUDABI32 depends on COMPAT_FREEBSD32, at least for the ELF
loading, this change adds all of the bits necessary to at least build a
kernel with COMPAT_FREEBSD32. All of the machine dependent system calls
are still stubbed out, for the reason that implementations for these are
only useful if actual support for running FreeBSD binaries is added.
This is outside the scope of this work.

Test Plan

With this change and others, I am able to run CloudABI armv6/armv7
binaries on FreeBSD/arm64.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

sys/arm64/include/param.h
54 ↗(On Diff #35407)

I wonder if this should be aarch32 and that somewhere else we have a compat that say that aarch32 == armv7

sys/arm64/include/param.h
54 ↗(On Diff #35407)

This is only used by sysctl hw.machine when accessed by 32-bit processes. I suspect it would make sense to pick armv6 (or armv7) here to remain compatible with actual 32-bit systems.

sys/arm64/include/param.h
54 ↗(On Diff #35407)

... and kern.supported_archs as well, it seems.

sys/arm64/include/param.h
54 ↗(On Diff #35407)

We should claim to be armv7

Announce armv7 instead of armv6.

ed added inline comments.
sys/arm64/include/param.h
54 ↗(On Diff #35407)

Done!

This revision is now accepted and ready to land.Nov 24 2017, 1:45 PM
This revision was automatically updated to reflect the committed changes.