Subject: Re: Ultra 5 X11
To: Eduardo Horvath <eeh@NetBSD.org>
From: Michael <macallan18@earthlink.net>
List: port-sparc
Date: 02/10/2005 15:39:35
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello,

>>>  Whatever strange things XFree does to the display machfb
>>> should be able to undo.
>> Sort of. But this isn't quite as easy. When XFree exits it tries to 
>> set
>> everything back to the state it found when starting - works fine on my
>> U10. Then it uses some ioctl() to silence the console while it's
>> working and another one to tell the console it can take over again, I
>> use it to clean things up when XFree exits ( cleaning the screen for
>> instance, but that's not yet in the cvs tree ). But if XFree crashes 
>> or
>> we get a kernel panic there's no graceful exit, therefore no ioctl() 
>> to
>> tell machfb what's going on and ultimately no console output on the
>> screen.
>
> Oh, in that case, there should already be a hook that is called when
> entering DDB or panic-ing specifically for this purpose.  ISTR it
> was even wired up to call into the wscons infrastructure.  I wouln't
> think adding plugging machfb into that would be too much work.  Or
> was that backed out?
I didn't know something like that exists (I'm still a newbie in kernel 
programming after all) - adding it shouldn't be hard at all. I'd just 
have to force the graphics chip back to the console screen, everything 
it needs should already be there so it would only be a couple of lines 
to add.

> In any case, you should be able to add a hook into Debugger() to
> undo whatever that ioctl() did and get the console back.
I guess that's the next thing I'll do.

have fun
Michael
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (Darwin)

iQEVAwUBQgvGh8pnzkX8Yg2nAQIl3wf/S74ch34snkNo9Zh5QXJ4SqnPB4rHVd5I
alk5oXi5xvZE+XZDI0NpV6UmUgTqDxNTrLNmcJW1st3bWUyKi636O/ayP85ULD6c
9H159N1ZvkMdTQZ11mguBhPAJySwhlw7UfiOJog8GuBjHpHr1ysRlJRHzh+BukBd
L6u+wzfE8Ubt0H/gT/Es145KCO34QpfOCgwBKDxqLnvEWMRVUcPxn7bsK7wPB2f3
RUteFFbNsqRAzBrmnyYfrrAYqpFDl79rWO8umPawRAPxAAhWDfIzztTjk6okQ0q5
obKV18FOUaL/XZGHUtKgNkz+Hqj/ClNQshsisMwuIUVS9KbHsDthlw==
=kU4U
-----END PGP SIGNATURE-----