]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: sigmadsp: Fix missleading return value
authorPascal Huerst <pascal.huerst@gmail.com>
Wed, 10 Feb 2016 14:59:28 +0000 (15:59 +0100)
committerMark Brown <broonie@kernel.org>
Wed, 10 Feb 2016 18:55:01 +0000 (18:55 +0000)
commit9e370f094c6264d3e6420405342ec527fccdd43f
tree6fd5f91ba08466716ddea39a1c0b75055902bce8
parentd7e15052ecc9ac4f938d1d7432c1d120a2711a7e
ASoC: sigmadsp: Fix missleading return value

Forwarding the return value of i2c_master_send, leads to errors
later on, since i2c_master_send returns the number of bytes
transmittet. Check for ret < 0 instead and return 0 otherwise.

Signed-off-by: Pascal Huerst <pascal.huerst@gmail.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/sigmadsp-i2c.c