*
* Spinlocks used by the code in arch/x86/mm.
*
- * Copyright (c) 2011 Citrix Systems, inc.
+ * Copyright (c) 2011 Citrix Systems, inc.
* Copyright (c) 2007 Advanced Micro Devices (Wei Huang)
* Copyright (c) 2006-2007 XenSource Inc.
* Copyright (c) 2006 Michael A Fetterman
- *
+ *
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
l->unlock_level = 0;
}
-static inline int mm_locked_by_me(mm_lock_t *l)
+static inline int mm_locked_by_me(mm_lock_t *l)
{
return (l->lock.recurse_cpu == current->processor);
}
static inline void _mm_lock(mm_lock_t *l, const char *func, int level, int rec)
{
- if ( !((mm_locked_by_me(l)) && rec) )
+ if ( !((mm_locked_by_me(l)) && rec) )
__check_lock_level(level);
spin_lock_recursive(&l->lock);
if ( l->lock.recurse_cnt == 1 )
spin_unlock_recursive(&l->lock);
}
-static inline void mm_enforce_order_unlock(int unlock_level,
+static inline void mm_enforce_order_unlock(int unlock_level,
unsigned short *recurse_count)
{
if ( recurse_count )
#define gfn_locked_by_me(p,g) p2m_locked_by_me(p)
/* PoD lock (per-p2m-table)
- *
+ *
* Protects private PoD data structs: entry and cache
* counts, page lists, sweep parameters. */
/* Page alloc lock (per-domain)
*
- * This is an external lock, not represented by an mm_lock_t. However,
+ * This is an external lock, not represented by an mm_lock_t. However,
* pod code uses it in conjunction with the p2m lock, and expecting
* the ordering which we enforce here.
* The lock is not recursive. */
* For shadow pagetables, this lock protects
* - all changes to shadow page table pages
* - the shadow hash table
- * - the shadow page allocator
+ * - the shadow page allocator
* - all changes to guest page table pages
* - all changes to the page_info->tlbflush_timestamp
- * - the page_info->count fields on shadow pages
- *
- * For HAP, it protects the NPT/EPT tables and mode changes.
- *
+ * - the page_info->count fields on shadow pages
+ *
+ * For HAP, it protects the NPT/EPT tables and mode changes.
+ *
* It also protects the log-dirty bitmap from concurrent accesses (and
* teardowns, etc). */