Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/sparc64/dev - initialize sc_bg_cache and FFB_FBC_BG...



details:   https://anonhg.NetBSD.org/src/rev/597050cf7586
branches:  trunk
changeset: 810683:597050cf7586
user:      macallan <macallan%NetBSD.org@localhost>
date:      Fri Sep 11 22:27:17 2015 +0000

description:
- initialize sc_bg_cache and FFB_FBC_BG along with everything else so things
  get redrawn properly when exiting X
- fix off by one in ffb_ras_erasecols(), no more artifacts when the screen
  is redrawn

diffstat:

 sys/arch/sparc64/dev/ffb.c |  11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diffs (48 lines):

diff -r 4f858c97c36a -r 597050cf7586 sys/arch/sparc64/dev/ffb.c
--- a/sys/arch/sparc64/dev/ffb.c        Fri Sep 11 15:56:56 2015 +0000
+++ b/sys/arch/sparc64/dev/ffb.c        Fri Sep 11 22:27:17 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ffb.c,v 1.55 2013/10/09 17:21:39 macallan Exp $        */
+/*     $NetBSD: ffb.c,v 1.56 2015/09/11 22:27:17 macallan Exp $        */
 /*     $OpenBSD: creator.c,v 1.20 2002/07/30 19:48:15 jason Exp $      */
 
 /*
@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ffb.c,v 1.55 2013/10/09 17:21:39 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ffb.c,v 1.56 2015/09/11 22:27:17 macallan Exp $");
 
 #include <sys/types.h>
 #include <sys/param.h>
@@ -640,7 +640,7 @@
        DPRINTF(("ffb_ras_init: standard resolution.\n"));
                fbc = FFB_FBC_XE_OFF;
        }
-       ffb_ras_fifo_wait(sc, 11);
+       ffb_ras_fifo_wait(sc, 7);
        DPRINTF(("WID: %08x\n", FBC_READ(sc, FFB_FBC_WID)));
        FBC_WRITE(sc, FFB_FBC_WID, 0x0);
        FBC_WRITE(sc, FFB_FBC_PPC,
@@ -656,8 +656,11 @@
        FBC_WRITE(sc, FFB_FBC_DRAWOP, FBC_DRAWOP_RECTANGLE);
        FBC_WRITE(sc, FFB_FBC_PMASK, 0xffffffff);
        FBC_WRITE(sc, FFB_FBC_FONTINC, 0x10000);
+       ffb_ras_fifo_wait(sc, 5);
        sc->sc_fg_cache = 0;
        FBC_WRITE(sc, FFB_FBC_FG, sc->sc_fg_cache);
+       sc->sc_bg_cache = 0;
+       FBC_WRITE(sc, FFB_FBC_BG, sc->sc_bg_cache);
        FBC_WRITE(sc, FFB_FBC_BLENDC, FFB_BLENDC_FORCE_ONE |
                                      FFB_BLENDC_DF_ONE_M_A |
                                      FFB_BLENDC_SF_A);
@@ -727,7 +730,7 @@
        FBC_WRITE(sc, FFB_FBC_BY, ri->ri_yorigin + row);
        FBC_WRITE(sc, FFB_FBC_BX, ri->ri_xorigin + col);
        FBC_WRITE(sc, FFB_FBC_BH, ri->ri_font->fontheight);
-       FBC_WRITE(sc, FFB_FBC_BW, n - 1);
+       FBC_WRITE(sc, FFB_FBC_BW, n);
        SYNC;
 }
 



Home | Main Index | Thread Index | Old Index