diff options
author | Corbin Simpson <[email protected]> | 2009-03-10 02:08:59 -0700 |
---|---|---|
committer | Corbin Simpson <[email protected]> | 2009-03-10 02:08:59 -0700 |
commit | 42fc3d3fa9d7c4a9fe7e15b9ddecfd816a12f1bc (patch) | |
tree | 38ad53ae9601e9259ea5ba9c49458afd5b641730 /src/gallium/winsys | |
parent | d559796d6f13579ecf921a63d9f0c6c6342dc230 (diff) |
radeon-gallium: Unbreak non-RADEON_SOFTPIPE.
Hehe, sleep may be necessary now.
Diffstat (limited to 'src/gallium/winsys')
5 files changed, 9 insertions, 7 deletions
diff --git a/src/gallium/winsys/drm/radeon/core/radeon_buffer.c b/src/gallium/winsys/drm/radeon/core/radeon_buffer.c index 483cbc13dc7..9dca510c815 100644 --- a/src/gallium/winsys/drm/radeon/core/radeon_buffer.c +++ b/src/gallium/winsys/drm/radeon/core/radeon_buffer.c @@ -154,7 +154,7 @@ static void radeon_flush_frontbuffer(struct pipe_winsys *pipe_winsys, /* TODO: call dri2CopyRegion */ } -struct pipe_winsys* radeon_pipe_winsys(int fd) +struct radeon_winsys* radeon_pipe_winsys(int fd) { struct radeon_winsys* radeon_ws; struct radeon_bo_manager* bom; diff --git a/src/gallium/winsys/drm/radeon/core/radeon_buffer.h b/src/gallium/winsys/drm/radeon/core/radeon_buffer.h index dc56ab90cff..40ad0fc8d19 100644 --- a/src/gallium/winsys/drm/radeon/core/radeon_buffer.h +++ b/src/gallium/winsys/drm/radeon/core/radeon_buffer.h @@ -58,7 +58,7 @@ struct radeon_winsys { struct radeon_bo_manager* bom; }; -struct pipe_winsys *radeon_pipe_winsys(int fb); +struct radeon_winsys* radeon_pipe_winsys(int fb); struct pipe_surface *radeon_surface_from_handle(struct radeon_context *radeon_context, uint32_t handle, enum pipe_format format, diff --git a/src/gallium/winsys/drm/radeon/core/radeon_drm.c b/src/gallium/winsys/drm/radeon/core/radeon_drm.c index 9387932a53b..3446654e287 100644 --- a/src/gallium/winsys/drm/radeon/core/radeon_drm.c +++ b/src/gallium/winsys/drm/radeon/core/radeon_drm.c @@ -33,10 +33,10 @@ /* Create a pipe_screen. */ struct pipe_screen* radeon_create_screen(int drmFB, int pciID) { - struct pipe_winsys* winsys = radeon_pipe_winsys(drmFB); + struct radeon_winsys* winsys = radeon_pipe_winsys(drmFB); if (getenv("RADEON_SOFTPIPE")) { - return softpipe_create_screen(winsys); + return softpipe_create_screen((struct pipe_winsys*)winsys); } else { struct r300_winsys* r300 = radeon_create_r300_winsys(drmFB, winsys); FREE(winsys); diff --git a/src/gallium/winsys/drm/radeon/core/radeon_r300.c b/src/gallium/winsys/drm/radeon/core/radeon_r300.c index 9a42db51bdf..c7b6813014f 100644 --- a/src/gallium/winsys/drm/radeon/core/radeon_r300.c +++ b/src/gallium/winsys/drm/radeon/core/radeon_r300.c @@ -75,7 +75,8 @@ static void do_ioctls(struct r300_winsys* winsys, int fd) } -struct r300_winsys* radeon_create_r300_winsys(int fd, struct pipe_winsys* old_winsys) +struct r300_winsys* +radeon_create_r300_winsys(int fd, struct radeon_winsys* old_winsys) { struct r300_winsys* winsys = CALLOC_STRUCT(r300_winsys); @@ -92,7 +93,7 @@ struct r300_winsys* radeon_create_r300_winsys(int fd, struct pipe_winsys* old_wi winsys->end_cs = radeon_cs_end; winsys->flush_cs = radeon_r300_flush_cs; - winsys->base = *old_winsys; + memcpy(winsys, old_winsys, sizeof(struct radeon_winsys)); return winsys; } diff --git a/src/gallium/winsys/drm/radeon/core/radeon_r300.h b/src/gallium/winsys/drm/radeon/core/radeon_r300.h index 432b7b18331..5c373cd0848 100644 --- a/src/gallium/winsys/drm/radeon/core/radeon_r300.h +++ b/src/gallium/winsys/drm/radeon/core/radeon_r300.h @@ -31,4 +31,5 @@ #include "radeon_buffer.h" -struct r300_winsys* radeon_create_r300_winsys(int fd, struct pipe_winsys* old_winsys); +struct r300_winsys* +radeon_create_r300_winsys(int fd, struct radeon_winsys* old_winsys); |