(void *) &IMG_TRANS;
S3SAVAccelInit() {/* Set-up our GE command primitive */        if (vgaBitsPerPixel == 8) {      s3vPriv.PlaneMask = 0xFF;      }    else if (vgaBitsPerPixel == 16) {      s3vPriv.PlaneMask = 0xFFFF;      }    else if (vgaBitsPerPixel == 24) {      s3vPriv.PlaneMask = 0xFFFFFF;      }    else if (vgaBitsPerPixel == 32) {      s3vPriv.PlaneMask = 0xFFFFFFFF;      }    /* General acceleration flags */    xf86AccelInfoRec.Flags = PIXMAP_CACHE         | BACKGROUND_OPERATIONS         | COP_FRAMEBUFFER_CONCURRENCY         | NO_SYNC_AFTER_CPU_COLOR_EXPAND         | HARDWARE_PATTERN_BIT_ORDER_MSBFIRST         | HARDWARE_PATTERN_PROGRAMMED_BITS         | HARDWARE_PATTERN_SCREEN_ORIGIN         | HARDWARE_PATTERN_MONO_TRANSPARENCY	 | USE_TWO_POINT_LINE 	 | TWO_POINT_LINE_NOT_LAST	 | HARDWARE_CLIP_LINE	 ;     xf86AccelInfoRec.Sync = S3SAVAccelSync;    /* ScreenToScreen copies */#if 1    xf86AccelInfoRec.SetupForScreenToScreenCopy =        S3SAVSetupForScreenToScreenCopy;    xf86AccelInfoRec.SubsequentScreenToScreenCopy =        S3SAVSubsequentScreenToScreenCopy;    xf86GCInfoRec.CopyAreaFlags = NO_PLANEMASK;#endif    /* Filled rectangles */#if 1    xf86AccelInfoRec.SetupForFillRectSolid =         S3SAVSetupForFillRectSolid;    xf86AccelInfoRec.SubsequentFillRectSolid =         S3SAVSubsequentFillRectSolid;    xf86GCInfoRec.PolyFillRectSolidFlags = NO_PLANEMASK;#endif    /* ImageWrite no sync required */#if 1    xf86AccelInfoRec.ImageWrite =        SavageImageWrite;#endif    /* Bresenham lines */#if 1    xf86AccelInfoRec.SubsequentBresenhamLine =        SavageSubsequentBresenhamLine;    xf86AccelInfoRec.ErrorTermBits =	16;#endif    xf86AccelInfoRec.ColorExpandFlags = SCANLINE_PAD_DWORD |					CPU_TRANSFER_PAD_DWORD | 					VIDEO_SOURCE_GRANULARITY_PIXEL |					LEFT_EDGE_CLIPPING;    /* WriteBitmap color expand */#if 1    xf86AccelInfoRec.WriteBitmap =        SavageWriteBitmapCPUToScreenColorExpand;#endif#if 0    xf86AccelInfoRec.SetupForScreenToScreenColorExpand =             S3SAVSetupForScreenToScreenColorExpand;    xf86AccelInfoRec.SubsequentScreenToScreenColorExpand =             S3SAVSubsequentCPUToScreenColorExpand;#endif#if 0    xf86AccelInfoRec.SetupForCPUToScreenColorExpand =             S3SAVSetupForCPUToScreenColorExpand;    xf86AccelInfoRec.SubsequentCPUToScreenColorExpand =             S3SAVSubsequentCPUToScreenColorExpand;    xf86AccelInfoRec.CPUToScreenColorExpandBase = s3vPriv.BciMem;             (void *) &IMG_TRANS;    xf86AccelInfoRec.CPUToScreenColorExpandRange = 128 * 1024;#endif     /* These are the 8x8 pattern fills using color expansion */#if 1    xf86AccelInfoRec.SetupFor8x8PatternColorExpand =             S3SAVSetupFor8x8PatternColorExpand;    xf86AccelInfoRec.Subsequent8x8PatternColorExpand =             S3SAVSubsequent8x8PatternColorExpand;  #endif    /* These are the 8x8 color pattern fills */#if 1    xf86AccelInfoRec.SetupForFill8x8Pattern =             S3SAVSetupForFill8x8Pattern;    xf86AccelInfoRec.SubsequentFill8x8Pattern =             S3SAVSubsequentFill8x8Pattern; #endif    /* These are the accelerated line functions */    xf86AccelInfoRec.SubsequentTwoPointLine = 	    S3SAVSubsequentTwoPointLine;    xf86AccelInfoRec.SetClippingRectangle =             S3SAVSetClippingRectangle;#if 0    xf86AccelInfoRec.SubsequentFillTrapezoidSolid =             S3SAVSubsequentFillTrapezoidSolid; #endif    /*     * Finally, we set up the video memory space available to the pixmap     * cache. In this case, all memory from the end of the virtual screen     * to the end of the command overflow buffer can be used. If you haven't     * enabled the PIXMAP_CACHE flag, then these lines can be omitted.     */     if( s3vPriv.chip == S3_SAVAGE4 ) {	 cob.Index = 2 /*4*/;	 cob.Size = 0x8000 << cob.Index;     }     else {         cob.Index = 7;	 cob.Size = 0x400 << cob.Index;     }     /* The command overflow buffer must be placed at the end of RAM. */     cob.Offset = (vga256InfoRec.videoRam << 10) - cob.Size;     xf86InitPixmapCache(&vga256InfoRec, vga256InfoRec.virtualY *	vga256InfoRec.displayWidth * vga256InfoRec.bitsPerPixel / 8,	cob.Offset);     /* And these are screen parameters used to setup the GE */     s3vPriv.Width = vga256InfoRec.displayWidth;     s3vPriv.Bpp = vgaBitsPerPixel / 8;     s3vPriv.Bpl = s3vPriv.Width * s3vPriv.Bpp;     s3vPriv.ScissB = (vga256InfoRec.videoRam * 1024 - 4096 - cob.Size) / s3vPriv.Bpl;     if (s3vPriv.ScissB > 2047)         s3vPriv.ScissB = 2047;}