drm/nouveau/dmaobj: move parent class check to bind() method
authorBen Skeggs <bskeggs@redhat.com>
Mon, 8 Oct 2012 02:58:23 +0000 (12:58 +1000)
committerBen Skeggs <bskeggs@redhat.com>
Wed, 28 Nov 2012 23:56:38 +0000 (09:56 +1000)
commit6c1689a08cf54e58c19eb565528a293f36f731be
tree53ecbfa8324e13c7a7af4373d2914cf5c90c9d15
parentf86770aaaa9a4d9cc68c8a9adc351ab7f47e6345
drm/nouveau/dmaobj: move parent class check to bind() method

Otherwise when nvc0- gains a bind() method (disp needs it), the fifo
engine will attempt to create a dma object for the push buffer, which
is unnecessary on fermi.

The only sane place to put these checks is in the bind method itself,
and have it unconditionally called from wherever it might be needed.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/core/engine/dmaobj/base.c
drivers/gpu/drm/nouveau/core/engine/dmaobj/nv04.c
drivers/gpu/drm/nouveau/core/engine/dmaobj/nv50.c
drivers/gpu/drm/nouveau/core/engine/fifo/base.c
drivers/gpu/drm/nouveau/core/include/engine/dmaobj.h