From: kernel test robot <lkp@intel.com>
To: Perry Yuan <perry.yuan@amd.com>
Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org,
Alex Deucher <alexander.deucher@amd.com>,
Yifan Zhang <yifan1.zhang@amd.com>
Subject: drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c:1394:32-44: opportunity for str_enabled_disabled(ptl -> enabled)
Date: Thu, 13 Aug 2026 13:39:50 +0800 [thread overview]
Message-ID: <202608131327.v2Vfrqry-lkp@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: f5bbbfec59b4e2fb7520a91de3df8a6174325d6a
commit: d51a0439358d4eacd8beb39df619998d8340d232 drm/amdgpu: add sysfs for Peak Tops Limiter (PTL)
date: 3 months ago
config: s390-randconfig-r062-20260812 (https://download.01.org/0day-ci/archive/20260813/202608131327.v2Vfrqry-lkp@intel.com/config)
compiler: clang version 24.0.0git (https://github.com/llvm/llvm-project 12df34b8469b8095359de8c249cb1b2753fadeea)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Fixes: d51a0439358d ("drm/amdgpu: add sysfs for Peak Tops Limiter (PTL)")
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202608131327.v2Vfrqry-lkp@intel.com/
cocci warnings: (new ones prefixed by >>)
>> drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c:1394:32-44: opportunity for str_enabled_disabled(ptl -> enabled)
vim +1394 drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c
1387
1388 static ssize_t ptl_enable_show(struct device *dev, struct device_attribute *attr, char *buf)
1389 {
1390 struct drm_device *ddev = dev_get_drvdata(dev);
1391 struct amdgpu_device *adev = drm_to_adev(ddev);
1392 struct amdgpu_ptl *ptl = &adev->psp.ptl;
1393
> 1394 return sysfs_emit(buf, "%s\n", ptl->enabled ? "enabled" : "disabled");
1395 }
1396
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2026-08-13 5:40 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=202608131327.v2Vfrqry-lkp@intel.com \
--to=lkp@intel.com \
--cc=alexander.deucher@amd.com \
--cc=linux-kernel@vger.kernel.org \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=perry.yuan@amd.com \
--cc=yifan1.zhang@amd.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®