Skip to contentSkip to conversation

intel_agp: fix G965 GTT size detect

PATCH Applied Wang Zhenyu 2 participants 2 messages Apr 10, 2007 Agpgart driver

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 intel_agp: fix G965 GTT size detect

Dave,

On G965, I810_PGETBL_CTL is a mmio offset, but we wrongly take it as pci config space offset in detecting GTT size. This one line patch fixs this.

---

drivers/char/agp/intel-agp.c +2 -3
index a9fdbf9..4c05c71 100644
@@ -431,9 +431,8 @@ static void intel_i830_init_gtt_entries(
 
 	if (IS_I965) {
 		u32 pgetbl_ctl;
-
-		pci_read_config_dword(agp_bridge->dev, I810_PGETBL_CTL,
-				      &pgetbl_ctl);
+		pgetbl_ctl = readl(intel_i830_private.registers+I810_PGETBL_CTL);
+		    	
 		/* The 965 has a field telling us the size of the GTT,
 		 * which may be larger than what is necessary to map the
 		 * aperture.

---

Applied
#1 lore raw
Quoted 6 lines · Wang Zhenyu

Dave,

On G965, I810_PGETBL_CTL is a mmio offset, but we wrongly take it as pci config space offset in detecting GTT size. This one line patch fixs this.

Thanks, applied, and pushed on to Linus for .21

Be careful with trailing whitespace btw, git-applymbox complains loudly when merging such patches. (I fixed it up by hand this time)

Dave

Signature · 1 line
http://www.codemonkey.org.uk