aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/pci-sysfs.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/pci/pci-sysfs.c')
-rw-r--r--drivers/pci/pci-sysfs.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
index 1b7b2812bf2d..7d1877341aad 100644
--- a/drivers/pci/pci-sysfs.c
+++ b/drivers/pci/pci-sysfs.c
@@ -702,8 +702,10 @@ static int __init pci_sysfs_init(void)
702 sysfs_initialized = 1; 702 sysfs_initialized = 1;
703 for_each_pci_dev(pdev) { 703 for_each_pci_dev(pdev) {
704 retval = pci_create_sysfs_dev_files(pdev); 704 retval = pci_create_sysfs_dev_files(pdev);
705 if (retval) 705 if (retval) {
706 pci_dev_put(pdev);
706 return retval; 707 return retval;
708 }
707 } 709 }
708 710
709 return 0; 711 return 0;