lkml.org 
[lkml]   [2023]   [Jan]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH mm-unstable 1/8] mm/hugetlb: convert isolate_hugetlb to folios
On Tue, Jan 03, 2023 at 01:13:33PM -0600, Sidhartha Kumar wrote:
> +++ b/include/linux/mm.h
> @@ -775,6 +775,11 @@ static inline bool get_page_unless_zero(struct page *page)
> return page_ref_add_unless(page, 1, 0);
> }
>
> +static inline bool get_folio_unless_zero(struct folio *folio)
> +{
> + return folio_ref_add_unless(folio, 1, 0);
> +}
> +

I think that's folio_try_get() in linux/page_ref.h.

The rest looks good though.

\
 
 \ /
  Last update: 2023-03-26 23:26    [W:0.294 / U:0.420 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site