linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3] ARM: da850: Fix LEGO EV3 battery voltage gpio
@ 2017-12-03 22:04 David Lechner
  2017-12-07  7:35 ` Sekhar Nori
  0 siblings, 1 reply; 3+ messages in thread
From: David Lechner @ 2017-12-03 22:04 UTC (permalink / raw)
  To: linux-arm-kernel; +Cc: David Lechner, Sekhar Nori, linux-kernel

This fixes the battery voltage monitoring gpio-hog settings.

When the gpio is low, it turns off the battery voltage to the ADC chip.
However, this needs to be on all of the time so that we can monitor
battery voltage.

Also, there was a typo that prevented pinmuxing from working correctly.

Signed-off-by: David Lechner <david@lechnology.com>
---

v3 changes:
* Rebased patch so that it applies cleanly to mainline

v2 changes:
* Fixed pinctrl typo

 arch/arm/boot/dts/da850-lego-ev3.dts | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/da850-lego-ev3.dts b/arch/arm/boot/dts/da850-lego-ev3.dts
index 413dbd5..81942ae 100644
--- a/arch/arm/boot/dts/da850-lego-ev3.dts
+++ b/arch/arm/boot/dts/da850-lego-ev3.dts
@@ -178,7 +178,7 @@
 	 */
 	battery {
 		pinctrl-names = "default";
-		pintctrl-0 = <&battery_pins>;
+		pinctrl-0 = <&battery_pins>;
 		compatible = "lego,ev3-battery";
 		io-channels = <&adc 4>, <&adc 3>;
 		io-channel-names = "voltage", "current";
@@ -392,7 +392,7 @@
 	batt_volt_en {
 		gpio-hog;
 		gpios = <6 GPIO_ACTIVE_HIGH>;
-		output-low;
+		output-high;
 	};
 };
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH v3] ARM: da850: Fix LEGO EV3 battery voltage gpio
  2017-12-03 22:04 [PATCH v3] ARM: da850: Fix LEGO EV3 battery voltage gpio David Lechner
@ 2017-12-07  7:35 ` Sekhar Nori
  2017-12-07 17:15   ` David Lechner
  0 siblings, 1 reply; 3+ messages in thread
From: Sekhar Nori @ 2017-12-07  7:35 UTC (permalink / raw)
  To: David Lechner, linux-arm-kernel; +Cc: linux-kernel

On Monday 04 December 2017 03:34 AM, David Lechner wrote:
> This fixes the battery voltage monitoring gpio-hog settings.
> 
> When the gpio is low, it turns off the battery voltage to the ADC chip.
> However, this needs to be on all of the time so that we can monitor
> battery voltage.
> 
> Also, there was a typo that prevented pinmuxing from working correctly.
> 
> Signed-off-by: David Lechner <david@lechnology.com>

Applied to fixes with subject line changed to:

ARM: dts: da850-lego-ev3: Fix battery voltage gpio

Please follow this style for future patches.

Thanks,
Sekhar

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH v3] ARM: da850: Fix LEGO EV3 battery voltage gpio
  2017-12-07  7:35 ` Sekhar Nori
@ 2017-12-07 17:15   ` David Lechner
  0 siblings, 0 replies; 3+ messages in thread
From: David Lechner @ 2017-12-07 17:15 UTC (permalink / raw)
  To: Sekhar Nori, linux-arm-kernel; +Cc: linux-kernel

On 12/07/2017 01:35 AM, Sekhar Nori wrote:
> On Monday 04 December 2017 03:34 AM, David Lechner wrote:
>> This fixes the battery voltage monitoring gpio-hog settings.
>>
>> When the gpio is low, it turns off the battery voltage to the ADC chip.
>> However, this needs to be on all of the time so that we can monitor
>> battery voltage.
>>
>> Also, there was a typo that prevented pinmuxing from working correctly.
>>
>> Signed-off-by: David Lechner <david@lechnology.com>
> 
> Applied to fixes with subject line changed to:
> 
> ARM: dts: da850-lego-ev3: Fix battery voltage gpio
> 
> Please follow this style for future patches.

Ack

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-12-07 17:14 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-12-03 22:04 [PATCH v3] ARM: da850: Fix LEGO EV3 battery voltage gpio David Lechner
2017-12-07  7:35 ` Sekhar Nori
2017-12-07 17:15   ` David Lechner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).