Skip to content

Sync unmappings in vmalloc/ioremap areas

Joerg Roedel linux-mm lkml 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest3 patches 3 repliesIn review
  2. v23 patches 14 repliesSuperseded
  3. v13 patches 4 repliesSuperseded

Changes in v3 from the cover letter

- Moved the vmalloc_sync_all() call to the lazy vmap purge function as requested by Andy Lutomirski

- Made sure that the code in vmalloc_sync_all() really iterates over all pgds (pointed out by Thomas Gleixner)

- Added a couple of comments

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3x86/mm: Check for pfn instead of page in vmalloc_sync_one()arch/x86/mm/fault.c+1 -10 replies
2/3x86/mm: Sync also unmappings in vmalloc_sync_all()arch/x86/mm/fault.c+5 -80 replies
3/3mm/vmalloc: Sync unmappings in vunmap_page_range()mm/vmalloc.c+9 -03 replies

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchDave Hansen
1/3R-b
2/3R-b
3/3R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH 0/3 v3] Sync unmappings in vmalloc/ioremap areas

Hi,

here is a small patch-set to sync unmappings in the vmalloc/ioremap areas between page-tables in the system.

This is only needed x86-32 with !SHARED_KERNEL_PMD, which is the case on a PAE kernel with PTI enabled.

On affected systems the missing sync causes old mappings to persist in some page-tables, causing data corruption and other undefined behavior.

Please review.

Thanks,

Joerg

Changes v2 -> v3:

- Moved the vmalloc_sync_all() call to the lazy vmap purge function as requested by Andy Lutomirski

- Made sure that the code in vmalloc_sync_all() really iterates over all pgds (pointed out by Thomas Gleixner)

- Added a couple of comments

Changes v1 -> v2:

- Added correct Fixes-tags to all patches

Joerg Roedel (3):
x86/mm: Check for pfn instead of page in vmalloc_sync_one() x86/mm: Sync also unmappings in vmalloc_sync_all() mm/vmalloc: Sync unmappings in vunmap_page_range()

 arch/x86/mm/fault.c | 15 ++++++---------
 mm/vmalloc.c        |  9 +++++++++
 2 files changed, 15 insertions(+), 9 deletions(-)
Signature · 1 line
2.17.1