Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933512AbbEMIKZ (ORCPT ); Wed, 13 May 2015 04:10:25 -0400 Received: from mo4-p00-ob.smtp.rzone.de ([81.169.146.218]:9175 "EHLO mo4-p00-ob.smtp.rzone.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753574AbbEMIKN convert rfc822-to-8bit (ORCPT ); Wed, 13 May 2015 04:10:13 -0400 X-RZG-AUTH: :JGIXVUS7cutRB/49FwqZ7WcKdUCnXG6JabOfSXKWrat7m8zrw40= X-RZG-CLASS-ID: mo00 Content-Type: text/plain; charset=windows-1252 Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: [Gta04-owner] [PATCH 0/3] tty slave device support - version 3. From: "Dr. H. Nikolaus Schaller" In-Reply-To: <21C337B3-D612-4931-BA23-6B7518E6E4DD@goldelico.com> Date: Wed, 13 May 2015 10:09:50 +0200 Cc: Mark Rutland , One Thousand Gnomes , Arnd Bergmann , "devicetree@vger.kernel.org" , Greg Kroah-Hartman , Sebastian Reichel , "linux-kernel@vger.kernel.org" , "grant.likely@linaro.org" , Pavel Machek , NeilBrown , Jiri Slaby , List for communicating with real GTA04 owners , Marek Belisko Content-Transfer-Encoding: 8BIT Message-Id: <112A49DF-935D-41DF-8DF7-F04CC13B9598@goldelico.com> References: <55492001.30806@hurleysoftware.com> <20150506092738.GB4508@amd> <554A03A7.2000504@hurleysoftware.com> <20150506123632.GA1764@leverpostej> <20150506141547.GB1764@leverpostej> <20150506171802.GE2974@leverpostej> <554B7D33.602@hurleysoftware.com> <9EF54D80-F634-4D59-BFD9-FC79FCFE06DE@goldelico.com> <554B8A14.2080904@hurleysoftware.com> <21C337B3-D612-4931-BA23-6B7518E6E4DD@goldelico.com> To: Peter Hurley X-Mailer: Apple Mail (2.1878.6) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2238 Lines: 51 Hi Peter, Am 07.05.2015 um 18:46 schrieb Dr. H. Nikolaus Schaller : > Hi Peter, > > Am 07.05.2015 um 17:51 schrieb Peter Hurley : > >> On 05/07/2015 11:34 AM, Dr. H. Nikolaus Schaller wrote: >>> Am 07.05.2015 um 16:56 schrieb Peter Hurley : >>>> On 05/07/2015 08:46 AM, Dr. H. Nikolaus Schaller wrote: >> >>>> Both devicetree and tty/serial can already represent independent control; >>>> what is proposed is a way to express dependent control, and in all cases, >>>> that control stems directly from either the UART state itself or via >>>> commands sent over that interface. >>> >>> Yes. This is why I propose that the tty/uart driver can send an internal notification >>> to the device driver. And the device driver can register to be notified by the UART >>> that is identified by the phandle of the slave DT entry. >> >> I've not seen any code with your proposal, so that makes it impossible to >> compare competing solutions. > > If you can give me some (unspecified) time to do it, I can write (simplified) patches > to demonstrate the idea. > > I just hesitate to work out and submit a counter proposal to what Neil has submitted, > because it will become wasted effort if it is rejected before I am finished. We have progress and some code on our workbench that identifies the uart_port by phandle, resolves probing sequence and intercepts uart_update_mctrl calls. So we can let the attached slave driver know that the DTR line has changed, which is typically the power-on/off signal on UART/RS232. The driver can then power manage the device as needed (GPIO state, GPIO pulses, regulator, I2C or whatever). What we have not yet solved is the issue that a slave driver might want to know that the controlled slave device is active (i.e. is autonomously sending data to the UART). Even if the tty is not open. But we have an rough idea how we want to solve that. Patches will come asap. BR, Nikolaus -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/