Commiting a few minor fixes to glut fbdev (segfault on a separate stack)
Updated all drivers that used the old _ac_ functions to use the new _vbo_ functions. I know this fixed the fbdev driver, it looks like it might fix some other drivers too.
This commit is contained in:
+16
-1
@@ -173,6 +173,9 @@ void glutInit (int *argcp, char **argv)
|
||||
int RequiredWidth = 0, RequiredHeight;
|
||||
char *fbdev;
|
||||
|
||||
stack_t stack;
|
||||
struct sigaction sa;
|
||||
|
||||
/* parse out args */
|
||||
for (i = 1; i < *argcp;) {
|
||||
if (!strcmp(argv[i], "-geometry")) {
|
||||
@@ -239,7 +242,19 @@ void glutInit (int *argcp, char **argv)
|
||||
gettimeofday(&StartTime, 0);
|
||||
atexit(Cleanup);
|
||||
|
||||
signal(SIGSEGV, CrashHandler);
|
||||
/* set up SIGSEGV to use alternate stack */
|
||||
stack.ss_flags = 0;
|
||||
stack.ss_size = SIGSTKSZ;
|
||||
if(!(stack.ss_sp = malloc(SIGSTKSZ)))
|
||||
sprintf(exiterror, "Failed to allocate alternate stack for SIGSEGV!\n");
|
||||
|
||||
sigaltstack(&stack, NULL);
|
||||
|
||||
sa.sa_handler = CrashHandler;
|
||||
sa.sa_flags = SA_ONSTACK;
|
||||
sigemptyset(&sa.sa_mask);
|
||||
sigaction(SIGSEGV, &sa, NULL);
|
||||
|
||||
signal(SIGINT, CrashHandler);
|
||||
signal(SIGTERM, CrashHandler);
|
||||
signal(SIGABRT, CrashHandler);
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -43,7 +43,7 @@ extern "C" {
|
||||
#include "texobj.h"
|
||||
#include "teximage.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast/swrast.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast/s_context.h"
|
||||
@@ -344,7 +344,7 @@ BGLView::BGLView(BRect rect, char *name,
|
||||
/* Initialize the software rasterizer and helper modules.
|
||||
*/
|
||||
_swrast_CreateContext(ctx);
|
||||
_ac_CreateContext(ctx);
|
||||
_vbo_CreateContext(ctx);
|
||||
_tnl_CreateContext(ctx);
|
||||
_swsetup_CreateContext(ctx);
|
||||
_swsetup_Wakeup(ctx);
|
||||
@@ -830,7 +830,7 @@ void MesaDriver::UpdateState( GLcontext *ctx, GLuint new_state )
|
||||
|
||||
_swrast_InvalidateState( ctx, new_state );
|
||||
_swsetup_InvalidateState( ctx, new_state );
|
||||
_ac_InvalidateState( ctx, new_state );
|
||||
_vbo_InvalidateState( ctx, new_state );
|
||||
_tnl_InvalidateState( ctx, new_state );
|
||||
|
||||
if (ctx->Color.DrawBuffer[0] == GL_FRONT) {
|
||||
|
||||
@@ -374,7 +374,7 @@ dfbUpdateState( GLcontext *ctx, GLuint new_state )
|
||||
{
|
||||
_swrast_InvalidateState( ctx, new_state );
|
||||
_swsetup_InvalidateState( ctx, new_state );
|
||||
_ac_InvalidateState( ctx, new_state );
|
||||
_vbo_InvalidateState( ctx, new_state );
|
||||
_tnl_InvalidateState( ctx, new_state );
|
||||
}
|
||||
|
||||
@@ -787,7 +787,7 @@ directfbgl_create_context( GLcontext *context,
|
||||
}
|
||||
|
||||
_swrast_CreateContext( context );
|
||||
_ac_CreateContext( context );
|
||||
_vbo_CreateContext( context );
|
||||
_tnl_CreateContext( context );
|
||||
_swsetup_CreateContext( context );
|
||||
_swsetup_Wakeup( context );
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
#include "texformat.h"
|
||||
#include "teximage.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast/swrast.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "tnl/tnl.h"
|
||||
@@ -143,7 +143,7 @@ update_state( GLcontext *ctx, GLuint new_state )
|
||||
/* not much to do here - pass it on */
|
||||
_swrast_InvalidateState( ctx, new_state );
|
||||
_swsetup_InvalidateState( ctx, new_state );
|
||||
_ac_InvalidateState( ctx, new_state );
|
||||
_vbo_InvalidateState( ctx, new_state );
|
||||
_tnl_InvalidateState( ctx, new_state );
|
||||
}
|
||||
|
||||
@@ -776,7 +776,7 @@ glFBDevCreateContext( const GLFBDevVisualPtr visual, GLFBDevContextPtr share )
|
||||
/* Create module contexts */
|
||||
glctx = (GLcontext *) &ctx->glcontext;
|
||||
_swrast_CreateContext( glctx );
|
||||
_ac_CreateContext( glctx );
|
||||
_vbo_CreateContext( glctx );
|
||||
_tnl_CreateContext( glctx );
|
||||
_swsetup_CreateContext( glctx );
|
||||
_swsetup_Wakeup( glctx );
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include "tnl/tnl.h"
|
||||
#include "tnl/t_context.h"
|
||||
#include "tnl/t_pipeline.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "teximage.h"
|
||||
#include "texformat.h"
|
||||
#include "texstore.h"
|
||||
@@ -563,7 +563,7 @@ ggi_mesa_context_t ggiMesaCreateContext(ggi_visual_t vis)
|
||||
_mesa_enable_sw_extensions(ctx->gl_ctx);
|
||||
|
||||
_swrast_CreateContext(ctx->gl_ctx);
|
||||
_ac_CreateContext(ctx->gl_ctx);
|
||||
_vbo_CreateContext(ctx->gl_ctx);
|
||||
_tnl_CreateContext(ctx->gl_ctx);
|
||||
_swsetup_CreateContext(ctx->gl_ctx);
|
||||
|
||||
|
||||
@@ -1783,7 +1783,7 @@ fxDDInitFxMesaContext(fxMesaContext fxMesa)
|
||||
/* Initialize the software rasterizer and helper modules.
|
||||
*/
|
||||
_swrast_CreateContext(ctx);
|
||||
_ac_CreateContext(ctx);
|
||||
_vbo_CreateContext(ctx);
|
||||
_tnl_CreateContext(ctx);
|
||||
_swsetup_CreateContext(ctx);
|
||||
|
||||
@@ -1826,7 +1826,7 @@ fxDDDestroyFxMesaContext(fxMesaContext fxMesa)
|
||||
{
|
||||
_swsetup_DestroyContext(fxMesa->glCtx);
|
||||
_tnl_DestroyContext(fxMesa->glCtx);
|
||||
_ac_DestroyContext(fxMesa->glCtx);
|
||||
_vbo_DestroyContext(fxMesa->glCtx);
|
||||
_swrast_DestroyContext(fxMesa->glCtx);
|
||||
|
||||
if (fxMesa->state)
|
||||
@@ -2101,7 +2101,7 @@ fxDDUpdateDDPointers(GLcontext * ctx, GLuint new_state)
|
||||
}
|
||||
|
||||
_swrast_InvalidateState(ctx, new_state);
|
||||
_ac_InvalidateState(ctx, new_state);
|
||||
_vbo_InvalidateState(ctx, new_state);
|
||||
_tnl_InvalidateState(ctx, new_state);
|
||||
_swsetup_InvalidateState(ctx, new_state);
|
||||
|
||||
|
||||
@@ -859,9 +859,9 @@ EXPORTS
|
||||
wglGetExtensionsStringARB
|
||||
;
|
||||
; Mesa internals - mostly for OSMESA
|
||||
_ac_CreateContext
|
||||
_ac_DestroyContext
|
||||
_ac_InvalidateState
|
||||
_vbo_CreateContext
|
||||
_vbo_DestroyContext
|
||||
_vbo_InvalidateState
|
||||
_glapi_check_multithread
|
||||
_glapi_get_context
|
||||
_glapi_get_proc_address
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
#include "framebuffer.h"
|
||||
#include "renderbuffer.h"
|
||||
#include "drivers/common/driverfuncs.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast/swrast.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "tnl/tnl.h"
|
||||
@@ -1125,7 +1125,7 @@ static void wmesa_update_state(GLcontext *ctx, GLuint new_state)
|
||||
{
|
||||
_swrast_InvalidateState(ctx, new_state);
|
||||
_swsetup_InvalidateState(ctx, new_state);
|
||||
_ac_InvalidateState(ctx, new_state);
|
||||
_vbo_InvalidateState(ctx, new_state);
|
||||
_tnl_InvalidateState(ctx, new_state);
|
||||
|
||||
/* TODO - This code is not complete yet because I
|
||||
@@ -1242,7 +1242,7 @@ WMesaContext WMesaCreateContext(HDC hDC,
|
||||
|
||||
/* Initialize the software rasterizer and helper modules. */
|
||||
if (!_swrast_CreateContext(ctx) ||
|
||||
!_ac_CreateContext(ctx) ||
|
||||
!_vbo_CreateContext(ctx) ||
|
||||
!_tnl_CreateContext(ctx) ||
|
||||
!_swsetup_CreateContext(ctx)) {
|
||||
_mesa_free_context_data(ctx);
|
||||
@@ -1285,7 +1285,7 @@ void WMesaDestroyContext( WMesaContext pwc )
|
||||
|
||||
_swsetup_DestroyContext(ctx);
|
||||
_tnl_DestroyContext(ctx);
|
||||
_ac_DestroyContext(ctx);
|
||||
_vbo_DestroyContext(ctx);
|
||||
_swrast_DestroyContext(ctx);
|
||||
|
||||
_mesa_free_context_data(ctx);
|
||||
|
||||
@@ -1453,7 +1453,7 @@ SkipPrimaryCreate:
|
||||
#ifdef _USE_GLD3_WGL
|
||||
// Init Mesa internals
|
||||
_swrast_CreateContext( lpCtx->glCtx );
|
||||
_ac_CreateContext( lpCtx->glCtx );
|
||||
_vbo_CreateContext( lpCtx->glCtx );
|
||||
_tnl_CreateContext( lpCtx->glCtx );
|
||||
_swsetup_CreateContext( lpCtx->glCtx );
|
||||
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
#include "texformat.h"
|
||||
#include "teximage.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast_setup/ss_context.h"
|
||||
#include "tnl/tnl.h"
|
||||
@@ -868,7 +868,7 @@ void gld_update_state_DX7(
|
||||
return;
|
||||
|
||||
_swsetup_InvalidateState( ctx, new_state );
|
||||
_ac_InvalidateState( ctx, new_state );
|
||||
_vbo_InvalidateState( ctx, new_state );
|
||||
_tnl_InvalidateState( ctx, new_state );
|
||||
|
||||
// SetupIndex will be used in the pipelines for choosing setup function
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
#include "mtypes.h"
|
||||
#include "texformat.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast_setup/ss_context.h"
|
||||
#include "tnl/tnl.h"
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
#include "mtypes.h"
|
||||
#include "texformat.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast/swrast.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast_setup/ss_context.h"
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
#include "texformat.h"
|
||||
#include "teximage.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast_setup/ss_context.h"
|
||||
#include "tnl/tnl.h"
|
||||
@@ -850,7 +850,7 @@ void gld_update_state_DX8(
|
||||
return;
|
||||
|
||||
_swsetup_InvalidateState( ctx, new_state );
|
||||
_ac_InvalidateState( ctx, new_state );
|
||||
_vbo_InvalidateState( ctx, new_state );
|
||||
_tnl_InvalidateState( ctx, new_state );
|
||||
|
||||
// SetupIndex will be used in the pipelines for choosing setup function
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
#include "mtypes.h"
|
||||
#include "texformat.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast_setup/ss_context.h"
|
||||
#include "tnl/tnl.h"
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
#include "mtypes.h"
|
||||
#include "texformat.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast/swrast.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast_setup/ss_context.h"
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
#include "texformat.h"
|
||||
#include "teximage.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast_setup/ss_context.h"
|
||||
#include "tnl/tnl.h"
|
||||
@@ -876,7 +876,7 @@ void gld_update_state_DX9(
|
||||
return;
|
||||
|
||||
_swsetup_InvalidateState( ctx, new_state );
|
||||
_ac_InvalidateState( ctx, new_state );
|
||||
_vbo_InvalidateState( ctx, new_state );
|
||||
_tnl_InvalidateState( ctx, new_state );
|
||||
|
||||
// SetupIndex will be used in the pipelines for choosing setup function
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
#include "mtypes.h"
|
||||
#include "texformat.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast_setup/ss_context.h"
|
||||
#include "tnl/tnl.h"
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
#include "mtypes.h"
|
||||
#include "texformat.h"
|
||||
#include "texstore.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast/swrast.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast_setup/ss_context.h"
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
#include "texformat.h"
|
||||
#include "texstore.h"
|
||||
#include "teximage.h"
|
||||
#include "array_cache/acache.h"
|
||||
#include "vbo/vbo.h"
|
||||
#include "swrast/swrast.h"
|
||||
#include "swrast_setup/swrast_setup.h"
|
||||
#include "swrast/s_context.h"
|
||||
@@ -1321,7 +1321,7 @@ static void wmesa_update_state(
|
||||
{
|
||||
_swrast_InvalidateState( ctx, new_state );
|
||||
_swsetup_InvalidateState( ctx, new_state );
|
||||
_ac_InvalidateState( ctx, new_state );
|
||||
_vbo_InvalidateState( ctx, new_state );
|
||||
_tnl_InvalidateState( ctx, new_state );
|
||||
}
|
||||
|
||||
@@ -1631,7 +1631,7 @@ BOOL gldInitialiseMesa_MesaSW(
|
||||
_mesa_enable_1_3_extensions(ctx);
|
||||
|
||||
// _swrast_CreateContext( ctx );
|
||||
// _ac_CreateContext( ctx );
|
||||
// _vbo_CreateContext( ctx );
|
||||
// _tnl_CreateContext( ctx );
|
||||
// _swsetup_CreateContext( ctx );
|
||||
|
||||
|
||||
@@ -24,9 +24,9 @@ EXPORTS
|
||||
|
||||
;
|
||||
; Mesa internals - mostly for OSMESA
|
||||
_ac_CreateContext
|
||||
_ac_DestroyContext
|
||||
_ac_InvalidateState
|
||||
_vbo_CreateContext
|
||||
_vbo_DestroyContext
|
||||
_vbo_InvalidateState
|
||||
_glapi_get_context
|
||||
_glapi_get_proc_address
|
||||
_mesa_buffer_data
|
||||
|
||||
Reference in New Issue
Block a user