Skip to contentSkip to conversation

drm/radeon: add audio support for DCE6/8 GPUs (v10)

PATCH In review Alex Deucher 2 participants 4 messages Aug 14, 2013 – Aug 15, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 3/3 drm/radeon: add audio support for DCE6/8 GPUs (v10)

Similar to DCE4/5, but supports multiple audio pins which can be assigned per afmt block.

v2: rework the driver to handle more than one audio pin.
v3: try different dto reg
v4: properly program dto
v5 (ck): change dto programming order
v6: program speaker allocation block
v7: rebase
v8: rebase on Rafał's changes
v9: integrated Rafał's comments, update to latest
drm_edid_to_speaker_allocation API
v10: add missing line break in error message

---
 drivers/gpu/drm/radeon/Makefile            |   2 +-
 drivers/gpu/drm/radeon/atombios_encoders.c |  11 +-
 drivers/gpu/drm/radeon/cik.c               |   5 +
 drivers/gpu/drm/radeon/dce6_afmt.c         | 250 +++++++++++++++++++++++++++++
 drivers/gpu/drm/radeon/evergreen_hdmi.c    |  54 +++++--
 drivers/gpu/drm/radeon/ni.c                |  17 +-
 drivers/gpu/drm/radeon/r600_audio.c        |  58 ++++---
 drivers/gpu/drm/radeon/r600_hdmi.c         |   7 +-
 drivers/gpu/drm/radeon/radeon.h            |  18 ++-
 drivers/gpu/drm/radeon/radeon_asic.c       |   8 +
 drivers/gpu/drm/radeon/radeon_asic.h       |   4 +-
 drivers/gpu/drm/radeon/radeon_display.c    |  13 +-
 drivers/gpu/drm/radeon/radeon_mode.h       |   3 +-
 drivers/gpu/drm/radeon/si.c                |   5 +
 drivers/gpu/drm/radeon/sid.h               |  59 +++++++
 15 files changed, 452 insertions(+), 62 deletions(-)
 create mode 100644 drivers/gpu/drm/radeon/dce6_afmt.c
drivers/gpu/drm/radeon/Makefile +1 -1
index da2a8e9..306364a 100644
@@ -80,7 +80,7 @@ radeon-y += radeon_device.o radeon_asic.o radeon_kms.o \
 	r600_dpm.o rs780_dpm.o rv6xx_dpm.o rv770_dpm.o rv730_dpm.o rv740_dpm.o \
 	rv770_smc.o cypress_dpm.o btc_dpm.o sumo_dpm.o sumo_smc.o trinity_dpm.o \
 	trinity_smc.o ni_dpm.o si_smc.o si_dpm.o kv_smc.o kv_dpm.o ci_smc.o \
-	ci_dpm.o
+	ci_dpm.o dce6_afmt.o
 
 # add async DMA block
 radeon-y += \
drivers/gpu/drm/radeon/atombios_encoders.c +3 -8
index 092275d..dfac796 100644
@@ -682,8 +682,6 @@ atombios_digital_setup(struct drm_encoder *encoder, int action)
 int
 atombios_get_encoder_mode(struct drm_encoder *encoder)
 {
-	struct drm_device *dev = encoder->dev;
-	struct radeon_device *rdev = dev->dev_private;
 	struct radeon_encoder *radeon_encoder = to_radeon_encoder(encoder);
 	struct drm_connector *connector;
 	struct radeon_connector *radeon_connector;
@@ -710,8 +708,7 @@ atombios_get_encoder_mode(struct drm_encoder *encoder)
 	case DRM_MODE_CONNECTOR_DVII:
 	case DRM_MODE_CONNECTOR_HDMIB: /* HDMI-B is basically DL-DVI; analog works fine */
 		if (drm_detect_hdmi_monitor(radeon_connector->edid) &&
-		    radeon_audio &&
-		    !ASIC_IS_DCE6(rdev)) /* remove once we support DCE6 */
+		    radeon_audio)
 			return ATOM_ENCODER_MODE_HDMI;
 		else if (radeon_connector->use_digital)
 			return ATOM_ENCODER_MODE_DVI;
