Oh, forgot one diff, attached now.
 Thomas

On Fri, Jul 19, 2019 at 11:26:06PM +0200, Thomas Klausner wrote:
> On Mon, Jul 15, 2019 at 02:31:13PM -0700, Alan Coopersmith wrote:
> > On 7/15/19 4:02 AM, Thomas Klausner wrote:
> > > As a datapoint:
> > 
> > Thanks for the info.
> > 
> > > Of these, the following have packages in pkgsrc:
> > > 
> > > libWindowsWM
> > 
> > This is supposed to only be useful on Cygwin, but a Cygwin package search
> > says they don't ship it, and it hasn't had a release since 2009,  so I
> > wonder if anyone uses it, or just keeps building it because no one ever
> > said "stop".
> > 
> > > libXTrap
> > 
> > Similarly, this just seems like something build because they never knew
> > what it was for - do they really have much software that adopted a
> > proposed extension for X11R5, that's been deprecated since XTEST &
> > RECORD came out in X11R6 in 1994?  (Oh, hey, time to change 15 -> 25 in
> > https://gitlab.freedesktop.org/xorg/lib/libxtrap/blob/master/README.md )
> > 
> > > rstart
> > 
> > We dropped this with a note to use ssh X-forwarding instead.
> 
> Thanks. I removed these three and xtrap from pkgsrc.
> 
> > > and the following:
> > > 
> > > beforelight
> 
> No local changes.
> 
> > > xf86-video-ark
> 
> Adaptation to latest xorg-server.
> 
> > > xf86-video-newport
> 
> Bigger diff, see attachment.
> 
> > > xf86-video-tga
> 
> Adaptation to latest xorg-server.
> 
> > > xf86-video-tseng
> 
> Adaptation to latest xorg-server, and some small diffs.
> 
> > > xf86-video-xgi
> 
> Big diff, see attachment.
> 
> > > xf86dga
> 
> No local changes.
> 
> > > xfwp
> 
> No local changes.
> 
> > > xvidtune
> 
> No changes.
> 
> > > are included in NetBSD's xsrc, probably some with patches.
> > > 
> > > I can't tell if they are there for historic reasons or if anyone is
> > > actually still using them.
> > 
> > Well, NetBSD still claims to support some of the ancient platforms for
> > those drivers, so they might be:
> > 
> >  - xf86-video-tga - DEC Alpha graphics, for mid-90's systems such as:
> >    https://en.wikipedia.org/wiki/DEC_Multia
> > 
> >  - xf86-video-newport - SGI MIPS workstation graphics:
> >    https://en.wikipedia.org/wiki/SGI_Indy#Graphics
> > 
> > but those drivers don't seem to be getting all the API/ABI updates, and
> > haven't had releases to make them compatible with any recent X server,
> > so they'd have to be patching them to make them work.  Perhaps NetBSD
> > folks who support those platforms should become their maintainers?
> 
> I usually can't even get NetBSD committers to send their diffs
> upstream to you, so making them maintainer is even less likely to have
> positive results.
> 
> I don't know what the best solution is.
> 
> Should we try getting the diffs merged? (See attachments, I can try to
> group them in commits with messages if someone will apply them.)
> 
> Cheers,
>  Thomas

> mibstore.h and its miInitializeBackingStore() have been otherwise empty
> since at least xorg-server 1.10.  remove all reference to them as the
> header is gone in xorg-server 1.18.
> 
> Index: dist/src/ark_driver.c
> ===================================================================
> RCS file: /cvsroot/xsrc/external/mit/xf86-video-ark/dist/src/ark_driver.c,v
> retrieving revision 1.1.1.4
> retrieving revision 1.2
> diff -u -r1.1.1.4 -r1.2
> --- dist/src/ark_driver.c     23 Jul 2015 01:15:49 -0000      1.1.1.4
> +++ dist/src/ark_driver.c     16 Aug 2016 01:27:46 -0000      1.2
> @@ -39,7 +39,6 @@
>  #include "compiler.h"
>  #include "mipointer.h"
>  #include "micmap.h"
> -#include "mibstore.h"
>  #include "fb.h"
>  #include "ark.h"
>  
> @@ -538,7 +537,6 @@
>  
>       fbPictureInit (pScreen, 0, 0);
>  
> -     miInitializeBackingStore(pScreen);
>       xf86SetBackingStore(pScreen);
>  
>       if (!pARK->NoAccel) {

> Index: dist/src/newport.h
> ===================================================================
> RCS file: /cvsroot/xsrc/external/mit/xf86-video-newport/dist/src/newport.h,v
> retrieving revision 1.1.1.2
> retrieving revision 1.4
> diff -u -r1.1.1.2 -r1.4
> --- dist/src/newport.h        23 Jul 2015 01:15:59 -0000      1.1.1.2
> +++ dist/src/newport.h        23 Jul 2015 01:19:16 -0000      1.4
> @@ -38,6 +38,7 @@
>  /* register definitions of the Newport card */
>  #include "newport_regs.h"
>  
> +#define NEWPORT_REGISTERS   0xf0000
>  #define NEWPORT_BASE_ADDR0  0x1f0f0000
>  #define NEWPORT_BASE_OFFSET 0x00400000
>  #define NEWPORT_MAX_BOARDS 4
> Index: dist/src/newport_cmap.c
> ===================================================================
> RCS file: 
> /cvsroot/xsrc/external/mit/xf86-video-newport/dist/src/newport_cmap.c,v
> retrieving revision 1.1.1.1
> retrieving revision 1.2
> diff -u -r1.1.1.1 -r1.2
> --- dist/src/newport_cmap.c   14 Feb 2009 03:04:46 -0000      1.1.1.1
> +++ dist/src/newport_cmap.c   6 Oct 2009 20:28:14 -0000       1.2
> @@ -71,7 +71,8 @@
>       }
>  #endif
>       for(i = 0; i < 256; i++) {
> -             NewportCmapSetRGB(pNewport->pNewportRegs, i, 
> pNewport->txt_colormap[i]);
> +             NewportCmapSetRGB(pNewport->pNewportRegs, i, 
> +                 pNewport->txt_colormap[i]);
>       }
>  }
>  
> @@ -80,8 +81,8 @@
>  static void NewportCmapFifoWait(NewportRegsPtr pNewportRegs)
>  {
>          while(1) {
> -             pNewportRegs->set.dcbmode = (NPORT_DMODE_ACM0 |  NCMAP_PROTOCOL 
> |
> -                                             NCMAP_REGADDR_SREG | 
> NPORT_DMODE_W1);
> +             pNewportRegs->set.dcbmode = (NPORT_DMODE_ACM0 | NCMAP_PROTOCOL |
> +                 NCMAP_REGADDR_SREG | NPORT_DMODE_W1);
>               if(!(pNewportRegs->set.dcbdata0.bytes.b3 & 4))
>                       break;
>          }
> @@ -91,6 +92,7 @@
>  /* set the colormap entry at addr to color */
>  void NewportCmapSetRGB( NewportRegsPtr pNewportRegs, unsigned short addr, 
> LOCO color)
>  {
> +     uint32_t colour;
>       NewportWait(pNewportRegs);      /* this one should not be necessary */
>       NewportBfwait(pNewportRegs);
>       pNewportRegs->set.dcbmode = (NPORT_DMODE_ACMALL | NCMAP_PROTOCOL |
> @@ -99,9 +101,9 @@
>       pNewportRegs->set.dcbdata0.hwords.s1 = addr;
>       pNewportRegs->set.dcbmode = (NPORT_DMODE_ACMALL | NCMAP_PROTOCOL |
>                                NCMAP_REGADDR_PBUF | NPORT_DMODE_W3);
> -     pNewportRegs->set.dcbdata0.all = (color.red << 24) |
> -                                             (color.green << 16) |
> +     colour = (color.red << 24) | (color.green << 16) |
>                                               (color.blue << 8);
> +     pNewportRegs->set.dcbdata0.all = colour;
>  }
>  
>  /* get the colormap entry at addr */
> Index: dist/src/newport_driver.c
> ===================================================================
> RCS file: 
> /cvsroot/xsrc/external/mit/xf86-video-newport/dist/src/newport_driver.c,v
> retrieving revision 1.1.1.2
> retrieving revision 1.12
> diff -u -r1.1.1.2 -r1.12
> --- dist/src/newport_driver.c 23 Jul 2015 01:15:59 -0000      1.1.1.2
> +++ dist/src/newport_driver.c 16 Aug 2016 01:27:47 -0000      1.12
> @@ -33,13 +33,17 @@
>  #include "config.h"
>  #endif
>  
> +#if defined(__NetBSD__)
> +#include <fcntl.h>
> +#include <dev/wscons/wsconsio.h>
> +#include <sys/ioctl.h>
> +#endif
> +
>  /* function prototypes, common data structures & generic includes */
>  #include "newport.h"
>  
>  /* Drivers using the mi SW cursor need: */
>  #include "mipointer.h"
> -/* Drivers using the mi implementation of backing store need: */
> -#include "mibstore.h"
>  /* Drivers using the mi colourmap code need: */
>  #include "micmap.h"
>  
> @@ -55,6 +59,12 @@
>  
>  #include <string.h>
>  #include <stdio.h>
> +#include <unistd.h>
> +
> +#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) > 6
> +#define xf86LoaderReqSymLists(...) do {} while (0)
> +#define LoaderRefSymLists(...) do {} while (0)
> +#endif
>  
>  #define NEWPORT_VERSION              4000
>  #define NEWPORT_NAME         "NEWPORT"
> @@ -195,7 +205,8 @@
>  static void
>  NewportIdentify(int flags)
>  {
> -     xf86PrintChipsets( NEWPORT_NAME, "driver for Newport Graphics Card", 
> NewportChipsets);
> +     xf86PrintChipsets( NEWPORT_NAME, "driver for Newport Graphics Card", 
> +         NewportChipsets);
>  }
>  
>  static Bool
> @@ -210,16 +221,31 @@
>  #endif
>       unsigned probedIDs[NEWPORT_MAX_BOARDS];
>       memType base;
> -
>       if ((numDevSections = xf86MatchDevice(NEWPORT_DRIVER_NAME, 
> &devSections)) <= 0) 
>                  return FALSE;
> +
>       numUsed = NewportHWProbe(probedIDs);
>       if ( numUsed <= 0 ) 
>               return FALSE;
>  
> -     if(flags & PROBE_DETECT) 
> +     if ( xf86DoConfigure && xf86DoConfigurePass1 ) {
> +             GDevPtr pGDev;
> +             for (i = 0; i < numUsed; i++) {
> +                     pGDev = xf86AddBusDeviceToConfigure(NEWPORT_DRIVER_NAME,
> +                             BUS_NONE, NULL, 0);
> +                     if (pGDev) {
> +                             /*
> +                              * XF86Match???Instances() treat chipID and 
> +                              * chipRev as overrides, so clobber them here.
> +                              */
> +                             pGDev->chipID = pGDev->chipRev = -1;
> +                     }
> +             }
> +     }
> +
> +     if(flags & PROBE_DETECT) {
>               foundScreen = TRUE;
> -     else {
> +     } else {
>               for (i = 0; i < numDevSections; i++) {
>                       dev = devSections[i];
>                       busID =  xf86SetIntOption(dev->options, "BusID", 0);
> @@ -372,9 +398,11 @@
>               pNewport->board_rev, pNewport->rex3_rev, 
>               pNewport->cmap_rev, pNewport->xmap9_rev);
>  
> -     if ( (xf86GetOptValInteger(pNewport->Options, OPTION_BITPLANES, 
> &pNewport->bitplanes)))
> +     if ( (xf86GetOptValInteger(pNewport->Options, OPTION_BITPLANES, 
> +         &pNewport->bitplanes)))
>       from = X_CONFIG;
> -     xf86DrvMsg(pScrn->scrnIndex, from, "Newport has %d bitplanes\n", 
> pNewport->bitplanes);
> +     xf86DrvMsg(pScrn->scrnIndex, from, "Newport has %d bitplanes\n", 
> +         pNewport->bitplanes);
>  
>       if ( pScrn->depth > pNewport->bitplanes ) {
>               xf86DrvMsg(pScrn->scrnIndex, X_ERROR, \
> @@ -459,6 +487,12 @@
>               return FALSE;
>       }
>  
> +     /* Load XAA module */
> +     if (!xf86LoadSubModule(pScrn, "xaa")) {
> +             NewportFreeRec(pScrn);
> +             return FALSE;
> +     }
> +     xf86LoaderReqSymLists(xaaSymbols, NULL);
>       return TRUE;
>  }
>  
> @@ -537,7 +571,6 @@
>               xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
>                          "RENDER extension initialisation failed.\n");
>  
> -     miInitializeBackingStore(pScreen);
>       xf86SetBackingStore(pScreen);
>  
>       xf86SetBlackWhitePixels(pScreen);
> @@ -617,7 +650,7 @@
>       if (serverGeneration == 1) {
>               xf86ShowUnusedOptions(pScrn->scrnIndex, pScrn->options);
>       }
> -     
> +     NewportModeInit(pScrn, pScrn->currentMode);
>       return TRUE;
>  }
>  
> @@ -709,7 +742,8 @@
>  
>       width = mode->HDisplay;
>       height = mode->VDisplay;
> -     if (width != 1280 || height != 1024) {
> +     if ((width > 1280) || (width < 1024) ||
> +         (height < 768) || (height > 1024)) {
>               xf86DrvMsg(pScrn->scrnIndex, X_ERROR, \
>               "Width = %d and height = %d is not supported by by this 
> driver\n", width, height);
>               return FALSE;
> @@ -735,17 +769,22 @@
>                                       NPORT_DMODE1_RWPCKD;
>       } else { /* 24bpp */
>               CARD32 mode = 0L;
> +             LOCO col;
> +             int i;
>  
>               /* tell the xmap9s that we are using 24bpp */
>               NewportBfwait(pNewport->pNewportRegs);
> -             pNewportRegs->set.dcbmode = (DCB_XMAP_ALL | 
> W_DCB_XMAP9_PROTOCOL |
> -                             XM9_CRS_CONFIG | NPORT_DMODE_W1 );
> -             pNewportRegs->set.dcbdata0.bytes.b3 &= ~(XM9_8_BITPLANES | 
> XM9_PUPMODE);
> +             pNewportRegs->set.dcbmode = (DCB_XMAP_ALL | 
> +                 W_DCB_XMAP9_PROTOCOL | XM9_CRS_CONFIG | NPORT_DMODE_W1 );
> +             pNewportRegs->set.dcbdata0.bytes.b3 &= 
> +                 ~(XM9_8_BITPLANES | XM9_PUPMODE);
>               NewportBfwait(pNewport->pNewportRegs);
>               /* set up the mode register for 24bpp */
> -             mode = XM9_MREG_PIX_SIZE_24BPP | XM9_MREG_PIX_MODE_RGB1
> +             mode = XM9_MREG_PIX_SIZE_24BPP | XM9_MREG_PIX_MODE_RGB2
>                               | XM9_MREG_GAMMA_BYPASS;
> -             NewportXmap9SetModeRegister( pNewportRegs , 0, mode);
> +             for (i = 0; i < 32; i++)
> +                     NewportXmap9SetModeRegister( pNewportRegs , i, mode);
> +
>               /* select the set up mode register */
>               NewportBfwait(pNewport->pNewportRegs);
>               pNewportRegs->set.dcbmode = (DCB_XMAP_ALL | 
> W_DCB_XMAP9_PROTOCOL |
> @@ -759,16 +798,29 @@
>                                       NPORT_DMODE1_RGBMD | 
>                                       /* turn on 8888 = RGBA pixel packing */
>                                       NPORT_DMODE1_HD32 | NPORT_DMODE1_RWPCKD;
> -             /* After setting up XMAP9 we have to reinitialize the CMAP for
> -              * whatever reason (the docs say nothing about it). 
> RestorePalette()
> -              * is just a lazy way to do this */
> -             NewportRestorePalette( pScrn );
> +             /*
> +              * After setting up XMAP9 we have to reinitialize the CMAP for
> +              * whatever reason (the docs say nothing about it). 
> +              */
> +
> +
> +             for (i = 0; i < 256; i++) {
> +                     col.red = col.green = col.blue = i;
> +                     NewportCmapSetRGB(NEWPORTREGSPTR(pScrn), i, col);
> +             }
> +             for (i = 0; i < 256; i++) {
> +                     col.red = col.green = col.blue = i;
> +                     NewportCmapSetRGB(NEWPORTREGSPTR(pScrn), i + 0x1f00,
> +                         col);
> +             }
> +
>       }
>       /* blank the framebuffer */
>       NewportWait(pNewportRegs);
> -     pNewportRegs->set.drawmode0 = (NPORT_DMODE0_DRAW | NPORT_DMODE0_DOSETUP 
> |
> -                                     NPORT_DMODE0_STOPX | NPORT_DMODE0_STOPY 
> |
> -                                     NPORT_DMODE0_BLOCK);
> +     pNewportRegs->set.drawmode0 = (NPORT_DMODE0_DRAW |
> +                                    NPORT_DMODE0_DOSETUP |
> +                                    NPORT_DMODE0_STOPX | NPORT_DMODE0_STOPY |
> +                                    NPORT_DMODE0_BLOCK);
>       pNewportRegs->set.drawmode1 = pNewport->drawmode1 |
>                                       NPORT_DMODE1_FCLR |
>                                       NPORT_DMODE1_RGBMD;
> @@ -812,10 +864,22 @@
>  static unsigned
>  NewportHWProbe(unsigned probedIDs[])
>  {
> -     FILE* cpuinfo;
> -     char line[80];
>       unsigned hasNewport = 0;
>  
> +#if defined(__NetBSD__)
> +     int fd, type, i;
> +
> +     probedIDs[0] = 0;
> +
> +     fd = open("/dev/ttyE0", O_RDONLY, 0);
> +     i = ioctl(fd, WSDISPLAYIO_GTYPE, &type);
> +     close(fd);
> +
> +     if ( (i == 0) && ( type == WSDISPLAY_TYPE_NEWPORT) )
> +             hasNewport = 1;
> +#else
> +     FILE* cpuinfo;
> +     char line[80];
>       if ((cpuinfo = fopen("/proc/cpuinfo", "r"))) {
>               while(fgets(line, 80, cpuinfo) != NULL) {
>                       if(strstr(line, "SGI Indy") != NULL) {
> @@ -831,6 +895,7 @@
>               }
>               fclose(cpuinfo);
>       }
> +#endif
>       return hasNewport;
>  }
>  
> @@ -866,12 +931,19 @@
>  {
>       NewportPtr pNewport = NEWPORTPTR(pScrn);
>  
> +#if defined(__NetBSD__)
> +     pNewport->pNewportRegs = xf86MapVidMem(pScrn->scrnIndex,
> +                     VIDMEM_MMIO, NEWPORT_REGISTERS, sizeof(NewportRegs));
> +#else
>       pNewport->pNewportRegs = xf86MapVidMem(pScrn->scrnIndex, 
>                       VIDMEM_MMIO,
> -                     NEWPORT_BASE_ADDR0 + pNewport->busID * 
> NEWPORT_BASE_OFFSET,
> -                      sizeof(NewportRegs));
> -     if ( ! pNewport->pNewportRegs ) 
> +                     NEWPORT_BASE_ADDR0 + pNewport->busID * 
> +                         NEWPORT_BASE_OFFSET, sizeof(NewportRegs));
> +#endif
> +     if ( ! pNewport->pNewportRegs ) {
> +             xf86Msg(X_ERROR, "can't map registers\n");
>               return FALSE;
> +     }
>       return TRUE;
>  }
>  
> Index: dist/src/newport_regs.c
> ===================================================================
> RCS file: 
> /cvsroot/xsrc/external/mit/xf86-video-newport/dist/src/newport_regs.c,v
> retrieving revision 1.1.1.1
> retrieving revision 1.2
> diff -u -r1.1.1.1 -r1.2
> --- dist/src/newport_regs.c   14 Feb 2009 03:04:46 -0000      1.1.1.1
> +++ dist/src/newport_regs.c   6 Oct 2009 20:28:14 -0000       1.2
> @@ -14,19 +14,19 @@
>  void 
>  NewportVc2Set(NewportRegsPtr pNewportRegs, unsigned char vc2Ireg, unsigned 
> short val)
>  {
> -     pNewportRegs->set.dcbmode = (NPORT_DMODE_AVC2 | VC2_REGADDR_INDEX | 
> NPORT_DMODE_W3 |
> -                                     NPORT_DMODE_ECINC | VC2_PROTOCOL);
> +     pNewportRegs->set.dcbmode = (NPORT_DMODE_AVC2 | VC2_REGADDR_INDEX | 
> +         NPORT_DMODE_W3 | NPORT_DMODE_ECINC | VC2_PROTOCOL);
>       pNewportRegs->set.dcbdata0.all = (vc2Ireg << 24) | (val << 8);
>  }
>  
>  unsigned short 
>  NewportVc2Get(NewportRegsPtr pNewportRegs, unsigned char vc2Ireg)
>  {
> -     pNewportRegs->set.dcbmode = (NPORT_DMODE_AVC2 | VC2_REGADDR_INDEX | 
> NPORT_DMODE_W1 |
> -                                     NPORT_DMODE_ECINC | VC2_PROTOCOL);
> +     pNewportRegs->set.dcbmode = (NPORT_DMODE_AVC2 | VC2_REGADDR_INDEX | 
> +         NPORT_DMODE_W1 | NPORT_DMODE_ECINC | VC2_PROTOCOL);
>       pNewportRegs->set.dcbdata0.bytes.b3 = vc2Ireg;
> -     pNewportRegs->set.dcbmode = (NPORT_DMODE_AVC2 | VC2_REGADDR_IREG | 
> NPORT_DMODE_W2 |
> -                                     NPORT_DMODE_ECINC | VC2_PROTOCOL);
> +     pNewportRegs->set.dcbmode = (NPORT_DMODE_AVC2 | VC2_REGADDR_IREG | 
> +         NPORT_DMODE_W2 | NPORT_DMODE_ECINC | VC2_PROTOCOL);
>       return pNewportRegs->set.dcbdata0.hwords.s1;
>  }
>  
> @@ -106,7 +106,7 @@
>       while(1) {
>               NewportBfwait( pNewportRegs);
>               pNewportRegs->set.dcbmode = (xmapChip | R_DCB_XMAP9_PROTOCOL |
> -                                             XM9_CRS_FIFO_AVAIL | 
> NPORT_DMODE_W1);
> +                 XM9_CRS_FIFO_AVAIL | NPORT_DMODE_W1);
>               if( (pNewportRegs->set.dcbdata0.bytes.b3) & 7 ) 
>                       break;
>       }
> Index: dist/src/newport_regs.h
> ===================================================================
> RCS file: 
> /cvsroot/xsrc/external/mit/xf86-video-newport/dist/src/newport_regs.h,v
> retrieving revision 1.1.1.1
> retrieving revision 1.2
> diff -u -r1.1.1.1 -r1.2
> --- dist/src/newport_regs.h   14 Feb 2009 03:04:46 -0000      1.1.1.1
> +++ dist/src/newport_regs.h   6 Oct 2009 20:28:14 -0000       1.2
> @@ -397,8 +397,8 @@
>  #   define XM9_CRS_FIFO_AVAIL        (2 << DCB_CRS_SHIFT)
>  #       define XM9_FIFO_0_AVAIL      0
>  #       define XM9_FIFO_1_AVAIL      1
> -#       define XM9_FIFO_2_AVAIL      3
> -#       define XM9_FIFO_3_AVAIL      2
> +#       define XM9_FIFO_2_AVAIL      2
> +#       define XM9_FIFO_3_AVAIL      3
>  #       define XM9_FIFO_FULL         XM9_FIFO_0_AVAIL
>  #       define XM9_FIFO_EMPTY        XM9_FIFO_3_AVAIL
>  #   define XM9_CRS_CURS_CMAP_MSB     (3 << DCB_CRS_SHIFT)
> @@ -412,7 +412,7 @@
>                  (setup << DCB_CSSETUP_SHIFT)|    \
>                  (width << DCB_CSWIDTH_SHIFT))
>  
> -#define W_DCB_XMAP9_PROTOCOL       DCB_CYCLES (2, 1, 0)
> +#define W_DCB_XMAP9_PROTOCOL       DCB_CYCLES (1, 2, 3)
>  #define WSLOW_DCB_XMAP9_PROTOCOL   DCB_CYCLES (5, 5, 0)
>  #define WAYSLOW_DCB_XMAP9_PROTOCOL DCB_CYCLES (12, 12, 0)
>  #define R_DCB_XMAP9_PROTOCOL       DCB_CYCLES (2, 1, 3)

> Index: dist/src/compat-api.h
> ===================================================================
> RCS file: /cvsroot/xsrc/external/mit/xf86-video-tga/dist/src/compat-api.h,v
> retrieving revision 1.1.1.1
> retrieving revision 1.2
> diff -u -r1.1.1.1 -r1.2
> --- dist/src/compat-api.h     3 Jun 2013 09:59:08 -0000       1.1.1.1
> +++ dist/src/compat-api.h     31 Dec 2018 22:17:21 -0000      1.2
> @@ -78,11 +78,19 @@
>  
>  #define SCREEN_INIT_ARGS_DECL ScreenPtr pScreen, int argc, char **argv
>  
> +#if ABI_VIDEODRV_VERSION >= SET_ABI_VERSION(23, 0)
> +#define BLOCKHANDLER_ARGS_DECL ScreenPtr arg, pointer pTimeout
> +#define BLOCKHANDLER_ARGS arg, pTimeout
> +
> +#define WAKEUPHANDLER_ARGS_DECL ScreenPtr arg, int result
> +#define WAKEUPHANDLER_ARGS arg, result
> +#else
>  #define BLOCKHANDLER_ARGS_DECL ScreenPtr arg, pointer pTimeout, pointer 
> pReadmask
>  #define BLOCKHANDLER_ARGS arg, pTimeout, pReadmask
>  
>  #define WAKEUPHANDLER_ARGS_DECL ScreenPtr arg, unsigned long result, pointer 
> read_mask
>  #define WAKEUPHANDLER_ARGS arg, result, read_mask
> +#endif
>  
>  #define CLOSE_SCREEN_ARGS_DECL ScreenPtr pScreen
>  #define CLOSE_SCREEN_ARGS pScreen
> Index: dist/src/tga_accel.c
> ===================================================================
> RCS file: /cvsroot/xsrc/external/mit/xf86-video-tga/dist/src/tga_accel.c,v
> retrieving revision 1.1.1.2
> retrieving revision 1.4
> diff -u -r1.1.1.2 -r1.4
> --- dist/src/tga_accel.c      3 Jun 2013 09:59:08 -0000       1.1.1.2
> +++ dist/src/tga_accel.c      20 Aug 2016 00:27:22 -0000      1.4
> @@ -37,7 +37,6 @@
>  #include "xf86cmap.h"
>  #include "mipointer.h"
>  
> -#include "mibstore.h"
>  #include "miline.h"
>  
>  #include "tga_regs.h"
> Index: dist/src/tga_driver.c
> ===================================================================
> RCS file: /cvsroot/xsrc/external/mit/xf86-video-tga/dist/src/tga_driver.c,v
> retrieving revision 1.1.1.4
> retrieving revision 1.4
> diff -u -r1.1.1.4 -r1.4
> --- dist/src/tga_driver.c     3 Jun 2013 09:59:08 -0000       1.1.1.4
> +++ dist/src/tga_driver.c     20 Aug 2016 00:27:22 -0000      1.4
> @@ -46,8 +46,6 @@
>  
>  /* software cursor */
>  #include "mipointer.h"
> -/* backing store */
> -#include "mibstore.h"
>  
>  /*  #include "mibank.h" */
>  /* colormap manipulation */
> @@ -1451,7 +1449,6 @@
>      
>      fbPictureInit (pScreen, 0, 0);
>      
> -    miInitializeBackingStore(pScreen);
>      xf86SetBackingStore(pScreen);
>      xf86SetSilkenMouse(pScreen);
>  

> Index: dist/src/compat-api.h
> ===================================================================
> RCS file: /cvsroot/xsrc/external/mit/xf86-video-tseng/dist/src/compat-api.h,v
> retrieving revision 1.1.1.1
> retrieving revision 1.2
> diff -u -r1.1.1.1 -r1.2
> --- dist/src/compat-api.h     3 Jun 2013 09:59:12 -0000       1.1.1.1
> +++ dist/src/compat-api.h     31 Dec 2018 22:17:21 -0000      1.2
> @@ -78,11 +78,19 @@
>  
>  #define SCREEN_INIT_ARGS_DECL ScreenPtr pScreen, int argc, char **argv
>  
> +#if ABI_VIDEODRV_VERSION >= SET_ABI_VERSION(23, 0)
> +#define BLOCKHANDLER_ARGS_DECL ScreenPtr arg, pointer pTimeout, pointer 
> pReadmask
> +#define BLOCKHANDLER_ARGS arg, pTimeout, pReadmask
> +
> +#define WAKEUPHANDLER_ARGS_DECL ScreenPtr arg, int result
> +#define WAKEUPHANDLER_ARGS arg, result
> +#else
>  #define BLOCKHANDLER_ARGS_DECL ScreenPtr arg, pointer pTimeout, pointer 
> pReadmask
>  #define BLOCKHANDLER_ARGS arg, pTimeout, pReadmask
>  
>  #define WAKEUPHANDLER_ARGS_DECL ScreenPtr arg, unsigned long result, pointer 
> read_mask
>  #define WAKEUPHANDLER_ARGS arg, result, read_mask
> +#endif
>  
>  #define CLOSE_SCREEN_ARGS_DECL ScreenPtr pScreen
>  #define CLOSE_SCREEN_ARGS pScreen
> Index: dist/src/tseng_accel.c
> ===================================================================
> RCS file: /cvsroot/xsrc/external/mit/xf86-video-tseng/dist/src/tseng_accel.c,v
> retrieving revision 1.1.1.3
> retrieving revision 1.2
> diff -u -r1.1.1.3 -r1.2
> --- dist/src/tseng_accel.c    3 Jun 2013 09:59:12 -0000       1.1.1.3
> +++ dist/src/tseng_accel.c    3 Jun 2013 10:28:19 -0000       1.2
> @@ -115,7 +115,7 @@
>      }
>  }
>  
> -static void 
> +void 
>  tseng_recover_timeout(TsengPtr pTseng)
>  {
>      if (pTseng->ChipType == ET4000) {
> Index: dist/src/tseng_accel.h
> ===================================================================
> RCS file: /cvsroot/xsrc/external/mit/xf86-video-tseng/dist/src/tseng_accel.h,v
> retrieving revision 1.1.1.1
> retrieving revision 1.2
> diff -u -r1.1.1.1 -r1.2
> --- dist/src/tseng_accel.h    2 Aug 2008 05:17:35 -0000       1.1.1.1
> +++ dist/src/tseng_accel.h    3 Jun 2013 10:28:19 -0000       1.2
> @@ -95,7 +95,7 @@
>  #define MAX_WAIT_CNT 500000         /* how long we wait before we time out */
>  #undef WAIT_VERBOSE                 /* if defined: print out how long we 
> waited */
>  
> -static void tseng_recover_timeout(TsengPtr pTseng);
> +void tseng_recover_timeout(TsengPtr pTseng);
>  
>  static __inline__ void 
>  tseng_wait(TsengPtr pTseng, int reg, char *name, unsigned char mask)
> Index: dist/src/tseng_driver.c
> ===================================================================
> RCS file: 
> /cvsroot/xsrc/external/mit/xf86-video-tseng/dist/src/tseng_driver.c,v
> retrieving revision 1.1.1.5
> retrieving revision 1.3
> diff -u -r1.1.1.5 -r1.3
> --- dist/src/tseng_driver.c   3 Jun 2013 09:59:12 -0000       1.1.1.5
> +++ dist/src/tseng_driver.c   31 Dec 2018 22:17:21 -0000      1.3
> @@ -39,9 +39,6 @@
>  /* All drivers initialising the SW cursor need this */
>  #include "mipointer.h"
>  
> -/* All drivers implementing backing store need this */
> -#include "mibstore.h"
> -
>  #include "fb.h"
>  
>  #if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 6
> @@ -1040,10 +1037,6 @@
>      else
>       pTseng->Bytesperpixel = 1;  /* this is fake for < 8bpp, but simplifies 
> other code */
>  
> -    /* hardware limits */
> -    pScrn->maxHValue = Tseng_HMAX;
> -    pScrn->maxVValue = Tseng_VMAX;
> -
>      /*
>       * This must happen after pScrn->display has been set because
>       * xf86SetWeight references it.
> @@ -1136,8 +1129,8 @@
>      /* Select valid modes from those available */
>      i = xf86ValidateModes(pScrn, pScrn->monitor->Modes,
>       pScrn->display->modes, &pTseng->clockRange,
> -     NULL, 32, pScrn->maxHValue, 8*pTseng->Bytesperpixel, /* H limits */
> -     0, pScrn->maxVValue,           /* V limits */
> +     NULL, 32, /* XXXMRG pScrn->maxHValue*/ 2048, 8*pTseng->Bytesperpixel, 
> /* H limits */
> +     0, /* XXXMRG pScrn->maxVValue*/ 2048,          /* V limits */
>       pScrn->display->virtualX,
>       pScrn->display->virtualY,
>       pTseng->FbMapSize,
> @@ -1453,7 +1446,6 @@
>       }
>      }
>  
> -    miInitializeBackingStore(pScreen);
>      xf86SetSilkenMouse(pScreen);
>      /* Initialise cursor functions */
>      miDCInitialize(pScreen, xf86GetPointerScreenFuncs());

Index: dist/src/vb_ext.c
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/vb_ext.c,v
retrieving revision 1.1.1.1
retrieving revision 1.3
diff -u -r1.1.1.1 -r1.3
--- dist/src/vb_ext.c   19 Jul 2012 15:24:38 -0000      1.1.1.1
+++ dist/src/vb_ext.c   2 Nov 2012 07:44:10 -0000       1.3
@@ -139,7 +139,7 @@
     USHORT tempax = 0 , tempbx , tempcx , temp ,
            P2reg0 = 0 , SenseModeNo = 0 , OutputSelect = pVBInfo->OutputSelect,
            ModeIdIndex , i ;
-    pVBInfo->BaseAddr = ( USHORT )HwDeviceExtension->pjIOAddress ;
+    pVBInfo->BaseAddr = ( ULONG )HwDeviceExtension->pjIOAddress ;
 
     {          /* for 301 */
         if ( pVBInfo->VBInfo & SetCRT2ToHiVisionTV )
@@ -510,7 +510,7 @@
     /* VB_DEVICE_INFO VBINF; */
     /* PVB_DEVICE_INFO pVBInfo = pXGI->XGI_Pr */ /* &VBINF */;
 
-       ErrorF("XGISetDPMS(VESA_POWER_STATE = 0x%x)...\n", VESA_POWER_STATE);
+       ErrorF("XGISetDPMS(VESA_POWER_STATE = 0x%lx)...\n", VESA_POWER_STATE);
 
     InitTo330Pointer( pXGIHWDE->jChipType,  pVBInfo ) ;
     ReadVBIOSTablData( pXGIHWDE->jChipType , pVBInfo) ;
Index: dist/src/vb_i2c.c
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/vb_i2c.c,v
retrieving revision 1.1.1.1
retrieving revision 1.3
diff -u -r1.1.1.1 -r1.3
--- dist/src/vb_i2c.c   19 Jul 2012 15:24:39 -0000      1.1.1.1
+++ dist/src/vb_i2c.c   2 Nov 2012 07:47:19 -0000       1.3
@@ -3,6 +3,7 @@
 #include "config.h"
 #endif
 
+#include <unistd.h>
 #include "osdef.h"
 #include "vgatypes.h"
 /* #include "vb_util.h" */ /* Jong@08032009 */
@@ -114,7 +115,7 @@
 #define ENABLE_GPIOC          0x04
 VOID
 EnableGPIOA(
-PUCHAR pjIOPort, I2C_ACCESS_CMD CmdType)
+XGIIOADDRESS pjIOPort, I2C_ACCESS_CMD CmdType)
 {
        PDEBUGI2C(ErrorF("EnableGPIOA()-pjIOPort=0x%x...\n", pjIOPort));
 
@@ -134,7 +135,7 @@
 
 VOID
 EnableGPIOB(
-PUCHAR pjIOPort, I2C_ACCESS_CMD CmdType)
+XGIIOADDRESS pjIOPort, I2C_ACCESS_CMD CmdType)
 {
     UCHAR ujCR4A = XGI_GetReg(pjIOPort, IND_CR4A_GPIO_REG_III);
 
@@ -152,7 +153,7 @@
 
 VOID
 EnableGPIOC(
-PUCHAR pjIOPort, I2C_ACCESS_CMD CmdType)
+XGIIOADDRESS pjIOPort, I2C_ACCESS_CMD CmdType)
 {
     UCHAR ujCR4A = XGI_GetReg(pjIOPort, IND_CR4A_GPIO_REG_III);
 
@@ -1174,8 +1175,8 @@
 *************************************************************************/
 VOID vWriteClockLineDVI(PXGI_HW_DEVICE_INFO pHWDE, UCHAR data)
 {
-    UCHAR       temp;
-    PUCHAR      pjI2cIOBase;
+    UCHAR        temp;
+    XGIIOADDRESS pjI2cIOBase;
 
        PDEBUGI2C(ErrorF("vWriteClockLineDVI()...begin\n"));
 
@@ -1224,8 +1225,8 @@
 *************************************************************************/
 VOID vWriteDataLineDVI(PXGI_HW_DEVICE_INFO pHWDE, UCHAR data)
 {
-    UCHAR       temp;
-    PUCHAR      pjI2cIOBase;
+    UCHAR        temp;
+    XGIIOADDRESS pjI2cIOBase;
 
        PDEBUGI2C(ErrorF("vWriteDataLineDVI()...begin\n"));
 
@@ -1277,8 +1278,8 @@
 *************************************************************************/
 BOOLEAN bReadClockLineDVI(PXGI_HW_DEVICE_INFO pHWDE)
 {
-    UCHAR   cPortData;
-    PUCHAR  pjI2cIOBase;
+    UCHAR        cPortData;
+    XGIIOADDRESS pjI2cIOBase;
 
        PDEBUGI2C(ErrorF("bReadClockLineDVI()...begin\n"));
 
@@ -1318,7 +1319,7 @@
 BOOLEAN bReadDataLineDVI(PXGI_HW_DEVICE_INFO pHWDE)
 {
     UCHAR       cPortData;
-    PUCHAR      pjI2cIOBase; 
+    XGIIOADDRESS      pjI2cIOBase; 
 
        PDEBUGI2C(ErrorF("bReadDataLineDVI()...begin\n"));
 
@@ -1357,7 +1358,7 @@
 //*************************************************************************//
 VOID vWaitForCRT1HsyncActive(PXGI_HW_DEVICE_INFO  pHWDE)
 {
-    PUCHAR  pjPort = pHWDE->pjIOAddress + INPUT_STATUS_1_COLOR;
+    XGIIOADDRESS  pjPort = pHWDE->pjIOAddress + INPUT_STATUS_1_COLOR;
     ULONG   i;
 
     for (i = 0; i < 0x00FFFF; i++)
@@ -1398,7 +1399,7 @@
 VOID vWriteClockLineCRT(PXGI_HW_DEVICE_INFO pHWDE, UCHAR data)
 {
     UCHAR       temp, ujSR1F;
-    PUCHAR      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
+    XGIIOADDRESS      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
 
     PDEBUGI2C(ErrorF("I2C:Write CRT clock = %x\n", data & 1));
 
@@ -1433,7 +1434,7 @@
 VOID vWriteDataLineCRT(PXGI_HW_DEVICE_INFO pHWDE, UCHAR data)
 {
     UCHAR       temp, ujSR1F;
-    PUCHAR      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
+    XGIIOADDRESS      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
 
     PDEBUGI2C(ErrorF("I2C:Write CRT data = %x\n", data & 1));
 
@@ -1467,7 +1468,7 @@
 BOOLEAN bReadClockLineCRT(PXGI_HW_DEVICE_INFO pHWDE)
 {
     UCHAR       cPortData;
-    PUCHAR      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
+    XGIIOADDRESS      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
 
     cPortData = XGI_GetReg(pjI2cIOBase, IND_SR11_DDC_REG);
     cPortData = GETBITS(cPortData, 0:0);
@@ -1489,7 +1490,7 @@
 BOOLEAN bReadDataLineCRT(PXGI_HW_DEVICE_INFO pHWDE)
 {
     UCHAR cPortData;
-    PUCHAR      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
+    XGIIOADDRESS      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
 
     cPortData = XGI_GetReg(pjI2cIOBase, IND_SR11_DDC_REG);
     cPortData = GETBITS(cPortData, 1:1);
@@ -1517,7 +1518,7 @@
 VOID vWriteClockLineFCNT(PXGI_HW_DEVICE_INFO pHWDE, UCHAR data)
 {
     UCHAR       temp;
-    PUCHAR      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
+    XGIIOADDRESS      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
 
     PDEBUGI2C(ErrorF("I2C:Write FCNT clock = %x\n", data & 1));
 
@@ -1541,7 +1542,7 @@
 VOID vWriteDataLineFCNT(PXGI_HW_DEVICE_INFO pHWDE, UCHAR data)
 {
     UCHAR       temp, temp2, temp3;
-    PUCHAR      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
+    XGIIOADDRESS      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
 
     PDEBUGI2C(ErrorF("I2C:Write FCNT data = %x\n", data & 1));
 
@@ -1565,7 +1566,7 @@
 BOOLEAN bReadClockLineFCNT(PXGI_HW_DEVICE_INFO pHWDE)
 {
     UCHAR       cPortData;
-    PUCHAR      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
+    XGIIOADDRESS      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
 
     cPortData = XGI_GetReg(pjI2cIOBase, IND_SR11_DDC_REG);
     cPortData = GETBITS(cPortData, 2:2);
@@ -1587,7 +1588,7 @@
 BOOLEAN bReadDataLineFCNT(PXGI_HW_DEVICE_INFO pHWDE)
 {
     UCHAR       cPortData;
-    PUCHAR      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
+    XGIIOADDRESS      pjI2cIOBase = pHWDE->pjIOAddress + SEQ_ADDRESS_PORT;
 
     cPortData = XGI_GetReg(pjI2cIOBase, IND_SR11_DDC_REG);
     cPortData = GETBITS(cPortData, 3:3);
@@ -1630,8 +1631,10 @@
                return(bReadClockLineDVI(pHWDE));
        else if(pHWDE->crtno == 2)
                return(bReadClockLineFCNT(pHWDE));
-       else
+       else {
                ErrorF("Error(XGI) : Unkonwn output device! \n");
+               return FALSE;
+       }
 }
 
 BOOLEAN bReadDataLine(PXGI_HW_DEVICE_INFO pHWDE)
@@ -1642,8 +1645,10 @@
                return(bReadDataLineDVI(pHWDE));
        else if(pHWDE->crtno == 2)
                return(bReadDataLineFCNT(pHWDE));
-       else
+       else {
                ErrorF("Error(XGI) : Unkonwn output device! \n");
+               return FALSE;
+       }
 }
 
 BOOLEAN bEDIDCheckSum(PUCHAR  pjEDIDBuf,ULONG   ulBufSize)
@@ -1890,4 +1895,4 @@
 
    PDEBUGI2C(ErrorF("bGetEDID()-return(%d)\n", status == NO_ERROR ? 1:0));
     return (status == NO_ERROR);
-}
\ No newline at end of file
+}
Index: dist/src/vb_i2c.h
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/vb_i2c.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- dist/src/vb_i2c.h   19 Jul 2012 15:24:39 -0000      1.1.1.1
+++ dist/src/vb_i2c.h   19 Jul 2012 19:18:20 -0000      1.2
@@ -7,7 +7,7 @@
 #endif 
 #ifndef u32
 #define u32 unsigned long
-#define u8 unsigned long
+#define u8 uint8_t
 #endif
 
 /* Jong@08052009 */
@@ -81,8 +81,11 @@
 //#define MASK(n)         BITSMASK(1?n, 0?n)
 // set bits as 1 between bit(a) and bit(b)
 #define MASK(n)         ( BITS(LARGE(n)-SMALL(n)+1) << SMALL(n) )
+
+#ifndef GETBITS
 // get bits [a:b]'s binary value
 #define GETBITS(b,n)    ( ((b) & MASK(n)) >> SMALL(n) ) /* Jong@08032009 */
+#endif /* GETBITS */
 // set binary value from [a:0] to [c:d]
 #define SETBITS(b, n)   ( ( (b) << ((1?n) > (0?n) ? (0?n) : (1?n)) ) & MASK(n) 
)
 // move bits value from [a:b] to [c:d]
@@ -180,5 +183,6 @@
 extern  BOOLEAN I2CRead(PXGI_HW_DEVICE_INFO pHWDE,PI2CControl pI2CControl);
 extern  BOOLEAN I2CWrite(PXGI_HW_DEVICE_INFO pHWDE,  PI2CControl pI2CControl);
 extern  BOOLEAN ResetI2C(PXGI_HW_DEVICE_INFO pHWDE,  PI2CControl pI2CControl);
+extern  BOOLEAN bGetEDID(PXGI_HW_DEVICE_INFO, ULONG , PUCHAR, ULONG);
 
 #endif
Index: dist/src/vb_setmode.c
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/vb_setmode.c,v
retrieving revision 1.1.1.1
retrieving revision 1.3
diff -u -r1.1.1.1 -r1.3
--- dist/src/vb_setmode.c       19 Jul 2012 15:24:40 -0000      1.1.1.1
+++ dist/src/vb_setmode.c       2 Nov 2012 07:55:38 -0000       1.3
@@ -189,7 +189,7 @@
 void XGI_SetCRT2ECLK(USHORT ModeNo, USHORT ModeIdIndex,
                      USHORT RefreshRateTableIndex, PVB_DEVICE_INFO pVBInfo);
 void InitTo330Pointer(UCHAR, PVB_DEVICE_INFO pVBInfo);
-void XGI_GetLCDSync(USHORT * HSyncWidth, USHORT * VSyncWidth,
+void XGI_GetLCDSync(ULONG * HSyncWidth, ULONG * VSyncWidth,
                     PVB_DEVICE_INFO pVBInfo);
 void XGI_DisableBridge(PXGI_HW_DEVICE_INFO HwDeviceExtension,
                        PVB_DEVICE_INFO pVBInfo);
@@ -325,8 +325,8 @@
         (void) memcpy(pVBInfo->ECLKData, XGI330_ECLKData, 
sizeof(XGI330_ECLKData));
     }
 
-    pVBInfo->VCLKData = XGI_VCLKData;
-    pVBInfo->VBVCLKData = XGI_VBVCLKData;
+    pVBInfo->VCLKData = (const XGI_VCLKDataStruct *)XGI_VCLKData;
+    pVBInfo->VBVCLKData = (const XGI_VBVCLKDataStruct *)XGI_VBVCLKData;
     pVBInfo->ScreenOffset = XGI330_ScreenOffset;
     pVBInfo->StResInfo = XGI330_StResInfo;
     pVBInfo->ModeResInfo = XGI330_ModeResInfo;
@@ -3131,7 +3131,7 @@
 
 
 static void
-get_HDE_VDE(PVB_DEVICE_INFO pVBInfo, USHORT *HDE, USHORT *VDE)
+get_HDE_VDE(PVB_DEVICE_INFO pVBInfo, ULONG *HDE, ULONG *VDE)
 {
     switch (pVBInfo->LCDResInfo) {
     case Panel1024x768:
@@ -3265,7 +3265,7 @@
 XGI_SetLVDSRegs(USHORT ModeNo, USHORT ModeIdIndex,
                 USHORT RefreshRateTableIndex, PVB_DEVICE_INFO pVBInfo)
 {
-    USHORT tempbx, tempax, tempcx, tempdx, push1, push2, modeflag;
+    ULONG tempbx, tempax, tempcx, tempdx, push1, push2, modeflag;
     unsigned long temp, temp1, temp2, temp3, push3;
     XGI330_LCDDataDesStruct *LCDPtr = NULL;
     XGI330_LCDDataDesStruct2 *LCDPtr1 = NULL;
@@ -6282,7 +6282,7 @@
                PXGI_HW_DEVICE_INFO HwDeviceExtension,
                USHORT RefreshRateTableIndex, PVB_DEVICE_INFO pVBInfo)
 {
-    USHORT push1,
+    ULONG push1,
         push2,
         pushbx,
         tempax,
@@ -8610,7 +8610,7 @@
 /* Description : */
 /* --------------------------------------------------------------------- */
 void
-XGI_GetLCDSync(USHORT * HSyncWidth, USHORT * VSyncWidth,
+XGI_GetLCDSync(ULONG * HSyncWidth, ULONG * VSyncWidth,
                PVB_DEVICE_INFO pVBInfo)
 {
     USHORT Index;
@@ -9502,7 +9502,7 @@
     if (pVBInfo->
         VBType & (VB_XGI301B | VB_XGI302B | VB_XGI301LV | VB_XGI302LV |
                   VB_XGI301C))
-        *tempch++;
+        (*tempch)++;
 }
 
 
@@ -10018,7 +10018,7 @@
 {
        /* Jong 10/08/2007; merge code */
     USHORT tempbx ; 
-    UCHAR *CHTVVCLKPtr = NULL ;
+    const UCHAR *CHTVVCLKPtr = NULL ;
 
        unsigned VCLKIndex;
     USHORT CRT2Index;
@@ -10242,4 +10242,4 @@
     }
 
        PDEBUG(ErrorF("XGIInitMiscVBInfo()...End\n"));
-}
\ No newline at end of file
+}
Index: dist/src/vb_table.h
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/vb_table.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- dist/src/vb_table.h 19 Jul 2012 15:24:41 -0000      1.1.1.1
+++ dist/src/vb_table.h 19 Jul 2012 19:18:20 -0000      1.2
@@ -3112,14 +3112,14 @@
  { 1152, 864, 8,16}
 };
 
-static const UCHAR XGI330_OutputSelect = 0x40;
-static const UCHAR XGI330_SoftSetting = 0x30;
-static const UCHAR XGI330_SR07 = 0x18;
-static const UCHAR XG21_DVOSetting = 0x00 ;
-static const UCHAR XG21_CR2E = 0x00 ;
-static const UCHAR XG21_CR2F = 0x00 ;
-static const UCHAR XG21_CR46 = 0x00 ;
-static const UCHAR XG21_CR47 = 0x00 ;
+static UCHAR XGI330_OutputSelect = 0x40;
+static UCHAR XGI330_SoftSetting = 0x30;
+static UCHAR XGI330_SR07 = 0x18;
+static UCHAR XG21_DVOSetting = 0x00 ;
+static UCHAR XG21_CR2E = 0x00 ;
+static UCHAR XG21_CR2F = 0x00 ;
+static UCHAR XG21_CR46 = 0x00 ;
+static UCHAR XG21_CR47 = 0x00 ;
 
 UCHAR XG27_CR97 = 0xC1 ;
 UCHAR XG27_SR36 = 0x30 ;
Index: dist/src/vgatypes.h
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/vgatypes.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- dist/src/vgatypes.h 19 Jul 2012 15:24:41 -0000      1.1.1.1
+++ dist/src/vgatypes.h 19 Jul 2012 19:18:20 -0000      1.2
@@ -212,7 +212,7 @@
 
 typedef struct _XGI_HW_DEVICE_INFO  XGI_HW_DEVICE_INFO, *PXGI_HW_DEVICE_INFO;
 
-typedef BOOLEAN (*PXGI_QUERYSPACE)   (PXGI_HW_DEVICE_INFO, ULONG, ULONG, ULONG 
*);
+typedef BOOLEAN (*PXGI_QUERYSPACE)   (PXGI_HW_DEVICE_INFO, ULONG, ULONG, 
CARD32 *);
 
 struct _XGI_HW_DEVICE_INFO
 {
@@ -229,7 +229,7 @@
 
     ULONG  ulVideoMemorySize;    /* size, in bytes, of the memory on the board 
*/
 
-    PUCHAR pjIOAddress;          /* base I/O address of VGA ports (0x3B0) */
+    XGIIOADDRESS pjIOAddress;          /* base I/O address of VGA ports 
(0x3B0) */
 
     PUCHAR pjCustomizedROMImage;
 
Index: dist/src/xgi.h
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/xgi.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- dist/src/xgi.h      19 Jul 2012 15:24:41 -0000      1.1.1.1
+++ dist/src/xgi.h      19 Jul 2012 19:18:20 -0000      1.2
@@ -32,13 +32,6 @@
 #ifndef _XGI_H_
 #define _XGI_H_
 
-#define DEBUG 
-#define DEBUG1
-#define DEBUG2
-#define DEBUG3
-#define DEBUG4
-#define DEBUG5
-
 /***************
 #define DEBUG 
 #define DEBUG1
@@ -51,7 +44,7 @@
 
 #ifndef XGI_VIDEO_HW /* avoid compile error in xgi_videohw.c; weird!  */
 /* Jong 07/27/2009; use run-time debug instead except for HW acceleration 
routines */
-extern BOOL g_bRunTimeDebug;
+extern Bool g_bRunTimeDebug;
 #define RUNTIMEDEBUG(p)                if(g_bRunTimeDebug)p;
 
 /* Jong@08052009 */
@@ -1017,7 +1010,10 @@
 extern void XGI_SetRegAND(XGIIOADDRESS Port, USHORT Index, USHORT DataAND);
 extern void XGI_SetRegOR(XGIIOADDRESS Port, USHORT Index, USHORT DataOR);
 
+#ifndef __NetBSD__
 #define uint8_t        CARD8
+#endif
+
 extern void XGI_WriteDAC(XGIIOADDRESS dac_data, unsigned shift,
     unsigned ordering, uint8_t red, uint8_t green, uint8_t blue);
 
Index: dist/src/xgi_accel.c
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/xgi_accel.c,v
retrieving revision 1.1.1.1
retrieving revision 1.6
diff -u -r1.1.1.1 -r1.6
--- dist/src/xgi_accel.c        19 Jul 2012 15:24:41 -0000      1.1.1.1
+++ dist/src/xgi_accel.c        9 Nov 2012 09:28:52 -0000       1.6
@@ -34,6 +34,7 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
+#include <unistd.h>
 
 #include "xf86.h"
 #include "xf86_OSproc.h"
@@ -958,6 +959,7 @@
             return TRUE;
        }
 #endif /* EXA */
+       return FALSE;
 }
 
 void
@@ -1738,11 +1740,12 @@
     
ErrorF("----------------------------------------------------------------------\n")
 ;
 
        SwWP = Volari_GetSwWP() ;
-    ErrorF("SwWP=0x%x\n", SwWP) ;
-    ErrorF("pXGI->cmdQueueBase=0x%x\n", pXGI->cmdQueueBase) ;
+    ErrorF("SwWP=0x%lx\n", SwWP) ;
+    ErrorF("pXGI->cmdQueueBase=%p\n", pXGI->cmdQueueBase) ;
        for( i = 0 ; i < SwWP ; i+=0x04 )
        {
-               ErrorF("[%04X]: %08lX\n",i, *(CARD32 *)(pXGI->cmdQueueBase+i));
+               ErrorF("[%04X]: %08lX\n",i,
+                   (unsigned long)*(CARD32 *)(pXGI->cmdQueueBase+i));
        }
 }
 
Index: dist/src/xgi_driver.c
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/xgi_driver.c,v
retrieving revision 1.1.1.1
retrieving revision 1.4
diff -u -r1.1.1.1 -r1.4
--- dist/src/xgi_driver.c       19 Jul 2012 15:24:43 -0000      1.1.1.1
+++ dist/src/xgi_driver.c       16 Aug 2016 01:27:48 -0000      1.4
@@ -47,9 +47,9 @@
 #include "config.h"
 #endif
 
-#define  PACKAGE_VERSION_MAJOR   6
-#define  PACKAGE_VERSION_MINOR   1
-#define  PACKAGE_VERSION_PATCHLEVEL   6803
+#define  PACKAGE_VERSION_MAJOR   1
+#define  PACKAGE_VERSION_MINOR   6
+#define  PACKAGE_VERSION_PATCHLEVEL   0
 
 #include "fb.h"
 #include "micmap.h"
@@ -70,18 +70,21 @@
 #include "vbe.h"
 
 #include "mipointer.h"
-#include "mibstore.h"
 
 #include "xgi.h"
 #include "xgi_regs.h"
 #include "xgi_vb.h"
 #include "xgi_dac.h"
 #include "vb_def.h"
+#include "vb_ext.h"
+#include "vb_i2c.h"
+#include "vb_setmode.h"
 #include "xgi_driver.h"
+#include "xgi_accel.h"
 #include "valid_mode.h"
 
 #define _XF86DGA_SERVER_
-#include <X11/extensions/xf86dgastr.h>
+#include <X11/extensions/xf86dgaproto.h>
 
 #include "globals.h"
 
@@ -106,11 +109,8 @@
 #include <unistd.h>
 #endif
 
-/* Jong 01/22/2009; compiler error; type conflict */
-/*
 #include <fcntl.h>
 #include <sys/ioctl.h>
-*/
 
 #ifdef XSERVER_LIBPCIACCESS
 static Bool XGIPciProbe(DriverPtr drv, int entity_num,
@@ -132,7 +132,7 @@
 
 /* Jong 07/27/2009; use run-time debug instead except for HW acceleration 
routines */
 /* Set Option "RunTimeDebug" to "true" in X configuration file */
-BOOL g_bRunTimeDebug=0;
+Bool g_bRunTimeDebug=0;
 
 /* Jong@09072009 */
 unsigned char g_DVI_I_SignalType = 0x00;
@@ -500,6 +500,7 @@
         xf86AddDriver(&XGI, module, 0);
 #endif
 
+#if 0
         LoaderRefSymLists(vgahwSymbols, fbSymbols, xaaSymbols,
                           shadowSymbols, ramdacSymbols, ddcSymbols,
                           vbeSymbols, int10Symbols,
@@ -507,6 +508,7 @@
                           drmSymbols, driSymbols,
 #endif
                           NULL);
+#endif
         return (pointer) TRUE;
     }
 
@@ -762,7 +764,7 @@
 
 typedef struct 
 {
-       unsigned char   name[10];
+    char   name[10];
     unsigned int    DCLK;
     unsigned int    HDisplay;
     unsigned int    HSyncStart;
@@ -862,13 +864,13 @@
         "**************************************************\n";
 
     va_start(ap, format);
-    xf86DrvMsg(pScrn->scrnIndex, X_ERROR, str);
+    xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "%s", str);
     xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "                      ERROR:\n");
     xf86VDrvMsgVerb(pScrn->scrnIndex, X_ERROR, 1, format, ap);
     va_end(ap);
     xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
                "                  END OF MESSAGE\n");
-    xf86DrvMsg(pScrn->scrnIndex, X_ERROR, str);
+    xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "%s", str);
 }
 
 #ifdef XSERVER_LIBPCIACCESS
@@ -1615,7 +1617,9 @@
     ErrorF("get EDID with VBIOS call...\n");
     if (xf86LoadSubModule(pScrn, "int10")) 
        {
+#if 0
         xf86LoaderReqSymLists(int10Symbols, NULL);
+#endif
         pInt = xf86InitInt10(pXGI->pEnt->index);
         if (pInt == NULL) {
             xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
@@ -1676,9 +1680,9 @@
 
                        g_DVI_I_SignalType = (buffer[20] & 0x80) >> 7;
                        ErrorF("DVI-I : %s signal ...\n", (g_DVI_I_SignalType 
== 0x01) ? "DVI" : "CRT" );
-
+#if 0
             xf86LoaderReqSymLists(ddcSymbols, NULL);
-
+#endif
                        /* Jong 09/04/2007; Alan fixed abnormal EDID data */
                        /* pMonitor = xf86InterpretEDID(pScrn->scrnIndex, 
buffer) ; */
                        if ( (buffer[0]==0) && (buffer[7]==0) )
@@ -2218,9 +2222,9 @@
 
         if (xf86LoadSubModule(pScrn, "ddc")) 
                {
-
+#if 0
             xf86LoaderReqSymLists(ddcSymbols, NULL);
-
+#endif
             if (pXGI->xgi_HwDevExt.jChipType == XG27) 
                        {
                                ErrorF("Getting CRT EDID (DAC1-CRT1)...\n");
@@ -2684,9 +2688,9 @@
         XGIErrorLog(pScrn, "Could not load vgahw module\n");
         return FALSE;
     }
-
+#if 0
     xf86LoaderReqSymLists(vgahwSymbols, NULL);
-
+#endif
     /* Due to the liberal license terms this is needed for
      * keeping the copyright notice readable and intact in
      * binary distributions. Removing this is a copyright
@@ -2768,11 +2772,11 @@
 #endif
 
                  xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 3, 
-                                 "VGA memory map from 0x%x to 0x%x \n", 
+                                 "VGA memory map from %p to %p \n", 
 #ifdef XSERVER_LIBPCIACCESS
-                                 pXGI->PciInfo->regions[2].base_addr, 
VGAHWPTR(pScrn)->Base);
+                                 (void 
*)(intptr_t)pXGI->PciInfo->regions[2].base_addr, VGAHWPTR(pScrn)->Base);
 #else
-                                 pXGI->PciInfo->ioBase[2], 
VGAHWPTR(pScrn)->Base);
+                                 (void *)(intptr_t)pXGI->PciInfo->ioBase[2], 
VGAHWPTR(pScrn)->Base);
 #endif
         }
     }
@@ -2798,7 +2802,9 @@
                    "Initializing display adapter through int10\n");
 
         if (xf86LoadSubModule(pScrn, "int10")) {
+#if 0
             xf86LoaderReqSymLists(int10Symbols, NULL);
+#endif
             pXGI->pInt = xf86InitInt10(pXGI->pEnt->index);
         }
         else {
@@ -2829,9 +2835,9 @@
         XGIFreeRec(pScrn);
         return FALSE;
     }
-
+#if 0
     xf86LoaderReqSymLists(ramdacSymbols, NULL);
-
+#endif
     /* Set pScrn->monitor */
     pScrn->monitor = pScrn->confScreen->monitor;
 
@@ -3049,7 +3055,7 @@
     pXGI->xgi_HwDevExt.pjIOAddress = (XGIIOADDRESS) (pXGI->RelIO + 0x30);
     xf86DrvMsg(pScrn->scrnIndex, from, "Relocated IO registers at 0x%lX\n",
                (unsigned long) pXGI->RelIO);
-       ErrorF("xgi_driver.c-pXGI->xgi_HwDevExt.pjIOAddress=0x%x...\n", 
pXGI->xgi_HwDevExt.pjIOAddress);
+       ErrorF("xgi_driver.c-pXGI->xgi_HwDevExt.pjIOAddress=0x%lx...\n", 
pXGI->xgi_HwDevExt.pjIOAddress);
 
     if (!xf86SetDepthBpp(pScrn, 0, 0, 0, pix24flags)) {
         XGIErrorLog(pScrn, "xf86SetDepthBpp() error\n");
@@ -3695,7 +3701,9 @@
 #if !defined(__powerpc__)
     /* Now load and initialize VBE module. */
     if (xf86LoadSubModule(pScrn, "vbe")) {
+#if 0
         xf86LoaderReqSymLists(vbeSymbols, NULL);
+#endif
         pXGI->pVbe = VBEExtendedInit(pXGI->pInt, pXGI->pEnt->index,
                                      SET_BIOS_SCRATCH | RESTORE_BIOS_SCRATCH);
         if (!pXGI->pVbe) {
@@ -3728,7 +3736,7 @@
                        pScrn->monitor->nHsync = 1;
                        pScrn->monitor->hsync[0].lo=30;
                        pScrn->monitor->hsync[0].hi=50;
-                       ErrorF("No HorizSync information set in Monitor section 
and use default (%d, %d)...\n", 
+                       ErrorF("No HorizSync information set in Monitor section 
and use default (%g, %g)...\n", 
                                pScrn->monitor->hsync[0].lo, 
pScrn->monitor->hsync[0].hi);
                }
 
@@ -3737,7 +3745,7 @@
                        pScrn->monitor->nVrefresh = 1;
                        pScrn->monitor->vrefresh[0].lo=40;
                        pScrn->monitor->vrefresh[0].hi=60;
-                       ErrorF("No VertRefresh information set in Monitor 
section and use default (%d, %d)...\n", 
+                       ErrorF("No VertRefresh information set in Monitor 
section and use default (%g, %g)...\n", 
                                pScrn->monitor->vrefresh[0].lo, 
pScrn->monitor->vrefresh[0].hi);
                }
        }
@@ -4117,8 +4125,9 @@
         XGIFreeRec(pScrn);
         return FALSE;
     }
+#if 0
     xf86LoaderReqSymLists(fbSymbols, NULL);
-
+#endif
     /* Load XAA if needed */
     if (!pXGI->NoAccel) 
        {
@@ -4139,7 +4148,9 @@
                                XGIFreeRec(pScrn);
                                return FALSE;
                        }
+#if 0
                        xf86LoaderReqSymLists(xaaSymbols, NULL);
+#endif
                }
 #endif
 
@@ -4150,7 +4161,9 @@
                          XGIErrorLog(pScrn, "Could not load exa module\n");
                          return FALSE;
                   }
+#if 0
                   xf86LoaderReqSymLists(exaSymbols, NULL);
+#endif
                }
 #endif
        }
@@ -4169,14 +4182,18 @@
             XGIFreeRec(pScrn);
             return FALSE;
         }
+#if 0
         xf86LoaderReqSymLists(shadowSymbols, NULL);
+#endif
     }
 
     /* Load the dri module if requested. */
 #ifdef XF86DRI
     if(pXGI->loadDRI) {
         if (xf86LoadSubModule(pScrn, "dri")) {
+#if 0
             xf86LoaderReqSymLists(driSymbols, drmSymbols, NULL);
+#endif
         }
         else {
             if (!IS_DUAL_HEAD(pXGI))
@@ -4771,7 +4788,9 @@
 #if !defined(__powerpc__)
     if (!IS_DUAL_HEAD(pXGI) || !IS_SECOND_HEAD(pXGI)) {
         if (xf86LoadSubModule(pScrn, "vbe")) {
+#if 0
             xf86LoaderReqSymLists(vbeSymbols, NULL);
+#endif
             pXGI->pVbe = VBEExtendedInit(NULL, pXGI->pEnt->index,
                                          SET_BIOS_SCRATCH |
                                          RESTORE_BIOS_SCRATCH);
@@ -5044,7 +5063,6 @@
     PDEBUG(ErrorF("--- AccelInit ---  \n"));
     PDEBUG(XGIDumpRegs(pScrn));
 
-    miInitializeBackingStore(pScreen);
     xf86SetBackingStore(pScreen);
     xf86SetSilkenMouse(pScreen);
 
Index: dist/src/xgi_driver.h
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/xgi_driver.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- dist/src/xgi_driver.h       19 Jul 2012 15:24:43 -0000      1.1.1.1
+++ dist/src/xgi_driver.h       19 Jul 2012 19:18:20 -0000      1.2
@@ -493,10 +493,10 @@
       },
 };
 
-unsigned const char XGIScalingP1Regs[] = {
+static unsigned const char XGIScalingP1Regs[] = {
        0x08,0x09,0x0b,0x0c,0x0d,0x0e,0x10,0x11,0x12
 };
-unsigned const char XGIScalingP4Regs[] = {
+static unsigned const char XGIScalingP4Regs[] = {
        0x13,0x14,0x15,0x16,0x17,0x18,0x19,0x1a,0x1b
 };
 
Index: dist/src/xgi_opt.c
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/xgi_opt.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- dist/src/xgi_opt.c  19 Jul 2012 15:24:43 -0000      1.1.1.1
+++ dist/src/xgi_opt.c  19 Jul 2012 19:18:20 -0000      1.2
@@ -315,13 +315,13 @@
                                Non_DDCDefaultResolutionY , 
                                Non_DDCDefaultRefreshRate  );
 
-               if( (xf86NameCmp(Non_DDCDefaultResolutionX,"") == NULL) || 
(xf86NameCmp(Non_DDCDefaultResolutionY,"") == NULL) ) 
+               if( (xf86NameCmp(Non_DDCDefaultResolutionX,"") == 0) || 
(xf86NameCmp(Non_DDCDefaultResolutionY,"") == 0) ) 
                {
                        strcpy(Non_DDCDefaultResolutionX, "1024");
                        strcpy(Non_DDCDefaultResolutionY, "768");
                }
 
-               if( (xf86NameCmp(Non_DDCDefaultRefreshRate,"") == NULL) || 
(xf86NameCmp(Non_DDCDefaultRefreshRate,"auto") == NULL) ) 
+               if( (xf86NameCmp(Non_DDCDefaultRefreshRate,"") == 0) || 
(xf86NameCmp(Non_DDCDefaultRefreshRate,"auto") == 0) ) 
                                strcpy(Non_DDCDefaultRefreshRate, "60");
 
                ErrorF("Non-DDC default mode is (%s x %s @ %s Hz)...\n", 
Index: dist/src/xgi_setup.c
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/xgi_setup.c,v
retrieving revision 1.1.1.1
retrieving revision 1.3
diff -u -r1.1.1.1 -r1.3
--- dist/src/xgi_setup.c        19 Jul 2012 15:24:43 -0000      1.1.1.1
+++ dist/src/xgi_setup.c        20 Jul 2012 01:35:41 -0000      1.3
@@ -47,10 +47,11 @@
 #include "xgi.h"
 #include "xgi_regs.h"
 #include "xgi_dac.h"
+#include "xgi_driver.h"
 /* #include "valid_mode.h" */
 
 #define _XF86DGA_SERVER_
-#include <X11/extensions/xf86dgastr.h>
+#include <X11/extensions/xf86dgaproto.h>
 
 #include "globals.h"
 #ifdef HAVE_XEXTPROTO_71
@@ -65,7 +66,7 @@
 extern  int  FbDevExist;
 
 static Bool bAccessVGAPCIInfo(PXGI_HW_DEVICE_INFO pHwDevInfo, ULONG ulOffset,
-    ULONG ulSet, ULONG *pulValue);
+    ULONG ulSet, CARD32 *pulValue);
 static Bool bAccessNBridgePCIInfo(PXGI_HW_DEVICE_INFO pHwDevInfo,
     ULONG ulOffset, ULONG ulSet, ULONG *pulValue);
 static Bool XGI_IsXG21(ScrnInfoPtr pScrn);
@@ -659,7 +660,7 @@
 }
 
 Bool
-bAccessVGAPCIInfo(PXGI_HW_DEVICE_INFO pHwDevInfo, ULONG ulOffset, ULONG ulSet, 
ULONG *pulValue)
+bAccessVGAPCIInfo(PXGI_HW_DEVICE_INFO pHwDevInfo, ULONG ulOffset, ULONG ulSet, 
CARD32 *pulValue)
 {
     XGIPtr pXGI ;
 #ifdef XSERVER_LIBPCIACCESS
@@ -678,7 +679,7 @@
        err = pci_device_cfg_write_u32(pXGI->PciInfo, *pulValue,
                                       ulOffset & ~3);
     } else {
-       err = pci_device_cfg_write_u32(pXGI->PciInfo, pulValue,
+       err = pci_device_cfg_read_u32(pXGI->PciInfo, (uint32_t *)pulValue,
                                       ulOffset & ~3);
     }
 
Index: dist/src/xgi_video.c
===================================================================
RCS file: /cvsroot/xsrc/external/mit/xf86-video-xgi/dist/src/xgi_video.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- dist/src/xgi_video.c        19 Jul 2012 15:24:43 -0000      1.1.1.1
+++ dist/src/xgi_video.c        19 Jul 2012 19:18:20 -0000      1.2
@@ -101,7 +101,7 @@
         short, short, short, short, unsigned int *, unsigned int *, pointer);
 static int XGIPutImage( ScrnInfoPtr,
         short, short, short, short, short, short, short, short,
-        int, unsigned char*, short, short, Bool, RegionPtr, pointer);
+        int, unsigned char*, short, short, Bool, RegionPtr, pointer, 
DrawablePtr);
 static int XGIQueryImageAttributes(ScrnInfoPtr,
         int, unsigned short *, unsigned short *,  int *, int *);
 
@@ -1081,7 +1081,8 @@
   int id, unsigned char* buf,
   short width, short height,
   Bool sync,
-  RegionPtr clipBoxes, pointer data
+  RegionPtr clipBoxes, pointer data,
+  DrawablePtr pDraw
 ){     
    XGIPtr pXGI = XGIPTR(pScrn);
    XGIPortPrivPtr pPriv = (XGIPortPrivPtr)data;
_______________________________________________
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to