Subject: Re: console device selection
To: Jared D. McNeill <>
From: Bill Studenmund <>
List: tech-kern
Date: 09/05/2006 16:36:18
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Sat, Sep 02, 2006 at 08:57:28AM -0300, Jared D. McNeill wrote:
> On 2-Sep-06, at 3:32 AM, Garrett D'Amore wrote:
> >Given this, how do folks feel about having wscons have this framework
> >for selecting console devices?  It would mean tweaking a bunch of
> >console devices.  But it would solve/cleanup the problem.  As we are
> >getting more and more devices that can be console devices, it seems =20
> >like
> >we need a unified way to select amongst them, especially as many of
> >these devices are potentially on expansion busses.
> Yes, please. This has been a pet peeve of mine for a long time.
> One comment about struct cons_device:
>     int (*initialize)(void);
> This will need to take parameters. MD code may need to pass bus tags/=20
> handles to an MI driver (as is the case for vga), or in a more =20
> extreme case (igsfb_pci) it also needs a pci_chipset_tag_t, and the =20
> PCI bus/device/function numbers of the device. Not sure what other =20
> devices might need..

I don't think that's at this level of abstraction. The md code would be=20
the thing that registers a potential console, and when its init is called,=
it can make specific calls into known MI frame buffer code. Or known MD=20
frame buffer code. :-)

Setting up the console (at this level) usually is tricky. Serial ports=20
usually had two sets of interfaces, one a normal character device and the=
other the console interface. I exect video consoles have the same.

Take care,


Content-Type: application/pgp-signature
Content-Disposition: inline

Version: GnuPG v1.4.3 (NetBSD)