Linux Test Project
 help / color / mirror / Atom feed
From: Cyril Hrubis <chrubis@suse.cz>
To: ltp@lists.linux.it
Subject: Re: [LTP] [PATCH v1 30/31] testcases: sysfs: Add sys_swap01
Date: Wed, 19 Aug 2026 18:14:39 +0200	[thread overview]
Message-ID: <aoXWbzGpcVF3nf1Y@yuki.lan> (raw)
In-Reply-To: <aoUFrxZAKAGWMq7i@linux.dev>

Hi!
> > @@ -25,3 +25,4 @@ sys_block_size01 sys_block_size01
> >  sys_hugepages01 sys_hugepages01
> >  sys_hugepages02 sys_hugepages02
> >  sys_ksm01 sys_ksm01
> > +sys_swap01 sys_swap01
> 
> This should be sys_mm_swap01; otherwise, the runtest file cannot
> find the correct test to execute.

Fixed.

> > --- /dev/null
> > +++ b/testcases/kernel/sysfs/kernel/mm/swap/sys_mm_swap01.c
> > @@ -0,0 +1,32 @@
> > +// SPDX-License-Identifier: GPL-2.0-or-later
> > +/*
> > + * Copyright (c) 2026 Cyril Hrubis <chrubis@suse.cz>
> > + */
> > +
> > +/*\
> > + * Sanity check for /sys/kernel/mm/swap/vma_ra_enabled.
> > + *
> > + * Unlike most other boolean sysfs tunables which use 0/1, this one is
> > + * formatted as the strings "true" or "false", so it needs its own check
> > + * rather than TST_SYSFS_ASSERT_BOOL().
> > + *
> > + * The test skips with TCONF when the attribute is not present.
> > + */
> > +
> > +#include "tst_test.h"
> > +#include "tst_sysfs_assert.h"
> > +
> > +#define VMA_RA "/sys/kernel/mm/swap/vma_ra_enabled"
> 
> I suggest adding all of those path definitions to tst_path_defs.h
> and unifying the common macro names.

I didn't fix that one yet, since I wanted to send v2 today. If we agree
that we want that I will fix this in subsequent versions or before
applying.

> Also, we need to add the sysfs/ directory to testcases/kernel/Makefile
> so they can build successfully by default.
> 
> --- a/testcases/kernel/Makefile
> +++ b/testcases/kernel/Makefile
> @@ -36,6 +36,7 @@ SUBDIRS                       += connectors \
>                            sched \
>                            security \
>                            sound \
> +                          sysfs \
>                            thermal \
>                            tracing \
>                            uevents \
> 

Fixed.

-- 
Cyril Hrubis
chrubis@suse.cz

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

  reply	other threads:[~2026-08-19 16:15 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-18 14:12 [LTP] [PATCH v1 00/31] Add sysfs sanity tests Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 01/31] lib: Add tst_sysfs_assert Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 02/31] testcases: sysfs: Add sys_power01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 03/31] testcases: sysfs: Add sys_kernel01 Cyril Hrubis
2026-08-18 14:54   ` [LTP] lib: Add tst_sysfs_assert linuxtestproject.agent
2026-08-19 16:13     ` Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 04/31] testcases: sysfs: Add sys_clocksource01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 05/31] testcases: sysfs: Add sys_node01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 06/31] testcases: sysfs: Add sys_cpu_topology01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 07/31] testcases: sysfs: Add sys_cpu_topology02 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 08/31] testcases: sysfs: Add sys_cpu_vulnerabilities01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 09/31] testcases: sysfs: Add sys_cpu_smt01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 10/31] testcases: sysfs: Add sys_cpu_cache01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 11/31] testcases: sysfs: Add sys_clockevents01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 12/31] testcases: sysfs: Add sys_ata01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 13/31] testcases: sysfs: Add sys_bdi01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 14/31] testcases: sysfs: sys_hwmon01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 15/31] testcases: sysfs: sys_leds01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 16/31] testcases: sysfs: Add sys_wakeup01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 17/31] testcases: sysfs: Add sys_rtc01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 18/31] testcases: sysfs: Add sys_thermal01 Cyril Hrubis
2026-08-18 14:12 ` [LTP] [PATCH v1 19/31] tst_netdevice: Add two more helper macros Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 20/31] testcases: sysfs: Add sys_net01 Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 21/31] testcases: sysfs: Add sys_net02 Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 22/31] testcases: sysfs: Add sys_net03 Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 23/31] testcases: sysfs: Add sys_net04 Cyril Hrubis
2026-08-19  2:13   ` Li Wang
2026-08-19  2:27     ` Li Wang
2026-08-19 15:40     ` Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 24/31] testcases: sysfs: Add sys_block_loop01 Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 25/31] testcases: sysfs: Add sys_block_queue01 Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 26/31] testcases: sysfs: Add sys_block_size01 Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 27/31] testcases: sysfs: Add sys_hugepages01 Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 28/31] testcases: sysfs: Add sys_hugepages02 Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 29/31] testcases: sysfs: Add sys_ksm01 Cyril Hrubis
2026-08-18 14:13 ` [LTP] [PATCH v1 30/31] testcases: sysfs: Add sys_swap01 Cyril Hrubis
2026-08-19  1:23   ` Li Wang
2026-08-19 16:14     ` Cyril Hrubis [this message]
2026-08-18 14:13 ` [LTP] [PATCH v1 31/31] testcases: sysfs: Add sys_thp01 Cyril Hrubis
2026-08-19  7:46 ` [LTP] [PATCH v1 00/31] Add sysfs sanity tests Jan Stancek via ltp
2026-08-19  7:55   ` Cyril Hrubis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aoXWbzGpcVF3nf1Y@yuki.lan \
    --to=chrubis@suse.cz \
    --cc=ltp@lists.linux.it \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox