Return-Path: Date: Fri, 19 Aug 2016 12:06:31 +0100 From: One Thousand Gnomes To: "H. Nikolaus Schaller" Cc: Sebastian Reichel , Rob Herring , Greg Kroah-Hartman , Marcel Holtmann , Jiri Slaby , Pavel Machek , Peter Hurley , NeilBrown , Arnd Bergmann , Linus Walleij , "open list:BLUETOOTH DRIVERS" , "linux-serial@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [RFC PATCH 0/3] UART slave device bus Message-ID: <20160819120631.5fe2af0d@lxorguk.ukuu.org.uk> In-Reply-To: References: <20160818011445.22726-1-robh@kernel.org> <20160818202900.hyvm4hfxedifuefn@earth> <20160819052125.ze5zilppwoe3f2lx@earth> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII List-ID: > If possible, please do a callback for every character that arrives. > And not only if the rx buffer becomes full, to give the slave driver > a chance to trigger actions almost immediately after every character. > This probably runs in interrupt context and can happen often. We don't realistically have the clock cycles to do that on a low end embedded processor handling high speed I/O. The best you can do is trigger a workqueue to switch the buffer data around and call the helper while the uart may be receiving more bytes. What you are asking for you'd get out of the first parts of tidying up the receive paths because you'd set a different port->rx() method and get bursts of characters, flags and length data. Alan