]> www.infradead.org Git - users/jedix/linux-maple.git/commit
mm/hugetlb: compute/return the number of regions added by region_add()
authorMike Kravetz <mike.kravetz@oracle.com>
Wed, 24 Jun 2015 23:57:55 +0000 (16:57 -0700)
committerSantosh Shilimkar <santosh.shilimkar@oracle.com>
Thu, 27 Aug 2015 23:02:53 +0000 (16:02 -0700)
commit27f685c57873876bf80f8212ae39b114b72dacf2
tree212d259d6952c6015e6f2ebb4fb6acd6317c9cfb
parentbdd77865eddae837ddbf410b4a86bd2dbeb3fc10
mm/hugetlb: compute/return the number of regions added by region_add()

Orabug: 21652814

Modify region_add() to keep track of regions(pages) added to the reserve
map and return this value.  The return value can be compared to the return
value of region_chg() to determine if the map was modified between calls.

Make vma_commit_reservation() also pass along the return value of
region_add().  In the normal case, we want vma_commit_reservation to
return the same value as the preceding call to vma_needs_reservation.
Create a common __vma_reservation_common routine to help keep the special
case return values in sync

Signed-off-by: Mike Kravetz <mike.kravetz@oracle.com>
Cc: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com>
Cc: Davidlohr Bueso <dave@stgolabs.net>
Cc: David Rientjes <rientjes@google.com>
Cc: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
(cherry picked from commit cf3ad20bfeadda693e408d85684790714fc29b08)
Signed-off-by: Mike Kravetz <mike.kravetz@oracle.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@oracle.com>
mm/hugetlb.c