Page MenuHomeFreeBSD

i386: Don't use static DPCPU and VNET defines in i386 modules
ClosedPublic

Authored by dchagin on Jul 26 2023, 10:44 AM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Nov 8, 10:01 AM
Unknown Object (File)
Oct 4 2024, 6:59 AM
Unknown Object (File)
Oct 1 2024, 4:50 AM
Unknown Object (File)
Sep 27 2024, 7:20 AM
Unknown Object (File)
Sep 20 2024, 1:50 AM
Unknown Object (File)
Sep 18 2024, 11:07 PM
Unknown Object (File)
Sep 9 2024, 12:19 AM
Unknown Object (File)
Sep 8 2024, 11:36 PM

Details

Summary

As of c84617e8 a similar to 4802a2cb and b6ea4c5a fix should be
applied to i386 too.

This should fix CI

Diff Detail

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

Event Timeline

dchagin added reviewers: emaste, jhb.

Hmm, does this mean vnet is now subtly broken on i386 as well now?

I mean more in the way that it's very broken on arm64 because VIMAGE/DPCPU depend on some rather dubious behavior in the kernel linker.

I think before -fPIC was added you'd end up with text relocations that would mean it could work, whereas after -fPIC was added it started to do the PC-relative thing, or something like that.

But the list of architectures that can't use static should be the list of architectures that use pre-linked kernel modules, i.e. everything except amd64, so at this point probably it should be flipped to say that.

I think before -fPIC was added you'd end up with text relocations that would mean it could work, whereas after -fPIC was added it started to do the PC-relative thing, or something like that.

I think so, that's why I mention -fPIC commit. Prior to -fPIC commit many modules was broken https://bugs.llvm.org/show_bug.cgi?id=51736

But the list of architectures that can't use static should be the list of architectures that use pre-linked kernel modules, i.e. everything except amd64, so at this point probably it should be flipped to say that.

I agree

This revision was not accepted when it landed; it landed in state Needs Review.Jul 28 2023, 8:56 AM
This revision was automatically updated to reflect the committed changes.