On Fri, Dec 21, 2012 at 10:17 AM, Albrecht Dreß <[email protected]> wrote: > Hi Alex! > > Am 20.12.12 22:42 schrieb(en) Alex Deucher: > >> Apple cards have a proprietary rom without that information so we need to >> hard code it in the driver. > > > I see. And OS X relies on that, so it doesn't work with standard cards... > bad! > > >> It would be great if you could test both connectors to make sure I got the >> ddc lines mapped correctly (make sure you can get an edid from the monitor). > > > I tested only with the ADC first; I'll have to find a device with a vga > input... > > >> I've included several options in the patch for each connector, e.g., >> + /* DVI-I - tv dac, int tmds */ >> + ddc_i2c = combios_setup_i2c_bus(rdev, DDC_CRT2, 0, 0); > > > Does not read any edid data, and ejects with 'Screen(s) found, but none have > a usable configuration'. The tft is disabled (put to sleep mode), as the > failsafe config cannot open the fb device (disabled in the kernel). > > >> + //ddc_i2c = combios_setup_i2c_bus(rdev, DDC_DVI, 0, 0); > > > Here edid data is read, the log says all is perfect (I think), and the tft > is activated, but apparently the output signal is not applied. I.e. I again > see the shades/lines/pixels...
Ok, it's definitely DDC_DVI. There's a chance apple used external tmds, but I doubt it. You can try the attached patch. I suspect internal tmds support may just be broken in the driver for some setups. I haven't tested an r1xx card in a while. Alex > > >> + //ddc_i2c = combios_setup_i2c_bus(rdev, DDC_VGA, 0, 0); >> + //ddc_i2c = combios_setup_i2c_bus(rdev, DDC_MONID, 0, 0); > > > These two behave exactly like DDC_CRT2. > > I attach the dmesg output and the X logs for all four cases. > > Thanks again, > Albrecht.
From c659119a27be71482854b3eaaa81a03fc5ba5aa4 Mon Sep 17 00:00:00 2001 From: Alex Deucher <[email protected]> Date: Thu, 20 Dec 2012 16:35:47 -0500 Subject: [PATCH] drm/radeon: add connector table for Mac G4 Silver (v2) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Apple cards do not provide data tables in the vbios so we have to hard code the connector parameters in the driver. v2: sort out the ddc line, try external tmds Reported-by: Albrecht Dreß <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected] --- drivers/gpu/drm/radeon/radeon_combios.c | 51 +++++++++++++++++++++++++++++++ drivers/gpu/drm/radeon/radeon_mode.h | 3 +- 2 files changed, 53 insertions(+), 1 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_combios.c b/drivers/gpu/drm/radeon/radeon_combios.c index 4af8912..0dcadaa 100644 --- a/drivers/gpu/drm/radeon/radeon_combios.c +++ b/drivers/gpu/drm/radeon/radeon_combios.c @@ -1548,6 +1548,9 @@ bool radeon_get_legacy_connector_info_from_table(struct drm_device *dev) of_machine_is_compatible("PowerBook6,7")) { /* ibook */ rdev->mode_info.connector_table = CT_IBOOK; + } else if (of_machine_is_compatible("PowerMac3,5")) { + /* PowerMac G4 Silver radeon 7500 */ + rdev->mode_info.connector_table = CT_MAC_G4_SILVER; } else if (of_machine_is_compatible("PowerMac4,4")) { /* emac */ rdev->mode_info.connector_table = CT_EMAC; @@ -2212,6 +2215,54 @@ bool radeon_get_legacy_connector_info_from_table(struct drm_device *dev) CONNECTOR_OBJECT_ID_SVIDEO, &hpd); break; + case CT_MAC_G4_SILVER: + DRM_INFO("Connector Table: %d (mac g4 silver)\n", + rdev->mode_info.connector_table); + /* DVI - tv dac, dvo */ + ddc_i2c = combios_setup_i2c_bus(rdev, DDC_DVI, 0, 0); + hpd.hpd = RADEON_HPD_1; /* ??? */ + radeon_add_legacy_encoder(dev, + radeon_get_encoder_enum(dev, + ATOM_DEVICE_DFP2_SUPPORT, + 0), + ATOM_DEVICE_DFP2_SUPPORT); + radeon_add_legacy_encoder(dev, + radeon_get_encoder_enum(dev, + ATOM_DEVICE_CRT2_SUPPORT, + 2), + ATOM_DEVICE_CRT2_SUPPORT); + radeon_add_legacy_connector(dev, 0, + ATOM_DEVICE_DFP2_SUPPORT | + ATOM_DEVICE_CRT2_SUPPORT, + DRM_MODE_CONNECTOR_DVII, &ddc_i2c, + CONNECTOR_OBJECT_ID_SINGLE_LINK_DVI_I, + &hpd); + /* VGA - primary dac */ + ddc_i2c = combios_setup_i2c_bus(rdev, DDC_VGA, 0, 0); + hpd.hpd = RADEON_HPD_NONE; + radeon_add_legacy_encoder(dev, + radeon_get_encoder_enum(dev, + ATOM_DEVICE_CRT1_SUPPORT, + 1), + ATOM_DEVICE_CRT1_SUPPORT); + radeon_add_legacy_connector(dev, 1, ATOM_DEVICE_CRT1_SUPPORT, + DRM_MODE_CONNECTOR_VGA, &ddc_i2c, + CONNECTOR_OBJECT_ID_VGA, + &hpd); + /* TV - TV DAC */ + ddc_i2c.valid = false; + hpd.hpd = RADEON_HPD_NONE; + radeon_add_legacy_encoder(dev, + radeon_get_encoder_enum(dev, + ATOM_DEVICE_TV1_SUPPORT, + 2), + ATOM_DEVICE_TV1_SUPPORT); + radeon_add_legacy_connector(dev, 2, ATOM_DEVICE_TV1_SUPPORT, + DRM_MODE_CONNECTOR_SVIDEO, + &ddc_i2c, + CONNECTOR_OBJECT_ID_SVIDEO, + &hpd); + break; default: DRM_INFO("Connector table: %d (invalid)\n", rdev->mode_info.connector_table); diff --git a/drivers/gpu/drm/radeon/radeon_mode.h b/drivers/gpu/drm/radeon/radeon_mode.h index d818b50..ed8a0fa 100644 --- a/drivers/gpu/drm/radeon/radeon_mode.h +++ b/drivers/gpu/drm/radeon/radeon_mode.h @@ -209,7 +209,8 @@ enum radeon_connector_table { CT_RN50_POWER, CT_MAC_X800, CT_MAC_G5_9600, - CT_SAM440EP + CT_SAM440EP, + CT_MAC_G4_SILVER }; enum radeon_dvo_chip { -- 1.7.7.5
_______________________________________________ xorg-driver-ati mailing list [email protected] http://lists.x.org/mailman/listinfo/xorg-driver-ati
