Re: [PATCH RFC 3/4] mm/page_alloc_test: Add logic to isolate a node for testing

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

 



On Tue, 25 Feb 2025 at 12:20, Brendan Jackman <jackmanb@xxxxxxxxxx> wrote:
>
> On Mon, 24 Feb 2025 at 19:34, Yosry Ahmed <yosry.ahmed@xxxxxxxxx> wrote:
> > > +#ifdef CONFIG_KUNIT
> >
> > Why not CONFIG_PAGE_ALLOC_KUNIT_TEST?
>
> VISIBLE_IF_KUNIT is paired with #ifdef CONFIG_KUNIT elsewhere (I think
> there might even be docs that do this in an example) so I just
> followed the pattern.
>
> #ifdef CONFIG_KUNIT -> things are consistent and you just don't have
> to think about this very much.
>
> #ifdef CONFIG_PAGE_ALLOC_KUNIT_TEST -> better scoping.
>
> So yeah, shrug. Maybe David/Rae/Brendan has an opinion.

Oh, actually I rescind my shrug. If we used #ifdef
CONFIG_PAGE_ALLOC_KUNIT_TEST, then -Wmissing-prototypes would fire for
people running other KUnit tests.

So yeah the function needs to be non-static exactly when there's a
prototype in the header.




[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux