Commit 5132f377 authored by Ben Skeggs's avatar Ben Skeggs

drm/nve0/fifo: initial implementation

Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
parent d0f3c7e4
...@@ -17,6 +17,7 @@ nouveau-y := nouveau_drv.o nouveau_state.o nouveau_channel.o nouveau_mem.o \ ...@@ -17,6 +17,7 @@ nouveau-y := nouveau_drv.o nouveau_state.o nouveau_channel.o nouveau_mem.o \
nv04_fb.o nv10_fb.o nv20_fb.o nv30_fb.o nv40_fb.o \ nv04_fb.o nv10_fb.o nv20_fb.o nv30_fb.o nv40_fb.o \
nv50_fb.o nvc0_fb.o \ nv50_fb.o nvc0_fb.o \
nv04_fifo.o nv10_fifo.o nv40_fifo.o nv50_fifo.o nvc0_fifo.o \ nv04_fifo.o nv10_fifo.o nv40_fifo.o nv50_fifo.o nvc0_fifo.o \
nve0_fifo.o \
nv04_graph.o nv10_graph.o nv20_graph.o \ nv04_graph.o nv10_graph.o nv20_graph.o \
nv40_graph.o nv50_graph.o nvc0_graph.o \ nv40_graph.o nv50_graph.o nvc0_graph.o \
nv40_grctx.o nv50_grctx.o nvc0_grctx.o \ nv40_grctx.o nv50_grctx.o nvc0_grctx.o \
......
...@@ -70,7 +70,7 @@ struct nouveau_mem; ...@@ -70,7 +70,7 @@ struct nouveau_mem;
#define MAX_NUM_DCB_ENTRIES 16 #define MAX_NUM_DCB_ENTRIES 16
#define NOUVEAU_MAX_CHANNEL_NR 128 #define NOUVEAU_MAX_CHANNEL_NR 4096
#define NOUVEAU_MAX_TILE_NR 15 #define NOUVEAU_MAX_TILE_NR 15
struct nouveau_mem { struct nouveau_mem {
...@@ -1260,6 +1260,14 @@ extern void nvc0_fifo_destroy_context(struct nouveau_channel *); ...@@ -1260,6 +1260,14 @@ extern void nvc0_fifo_destroy_context(struct nouveau_channel *);
extern int nvc0_fifo_load_context(struct nouveau_channel *); extern int nvc0_fifo_load_context(struct nouveau_channel *);
extern int nvc0_fifo_unload_context(struct drm_device *); extern int nvc0_fifo_unload_context(struct drm_device *);
/* nve0_fifo.c */
extern int nve0_fifo_init(struct drm_device *);
extern void nve0_fifo_takedown(struct drm_device *);
extern int nve0_fifo_channel_id(struct drm_device *);
extern int nve0_fifo_create_context(struct nouveau_channel *);
extern void nve0_fifo_destroy_context(struct nouveau_channel *);
extern int nve0_fifo_unload_context(struct drm_device *);
/* nv04_graph.c */ /* nv04_graph.c */
extern int nv04_graph_create(struct drm_device *); extern int nv04_graph_create(struct drm_device *);
extern int nv04_graph_object_new(struct nouveau_channel *, int, u32, u16); extern int nv04_graph_object_new(struct nouveau_channel *, int, u32, u16);
......
...@@ -496,13 +496,17 @@ static int nouveau_init_engine_ptrs(struct drm_device *dev) ...@@ -496,13 +496,17 @@ static int nouveau_init_engine_ptrs(struct drm_device *dev)
engine->timer.takedown = nv04_timer_takedown; engine->timer.takedown = nv04_timer_takedown;
engine->fb.init = nvc0_fb_init; engine->fb.init = nvc0_fb_init;
engine->fb.takedown = nvc0_fb_takedown; engine->fb.takedown = nvc0_fb_takedown;
engine->fifo.channels = 0; engine->fifo.channels = 4096;
engine->fifo.init = nouveau_stub_init; engine->fifo.init = nve0_fifo_init;
engine->fifo.takedown = nouveau_stub_takedown; engine->fifo.takedown = nve0_fifo_takedown;
engine->fifo.disable = nvc0_fifo_disable; engine->fifo.disable = nvc0_fifo_disable;
engine->fifo.enable = nvc0_fifo_enable; engine->fifo.enable = nvc0_fifo_enable;
engine->fifo.reassign = nvc0_fifo_reassign; engine->fifo.reassign = nvc0_fifo_reassign;
engine->fifo.unload_context = nouveau_stub_init; engine->fifo.channel_id = nve0_fifo_channel_id;
engine->fifo.create_context = nve0_fifo_create_context;
engine->fifo.destroy_context = nve0_fifo_destroy_context;
engine->fifo.load_context = nvc0_fifo_load_context;
engine->fifo.unload_context = nve0_fifo_unload_context;
engine->display.early_init = nouveau_stub_init; engine->display.early_init = nouveau_stub_init;
engine->display.late_takedown = nouveau_stub_takedown; engine->display.late_takedown = nouveau_stub_takedown;
engine->display.create = nvd0_display_create; engine->display.create = nvd0_display_create;
......
This diff is collapsed.
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