summaryrefslogtreecommitdiff
path: root/bin/nv_rffunc.h
diff options
context:
space:
mode:
Diffstat (limited to 'bin/nv_rffunc.h')
-rw-r--r--bin/nv_rffunc.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/nv_rffunc.h b/bin/nv_rffunc.h
index 4bc0e4a41..fe1d616a0 100644
--- a/bin/nv_rffunc.h
+++ b/bin/nv_rffunc.h
@@ -8,6 +8,7 @@ static u64 map_page = ~0ULL;
static CAST
nv_rfb(struct nvif_device *device, u64 offset)
{
+ struct nvkm_device *nv = nvxx_device(device);
u64 page = (offset & ~(PAGE_SIZE - 1));
u64 addr = (offset & (PAGE_SIZE - 1));
@@ -21,8 +22,7 @@ nv_rfb(struct nvif_device *device, u64 offset)
if (map)
iounmap(map);
- map = ioremap(pci_resource_start(nvxx_device(device)->pdev, 1) +
- page, PAGE_SIZE);
+ map = ioremap(nv->func->resource_addr(nv, 1) + page, PAGE_SIZE);
if (!map) {
printk("map failed\n");
exit(1);