From: Dan Carpenter <dan.carpenter@oracle.com>
To: kbuild@lists.01.org, Bjorn Helgaas <helgaas@kernel.org>
Cc: lkp@intel.com, kbuild-all@lists.01.org, linux-pci@vger.kernel.org
Subject: [kbuild] [pci:pci/error 2/8] drivers/pci/hotplug/../pci.h:348 pci_dev_set_io_state() warn: statement has no effect 22
Date: Wed, 10 Feb 2021 18:24:21 +0300 [thread overview]
Message-ID: <20210210152421.GC20820@kadam> (raw)
[-- Attachment #1: Type: text/plain, Size: 2210 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: i386-randconfig-m021-20210209 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/pci/hotplug/../pci.h:348 pci_dev_set_io_state() warn: statement has no effect 22
vim +348 drivers/pci/hotplug/../pci.h
a6bd101b8f84f9b Keith Busch 2018-09-20 341 static inline bool pci_dev_set_io_state(struct pci_dev *dev,
a6bd101b8f84f9b Keith Busch 2018-09-20 342 pci_channel_state_t new)
a6bd101b8f84f9b Keith Busch 2018-09-20 343 {
a6bd101b8f84f9b Keith Busch 2018-09-20 344 device_lock_assert(&dev->dev);
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 345
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 346 /* Can always put a device in perm_failure state */
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 347 if (new == pci_channel_io_perm_failure) {
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 @348 dev->error_state == pci_channel_io_perm_failure;
This should be = instead of ==.
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 349 return true;
a6bd101b8f84f9b Keith Busch 2018-09-20 350 }
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 351
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 352 /* If already in perm_failure, can't set to normal or frozen */
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 353 if (dev->error_state == pci_channel_io_perm_failure)
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 354 return false;
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 355
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 356 /* Can always change normal to frozen or vice versa */
a6bd101b8f84f9b Keith Busch 2018-09-20 357 dev->error_state = new;
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 358 return true;
a6bd101b8f84f9b Keith Busch 2018-09-20 359 }
---
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: 37152 bytes --]
[-- Attachment #3: Type: text/plain, Size: 149 bytes --]
_______________________________________________
kbuild mailing list -- kbuild@lists.01.org
To unsubscribe send an email to kbuild-leave@lists.01.org
WARNING: multiple messages have this Message-ID (diff)
From: Dan Carpenter <dan.carpenter@oracle.com>
To: kbuild@lists.01.org
Subject: [pci:pci/error 2/8] drivers/pci/hotplug/../pci.h:348 pci_dev_set_io_state() warn: statement has no effect 22
Date: Wed, 10 Feb 2021 18:24:21 +0300 [thread overview]
Message-ID: <20210210152421.GC20820@kadam> (raw)
[-- Attachment #1: Type: text/plain, Size: 2411 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: i386-randconfig-m021-20210209 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/pci/hotplug/../pci.h:348 pci_dev_set_io_state() warn: statement has no effect 22
vim +348 drivers/pci/hotplug/../pci.h
a6bd101b8f84f9b Keith Busch 2018-09-20 341 static inline bool pci_dev_set_io_state(struct pci_dev *dev,
a6bd101b8f84f9b Keith Busch 2018-09-20 342 pci_channel_state_t new)
a6bd101b8f84f9b Keith Busch 2018-09-20 343 {
a6bd101b8f84f9b Keith Busch 2018-09-20 344 device_lock_assert(&dev->dev);
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 345
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 346 /* Can always put a device in perm_failure state */
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 347 if (new == pci_channel_io_perm_failure) {
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 @348 dev->error_state == pci_channel_io_perm_failure;
This should be = instead of ==.
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 349 return true;
a6bd101b8f84f9b Keith Busch 2018-09-20 350 }
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 351
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 352 /* If already in perm_failure, can't set to normal or frozen */
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 353 if (dev->error_state == pci_channel_io_perm_failure)
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 354 return false;
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 355
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 356 /* Can always change normal to frozen or vice versa */
a6bd101b8f84f9b Keith Busch 2018-09-20 357 dev->error_state = new;
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 358 return true;
a6bd101b8f84f9b Keith Busch 2018-09-20 359 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
_______________________________________________
kbuild mailing list -- kbuild(a)lists.01.org
To unsubscribe send an email to kbuild-leave(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 37152 bytes --]
WARNING: multiple messages have this Message-ID (diff)
From: Dan Carpenter <dan.carpenter@oracle.com>
To: kbuild-all@lists.01.org
Subject: [kbuild] [pci:pci/error 2/8] drivers/pci/hotplug/../pci.h:348 pci_dev_set_io_state() warn: statement has no effect 22
Date: Wed, 10 Feb 2021 18:24:21 +0300 [thread overview]
Message-ID: <20210210152421.GC20820@kadam> (raw)
[-- Attachment #1: Type: text/plain, Size: 2411 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: i386-randconfig-m021-20210209 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/pci/hotplug/../pci.h:348 pci_dev_set_io_state() warn: statement has no effect 22
vim +348 drivers/pci/hotplug/../pci.h
a6bd101b8f84f9b Keith Busch 2018-09-20 341 static inline bool pci_dev_set_io_state(struct pci_dev *dev,
a6bd101b8f84f9b Keith Busch 2018-09-20 342 pci_channel_state_t new)
a6bd101b8f84f9b Keith Busch 2018-09-20 343 {
a6bd101b8f84f9b Keith Busch 2018-09-20 344 device_lock_assert(&dev->dev);
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 345
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 346 /* Can always put a device in perm_failure state */
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 347 if (new == pci_channel_io_perm_failure) {
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 @348 dev->error_state == pci_channel_io_perm_failure;
This should be = instead of ==.
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 349 return true;
a6bd101b8f84f9b Keith Busch 2018-09-20 350 }
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 351
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 352 /* If already in perm_failure, can't set to normal or frozen */
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 353 if (dev->error_state == pci_channel_io_perm_failure)
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 354 return false;
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 355
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 356 /* Can always change normal to frozen or vice versa */
a6bd101b8f84f9b Keith Busch 2018-09-20 357 dev->error_state = new;
8fae7d8809b8151 Bjorn Helgaas 2020-05-19 358 return true;
a6bd101b8f84f9b Keith Busch 2018-09-20 359 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
_______________________________________________
kbuild mailing list -- kbuild(a)lists.01.org
To unsubscribe send an email to kbuild-leave(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 37152 bytes --]
next reply other threads:[~2021-02-10 15:25 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-10 15:24 Dan Carpenter [this message]
2021-02-10 15:24 ` [kbuild] [pci:pci/error 2/8] drivers/pci/hotplug/../pci.h:348 pci_dev_set_io_state() warn: statement has no effect 22 Dan Carpenter
2021-02-10 15:24 ` Dan Carpenter
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=20210210152421.GC20820@kadam \
--to=dan.carpenter@oracle.com \
--cc=helgaas@kernel.org \
--cc=kbuild-all@lists.01.org \
--cc=kbuild@lists.01.org \
--cc=linux-pci@vger.kernel.org \
--cc=lkp@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.