[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1432585785.2185.59.camel@stgolabs.net>
Date: Mon, 25 May 2015 13:29:45 -0700
From: Davidlohr Bueso <dave@...olabs.net>
To: Mike Kravetz <mike.kravetz@...cle.com>
Cc: linux-mm@...ck.org, linux-kernel@...r.kernel.org,
Naoya Horiguchi <n-horiguchi@...jp.nec.com>,
David Rientjes <rientjes@...gle.com>,
Luiz Capitulino <lcapitulino@...hat.com>,
Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: [PATCH v2 1/2] mm/hugetlb: compute/return the number of regions
added by region_add()
On Fri, 2015-05-22 at 20:55 -0700, Mike Kravetz wrote:
> + * The region data structures are embedded into a resv_map and protected
> + * by a resv_map's lock. The set of regions within the resv_map represent
> + * reservations for huge pages, or huge pages that have already been
> + * instantiated within the map. The from and to elements are huge page
> + * indicies into the associated mapping. from indicates the starting index
> + * of the region. to represents the first index past the end of the region.
newline
> + * For example, a file region structure with from == 0 and to == 4 represents
> + * four huge pages in a mapping. It is important to note that the to element
> + * represents the first element past the end of the region. This is used in
> + * arithmetic as 4(to) - 0(from) = 4 huge pages in the region.
> */
> struct file_region {
> struct list_head link;
> @@ -221,10 +229,23 @@ struct file_region {
> long to;
> };
>
> +/*
> + * Add the huge page range represented by indicies f (from)
> + * and t (to) to the reserve map. Existing regions will be
How about simply renaming those parameters to from and to across the
entire hugetlb code.
Thanks,
Davidlohr
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists