summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/nouveau/core/subdev/mc/base.c
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2013-10-11 09:34:08 +0400
committerBen Skeggs <bskeggs@redhat.com>2013-11-08 09:39:35 +0400
commit08f6fbdb9bef0f9f920a8531addb0952c293d4c9 (patch)
treecef9063d1f0412ce198eb8190b6d69029cd450d5 /drivers/gpu/drm/nouveau/core/subdev/mc/base.c
parent3c792a15ec799c27d634b102b605f3ec32c033c3 (diff)
downloadlinux-08f6fbdb9bef0f9f920a8531addb0952c293d4c9.tar.xz
drm/nouveau/mc: store static data in nouveau_mc class definition
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/core/subdev/mc/base.c')
-rw-r--r--drivers/gpu/drm/nouveau/core/subdev/mc/base.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/gpu/drm/nouveau/core/subdev/mc/base.c b/drivers/gpu/drm/nouveau/core/subdev/mc/base.c
index 525d40dcc3ff..dccd17b1f26e 100644
--- a/drivers/gpu/drm/nouveau/core/subdev/mc/base.c
+++ b/drivers/gpu/drm/nouveau/core/subdev/mc/base.c
@@ -29,7 +29,9 @@ static irqreturn_t
nouveau_mc_intr(int irq, void *arg)
{
struct nouveau_mc *pmc = arg;
- const struct nouveau_mc_intr *map = pmc->intr_map;
+ const struct nouveau_mc_oclass *oclass = (void *)nv_object(pmc)->oclass;
+ const struct nouveau_mc_intr *map = oclass->intr;
+ struct nouveau_device *device = nv_device(pmc);
struct nouveau_subdev *unit;
u32 intr;
@@ -95,9 +97,7 @@ _nouveau_mc_dtor(struct nouveau_object *object)
int
nouveau_mc_create_(struct nouveau_object *parent, struct nouveau_object *engine,
- struct nouveau_oclass *oclass,
- const struct nouveau_mc_intr *intr_map,
- int length, void **pobject)
+ struct nouveau_oclass *oclass, int length, void **pobject)
{
struct nouveau_device *device = nv_device(parent);
struct nouveau_mc *pmc;
@@ -109,8 +109,6 @@ nouveau_mc_create_(struct nouveau_object *parent, struct nouveau_object *engine,
if (ret)
return ret;
- pmc->intr_map = intr_map;
-
switch (device->pdev->device & 0x0ff0) {
case 0x00f0: /* BR02? */
case 0x02e0: /* BR02? */