@@ -722,8 +719,7 @@ atombios_get_encoder_mode(struct drm_encoder *encoder)
 	case DRM_MODE_CONNECTOR_HDMIA:
 	default:
 		if (drm_detect_hdmi_monitor(radeon_connector->edid) &&
-		    radeon_audio &&
-		    !ASIC_IS_DCE6(rdev)) /* remove once we support DCE6 */
+		    radeon_audio)
 			return ATOM_ENCODER_MODE_HDMI;
 		else
 			return ATOM_ENCODER_MODE_DVI;
@@ -737,8 +733,7 @@ atombios_get_encoder_mode(struct drm_encoder *encoder)
 		    (dig_connector->dp_sink_type == CONNECTOR_OBJECT_ID_eDP))
 			return ATOM_ENCODER_MODE_DP;
 		else if (drm_detect_hdmi_monitor(radeon_connector->edid) &&
-			 radeon_audio &&
-			 !ASIC_IS_DCE6(rdev)) /* remove once we support DCE6 */
+			 radeon_audio)
 			return ATOM_ENCODER_MODE_HDMI;
 		else
 			return ATOM_ENCODER_MODE_DVI;
drivers/gpu/drm/radeon/cik.c +5 -0
index 01fd886..c2f78dc 100644
@@ -7093,6 +7093,10 @@ static int cik_startup(struct radeon_device *rdev)
 		return r;
 	}
 
+	r = dce6_audio_init(rdev);
+	if (r)
+		return r;
+
 	return 0;
 }
 
@@ -7138,6 +7142,7 @@ int cik_resume(struct radeon_device *rdev)
  */
 int cik_suspend(struct radeon_device *rdev)
 {
+	dce6_audio_fini(rdev);
 	radeon_vm_manager_fini(rdev);
 	cik_cp_enable(rdev, false);
 	cik_sdma_enable(rdev, false);
drivers/gpu/drm/radeon/dce6_afmt.c new file +250 -0

250 lines not on this page · raw message

drivers/gpu/drm/radeon/evergreen_hdmi.c +39 -15

86 lines not on this page · raw message

drivers/gpu/drm/radeon/ni.c +13 -4
index 2db8ce0..69499ff 100644
@@ -2027,9 +2027,15 @@ static int cayman_startup(struct radeon_device *rdev)
 		return r;
 	}
 
-	r = r600_audio_init(rdev);
-	if (r)
-		return r;
+	if (ASIC_IS_DCE6(rdev)) {
+		r = dce6_audio_init(rdev);
+		if (r)
+			return r;
+	} else {
+		r = r600_audio_init(rdev);
+		if (r)
+			return r;
+	}
 
 	return 0;
 }
