diff options
author | Zhenyu Wang <zhenyu.z.wang@intel.com> | 2008-06-17 12:39:28 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2008-06-17 12:40:45 -0700 |
commit | 093f65fd04c38e6c1f19889074f9316749959c7a (patch) | |
tree | 5feb1735ce740b8d8160a509f60fb455e1625de4 /src/i830_driver.c | |
parent | 289790c0467d27e96b537598a6589fc6a36da8b8 (diff) |
Add support for Intel 4 series chipsets.
(cherry picked from commit 1cfe769c74d1a3a392bf1aaaf5c2dcc8273daf66)
Diffstat (limited to 'src/i830_driver.c')
-rw-r--r-- | src/i830_driver.c | 37 |
1 files changed, 35 insertions, 2 deletions
diff --git a/src/i830_driver.c b/src/i830_driver.c index 091b5ca6..604665e3 100644 --- a/src/i830_driver.c +++ b/src/i830_driver.c @@ -252,6 +252,9 @@ static SymTabRec I830Chipsets[] = { {PCI_CHIP_Q35_G, "Q35"}, {PCI_CHIP_Q33_G, "Q33"}, {PCI_CHIP_IGD_GM, "Intel Integrated Graphics Device"}, + {PCI_CHIP_IGD_E_G, "Intel Integrated Graphics Device"}, + {PCI_CHIP_G45_G, "G45/G43"}, + {PCI_CHIP_Q45_G, "Q45/Q43"}, {-1, NULL} }; @@ -276,6 +279,9 @@ static PciChipsets I830PciChipsets[] = { {PCI_CHIP_Q35_G, PCI_CHIP_Q35_G, RES_SHARED_VGA}, {PCI_CHIP_Q33_G, PCI_CHIP_Q33_G, RES_SHARED_VGA}, {PCI_CHIP_IGD_GM, PCI_CHIP_IGD_GM, RES_SHARED_VGA}, + {PCI_CHIP_IGD_E_G, PCI_CHIP_IGD_E_G, RES_SHARED_VGA}, + {PCI_CHIP_G45_G, PCI_CHIP_G45_G, RES_SHARED_VGA}, + {PCI_CHIP_Q45_G, PCI_CHIP_Q45_G, RES_SHARED_VGA}, {-1, -1, RES_UNDEFINED} }; @@ -511,6 +517,10 @@ I830DetectMemory(ScrnInfoPtr pScrn) */ range = gtt_size + 4; + /* new 4 series hardware has seperate GTT stolen with GFX stolen */ + if (IS_G4X(pI830)) + range = 0; + if (IS_I85X(pI830) || IS_I865G(pI830) || IS_I9XX(pI830)) { switch (gmch_ctrl & I855_GMCH_GMS_MASK) { case I855_GMCH_GMS_STOLEN_1M: @@ -544,6 +554,22 @@ I830DetectMemory(ScrnInfoPtr pScrn) if (IS_I9XX(pI830)) memsize = MB(256) - KB(range); break; + case INTEL_GMCH_GMS_STOLEN_96M: + if (IS_I9XX(pI830)) + memsize = MB(96) - KB(range); + break; + case INTEL_GMCH_GMS_STOLEN_160M: + if (IS_I9XX(pI830)) + memsize = MB(160) - KB(range); + break; + case INTEL_GMCH_GMS_STOLEN_224M: + if (IS_I9XX(pI830)) + memsize = MB(224) - KB(range); + break; + case INTEL_GMCH_GMS_STOLEN_352M: + if (IS_I9XX(pI830)) + memsize = MB(352) - KB(range); + break; } } else { switch (gmch_ctrl & I830_GMCH_GMS_MASK) { @@ -627,7 +653,7 @@ I830MapMMIO(ScrnInfoPtr pScrn) if (IS_I965G(pI830)) { - if (IS_IGD_GM(pI830)) { + if (IS_IGD_GM(pI830) || IS_G4X(pI830)) { gttaddr = pI830->MMIOAddr + MB(2); pI830->GTTMapSize = MB(2); } else { @@ -1182,8 +1208,15 @@ i830_detect_chipset(ScrnInfoPtr pScrn) chipname = "Q33"; break; case PCI_CHIP_IGD_GM: + case PCI_CHIP_IGD_E_G: chipname = "Intel Integrated Graphics Device"; break; + case PCI_CHIP_G45_G: + chipname = "G45/G43"; + break; + case PCI_CHIP_Q45_G: + chipname = "Q45/Q43"; + break; default: chipname = "unknown chipset"; break; @@ -2952,7 +2985,7 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv) "needs 2D acceleration.\n"); pI830->XvEnabled = FALSE; } - if (!IS_IGD_GM(pI830) && pI830->overlay_regs == NULL) { + if (!OVERLAY_NOEXIST(pI830) && pI830->overlay_regs == NULL) { xf86DrvMsg(pScrn->scrnIndex, X_WARNING, "Disabling Xv because the overlay register buffer " "allocation failed.\n"); |