From: Yoann Padioleau Date: Fri, 27 Jul 2007 09:45:31 +0000 Subject: [PATCH 14/68] 0 -> NULL, for arch/sh Message-Id: <200707270945.LAA17306@ifs.emn.fr> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: kernel-janitors@vger.kernel.org Cc: lethal@linux-sh.org, akpm@linux-foundation.org, linux-kernel@vger.kernel.org When comparing a pointer, it's clearer to compare it to NULL than to 0. Here is an excerpt of the semantic patch: @@ expression *E; @@ E = - 0 + NULL @@ expression *E; @@ E !- 0 + NULL Signed-off-by: Yoann Padioleau Cc: lethal@linux-sh.org Cc: akpm@linux-foundation.org --- cchips/hd6446x/hd64461.c | 2 +- cchips/hd6446x/hd64465/gpio.c | 4 ++-- cchips/hd6446x/hd64465/setup.c | 2 +- cchips/voyagergx/irq.c | 2 +- kernel/sh_bios.c | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/arch/sh/cchips/hd6446x/hd64461.c b/arch/sh/cchips/hd6446x/hd64461.c index 97f6512..6117fd7 100644 --- a/arch/sh/cchips/hd6446x/hd64461.c +++ b/arch/sh/cchips/hd6446x/hd64461.c @@ -116,7 +116,7 @@ int hd64461_irq_demux(int irq) irq = CONFIG_HD64461_IRQ; else { irq = HD64461_IRQBASE + i; - if (hd64461_demux[i].func != 0) { + if (hd64461_demux[i].func != NULL) { irq = hd64461_demux[i].func(irq, hd64461_demux[i].dev); } } diff --git a/arch/sh/cchips/hd6446x/hd64465/gpio.c b/arch/sh/cchips/hd6446x/hd64465/gpio.c index 4343185..8ed39e2 100644 --- a/arch/sh/cchips/hd6446x/hd64465/gpio.c +++ b/arch/sh/cchips/hd6446x/hd64465/gpio.c @@ -96,7 +96,7 @@ static irqreturn_t hd64465_gpio_interrup mask = 1<