diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2003-06-17 17:35:44 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2003-06-17 17:35:44 +0000 |
commit | b37ecf5b03678191a26dd176cde8980b08eb766a (patch) | |
tree | 2658214e501950d9851b7692e92c5ca8cbf26810 /sys/arch/sparc64/dev/fb.c | |
parent | 715335a33b88e081090522d8f3f0a6aca95e87de (diff) |
Extend the sunfb structure to take care of the PROM cursor position
pointers, and adapt creator to the fb api.
ok jason@
Diffstat (limited to 'sys/arch/sparc64/dev/fb.c')
-rw-r--r-- | sys/arch/sparc64/dev/fb.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/sys/arch/sparc64/dev/fb.c b/sys/arch/sparc64/dev/fb.c index ff4962027fa..c3a16df3b7c 100644 --- a/sys/arch/sparc64/dev/fb.c +++ b/sys/arch/sparc64/dev/fb.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fb.c,v 1.1 2003/06/16 20:46:10 miod Exp $ */ +/* $OpenBSD: fb.c,v 1.2 2003/06/17 17:35:40 miod Exp $ */ /* $NetBSD: fb.c,v 1.23 1997/07/07 23:30:22 pk Exp $ */ /* @@ -166,21 +166,23 @@ fbwscons_console_init(struct sunfb *sf, struct wsscreen_descr *wsc, int row, void (*burner)(void *, u_int, u_int)) { long defattr; - int *ccolp, *crowp; - if (romgetcursoraddr(&crowp, &ccolp)) - ccolp = crowp = NULL; - if (ccolp != NULL) - sf->sf_ro.ri_ccol = *ccolp; + if (romgetcursoraddr(&sf->sf_crowp, &sf->sf_ccolp)) + sf->sf_ccolp = sf->sf_crowp = NULL; + if (sf->sf_ccolp != NULL) + sf->sf_ro.ri_ccol = *sf->sf_ccolp; if (row < 0) { - if (crowp != NULL) - sf->sf_ro.ri_crow = *crowp; + if (sf->sf_crowp != NULL) + sf->sf_ro.ri_crow = *sf->sf_crowp; else /* assume last row */ sf->sf_ro.ri_crow = sf->sf_ro.ri_rows - 1; - } else + } else { sf->sf_ro.ri_crow = row; + if (sf->sf_crowp != NULL) + *sf->sf_crowp = row; + } /* * Scale back rows and columns if the font would not otherwise |