mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-14 15:54:15 +08:00
ARM: S5PV210: Add S/PDIF platform device
This patch add S/PDIF platform device to support S/PDIF PCM audio on S5PV210. Signed-off-by: Seungwhan Youn <sw.youn@samsung.com> Acked-by: Jassi Brar <jassi.brar@samsung.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
This commit is contained in:
parent
04a4fd0ae2
commit
494edadd62
@ -293,3 +293,43 @@ struct platform_device s5pv210_device_ac97 = {
|
||||
.coherent_dma_mask = DMA_BIT_MASK(32),
|
||||
},
|
||||
};
|
||||
|
||||
/* S/PDIF Controller platform_device */
|
||||
|
||||
static int s5pv210_spdif_cfg_gpio(struct platform_device *pdev)
|
||||
{
|
||||
s3c_gpio_cfgpin_range(S5PV210_GPC1(0), 2, S3C_GPIO_SFN(3));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct resource s5pv210_spdif_resource[] = {
|
||||
[0] = {
|
||||
.start = S5PV210_PA_SPDIF,
|
||||
.end = S5PV210_PA_SPDIF + 0x100 - 1,
|
||||
.flags = IORESOURCE_MEM,
|
||||
},
|
||||
[1] = {
|
||||
.start = DMACH_SPDIF,
|
||||
.end = DMACH_SPDIF,
|
||||
.flags = IORESOURCE_DMA,
|
||||
},
|
||||
};
|
||||
|
||||
static struct s3c_audio_pdata samsung_spdif_pdata = {
|
||||
.cfg_gpio = s5pv210_spdif_cfg_gpio,
|
||||
};
|
||||
|
||||
static u64 s5pv210_spdif_dmamask = DMA_BIT_MASK(32);
|
||||
|
||||
struct platform_device s5pv210_device_spdif = {
|
||||
.name = "samsung-spdif",
|
||||
.id = -1,
|
||||
.num_resources = ARRAY_SIZE(s5pv210_spdif_resource),
|
||||
.resource = s5pv210_spdif_resource,
|
||||
.dev = {
|
||||
.platform_data = &samsung_spdif_pdata,
|
||||
.dma_mask = &s5pv210_spdif_dmamask,
|
||||
.coherent_dma_mask = DMA_BIT_MASK(32),
|
||||
},
|
||||
};
|
||||
|
@ -86,6 +86,9 @@
|
||||
#define S5PV210_PA_SDRAM (0x20000000)
|
||||
#define S5P_PA_SDRAM S5PV210_PA_SDRAM
|
||||
|
||||
/* S/PDIF */
|
||||
#define S5PV210_PA_SPDIF 0xE1100000
|
||||
|
||||
/* I2S */
|
||||
#define S5PV210_PA_IIS0 0xEEE30000
|
||||
#define S5PV210_PA_IIS1 0xE2100000
|
||||
|
@ -82,6 +82,7 @@ static struct s3c_ide_platdata smdkc110_ide_pdata __initdata = {
|
||||
static struct platform_device *smdkc110_devices[] __initdata = {
|
||||
&s5pv210_device_iis0,
|
||||
&s5pv210_device_ac97,
|
||||
&s5pv210_device_spdif,
|
||||
&s3c_device_cfcon,
|
||||
&s3c_device_i2c0,
|
||||
&s3c_device_i2c1,
|
||||
|
@ -104,6 +104,7 @@ static struct samsung_keypad_platdata smdkv210_keypad_data __initdata = {
|
||||
static struct platform_device *smdkv210_devices[] __initdata = {
|
||||
&s5pv210_device_iis0,
|
||||
&s5pv210_device_ac97,
|
||||
&s5pv210_device_spdif,
|
||||
&s3c_device_adc,
|
||||
&s3c_device_cfcon,
|
||||
&s3c_device_hsmmc0,
|
||||
|
@ -92,6 +92,7 @@ extern struct platform_device s5pv210_device_pcm2;
|
||||
extern struct platform_device s5pv210_device_iis0;
|
||||
extern struct platform_device s5pv210_device_iis1;
|
||||
extern struct platform_device s5pv210_device_iis2;
|
||||
extern struct platform_device s5pv210_device_spdif;
|
||||
|
||||
extern struct platform_device s5p6442_device_pcm0;
|
||||
extern struct platform_device s5p6442_device_pcm1;
|
||||
|
Loading…
Reference in New Issue
Block a user