[PATCH] PCI/ERR: Fix state assignment

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The state was intended to be assigned rather than compared for equality.

Link: https://lore.kernel.org/linux-pci/202102101255.HZtDITwe-lkp@xxxxxxxxx/
Fixes: 8fae7d8809b815148 ("PCI/ERR: Simplify pci_dev_set_io_state()")
Cc: Bjorn Helgass <helgaas@xxxxxxxxxx>
Signed-off-by: Keith Busch <kbusch@xxxxxxxxxx>
---
 drivers/pci/pci.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h
index db267120c962..1e4e4cb48bab 100644
--- a/drivers/pci/pci.h
+++ b/drivers/pci/pci.h
@@ -345,7 +345,7 @@ static inline bool pci_dev_set_io_state(struct pci_dev *dev,
 
 	/* Can always put a device in perm_failure state */
 	if (new == pci_channel_io_perm_failure) {
-		dev->error_state == pci_channel_io_perm_failure;
+		dev->error_state = pci_channel_io_perm_failure;
 		return true;
 	}
 
-- 
2.25.4




[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux