Subject: Re: should cngetc block?
To: Jaromir Dolecek <>
From: Kin Cho <>
List: tech-kern
Date: 02/05/2002 14:33:17
Jaromir Dolecek <> writes:

> wrote:
> > I'm looking for a function like cngetc (in dev/cons.c), but
> > doesn't block for an available char.
> Note that cngetc() is only mean for very limited set of things,
> where it's not possible to use the terminal interface, like
> when asking for root/swap on boot, or when in DDB.

Exactly.  We have a boot monitor/loader built from a barebone

I'm looking for a function to poll (but not block) for keyboard
input.  It seems to me cngetc should not block (unless enabled by
cnpollc(1)), and if so would be the right function for me.