aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-x86
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-x86')
-rw-r--r--include/asm-x86/pgalloc_64.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/include/asm-x86/pgalloc_64.h b/include/asm-x86/pgalloc_64.h
index 315314ce4bfb..4f6220db22b1 100644
--- a/include/asm-x86/pgalloc_64.h
+++ b/include/asm-x86/pgalloc_64.h
@@ -42,19 +42,21 @@ static inline void pud_free(struct mm_struct *mm, pud_t *pud)
42static inline void pgd_list_add(pgd_t *pgd) 42static inline void pgd_list_add(pgd_t *pgd)
43{ 43{
44 struct page *page = virt_to_page(pgd); 44 struct page *page = virt_to_page(pgd);
45 unsigned long flags;
45 46
46 spin_lock(&pgd_lock); 47 spin_lock_irqsave(&pgd_lock, flags);
47 list_add(&page->lru, &pgd_list); 48 list_add(&page->lru, &pgd_list);
48 spin_unlock(&pgd_lock); 49 spin_unlock_irqrestore(&pgd_lock, flags);
49} 50}
50 51
51static inline void pgd_list_del(pgd_t *pgd) 52static inline void pgd_list_del(pgd_t *pgd)
52{ 53{
53 struct page *page = virt_to_page(pgd); 54 struct page *page = virt_to_page(pgd);
55 unsigned long flags;
54 56
55 spin_lock(&pgd_lock); 57 spin_lock_irqsave(&pgd_lock, flags);
56 list_del(&page->lru); 58 list_del(&page->lru);
57 spin_unlock(&pgd_lock); 59 spin_unlock_irqrestore(&pgd_lock, flags);
58} 60}
59 61
60static inline pgd_t *pgd_alloc(struct mm_struct *mm) 62static inline pgd_t *pgd_alloc(struct mm_struct *mm)