Patchwork ide: pmac: remove unnecessary pci_set_drvdata()

login
register
mail settings
Submitter Jingoo Han
Date Sept. 23, 2013, 1:28 a.m.
Message ID <002c01ceb7fc$2ad496e0$807dc4a0$%han@samsung.com>
Download mbox | patch
Permalink /patch/277038/
State Accepted
Delegated to: David Miller
Headers show

Comments

Jingoo Han - Sept. 23, 2013, 1:28 a.m.
The driver core clears the driver data to NULL after device_release
or on probe failure. Thus, it is not needed to manually clear the
device driver data to NULL.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
---
 drivers/ide/pmac.c |    1 -
 1 file changed, 1 deletion(-)

Patch

diff --git a/drivers/ide/pmac.c b/drivers/ide/pmac.c
index bf83d7b..4511ea7 100644
--- a/drivers/ide/pmac.c
+++ b/drivers/ide/pmac.c
@@ -1318,7 +1318,6 @@  static int pmac_ide_pci_attach(struct pci_dev *pdev,
 	rc = pmac_ide_setup_device(pmif, &hw);
 	if (rc != 0) {
 		/* The inteface is released to the common IDE layer */
-		pci_set_drvdata(pdev, NULL);
 		iounmap(base);
 		pci_release_regions(pdev);
 		kfree(pmif);