]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
sata_fsl: Return non-zero on error in probe()
authorMichal Sojka <sojkam1@fel.cvut.cz>
Wed, 14 Jan 2009 13:02:38 +0000 (14:02 +0100)
committerJeff Garzik <jgarzik@redhat.com>
Fri, 16 Jan 2009 15:23:58 +0000 (10:23 -0500)
while I was looking over kernel sources I've found this small bug.

Formerly, zero was returned even if an error happened.

Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
drivers/ata/sata_fsl.c

index 1a56db92ff7ac685bfab920508d6fcc2bc0124a1..55bc88c1707bfab1fdcb7f63e961a05e004d57dc 100644 (file)
@@ -1288,7 +1288,7 @@ static const struct ata_port_info sata_fsl_port_info[] = {
 static int sata_fsl_probe(struct of_device *ofdev,
                        const struct of_device_id *match)
 {
-       int retval = 0;
+       int retval = -ENXIO;
        void __iomem *hcr_base = NULL;
        void __iomem *ssr_base = NULL;
        void __iomem *csr_base = NULL;