[<prev] [next>] [day] [month] [year] [list]
Message-id: <1435226538-47364-1-git-send-email-maninder1.s@samsung.com>
Date: Thu, 25 Jun 2015 15:32:18 +0530
From: Maninder Singh <maninder1.s@...sung.com>
To: airlied@...ux.ie, linux-kernel@...r.kernel.org
Cc: pankaj.m@...sung.com, Maninder Singh <maninder1.s@...sung.com>
Subject: [PATCH 1/1] char/agp: remove checks around pci_dev_put
No need of explicit check around pci_dev_put,
It handles with NULL pointer itself.
Signed-off-by: Maninder Singh <maninder1.s@...sung.com>
Reviewed-by: Akhilesh Kumar <akhilesh.k@...sung.com>
---
drivers/char/agp/intel-gtt.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/char/agp/intel-gtt.c b/drivers/char/agp/intel-gtt.c
index 0b4188b..78d35fa 100644
--- a/drivers/char/agp/intel-gtt.c
+++ b/drivers/char/agp/intel-gtt.c
@@ -1430,10 +1430,8 @@ void intel_gmch_remove(void)
if (--intel_private.refcount)
return;
- if (intel_private.pcidev)
- pci_dev_put(intel_private.pcidev);
- if (intel_private.bridge_dev)
- pci_dev_put(intel_private.bridge_dev);
+ pci_dev_put(intel_private.pcidev);
+ pci_dev_put(intel_private.bridge_dev);
intel_private.driver = NULL;
}
EXPORT_SYMBOL(intel_gmch_remove);
--
1.7.9.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists