diff options
Diffstat (limited to 'drivers/video')
-rw-r--r-- | drivers/video/omap2/dss/ti_hdmi_4xxx_ip.c | 29 | ||||
-rw-r--r-- | drivers/video/omap2/dss/ti_hdmi_4xxx_ip.h | 4 |
2 files changed, 20 insertions, 13 deletions
diff --git a/drivers/video/omap2/dss/ti_hdmi_4xxx_ip.c b/drivers/video/omap2/dss/ti_hdmi_4xxx_ip.c index f503c9d12b2f..b572101c1d03 100644 --- a/drivers/video/omap2/dss/ti_hdmi_4xxx_ip.c +++ b/drivers/video/omap2/dss/ti_hdmi_4xxx_ip.c | |||
@@ -1112,10 +1112,25 @@ void hdmi_core_audio_config(struct hdmi_ip_data *ip_data, | |||
1112 | REG_FLD_MOD(av_base, HDMI_CORE_AV_SPDIF_CTRL, | 1112 | REG_FLD_MOD(av_base, HDMI_CORE_AV_SPDIF_CTRL, |
1113 | cfg->fs_override, 1, 1); | 1113 | cfg->fs_override, 1, 1); |
1114 | 1114 | ||
1115 | /* I2S parameters */ | 1115 | /* |
1116 | REG_FLD_MOD(av_base, HDMI_CORE_AV_I2S_CHST4, | 1116 | * Set IEC-60958-3 channel status word. It is passed to the IP |
1117 | cfg->freq_sample, 3, 0); | 1117 | * just as it is received. The user of the driver is responsible |
1118 | 1118 | * for its contents. | |
1119 | */ | ||
1120 | hdmi_write_reg(av_base, HDMI_CORE_AV_I2S_CHST0, | ||
1121 | cfg->iec60958_cfg->status[0]); | ||
1122 | hdmi_write_reg(av_base, HDMI_CORE_AV_I2S_CHST1, | ||
1123 | cfg->iec60958_cfg->status[1]); | ||
1124 | hdmi_write_reg(av_base, HDMI_CORE_AV_I2S_CHST2, | ||
1125 | cfg->iec60958_cfg->status[2]); | ||
1126 | /* yes, this is correct: status[3] goes to CHST4 register */ | ||
1127 | hdmi_write_reg(av_base, HDMI_CORE_AV_I2S_CHST4, | ||
1128 | cfg->iec60958_cfg->status[3]); | ||
1129 | /* yes, this is correct: status[4] goes to CHST5 register */ | ||
1130 | hdmi_write_reg(av_base, HDMI_CORE_AV_I2S_CHST5, | ||
1131 | cfg->iec60958_cfg->status[4]); | ||
1132 | |||
1133 | /* set I2S parameters */ | ||
1119 | r = hdmi_read_reg(av_base, HDMI_CORE_AV_I2S_IN_CTRL); | 1134 | r = hdmi_read_reg(av_base, HDMI_CORE_AV_I2S_IN_CTRL); |
1120 | r = FLD_MOD(r, cfg->i2s_cfg.sck_edge_mode, 6, 6); | 1135 | r = FLD_MOD(r, cfg->i2s_cfg.sck_edge_mode, 6, 6); |
1121 | r = FLD_MOD(r, cfg->i2s_cfg.vbit, 4, 4); | 1136 | r = FLD_MOD(r, cfg->i2s_cfg.vbit, 4, 4); |
@@ -1124,12 +1139,6 @@ void hdmi_core_audio_config(struct hdmi_ip_data *ip_data, | |||
1124 | r = FLD_MOD(r, cfg->i2s_cfg.shift, 0, 0); | 1139 | r = FLD_MOD(r, cfg->i2s_cfg.shift, 0, 0); |
1125 | hdmi_write_reg(av_base, HDMI_CORE_AV_I2S_IN_CTRL, r); | 1140 | hdmi_write_reg(av_base, HDMI_CORE_AV_I2S_IN_CTRL, r); |
1126 | 1141 | ||
1127 | r = hdmi_read_reg(av_base, HDMI_CORE_AV_I2S_CHST5); | ||
1128 | r = FLD_MOD(r, cfg->freq_sample, 7, 4); | ||
1129 | r = FLD_MOD(r, cfg->i2s_cfg.word_length, 3, 1); | ||
1130 | r = FLD_MOD(r, cfg->i2s_cfg.word_max_length, 0, 0); | ||
1131 | hdmi_write_reg(av_base, HDMI_CORE_AV_I2S_CHST5, r); | ||
1132 | |||
1133 | REG_FLD_MOD(av_base, HDMI_CORE_AV_I2S_IN_LEN, | 1142 | REG_FLD_MOD(av_base, HDMI_CORE_AV_I2S_IN_LEN, |
1134 | cfg->i2s_cfg.in_length_bits, 3, 0); | 1143 | cfg->i2s_cfg.in_length_bits, 3, 0); |
1135 | 1144 | ||
diff --git a/drivers/video/omap2/dss/ti_hdmi_4xxx_ip.h b/drivers/video/omap2/dss/ti_hdmi_4xxx_ip.h index 914be3dbf71d..4510edba4406 100644 --- a/drivers/video/omap2/dss/ti_hdmi_4xxx_ip.h +++ b/drivers/video/omap2/dss/ti_hdmi_4xxx_ip.h | |||
@@ -407,8 +407,6 @@ struct hdmi_audio_dma { | |||
407 | }; | 407 | }; |
408 | 408 | ||
409 | struct hdmi_core_audio_i2s_config { | 409 | struct hdmi_core_audio_i2s_config { |
410 | u8 word_max_length; | ||
411 | u8 word_length; | ||
412 | u8 in_length_bits; | 410 | u8 in_length_bits; |
413 | u8 justification; | 411 | u8 justification; |
414 | u8 sck_edge_mode; | 412 | u8 sck_edge_mode; |
@@ -420,7 +418,7 @@ struct hdmi_core_audio_i2s_config { | |||
420 | 418 | ||
421 | struct hdmi_core_audio_config { | 419 | struct hdmi_core_audio_config { |
422 | struct hdmi_core_audio_i2s_config i2s_cfg; | 420 | struct hdmi_core_audio_i2s_config i2s_cfg; |
423 | u32 freq_sample; | 421 | struct snd_aes_iec958 *iec60958_cfg; |
424 | bool fs_override; | 422 | bool fs_override; |
425 | u32 n; | 423 | u32 n; |
426 | u32 cts; | 424 | u32 cts; |