Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 318576
b: refs/heads/master
c: 32e3cd6
h: refs/heads/master
v: v3
  • Loading branch information
Daniel Vetter committed Jun 12, 2012
1 parent 5a36551 commit 001e08a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 14be93ddff61eb196382aeaa3ac86f4db844aeb0
refs/heads/master: 32e3cd6ecd7ae9b79605b5f2eb993186a509c239
20 changes: 10 additions & 10 deletions trunk/drivers/char/agp/intel-gtt.c
Original file line number Diff line number Diff line change
Expand Up @@ -648,6 +648,7 @@ static void intel_gtt_cleanup(void)

static int intel_gtt_init(void)
{
u32 gma_addr;
u32 gtt_map_size;
int ret;

Expand Down Expand Up @@ -694,6 +695,15 @@ static int intel_gtt_init(void)
return ret;
}

if (INTEL_GTT_GEN <= 2)
pci_read_config_dword(intel_private.pcidev, I810_GMADDR,
&gma_addr);
else
pci_read_config_dword(intel_private.pcidev, I915_GMADDR,
&gma_addr);

intel_private.base.gma_bus_addr = (gma_addr & PCI_BASE_ADDRESS_MEM_MASK);

return 0;
}

Expand Down Expand Up @@ -769,18 +779,8 @@ static void i830_write_entry(dma_addr_t addr, unsigned int entry,

static bool intel_enable_gtt(void)
{
u32 gma_addr;
u8 __iomem *reg;

if (INTEL_GTT_GEN <= 2)
pci_read_config_dword(intel_private.pcidev, I810_GMADDR,
&gma_addr);
else
pci_read_config_dword(intel_private.pcidev, I915_GMADDR,
&gma_addr);

intel_private.base.gma_bus_addr = (gma_addr & PCI_BASE_ADDRESS_MEM_MASK);

if (INTEL_GTT_GEN >= 6)
return true;

Expand Down

0 comments on commit 001e08a

Please sign in to comment.