Page MenuHomeFreeBSD

Add EFI RT support for arm64
ClosedPublic

Authored by andrew on Oct 5 2017, 11:52 AM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Apr 17, 3:36 AM
Unknown Object (File)
Wed, Apr 17, 1:43 AM
Unknown Object (File)
Wed, Apr 17, 1:37 AM
Unknown Object (File)
Tue, Apr 16, 3:17 PM
Unknown Object (File)
Feb 10 2024, 9:33 PM
Unknown Object (File)
Feb 2 2024, 10:45 PM
Unknown Object (File)
Jan 31 2024, 3:48 AM
Unknown Object (File)
Dec 23 2023, 12:59 AM
Subscribers

Details

Summary

Support the EFI Runtime Services on arm64. As with amd64 we use the 1:1
mapping. This uses the new common code shared with amd64.

The RTC should only be accessed via EFI. There is no locking around it as
the spec only has this as a requirement for the PC-AT CMOS device.

Test Plan

Tested on ThunderX with an EDK based UEFI. Will need testing with U-Boot.

Diff Detail

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

Event Timeline

This revision is now accepted and ready to land.Oct 5 2017, 1:17 PM
sys/arm64/include/fpu.h
1 ↗(On Diff #33716)

Need headers on this file. I'd recommend the public domain one because it's just a single #include.

sys/modules/Makefile
707–709 ↗(On Diff #33716)

This is super ugly. Any chance you can define _efirt twice: once in the amd64 section and once in the aarch64 section? And really, that should be MACHINE == arm64 (there are many mistakes like this in this file, some introduced by me).

  • Add a public domain comment to fpu.h
  • Move _efirt to an aarch64 specific section in modules/Makefile
This revision now requires review to proceed.Oct 8 2017, 1:55 PM

I didn't check that all the MMU stuff was right, but the rest looks good now. thanks for fixing.

sys/arm64/arm64/machdep.c
995 ↗(On Diff #33817)

I thought that there were extensions to efi to return FDT. Does it not make sense to grab it before we try to load dtb? Or is that detail handled in the boot loader?

This revision is now accepted and ready to land.Oct 8 2017, 2:41 PM
sys/arm64/arm64/machdep.c
995 ↗(On Diff #33817)

We grab the dtb in the boot loader, then copy it to be just after before the module data.

This revision was automatically updated to reflect the committed changes.