[<prev] [next>] [day] [month] [year] [list]
Message-ID: <1298332643.11571.21.camel@t41.thuisdomein>
Date: Tue, 22 Feb 2011 00:57:22 +0100
From: Paul Bolle <pebolle@...cali.nl>
To: linux-kernel@...r.kernel.org
Subject: snd_intel8x0m: error message because return value is unused?
0) In order to make a laptop run without error messages (ie, printks at
KERN_ERR level) I had to look at an error generated by snd_intel8x0m:
ALSA intel8x0m.c:904: AC'97 warm reset still in progress? [0x2]
1) There's a datasheet one can study to understand that message. But
that seems not necessary here. It all boils down to the fact that this
test:
if ((igetdword(chip, ICHREG(GLOB_CNT)) & ICH_AC97WARM) == 0)
goto __ok;
will always fail so we'll never go to __ok and finally that error will
be printed. But if I simply change it into:
cnt = igetdword(chip, ICHREG(GLOB_CNT));
if ((cnt & ICH_AC97WARM) == 0)
goto __ok;
this test will (always) succeed, we'll go to __ok and no error message
will be printed. So apparently, the error message was just a false
alarm.
2) Before I submit a (trivial) patch to fix this I'd like to better
understand what is going on here: is this standard C behavior, something
the build system asks the compiler to do, or maybe something else?
Paul Bolle
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists