aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/intel_sst/intelmid.c
diff options
context:
space:
mode:
authorLu Guanqun <guanqun.lu@intel.com>2011-04-06 10:20:42 +0800
committerGreg Kroah-Hartman <gregkh@suse.de>2011-05-10 12:51:58 -0700
commit31dea7385174596f4369f71c712f1d1006a3fa05 (patch)
tree2bdfe54da73c3f1e6be621d524ebd4b7737f2dbb /drivers/staging/intel_sst/intelmid.c
parentfb03d4fc6c9bc4bf509221101639cde1b8330405 (diff)
sst: make register_sst_card more self-contained
register_sst_card is used in ASoC code with field `scard_ops` being NULL. Without this patch, there will be NULL dereference. Signed-off-by: Lu Guanqun <guanqun.lu@intel.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/intel_sst/intelmid.c')
-rw-r--r--drivers/staging/intel_sst/intelmid.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/staging/intel_sst/intelmid.c b/drivers/staging/intel_sst/intelmid.c
index d207636a7b6..2d4b94a8aa9 100644
--- a/drivers/staging/intel_sst/intelmid.c
+++ b/drivers/staging/intel_sst/intelmid.c
@@ -802,6 +802,7 @@ static int __devinit snd_intelmad_sst_register(
pr_err("sst card registration failed\n");
return ret_val;
}
+ sst_drv_ctx->scard_ops->card_status = SND_CARD_UN_INIT;
sst_card_vendor_id = intelmaddata->sstdrv_ops->vendor_id;
intelmaddata->pmic_status = PMIC_UNINIT;