From mboxrd@z Thu Jan 1 00:00:00 1970 From: Baruch Siach Subject: Re: [PATCH v2 1/2] gpio: Add driver for Zynq GPIO controller Date: Mon, 7 Jul 2014 18:23:09 +0300 Message-ID: <20140707152309.GH4939@tarshish> References: <1403091577-10232-1-git-send-email-harinik@xilinx.com> <5cc8b89b-20ff-4fa9-92dd-bb2f6d3512d8@BY2FFO11FD030.protection.gbl> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: Received: from guitar.tcltek.co.il ([192.115.133.116]:47561 "EHLO mx.tkos.co.il" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750859AbaGGPXQ (ORCPT ); Mon, 7 Jul 2014 11:23:16 -0400 Content-Disposition: inline In-Reply-To: Sender: linux-gpio-owner@vger.kernel.org List-Id: linux-gpio@vger.kernel.org To: Linus Walleij Cc: =?iso-8859-1?Q?S=F6ren?= Brinkmann , Mark Rutland , Alexandre Courbot , Harini Katakam , Pawel Moll , "ijc+devicetree@hellion.org.uk" , "linux-doc@vger.kernel.org" , Michal Simek , Harini Katakam , "linux-kernel@vger.kernel.org" , "linux-gpio@vger.kernel.org" , "devicetree@vger.kernel.org" , Rob Herring , Rob Landley , Kumar Gala , Grant Likely , Harini Katakam , "linux-arm-kernel@lists.infradead.org" Hi Linux, On Mon, Jul 07, 2014 at 04:51:56PM +0200, Linus Walleij wrote: > On Wed, Jun 18, 2014 at 5:36 PM, S=F6ren Brinkmann wrote: > > The first is, how is userspace supposed to find the correct offset = for a > > GPIO pin. >=20 > The sysfs interface to GPIO is *NOT* *GOOD* this is universally > agreed upon. >=20 > This needs someone to step in and provide a replacement, my preferred > mechanism would be a /dev/gpiochip0/... hierarchy using char devices. I really like the ability to control GPIOs from shell, both interactive= ly and=20 scripted. I find it useful for quick hardware level debugging, and for = boot=20 time scripting (mainly in initramfs). Do you intend to preserve this=20 capability in the future? Will I need a special utility (or Busybox app= let) to=20 do this with char device ioctl? baruch --=20 http://baruch.siach.name/blog/ ~. .~ Tk Open Sy= stems =3D}------------------------------------------------ooO--U--Ooo--------= ----{=3D - baruch@tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il - -- To unsubscribe from this list: send the line "unsubscribe linux-gpio" i= n the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html From mboxrd@z Thu Jan 1 00:00:00 1970 From: baruch@tkos.co.il (Baruch Siach) Date: Mon, 7 Jul 2014 18:23:09 +0300 Subject: [PATCH v2 1/2] gpio: Add driver for Zynq GPIO controller In-Reply-To: References: <1403091577-10232-1-git-send-email-harinik@xilinx.com> <5cc8b89b-20ff-4fa9-92dd-bb2f6d3512d8@BY2FFO11FD030.protection.gbl> Message-ID: <20140707152309.GH4939@tarshish> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Hi Linux, On Mon, Jul 07, 2014 at 04:51:56PM +0200, Linus Walleij wrote: > On Wed, Jun 18, 2014 at 5:36 PM, S?ren Brinkmann wrote: > > The first is, how is userspace supposed to find the correct offset for a > > GPIO pin. > > The sysfs interface to GPIO is *NOT* *GOOD* this is universally > agreed upon. > > This needs someone to step in and provide a replacement, my preferred > mechanism would be a /dev/gpiochip0/... hierarchy using char devices. I really like the ability to control GPIOs from shell, both interactively and scripted. I find it useful for quick hardware level debugging, and for boot time scripting (mainly in initramfs). Do you intend to preserve this capability in the future? Will I need a special utility (or Busybox applet) to do this with char device ioctl? baruch -- http://baruch.siach.name/blog/ ~. .~ Tk Open Systems =}------------------------------------------------ooO--U--Ooo------------{= - baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il - From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752593AbaGGPXV (ORCPT ); Mon, 7 Jul 2014 11:23:21 -0400 Received: from guitar.tcltek.co.il ([192.115.133.116]:47561 "EHLO mx.tkos.co.il" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750859AbaGGPXQ (ORCPT ); Mon, 7 Jul 2014 11:23:16 -0400 Date: Mon, 7 Jul 2014 18:23:09 +0300 From: Baruch Siach To: Linus Walleij Cc: =?iso-8859-1?Q?S=F6ren?= Brinkmann , Mark Rutland , Alexandre Courbot , Harini Katakam , Pawel Moll , "ijc+devicetree@hellion.org.uk" , "linux-doc@vger.kernel.org" , Michal Simek , Harini Katakam , "linux-kernel@vger.kernel.org" , "linux-gpio@vger.kernel.org" , "devicetree@vger.kernel.org" , Rob Herring , Rob Landley , Kumar Gala , Grant Likely , Harini Katakam , "linux-arm-kernel@lists.infradead.org" Subject: Re: [PATCH v2 1/2] gpio: Add driver for Zynq GPIO controller Message-ID: <20140707152309.GH4939@tarshish> References: <1403091577-10232-1-git-send-email-harinik@xilinx.com> <5cc8b89b-20ff-4fa9-92dd-bb2f6d3512d8@BY2FFO11FD030.protection.gbl> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Linux, On Mon, Jul 07, 2014 at 04:51:56PM +0200, Linus Walleij wrote: > On Wed, Jun 18, 2014 at 5:36 PM, Sören Brinkmann wrote: > > The first is, how is userspace supposed to find the correct offset for a > > GPIO pin. > > The sysfs interface to GPIO is *NOT* *GOOD* this is universally > agreed upon. > > This needs someone to step in and provide a replacement, my preferred > mechanism would be a /dev/gpiochip0/... hierarchy using char devices. I really like the ability to control GPIOs from shell, both interactively and scripted. I find it useful for quick hardware level debugging, and for boot time scripting (mainly in initramfs). Do you intend to preserve this capability in the future? Will I need a special utility (or Busybox applet) to do this with char device ioctl? baruch -- http://baruch.siach.name/blog/ ~. .~ Tk Open Systems =}------------------------------------------------ooO--U--Ooo------------{= - baruch@tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -