|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [mini-os master] x86: have .note.Xen segment contents before other .note.* ones
commit b6f79f5f44cf69044079c042b88fe9d75367642e
Author: Juergen Gross <jgross@xxxxxxxx>
AuthorDate: Mon Dec 1 10:14:47 2025 +0100
Commit: Jan Beulich <jbeulich@xxxxxxxx>
CommitDate: Mon Dec 1 10:14:47 2025 +0100
x86: have .note.Xen segment contents before other .note.* ones
Today the linker script of Mini-OS specifies to merge all .note*
sections into a single section .note:
.note : {
*(.note)
*(.note.*)
}
It seems as if ld will use the attributes of the first .note* segment
found during the linking process for the final .note segment.
Somewhere between binutils 2.43 and 2.45 something changed resulting in
.note.GNU-stack being the first .note* segment found. Unfortunately
this segment has unusual attributes: it has PROGBITS instead of NOTE as
type, resulting in the Xen ELF parsing to no longer look into it for
finding the Xen ELF-notes. This in turn will result in failure while
trying to parse the binary, which will let domain creation fail.
In order to avoid this issue, enhance the linker script to merge
.note.Xen before other .note.* segments, resulting in the final .note
segment to still have the NOTE type.
Fixes: 6d1cc81d049f ("x86: switch to use elfnote")
Signed-off-by: Juergen Gross <jgross@xxxxxxxx>
Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx>
---
arch/x86/minios-x86.lds.S | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch/x86/minios-x86.lds.S b/arch/x86/minios-x86.lds.S
index 8c6e0a6..6367b4b 100644
--- a/arch/x86/minios-x86.lds.S
+++ b/arch/x86/minios-x86.lds.S
@@ -33,6 +33,7 @@ SECTIONS
.note : {
*(.note)
+ *(.note.Xen)
*(.note.*)
}
--
generated by git-patchbot for /home/xen/git/mini-os.git#master
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |