linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/ati: use NULL instead of 0
@ 2006-01-18  5:10 Randy.Dunlap
  0 siblings, 0 replies; only message in thread
From: Randy.Dunlap @ 2006-01-18  5:10 UTC (permalink / raw)
  To: lkml; +Cc: akpm, airlied

From: Randy Dunlap <rdunlap@xenotime.net>

Use NULL instead of 0 (sparse warnings):

drivers/char/drm/ati_pcigart.c:64:10: warning: Using plain integer as NULL pointer
drivers/char/drm/ati_pcigart.c:130:21: warning: Using plain integer as NULL pointer
drivers/char/drm/ati_pcigart.c:171:14: warning: Using plain integer as NULL pointer

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
---
 drivers/char/drm/ati_pcigart.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

--- linux-2616-rc1.orig/drivers/char/drm/ati_pcigart.c
+++ linux-2616-rc1/drivers/char/drm/ati_pcigart.c
@@ -61,7 +61,7 @@ static void *drm_ati_alloc_pcigart_table
 
 	address = __get_free_pages(GFP_KERNEL, ATI_PCIGART_TABLE_ORDER);
 	if (address == 0UL) {
-		return 0;
+		return NULL;
 	}
 
 	page = virt_to_page(address);
@@ -127,7 +127,7 @@ int drm_ati_pcigart_cleanup(drm_device_t
 	if (gart_info->gart_table_location == DRM_ATI_GART_MAIN
 	    && gart_info->addr) {
 		drm_ati_free_pcigart_table(gart_info->addr);
-		gart_info->addr = 0;
+		gart_info->addr = NULL;
 	}
 
 	return 1;
@@ -168,7 +168,7 @@ int drm_ati_pcigart_init(drm_device_t *d
 		if (bus_address == 0) {
 			DRM_ERROR("unable to map PCIGART pages!\n");
 			drm_ati_free_pcigart_table(address);
-			address = 0;
+			address = NULL;
 			goto done;
 		}
 	} else {


---

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-01-18  5:14 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-01-18  5:10 [PATCH] drm/ati: use NULL instead of 0 Randy.Dunlap

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).