aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/gxt4500.c
diff options
context:
space:
mode:
authorArjan van de Ven <arjan@linux.intel.com>2009-01-06 17:42:28 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2009-01-06 18:59:26 -0500
commit3c36aa5ccdf516255ef2eac90dd948da891aa4bd (patch)
tree7930059e5ba51e0fe58fd902b3622664dcfee749 /drivers/video/gxt4500.c
parentab5dc372021def8f40b34761babecad0bf868b1c (diff)
pci: use pci_ioremap_bar() in drivers/video
Use the newly introduced pci_ioremap_bar() function in drivers/video. pci_ioremap_bar() just takes a pci device and a bar number, with the goal of making it really hard to get wrong, while also having a central place to stick sanity checks. Signed-off-by: Arjan van de Ven <arjan@linux.intel.com> Cc: Krzysztof Helt <krzysztof.h1@poczta.fm> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/video/gxt4500.c')
-rw-r--r--drivers/video/gxt4500.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/video/gxt4500.c b/drivers/video/gxt4500.c
index 564557792bed..896e53dea906 100644
--- a/drivers/video/gxt4500.c
+++ b/drivers/video/gxt4500.c
@@ -648,7 +648,7 @@ static int __devinit gxt4500_probe(struct pci_dev *pdev,
648 info->pseudo_palette = par->pseudo_palette; 648 info->pseudo_palette = par->pseudo_palette;
649 649
650 info->fix.mmio_start = reg_phys; 650 info->fix.mmio_start = reg_phys;
651 par->regs = ioremap(reg_phys, pci_resource_len(pdev, 0)); 651 par->regs = pci_ioremap_bar(pdev, 0);
652 if (!par->regs) { 652 if (!par->regs) {
653 dev_err(&pdev->dev, "gxt4500: cannot map registers\n"); 653 dev_err(&pdev->dev, "gxt4500: cannot map registers\n");
654 goto err_free_all; 654 goto err_free_all;
@@ -656,7 +656,7 @@ static int __devinit gxt4500_probe(struct pci_dev *pdev,
656 656
657 info->fix.smem_start = fb_phys; 657 info->fix.smem_start = fb_phys;
658 info->fix.smem_len = pci_resource_len(pdev, 1); 658 info->fix.smem_len = pci_resource_len(pdev, 1);
659 info->screen_base = ioremap(fb_phys, pci_resource_len(pdev, 1)); 659 info->screen_base = pci_ioremap_bar(pdev, 1);
660 if (!info->screen_base) { 660 if (!info->screen_base) {
661 dev_err(&pdev->dev, "gxt4500: cannot map framebuffer\n"); 661 dev_err(&pdev->dev, "gxt4500: cannot map framebuffer\n");
662 goto err_unmap_regs; 662 goto err_unmap_regs;