]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
sata_nv: propagate ata_pci_device_do_resume return value
authorRobert Hancock <hancockr@shaw.ca>
Tue, 6 Feb 2007 00:26:04 +0000 (16:26 -0800)
committerJeff Garzik <jeff@garzik.org>
Fri, 9 Feb 2007 22:39:40 +0000 (17:39 -0500)
ata_pci_device_do_resume can fail if the PCI device couldn't be re-enabled.
 Update sata_nv to propagate the return value from this call and to not try
to do any other resume activities if it fails.  Fixes a compile warning.

Signed-off-by: Robert Hancock <hancockr@shaw.ca>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/ata/sata_nv.c

index aea005d5663cb24ebbfaceeec9193013be3a67e9..095ef1b2cd0e92b1e7dc3dd75a1a4f3760438c2f 100644 (file)
@@ -1575,8 +1575,11 @@ static int nv_pci_device_resume(struct pci_dev *pdev)
 {
        struct ata_host *host = dev_get_drvdata(&pdev->dev);
        struct nv_host_priv *hpriv = host->private_data;
+       int rc;
 
-       ata_pci_device_do_resume(pdev);
+       rc = ata_pci_device_do_resume(pdev);
+       if(rc)
+               return rc;
 
        if (pdev->dev.power.power_state.event == PM_EVENT_SUSPEND) {
                if(hpriv->type >= CK804) {