diff options
author | Dave Airlie <airlied@linux.ie> | 2006-03-23 13:06:32 +1100 |
---|---|---|
committer | Dave Airlie <airlied@linux.ie> | 2006-04-03 11:43:28 +1000 |
commit | 8bb91f6a2d1db8031bfbb367df075f041d0cdfe2 (patch) | |
tree | 558db93f69096ede171d0b4e6c6c0330d8362e92 /drivers/video/intelfb/intelfbdrv.c | |
parent | 7679f4d69296de97a7f62458cc4d1c6c884dfcfb (diff) | |
download | op-kernel-dev-8bb91f6a2d1db8031bfbb367df075f041d0cdfe2.zip op-kernel-dev-8bb91f6a2d1db8031bfbb367df075f041d0cdfe2.tar.gz |
intelfb: add hw cursor support for i9xx
This adds hw cursor support for the i9xx chipsets.
Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/video/intelfb/intelfbdrv.c')
-rw-r--r-- | drivers/video/intelfb/intelfbdrv.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/drivers/video/intelfb/intelfbdrv.c b/drivers/video/intelfb/intelfbdrv.c index ce45a68..b96001b 100644 --- a/drivers/video/intelfb/intelfbdrv.c +++ b/drivers/video/intelfb/intelfbdrv.c @@ -6,6 +6,7 @@ * * Copyright © 2002, 2003 David Dawes <dawes@xfree86.org> * 2004 Sylvain Meyer + * 2006 David Airlie * * This driver consists of two parts. The first part (intelfbdrv.c) provides * the basic fbdev interfaces, is derived in part from the radeonfb and @@ -551,8 +552,6 @@ intelfb_pci_register(struct pci_dev *pdev, const struct pci_device_id *ent) (ent->device == PCI_DEVICE_ID_INTEL_945G)) { aperture_bar = 2; mmio_bar = 0; - /* Disable HW cursor on 9x5G/M (not implemented yet) */ - hwcursor = 0; } dinfo->aperture.physical = pci_resource_start(pdev, aperture_bar); dinfo->aperture.size = pci_resource_len(pdev, aperture_bar); @@ -1468,7 +1467,7 @@ static int intelfb_cursor(struct fb_info *info, struct fb_cursor *cursor) { struct intelfb_info *dinfo = GET_DINFO(info); - + int ret; #if VERBOSE > 0 DBG_MSG("intelfb_cursor\n"); #endif @@ -1479,7 +1478,12 @@ intelfb_cursor(struct fb_info *info, struct fb_cursor *cursor) intelfbhw_cursor_hide(dinfo); /* If XFree killed the cursor - restore it */ - if (INREG(CURSOR_A_BASEADDR) != dinfo->cursor.offset << 12) { + if (dinfo->mobile || IS_I9xx(dinfo)) + ret = (INREG(CURSOR_A_BASEADDR) != dinfo->cursor.physical); + else + ret = (INREG(CURSOR_A_BASEADDR) != dinfo->cursor.offset << 12); + + if (ret) { u32 fg, bg; DBG_MSG("the cursor was killed - restore it !!\n"); |