diff options
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gk20a.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.c b/drivers/gpu/nvgpu/gk20a/gk20a.c index a13d54b3..c645aeea 100644 --- a/drivers/gpu/nvgpu/gk20a/gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gk20a.c | |||
@@ -271,7 +271,7 @@ static void __iomem *gk20a_ioremap_resource(struct platform_device *dev, int i, | |||
271 | return NULL; | 271 | return NULL; |
272 | if (out) | 272 | if (out) |
273 | *out = r; | 273 | *out = r; |
274 | return devm_request_and_ioremap(&dev->dev, r); | 274 | return devm_ioremap_resource(&dev->dev, r); |
275 | } | 275 | } |
276 | 276 | ||
277 | /* TBD: strip from released */ | 277 | /* TBD: strip from released */ |
@@ -285,9 +285,9 @@ static int gk20a_init_sim_support(struct platform_device *dev) | |||
285 | g->sim.g = g; | 285 | g->sim.g = g; |
286 | g->sim.regs = gk20a_ioremap_resource(dev, GK20A_SIM_IORESOURCE_MEM, | 286 | g->sim.regs = gk20a_ioremap_resource(dev, GK20A_SIM_IORESOURCE_MEM, |
287 | &g->sim.reg_mem); | 287 | &g->sim.reg_mem); |
288 | if (!g->sim.regs) { | 288 | if (IS_ERR(g->sim.regs)) { |
289 | dev_err(d, "failed to remap gk20a sim regs\n"); | 289 | dev_err(d, "failed to remap gk20a sim regs\n"); |
290 | err = -ENXIO; | 290 | err = PTR_ERR(g->sim.regs); |
291 | goto fail; | 291 | goto fail; |
292 | } | 292 | } |
293 | 293 | ||
@@ -617,17 +617,17 @@ static int gk20a_init_support(struct platform_device *dev) | |||
617 | 617 | ||
618 | g->regs = gk20a_ioremap_resource(dev, GK20A_BAR0_IORESOURCE_MEM, | 618 | g->regs = gk20a_ioremap_resource(dev, GK20A_BAR0_IORESOURCE_MEM, |
619 | &g->reg_mem); | 619 | &g->reg_mem); |
620 | if (!g->regs) { | 620 | if (IS_ERR(g->regs)) { |
621 | dev_err(dev_from_gk20a(g), "failed to remap gk20a registers\n"); | 621 | dev_err(dev_from_gk20a(g), "failed to remap gk20a registers\n"); |
622 | err = -ENXIO; | 622 | err = PTR_ERR(g->regs); |
623 | goto fail; | 623 | goto fail; |
624 | } | 624 | } |
625 | 625 | ||
626 | g->bar1 = gk20a_ioremap_resource(dev, GK20A_BAR1_IORESOURCE_MEM, | 626 | g->bar1 = gk20a_ioremap_resource(dev, GK20A_BAR1_IORESOURCE_MEM, |
627 | &g->bar1_mem); | 627 | &g->bar1_mem); |
628 | if (!g->bar1) { | 628 | if (IS_ERR(g->bar1)) { |
629 | dev_err(dev_from_gk20a(g), "failed to remap gk20a bar1\n"); | 629 | dev_err(dev_from_gk20a(g), "failed to remap gk20a bar1\n"); |
630 | err = -ENXIO; | 630 | err = PTR_ERR(g->regs); |
631 | goto fail; | 631 | goto fail; |
632 | } | 632 | } |
633 | 633 | ||