Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6

* 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
drm: Take lock around probes for drm_fb_helper_hotplug_event
drm/i915: Revert i915.semaphore=1 default from 47ae63e0
vga_switcheroo: don't toggle-switch devices
drm/radeon/kms: add some evergreen/ni safe regs
drm/radeon/kms: fix extended lvds info parsing
drm/radeon/kms: fix tiling reg on fusion

+44 -12
+22 -4
drivers/gpu/drm/drm_fb_helper.c
··· 1516 1516 } 1517 1517 EXPORT_SYMBOL(drm_fb_helper_initial_config); 1518 1518 1519 - bool drm_fb_helper_hotplug_event(struct drm_fb_helper *fb_helper) 1519 + /** 1520 + * drm_fb_helper_hotplug_event - respond to a hotplug notification by 1521 + * probing all the outputs attached to the fb. 1522 + * @fb_helper: the drm_fb_helper 1523 + * 1524 + * LOCKING: 1525 + * Called at runtime, must take mode config lock. 1526 + * 1527 + * Scan the connectors attached to the fb_helper and try to put together a 1528 + * setup after *notification of a change in output configuration. 1529 + * 1530 + * RETURNS: 1531 + * 0 on success and a non-zero error code otherwise. 1532 + */ 1533 + int drm_fb_helper_hotplug_event(struct drm_fb_helper *fb_helper) 1520 1534 { 1535 + struct drm_device *dev = fb_helper->dev; 1521 1536 int count = 0; 1522 1537 u32 max_width, max_height, bpp_sel; 1523 1538 bool bound = false, crtcs_bound = false; 1524 1539 struct drm_crtc *crtc; 1525 1540 1526 1541 if (!fb_helper->fb) 1527 - return false; 1542 + return 0; 1528 1543 1529 - list_for_each_entry(crtc, &fb_helper->dev->mode_config.crtc_list, head) { 1544 + mutex_lock(&dev->mode_config.mutex); 1545 + list_for_each_entry(crtc, &dev->mode_config.crtc_list, head) { 1530 1546 if (crtc->fb) 1531 1547 crtcs_bound = true; 1532 1548 if (crtc->fb == fb_helper->fb) ··· 1551 1535 1552 1536 if (!bound && crtcs_bound) { 1553 1537 fb_helper->delayed_hotplug = true; 1554 - return false; 1538 + mutex_unlock(&dev->mode_config.mutex); 1539 + return 0; 1555 1540 } 1556 1541 DRM_DEBUG_KMS("\n"); 1557 1542 ··· 1563 1546 count = drm_fb_helper_probe_connector_modes(fb_helper, max_width, 1564 1547 max_height); 1565 1548 drm_setup_crtcs(fb_helper); 1549 + mutex_unlock(&dev->mode_config.mutex); 1566 1550 1567 1551 return drm_fb_helper_single_fb_probe(fb_helper, bpp_sel); 1568 1552 }
+4 -1
drivers/gpu/drm/radeon/evergreen.c
··· 1780 1780 1781 1781 1782 1782 mc_shared_chmap = RREG32(MC_SHARED_CHMAP); 1783 - mc_arb_ramcfg = RREG32(MC_ARB_RAMCFG); 1783 + if (rdev->flags & RADEON_IS_IGP) 1784 + mc_arb_ramcfg = RREG32(FUS_MC_ARB_RAMCFG); 1785 + else 1786 + mc_arb_ramcfg = RREG32(MC_ARB_RAMCFG); 1784 1787 1785 1788 switch (rdev->config.evergreen.max_tile_pipes) { 1786 1789 case 1:
+1
drivers/gpu/drm/radeon/evergreend.h
··· 200 200 #define BURSTLENGTH_SHIFT 9 201 201 #define BURSTLENGTH_MASK 0x00000200 202 202 #define CHANSIZE_OVERRIDE (1 << 11) 203 + #define FUS_MC_ARB_RAMCFG 0x2768 203 204 #define MC_VM_AGP_TOP 0x2028 204 205 #define MC_VM_AGP_BOT 0x202C 205 206 #define MC_VM_AGP_BASE 0x2030
+11 -3
drivers/gpu/drm/radeon/radeon_atombios.c
··· 1574 1574 ATOM_FAKE_EDID_PATCH_RECORD *fake_edid_record; 1575 1575 ATOM_PANEL_RESOLUTION_PATCH_RECORD *panel_res_record; 1576 1576 bool bad_record = false; 1577 - u8 *record = (u8 *)(mode_info->atom_context->bios + 1578 - data_offset + 1579 - le16_to_cpu(lvds_info->info.usModePatchTableOffset)); 1577 + u8 *record; 1578 + 1579 + if ((frev == 1) && (crev < 2)) 1580 + /* absolute */ 1581 + record = (u8 *)(mode_info->atom_context->bios + 1582 + le16_to_cpu(lvds_info->info.usModePatchTableOffset)); 1583 + else 1584 + /* relative */ 1585 + record = (u8 *)(mode_info->atom_context->bios + 1586 + data_offset + 1587 + le16_to_cpu(lvds_info->info.usModePatchTableOffset)); 1580 1588 while (*record != ATOM_RECORD_END_TYPE) { 1581 1589 switch (*record) { 1582 1590 case LCD_MODE_PATCH_RECORD_MODE_TYPE:
+1
drivers/gpu/drm/radeon/reg_srcs/cayman
··· 33 33 0x00008E48 SQ_EX_ALLOC_TABLE_SLOTS 34 34 0x00009100 SPI_CONFIG_CNTL 35 35 0x0000913C SPI_CONFIG_CNTL_1 36 + 0x00009508 TA_CNTL_AUX 36 37 0x00009830 DB_DEBUG 37 38 0x00009834 DB_DEBUG2 38 39 0x00009838 DB_DEBUG3
+1
drivers/gpu/drm/radeon/reg_srcs/evergreen
··· 46 46 0x00008E48 SQ_EX_ALLOC_TABLE_SLOTS 47 47 0x00009100 SPI_CONFIG_CNTL 48 48 0x0000913C SPI_CONFIG_CNTL_1 49 + 0x00009508 TA_CNTL_AUX 49 50 0x00009700 VC_CNTL 50 51 0x00009714 VC_ENHANCE 51 52 0x00009830 DB_DEBUG
+3 -3
drivers/gpu/vga/vga_switcheroo.c
··· 219 219 int i; 220 220 struct vga_switcheroo_client *active = NULL; 221 221 222 - if (new_client->active == true) 223 - return 0; 224 - 225 222 for (i = 0; i < VGA_SWITCHEROO_MAX_CLIENTS; i++) { 226 223 if (vgasr_priv.clients[i].active == true) { 227 224 active = &vgasr_priv.clients[i]; ··· 368 371 ret = vgasr_priv.handler->switchto(client_id); 369 372 goto out; 370 373 } 374 + 375 + if (client->active == true) 376 + goto out; 371 377 372 378 /* okay we want a switch - test if devices are willing to switch */ 373 379 can_switch = true;
+1 -1
include/drm/drm_fb_helper.h
··· 127 127 128 128 int drm_fb_helper_setcmap(struct fb_cmap *cmap, struct fb_info *info); 129 129 130 - bool drm_fb_helper_hotplug_event(struct drm_fb_helper *fb_helper); 130 + int drm_fb_helper_hotplug_event(struct drm_fb_helper *fb_helper); 131 131 bool drm_fb_helper_initial_config(struct drm_fb_helper *fb_helper, int bpp_sel); 132 132 int drm_fb_helper_single_add_all_connectors(struct drm_fb_helper *fb_helper); 133 133 int drm_fb_helper_debug_enter(struct fb_info *info);