@@ -2060,7 +2066,10 @@ int cayman_resume(struct radeon_device *rdev)
 
 int cayman_suspend(struct radeon_device *rdev)
 {
-	r600_audio_fini(rdev);
+	if (ASIC_IS_DCE6(rdev))
+		dce6_audio_fini(rdev);
+	else
+		r600_audio_fini(rdev);
 	radeon_vm_manager_fini(rdev);
 	cayman_cp_enable(rdev, false);
 	cayman_dma_stop(rdev);
drivers/gpu/drm/radeon/r600_audio.c +34 -24

103 lines not on this page · raw message

drivers/gpu/drm/radeon/r600_hdmi.c +6 -1
index f264df5..e1dec13 100644
@@ -382,7 +382,7 @@ void r600_hdmi_update_audio_settings(struct drm_encoder *encoder)
 	struct radeon_device *rdev = dev->dev_private;
 	struct radeon_encoder *radeon_encoder = to_radeon_encoder(encoder);
 	struct radeon_encoder_atom_dig *dig = radeon_encoder->enc_priv;
-	struct r600_audio audio = r600_audio_status(rdev);
+	struct r600_audio_pin audio = r600_audio_status(rdev);
 	uint8_t buffer[HDMI_INFOFRAME_HEADER_SIZE + HDMI_AUDIO_INFOFRAME_SIZE];
 	struct hdmi_audio_infoframe frame;
 	uint32_t offset;
@@ -491,6 +491,11 @@ void r600_hdmi_enable(struct drm_encoder *encoder, bool enable)
 	if (!enable && !dig->afmt->enabled)
 		return;
 
+	if (enable)
+		dig->afmt->pin = r600_audio_get_pin(rdev);
+	else
+		dig->afmt->pin = NULL;
+
 	/* Older chipsets require setting HDMI and routing manually */
 	if (!ASIC_IS_DCE3(rdev)) {
 		if (enable)
drivers/gpu/drm/radeon/radeon.h +14 -4
index 93bef23..9fc9e71 100644
@@ -728,7 +728,7 @@ union radeon_irq_stat_regs {
 
 #define RADEON_MAX_HPD_PINS 6
 #define RADEON_MAX_CRTCS 6
-#define RADEON_MAX_AFMT_BLOCKS 6
+#define RADEON_MAX_AFMT_BLOCKS 7
 
 struct radeon_irq {
 	bool				installed;
@@ -1569,12 +1569,21 @@ int radeon_uvd_calc_upll_dividers(struct radeon_device *rdev,
 int radeon_uvd_send_upll_ctlreq(struct radeon_device *rdev,
                                 unsigned cg_upll_func_cntl);
 
-struct r600_audio {
+struct r600_audio_pin {
 	int			channels;
 	int			rate;
 	int			bits_per_sample;
 	u8			status_bits;
 	u8			category_code;
+	u32			offset;
+	bool			connected;
+	u32			id;
+};
+
+struct r600_audio {
+	bool enabled;
+	struct r600_audio_pin pin[RADEON_MAX_AFMT_BLOCKS];
+	int num_pins;
 };
 
 /*
@@ -2160,9 +2169,8 @@ struct radeon_device {
 	struct work_struct reset_work;
 	int num_crtc; /* number of crtcs */
 	struct mutex dc_hw_i2c_mutex; /* display controller hw i2c mutex */
-	bool audio_enabled;
 	bool has_uvd;
-	struct r600_audio audio_status; /* audio stuff */
+	struct r600_audio audio; /* audio stuff */
 	struct notifier_block acpi_nb;
 	/* only one userspace can use Hyperz features or CMASK at a time */
 	struct drm_file *hyperz_filp;
@@ -2629,6 +2637,8 @@ int radeon_vm_bo_rmv(struct radeon_device *rdev,
 
 /* audio */
 void r600_audio_update_hdmi(struct work_struct *work);
+struct r600_audio_pin *r600_audio_get_pin(struct radeon_device *rdev);
+struct r600_audio_pin *dce6_audio_get_pin(struct radeon_device *rdev);
 
 /*
  * R600 vram scratch functions
drivers/gpu/drm/radeon/radeon_asic.c +8 -0
index 41e9f32..18a65a0 100644
@@ -1739,6 +1739,8 @@ static struct radeon_asic trinity_asic = {
 		.wait_for_vblank = &dce4_wait_for_vblank,
 		.set_backlight_level = &atombios_set_backlight_level,
 		.get_backlight_level = &atombios_get_backlight_level,
+		.hdmi_enable = &evergreen_hdmi_enable,
+		.hdmi_setmode = &evergreen_hdmi_setmode,
 	},
 	.copy = {
 		.blit = &r600_copy_cpdma,
@@ -1867,6 +1869,8 @@ static struct radeon_asic si_asic = {
 		.wait_for_vblank = &dce4_wait_for_vblank,
 		.set_backlight_level = &atombios_set_backlight_level,
 		.get_backlight_level = &atombios_get_backlight_level,
+		.hdmi_enable = &evergreen_hdmi_enable,
+		.hdmi_setmode = &evergreen_hdmi_setmode,
 	},
 	.copy = {
 		.blit = NULL,
@@ -2009,6 +2013,8 @@ static struct radeon_asic ci_asic = {
 		.bandwidth_update = &dce8_bandwidth_update,
 		.get_vblank_counter = &evergreen_get_vblank_counter,
 		.wait_for_vblank = &dce4_wait_for_vblank,
+		.hdmi_enable = &evergreen_hdmi_enable,
+		.hdmi_setmode = &evergreen_hdmi_setmode,
 	},
 	.copy = {
 		.blit = NULL,
@@ -2107,6 +2113,8 @@ static struct radeon_asic kv_asic = {
 		.bandwidth_update = &dce8_bandwidth_update,
 		.get_vblank_counter = &evergreen_get_vblank_counter,
 		.wait_for_vblank = &dce4_wait_for_vblank,
+		.hdmi_enable = &evergreen_hdmi_enable,
+		.hdmi_setmode = &evergreen_hdmi_setmode,
 	},
 	.copy = {
 		.blit = NULL,
drivers/gpu/drm/radeon/radeon_asic.h +3 -1
index e69f00a..818bbe6 100644
@@ -379,7 +379,7 @@ void r600_disable_interrupts(struct radeon_device *rdev);
 void r600_rlc_stop(struct radeon_device *rdev);
 /* r600 audio */
 int r600_audio_init(struct radeon_device *rdev);
-struct r600_audio r600_audio_status(struct radeon_device *rdev);
+struct r600_audio_pin r600_audio_status(struct radeon_device *rdev);
 void r600_audio_fini(struct radeon_device *rdev);
 int r600_hdmi_buffer_status_changed(struct drm_encoder *encoder);
 void r600_hdmi_update_audio_settings(struct drm_encoder *encoder);
@@ -628,6 +628,8 @@ int trinity_dpm_force_performance_level(struct radeon_device *rdev,
 
 /* DCE6 - SI */
 void dce6_bandwidth_update(struct radeon_device *rdev);
+int dce6_audio_init(struct radeon_device *rdev);
+void dce6_audio_fini(struct radeon_device *rdev);
 
 /*
  * si
drivers/gpu/drm/radeon/radeon_display.c +10 -3
index 31d9fbe..af9cd6a 100644
@@ -1254,8 +1254,8 @@ static void radeon_afmt_init(struct radeon_device *rdev)
 	for (i = 0; i < RADEON_MAX_AFMT_BLOCKS; i++)
 		rdev->mode_info.afmt[i] = NULL;
 
-	if (ASIC_IS_DCE6(rdev)) {
-		/* todo */
+	if (ASIC_IS_NODCE(rdev)) {
+		/* nothing to do */
 	} else if (ASIC_IS_DCE4(rdev)) {
 		static uint32_t eg_offsets[] = {
 			EVERGREEN_CRTC0_REGISTER_OFFSET,
@@ -1264,12 +1264,19 @@ static void radeon_afmt_init(struct radeon_device *rdev)
 			EVERGREEN_CRTC3_REGISTER_OFFSET,
 			EVERGREEN_CRTC4_REGISTER_OFFSET,
 			EVERGREEN_CRTC5_REGISTER_OFFSET,
+			0x13830 - 0x7030,
 		};
 		int num_afmt;
 
+		/* DCE8 has 7 audio blocks tied to DIG encoders */
+		/* DCE6 has 6 audio blocks tied to DIG encoders */
 		/* DCE4/5 has 6 audio blocks tied to DIG encoders */
 		/* DCE4.1 has 2 audio blocks tied to DIG encoders */
-		if (ASIC_IS_DCE5(rdev))
+		if (ASIC_IS_DCE8(rdev))
+			num_afmt = 7;
+		else if (ASIC_IS_DCE6(rdev))
+			num_afmt = 6;
+		else if (ASIC_IS_DCE5(rdev))
 			num_afmt = 6;
 		else if (ASIC_IS_DCE41(rdev))
 			num_afmt = 2;
drivers/gpu/drm/radeon/radeon_mode.h +2 -1
index 8296632..d908d8d 100644
@@ -225,6 +225,7 @@ struct radeon_afmt {
 	int offset;
 	bool last_buffer_filled_status;
 	int id;
+	struct r600_audio_pin *pin;
 };
 
 struct radeon_mode_info {
@@ -233,7 +234,7 @@ struct radeon_mode_info {
 	enum radeon_connector_table connector_table;
 	bool mode_config_initialized;
 	struct radeon_crtc *crtcs[6];
-	struct radeon_afmt *afmt[6];
+	struct radeon_afmt *afmt[7];
 	/* DVI-I properties */
 	struct drm_property *coherent_mode_property;
 	/* DAC enable load detect */
drivers/gpu/drm/radeon/si.c +5 -0
index ca37aa1..219ca35 100644
@@ -6361,6 +6361,10 @@ static int si_startup(struct radeon_device *rdev)
 		return r;
 	}
 
+	r = dce6_audio_init(rdev);
+	if (r)
+		return r;
+
 	return 0;
 }
 
@@ -6392,6 +6396,7 @@ int si_resume(struct radeon_device *rdev)
 
 int si_suspend(struct radeon_device *rdev)
 {
+	dce6_audio_fini(rdev);
 	radeon_vm_manager_fini(rdev);
 	si_cp_enable(rdev, false);
 	cayman_dma_stop(rdev);
drivers/gpu/drm/radeon/sid.h +59 -0

71 lines not on this page · raw message

Signature · 6 lines
1.8.3.1

_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
Acked-by on v1 3/3
#1 lore raw

2013/8/14 Alex Deucher <[email protected]>:

Quoted 2 lines

Similar to DCE4/5, but supports multiple audio pins which can be assigned per afmt block.

Tested successfully on my HD7750.

drivers/gpu/drm/radeon/r600_audio.c void r600_audio_update_hdmi(struct work_struct *work) · line 150

Quoted 6 lines
drivers/gpu/drm/radeon/r600_audio.c +3 -1
+static void r600_audio_enable(struct radeon_device *rdev,
+                             struct r600_audio_pin *pin,
+                             bool enable)
 {
        u32 value = 0;
-       DRM_INFO("%s audio support\n", enable ? "Enabling" : "Disabling");

Whoops, that confused me at the beginning. Don't you think it's nice to know from somebody's dmesg if he uses radeon.audio or now? For debugging purposes.

drivers/gpu/drm/radeon/sid.h line 649

Quoted 6 lines
drivers/gpu/drm/radeon/sid.h +6 -0
+#define AZ_F0_CODEC_PIN_CONTROL_CHANNEL_SPEAKER          0x25
+#define                SPEAKER_ALLOCATION(x)                   (((x) & 0x7f) << 0)
+#define                SPEAKER_ALLOCATION_MASK                 (0x7f << 0)
+#define                SPEAKER_ALLOCATION_SHIFT                0
+#define                HDMI_CONNECTION                         (1 << 16)
+#define                DP_CONNECTION                           (1 << 17)

Could you share a meaning of 0x00c00000 bit? I noticed it's set when fglrx reads this register:
WREG32(0x00005e00, 0x00000025);
RREG32(0x00005e04); -> 0x00c00000

WREG32(0x00005e00, 0x00000125);
WREG32(0x00005e04, 0x00c1005f);

but it's not set with radeon reads it for the first time. Maybe fglrx sets that at some other stage (earlier)?

Signature · 5 lines
Rafał
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
#2 lore raw
In reply to Alex Deucher

2013/8/14 Alex Deucher <[email protected]>:

Quoted 19 lines
drivers/gpu/drm/radeon/dce6_afmt.c new file +19 -0
+       /* program the speaker allocation */
+       tmp = RREG32_ENDPOINT(offset, AZ_F0_CODEC_PIN_CONTROL_CHANNEL_SPEAKER);
+       tmp &= ~(DP_CONNECTION | SPEAKER_ALLOCATION_MASK);
+       /* set HDMI mode */
+       tmp |= HDMI_CONNECTION;
+       if (sadb_count)
+               tmp |= SPEAKER_ALLOCATION(sadb[0]);
+       else
+               tmp |= SPEAKER_ALLOCATION(5); /* stereo */
+       WREG32_ENDPOINT(offset, AZ_F0_CODEC_PIN_CONTROL_CHANNEL_SPEAKER, tmp);
+
+       for (i = 0; i < ARRAY_SIZE(eld_reg_to_type); i++) {
+               u32 value = 0;
+               int j;
+
+               for (j = 0; j < sad_count; j++) {
+                       struct cea_sad *sad = &sads[j];
+
+                       if (sad->format == eld_reg_to_type[i][1]) {

drivers/gpu/drm/radeon/dce6_afmt.c line 180

Quoted 10 lines
drivers/gpu/drm/radeon/dce6_afmt.c new file +10 -0
+                               value = MAX_CHANNELS(sad->channels) |
+                                       DESCRIPTOR_BYTE_2(sad->byte2) |
+                                       SUPPORTED_FREQUENCIES(sad->freq);
+                               if (sad->format == HDMI_AUDIO_CODING_TYPE_PCM)
+                                       value |= SUPPORTED_FREQUENCIES_STEREO(sad->freq);
+                               break;
+                       }
+               }
+               WREG32_ENDPOINT(offset, eld_reg_to_type[i][0], value);
+       }

I hope this is my last questions I'm bothering you with... This is how fglrx does that part:

WREG32(0x00005e00, 0x00000125); PIN_CONTROL_CHANNEL_SPEAKER
WREG32(0x00005e04, 0x00c1005f); PIN_CONTROL_CHANNEL_SPEAKER

RREG32(0x000..05c); -> 0x00000000 AFMT_AUDIO_PACKET_CONTROL2
WREG32(0x000..05c, 0x0000ff00); AFMT_AUDIO_PACKET_CONTROL2

WREG32(0x00005e00, 0x00000027); 0x27 was 0x00005f80 on Evergreen
RREG32(0x00005e04); -> 0x00000000 0x27 was 0x00005f80 on Evergreen

WREG32(0x00005e00, 0x00000127); 0x27 was 0x00005f80
WREG32(0x00005e04, 0x00000040); 0x27 was 0x00005f80

WREG32(0x00005e00, 0x000c3128); DESCRIPTOR0
WREG32(0x00005e04, 0x7f077f07); DESCRIPTOR0

The difference is that between setting PIN_CONTROL_CHANNEL_SPEAKER and DESCRIPTOR0 fglrx enables audio channels (see AFMT_AUDIO_PACKET_CONTROL2 and 0xff00).

Do you think it does matter? Or can we ignore the order and do it your way?

#3 lore raw
Quoted 46 lines · Rafał Miłecki

2013/8/14 Alex Deucher <[email protected]>:

Quoted 19 lines
drivers/gpu/drm/radeon/dce6_afmt.c new file +19 -0
+       /* program the speaker allocation */
+       tmp = RREG32_ENDPOINT(offset, AZ_F0_CODEC_PIN_CONTROL_CHANNEL_SPEAKER);
+       tmp &= ~(DP_CONNECTION | SPEAKER_ALLOCATION_MASK);
+       /* set HDMI mode */
+       tmp |= HDMI_CONNECTION;
+       if (sadb_count)
+               tmp |= SPEAKER_ALLOCATION(sadb[0]);
+       else
+               tmp |= SPEAKER_ALLOCATION(5); /* stereo */
+       WREG32_ENDPOINT(offset, AZ_F0_CODEC_PIN_CONTROL_CHANNEL_SPEAKER, tmp);
+
+       for (i = 0; i < ARRAY_SIZE(eld_reg_to_type); i++) {
+               u32 value = 0;
+               int j;
+
+               for (j = 0; j < sad_count; j++) {
+                       struct cea_sad *sad = &sads[j];
+
+                       if (sad->format == eld_reg_to_type[i][1]) {

drivers/gpu/drm/radeon/dce6_afmt.c line 180

Quoted 10 lines
drivers/gpu/drm/radeon/dce6_afmt.c new file +10 -0
+                               value = MAX_CHANNELS(sad->channels) |
+                                       DESCRIPTOR_BYTE_2(sad->byte2) |
+                                       SUPPORTED_FREQUENCIES(sad->freq);
+                               if (sad->format == HDMI_AUDIO_CODING_TYPE_PCM)
+                                       value |= SUPPORTED_FREQUENCIES_STEREO(sad->freq);
+                               break;
+                       }
+               }
+               WREG32_ENDPOINT(offset, eld_reg_to_type[i][0], value);
+       }

I hope this is my last questions I'm bothering you with... This is how fglrx does that part:

WREG32(0x00005e00, 0x00000125); PIN_CONTROL_CHANNEL_SPEAKER
WREG32(0x00005e04, 0x00c1005f); PIN_CONTROL_CHANNEL_SPEAKER

RREG32(0x000..05c); -> 0x00000000 AFMT_AUDIO_PACKET_CONTROL2
WREG32(0x000..05c, 0x0000ff00); AFMT_AUDIO_PACKET_CONTROL2

WREG32(0x00005e00, 0x00000027); 0x27 was 0x00005f80 on Evergreen
RREG32(0x00005e04); -> 0x00000000 0x27 was 0x00005f80 on Evergreen

WREG32(0x00005e00, 0x00000127); 0x27 was 0x00005f80
WREG32(0x00005e04, 0x00000040); 0x27 was 0x00005f80

Quoted 8 lines

WREG32(0x00005e00, 0x000c3128); DESCRIPTOR0
WREG32(0x00005e04, 0x7f077f07); DESCRIPTOR0

The difference is that between setting PIN_CONTROL_CHANNEL_SPEAKER and DESCRIPTOR0 fglrx enables audio channels (see AFMT_AUDIO_PACKET_CONTROL2 and 0xff00).

Do you think it does matter? Or can we ignore the order and do it your way?

Not sure. I'll go ahead and apply your patch.

Alex
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel