[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20100625120329.1303aa61@lxorguk.ukuu.org.uk>
Date: Fri, 25 Jun 2010 12:03:29 +0100
From: Alan Cox <alan@...rguk.ukuu.org.uk>
To: Samo Pogacnik <samo_pogacnik@....net>
Cc: linux-embedded <linux-embedded@...r.kernel.org>,
linux kernel <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] detour TTY driver - now ttyprintk
> +static int tpk_write_room(struct tty_struct *tty)
> +{
> + int ret = tpk_space;
> +
> + /* allow char by char under max pressure */
> + if (tpk_space == 0)
> + tpk_space = 1;
That won't do what you think, the ldisc will keep seeing progress and
generate millions of 1 byte I/Os in a loop !
Otherwise looks excellent.
> + switch (cmd) {
> + /* Stop TIOCCONS */
> + case TIOCCONS:
> + return -EOPNOTSUPP;
And I'll fix this bit up to work properly in the core code.
With my devices.txt owner hat on I'll allocate the minor as you suggest
(and double check this causes no problems), with my tty hat on can you
send it to GregKH for merging into the tree.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists