archrelease: copy trunk to extra-x86_64
[arch-packages.git] / xf86-video-vmware / repos / extra-x86_64 / gcc8.diff
blobf9ee9b0b6310e847abfa0e8a61da97c521272d97
1 --- src/vmware.h 2018-05-11 17:43:24.776710047 +0200
2 +++ src/vmware.h.new 2018-05-11 17:45:16.599821536 +0200
3 @@ -83,7 +83,7 @@
5 typedef struct {
6 EntityInfoPtr pEnt;
7 -#if XSERVER_LIBPCIACCESS
8 +#ifdef XSERVER_LIBPCIACCESS
9 struct pci_device *PciInfo;
10 #else
11 pciVideoPtr PciInfo;
12 @@ -207,7 +207,7 @@
13 /* Undefine this to kill all acceleration */
14 #define ACCELERATE_OPS
16 -#if XSERVER_LIBPCIACCESS
17 +#ifdef XSERVER_LIBPCIACCESS
18 #define VENDOR_ID(p) (p)->vendor_id
19 #define DEVICE_ID(p) (p)->device_id
20 #define SUBVENDOR_ID(p) (p)->subvendor_id
21 --- src/vmware.c 2018-05-11 17:28:30.612158774 +0200
22 +++ src/vmware.c.new 2018-05-11 17:38:40.108785284 +0200
23 @@ -341,7 +341,7 @@
24 SVGA_LEGACY_BASE_PORT + SVGA_VALUE_PORT*sizeof(uint32);
25 } else {
26 /* Note: This setting of valueReg causes unaligned I/O */
27 -#if XSERVER_LIBPCIACCESS
28 +#ifdef XSERVER_LIBPCIACCESS
29 pVMWARE->portIOBase = pVMWARE->PciInfo->regions[0].base_addr;
30 #else
31 pVMWARE->portIOBase = pVMWARE->PciInfo->ioBase[0];
32 @@ -383,7 +383,7 @@
34 pVMWARE->suspensionSavedRegId = id;
36 -#if !XSERVER_LIBPCIACCESS
37 +#ifndef XSERVER_LIBPCIACCESS
38 pVMWARE->PciTag = pciTag(pVMWARE->PciInfo->bus, pVMWARE->PciInfo->device,
39 pVMWARE->PciInfo->func);
40 #endif
41 @@ -727,13 +727,13 @@
42 VMWAREMapMem(ScrnInfoPtr pScrn)
44 VMWAREPtr pVMWARE = VMWAREPTR(pScrn);
45 -#if XSERVER_LIBPCIACCESS
46 +#ifdef XSERVER_LIBPCIACCESS
47 int err;
48 struct pci_device *const device = pVMWARE->PciInfo;
49 void *fbBase;
50 #endif
52 -#if XSERVER_LIBPCIACCESS
53 +#ifdef XSERVER_LIBPCIACCESS
54 err = pci_device_map_range(device,
55 pVMWARE->memPhysBase,
56 pVMWARE->videoRam,
57 @@ -770,7 +770,7 @@
59 VmwareLog(("Unmapped: %p/%u\n", pVMWARE->FbBase, pVMWARE->videoRam));
61 -#if XSERVER_LIBPCIACCESS
62 +#ifdef XSERVER_LIBPCIACCESS
63 pci_device_unmap_range(pVMWARE->PciInfo, pVMWARE->FbBase, pVMWARE->videoRam);
64 #else
65 xf86UnMapVidMem(pScrn->scrnIndex, pVMWARE->FbBase, pVMWARE->videoRam);
66 @@ -1045,7 +1045,7 @@
67 VMWAREInitFIFO(ScrnInfoPtr pScrn)
69 VMWAREPtr pVMWARE = VMWAREPTR(pScrn);
70 -#if XSERVER_LIBPCIACCESS
71 +#ifdef XSERVER_LIBPCIACCESS
72 struct pci_device *const device = pVMWARE->PciInfo;
73 int err;
74 void *mmioVirtBase;
75 @@ -1058,7 +1058,7 @@
77 pVMWARE->mmioPhysBase = vmwareReadReg(pVMWARE, SVGA_REG_MEM_START);
78 pVMWARE->mmioSize = vmwareReadReg(pVMWARE, SVGA_REG_MEM_SIZE) & ~3;
79 -#if XSERVER_LIBPCIACCESS
80 +#ifdef XSERVER_LIBPCIACCESS
81 err = pci_device_map_range(device, pVMWARE->mmioPhysBase,
82 pVMWARE->mmioSize,
83 PCI_DEV_MAP_FLAG_WRITABLE,
84 @@ -1099,7 +1099,7 @@
85 TRACEPOINT
87 vmwareWriteReg(pVMWARE, SVGA_REG_CONFIG_DONE, 0);
88 -#if XSERVER_LIBPCIACCESS
89 +#ifdef XSERVER_LIBPCIACCESS
90 pci_device_unmap_range(pVMWARE->PciInfo, pVMWARE->mmioVirtBase, pVMWARE->mmioSize);
91 #else
92 xf86UnMapVidMem(pScrn->scrnIndex, pVMWARE->mmioVirtBase, pVMWARE->mmioSize);
93 --- src/vmware_bootstrap.c 2018-05-11 20:59:15.003530525 +0200
94 +++ src/vmware_bootstrap.c.new 2018-05-11 21:02:11.228289137 +0200
95 @@ -91,7 +91,7 @@
96 VMW_STRING(PACKAGE_VERSION_MAJOR) "." VMW_STRING(PACKAGE_VERSION_MINOR) \
97 "." VMW_STRING(PACKAGE_VERSION_PATCHLEVEL)
99 -#if !XSERVER_LIBPCIACCESS
100 +#ifndef XSERVER_LIBPCIACCESS
101 static const char VMWAREBuildStr[] = "VMware Guest X Server "
102 VMWARE_DRIVER_VERSION_STRING " - build=$Name$\n";
103 #else
104 @@ -127,7 +127,7 @@
105 #define vmwareLegacyRes NULL
106 #endif
108 -#if XSERVER_LIBPCIACCESS
109 +#ifdef XSERVER_LIBPCIACCESS
110 #define VENDOR_ID(p) (p)->vendor_id
111 #define DEVICE_ID(p) (p)->device_id
112 #define SUBVENDOR_ID(p) (p)->subvendor_id
113 @@ -141,7 +141,7 @@
114 #define CHIP_REVISION(p) (p)->chipRev
115 #endif
117 -#if XSERVER_LIBPCIACCESS
118 +#ifdef XSERVER_LIBPCIACCESS
120 #define VMWARE_DEVICE_MATCH(d, i) \
121 {PCI_VENDOR_ID_VMWARE, (d), PCI_MATCH_ANY, PCI_MATCH_ANY, 0, 0, (i) }
122 @@ -220,7 +220,7 @@
123 static Bool
124 VMwarePreinitStub(ScrnInfoPtr pScrn, int flags)
126 -#if XSERVER_LIBPCIACCESS
127 +#ifdef XSERVER_LIBPCIACCESS
128 struct pci_device *pciInfo;
129 #else
130 pciVideoPtr pciInfo;
131 @@ -270,7 +270,7 @@
132 return (*pScrn->PreInit)(pScrn, flags);
135 -#if XSERVER_LIBPCIACCESS
136 +#ifdef XSERVER_LIBPCIACCESS
137 static Bool
138 VMwarePciProbe (DriverPtr drv,
139 int entity_num,
140 @@ -520,7 +520,7 @@
141 VMWARE_DRIVER_VERSION,
142 vmware_driver_name,
143 VMWAREIdentify,
144 -#if XSERVER_LIBPCIACCESS
145 +#ifdef XSERVER_LIBPCIACCESS
146 NULL,
147 #else
148 VMWAREProbe,
149 @@ -532,7 +532,7 @@
150 VMWareDriverFunc,
151 #endif
152 #if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) >= 4
153 -#if XSERVER_LIBPCIACCESS
154 +#ifdef XSERVER_LIBPCIACCESS
155 VMwareDeviceMatch,
156 VMwarePciProbe,
157 #else