lib/systems: strip kernel to avoid reference cycles#228018
lib/systems: strip kernel to avoid reference cycles#2280181 commit merged intomasterfrom unknown repository
Conversation
|
It turns out that I can't actually get the PowerPC zImage to boot with kexec. Sorry for the half-baked suggestion... Unfortunately, for reasons that I don't understand, doing the same stripping on Stupid workaround: the linux kernel build produces a |
|
Further testing: setting |
MIPS kernels are actually fully ELF-compliant images, so a lot of stuff is easier there. |
|
I'm running test builds of this now... |
I know that, stylistically, you were trying to avoid doing things this way, but no other solutions for the breakage caused by #221707 have arisen. I can't get anything else to work and I have run out of time. |
|
(Originally posted here by mistake.) I've done some investigation of my own. Here are the results: PowerPCPowerPC ends up with two sets of references. One is from kexec purgatory, and is probably an oversight. I expect I could upstream a patch to fix this, like I recently did for x86 and RISC-V1. The other is from the VDSO. Unlike every other architecture, PowerPC deliberately uses a non-stripped vdso, apparently because it made perf traces nicer. So unless things I've changed there (I'll try to have a look — it seems a bit strange that PowerPC would be special here), we won't be able to get the kernel build system to give us a reference-free PowerPC image. So even though I don't like it, ack to stripping manually on PowerPC. MIPSMIPS offers vmlinux, vmlinuz, and uImage. vmlinuz and uImage should both be reference-free, but I don't know enough about how MIPS boots to know whether either of those would be sensible default targets. I'd appreciate your insight here. If it's not feasible to change to either of those images, then we probably have to strip manually on MIPS too. Footnotes
|
So I tried
@alyssais would you please update your review to reflect this? It still shows the big-red-changes-requested-of-doom. |
|
@ofborg eval |
|
Rebased. |
@alyssais said "If it's not feasible to change to either of those images, then we probably have to strip manually on MIPS too." and that is the case #228018 (comment)
|
I have moved the powerpc fix into |
|
Rebased. It seems that ofborg-eval is on vacation today. |
Description of changes
lib/systems: strip kernel to avoid reference cycles
Since #221707 we must ensure that the image resulting from a kernel build is stripped. If we do not do this, there will be circular dependencies among its outpaths.
This commit fixes the breakage on mips.
Closes #244438
Things done
sandbox = trueset innix.conf? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/)