Skip to content

pagemap: make useable for non-privilege users

Konstantin Khlebnikov linux-api linux-mm lkml 2 versions – In review

Get series with b4
b4 am 20150714152516.29844.69929.stgit@buzz

Versions newest first · linked by author and title

  1. v4 Latest5 patches 16 repliesIn review
  2. v1 RFC0 of 3 patches 3 repliesSuperseded

Changes in v4 from the cover letter

* patches reordered: cleanup now in second patch
* update pagemap for hugetlb, add missing 'FILE' bit
* fix PM_PFRAME_BITS: its 55 not 54 as was in previous versions

Patches in v4 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5pagemap: check permissions and capabilities at open timefs/proc/task_mmu.c+28 -202 replies
2/5pagemap: switch to the new format and do some cleanupfs/proc/task_mmu.c tools/vm/page-types.c+61 -1141 reply
3/5pagemap: rework hugetlb and thp reportfs/proc/task_mmu.c+44 -565 replies
4/5pagemap: hide physical addresses from non-privileged usersfs/proc/task_mmu.c+14 -113 replies
5/5pagemap: add mmap-exclusive bit for marking pages mapped only hereDocumentation/vm/pagemap.txt fs/proc/task_mmu.c tools/vm/page-types.c+25 -22 replies

Reviews trailers per patch

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

PatchMark WilliamsonNaoya Horiguchi
1/5R-b R-b
2/5R-b
3/5R-b R-b
4/5R-b
5/5Requested-by R-b R-b

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

Read the v4 thread

Cover letter [PATCHSET v4 0/5] pagemap: make useable for non-privilege users

This patchset makes pagemap useable again in the safe way (after row hammer bug it was made CAP_SYS_ADMIN-only). This patchset restores access for non-privileged users but hides PFNs from them.

Also it adds bit 'map-exlusive' which is set if page is mapped only here:
it helps in estimation of working set without exposing pfns and allows to distinguish CoWed and non-CoWed private anonymous pages.

Second patch removes page-shift bits and completes migration to the new pagemap format: flags soft-dirty and mmap-exlusive are available only in the new format.

Changes since v3:
* patches reordered: cleanup now in second patch
* update pagemap for hugetlb, add missing 'FILE' bit
* fix PM_PFRAME_BITS: its 55 not 54 as was in previous versions

---

Konstantin Khlebnikov (5):
pagemap: check permissions and capabilities at open time
pagemap: switch to the new format and do some cleanup
pagemap: rework hugetlb and thp report
pagemap: hide physical addresses from non-privileged users
pagemap: add mmap-exclusive bit for marking pages mapped only here

 Documentation/vm/pagemap.txt |    3 
 fs/proc/task_mmu.c           |  267 ++++++++++++++++++------------------------
 tools/vm/page-types.c        |   35 +++---
 3 files changed, 137 insertions(+), 168 deletions(-)

--
Konstantin

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>