[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen stable-4.10] x86: introduce ELFNOTE macro



commit 887c705600114c502cd3b529659af085680f526a
Author:     Wei Liu <wei.liu2@xxxxxxxxxx>
AuthorDate: Fri Nov 10 12:36:49 2017 +0000
Commit:     Roger Pau Monne <roger.pau@xxxxxxxxxx>
CommitDate: Thu Jan 11 17:51:18 2018 +0000

    x86: introduce ELFNOTE macro
    
    It is needed later for introducing PVH entry point.
    
    Signed-off-by: Wei Liu <wei.liu2@xxxxxxxxxx>
    ---
    v2:
    1. Specify section attribute and type.
    2. Use p2align.
    3. Align instructions.
    4. Haven't used .L or turned it into assembly macro.
---
 xen/include/asm-x86/asm_defns.h | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/xen/include/asm-x86/asm_defns.h b/xen/include/asm-x86/asm_defns.h
index 388fc93b9d..35a5d9ee03 100644
--- a/xen/include/asm-x86/asm_defns.h
+++ b/xen/include/asm-x86/asm_defns.h
@@ -409,4 +409,16 @@ static always_inline void stac(void)
 #define REX64_PREFIX "rex64/"
 #endif
 
+#define ELFNOTE(name, type, desc)           \
+    .pushsection .note.name, "a", @note   ; \
+    .p2align 2                            ; \
+    .long 2f - 1f       /* namesz */      ; \
+    .long 4f - 3f       /* descsz */      ; \
+    .long type          /* type   */      ; \
+1:  .asciz #name        /* name   */      ; \
+2:  .p2align 2                            ; \
+3:  desc                /* desc   */      ; \
+4:  .p2align 2                            ; \
+    .popsection
+
 #endif /* __X86_ASM_DEFNS_H__ */
--
generated by git-patchbot for /home/xen/git/xen.git#stable-4.10

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.