Page MenuHomeFreeBSD

arm64: don't loop forever if first option in kern.cfg.order not available
ClosedPublic

Authored by imp on Sep 23 2022, 8:54 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Nov 15, 5:47 AM
Unknown Object (File)
Oct 10 2024, 7:25 AM
Unknown Object (File)
Oct 10 2024, 7:25 AM
Unknown Object (File)
Oct 5 2024, 4:53 PM
Unknown Object (File)
Oct 4 2024, 10:57 AM
Unknown Object (File)
Oct 2 2024, 10:58 PM
Unknown Object (File)
Oct 2 2024, 8:17 PM
Unknown Object (File)
Oct 2 2024, 4:39 AM
Subscribers

Details

Summary

strchr returns a pointer to the ',', so if the first option in the list
isn't available, we need to step over the , to look at the next
option. So if kern.cfg.order="acpi,fdt" and we have no acpi, we'd loop
forever with order=',fdt'.

Sponsored by: Netflix

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

imp requested review of this revision.Sep 23 2022, 8:54 PM
This revision is now accepted and ready to land.Sep 23 2022, 8:58 PM
jhb added a subscriber: jhb.

typo in the title: s/forver/forever/

Not sure if you want to quote the comma in the second line, or maybe just spell it out (e.g. "we need to step over the comma")

imp retitled this revision from arm64: don't loop forver if first option in kern.cfg.order not available to arm64: don't loop forever if first option in kern.cfg.order not available.Sep 23 2022, 9:03 PM
In D36682#832825, @jhb wrote:

Not sure if you want to quote the comma in the second line, or maybe just spell it out (e.g. "we need to step over the comma")

Will add before push. Thanks!

Ah yes I remember this issue