Mon Jul 16 09:55:14 2018 UTC ()
Fix cats build.


(rjs)
diff -r1.1 -r1.2 xsrc/external/mit/xf86-video-nv/dist/src/nv_exa.c

cvs diff -r1.1 -r1.2 xsrc/external/mit/xf86-video-nv/dist/src/nv_exa.c (expand / switch to unified diff)

--- xsrc/external/mit/xf86-video-nv/dist/src/nv_exa.c 2018/07/12 21:19:54 1.1
+++ xsrc/external/mit/xf86-video-nv/dist/src/nv_exa.c 2018/07/16 09:55:13 1.2
@@ -11,27 +11,27 @@ @@ -11,27 +11,27 @@
11 * furnished to do so, subject to the following conditions: 11 * furnished to do so, subject to the following conditions:
12 * 12 *
13 * The above copyright notice and this permission notice shall be included in 13 * The above copyright notice and this permission notice shall be included in
14 * all copies or substantial portions of the Software. 14 * all copies or substantial portions of the Software.
15 * 15 *
16 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 18 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
19 * MICHAEL LORENZ BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 19 * MICHAEL LORENZ BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
20 * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 20 * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
21 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22 */ 22 */
23 23
24/* $NetBSD: nv_exa.c,v 1.1 2018/07/12 21:19:54 macallan Exp $ */ 24/* $NetBSD: nv_exa.c,v 1.2 2018/07/16 09:55:13 rjs Exp $ */
25 25
26#ifdef HAVE_CONFIG_H 26#ifdef HAVE_CONFIG_H
27#include "config.h" 27#include "config.h"
28#endif 28#endif
29 29
30#include "nv_include.h" 30#include "nv_include.h"
31#include "miline.h" 31#include "miline.h"
32#include "nv_dma.h" 32#include "nv_dma.h"
33#include "exa.h" 33#include "exa.h"
34 34
35//#define DEBUG 35//#define DEBUG
36 36
37#ifdef DEBUG 37#ifdef DEBUG
@@ -228,43 +228,26 @@ NvDownloadFromScreen(PixmapPtr pSrc, int @@ -228,43 +228,26 @@ NvDownloadFromScreen(PixmapPtr pSrc, int
228 src += (x * cpp) + (y * src_pitch); 228 src += (x * cpp) + (y * src_pitch);
229 229
230 NVSync(pScrn); 230 NVSync(pScrn);
231 231
232 while (h--) { 232 while (h--) {
233 memcpy(dst, src, wBytes); 233 memcpy(dst, src, wBytes);
234 src += src_pitch; 234 src += src_pitch;
235 dst += dst_pitch; 235 dst += dst_pitch;
236 } 236 }
237 LEAVE; 237 LEAVE;
238 return TRUE; 238 return TRUE;
239} 239}
240 240
241#ifdef __arm__ 
242static Bool 
243NvPrepareAccess(PixmapPtr pPix, int index) 
244{ 
245 ScrnInfoPtr pScrn = xf86Screens[pPix->drawable.pScreen->myNum]; 
246 NVPtr pNv = NVPTR(pScrn); 
247 
248 IgsWaitReady(fPtr); 
249 return TRUE;  
250} 
251 
252static void 
253NvFinishAccess(PixmapPtr pPix, int index) 
254{ 
255} 
256#endif 
257 
258Bool 241Bool
259NvInitExa(ScreenPtr pScreen) 242NvInitExa(ScreenPtr pScreen)
260{ 243{
261 ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum]; 244 ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
262 NVPtr pNv = NVPTR(pScrn); 245 NVPtr pNv = NVPTR(pScrn);
263 ExaDriverPtr pExa; 246 ExaDriverPtr pExa;
264 int surfaceFormat, rectFormat; 247 int surfaceFormat, rectFormat;
265 248
266 pExa = exaDriverAlloc(); 249 pExa = exaDriverAlloc();
267 if (!pExa) 250 if (!pExa)
268 return FALSE; 251 return FALSE;
269 252
270 pNv->pExa = pExa; 253 pNv->pExa = pExa;
@@ -316,19 +299,15 @@ NvInitExa(ScreenPtr pScreen) @@ -316,19 +299,15 @@ NvInitExa(ScreenPtr pScreen)
316 NVDmaStart(pNv, RECT_FORMAT, 1); 299 NVDmaStart(pNv, RECT_FORMAT, 1);
317 NVDmaNext (pNv, rectFormat); 300 NVDmaNext (pNv, rectFormat);
318 301
319 pNv->currentRop = ~0; /* set to something invalid */ 302 pNv->currentRop = ~0; /* set to something invalid */
320 NVSetRopSolid(pScrn, GXcopy, ~0); 303 NVSetRopSolid(pScrn, GXcopy, ~0);
321 304
322 NVDmaKickoff(pNv); 305 NVDmaKickoff(pNv);
323 306
324 /* EXA hits more optimized paths when it does not have to fallback  307 /* EXA hits more optimized paths when it does not have to fallback
325 * because of missing UTS/DFS, hook memcpy-based UTS/DFS. 308 * because of missing UTS/DFS, hook memcpy-based UTS/DFS.
326 */ 309 */
327 pExa->UploadToScreen = NvUploadToScreen; 310 pExa->UploadToScreen = NvUploadToScreen;
328 pExa->DownloadFromScreen = NvDownloadFromScreen; 311 pExa->DownloadFromScreen = NvDownloadFromScreen;
329#ifdef __arm__ 
330 pExa->PrepareAccess = IgsPrepareAccess; 
331 pExa->FinishAccess = IgsFinishAccess; 
332#endif 
333 return exaDriverInit(pScreen, pExa); 312 return exaDriverInit(pScreen, pExa);
334} 313}