dri: Add DRI entrypoints to create a context for a given API
[mesa.git] / src / mesa / drivers / dri / mach64 / mach64_context.c
index 11bce31b12cb33e1acf9677d7ae46d1b7e5df388..72a44d96424c6cd28fbdebe8d5519ba2afe738ea 100644 (file)
@@ -86,7 +86,8 @@ static const struct dri_extension card_extensions[] =
 
 /* Create the device specific context.
   */
-GLboolean mach64CreateContext( const __GLcontextModes *glVisual,
+GLboolean mach64CreateContext( gl_api api,
+                              const __GLcontextModes *glVisual,
                               __DRIcontext *driContextPriv,
                                void *sharedContextPrivate )
 {
@@ -211,7 +212,7 @@ GLboolean mach64CreateContext( const __GLcontextModes *glVisual,
 
    /* Allocate the vertex buffer
     */
-   mmesa->vert_buf = ALIGN_MALLOC(MACH64_BUFFER_SIZE, 32);
+   mmesa->vert_buf = _mesa_align_malloc(MACH64_BUFFER_SIZE, 32);
    if ( !mmesa->vert_buf )
       return GL_FALSE;
    mmesa->vert_used = 0;
@@ -291,7 +292,7 @@ void mach64DestroyContext( __DRIcontext *driContextPriv  )
 
       /* Free the vertex buffer */
       if ( mmesa->vert_buf )
-        ALIGN_FREE( mmesa->vert_buf );
+        _mesa_align_free( mmesa->vert_buf );
       
       /* free the Mesa context */
       mmesa->glCtx->DriverCtx = NULL;