From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <57491b2937028588564c58c83826c506@felloff.net> Date: Thu, 17 Jul 2014 20:41:06 +0200 From: cinap_lenrek@felloff.net To: 9fans@9fans.net In-Reply-To: <2bd8d0124ea7bda9b5ba618c07633cab@ladd.quanstro.net> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Subject: Re: [9fans] kbdputc() in devcons.c in 9front? Topicbox-Message-UUID: 050e85e4-ead9-11e9-9d60-3106f5b1d025 rio multiplexes /dev/kbd, so it opens it and derives the windows kbd and cons files from it. it obviously has to read /dev/kbd to multiplex it. now, the incompatibility is that opening /dev/kbd disables /dev/cons input. the reason is that /dev/cons is buffered but pressing keys on the keyboard will result in characters being queued to /dev/cons. /dev/kbd reading programs should *not* require a dummy reader proc to flush duplicated console input in addition to reading /dev/kbd. you open /dev/kbd and the keyboard is yours. it is also harder to filter or translate multiple asynchronously read file stremas instead of just one. and filtering /dev/kbd is not much differnet from filtering /dev/cons. in addition, you have keyboard chords. -- cinap