From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com
Subject: [linux-next:master 9218/9273] drivers/platform/x86/asus-wmi.c:4427:27: sparse: sparse: unsigned value that used to be signed checked against zero?
Date: Fri, 27 Mar 2026 16:30:56 +0800 [thread overview]
Message-ID: <202603271607.FADIT5HL-lkp@intel.com> (raw)
::::::
:::::: Manual check reason: "low confidence static check warning: drivers/platform/x86/asus-wmi.c:4427:27: sparse: sparse: unsigned value that used to be signed checked against zero?"
::::::
BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
TO: "Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>
CC: Mark Brown <broonie@kernel.org>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: e77a5a5cfe43b4c25bd44a3818e487033287517f
commit: 5966013848d1661f1062965bb0d696bbca08daa0 [9218/9273] Merge branch 'for-next' of https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git
:::::: branch date: 16 hours ago
:::::: commit date: 2 days ago
config: i386-randconfig-062-20260327 (https://download.01.org/0day-ci/archive/20260327/202603271607.FADIT5HL-lkp@intel.com/config)
compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
sparse: v0.6.5-rc1
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260327/202603271607.FADIT5HL-lkp@intel.com/reproduce)
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
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/r/202603271607.FADIT5HL-lkp@intel.com/
sparse warnings: (new ones prefixed by >>)
drivers/platform/x86/asus-wmi.c:2792:33: sparse: sparse: incorrect type in argument 3 (different base types) @@ expected unsigned int [usertype] val @@ got restricted __le32 [usertype] @@
drivers/platform/x86/asus-wmi.c:2792:33: sparse: expected unsigned int [usertype] val
drivers/platform/x86/asus-wmi.c:2792:33: sparse: got restricted __le32 [usertype]
>> drivers/platform/x86/asus-wmi.c:4427:27: sparse: sparse: unsigned value that used to be signed checked against zero?
drivers/platform/x86/asus-wmi.c:4424:26: sparse: signed value source
vim +4427 drivers/platform/x86/asus-wmi.c
2c97d3e55b70ed Luke D. Jones 2023-08-30 4421
2c97d3e55b70ed Luke D. Jones 2023-08-30 4422 static int update_screenpad_bl_status(struct backlight_device *bd)
2c97d3e55b70ed Luke D. Jones 2023-08-30 4423 {
034f5efd362fb8 Denis Benato 2026-03-02 4424 u32 ctrl_param = bd->props.brightness;
034f5efd362fb8 Denis Benato 2026-03-02 4425 int err = 0;
2c97d3e55b70ed Luke D. Jones 2023-08-30 4426
034f5efd362fb8 Denis Benato 2026-03-02 @4427 if (ctrl_param >= 0 && bd->props.power) {
034f5efd362fb8 Denis Benato 2026-03-02 4428 err = asus_wmi_set_devstate(ASUS_WMI_DEVID_SCREENPAD_POWER, 1, NULL);
034f5efd362fb8 Denis Benato 2026-03-02 4429 if (err < 0)
034f5efd362fb8 Denis Benato 2026-03-02 4430 return err;
2c97d3e55b70ed Luke D. Jones 2023-08-30 4431
2c97d3e55b70ed Luke D. Jones 2023-08-30 4432 err = asus_wmi_set_devstate(ASUS_WMI_DEVID_SCREENPAD_LIGHT, ctrl_param, NULL);
034f5efd362fb8 Denis Benato 2026-03-02 4433 if (err < 0)
034f5efd362fb8 Denis Benato 2026-03-02 4434 return err;
2c97d3e55b70ed Luke D. Jones 2023-08-30 4435 }
2c97d3e55b70ed Luke D. Jones 2023-08-30 4436
034f5efd362fb8 Denis Benato 2026-03-02 4437 if (!bd->props.power) {
034f5efd362fb8 Denis Benato 2026-03-02 4438 err = asus_wmi_set_devstate(ASUS_WMI_DEVID_SCREENPAD_POWER, 0, NULL);
034f5efd362fb8 Denis Benato 2026-03-02 4439 if (err < 0)
034f5efd362fb8 Denis Benato 2026-03-02 4440 return err;
034f5efd362fb8 Denis Benato 2026-03-02 4441 }
2c97d3e55b70ed Luke D. Jones 2023-08-30 4442
2c97d3e55b70ed Luke D. Jones 2023-08-30 4443 return err;
2c97d3e55b70ed Luke D. Jones 2023-08-30 4444 }
2c97d3e55b70ed Luke D. Jones 2023-08-30 4445
:::::: The code at line 4427 was first introduced by commit
:::::: 034f5efd362fb87a3970d61eaf982664f84e6c5a platform/x86: asus-wmi: adjust screenpad power/brightness handling
:::::: TO: Denis Benato <denis.benato@linux.dev>
:::::: CC: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2026-03-27 8:31 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=202603271607.FADIT5HL-lkp@intel.com \
--to=lkp@intel.com \
--cc=oe-kbuild@lists.linux.dev \
/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