diff options
Diffstat (limited to 'sys/arch/sparc/dev/tvtwo.c')
-rw-r--r-- | sys/arch/sparc/dev/tvtwo.c | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/sys/arch/sparc/dev/tvtwo.c b/sys/arch/sparc/dev/tvtwo.c index a46eb9c44cb..4b8cffa8aef 100644 --- a/sys/arch/sparc/dev/tvtwo.c +++ b/sys/arch/sparc/dev/tvtwo.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tvtwo.c,v 1.10 2006/02/12 12:02:29 miod Exp $ */ +/* $OpenBSD: tvtwo.c,v 1.11 2006/02/12 13:18:07 miod Exp $ */ /* * Copyright (c) 2003, 2006, Miodrag Vallat. * All rights reserved. @@ -107,6 +107,7 @@ #define PX_REG_DISPKLUDGE 0x00b8 /* write only */ #define DISPKLUDGE_DEFAULT 0xc41f #define DISPKLUDGE_BLANK (1 << 12) +#define DISPKLUDGE_SYNC (1 << 13) #define PX_REG_BT463_RED 0x0480 #define PX_REG_BT463_GREEN 0x0490 @@ -344,13 +345,18 @@ void tvtwo_burner(void *v, u_int on, u_int flags) { struct tvtwo_softc *sc = v; - volatile u_int32_t *dispkludge = - (u_int32_t *)(sc->sc_regs + PX_REG_DISPKLUDGE); + u_int32_t dispkludge; if (on) - *dispkludge = DISPKLUDGE_DEFAULT & ~DISPKLUDGE_BLANK; - else - *dispkludge = DISPKLUDGE_DEFAULT | DISPKLUDGE_BLANK; + dispkludge = DISPKLUDGE_DEFAULT & ~DISPKLUDGE_BLANK; + else { + dispkludge = DISPKLUDGE_DEFAULT | DISPKLUDGE_BLANK; + if (flags & WSDISPLAY_BURN_VBLANK) + dispkludge |= DISPKLUDGE_SYNC; + } + + *(volatile u_int32_t *)(sc->sc_regs + PX_REG_DISPKLUDGE) = + dispkludge; } void |