drivers: atm, char fix integer as NULL pointer warnings
authorHarvey Harrison <harvey.harrison@gmail.com>
Mon, 28 Apr 2008 21:13:20 +0000 (14:13 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 29 Apr 2008 00:29:18 +0000 (17:29 -0700)
drivers/atm/nicstar.c:418:25: warning: Using plain integer as NULL pointer
drivers/char/drm/r128_cce.c:820:25: warning: Using plain integer as NULL pointer
drivers/char/tty_io.c:1183:10: warning: Using plain integer as NULL pointer

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/atm/nicstar.c
drivers/char/drm/r128_cce.c
drivers/char/tty_io.c

index 38c769f8d2b7a991762c1727cf1ff2f192b85c67..3da804b1627d6b7e8578b381aae4b2c3f7c51be1 100644 (file)
@@ -415,7 +415,7 @@ static int __devinit ns_init_card(int i, struct pci_dev *pcidev)
    card->pcidev = pcidev;
    membase = pci_resource_start(pcidev, 1);
    card->membase = ioremap(membase, NS_IOREMAP_SIZE);
-   if (card->membase == 0)
+   if (!card->membase)
    {
       printk("nicstar%d: can't ioremap() membase.\n",i);
       error = 3;
index f36adbd3aaf5cccac2db4e48921f484f3d3d076e..c31afbde62e72d8fdadb31b5255a34918c64d2f1 100644 (file)
@@ -817,7 +817,7 @@ static struct drm_buf *r128_freelist_get(struct drm_device * dev)
        for (i = 0; i < dma->buf_count; i++) {
                buf = dma->buflist[i];
                buf_priv = buf->dev_private;
-               if (buf->file_priv == 0)
+               if (!buf->file_priv)
                        return buf;
        }
 
index 4d3c7018f0c3a9198093ace1ed28b69747a2209b..98b65a2309943041f88690b6b50bddab096300be 100644 (file)
@@ -1180,7 +1180,7 @@ struct tty_driver *tty_find_polling_driver(char *name, int *line)
                if (*str == ',')
                        str++;
                if (*str == '\0')
-                       str = 0;
+                       str = NULL;
 
                if (tty_line >= 0 && tty_line <= p->num && p->poll_init &&
                                !p->poll_init(p, tty_line, str)) {