Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1308349

[patch] drm/nouveau/pci: reversed condition in nvkm_pcie_set_link()

From Dan Carpenter <dan.carpenter@oracle.com>
Newsgroups linux.kernel
Subject [patch] drm/nouveau/pci: reversed condition in nvkm_pcie_set_link()
Date 2016-01-13 13:30 +0100
Message-ID <qQsIO-84i-7@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


The condition is reversed so this function is a no-op.

Fixes: bcc19d9bf5cd ('drm/nouveau/pci: implement generic code for pcie speed change')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/pci/pcie.c b/drivers/gpu/drm/nouveau/nvkm/subdev/pci/pcie.c
index b32954f..d71e5db 100644
--- a/drivers/gpu/drm/nouveau/nvkm/subdev/pci/pcie.c
+++ b/drivers/gpu/drm/nouveau/nvkm/subdev/pci/pcie.c
@@ -119,7 +119,7 @@ nvkm_pcie_set_link(struct nvkm_pci *pci, enum nvkm_pcie_speed speed, u8 width)
 	struct pci_bus *pbus;
 	int ret;
 
-	if (pci || !pci_is_pcie(pci->pdev))
+	if (!pci || !pci_is_pcie(pci->pdev))
 		return 0;
 	pbus = pci->pdev->bus;
 

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[patch] drm/nouveau/pci: reversed condition in nvkm_pcie_set_link() Dan Carpenter <dan.carpenter@oracle.com> - 2016-01-13 13:30 +0100
  Re: [patch] drm/nouveau/pci: reversed condition in  nvkm_pcie_set_link() Karol Herbst <nouveau@karolherbst.de> - 2016-01-13 13:40 +0100
    Re: [patch] drm/nouveau/pci: reversed condition in  nvkm_pcie_set_link() Karol Herbst <desurium@karolherbst.de> - 2016-01-13 13:50 +0100

csiph-web