aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
authorAlex Deucher <alexdeucher@gmail.com>2010-11-30 15:46:47 -0500
committerDave Airlie <airlied@redhat.com>2010-11-30 21:13:23 -0500
commitc49948f4bd39e27dd06a1cdb0c3743ca2a734f5e (patch)
treec88292306c0e6314c792b4bbc827b44b2c908840 /drivers/gpu
parent0ec80d645661dda50acd417bdfcb33df2e5dd31e (diff)
drm/radeon/kms: fix interlaced and doublescan handling
Signed-off-by: Alex Deucher <alexdeucher@gmail.com> Cc: stable@kernel.org Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/radeon/radeon_connectors.c34
1 files changed, 34 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_connectors.c b/drivers/gpu/drm/radeon/radeon_connectors.c
index 3bef9f6d66fd..8afaf7a7459e 100644
--- a/drivers/gpu/drm/radeon/radeon_connectors.c
+++ b/drivers/gpu/drm/radeon/radeon_connectors.c
@@ -1175,6 +1175,8 @@ radeon_add_atom_connector(struct drm_device *dev,
1175 /* no HPD on analog connectors */ 1175 /* no HPD on analog connectors */
1176 radeon_connector->hpd.hpd = RADEON_HPD_NONE; 1176 radeon_connector->hpd.hpd = RADEON_HPD_NONE;
1177 connector->polled = DRM_CONNECTOR_POLL_CONNECT; 1177 connector->polled = DRM_CONNECTOR_POLL_CONNECT;
1178 connector->interlace_allowed = true;
1179 connector->doublescan_allowed = true;
1178 break; 1180 break;
1179 case DRM_MODE_CONNECTOR_DVIA: 1181 case DRM_MODE_CONNECTOR_DVIA:
1180 drm_connector_init(dev, &radeon_connector->base, &radeon_vga_connector_funcs, connector_type); 1182 drm_connector_init(dev, &radeon_connector->base, &radeon_vga_connector_funcs, connector_type);
@@ -1190,6 +1192,8 @@ radeon_add_atom_connector(struct drm_device *dev,
1190 1); 1192 1);
1191 /* no HPD on analog connectors */ 1193 /* no HPD on analog connectors */
1192 radeon_connector->hpd.hpd = RADEON_HPD_NONE; 1194 radeon_connector->hpd.hpd = RADEON_HPD_NONE;
1195 connector->interlace_allowed = true;
1196 connector->doublescan_allowed = true;
1193 break; 1197 break;
1194 case DRM_MODE_CONNECTOR_DVII: 1198 case DRM_MODE_CONNECTOR_DVII:
1195 case DRM_MODE_CONNECTOR_DVID: 1199 case DRM_MODE_CONNECTOR_DVID:
@@ -1226,6 +1230,11 @@ radeon_add_atom_connector(struct drm_device *dev,
1226 rdev->mode_info.load_detect_property, 1230 rdev->mode_info.load_detect_property,
1227 1); 1231 1);
1228 } 1232 }
1233 connector->interlace_allowed = true;
1234 if (connector_type == DRM_MODE_CONNECTOR_DVII)
1235 connector->doublescan_allowed = true;
1236 else
1237 connector->doublescan_allowed = false;
1229 break; 1238 break;
1230 case DRM_MODE_CONNECTOR_HDMIA: 1239 case DRM_MODE_CONNECTOR_HDMIA:
1231 case DRM_MODE_CONNECTOR_HDMIB: 1240 case DRM_MODE_CONNECTOR_HDMIB:
@@ -1256,6 +1265,11 @@ radeon_add_atom_connector(struct drm_device *dev,
1256 0); 1265 0);
1257 } 1266 }
1258 subpixel_order = SubPixelHorizontalRGB; 1267 subpixel_order = SubPixelHorizontalRGB;
1268 connector->interlace_allowed = true;
1269 if (connector_type == DRM_MODE_CONNECTOR_HDMIB)
1270 connector->doublescan_allowed = true;
1271 else
1272 connector->doublescan_allowed = false;
1259 break; 1273 break;
1260 case DRM_MODE_CONNECTOR_DisplayPort: 1274 case DRM_MODE_CONNECTOR_DisplayPort:
1261 case DRM_MODE_CONNECTOR_eDP: 1275 case DRM_MODE_CONNECTOR_eDP:
@@ -1293,6 +1307,9 @@ radeon_add_atom_connector(struct drm_device *dev,
1293 rdev->mode_info.underscan_vborder_property, 1307 rdev->mode_info.underscan_vborder_property,
1294 0); 1308 0);
1295 } 1309 }
1310 connector->interlace_allowed = true;
1311 /* in theory with a DP to VGA converter... */
1312 connector->doublescan_allowed = false;
1296 break; 1313 break;
1297 case DRM_MODE_CONNECTOR_SVIDEO: 1314 case DRM_MODE_CONNECTOR_SVIDEO:
1298 case DRM_MODE_CONNECTOR_Composite: 1315 case DRM_MODE_CONNECTOR_Composite:
@@ -1308,6 +1325,8 @@ radeon_add_atom_connector(struct drm_device *dev,
1308 radeon_atombios_get_tv_info(rdev)); 1325 radeon_atombios_get_tv_info(rdev));
1309 /* no HPD on analog connectors */ 1326 /* no HPD on analog connectors */
1310 radeon_connector->hpd.hpd = RADEON_HPD_NONE; 1327 radeon_connector->hpd.hpd = RADEON_HPD_NONE;
1328 connector->interlace_allowed = false;
1329 connector->doublescan_allowed = false;
1311 break; 1330 break;
1312 case DRM_MODE_CONNECTOR_LVDS: 1331 case DRM_MODE_CONNECTOR_LVDS:
1313 radeon_dig_connector = kzalloc(sizeof(struct radeon_connector_atom_dig), GFP_KERNEL); 1332 radeon_dig_connector = kzalloc(sizeof(struct radeon_connector_atom_dig), GFP_KERNEL);
@@ -1326,6 +1345,8 @@ radeon_add_atom_connector(struct drm_device *dev,
1326 dev->mode_config.scaling_mode_property, 1345 dev->mode_config.scaling_mode_property,
1327 DRM_MODE_SCALE_FULLSCREEN); 1346 DRM_MODE_SCALE_FULLSCREEN);
1328 subpixel_order = SubPixelHorizontalRGB; 1347 subpixel_order = SubPixelHorizontalRGB;
1348 connector->interlace_allowed = false;
1349 connector->doublescan_allowed = false;
1329 break; 1350 break;
1330 } 1351 }
1331 1352
@@ -1403,6 +1424,8 @@ radeon_add_legacy_connector(struct drm_device *dev,
1403 /* no HPD on analog connectors */ 1424 /* no HPD on analog connectors */
1404 radeon_connector->hpd.hpd = RADEON_HPD_NONE; 1425 radeon_connector->hpd.hpd = RADEON_HPD_NONE;
1405 connector->polled = DRM_CONNECTOR_POLL_CONNECT; 1426 connector->polled = DRM_CONNECTOR_POLL_CONNECT;
1427 connector->interlace_allowed = true;
1428 connector->doublescan_allowed = true;
1406 break; 1429 break;
1407 case DRM_MODE_CONNECTOR_DVIA: 1430 case DRM_MODE_CONNECTOR_DVIA:
1408 drm_connector_init(dev, &radeon_connector->base, &radeon_vga_connector_funcs, connector_type); 1431 drm_connector_init(dev, &radeon_connector->base, &radeon_vga_connector_funcs, connector_type);
@@ -1418,6 +1441,8 @@ radeon_add_legacy_connector(struct drm_device *dev,
1418 1); 1441 1);
1419 /* no HPD on analog connectors */ 1442 /* no HPD on analog connectors */
1420 radeon_connector->hpd.hpd = RADEON_HPD_NONE; 1443 radeon_connector->hpd.hpd = RADEON_HPD_NONE;
1444 connector->interlace_allowed = true;
1445 connector->doublescan_allowed = true;
1421 break; 1446 break;
1422 case DRM_MODE_CONNECTOR_DVII: 1447 case DRM_MODE_CONNECTOR_DVII:
1423 case DRM_MODE_CONNECTOR_DVID: 1448 case DRM_MODE_CONNECTOR_DVID:
@@ -1435,6 +1460,11 @@ radeon_add_legacy_connector(struct drm_device *dev,
1435 1); 1460 1);
1436 } 1461 }
1437 subpixel_order = SubPixelHorizontalRGB; 1462 subpixel_order = SubPixelHorizontalRGB;
1463 connector->interlace_allowed = true;
1464 if (connector_type == DRM_MODE_CONNECTOR_DVII)
1465 connector->doublescan_allowed = true;
1466 else
1467 connector->doublescan_allowed = false;
1438 break; 1468 break;
1439 case DRM_MODE_CONNECTOR_SVIDEO: 1469 case DRM_MODE_CONNECTOR_SVIDEO:
1440 case DRM_MODE_CONNECTOR_Composite: 1470 case DRM_MODE_CONNECTOR_Composite:
@@ -1457,6 +1487,8 @@ radeon_add_legacy_connector(struct drm_device *dev,
1457 radeon_combios_get_tv_info(rdev)); 1487 radeon_combios_get_tv_info(rdev));
1458 /* no HPD on analog connectors */ 1488 /* no HPD on analog connectors */
1459 radeon_connector->hpd.hpd = RADEON_HPD_NONE; 1489 radeon_connector->hpd.hpd = RADEON_HPD_NONE;
1490 connector->interlace_allowed = false;
1491 connector->doublescan_allowed = false;
1460 break; 1492 break;
1461 case DRM_MODE_CONNECTOR_LVDS: 1493 case DRM_MODE_CONNECTOR_LVDS:
1462 drm_connector_init(dev, &radeon_connector->base, &radeon_lvds_connector_funcs, connector_type); 1494 drm_connector_init(dev, &radeon_connector->base, &radeon_lvds_connector_funcs, connector_type);
@@ -1470,6 +1502,8 @@ radeon_add_legacy_connector(struct drm_device *dev,
1470 dev->mode_config.scaling_mode_property, 1502 dev->mode_config.scaling_mode_property,
1471 DRM_MODE_SCALE_FULLSCREEN); 1503 DRM_MODE_SCALE_FULLSCREEN);
1472 subpixel_order = SubPixelHorizontalRGB; 1504 subpixel_order = SubPixelHorizontalRGB;
1505 connector->interlace_allowed = false;
1506 connector->doublescan_allowed = false;
1473 break; 1507 break;
1474 } 1508 }
1475 1509