All of lore.kernel.org
 help / color / mirror / Atom feed
From: linuxtestproject.agent@gmail.com
To: Shaojie Sun <sunshaojie@kylinos.cn>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] tst_cgroup: add cpu.stat and cpu.weight to cgroup file table
Date: Thu, 30 Jul 2026 14:06:40 +0000	[thread overview]
Message-ID: <20260730140640.4098-1-linuxtestproject.agent@gmail.com> (raw)
In-Reply-To: <20260730122521.1218460-2-sunshaojie@kylinos.cn>

Hi Shaojie,

On Thu, 30 Jul 2026, Shaojie Sun wrote:
> tst_cgroup: add cpu.stat and cpu.weight to cgroup file table

--- [PATCH 2/3] ---

> +static void cleanup(void)
> +{
> +	if (cg_test) {
> +		cg_test = tst_cg_group_rm(cg_test);
> +	}
> +}

The braces around the single statement here (and the equivalent cleanup()
in cgroup_cpu03.c) trip checkpatch: "braces {} are not necessary for
single statement blocks". This is also inconsistent with cgroup_cpu01/04/05
which omit them. Could the braces be dropped?

> +	long usage_seconds = 2;
> +	long expected_usage_usec = usage_seconds * USEC_PER_SEC;
> +	cg_test = tst_cg_group_mk(tst_cg, "cpucg_test");

checkpatch reports "Missing a blank line after declarations" here (and at
the analogous spot in cgroup_cpu03.c). Should a blank line separate the
declarations from the first statement?

Verdict - Needs revision

---
Note:

The agent can sometimes produce false positives although often its
findings are genuine. If you find issues with the review, please
comment this email or ignore the suggestions.

Regards,
LTP AI Reviewer

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

  reply	other threads:[~2026-07-30 14:07 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-30 12:25 [LTP] [PATCH v2 0/3] Add CPU cgroup v2 tests ported from kselftest Shaojie Sun
2026-07-30 12:25 ` [LTP] [PATCH v2 1/3] tst_cgroup: add cpu.stat and cpu.weight to cgroup file table Shaojie Sun
2026-07-30 14:06   ` linuxtestproject.agent [this message]
2026-07-31  3:13   ` [LTP] [PATCH v3 0/3] Add CPU cgroup v2 tests ported from kselftest Shaojie Sun
2026-07-31  3:13     ` [LTP] [PATCH v3 1/3] tst_cgroup: add cpu.stat and cpu.weight to cgroup file table Shaojie Sun
2026-07-31  3:13     ` [LTP] [PATCH v3 2/3] cgroup: add CPU cgroup v2 tests ported from kselftest Shaojie Sun
2026-07-31  3:13     ` [LTP] [PATCH v3 3/3] runtest/controllers: add CPU cgroup v2 test entries Shaojie Sun
2026-07-30 12:25 ` [LTP] [PATCH v2 2/3] cgroup: add CPU cgroup v2 tests ported from kselftest Shaojie Sun
2026-07-30 12:25 ` [LTP] [PATCH v2 3/3] runtest/controllers: add CPU cgroup v2 test entries Shaojie Sun
  -- strict thread matches above, loose matches on Subject: below --
2026-07-30  3:28 [LTP] [PATCH 1/3] tst_cgroup: add cpu.stat and cpu.weight to cgroup file table Shaojie Sun
2026-07-30  7:04 ` [LTP] " linuxtestproject.agent

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=20260730140640.4098-1-linuxtestproject.agent@gmail.com \
    --to=linuxtestproject.agent@gmail.com \
    --cc=ltp@lists.linux.it \
    --cc=sunshaojie@kylinos.cn \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.