Page MenuHomeFreeBSD

Add support for SMP on arm64.
ClosedPublic

Authored by andrew on Jul 8 2015, 5:09 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Nov 23, 6:55 AM
Unknown Object (File)
Fri, Nov 22, 1:24 AM
Unknown Object (File)
Thu, Nov 21, 11:19 AM
Unknown Object (File)
Oct 26 2024, 7:16 PM
Unknown Object (File)
Oct 24 2024, 3:36 PM
Unknown Object (File)
Oct 1 2024, 11:51 AM
Unknown Object (File)
Oct 1 2024, 10:47 AM
Unknown Object (File)
Sep 28 2024, 10:49 AM
Subscribers

Details

Summary

Add support for SMP. This uses the FDT data to find the CPUs to start
on, and psci to start them. I expect ACPI support to be added later.

This has been tested on qemu with 2 cpus as that is the current value
of MAXCPUS.

Partially based on a patch from Robin Randhawa from ARM.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage

Event Timeline

andrew retitled this revision from to Add support for SMP on arm64..
andrew updated this object.
andrew edited the test plan for this revision. (Show Details)
andrew added reviewers: zbb, imp, wma_semihalf.com.
andrew added a subscriber: emaste.

The Semihalf 48 core SMP testing is on a branch which started from (a version of) this change. I will defer to @zbb and @wma_semihalf.com for specific details and comment, but it seems reasonable to me to commit this change once reviewed and have Semihalf add the additional changes as separate commits to svn HEAD.

sys/arm64/include/smp.h
43

Should we make it ARM64TODO?

That would be great if you could commit this patch "as is". We have few fixes to mp_machdep/locore which are currently rebased against your version. Avoiding merges of post-review fixes will let us save a lot of time...
I will send all our patches once it's pushed. Thanks in advance.

Do note that this patch has been reworked than the version on GitHub. We now start the CPUs earlier in the boot process so they will be running when we wish to release them.

wma_semihalf.com edited edge metadata.

I did notice it's cleaned up (and it's got the annoying DO_AST printf changed to ktr). However, the places where I expect merge conflicts are the same. We had to change stack calculation, sequence in init_secondary, fix the KSTACK_PAGES variable (it does not correspond to the one set in kernconf here)... these are the one from the top of my head.
I'm good with this patch, please commit.

This revision is now accepted and ready to land.Jul 8 2015, 5:42 PM
This revision was automatically updated to reflect the committed changes.