lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAKEwX=MmiswiBwEjS_7S9++JjRb0pbD0kcvY_UhrU4zN0tTiVQ@mail.gmail.com>
Date:   Wed, 7 Dec 2022 09:28:29 -0800
From:   Nhat Pham <nphamcs@...il.com>
To:     Matthew Wilcox <willy@...radead.org>
Cc:     akpm@...ux-foundation.org, hannes@...xchg.org, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org, bfoster@...hat.com,
        kernel-team@...a.com
Subject: Re: [PATCH v2 2/4] workingset: refactor LRU refault to expose refault
 recency check

On Tue, Dec 6, 2022 at 7:22 AM Matthew Wilcox <willy@...radead.org> wrote:
>
> On Mon, Dec 05, 2022 at 09:51:38AM -0800, Nhat Pham wrote:
> > +static bool lru_gen_test_recent(void *shadow, bool file, int *memcgid,
> > +     struct pglist_data **pgdat, unsigned long *token, bool *workingset)
>
> This line needs more than one tab indent.  I tend to use two tabs,
> others try to line up the parameters with the opening '('.  But
> one tab is too visually similar to the body of the function.
>
> >       rcu_read_lock();
> >
> >       memcg = folio_memcg_rcu(folio);
> > +
> > +     if (!lru_gen_test_recent(shadow, type, &memcg_id, &pgdat, &token,
> > +             &workingset))
>
> Similarly here.  &workingset looks like it's part of the body of the if,
> not part of the function call.
>
> > +             goto unlock;
> > +
> >       if (memcg_id != mem_cgroup_id(memcg))
> >               goto unlock;
> >

That's fair - I'll add another tab to each of these lines! Let me
know if you have any other concerns.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