Linux Headquarters
[ Register ]
[ About us ] [ Home Page ]

Advertisement
[ Kernel ] [ Documentation ] [ Links ] [ Books ]

Advertisement

Kernel v2.6.24-git21 /drivers/ata/pata_hpt37x.c

Filename:/drivers/ata/pata_hpt37x.c
Lines Added:4
Lines Deleted:3
Also changed in: (Previous) 2.6.24-git20  2.6.24-git19  2.6.24-git18  2.6.24-git17  2.6.24-git16  2.6.24-git15 
(Following) 2.6.24-git22  2.6.24.4-rc1  2.6.24.4-rc2  2.6.24.4-rc3  2.6.24.4  2.6.24.5 

Location
[  2.6.24-git21
  [  drivers
    [  ata
       o  pata_hpt37x.c

Patch

diff --git a/drivers/ata/pata_hpt37x.c b/drivers/ata/pata_hpt37x.c
index c79f066..68eb349 100644
--- a/drivers/ata/pata_hpt37x.c
+++ b/drivers/ata/pata_hpt37x.c
@@ -847,15 +847,16 @@ static u32 hpt374_read_freq(struct pci_dev *pdev)
    u32 freq;
    unsigned long io_base = pci_resource_start(pdev, 4);
    if (PCI_FUNC(pdev->devfn) & 1) {
-      struct pci_dev *pdev_0 = pci_get_slot(pdev->bus, pdev->devfn - 1);
+      struct pci_dev *pdev_0;
+
+      pdev_0 = pci_get_slot(pdev->bus, pdev->devfn - 1);
       /* Someone hot plugged the controller on us ? */
       if (pdev_0 == NULL)
          return 0;
       io_base = pci_resource_start(pdev_0, 4);
       freq = inl(io_base + 0x90);
       pci_dev_put(pdev_0);
-   }
-   else
+   } else
       freq = inl(io_base + 0x90);
    return freq;
 }


Comments: webmaster (at) linuxhq.com.
Advertising: banners (at) linuxhq.com.
Compilation ©1998-2008 Linux Headquarters, Inc.