ASoC: tegra+wm8903: simplify gpio tests in widget callbacks
authorStephen Warren <swarren@nvidia.com>
Tue, 22 May 2012 22:08:53 +0000 (16:08 -0600)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Sun, 3 Jun 2012 12:06:37 +0000 (13:06 +0100)
commit14df415a38234aa483219335bc6c1ee899b85e10
tree243bc6bc30b7fe3faee0d6ce3b15e34fc99ebe89
parent9f6328d910ef8df8176ed433aa2de037eba1f656
ASoC: tegra+wm8903: simplify gpio tests in widget callbacks

By the time any widget callbacks could be called, if the GPIO ID they
will manipulate is valid, it must have already been requested, or the
card would have failed to probe or initialize. So, testing for GPIO
validity is equivalent to testing whether the GPIO was successfully
requested at this point in the code. Making this change will allow later
patches to remove the gpio_requested variable.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/tegra/tegra_wm8903.c