]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
SATA: use NULL for ptrs
authorRandy Dunlap <randy.dunlap@oracle.com>
Fri, 16 Feb 2007 09:40:06 +0000 (01:40 -0800)
committerJeff Garzik <jeff@garzik.org>
Wed, 21 Feb 2007 09:58:17 +0000 (04:58 -0500)
Fix sparse warnings in SATA:
drivers/ata/sata_sil.c:342:9: warning: Using plain integer as NULL pointer
drivers/ata/sata_mv.c:2056:55: warning: Using plain integer as NULL pointer

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/ata/sata_mv.c
drivers/ata/sata_sil.c

index d689df52eae3790a8027aaa21bc140bd3112d3ae..c73aa3bbaa3e4595b73dbaea31ce94f16725efe6 100644 (file)
@@ -2052,7 +2052,7 @@ static void mv_port_init(struct ata_ioports *port,  void __iomem *port_mmio)
        port->altstatus_addr = port->ctl_addr = shd_base + SHD_CTL_AST_OFS;
 
        /* unused: */
-       port->cmd_addr = port->bmdma_addr = port->scr_addr = 0;
+       port->cmd_addr = port->bmdma_addr = port->scr_addr = NULL;
 
        /* Clear any currently outstanding port interrupt conditions */
        serr_ofs = mv_scr_offset(SCR_ERROR);
index dca3d3749f0626cbc2d79798ecda01502b1452e3..14872556334be81d96df55ccff435e4dd5ba22db 100644 (file)
@@ -339,7 +339,7 @@ static inline void __iomem *sil_scr_addr(struct ata_port *ap, unsigned int sc_re
                break;
        }
 
-       return 0;
+       return NULL;
 }
 
 static u32 sil_scr_read (struct ata_port *ap, unsigned int sc_reg)