All of lore.kernel.org
 help / color / mirror / Atom feed
From: linuxtestproject.agent@gmail.com
To: Piotr Kubaj <piotr.kubaj@intel.com>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] rfim: add new test for verifying RFIM sysfs interface
Date: Thu, 18 Jun 2026 16:40:32 +0000	[thread overview]
Message-ID: <20260618164032.4133-1-linuxtestproject.agent@gmail.com> (raw)
In-Reply-To: <20260618131203.87824-2-piotr.kubaj@intel.com>

Hi Piotr,

On Thu, 18 Jun 2026, Piotr Kubaj wrote:
> rfim: add new test for verifying RFIM sysfs interface

> +#define RFIM_ROOT "/sys/bus/pci/devices/0000:00:04.0"

The PCI BDF is hardcoded here. The proc_thermal driver matches by
PCI device ID (PCI_DEVICE_ID_INTEL_*_THERMAL), not by slot. While
00:04.0 is the typical BDF on current Intel client SoCs, could this
be discovered dynamically instead -- e.g. by scanning
/sys/bus/pci/devices/*/driver for a proc_thermal link, or by looking
up the device via its class or vendor:device pair?

This would prevent a silent TCONF on any future platform where the
thermal device appears at a different BDF.

> +static void check_read_only(const char *path)
> +{
> +	int fd = TST_EXP_FD(open(path, O_RDONLY));
> +
> +	if (fd >= 0)
> +		SAFE_CLOSE(fd);

LTP convention is to use "fd != -1" rather than "fd >= 0" for fd
validity checks. Same applies in check_read_write().

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-06-18 16:41 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-18 13:12 [LTP] [PATCH v2] rfim: add new test for verifying RFIM sysfs interface Piotr Kubaj
2026-06-18 16:40 ` linuxtestproject.agent [this message]
  -- strict thread matches above, loose matches on Subject: below --
2026-06-16 11:42 [LTP] [PATCH] " Piotr Kubaj
2026-06-16 14:28 ` [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=20260618164032.4133-1-linuxtestproject.agent@gmail.com \
    --to=linuxtestproject.agent@gmail.com \
    --cc=ltp@lists.linux.it \
    --cc=piotr.kubaj@intel.com \
    /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.