Page MenuHomeFreeBSD

kinst: skip trampoline searching for riscv and arm64
AbandonedPublic

Authored by christos on Jul 4 2023, 9:35 AM.
Tags
None
Referenced Files
F82999518: D40873.id124162.diff
Sun, May 5, 1:21 AM
Unknown Object (File)
Mon, Apr 29, 5:54 PM
Unknown Object (File)
Mon, Apr 29, 12:56 PM
Unknown Object (File)
Sat, Apr 27, 11:14 AM
Unknown Object (File)
Sat, Apr 27, 11:14 AM
Unknown Object (File)
Sat, Apr 27, 11:14 AM
Unknown Object (File)
Sat, Apr 27, 9:31 AM
Unknown Object (File)
Mar 14 2024, 10:43 AM
Subscribers

Details

Reviewers
markj
Summary

RISCV and ARM64 use PAGE_SIZE-long trampolines as a workaround to a QEMU
bug occuring when there are multiple trampolines live in the same page.
However, BITSET(9) doesn't seem to be working properly when the bitset
size is 1, so in this case we skip the bit searching completely.

This is most likely a temporary fix.

Diff Detail

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

Event Timeline

christos retitled this revision from kinst: skip trampoline searching for riscv to kinst: skip trampoline searching for riscv and arm64.Jul 4 2023, 10:47 AM
sys/cddl/dev/kinst/trampoline.c
140

We are not completely sure that it's a QEMU bug, so I would write "apparent QEMU bug". Also, did you try to reproduce the problem on amd64 in QEMU? The problem might be there too.

(I also don't understand why bitset(9) doesn't work properly in this case and would prefer to have an explanation for that.)