Re: [External] Re: [PATCH] mm: zswap: fix the lack of page lru flag in zswap_writeback_entry

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

 



On Wed, Jan 17, 2024 at 5:04 AM Matthew Wilcox <willy@xxxxxxxxxxxxx> wrote:
>
> On Tue, Jan 16, 2024 at 09:40:05PM +0800, Zhongkun He wrote:
> > 2)  __read_swap_cache_async has six parameters, so there is no space to
> > add a new one, add_to_lru_head.
>
> That's easy enough.  Define a new set of flags, make one of them the
> equivalent of skip_if_exists.  Something like:
>
> typedef unsigned int __bitwise read_swap_t;
>
> #define READ_SWAP_SKIP_EXISTING ((__force read_swap_t)0x00000001)
> #define READ_SWAP_ADD_TAIL      ((__force read_swap_t)0x00000002)
>
> There's only six callers of __read_swap_cache_async() to convert, so not
> really a big deal.
>

Yes, thanks for your suggestion.
The major problem is not the parameters, but the need to add three functions
to deal with a special case.  Thanks again.





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

  Powered by Linux