Skip to content

x86: unify vmlinux.lds

Sam Ravnborg lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest13 patches 28 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/13x86: beautify vmlinux_32.lds.Sarch/x86/kernel/vmlinux_32.lds.S+200 -1761 reply
2/13x86, vmlinux.lds: unify header/footerarch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S arch/x86/kernel/vmlinux_64.lds.S+72 -797 replies
3/13x86, vmlinux.lds: unify PHDRSarch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S arch/x86/kernel/vmlinux_64.lds.S+13 -161 reply
4/13x86, vmlinux.lds: unify start/end of SECTIONSarch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S arch/x86/kernel/vmlinux_64.lds.S+14 -181 reply
5/13x86, vmlinux.lds: unify .text output sectionsarch/x86/kernel/head_32.S arch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S +1 more+31 -511 reply
6/13x86, vmlinux.lds: unify exceptiontablearch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S arch/x86/kernel/vmlinux_64.lds.S+10 -201 reply
7/13x86, vmlinux.lds: unify data output sectionsarch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S arch/x86/kernel/vmlinux_64.lds.S+55 -651 reply
8/13x86, vmlinux.lds: move vsyscall output sectionsarch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_64.lds.S+71 -681 reply
9/13x86, vmlinux.lds: unify first part of initdataarch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S arch/x86/kernel/vmlinux_64.lds.S+61 -1191 reply
10/13x86, vmlinux.lds: unify parainstructionsarch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S arch/x86/kernel/vmlinux_64.lds.S+18 -361 reply
11/13x86, vmlinux.lds: unify .exit.* and .init.ramfsarch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S arch/x86/kernel/vmlinux_64.lds.S+20 -421 reply
12/13x86, vmlinux.lds: unify percpuarch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S arch/x86/kernel/vmlinux_64.lds.S+30 -321 reply
13/13x86, vmlinux.lds: unify remaining partsarch/x86/kernel/vmlinux.lds.S arch/x86/kernel/vmlinux_32.lds.S arch/x86/kernel/vmlinux_64.lds.S+27 -551 reply

Reviews trailers per patch

1 of 13 patches has a Reviewed-by or Acked-by.

PatchSam Ravnborg
1/13
2/13A-b
3/13
4/13
5/13
6/13
7/13
8/13
9/13
10/13
11/13
12/13
13/13

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH/RFT 0/13] x86: unify vmlinux.lds

Following patchset is on top of the x86/kbuild branch of tip. It unifies vmlinux.lds so we end up with a single file.

The patchset has been build tested on 32bit and 64 bit but has not been boot tested. (Lacking time/resources atm).

The steps were made minimal to make it simpler to track regressions using bisect (if any) and to make review easier.

The unified vmlinux.lds shows some questionable differences between 32 bit and 64 bit.

o 64 bit uses PHDRS more extensively than 32 bit. Could they be the same?

o _stext does not cover all text for 32 bit - a bug? For 64b bit it does. It is only the .code16 wakeup stuff that is not covered but anyway.

o _edata covers much more on 32 bit

o The nosave stuff differs (but that is due to the PHDRS stuff anyway)

o Different alignmnet requirements in several spots

o All the stuff added to support relocable kernels

Please test/review.

This patchset will conflict with Tim's work but the conflicts should be simple to fix. Lets tackle that later.

Sam

 arch/x86/kernel/head_32.S        |    7 -
 arch/x86/kernel/vmlinux.lds.S    |  421 +++++++++++++++++++++++++++++++++++++-
 arch/x86/kernel/vmlinux_32.lds.S |  229 ---------------------
 arch/x86/kernel/vmlinux_64.lds.S |  336 ------------------------------
 4 files changed, 419 insertions(+), 574 deletions(-)

Sam Ravnborg (13):
x86: beautify vmlinux_32.lds.S
x86, vmlinux.lds: unify header/footer x86, vmlinux.lds: unify PHDRS
x86, vmlinux.lds: unify start/end of SECTIONS x86, vmlinux.lds: unify .text output sections x86, vmlinux.lds: unify exceptiontable x86, vmlinux.lds: unify data output sections x86, vmlinux.lds: move vsyscall output sections x86, vmlinux.lds: unify first part of initdata x86, vmlinux.lds: unify parainstructions x86, vmlinux.lds: unify .exit.* and .init.ramfs x86, vmlinux.lds: unify percpu
x86, vmlinux.lds: unify remaining parts