x86/pvops: replace arch_enter_lazy_cpu_mode with arch_start_context_switch
Impact: simplification, prepare for later changes Make lazy cpu mode more specific to context switching, so that it makes sense to do more context-switch specific things in the callbacks. Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com> Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
This commit is contained in:
parent
b8bcfe997e
commit
7fd7d83d49
8 changed files with 20 additions and 37 deletions
|
@ -280,17 +280,18 @@ static inline void ptep_modify_prot_commit(struct mm_struct *mm,
|
|||
#endif
|
||||
|
||||
/*
|
||||
* A facility to provide batching of the reload of page tables with the
|
||||
* actual context switch code for paravirtualized guests. By convention,
|
||||
* only one of the lazy modes (CPU, MMU) should be active at any given
|
||||
* time, entry should never be nested, and entry and exits should always
|
||||
* be paired. This is for sanity of maintaining and reasoning about the
|
||||
* kernel code.
|
||||
* A facility to provide batching of the reload of page tables and
|
||||
* other process state with the actual context switch code for
|
||||
* paravirtualized guests. By convention, only one of the batched
|
||||
* update (lazy) modes (CPU, MMU) should be active at any given time,
|
||||
* entry should never be nested, and entry and exits should always be
|
||||
* paired. This is for sanity of maintaining and reasoning about the
|
||||
* kernel code. In this case, the exit (end of the context switch) is
|
||||
* in architecture-specific code, and so doesn't need a generic
|
||||
* definition.
|
||||
*/
|
||||
#ifndef __HAVE_ARCH_ENTER_LAZY_CPU_MODE
|
||||
#define arch_enter_lazy_cpu_mode() do {} while (0)
|
||||
#define arch_leave_lazy_cpu_mode() do {} while (0)
|
||||
#define arch_flush_lazy_cpu_mode() do {} while (0)
|
||||
#ifndef __HAVE_ARCH_START_CONTEXT_SWITCH
|
||||
#define arch_start_context_switch() do {} while (0)
|
||||
#endif
|
||||
|
||||
#ifndef __HAVE_PFNMAP_TRACKING
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue