Discussion:
[PATCH v2 1/3] ASoC: ssm2602: do not hardcode type to SSM2602
Stefan Kristiansson
2014-09-29 19:39:13 UTC
Permalink
The correct type (SSM2602/SSM2603/SSM2604) is passed down
from the ssm2602_spi_probe()/ssm2602_spi_probe() functions,
so use that instead of hardcoding it to SSM2602 in
ssm2602_probe().

Signed-off-by: Stefan Kristiansson <***@saunalahti.fi>
---
Changes in v2:
- None, new in series.
---
sound/soc/codecs/ssm2602.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/codecs/ssm2602.c b/sound/soc/codecs/ssm2602.c
index 484b3bb..4021cd4 100644
--- a/sound/soc/codecs/ssm2602.c
+++ b/sound/soc/codecs/ssm2602.c
@@ -647,7 +647,7 @@ int ssm2602_probe(struct device *dev, enum ssm2602_type type,
return -ENOMEM;

dev_set_drvdata(dev, ssm2602);
- ssm2602->type = SSM2602;
+ ssm2602->type = type;
ssm2602->regmap = regmap;

return snd_soc_register_codec(dev, &soc_codec_dev_ssm2602,
--
1.9.1
Lars-Peter Clausen
2014-09-29 19:51:05 UTC
Permalink
Post by Stefan Kristiansson
The correct type (SSM2602/SSM2603/SSM2604) is passed down
from the ssm2602_spi_probe()/ssm2602_spi_probe() functions,
so use that instead of hardcoding it to SSM2602 in
ssm2602_probe().
Fixes: c924dc68f737 ("ASoC: ssm2602: Split SPI and I2C code into different \
modules")
Acked-by: Lars-Peter Clausen <***@metafoo.de>
Mark Brown
2014-09-30 12:38:01 UTC
Permalink
Post by Stefan Kristiansson
The correct type (SSM2602/SSM2603/SSM2604) is passed down
from the ssm2602_spi_probe()/ssm2602_spi_probe() functions,
so use that instead of hardcoding it to SSM2602 in
ssm2602_probe().
Applied all, thanks.

Loading...