Commit 93187450 authored by Ben Skeggs's avatar Ben Skeggs

drm/nv50: rename nv84_mpeg to nv50_mpeg

In preparation for adding 0x50 support.
Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
parent c0924326
......@@ -21,7 +21,7 @@ nouveau-y := nouveau_drv.o nouveau_state.o nouveau_channel.o nouveau_mem.o \
nv40_grctx.o nv50_grctx.o nvc0_grctx.o \
nv84_crypt.o \
nva3_copy.o nvc0_copy.o \
nv40_mpeg.o nv84_mpeg.o \
nv40_mpeg.o nv50_mpeg.o \
nv04_instmem.o nv50_instmem.o nvc0_instmem.o \
nv50_evo.o nv50_crtc.o nv50_dac.o nv50_sor.o \
nv50_cursor.o nv50_display.o \
......
......@@ -1158,8 +1158,8 @@ extern int nvc0_copy_create(struct drm_device *dev, int engine);
/* nv40_mpeg.c */
extern int nv40_mpeg_create(struct drm_device *dev);
/* nv84_mpeg.c */
extern int nv84_mpeg_create(struct drm_device *dev);
/* nv50_mpeg.c */
extern int nv50_mpeg_create(struct drm_device *dev);
/* nv04_instmem.c */
extern int nv04_instmem_init(struct drm_device *);
......
......@@ -622,7 +622,7 @@ nouveau_card_init(struct drm_device *dev)
else
if (dev_priv->card_type == NV_50 && dev_priv->chipset > 0x50 &&
(dev_priv->chipset < 0x98 || dev_priv->chipset == 0xa0))
nv84_mpeg_create(dev);
nv50_mpeg_create(dev);
if (!nouveau_noaccel) {
for (e = 0; e < NVOBJ_ENGINE_NR; e++) {
......
......@@ -26,12 +26,12 @@
#include "nouveau_drv.h"
#include "nouveau_ramht.h"
struct nv84_mpeg_engine {
struct nv50_mpeg_engine {
struct nouveau_exec_engine base;
};
static int
nv84_mpeg_context_new(struct nouveau_channel *chan, int engine)
nv50_mpeg_context_new(struct nouveau_channel *chan, int engine)
{
struct drm_device *dev = chan->dev;
struct drm_nouveau_private *dev_priv = dev->dev_private;
......@@ -62,7 +62,7 @@ nv84_mpeg_context_new(struct nouveau_channel *chan, int engine)
}
static void
nv84_mpeg_context_del(struct nouveau_channel *chan, int engine)
nv50_mpeg_context_del(struct nouveau_channel *chan, int engine)
{
struct drm_nouveau_private *dev_priv = chan->dev->dev_private;
struct nouveau_gpuobj *ctx = chan->engctx[engine];
......@@ -90,7 +90,7 @@ nv84_mpeg_context_del(struct nouveau_channel *chan, int engine)
}
static int
nv84_mpeg_object_new(struct nouveau_channel *chan, int engine,
nv50_mpeg_object_new(struct nouveau_channel *chan, int engine,
u32 handle, u16 class)
{
struct drm_device *dev = chan->dev;
......@@ -116,13 +116,13 @@ nv84_mpeg_object_new(struct nouveau_channel *chan, int engine,
}
static void
nv84_mpeg_tlb_flush(struct drm_device *dev, int engine)
nv50_mpeg_tlb_flush(struct drm_device *dev, int engine)
{
nv50_vm_flush_engine(dev, 0x08);
}
static int
nv84_mpeg_init(struct drm_device *dev, int engine)
nv50_mpeg_init(struct drm_device *dev, int engine)
{
nv_wr32(dev, 0x00b32c, 0x00000000);
nv_wr32(dev, 0x00b314, 0x00000100);
......@@ -147,7 +147,7 @@ nv84_mpeg_init(struct drm_device *dev, int engine)
}
static int
nv84_mpeg_fini(struct drm_device *dev, int engine)
nv50_mpeg_fini(struct drm_device *dev, int engine)
{
/*XXX: context save for s/r */
nv_mask(dev, 0x00b32c, 0x00000001, 0x00000000);
......@@ -156,7 +156,7 @@ nv84_mpeg_fini(struct drm_device *dev, int engine)
}
static void
nv84_mpeg_isr(struct drm_device *dev)
nv50_mpeg_isr(struct drm_device *dev)
{
u32 stat = nv_rd32(dev, 0x00b100);
u32 type = nv_rd32(dev, 0x00b230);
......@@ -183,9 +183,9 @@ nv84_mpeg_isr(struct drm_device *dev)
}
static void
nv84_mpeg_destroy(struct drm_device *dev, int engine)
nv50_mpeg_destroy(struct drm_device *dev, int engine)
{
struct nv84_mpeg_engine *pmpeg = nv_engine(dev, engine);
struct nv50_mpeg_engine *pmpeg = nv_engine(dev, engine);
nouveau_irq_unregister(dev, 0);
......@@ -194,23 +194,23 @@ nv84_mpeg_destroy(struct drm_device *dev, int engine)
}
int
nv84_mpeg_create(struct drm_device *dev)
nv50_mpeg_create(struct drm_device *dev)
{
struct nv84_mpeg_engine *pmpeg;
struct nv50_mpeg_engine *pmpeg;
pmpeg = kzalloc(sizeof(*pmpeg), GFP_KERNEL);
if (!pmpeg)
return -ENOMEM;
pmpeg->base.destroy = nv84_mpeg_destroy;
pmpeg->base.init = nv84_mpeg_init;
pmpeg->base.fini = nv84_mpeg_fini;
pmpeg->base.context_new = nv84_mpeg_context_new;
pmpeg->base.context_del = nv84_mpeg_context_del;
pmpeg->base.object_new = nv84_mpeg_object_new;
pmpeg->base.tlb_flush = nv84_mpeg_tlb_flush;
pmpeg->base.destroy = nv50_mpeg_destroy;
pmpeg->base.init = nv50_mpeg_init;
pmpeg->base.fini = nv50_mpeg_fini;
pmpeg->base.context_new = nv50_mpeg_context_new;
pmpeg->base.context_del = nv50_mpeg_context_del;
pmpeg->base.object_new = nv50_mpeg_object_new;
pmpeg->base.tlb_flush = nv50_mpeg_tlb_flush;
nouveau_irq_register(dev, 0, nv84_mpeg_isr);
nouveau_irq_register(dev, 0, nv50_mpeg_isr);
NVOBJ_ENGINE_ADD(dev, MPEG, &pmpeg->base);
NVOBJ_CLASS(dev, 0x8274, MPEG);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment