diff options
Diffstat (limited to 'arch/x86/include/asm/alternative.h')
-rw-r--r-- | arch/x86/include/asm/alternative.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/arch/x86/include/asm/alternative.h b/arch/x86/include/asm/alternative.h index bc6abb7bc7ee..bf535f947e8c 100644 --- a/arch/x86/include/asm/alternative.h +++ b/arch/x86/include/asm/alternative.h | |||
@@ -65,6 +65,7 @@ extern void alternatives_smp_module_add(struct module *mod, char *name, | |||
65 | extern void alternatives_smp_module_del(struct module *mod); | 65 | extern void alternatives_smp_module_del(struct module *mod); |
66 | extern void alternatives_smp_switch(int smp); | 66 | extern void alternatives_smp_switch(int smp); |
67 | extern int alternatives_text_reserved(void *start, void *end); | 67 | extern int alternatives_text_reserved(void *start, void *end); |
68 | extern bool skip_smp_alternatives; | ||
68 | #else | 69 | #else |
69 | static inline void alternatives_smp_module_add(struct module *mod, char *name, | 70 | static inline void alternatives_smp_module_add(struct module *mod, char *name, |
70 | void *locks, void *locks_end, | 71 | void *locks, void *locks_end, |
@@ -160,6 +161,8 @@ static inline void apply_paravirt(struct paravirt_patch_site *start, | |||
160 | #define __parainstructions_end NULL | 161 | #define __parainstructions_end NULL |
161 | #endif | 162 | #endif |
162 | 163 | ||
164 | extern void *text_poke_early(void *addr, const void *opcode, size_t len); | ||
165 | |||
163 | /* | 166 | /* |
164 | * Clear and restore the kernel write-protection flag on the local CPU. | 167 | * Clear and restore the kernel write-protection flag on the local CPU. |
165 | * Allows the kernel to edit read-only pages. | 168 | * Allows the kernel to edit read-only pages. |
@@ -177,7 +180,14 @@ static inline void apply_paravirt(struct paravirt_patch_site *start, | |||
177 | * On the local CPU you need to be protected again NMI or MCE handlers seeing an | 180 | * On the local CPU you need to be protected again NMI or MCE handlers seeing an |
178 | * inconsistent instruction while you patch. | 181 | * inconsistent instruction while you patch. |
179 | */ | 182 | */ |
183 | struct text_poke_param { | ||
184 | void *addr; | ||
185 | const void *opcode; | ||
186 | size_t len; | ||
187 | }; | ||
188 | |||
180 | extern void *text_poke(void *addr, const void *opcode, size_t len); | 189 | extern void *text_poke(void *addr, const void *opcode, size_t len); |
181 | extern void *text_poke_smp(void *addr, const void *opcode, size_t len); | 190 | extern void *text_poke_smp(void *addr, const void *opcode, size_t len); |
191 | extern void text_poke_smp_batch(struct text_poke_param *params, int n); | ||
182 | 192 | ||
183 | #endif /* _ASM_X86_ALTERNATIVE_H */ | 193 | #endif /* _ASM_X86_ALTERNATIVE_H */ |