summaryrefslogtreecommitdiffstats
path: root/sound/soc/mid-x86/sst_platform.c
diff options
context:
space:
mode:
authorMark Brown <broonie@linaro.org>2013-11-24 14:35:18 +0000
committerMark Brown <broonie@linaro.org>2013-11-24 14:35:18 +0000
commit30c27abd28fa168d7ebd2e5286f1fe473c74bfa9 (patch)
tree9936b38c0c81cd430d5e75906c1207d127fe588c /sound/soc/mid-x86/sst_platform.c
parent16ec790938d4f356c82fab27b9a9adf4d6fe19a6 (diff)
parent6ce4eac1f600b34f2f7f58f9cd8f0503d79e42ae (diff)
downloadblackbird-op-linux-30c27abd28fa168d7ebd2e5286f1fe473c74bfa9.tar.gz
blackbird-op-linux-30c27abd28fa168d7ebd2e5286f1fe473c74bfa9.zip
Merge tag 'v3.13-rc1' into asoc-arizona
Linux 3.13-rc1
Diffstat (limited to 'sound/soc/mid-x86/sst_platform.c')
-rw-r--r--sound/soc/mid-x86/sst_platform.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sound/soc/mid-x86/sst_platform.c b/sound/soc/mid-x86/sst_platform.c
index 392fc0b8f5b8..b6b5eb698d33 100644
--- a/sound/soc/mid-x86/sst_platform.c
+++ b/sound/soc/mid-x86/sst_platform.c
@@ -40,7 +40,8 @@ static DEFINE_MUTEX(sst_lock);
int sst_register_dsp(struct sst_device *dev)
{
- BUG_ON(!dev);
+ if (WARN_ON(!dev))
+ return -EINVAL;
if (!try_module_get(dev->dev->driver->owner))
return -ENODEV;
mutex_lock(&sst_lock);
@@ -59,7 +60,8 @@ EXPORT_SYMBOL_GPL(sst_register_dsp);
int sst_unregister_dsp(struct sst_device *dev)
{
- BUG_ON(!dev);
+ if (WARN_ON(!dev))
+ return -EINVAL;
if (dev != sst)
return -EINVAL;
OpenPOWER on IntegriCloud