linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [rafael-pm:bleeding-edge 44/56] drivers/acpi/processor_idle.c:464:22: warning: unused variable 'i'
@ 2025-04-10  3:51 kernel test robot
  2025-04-10  7:56 ` Zhang, Rui
  0 siblings, 1 reply; 3+ messages in thread
From: kernel test robot @ 2025-04-10  3:51 UTC (permalink / raw)
  To: Zhang Rui; +Cc: oe-kbuild-all, linux-acpi, devel, linux-pm, Rafael J. Wysocki

Hi Zhang,

FYI, the error/warning was bisected to this commit, please ignore it if it's irrelevant.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git bleeding-edge
head:   655d33f14d6cebcf46e422bcb9d225d791bba42f
commit: 8ea9d119e7c666b6d87697af1b69193354c865d1 [44/56] ACPI: processor: idle: Remove redundant pr->power.count assignment
config: i386-buildonly-randconfig-003-20250409 (https://download.01.org/0day-ci/archive/20250410/202504101132.pgiDBR2Q-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-12) 11.3.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250410/202504101132.pgiDBR2Q-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/oe-kbuild-all/202504101132.pgiDBR2Q-lkp@intel.com/

All warnings (new ones prefixed by >>):

   drivers/acpi/processor_idle.c: In function 'acpi_processor_get_cstate_info':
>> drivers/acpi/processor_idle.c:464:22: warning: unused variable 'i' [-Wunused-variable]
     464 |         unsigned int i;
         |                      ^


vim +/i +464 drivers/acpi/processor_idle.c

^1da177e4c3f415 Linus Torvalds      2005-04-16  461  
a36a7fecfe60717 Sudeep Holla        2016-07-21  462  static int acpi_processor_get_cstate_info(struct acpi_processor *pr)
^1da177e4c3f415 Linus Torvalds      2005-04-16  463  {
^1da177e4c3f415 Linus Torvalds      2005-04-16 @464  	unsigned int i;
^1da177e4c3f415 Linus Torvalds      2005-04-16  465  	int result;
^1da177e4c3f415 Linus Torvalds      2005-04-16  466  
^1da177e4c3f415 Linus Torvalds      2005-04-16  467  
^1da177e4c3f415 Linus Torvalds      2005-04-16  468  	/* NOTE: the idle thread may not be running while calling
^1da177e4c3f415 Linus Torvalds      2005-04-16  469  	 * this function */
^1da177e4c3f415 Linus Torvalds      2005-04-16  470  
991528d73486679 Venkatesh Pallipadi 2006-09-25  471  	/* Zero initialize all the C-states info. */
991528d73486679 Venkatesh Pallipadi 2006-09-25  472  	memset(pr->power.states, 0, sizeof(pr->power.states));
991528d73486679 Venkatesh Pallipadi 2006-09-25  473  
^1da177e4c3f415 Linus Torvalds      2005-04-16  474  	result = acpi_processor_get_power_info_cst(pr);
6d93c64803a5fea Venkatesh Pallipadi 2005-09-15  475  	if (result == -ENODEV)
c5a114f1fb2d3c5 Darrick J. Wong     2006-10-19  476  		result = acpi_processor_get_power_info_fadt(pr);
6d93c64803a5fea Venkatesh Pallipadi 2005-09-15  477  
991528d73486679 Venkatesh Pallipadi 2006-09-25  478  	if (result)
991528d73486679 Venkatesh Pallipadi 2006-09-25  479  		return result;
991528d73486679 Venkatesh Pallipadi 2006-09-25  480  
991528d73486679 Venkatesh Pallipadi 2006-09-25  481  	acpi_processor_get_power_info_default(pr);
991528d73486679 Venkatesh Pallipadi 2006-09-25  482  
cf82478840188f8 Janosch Machowinski 2005-08-20  483  	pr->power.count = acpi_processor_power_verify(pr);
8fa2f8bd6ad10ec Zhang Rui           2025-04-09  484  	pr->flags.power = 1;
^1da177e4c3f415 Linus Torvalds      2005-04-16  485  
d550d98d3317378 Patrick Mochel      2006-06-27  486  	return 0;
^1da177e4c3f415 Linus Torvalds      2005-04-16  487  }
^1da177e4c3f415 Linus Torvalds      2005-04-16  488  

:::::: The code at line 464 was first introduced by commit
:::::: 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 Linux-2.6.12-rc2

:::::: TO: Linus Torvalds <torvalds@ppc970.osdl.org>
:::::: CC: Linus Torvalds <torvalds@ppc970.osdl.org>

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [rafael-pm:bleeding-edge 44/56] drivers/acpi/processor_idle.c:464:22: warning: unused variable 'i'
  2025-04-10  3:51 [rafael-pm:bleeding-edge 44/56] drivers/acpi/processor_idle.c:464:22: warning: unused variable 'i' kernel test robot
@ 2025-04-10  7:56 ` Zhang, Rui
  2025-04-10 12:18   ` Rafael J. Wysocki
  0 siblings, 1 reply; 3+ messages in thread
From: Zhang, Rui @ 2025-04-10  7:56 UTC (permalink / raw)
  To: lkp
  Cc: linux-pm@vger.kernel.org, devel@acpica.org,
	oe-kbuild-all@lists.linux.dev, linux-acpi@vger.kernel.org,
	rjw@rjwysocki.net

On Thu, 2025-04-10 at 11:51 +0800, kernel test robot wrote:
> Hi Zhang,
> 
> FYI, the error/warning was bisected to this commit, please ignore it if
> it's irrelevant.

yes, this is a valid report.

Rafael,
Do I need to send an updated patch or you will handle this directly?

thanks,
rui
> 
> tree:  
> https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git ble
> eding-edge
> head:   655d33f14d6cebcf46e422bcb9d225d791bba42f
> commit: 8ea9d119e7c666b6d87697af1b69193354c865d1 [44/56] ACPI:
> processor: idle: Remove redundant pr->power.count assignment
> config: i386-buildonly-randconfig-003-20250409
> (https://download.01.org/0day-ci/archive/20250410/202504101132.pgiDBR2Q
> -lkp@intel.com/config)
> compiler: gcc-11 (Debian 11.3.0-12) 11.3.0
> reproduce (this is a W=1 build):
> (https://download.01.org/0day-ci/archive/20250410/202504101132.pgiDBR2Q
> -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/oe-kbuild-all/202504101132.pgiDBR2Q-lkp@intel.com/
> 
> All warnings (new ones prefixed by >>):
> 
>    drivers/acpi/processor_idle.c: In function
> 'acpi_processor_get_cstate_info':
> > > drivers/acpi/processor_idle.c:464:22: warning: unused variable 'i'
> > > [-Wunused-variable]
>      464 |         unsigned int i;
>          |                      ^
> 
> 
> vim +/i +464 drivers/acpi/processor_idle.c
> 
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  461  
> a36a7fecfe60717 Sudeep Holla        2016-07-21  462  static int
> acpi_processor_get_cstate_info(struct acpi_processor *pr)
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  463  {
> ^1da177e4c3f415 Linus Torvalds      2005-04-16 @464  	unsigned int
> i;
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  465  	int result;
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  466  
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  467  
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  468  	/* NOTE: the
> idle thread may not be running while calling
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  469  	 * this
> function */
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  470  
> 991528d73486679 Venkatesh Pallipadi 2006-09-25  471  	/* Zero
> initialize all the C-states info. */
> 991528d73486679 Venkatesh Pallipadi 2006-09-25  472  	memset(pr-
> >power.states, 0, sizeof(pr->power.states));
> 991528d73486679 Venkatesh Pallipadi 2006-09-25  473  
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  474  	result =
> acpi_processor_get_power_info_cst(pr);
> 6d93c64803a5fea Venkatesh Pallipadi 2005-09-15  475  	if (result ==
> -ENODEV)
> c5a114f1fb2d3c5 Darrick J. Wong     2006-10-19  476  		result
> = acpi_processor_get_power_info_fadt(pr);
> 6d93c64803a5fea Venkatesh Pallipadi 2005-09-15  477  
> 991528d73486679 Venkatesh Pallipadi 2006-09-25  478  	if (result)
> 991528d73486679 Venkatesh Pallipadi 2006-09-25  479  		return
> result;
> 991528d73486679 Venkatesh Pallipadi 2006-09-25  480  
> 991528d73486679 Venkatesh Pallipadi 2006-09-25 
> 481  	acpi_processor_get_power_info_default(pr);
> 991528d73486679 Venkatesh Pallipadi 2006-09-25  482  
> cf82478840188f8 Janosch Machowinski 2005-08-20  483  	pr-
> >power.count = acpi_processor_power_verify(pr);
> 8fa2f8bd6ad10ec Zhang Rui           2025-04-09  484  	pr-
> >flags.power = 1;
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  485  
> d550d98d3317378 Patrick Mochel      2006-06-27  486  	return 0;
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  487  }
> ^1da177e4c3f415 Linus Torvalds      2005-04-16  488  
> 
> :::::: The code at line 464 was first introduced by commit
> :::::: 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 Linux-2.6.12-rc2
> 
> :::::: TO: Linus Torvalds <torvalds@ppc970.osdl.org>
> :::::: CC: Linus Torvalds <torvalds@ppc970.osdl.org>
> 


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [rafael-pm:bleeding-edge 44/56] drivers/acpi/processor_idle.c:464:22: warning: unused variable 'i'
  2025-04-10  7:56 ` Zhang, Rui
@ 2025-04-10 12:18   ` Rafael J. Wysocki
  0 siblings, 0 replies; 3+ messages in thread
From: Rafael J. Wysocki @ 2025-04-10 12:18 UTC (permalink / raw)
  To: Zhang, Rui
  Cc: lkp, linux-pm@vger.kernel.org, devel@acpica.org,
	oe-kbuild-all@lists.linux.dev, linux-acpi@vger.kernel.org,
	rjw@rjwysocki.net

On Thu, Apr 10, 2025 at 9:56 AM Zhang, Rui <rui.zhang@intel.com> wrote:
>
> On Thu, 2025-04-10 at 11:51 +0800, kernel test robot wrote:
> > Hi Zhang,
> >
> > FYI, the error/warning was bisected to this commit, please ignore it if
> > it's irrelevant.
>
> yes, this is a valid report.
>
> Rafael,
> Do I need to send an updated patch or you will handle this directly?

I've fixed it up locally, thanks!

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-04-10 12:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-10  3:51 [rafael-pm:bleeding-edge 44/56] drivers/acpi/processor_idle.c:464:22: warning: unused variable 'i' kernel test robot
2025-04-10  7:56 ` Zhang, Rui
2025-04-10 12:18   ` Rafael J. Wysocki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).