diff options
Diffstat (limited to 'arch/x86/mm/fault.c')
| -rw-r--r-- | arch/x86/mm/fault.c | 24 |
1 files changed, 1 insertions, 23 deletions
diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c index 4c4508e8a204..51f7ee71d6c7 100644 --- a/arch/x86/mm/fault.c +++ b/arch/x86/mm/fault.c | |||
| @@ -326,29 +326,7 @@ out: | |||
| 326 | 326 | ||
| 327 | void vmalloc_sync_all(void) | 327 | void vmalloc_sync_all(void) |
| 328 | { | 328 | { |
| 329 | unsigned long address; | 329 | sync_global_pgds(VMALLOC_START & PGDIR_MASK, VMALLOC_END); |
| 330 | |||
| 331 | for (address = VMALLOC_START & PGDIR_MASK; address <= VMALLOC_END; | ||
| 332 | address += PGDIR_SIZE) { | ||
| 333 | |||
| 334 | const pgd_t *pgd_ref = pgd_offset_k(address); | ||
| 335 | unsigned long flags; | ||
| 336 | struct page *page; | ||
| 337 | |||
| 338 | if (pgd_none(*pgd_ref)) | ||
| 339 | continue; | ||
| 340 | |||
| 341 | spin_lock_irqsave(&pgd_lock, flags); | ||
| 342 | list_for_each_entry(page, &pgd_list, lru) { | ||
| 343 | pgd_t *pgd; | ||
| 344 | pgd = (pgd_t *)page_address(page) + pgd_index(address); | ||
| 345 | if (pgd_none(*pgd)) | ||
| 346 | set_pgd(pgd, *pgd_ref); | ||
| 347 | else | ||
| 348 | BUG_ON(pgd_page_vaddr(*pgd) != pgd_page_vaddr(*pgd_ref)); | ||
| 349 | } | ||
| 350 | spin_unlock_irqrestore(&pgd_lock, flags); | ||
| 351 | } | ||
| 352 | } | 330 | } |
| 353 | 331 | ||
| 354 | /* | 332 | /* |
