From 4c848c34d2efe2be1778423b797faf2562f77e4d Mon Sep 17 00:00:00 2001 From: WangYuli Date: Wed, 28 Aug 2024 11:07:37 +0800 Subject: [PATCH] KABI: Init reservation for x86 arch Init reservation for x86 arch Link: https://github.com/deepin-community/kernel/pull/59 Signed-off-by: Lugang He Signed-off-by: WangYuli --- arch/x86/include/asm/paravirt_types.h | 12 ++++++++++++ arch/x86/include/asm/thread_info.h | 3 +++ 2 files changed, 15 insertions(+) diff --git a/arch/x86/include/asm/paravirt_types.h b/arch/x86/include/asm/paravirt_types.h index 772d03487520e..53540938152c8 100644 --- a/arch/x86/include/asm/paravirt_types.h +++ b/arch/x86/include/asm/paravirt_types.h @@ -19,6 +19,8 @@ struct paravirt_patch_site { #include #include +#include + struct page; struct thread_struct; struct desc_ptr; @@ -133,6 +135,9 @@ struct pv_irq_ops { void (*safe_halt)(void); void (*halt)(void); + + DEEPIN_KABI_RESERVE(1) + DEEPIN_KABI_RESERVE(2) #endif } __no_randomize_layout; @@ -217,6 +222,11 @@ struct pv_mmu_ops { an mfn. We can tell which is which from the index. */ void (*set_fixmap)(unsigned /* enum fixed_addresses */ idx, phys_addr_t phys, pgprot_t flags); + + DEEPIN_KABI_RESERVE(1) + DEEPIN_KABI_RESERVE(2) + DEEPIN_KABI_RESERVE(3) + DEEPIN_KABI_RESERVE(4) #endif } __no_randomize_layout; @@ -235,6 +245,8 @@ struct pv_lock_ops { void (*kick)(int cpu); struct paravirt_callee_save vcpu_is_preempted; + + DEEPIN_KABI_RESERVE(1) } __no_randomize_layout; /* This contains all the paravirt structures: we get a convenient diff --git a/arch/x86/include/asm/thread_info.h b/arch/x86/include/asm/thread_info.h index d63b02940747f..05a891a394bb7 100644 --- a/arch/x86/include/asm/thread_info.h +++ b/arch/x86/include/asm/thread_info.h @@ -9,6 +9,7 @@ #define _ASM_X86_THREAD_INFO_H #include +#include #include #include #include @@ -60,6 +61,8 @@ struct thread_info { #ifdef CONFIG_SMP u32 cpu; /* current CPU */ #endif + DEEPIN_KABI_RESERVE(1) + DEEPIN_KABI_RESERVE(2) }; #define INIT_THREAD_INFO(tsk) \