2021-01-12 12:35:10

by Martin Kepplinger

[permalink] [raw]
Subject: [PATCH 0/9] Config and devicetree updates for the Librem 5 phone

This is another set of updates in order to maintain support for the
Librem 5 phone:

Guido Günther (5):
arm64: defconfig: Enable vibra-pwm
arm64: dts: imx8mq-librem5: Mark charger IRQ as High-Z
arm64: dts: imx8mq-librem5: Don't mark buck3 as always on
arm64: dts: imx8mq-librem5: Add usb-c chip as supplier for the charger
arm64: dts: imx8mq-librem5: Add LCD_1V8 regulator

Martin Kepplinger (4):
arm64: dts: imx8mq-librem5: enable the LCD panel
arm64: dts: imx8mq-librem5: set regulators boot-on
arm64: dts: Add Librem5 Evergreen
dt-bindings: arm: fsl: Add the librem 5 Evergreen revision

.../devicetree/bindings/arm/fsl.yaml | 1 +
arch/arm64/boot/dts/freescale/Makefile | 1 +
.../boot/dts/freescale/imx8mq-librem5-r4.dts | 35 ++++++++
.../boot/dts/freescale/imx8mq-librem5.dtsi | 83 ++++++++++++++++++-
arch/arm64/configs/defconfig | 1 +
5 files changed, 117 insertions(+), 4 deletions(-)
create mode 100644 arch/arm64/boot/dts/freescale/imx8mq-librem5-r4.dts

--
2.20.1


2021-01-13 01:28:58

by Martin Kepplinger

[permalink] [raw]
Subject: [PATCH 8/9] arm64: dts: Add Librem5 Evergreen

Add librem5-r4 with specifics to that revision like the near-level,
battery and charger properties. For schematics and more information,
see https://developer.puri.sm/Librem5/Hardware_Reference/Evergreen.html

Signed-off-by: Martin Kepplinger <[email protected]>
---
arch/arm64/boot/dts/freescale/Makefile | 1 +
.../boot/dts/freescale/imx8mq-librem5-r4.dts | 35 +++++++++++++++++++
2 files changed, 36 insertions(+)
create mode 100644 arch/arm64/boot/dts/freescale/imx8mq-librem5-r4.dts

diff --git a/arch/arm64/boot/dts/freescale/Makefile b/arch/arm64/boot/dts/freescale/Makefile
index 38559943c15d..e814ee98fecf 100644
--- a/arch/arm64/boot/dts/freescale/Makefile
+++ b/arch/arm64/boot/dts/freescale/Makefile
@@ -48,6 +48,7 @@ dtb-$(CONFIG_ARCH_MXC) += imx8mq-hummingboard-pulse.dtb
dtb-$(CONFIG_ARCH_MXC) += imx8mq-librem5-devkit.dtb
dtb-$(CONFIG_ARCH_MXC) += imx8mq-librem5-r2.dtb
dtb-$(CONFIG_ARCH_MXC) += imx8mq-librem5-r3.dtb
+dtb-$(CONFIG_ARCH_MXC) += imx8mq-librem5-r4.dtb
dtb-$(CONFIG_ARCH_MXC) += imx8mq-nitrogen.dtb
dtb-$(CONFIG_ARCH_MXC) += imx8mq-phanbell.dtb
dtb-$(CONFIG_ARCH_MXC) += imx8mq-pico-pi.dtb
diff --git a/arch/arm64/boot/dts/freescale/imx8mq-librem5-r4.dts b/arch/arm64/boot/dts/freescale/imx8mq-librem5-r4.dts
new file mode 100644
index 000000000000..cbfb49aa2563
--- /dev/null
+++ b/arch/arm64/boot/dts/freescale/imx8mq-librem5-r4.dts
@@ -0,0 +1,35 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+// Copyright (C) 2020 Purism SPC <[email protected]>
+
+/dts-v1/;
+
+#include "imx8mq-librem5.dtsi"
+
+/ {
+ model = "Purism Librem 5r4";
+ compatible = "purism,librem5r4", "purism,librem5", "fsl,imx8mq";
+};
+
+&accel_gyro {
+ mount-matrix = "1", "0", "0",
+ "0", "1", "0",
+ "0", "0", "-1";
+};
+
+&bat {
+ maxim,rsns-microohm = <1667>;
+};
+
+&bq25895 {
+ ti,battery-regulation-voltage = <4200000>; /* uV */
+ ti,charge-current = <1500000>; /* uA */
+ ti,termination-current = <144000>; /* uA */
+};
+
+&led_backlight {
+ led-max-microamp = <25000>;
+};
+
+&proximity {
+ proximity-near-level = <10>;
+};
--
2.20.1

