linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [pci:pci/error 2/8] arch/powerpc/platforms/powernv/../../../../drivers/pci/pci.h:348:20: error: statement with no effect
@ 2021-02-10  6:16 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-02-10  6:16 UTC (permalink / raw)
  To: Bjorn Helgaas; +Cc: kbuild-all, linux-pci

[-- Attachment #1: Type: text/plain, Size: 3247 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git pci/error
head:   5692817fc88f347328e35cd7b19bd04f4400652e
commit: 8fae7d8809b8151488969d6cfad2f6dd2c69d311 [2/8] PCI/ERR: Simplify pci_dev_set_io_state()
config: powerpc-pseries_defconfig (attached as .config)
compiler: powerpc64-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git/commit/?id=8fae7d8809b8151488969d6cfad2f6dd2c69d311
        git remote add pci https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git
        git fetch --no-tags pci pci/error
        git checkout 8fae7d8809b8151488969d6cfad2f6dd2c69d311
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=powerpc 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   In file included from arch/powerpc/platforms/powernv/pci-ioda.c:44:
   arch/powerpc/platforms/powernv/../../../../drivers/pci/pci.h: In function 'pci_dev_set_io_state':
>> arch/powerpc/platforms/powernv/../../../../drivers/pci/pci.h:348:20: error: statement with no effect [-Werror=unused-value]
     348 |   dev->error_state == pci_channel_io_perm_failure;
         |   ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   cc1: all warnings being treated as errors
--
   In file included from arch/powerpc/platforms/pseries/setup.c:76:
   arch/powerpc/platforms/pseries/../../../../drivers/pci/pci.h: In function 'pci_dev_set_io_state':
>> arch/powerpc/platforms/pseries/../../../../drivers/pci/pci.h:348:20: error: statement with no effect [-Werror=unused-value]
     348 |   dev->error_state == pci_channel_io_perm_failure;
         |   ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   cc1: all warnings being treated as errors


vim +348 arch/powerpc/platforms/powernv/../../../../drivers/pci/pci.h

   330	
   331	/**
   332	 * pci_dev_set_io_state - Set the new error state if possible.
   333	 *
   334	 * @dev - pci device to set new error_state
   335	 * @new - the state we want dev to be in
   336	 *
   337	 * Must be called with device_lock held.
   338	 *
   339	 * Returns true if state has been changed to the requested state.
   340	 */
   341	static inline bool pci_dev_set_io_state(struct pci_dev *dev,
   342						pci_channel_state_t new)
   343	{
   344		device_lock_assert(&dev->dev);
   345	
   346		/* Can always put a device in perm_failure state */
   347		if (new == pci_channel_io_perm_failure) {
 > 348			dev->error_state == pci_channel_io_perm_failure;
   349			return true;
   350		}
   351	
   352		/* If already in perm_failure, can't set to normal or frozen */
   353		if (dev->error_state == pci_channel_io_perm_failure)
   354			return false;
   355	
   356		/* Can always change normal to frozen or vice versa */
   357		dev->error_state = new;
   358		return true;
   359	}
   360	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 24900 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-02-10  6:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-10  6:16 [pci:pci/error 2/8] arch/powerpc/platforms/powernv/../../../../drivers/pci/pci.h:348:20: error: statement with no effect kernel test robot

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).