summaryrefslogtreecommitdiff
path: root/arch/arm/mach-bcm2708/bcm2708.c
diff options
context:
space:
mode:
authorDaniel Matuschek <info@crazy-audio.com>2014-08-04 10:06:56 +0200
committerpopcornmix <popcornmix@gmail.com>2015-05-18 14:11:15 +0100
commit6bd1b0b2dec7f654018bf6b81580a8419c172008 (patch)
treebcf70c122f93fc6d8fc93be63047f3dc0393e75b /arch/arm/mach-bcm2708/bcm2708.c
parentf2b5a6b2beae0666bb9e9798a3b8f97c89ef74aa (diff)
downloadlinux-6bd1b0b2dec7f654018bf6b81580a8419c172008.tar.gz
Added support for HiFiBerry DAC+
The driver is based on the HiFiBerry DAC driver. However HiFiBerry DAC+ uses a different codec chip (PCM5122), therefore a new driver is necessary.
Diffstat (limited to 'arch/arm/mach-bcm2708/bcm2708.c')
-rw-r--r--arch/arm/mach-bcm2708/bcm2708.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
index a81200edf981..5f7df9e64911 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
@@ -649,6 +649,20 @@ static struct platform_device snd_pcm5102a_codec_device = {
};
#endif
+#if defined(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DACPLUS) || defined(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DACPLUS_MODULE)
+static struct platform_device snd_rpi_hifiberry_dacplus_device = {
+ .name = "snd-rpi-hifiberry-dacplus",
+ .id = 0,
+ .num_resources = 0,
+};
+
+static struct i2c_board_info __initdata snd_pcm512x_hbdacplus_i2c_devices[] = {
+ {
+ I2C_BOARD_INFO("pcm5122", 0x4d)
+ },
+};
+#endif
+
#if defined(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DIGI) || defined(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DIGI_MODULE)
static struct platform_device snd_hifiberry_digi_device = {
.name = "snd-hifiberry-digi",
@@ -852,6 +866,11 @@ void __init bcm2708_init(void)
bcm_register_device_dt(&snd_pcm5102a_codec_device);
#endif
+#if defined(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DACPLUS) || defined(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DACPLUS_MODULE)
+ bcm_register_device_dt(&snd_rpi_hifiberry_dacplus_device);
+ i2c_register_board_info_dt(1, snd_pcm512x_hbdacplus_i2c_devices, ARRAY_SIZE(snd_pcm512x_hbdacplus_i2c_devices));
+#endif
+
#if defined(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DIGI) || defined(CONFIG_SND_BCM2708_SOC_HIFIBERRY_DIGI_MODULE)
bcm_register_device_dt(&snd_hifiberry_digi_device);
i2c_register_board_info_dt(1, snd_wm8804_i2c_devices, ARRAY_SIZE(snd_wm8804_i2c_devices));