[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <a45e4183-3ac3-2853-810a-63c7277d6318@huawei.com>
Date: Sat, 25 Nov 2023 19:53:13 +0800
From: Yunsheng Lin <linyunsheng@...wei.com>
To: Liang Chen <liangchen.linux@...il.com>, <davem@...emloft.net>,
<edumazet@...gle.com>, <kuba@...nel.org>, <pabeni@...hat.com>,
<hawk@...nel.org>, <ilias.apalodimas@...aro.org>
CC: <netdev@...r.kernel.org>, <linux-mm@...ck.org>
Subject: Re: [PATCH net-next v3 1/3] page_pool: Rename pp_frag_count to
pp_ref_count
On 2023/11/24 15:34, Liang Chen wrote:
> static inline void page_pool_fragment_page(struct page *page, long nr)
It seems page_pool_fragment_page() might not be a appropriate name too?
Perhaps it might be better to grep defrag/frag to see if there is other
function name might need changing.
> {
> - atomic_long_set(&page->pp_frag_count, nr);
> + atomic_long_set(&page->pp_ref_count, nr);
> }
>
> -static inline long page_pool_defrag_page(struct page *page, long nr)
> +static inline long page_pool_deref_page(struct page *page, long nr)
page_pool_defrag_page() related function is called by mlx5 driver directly,
we need to change it to use the new function too.
I assume that deref is short for dereference? According to:
https://stackoverflow.com/questions/4955198/what-does-dereferencing-a-pointer-mean-in-c-c
'dereferencing means accessing the value from a certain memory location
against which that pointer is pointing'.
So I am not sure if 'deref' is the right word here as I am not a native
english speaker, But it seems 'unref' is more appropriate here if we mirror
the napi_frag_unref() function name?
Powered by blists - more mailing lists