HomeFreeBSD

powerpc64: fix loader regression

Description

powerpc64: fix loader regression

After b4cb3fe0e39a, loader started crashing on PowerPC64, with a
Program Exception (700) error. The problem was that archsw was
used before being initialized, with the new mount feature. This
change fixes the issue by initializing archsw earlier, before
setting currdev, that triggers the mount.

Reviewed by: tsoome
MFC after: 1 month
X-MFC-With: b4cb3fe0e39a
Sponsored by: Instituto de Pesquisas Eldorado (eldorado.org.br)
Differential Revision: https://reviews.freebsd.org/D32027

(cherry picked from commit 680ca739458ba8cba221ea74794c2cd9771c77f8)

Details

Provenance
luporlAuthored on Sep 21 2021, 8:22 PM
alfredoCommitted on Mar 4 2022, 10:18 PM
Reviewer
rGb4cb3fe0e39a: loader: implement mount/unmount rootfs
Differential Revision
D32027: powerpc64: fix loader regression
Parents
rG543157870da5: rmlock: Micro-optimize read locking
Branches
Unknown
Tags
Unknown