lkml.org 
[lkml]   [2023]   [Dec]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/1] mm: add swapiness= arg to memory.reclaim
On Wed, Dec 06, 2023 at 08:28:56AM -0800, Dan Schatzberg <schatzberg.dan@gmail.com> wrote:
> @@ -6902,12 +6913,33 @@ static ssize_t memory_reclaim(struct kernfs_open_file *of, char *buf,
...
> + int swappiness = -1;

Here you use a negative number...

> @@ -136,6 +136,9 @@ struct scan_control {
...
> + /* Swappiness value for reclaim, if NULL use memcg/global value */
> + int *swappiness;

... and here a NULL to denote the unset value.

I'd suggest unifying those. Perhaps the negative to avoid unnecessary dereferences.

Thanks,
Michal
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2023-12-07 20:00    [W:1.910 / U:0.084 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site