diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2006-07-25 21:23:33 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2006-07-25 21:23:33 +0000 |
commit | 18714f8a7b3ff37ea2c79d98f63cdaa23f920a81 (patch) | |
tree | 7f9f1458f0d218575d9c907d44ca48a79d3ab099 /sys/dev | |
parent | 495c71bb13aeb85b37821a81b3a1eaea9fa5a728 (diff) |
Do not bother reading the existing colormap on attach, since we will
override it with the rasops one.
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/sbus/cgsix.c | 14 | ||||
-rw-r--r-- | sys/dev/sbus/cgthree.c | 9 |
2 files changed, 5 insertions, 18 deletions
diff --git a/sys/dev/sbus/cgsix.c b/sys/dev/sbus/cgsix.c index 3821e8979c1..6480897f328 100644 --- a/sys/dev/sbus/cgsix.c +++ b/sys/dev/sbus/cgsix.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cgsix.c,v 1.53 2006/06/02 20:00:56 miod Exp $ */ +/* $OpenBSD: cgsix.c,v 1.54 2006/07/25 21:23:32 miod Exp $ */ /* * Copyright (c) 2001 Jason L. Wright (jason@thought.net) @@ -116,7 +116,7 @@ cgsixattach(struct device *parent, struct device *self, void *aux) { struct cgsix_softc *sc = (struct cgsix_softc *)self; struct sbus_attach_args *sa = aux; - int node, console, i; + int node, console; u_int32_t fhc, rev; const char *nam; @@ -198,14 +198,6 @@ cgsixattach(struct device *parent, struct device *self, void *aux) rev = (fhc & FHC_REV_MASK) >> FHC_REV_SHIFT; cgsix_reset(sc, rev); - /* grab the current palette */ - BT_WRITE(sc, BT_ADDR, 0); - for (i = 0; i < 256; i++) { - sc->sc_cmap.cm_map[i][0] = BT_READ(sc, BT_CMAP) >> 24; - sc->sc_cmap.cm_map[i][1] = BT_READ(sc, BT_CMAP) >> 24; - sc->sc_cmap.cm_map[i][2] = BT_READ(sc, BT_CMAP) >> 24; - } - cgsix_burner(sc, 1, 0); sc->sc_sunfb.sf_ro.ri_bits = (void *)bus_space_vaddr(sc->sc_bustag, @@ -257,7 +249,7 @@ fail_fhc: bus_space_unmap(sa->sa_bustag, sc->sc_bt_regs, CGSIX_BT_SIZE); fail_bt: fail: -; + return; } int diff --git a/sys/dev/sbus/cgthree.c b/sys/dev/sbus/cgthree.c index 9f623915573..0d387f639d7 100644 --- a/sys/dev/sbus/cgthree.c +++ b/sys/dev/sbus/cgthree.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cgthree.c,v 1.41 2006/06/02 20:00:56 miod Exp $ */ +/* $OpenBSD: cgthree.c,v 1.42 2006/07/25 21:23:32 miod Exp $ */ /* * Copyright (c) 2001 Jason L. Wright (jason@thought.net) @@ -209,7 +209,7 @@ cgthreeattach(struct device *parent, struct device *self, void *aux) { struct cgthree_softc *sc = (struct cgthree_softc *)self; struct sbus_attach_args *sa = aux; - int node, console, i; + int node, console; const char *nam; node = sa->sa_node; @@ -249,11 +249,6 @@ cgthreeattach(struct device *parent, struct device *self, void *aux) console = cgthree_is_console(node); cgthree_reset(sc); - - BT_WRITE(sc, BT_ADDR, 0); - for (i = 0; i < 256 * 3 / 4; i++) - sc->sc_cmap.cm_chip[i] = BT_READ(sc, BT_CMAP); - cgthree_burner(sc, 1, 0); sc->sc_sunfb.sf_ro.ri_bits = (void *)bus_space_vaddr(sc->sc_bustag, |