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

drm, gma500: Fix Cedarview boot failures in 3.3-rc

Production GMA3600/3650 hardware turns out to be subtly different to the
development platforms. This combined with a minor driver bug is causing
the kernel to hang on these platforms.

This patch does the following

- turn down a couple of messages that were meant to be debug and are
causing much confusion

- ensure the hotplug interrupt is disabled on Cedartrail systems.

- fix a bug where gtt roll mode called psbfb_sync, which tries to sync
the 2D engine. On other devices it is harmless as the 2D engine is
present but not in use when in gtt roll mode, on Cedartrail it causes
a hang

Without these changes 3.3-rc hangs on boot on Cedartrail based systems.

Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Alan Cox and committed by
Linus Torvalds
055bf38d aa139092

+6 -6
+2
drivers/gpu/drm/gma500/cdv_device.c
··· 321 321 cdv_get_core_freq(dev); 322 322 gma_intel_opregion_init(dev); 323 323 psb_intel_init_bios(dev); 324 + REG_WRITE(PORT_HOTPLUG_EN, 0); 325 + REG_WRITE(PORT_HOTPLUG_STAT, REG_READ(PORT_HOTPLUG_STAT)); 324 326 return 0; 325 327 } 326 328
-1
drivers/gpu/drm/gma500/framebuffer.c
··· 247 247 .fb_imageblit = cfb_imageblit, 248 248 .fb_pan_display = psbfb_pan, 249 249 .fb_mmap = psbfb_mmap, 250 - .fb_sync = psbfb_sync, 251 250 .fb_ioctl = psbfb_ioctl, 252 251 }; 253 252
+4 -5
drivers/gpu/drm/gma500/gtt.c
··· 446 446 pg->gtt_start = pci_resource_start(dev->pdev, PSB_GTT_RESOURCE); 447 447 gtt_pages = pci_resource_len(dev->pdev, PSB_GTT_RESOURCE) 448 448 >> PAGE_SHIFT; 449 - /* Some CDV firmware doesn't report this currently. In which case the 450 - system has 64 gtt pages */ 449 + /* CDV doesn't report this. In which case the system has 64 gtt pages */ 451 450 if (pg->gtt_start == 0 || gtt_pages == 0) { 452 - dev_err(dev->dev, "GTT PCI BAR not initialized.\n"); 451 + dev_dbg(dev->dev, "GTT PCI BAR not initialized.\n"); 453 452 gtt_pages = 64; 454 453 pg->gtt_start = dev_priv->pge_ctl; 455 454 } ··· 460 461 461 462 if (pg->gatt_pages == 0 || pg->gatt_start == 0) { 462 463 static struct resource fudge; /* Preferably peppermint */ 463 - /* This can occur on CDV SDV systems. Fudge it in this case. 464 + /* This can occur on CDV systems. Fudge it in this case. 464 465 We really don't care what imaginary space is being allocated 465 466 at this point */ 466 - dev_err(dev->dev, "GATT PCI BAR not initialized.\n"); 467 + dev_dbg(dev->dev, "GATT PCI BAR not initialized.\n"); 467 468 pg->gatt_start = 0x40000000; 468 469 pg->gatt_pages = (128 * 1024 * 1024) >> PAGE_SHIFT; 469 470 /* This is a little confusing but in fact the GTT is providing