diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2012-10-07 23:39:13 -0400 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2012-11-28 18:56:38 -0500 |
commit | 82d23aea108886c869fce4c1e3178db5f57b6e9c (patch) | |
tree | 731b32d78e1e7edc3a4f5b1275f8078daf2f6e3a /drivers/gpu/drm/nouveau/core/engine/dmaobj/nvc0.c | |
parent | 6c1689a08cf54e58c19eb565528a293f36f731be (diff) |
drm/nvc0/dmaobj: stub bind function for now so we can call unconditionally
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/core/engine/dmaobj/nvc0.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/core/engine/dmaobj/nvc0.c | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/drivers/gpu/drm/nouveau/core/engine/dmaobj/nvc0.c b/drivers/gpu/drm/nouveau/core/engine/dmaobj/nvc0.c index 36de4491629..6fe20d21158 100644 --- a/drivers/gpu/drm/nouveau/core/engine/dmaobj/nvc0.c +++ b/drivers/gpu/drm/nouveau/core/engine/dmaobj/nvc0.c | |||
@@ -23,7 +23,10 @@ | |||
23 | */ | 23 | */ |
24 | 24 | ||
25 | #include <core/device.h> | 25 | #include <core/device.h> |
26 | #include <core/gpuobj.h> | ||
27 | #include <core/class.h> | ||
26 | 28 | ||
29 | #include <subdev/fb.h> | ||
27 | #include <engine/dmaobj.h> | 30 | #include <engine/dmaobj.h> |
28 | 31 | ||
29 | struct nvc0_dmaeng_priv { | 32 | struct nvc0_dmaeng_priv { |
@@ -31,6 +34,25 @@ struct nvc0_dmaeng_priv { | |||
31 | }; | 34 | }; |
32 | 35 | ||
33 | static int | 36 | static int |
37 | nvc0_dmaobj_bind(struct nouveau_dmaeng *dmaeng, | ||
38 | struct nouveau_object *parent, | ||
39 | struct nouveau_dmaobj *dmaobj, | ||
40 | struct nouveau_gpuobj **pgpuobj) | ||
41 | { | ||
42 | int ret = 0; | ||
43 | |||
44 | if (!nv_iclass(parent, NV_ENGCTX_CLASS)) { | ||
45 | switch (nv_mclass(parent->parent)) { | ||
46 | default: | ||
47 | return -EINVAL; | ||
48 | } | ||
49 | } else | ||
50 | return 0; | ||
51 | |||
52 | return ret; | ||
53 | } | ||
54 | |||
55 | static int | ||
34 | nvc0_dmaeng_ctor(struct nouveau_object *parent, struct nouveau_object *engine, | 56 | nvc0_dmaeng_ctor(struct nouveau_object *parent, struct nouveau_object *engine, |
35 | struct nouveau_oclass *oclass, void *data, u32 size, | 57 | struct nouveau_oclass *oclass, void *data, u32 size, |
36 | struct nouveau_object **pobject) | 58 | struct nouveau_object **pobject) |
@@ -44,6 +66,7 @@ nvc0_dmaeng_ctor(struct nouveau_object *parent, struct nouveau_object *engine, | |||
44 | return ret; | 66 | return ret; |
45 | 67 | ||
46 | nv_engine(priv)->sclass = nouveau_dmaobj_sclass; | 68 | nv_engine(priv)->sclass = nouveau_dmaobj_sclass; |
69 | priv->base.bind = nvc0_dmaobj_bind; | ||
47 | return 0; | 70 | return 0; |
48 | } | 71 | } |
49 | 72 | ||