1 // SPDX-License-Identifier: GPL-2.0-only
3 * ALSA SoC TLV320AIC23 codec driver SPI interface
5 * Author: Arun KS, <arunks@mistralsolutions.com>
6 * Copyright: (C) 2008 Mistral Solutions Pvt Ltd.,
8 * Based on sound/soc/codecs/wm8731.c by Richard Purdie
11 #include <linux/module.h>
12 #include <linux/regmap.h>
13 #include <linux/spi/spi.h>
14 #include <sound/soc.h>
16 #include "tlv320aic23.h"
18 static int aic23_spi_probe(struct spi_device
*spi
)
21 struct regmap
*regmap
;
23 dev_dbg(&spi
->dev
, "probing tlv320aic23 spi device\n");
25 spi
->mode
= SPI_MODE_0
;
30 regmap
= devm_regmap_init_spi(spi
, &tlv320aic23_regmap
);
31 return tlv320aic23_probe(&spi
->dev
, regmap
);
34 static struct spi_driver aic23_spi
= {
36 .name
= "tlv320aic23",
38 .probe
= aic23_spi_probe
,
41 module_spi_driver(aic23_spi
);
43 MODULE_DESCRIPTION("ASoC TLV320AIC23 codec driver SPI");
44 MODULE_AUTHOR("Arun KS <arunks@mistralsolutions.com>");
45 MODULE_LICENSE("GPL");