Skip to content

Commit

Permalink
drm/i915: enable 36bit physical address for hardware status page
Browse files Browse the repository at this point in the history
This enables possible 36bit address mask on 965G that use physical
address for hw status page.

Signed-off-by: Zhenyu Wang <[email protected]>
Signed-off-by: Eric Anholt <[email protected]>
  • Loading branch information
zhenyw authored and anholt committed Jan 15, 2010
1 parent 6251ec0 commit 9b974cc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
6 changes: 5 additions & 1 deletion drivers/char/agp/intel-agp.c
Original file line number Diff line number Diff line change
Expand Up @@ -2460,10 +2460,14 @@ static int __devinit agp_intel_probe(struct pci_dev *pdev,
&bridge->mode);
}

if (bridge->driver->mask_memory == intel_i965_mask_memory)
if (bridge->driver->mask_memory == intel_i965_mask_memory) {
if (pci_set_dma_mask(intel_private.pcidev, DMA_BIT_MASK(36)))
dev_err(&intel_private.pcidev->dev,
"set gfx device dma mask 36bit failed!\n");
else
pci_set_consistent_dma_mask(intel_private.pcidev,
DMA_BIT_MASK(36));
}

pci_set_drvdata(pdev, bridge);
return agp_add_bridge(bridge);
Expand Down
4 changes: 4 additions & 0 deletions drivers/gpu/drm/i915/i915_dma.c
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,10 @@ static int i915_init_phys_hws(struct drm_device *dev)

memset(dev_priv->hw_status_page, 0, PAGE_SIZE);

if (IS_I965G(dev))
dev_priv->dma_status_page |= (dev_priv->dma_status_page >> 28) &
0xf0;

I915_WRITE(HWS_PGA, dev_priv->dma_status_page);
DRM_DEBUG_DRIVER("Enabled hardware status page\n");
return 0;
Expand Down

0 comments on commit 9b974cc

Please sign in to comment.