linux/sound/soc
Julia Lawall 02ffc5f3f9 ASoC: davinci-mcasp.c: Return error code in failure
In this code, 0 is returned on failure, even though other
failures return -ENOMEM or other similar values.

A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)

// <smpl>
@a@
identifier alloc;
identifier ret;
constant C;
expression x;
@@

x = alloc(...);
if (x == NULL) { <+... \(ret = -C; \| return -C; \) ...+> }

@@
identifier f, a.alloc;
expression ret;
expression x,e1,e2,e3;
@@

ret = 0
... when != ret = e1
*x = alloc(...)
... when != ret = e2
if (x == NULL) { ... when != ret = e3
  return ret;
}
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2010-10-18 16:29:24 -07:00
..
atmel ASoC: Add simplfied device registration for Atmel SSC devices 2010-08-18 16:53:22 +01:00
au1x ASoC: fix au1x platform 2010-08-31 13:06:31 +01:00
blackfin Merge branch 'for-2.6.36' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound-2.6 into for-2.6.37 2010-08-15 14:56:40 +01:00
codecs Revert "ASoC: Add max98088 CODEC driver" 2010-10-18 06:01:33 +01:00
davinci ASoC: davinci-mcasp.c: Return error code in failure 2010-10-18 16:29:24 -07:00
ep93xx ASoC: ep93xx: add Simplemachines Sim.One AC97 audio support 2010-10-15 11:54:54 +01:00
fsl ASoC: pl022_ds.c: Add of_node_put to avoid memory leak 2010-09-02 16:28:49 +01:00
imx ASoC: Remove -dai suffix from i.MX SSI driver 2010-10-01 00:13:28 -07:00
jz4740 ASoC: Multi-component: JZ4740: QI_LB60 board fixes 2010-08-17 12:10:30 +01:00
kirkwood ASoC: Change my mail address 2010-09-15 12:03:58 +01:00
nuc900 ASoC: remove duplicated include for nuc900 2010-10-05 19:26:00 -07:00
omap OMAP: McBSP: Fix static function warning 2010-09-08 12:14:02 +01:00
pxa ASoC: pxa-ssp: fix a memory leak in pxa_ssp_remove() 2010-08-25 14:20:15 +01:00
s3c24xx ASoC: SAMSUNG: Add Machine driver for S/PDIF PCM audio 2010-10-15 11:41:12 +01:00
s6000 ASoC: multi-component - ASoC Multi-Component Support 2010-08-12 14:00:00 +01:00
sh ASoC: fsi: simultaneous playback/recorde support 2010-10-15 11:41:25 +01:00
txx9 ASoC: multi-component - ASoC Multi-Component Support 2010-08-12 14:00:00 +01:00
Kconfig ASoC: Fix sorting of Makefile and Kconfig 2010-07-05 23:35:29 +09:00
Makefile ASoC: Fix sorting of Makefile and Kconfig 2010-07-05 23:35:29 +09:00
soc-cache.c ASoC: soc-cache: Add spi_write support for all I/O types 2010-10-05 09:56:34 -07:00
soc-core.c ASoC: Pay attention to driver supplied DAI IDs 2010-10-13 11:02:43 +01:00
soc-dapm.c ASoC: multi-component - ASoC Multi-Component Support 2010-08-12 14:00:00 +01:00
soc-jack.c ASoC: Use delayed work for debounce of GPIO based jacks 2010-10-07 12:58:56 -07:00
soc-utils.c ASoC: Add BCLK calculation utility for TDM mode too 2009-11-25 19:55:46 +00:00