Re: [RFC 1/3] hugetlbfs: add reserved mount fields to subpool structure

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 27 Feb 2015 14:58:10 -0800 Mike Kravetz <mike.kravetz@xxxxxxxxxx> wrote:

> Add a boolean to the subpool structure to indicate that the pages for
> subpool have been reserved.  The hstate pointer in the subpool is
> convienient to have when it comes time to unreserve the pages.
> subool_reserved() is a handy way to check if reserved and take into
> account a NULL subpool.
> 
> ...
>
> @@ -38,6 +40,10 @@ extern int hugetlb_max_hstate __read_mostly;
>  #define for_each_hstate(h) \
>  	for ((h) = hstates; (h) < &hstates[hugetlb_max_hstate]; (h)++)
>  
> +static inline bool subpool_reserved(struct hugepage_subpool *spool)
> +{
> +	return spool && spool->reserved;
> +}

"subpool_reserved" is not a good identifier.

>  struct hugepage_subpool *hugepage_new_subpool(long nr_blocks);
>  void hugepage_put_subpool(struct hugepage_subpool *spool);

See what they did?


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




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]