2021-01-13 01:29:05

by Martin Kepplinger

[permalink] [raw]
Subject: [PATCH 9/9] dt-bindings: arm: fsl: Add the librem 5 Evergreen revision

Add an entry for the Librem 5 phone, Evergreen revision which is supported
by "r4". Schematics and more information can be found at
https://developer.puri.sm/Librem5/Hardware_Reference/Evergreen.html

Signed-off-by: Martin Kepplinger <[email protected]>
---
Documentation/devicetree/bindings/arm/fsl.yaml | 1 +
1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/arm/fsl.yaml b/Documentation/devicetree/bindings/arm/fsl.yaml
index 34000f7fbe02..5921ccf218d9 100644
--- a/Documentation/devicetree/bindings/arm/fsl.yaml
+++ b/Documentation/devicetree/bindings/arm/fsl.yaml
@@ -724,6 +724,7 @@ properties:
- enum:
- purism,librem5r2 # Purism Librem5 phone "Chestnut"
- purism,librem5r3 # Purism Librem5 phone "Dogwood"
+ - purism,librem5r4 # Purism Librem5 phone "Evergreen"
- const: purism,librem5
- const: fsl,imx8mq

--
2.20.1

2021-01-13 04:23:39

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH 8/9] arm64: dts: Add Librem5 Evergreen

On Tue, Jan 12, 2021 at 10:51:50AM +0100, Martin Kepplinger wrote:
> Add librem5-r4 with specifics to that revision like the near-level,
> battery and charger properties. For schematics and more information,
> see https://developer.puri.sm/Librem5/Hardware_Reference/Evergreen.html
>
> Signed-off-by: Martin Kepplinger <[email protected]>
> ---
> arch/arm64/boot/dts/freescale/Makefile | 1 +
> .../boot/dts/freescale/imx8mq-librem5-r4.dts | 35 +++++++++++++++++++
> 2 files changed, 36 insertions(+)
> create mode 100644 arch/arm64/boot/dts/freescale/imx8mq-librem5-r4.dts
>

The bindings go before DTS change using them.

Reviewed-by: Krzysztof Kozlowski <[email protected]>

Best regards,
Krzysztof

2021-01-13 04:25:52

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH 9/9] dt-bindings: arm: fsl: Add the librem 5 Evergreen revision

On Tue, Jan 12, 2021 at 10:51:51AM +0100, Martin Kepplinger wrote:
> Add an entry for the Librem 5 phone, Evergreen revision which is supported
> by "r4". Schematics and more information can be found at
> https://developer.puri.sm/Librem5/Hardware_Reference/Evergreen.html
>
> Signed-off-by: Martin Kepplinger <[email protected]>
> ---
> Documentation/devicetree/bindings/arm/fsl.yaml | 1 +
> 1 file changed, 1 insertion(+)
>

Reviewed-by: Krzysztof Kozlowski <[email protected]>

Best regards,
Krzysztof

2021-01-14 20:19:34

by Rob Herring (Arm)

[permalink] [raw]
Subject: Re: [PATCH 9/9] dt-bindings: arm: fsl: Add the librem 5 Evergreen revision

On Tue, 12 Jan 2021 10:51:51 +0100, Martin Kepplinger wrote:
> Add an entry for the Librem 5 phone, Evergreen revision which is supported
> by "r4". Schematics and more information can be found at
> https://developer.puri.sm/Librem5/Hardware_Reference/Evergreen.html
>
> Signed-off-by: Martin Kepplinger <[email protected]>
> ---
> Documentation/devicetree/bindings/arm/fsl.yaml | 1 +
> 1 file changed, 1 insertion(+)
>

Acked-by: Rob Herring <[email protected]>