diff options
author | Julia Lawall <Julia.Lawall@lip6.fr> | 2012-08-19 09:02:57 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2012-08-20 10:56:01 +0200 |
commit | 0c23e46eb4878422c25351ff54ab0fe80c643809 (patch) | |
tree | c65f5098ef603acc9b18c08dbcb7b381d50374ca /arch/cris | |
parent | aaf265c22e48f10c94ad04d23b6ab0c88f554d35 (diff) | |
download | linux-stable-0c23e46eb4878422c25351ff54ab0fe80c643809.tar.gz linux-stable-0c23e46eb4878422c25351ff54ab0fe80c643809.tar.bz2 linux-stable-0c23e46eb4878422c25351ff54ab0fe80c643809.zip |
ALSA: sound/atmel/ac97c.c: fix error return code
In the first case, the second test of whether retval is negative is
redundant. It is dropped and the previous and subsequent tests are
combined.
In the second case, add an initialization of retval on failure of ioremap.
A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)
// <smpl>
(
if@p1 (\(ret < 0\|ret != 0\))
{ ... return ret; }
|
ret@p1 = 0
)
... when != ret = e1
when != &ret
*if(...)
{
... when != ret = e2
when forall
return ret;
}
// </smpl>
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'arch/cris')
0 files changed, 0 insertions, 0 deletions