Page MenuHomeFreeBSD

powerpc/pic: fix the openpic CPU logic to work on powermac
ClosedPublic

Authored by adrian on Apr 30 2026, 7:50 PM.
Referenced Files
F168239420: D56751.diff
Thu, Aug 27, 3:03 AM
Unknown Object (File)
Wed, Aug 26, 4:15 AM
Unknown Object (File)
Wed, Aug 26, 3:07 AM
Unknown Object (File)
Tue, Aug 25, 6:56 PM
Unknown Object (File)
Tue, Aug 25, 4:33 PM
Unknown Object (File)
Mon, Aug 24, 11:30 PM
Unknown Object (File)
Sun, Aug 23, 4:40 PM
Unknown Object (File)
Sat, Aug 22, 11:13 PM

Details

Summary

Earlier work (40bcad56f - powerpc/pic: Add a PIC_AP_INIT() to
set up AP PIC info) broke booting my dual G5 powermac.

After much digging, jhibbits@ and I discovered that the openpic
implementation for the memory/bus controller used in the G5 CPUs
doesn't implement /all/ of the openpic specification.
Notably it sticks the WHOAMI register in a different location.
This is reading 0x0 back for all the PICs which is .. very not great.

So to restore the previous behaviour, use a quick for now that jhibbits@
can set appropriately to trust WHOAMI.

I've tested this on my dual G5 PPC and it boots/runs fine.

Fixes: 40bcad56f

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 72685
Build 69568: arc lint + arc unit

Event Timeline

This really is funny, that we're working around broken IBM and Apple hardware by putting a quirk on the one conforming implementer.

This revision is now accepted and ready to land.Apr 30 2026, 10:24 PM