summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/nv50
diff options
context:
space:
mode:
authorZack Rusin <zackr@vmware.com>2009-01-30 15:56:00 -0500
committerZack Rusin <zackr@vmware.com>2009-01-30 15:57:33 -0500
commitadfbba476db1fc55006efb748656ebb1a481d143 (patch)
tree98ebea9330cf69f649d49cb8995d2e95d14481db /src/gallium/drivers/nv50
parent3cfaccf92a2e0f5ea395a2c95c323a8b762fc156 (diff)
downloadexternal_mesa3d-adfbba476db1fc55006efb748656ebb1a481d143.zip
external_mesa3d-adfbba476db1fc55006efb748656ebb1a481d143.tar.gz
external_mesa3d-adfbba476db1fc55006efb748656ebb1a481d143.tar.bz2
gallium: make p_winsys internal
move it to pipe/internal/p_winsys_screen.h and start converting the state trackers to the screen usage
Diffstat (limited to 'src/gallium/drivers/nv50')
-rw-r--r--src/gallium/drivers/nv50/nv50_context.c2
-rw-r--r--src/gallium/drivers/nv50/nv50_miptree.c4
-rw-r--r--src/gallium/drivers/nv50/nv50_program.c6
-rw-r--r--src/gallium/drivers/nv50/nv50_query.c6
-rw-r--r--src/gallium/drivers/nv50/nv50_screen.c6
-rw-r--r--src/gallium/drivers/nv50/nv50_surface.c6
-rw-r--r--src/gallium/drivers/nv50/nv50_vbo.c2
7 files changed, 16 insertions, 16 deletions
diff --git a/src/gallium/drivers/nv50/nv50_context.c b/src/gallium/drivers/nv50/nv50_context.c
index b02c53f..9977623 100644
--- a/src/gallium/drivers/nv50/nv50_context.c
+++ b/src/gallium/drivers/nv50/nv50_context.c
@@ -22,7 +22,7 @@
#include "draw/draw_context.h"
#include "pipe/p_defines.h"
-#include "pipe/p_winsys.h"
+#include "pipe/internal/p_winsys_screen.h"
#include "nv50_context.h"
#include "nv50_screen.h"
diff --git a/src/gallium/drivers/nv50/nv50_miptree.c b/src/gallium/drivers/nv50/nv50_miptree.c
index 3965dad..7770fcc 100644
--- a/src/gallium/drivers/nv50/nv50_miptree.c
+++ b/src/gallium/drivers/nv50/nv50_miptree.c
@@ -88,14 +88,14 @@ nv50_miptree_create(struct pipe_screen *pscreen, const struct pipe_texture *tmp)
size = align(size, 64);
size *= align(pt->height[l], 8) * pt->block.size;
- lvl->image[i] = ws->_buffer_create(ws, 256, 0, size);
+ lvl->image[i] = ws->buffer_create(ws, 256, 0, size);
lvl->image_offset[i] = mt->total_size;
mt->total_size += size;
}
}
- mt->buffer = ws->_buffer_create(ws, 256, usage, mt->total_size);
+ mt->buffer = ws->buffer_create(ws, 256, usage, mt->total_size);
if (!mt->buffer) {
FREE(mt);
return NULL;
diff --git a/src/gallium/drivers/nv50/nv50_program.c b/src/gallium/drivers/nv50/nv50_program.c
index 73867cf..7686f74 100644
--- a/src/gallium/drivers/nv50/nv50_program.c
+++ b/src/gallium/drivers/nv50/nv50_program.c
@@ -1581,11 +1581,11 @@ nv50_program_validate_data(struct nv50_context *nv50, struct nv50_program *p)
}
if (p->param_nr) {
- float *map = ws->_buffer_map(ws, nv50->constbuf[p->type],
+ float *map = ws->buffer_map(ws, nv50->constbuf[p->type],
PIPE_BUFFER_USAGE_CPU_READ);
nv50_program_upload_data(nv50, map, p->data->start,
p->param_nr);
- ws->_buffer_unmap(ws, nv50->constbuf[p->type]);
+ ws->buffer_unmap(ws, nv50->constbuf[p->type]);
}
if (p->immd_nr) {
@@ -1606,7 +1606,7 @@ nv50_program_validate_code(struct nv50_context *nv50, struct nv50_program *p)
boolean upload = FALSE;
if (!p->buffer) {
- p->buffer = ws->_buffer_create(ws, 0x100, 0, p->exec_size * 4);
+ p->buffer = ws->buffer_create(ws, 0x100, 0, p->exec_size * 4);
upload = TRUE;
}
diff --git a/src/gallium/drivers/nv50/nv50_query.c b/src/gallium/drivers/nv50/nv50_query.c
index b0fb346..1b3a413 100644
--- a/src/gallium/drivers/nv50/nv50_query.c
+++ b/src/gallium/drivers/nv50/nv50_query.c
@@ -47,7 +47,7 @@ nv50_query_create(struct pipe_context *pipe, unsigned type)
assert (q->type == PIPE_QUERY_OCCLUSION_COUNTER);
q->type = type;
- q->buffer = ws->_buffer_create(ws, 256, 0, 16);
+ q->buffer = ws->buffer_create(ws, 256, 0, 16);
if (!q->buffer) {
FREE(q);
return NULL;
@@ -107,11 +107,11 @@ nv50_query_result(struct pipe_context *pipe, struct pipe_query *pq,
*/
if (!q->ready) {
- uint32_t *map = ws->_buffer_map(ws, q->buffer,
+ uint32_t *map = ws->buffer_map(ws, q->buffer,
PIPE_BUFFER_USAGE_CPU_READ);
q->result = map[1];
q->ready = TRUE;
- ws->_buffer_unmap(ws, q->buffer);
+ ws->buffer_unmap(ws, q->buffer);
}
*result = q->result;
diff --git a/src/gallium/drivers/nv50/nv50_screen.c b/src/gallium/drivers/nv50/nv50_screen.c
index 3abacfc..ef46233 100644
--- a/src/gallium/drivers/nv50/nv50_screen.c
+++ b/src/gallium/drivers/nv50/nv50_screen.c
@@ -242,7 +242,7 @@ nv50_screen_create(struct pipe_winsys *ws, struct nouveau_winsys *nvws)
so_data (so, 8);
/* Shared constant buffer */
- screen->constbuf = ws->_buffer_create(ws, 0, 0, 128 * 4 * 4);
+ screen->constbuf = ws->buffer_create(ws, 0, 0, 128 * 4 * 4);
if (nvws->res_init(&screen->vp_data_heap, 0, 128)) {
NOUVEAU_ERR("Error initialising constant buffer\n");
nv50_screen_destroy(&screen->pipe);
@@ -261,7 +261,7 @@ nv50_screen_create(struct pipe_winsys *ws, struct nouveau_winsys *nvws)
* blocks. At some point we *may* want to go the NVIDIA way of doing
* things?
*/
- screen->tic = ws->_buffer_create(ws, 0, 0, 32 * 8 * 4);
+ screen->tic = ws->buffer_create(ws, 0, 0, 32 * 8 * 4);
so_method(so, screen->tesla, 0x1280, 3);
so_reloc (so, screen->tic, 0, NOUVEAU_BO_VRAM |
NOUVEAU_BO_RD | NOUVEAU_BO_HIGH, 0, 0);
@@ -275,7 +275,7 @@ nv50_screen_create(struct pipe_winsys *ws, struct nouveau_winsys *nvws)
NOUVEAU_BO_RD | NOUVEAU_BO_LOW, 0, 0);
so_data (so, 0x00000800);
- screen->tsc = ws->_buffer_create(ws, 0, 0, 32 * 8 * 4);
+ screen->tsc = ws->buffer_create(ws, 0, 0, 32 * 8 * 4);
so_method(so, screen->tesla, 0x1280, 3);
so_reloc (so, screen->tsc, 0, NOUVEAU_BO_VRAM |
NOUVEAU_BO_RD | NOUVEAU_BO_HIGH, 0, 0);
diff --git a/src/gallium/drivers/nv50/nv50_surface.c b/src/gallium/drivers/nv50/nv50_surface.c
index 743eb6e..ed6602b 100644
--- a/src/gallium/drivers/nv50/nv50_surface.c
+++ b/src/gallium/drivers/nv50/nv50_surface.c
@@ -22,7 +22,7 @@
#include "nv50_context.h"
#include "pipe/p_defines.h"
-#include "pipe/p_winsys.h"
+#include "pipe/internal/p_winsys_screen.h"
#include "pipe/p_inlines.h"
#include "util/u_tile.h"
@@ -65,7 +65,7 @@ nv50_surface_map(struct pipe_screen *screen, struct pipe_surface *ps,
{
struct pipe_winsys *ws = screen->winsys;
- return ws->_buffer_map(ws, ps->buffer, flags);
+ return ws->buffer_map(ws, ps->buffer, flags);
}
static void
@@ -73,7 +73,7 @@ nv50_surface_unmap(struct pipe_screen *pscreen, struct pipe_surface *ps)
{
struct pipe_winsys *ws = pscreen->winsys;
- ws->_buffer_unmap(ws, ps->buffer);
+ ws->buffer_unmap(ws, ps->buffer);
}
void
diff --git a/src/gallium/drivers/nv50/nv50_vbo.c b/src/gallium/drivers/nv50/nv50_vbo.c
index 86471c0..c482a4c 100644
--- a/src/gallium/drivers/nv50/nv50_vbo.c
+++ b/src/gallium/drivers/nv50/nv50_vbo.c
@@ -153,7 +153,7 @@ nv50_draw_elements(struct pipe_context *pipe,
{
struct nv50_context *nv50 = nv50_context(pipe);
struct pipe_winsys *ws = pipe->winsys;
- void *map = ws->_buffer_map(ws, indexBuffer, PIPE_BUFFER_USAGE_CPU_READ);
+ void *map = ws->buffer_map(ws, indexBuffer, PIPE_BUFFER_USAGE_CPU_READ);
nv50_state_validate(nv50);