From mboxrd@z Thu Jan 1 00:00:00 1970 From: Linus Walleij Subject: Re: [PATCH] arm: dts: sun7i-a20-bananapi: name the GPIO lines Date: Mon, 25 Jul 2016 15:27:55 +0200 Message-ID: References: <1468496825-4896-1-git-send-email-linux@rempel-privat.de> <5795A334.3000701@de.bosch.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Return-path: In-Reply-To: <5795A334.3000701-V5te9oGctAVWk0Htik3J/w@public.gmane.org> Sender: devicetree-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: "fixed-term.Oleksij.Rempel" Cc: Chen-Yu Tsai , Oleksij Rempel , "devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" , "linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org" List-Id: devicetree@vger.kernel.org On Mon, Jul 25, 2016 at 7:27 AM, fixed-term.Oleksij.Rempel wrote: > On 22.07.2016 17:47, Chen-Yu Tsai wrote: >> On Fri, Jul 22, 2016 at 10:55 PM, Linus Walleij >> wrote: >>> "LED1" seems like the right name, if this is a GPIO used to drive >>> a LED. >> >> This is GPIO based. > > This was not clear to me, marking GPIO pin as peripheral, at moment of > writing and testing it was a allocated by led driver. Bit for example > IO-GCLK was free to use for GPIO :).. so do [] actually make sense? I would say if the hardware is used in GPIO mode, i.e. if the hardware registers of the GPIO block is written to activate the LED, then it is "LED1". If there would be a specific LED driver block that disables the GPIO block to be used for the same lines and have its registers elsewhere, it would be "[LED1]". So proper names "FOO" is for the case where the GPIO output is used as GPIO. Yours, Linus Walleij -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html From mboxrd@z Thu Jan 1 00:00:00 1970 From: linus.walleij@linaro.org (Linus Walleij) Date: Mon, 25 Jul 2016 15:27:55 +0200 Subject: [PATCH] arm: dts: sun7i-a20-bananapi: name the GPIO lines In-Reply-To: <5795A334.3000701@de.bosch.com> References: <1468496825-4896-1-git-send-email-linux@rempel-privat.de> <5795A334.3000701@de.bosch.com> Message-ID: To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On Mon, Jul 25, 2016 at 7:27 AM, fixed-term.Oleksij.Rempel wrote: > On 22.07.2016 17:47, Chen-Yu Tsai wrote: >> On Fri, Jul 22, 2016 at 10:55 PM, Linus Walleij >> wrote: >>> "LED1" seems like the right name, if this is a GPIO used to drive >>> a LED. >> >> This is GPIO based. > > This was not clear to me, marking GPIO pin as peripheral, at moment of > writing and testing it was a allocated by led driver. Bit for example > IO-GCLK was free to use for GPIO :).. so do [] actually make sense? I would say if the hardware is used in GPIO mode, i.e. if the hardware registers of the GPIO block is written to activate the LED, then it is "LED1". If there would be a specific LED driver block that disables the GPIO block to be used for the same lines and have its registers elsewhere, it would be "[LED1]". So proper names "FOO" is for the case where the GPIO output is used as GPIO. Yours, Linus Walleij