drm/radeon/hdmi: separate Evergreen, update modesetting
Subsystems (2)
cover drm/radeon/hdmi: separate Evergreen, update modesetting
This patch finally separates Evergreen code and applies changes published as WIP by Alex.
Alex: I think we should add your Signed-o-b in PATCH 2, can you take a look at this?
Rafał Miłecki (3):
drm/radeon/hdmi: separate evergreen code
drm/radeon/hdmi: update modesetting
drm/radeon/hdmi: fix some coding style
drivers/gpu/drm/radeon/Makefile | 5 +- drivers/gpu/drm/radeon/atombios_encoders.c | 5 +- drivers/gpu/drm/radeon/evergreen_hdmi.c | 208 ++++++++++++++++++++++++++++ drivers/gpu/drm/radeon/r600_hdmi.c | 107 ++++++++++----- drivers/gpu/drm/radeon/radeon.h | 8 + 5 files changed, 293 insertions(+), 40 deletions(-) create mode 100644 drivers/gpu/drm/radeon/evergreen_hdmi.c
Signature · 6 lines
1.7.7 _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 1/3 drm/radeon/hdmi: separate evergreen code
--- drivers/gpu/drm/radeon/Makefile | 5 +- drivers/gpu/drm/radeon/atombios_encoders.c | 5 +- drivers/gpu/drm/radeon/evergreen_hdmi.c | 187 ++++++++++++++++++++++++++++ drivers/gpu/drm/radeon/r600_hdmi.c | 9 +-- drivers/gpu/drm/radeon/radeon.h | 8 ++ 5 files changed, 203 insertions(+), 11 deletions(-) create mode 100644 drivers/gpu/drm/radeon/evergreen_hdmi.c
drivers/gpu/drm/radeon/Makefile +3 -2
@@ -70,8 +70,9 @@ radeon-y += radeon_device.o radeon_asic.o radeon_kms.o \ r200.o radeon_legacy_tv.o r600_cs.o r600_blit.o r600_blit_shaders.o \ r600_blit_kms.o radeon_pm.o atombios_dp.o r600_audio.o r600_hdmi.o \ evergreen.o evergreen_cs.o evergreen_blit_shaders.o evergreen_blit_kms.o \ - radeon_trace_points.o ni.o cayman_blit_shaders.o atombios_encoders.o \ - radeon_semaphore.o radeon_sa.o atombios_i2c.o si.o si_blit_shaders.o + evergreen_hdmi.o radeon_trace_points.o ni.o cayman_blit_shaders.o \ + atombios_encoders.o radeon_semaphore.o radeon_sa.o atombios_i2c.o si.o \ + si_blit_shaders.o radeon-$(CONFIG_COMPAT) += radeon_ioc32.o radeon-$(CONFIG_VGA_SWITCHEROO) += radeon_atpx_handler.o
drivers/gpu/drm/radeon/atombios_encoders.c +4 -1
@@ -1926,7 +1926,10 @@ radeon_atom_encoder_mode_set(struct drm_encoder *encoder,if (atombios_get_encoder_mode (encoder) ==ATOM_ENCODER_MODE_HDMI ) {r600_hdmi_enable (encoder); -r600_hdmi_setmode (encoder, adjusted_mode); +if (ASIC_IS_DCE4 (rdev)) +evergreen_hdmi_setmode (encoder, adjusted_mode); +else +r600_hdmi_setmode (encoder, adjusted_mode); } }
drivers/gpu/drm/radeon/evergreen_hdmi.c new file +187 -0
187 lines not on this page · raw message
drivers/gpu/drm/radeon/r600_hdmi.c +1 -8
@@ -328,10 +328,7 @@ void r600_hdmi_setmode(struct drm_encoder *encoder, struct drm_display_mode *modWREG32 (HDMI0_GC + offset,0x0 );/* Send audio packets */ -if (ASIC_IS_DCE4 (rdev)) -WREG32_P (0x74fc + offset, -AFMT_AUDIO_SAMPLE_SEND , ~AFMT_AUDIO_SAMPLE_SEND ); -else if (ASIC_IS_DCE32 (rdev)) +if (ASIC_IS_DCE32 (rdev))WREG32_P (AFMT_AUDIO_PACKET_CONTROL + offset,AFMT_AUDIO_SAMPLE_SEND , ~AFMT_AUDIO_SAMPLE_SEND );else
@@ -458,10 +455,6 @@ static void r600_hdmi_assign_block(struct drm_encoder *encoder)return ; } radeon_encoder->hdmi_offset = eg_offsets[dig->dig_encoder]; -/* Temp hack for Evergreen until we split r600_hdmi.c -* Evergreen first block is 0x7030 instead of 0x7400. -*/ - radeon_encoder->hdmi_offset -=0x3d0 ; }else if (ASIC_IS_DCE3 (rdev)) { radeon_encoder->hdmi_offset = dig->dig_encoder ?DCE3_HDMI_OFFSET1 :DCE3_HDMI_OFFSET0 ;
drivers/gpu/drm/radeon/radeon.h +8 -0
@@ -1874,10 +1874,18 @@ struct radeon_hdmi_acr { }; +extern struct radeon_hdmi_acr r600_hdmi_acr (uint32_t clock); +extern void r600_hdmi_enable (struct drm_encoder *encoder);extern void r600_hdmi_disable (struct drm_encoder *encoder);extern void r600_hdmi_setmode (struct drm_encoder *encoder,struct drm_display_mode *mode); +/* +* evergreen functions used by radeon_encoder.c +*/ + +extern void evergreen_hdmi_setmode (struct drm_encoder *encoder,struct drm_display_mode *mode); +extern int ni_init_microcode (struct radeon_device *rdev);extern int ni_mc_load_microcode (struct radeon_device *rdev);
Signature · 6 lines
1.7.7 _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 2/3 drm/radeon/hdmi: update modesetting
In reply to Rafał Miłecki--- drivers/gpu/drm/radeon/evergreen_hdmi.c | 43 ++++++++++++++++++------ drivers/gpu/drm/radeon/r600_hdmi.c | 53 ++++++++++++++++++++++--------- 2 files changed, 70 insertions(+), 26 deletions(-)
drivers/gpu/drm/radeon/evergreen_hdmi.c +32 -11
@@ -158,30 +158,51 @@ void evergreen_hdmi_setmode(struct drm_encoder *encoder, struct drm_display_moder600_audio_set_clock (encoder, mode->clock); +WREG32 (HDMI_VBI_PACKET_CONTROL + offset, +HDMI_NULL_SEND );/* send null packets when required */ +WREG32 (AFMT_AUDIO_CRC_CONTROL + offset,0x1000 ); -WREG32 (HDMI_GC + offset,0x0 ); -/* Send audio packets */ -WREG32_P (AFMT_AUDIO_PACKET_CONTROL + offset, -AFMT_AUDIO_SAMPLE_SEND , ~AFMT_AUDIO_SAMPLE_SEND ); +WREG32 (HDMI_AUDIO_PACKET_CONTROL + offset, +HDMI_AUDIO_DELAY_EN (1 ) |/* set the default audio delay */ +HDMI_AUDIO_PACKETS_PER_LINE (3 ));/* should be suffient for all audio modes and small enough for all hblanks */ -WREG32 (HDMI_ACR_PACKET_CONTROL + offset,0x1000 ); +WREG32 (AFMT_AUDIO_PACKET_CONTROL + offset, +AFMT_AUDIO_SAMPLE_SEND |/* send audio packets */ +AFMT_60958_CS_UPDATE );/* allow 60958 channel status fields to be updated */ -evergreen_hdmi_update_ACR (encoder, mode->clock); +WREG32 (HDMI_ACR_PACKET_CONTROL + offset, +HDMI_ACR_AUTO_SEND |/* allow hw to sent ACR packets when required */ +HDMI_ACR_SOURCE );/* select SW CTS value */ + +WREG32 (HDMI_VBI_PACKET_CONTROL + offset, +HDMI_NULL_SEND |/* send null packets when required */ +HDMI_GC_SEND |/* send general control packets */ +HDMI_GC_CONT );/* send general control packets every frame */ + +WREG32 (HDMI_INFOFRAME_CONTROL0 + offset, +HDMI_AVI_INFO_SEND |/* enable AVI info frames */ +HDMI_AVI_INFO_CONT |/* send AVI info frames every frame/field */ +HDMI_AUDIO_INFO_SEND |/* enable audio info frames (frames won't be set until audio is enabled) */ +HDMI_AUDIO_INFO_CONT );/* required for audio info values to be updated */ + +WREG32 (AFMT_INFOFRAME_CONTROL0 + offset, +AFMT_AUDIO_INFO_UPDATE );/* required for audio info values to be updated */ -WREG32 (HDMI_INFOFRAME_CONTROL0 + offset,0x13 ); +WREG32 (HDMI_INFOFRAME_CONTROL1 + offset, +HDMI_AVI_INFO_LINE (2 ) |/* anything other than 0 */ +HDMI_AUDIO_INFO_LINE (2 ));/* anything other than 0 */ -WREG32 (HDMI_INFOFRAME_CONTROL1 + offset,0x202 ); +WREG32 (HDMI_GC + offset,0 );/* unset HDMI_GC_AVMUTE */ evergreen_hdmi_videoinfoframe (encoder,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ); +evergreen_hdmi_update_ACR (encoder, mode->clock); +/* it's unknown what these bits do excatly, but it's indeed quite useful for debugging */ WREG32 (AFMT_RAMP_CONTROL0 + offset,0x00FFFFFF );WREG32 (AFMT_RAMP_CONTROL1 + offset,0x007FFFFF );WREG32 (AFMT_RAMP_CONTROL2 + offset,0x00000001 );WREG32 (AFMT_RAMP_CONTROL3 + offset,0x00000001 ); - -/* audio packets per line, does anyone know how to calc this ? */ -WREG32_P (AFMT_AUDIO_PACKET_CONTROL + offset,0x00040000 , ~0x001F0000 ); }
drivers/gpu/drm/radeon/r600_hdmi.c +38 -15
75 lines not on this page · raw message
Signature · 6 lines
1.7.7 _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [next][PATCH 2/3] drm/radeon/hdmi: update modesetting
2012/5/6 Rafał Miłecki <[email protected]>:
Quoted 6 lines
+ WREG32(HDMI0_AUDIO_PACKET_CONTROL + offset,
+ HDMI0_AUDIO_SAMPLE_SEND | /* send audio packets */
+ HDMI0_AUDIO_DELAY_EN(1) | /* default audio delay */
+ HDMI0_AUDIO_SEND_MAX_PACKETS | /* send NULL packets if no audio is available */
+ HDMI0_AUDIO_PACKETS_PER_LINE(3) | /* should be suffient for all audio modes and small enough for all hblanks */
+ HDMI0_60958_CS_UPDATE); /* allow 60958 channel status fields to be updated */
Alex, I've problem with the above code. I've arrived to my parent's house and I noticed audio doesn't work anymore with Onkyo TX-SR605. The problem is caused by:HDMI0_AUDIO_SEND_MAX_PACKETS
Setting this bit doesn't seem to be problem for my Denon 1912, so I didn't notice that earlier. Before the rewrite modesetting we weren't set that bit, so it's actually a regression for my case with Onkyo.
Can you say something more about this bit? My only solution is to just don't set it, but maybe there's a better one?
Signature · 5 lines
Rafał _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [next][PATCH 2/3] drm/radeon/hdmi: update modesetting
2012/5/26 Rafał Miłecki <[email protected]>:
Quoted 13 lines
2012/5/6 Rafał Miłecki <[email protected]>:
Quoted 6 lines
+ WREG32(HDMI0_AUDIO_PACKET_CONTROL + offset,
+ HDMI0_AUDIO_SAMPLE_SEND | /* send audio packets */
+ HDMI0_AUDIO_DELAY_EN(1) | /* default audio delay */
+ HDMI0_AUDIO_SEND_MAX_PACKETS | /* send NULL packets if no audio is available */
+ HDMI0_AUDIO_PACKETS_PER_LINE(3) | /* should be suffient for all audio modes and small enough for all hblanks */
+ HDMI0_60958_CS_UPDATE); /* allow 60958 channel status fields to be updated */Alex, I've problem with the above code. I've arrived to my parent's house and I noticed audio doesn't work anymore with Onkyo TX-SR605. The problem is caused by:
HDMI0_AUDIO_SEND_MAX_PACKETS
Quoted 6 lines
Setting this bit doesn't seem to be problem for my Denon 1912, so I didn't notice that earlier. Before the rewrite modesetting we weren't set that bit, so it's actually a regression for my case with Onkyo.
Can you say something more about this bit? My only solution is to just don't set it, but maybe there's a better one?
The same happens when I connect my RV620 directly to the TV (not using Onkyo between as audio receiver). My TV is Sony BRAVIA KDL-52X3500. Setting bit HDMI0_AUDIO_SEND_MAX_PACKETS also causes no audio in TV.
Signature · 5 lines
Rafał _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [next][PATCH 2/3] drm/radeon/hdmi: update modesetting
2012/5/26 Rafał Miłecki <[email protected]>:
Quoted 18 lines
2012/5/26 Rafał Miłecki <[email protected]>:
Quoted 17 lines
2012/5/6 Rafał Miłecki <[email protected]>:
Quoted 6 lines
+ WREG32(HDMI0_AUDIO_PACKET_CONTROL + offset,
+ HDMI0_AUDIO_SAMPLE_SEND | /* send audio packets */
+ HDMI0_AUDIO_DELAY_EN(1) | /* default audio delay */
+ HDMI0_AUDIO_SEND_MAX_PACKETS | /* send NULL packets if no audio is available */
+ HDMI0_AUDIO_PACKETS_PER_LINE(3) | /* should be suffient for all audio modes and small enough for all hblanks */
+ HDMI0_60958_CS_UPDATE); /* allow 60958 channel status fields to be updated */Alex, I've problem with the above code. I've arrived to my parent's house and I noticed audio doesn't work anymore with Onkyo TX-SR605. The problem is caused by:
HDMI0_AUDIO_SEND_MAX_PACKETSSetting this bit doesn't seem to be problem for my Denon 1912, so I didn't notice that earlier. Before the rewrite modesetting we weren't set that bit, so it's actually a regression for my case with Onkyo.
Quoted 6 lines
Quoted 2 lines
Can you say something more about this bit? My only solution is to just don't set it, but maybe there's a better one?
The same happens when I connect my RV620 directly to the TV (not using Onkyo between as audio receiver). My TV is Sony BRAVIA KDL-52X3500. Setting bit
HDMI0_AUDIO_SEND_MAX_PACKETSalso causes no audio in TV.
Last e-mail for today (well, it's only 25 minutes left here ;) ). I've decided to give fglrx a chance (12.4).
1) RV620 connected directly to Sony BRAVIA KDL-52X3500
[ 234.399] (WW) fglrx(0): Incorrect HDMI dongle found, HDMI audio disabled.
I couldn't play anything.
2) RV620 connected to Onkyo TX-SR605
Audio playing, but fglrx set 0x7408 to:0x10020011
so it seems fglrx isn't usingHDMI0_AUDIO_SEND_MAX_PACKETS == 0x100
Setting that bit while using fglrx broke audio.
I did one more test with a different TV: Sony BRAVIA KDL-40S40xx. The results are the same. fglrx sets 0x7408 to: 0x10020011 (so HDMI0_AUDIO_SEND_MAX_PACKETS is not set). Setting that bit manually (while using fglrx) breaks audio.
It just seems to me we shouldn't set that bit at all...
Signature · 5 lines
Rafał _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [next][PATCH 2/3] drm/radeon/hdmi: update modesetting
Quoted 41 lines · Rafał Miłecki
2012/5/26 Rafał Miłecki <[email protected]>:
Quoted 18 lines
2012/5/26 Rafał Miłecki <[email protected]>:
Quoted 17 lines
2012/5/6 Rafał Miłecki <[email protected]>:
Quoted 6 lines
+ WREG32(HDMI0_AUDIO_PACKET_CONTROL + offset,
+ HDMI0_AUDIO_SAMPLE_SEND | /* send audio packets */
+ HDMI0_AUDIO_DELAY_EN(1) | /* default audio delay */
+ HDMI0_AUDIO_SEND_MAX_PACKETS | /* send NULL packets if no audio is available */
+ HDMI0_AUDIO_PACKETS_PER_LINE(3) | /* should be suffient for all audio modes and small enough for all hblanks */
+ HDMI0_60958_CS_UPDATE); /* allow 60958 channel status fields to be updated */Alex, I've problem with the above code. I've arrived to my parent's house and I noticed audio doesn't work anymore with Onkyo TX-SR605. The problem is caused by:
HDMI0_AUDIO_SEND_MAX_PACKETSSetting this bit doesn't seem to be problem for my Denon 1912, so I didn't notice that earlier. Before the rewrite modesetting we weren't set that bit, so it's actually a regression for my case with Onkyo.
Quoted 6 lines
Quoted 2 lines
Can you say something more about this bit? My only solution is to just don't set it, but maybe there's a better one?
The same happens when I connect my RV620 directly to the TV (not using Onkyo between as audio receiver). My TV is Sony BRAVIA KDL-52X3500. Setting bit
HDMI0_AUDIO_SEND_MAX_PACKETSalso causes no audio in TV.Last e-mail for today (well, it's only 25 minutes left here ;) ). I've decided to give fglrx a chance (12.4).
1) RV620 connected directly to Sony BRAVIA KDL-52X3500
[ 234.399] (WW) fglrx(0): Incorrect HDMI dongle found, HDMI audio disabled. I couldn't play anything.2) RV620 connected to Onkyo TX-SR605
Audio playing, but fglrx set0x7408to:0x10020011
so it seems fglrx isn't usingHDMI0_AUDIO_SEND_MAX_PACKETS==0x100
Setting that bit while using fglrx broke audio.
Quoted 7 lines
I did one more test with a different TV: Sony BRAVIA KDL-40S40xx. The results are the same. fglrx sets
0x7408to:0x10020011(soHDMI0_AUDIO_SEND_MAX_PACKETSis not set). Setting that bit manually (while using fglrx) breaks audio.It just seems to me we shouldn't set that bit at all...
If it breaks things, might as well not set it. I only set it because some of the documents said it needed to be set. That bit causes the hw to send null packets if audio data is not available. Maybe some receivers don't deal well with null packets. Might as well disable it for now and I can ask the display guys more about it next week.
Alex
Quoted 3 lines
--
Rafał
Re: [next][PATCH 2/3] drm/radeon/hdmi: update modesetting
2012/5/27 Alex Deucher <[email protected]>:
Quoted 48 lines · Rafał Miłecki
Quoted 47 lines
2012/5/26 Rafał Miłecki <[email protected]>:
Quoted 18 lines
2012/5/26 Rafał Miłecki <[email protected]>:
Quoted 17 lines
2012/5/6 Rafał Miłecki <[email protected]>:
Quoted 6 lines
+ WREG32(HDMI0_AUDIO_PACKET_CONTROL + offset,
+ HDMI0_AUDIO_SAMPLE_SEND | /* send audio packets */
+ HDMI0_AUDIO_DELAY_EN(1) | /* default audio delay */
+ HDMI0_AUDIO_SEND_MAX_PACKETS | /* send NULL packets if no audio is available */
+ HDMI0_AUDIO_PACKETS_PER_LINE(3) | /* should be suffient for all audio modes and small enough for all hblanks */
+ HDMI0_60958_CS_UPDATE); /* allow 60958 channel status fields to be updated */Alex, I've problem with the above code. I've arrived to my parent's house and I noticed audio doesn't work anymore with Onkyo TX-SR605. The problem is caused by:
HDMI0_AUDIO_SEND_MAX_PACKETSSetting this bit doesn't seem to be problem for my Denon 1912, so I didn't notice that earlier. Before the rewrite modesetting we weren't set that bit, so it's actually a regression for my case with Onkyo.
Quoted 6 lines
Quoted 2 lines
Can you say something more about this bit? My only solution is to just don't set it, but maybe there's a better one?
The same happens when I connect my RV620 directly to the TV (not using Onkyo between as audio receiver). My TV is Sony BRAVIA KDL-52X3500. Setting bit
HDMI0_AUDIO_SEND_MAX_PACKETSalso causes no audio in TV.Last e-mail for today (well, it's only 25 minutes left here ;) ). I've decided to give fglrx a chance (12.4).
1) RV620 connected directly to Sony BRAVIA KDL-52X3500
[ 234.399] (WW) fglrx(0): Incorrect HDMI dongle found, HDMI audio disabled. I couldn't play anything.2) RV620 connected to Onkyo TX-SR605
Audio playing, but fglrx set0x7408to:0x10020011
so it seems fglrx isn't usingHDMI0_AUDIO_SEND_MAX_PACKETS==0x100
Setting that bit while using fglrx broke audio.I did one more test with a different TV: Sony BRAVIA KDL-40S40xx. The results are the same. fglrx sets
0x7408to:0x10020011(soHDMI0_AUDIO_SEND_MAX_PACKETSis not set). Setting that bit manually (while using fglrx) breaks audio.
Quoted 7 lines
Quoted 1 line
It just seems to me we shouldn't set that bit at all...
If it breaks things, might as well not set it. I only set it because some of the documents said it needed to be set. That bit causes the hw to send null packets if audio data is not available. Maybe some receivers don't deal well with null packets. Might as well disable it for now and I can ask the display guys more about it next week.
Thanks for answer. It seems this bit works somehow differently than your docs says.
I could understand NULL packets breaking display when not playing audio. However this bit broke audio totally, even when feeding GPU with audio, my receivers still couldn't play anything.
I've just arrived my home and tested my home configuration: Denon 1912
+ Sony UE55D7000. This set handles audio correctly even when setting HDMI0_AUDIO_SEND_MAX_PACKETS. However dumping regs while using fglrx has showed this bit is not being set (by fglrx).
So there isn't any magical detection of HDMI0_AUDIO_SEND_MAX_PACKETS receiver-acceptance in fglrx code. fglrx just doesn't set HDMI0_AUDIO_SEND_MAX_PACKETS no matter if this would work with the attached receivers. Maybe fglrx programmers detected problem with that bit/feature and disabled it, ignoring specs at this single point.
Signature · 5 lines
Rafał _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 3/3 drm/radeon/hdmi: fix some coding style
In reply to Rafał MiłeckiUse defined macros by the way.
--- drivers/gpu/drm/radeon/r600_hdmi.c | 47 ++++++++++++++++++++++++----------- 1 files changed, 32 insertions(+), 15 deletions(-)
drivers/gpu/drm/radeon/r600_hdmi.c +32 -15
@@ -417,34 +417,51 @@ void r600_hdmi_update_audio_settings(struct drm_encoder *encoder)if (status_bits &AUDIO_STATUS_EMPHASIS ) iec |=1 <<3 ; - iec |= category_code <<8 ; + iec |=HDMI0_60958_CS_CATEGORY_CODE (category_code);switch (rate) { -case 32000 : iec |=0x3 <<24 ;break ; -case 44100 : iec |=0x0 <<24 ;break ; -case 88200 : iec |=0x8 <<24 ;break ; -case 176400 : iec |=0xc <<24 ;break ; -case 48000 : iec |=0x2 <<24 ;break ; -case 96000 : iec |=0xa <<24 ;break ; -case 192000 : iec |=0xe <<24 ;break ; +case 32000 : + iec |=HDMI0_60958_CS_SAMPLING_FREQUENCY (0x3 ); +break ; +case 44100 : + iec |=HDMI0_60958_CS_SAMPLING_FREQUENCY (0x0 ); +break ; +case 48000 : + iec |=HDMI0_60958_CS_SAMPLING_FREQUENCY (0x2 ); +break ; +case 88200 : + iec |=HDMI0_60958_CS_SAMPLING_FREQUENCY (0x8 ); +break ; +case 96000 : + iec |=HDMI0_60958_CS_SAMPLING_FREQUENCY (0xa ); +break ; +case 176400 : + iec |=HDMI0_60958_CS_SAMPLING_FREQUENCY (0xc ); +break ; +case 192000 : + iec |=HDMI0_60958_CS_SAMPLING_FREQUENCY (0xe ); +break ; }WREG32 (HDMI0_60958_0 + offset, iec); iec =0 ;switch (bps) { -case 16 : iec |=0x2 ;break ; -case 20 : iec |=0x3 ;break ; -case 24 : iec |=0xb ;break ; +case 16 : + iec |=HDMI0_60958_CS_WORD_LENGTH (0x2 ); +break ; +case 20 : + iec |=HDMI0_60958_CS_WORD_LENGTH (0x3 ); +break ; +case 24 : + iec |=HDMI0_60958_CS_WORD_LENGTH (0xb ); +break ; }if (status_bits &AUDIO_STATUS_V ) iec |=0x5 <<16 ; -WREG32_P (HDMI0_60958_1 + offset, iec, ~0x5000f ); -/* 0x021 or 0x031 sets the audio frame length */ -WREG32 (HDMI0_VBI_PACKET_CONTROL + offset,0x31 ); -r600_hdmi_audioinfoframe (encoder, channels-1 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ); +r600_hdmi_audioinfoframe (encoder, channels -1 ,0 ,0 ,0 ,0 ,0 ,0 ,0 );r600_hdmi_audio_workaround (encoder); }
Signature · 6 lines
1.7.7 _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel