Set RI_NO_AUTO in ri_flg if init function is invoked from cnattach.
Untested. (3100 support seems somewhat broken, per gxemul output)
This commit is contained in:
parent
15fb978372
commit
6f304e5ae5
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pm.c,v 1.7 2008/05/26 10:31:22 nisimura Exp $ */
|
||||
/* $NetBSD: pm.c,v 1.8 2010/05/15 20:31:10 tsutsui Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2002, 2003 The NetBSD Foundation, Inc.
|
||||
@ -30,7 +30,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: pm.c,v 1.7 2008/05/26 10:31:22 nisimura Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: pm.c,v 1.8 2010/05/15 20:31:10 tsutsui Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
@ -171,9 +171,10 @@ pm_attach(struct device *parent, struct device *self, void *aux)
|
||||
ri = &pm_ri;
|
||||
console = (ri->ri_bits != NULL);
|
||||
|
||||
if (console)
|
||||
if (console) {
|
||||
sc->sc_nscreens = 1;
|
||||
else
|
||||
ri->ri_flg &= ~RI_NO_AUTO;
|
||||
} else
|
||||
pm_common_init();
|
||||
|
||||
printf(": %dx%d, %dbpp\n", ri->ri_width, ri->ri_height, ri->ri_depth);
|
||||
@ -243,6 +244,8 @@ pm_common_init(void)
|
||||
ri = &pm_ri;
|
||||
|
||||
ri->ri_flg = RI_CENTER;
|
||||
if (ri->ri_bits == NULL)
|
||||
ri->ri_flg |= RI_NO_AUTO;
|
||||
ri->ri_depth = ((kn01csr & KN01_CSR_MONO) != 0 ? 1 : 8);
|
||||
ri->ri_width = 1024;
|
||||
ri->ri_height = 864;
|
||||
|
Loading…
Reference in New Issue
Block a user