LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH 07/12] sound: rme96.c fix integer as NULL pointer warning
@ 2008-02-28  0:56 Harvey Harrison
  0 siblings, 0 replies; only message in thread
From: Harvey Harrison @ 2008-02-28  0:56 UTC (permalink / raw)
  To: Andrew Morton; +Cc: LKML

kernel style does assignment outside of if() block
sound/pci/rme96.c:1562:71: warning: Using plain integer as NULL pointer

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
---
 sound/pci/rme96.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/sound/pci/rme96.c b/sound/pci/rme96.c
index fb0a4ee..3fdd488 100644
--- a/sound/pci/rme96.c
+++ b/sound/pci/rme96.c
@@ -1559,7 +1559,8 @@ snd_rme96_create(struct rme96 *rme96)
 		return err;
 	rme96->port = pci_resource_start(rme96->pci, 0);
 
-	if ((rme96->iobase = ioremap_nocache(rme96->port, RME96_IO_SIZE)) == 0) {
+	rme96->iobase = ioremap_nocache(rme96->port, RME96_IO_SIZE);
+	if (!rme96->iobase) {
 		snd_printk(KERN_ERR "unable to remap memory region 0x%lx-0x%lx\n", rme96->port, rme96->port + RME96_IO_SIZE - 1);
 		return -ENOMEM;
 	}
-- 
1.5.4.3.342.g99e8



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

only message in thread, other threads:[~2008-02-28  0:58 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-02-28  0:56 [PATCH 07/12] sound: rme96.c fix integer as NULL pointer warning Harvey Harrison

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).