Linux-ARM-MSM Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH 1/2] arm64: dts: msm8916-longcheer-l8150: Enable WCNSS for WiFi and BT
@ 2019-10-12 14:58 nikitos.tr
  2019-10-12 14:58 ` [PATCH 2/2] arm64: dts: msm8916-longcheer-l8150: Add Volume buttons nikitos.tr
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: nikitos.tr @ 2019-10-12 14:58 UTC (permalink / raw)
  To: agross, bjorn.andersson
  Cc: robh+dt, mark.rutland, linux-arm-msm, devicetree, linux-kernel,
	stephan, Nikita Travkin

From: Nikita Travkin <nikitos.tr@gmail.com>

WCNSS is used on L8150 for WiFi and BT.
Its firmware isn't relocatable and must be loaded at specific address.

Signed-off-by: Nikita Travkin <nikitos.tr@gmail.com>
---
 .../boot/dts/qcom/msm8916-longcheer-l8150.dts      | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
index 2b28e383fd0b..e4d467e7dedb 100644
--- a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
+++ b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
@@ -18,6 +18,16 @@
 		stdout-path = "serial0";
 	};
 
+	reserved-memory {
+		// wcnss.mdt is not relocatable, so it must be loaded at 0x8b600000
+		/delete-node/ wcnss@89300000;
+
+		wcnss_mem: wcnss@8b600000 {
+			reg = <0x0 0x8b600000 0x0 0x600000>;
+			no-map;
+		};
+	};
+
 	soc {
 		sdhci@7824000 {
 			status = "okay";
@@ -68,6 +78,10 @@
 			};
 		};
 
+		wcnss@a21b000 {
+			status = "okay";
+		};
+
 		/*
 		 * Attempting to enable these devices causes a "synchronous
 		 * external abort". Suspected cause is that the debug power
-- 
2.19.1


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

* [PATCH 2/2] arm64: dts: msm8916-longcheer-l8150: Add Volume buttons
  2019-10-12 14:58 [PATCH 1/2] arm64: dts: msm8916-longcheer-l8150: Enable WCNSS for WiFi and BT nikitos.tr
@ 2019-10-12 14:58 ` nikitos.tr
  2019-10-12 15:10   ` Stephan Gerhold
  2019-10-12 15:08 ` [PATCH 1/2] arm64: dts: msm8916-longcheer-l8150: Enable WCNSS for WiFi and BT Stephan Gerhold
  2019-10-15  6:27 ` Bjorn Andersson
  2 siblings, 1 reply; 5+ messages in thread
From: nikitos.tr @ 2019-10-12 14:58 UTC (permalink / raw)
  To: agross, bjorn.andersson
  Cc: robh+dt, mark.rutland, linux-arm-msm, devicetree, linux-kernel,
	stephan, Nikita Travkin

From: Nikita Travkin <nikitos.tr@gmail.com>

Add nodes for Volume UP button connected to GPIO and Volume DOWN button,
which is handled by the pm8916 as is common with msm8916 devices.

Signed-off-by: Nikita Travkin <nikitos.tr@gmail.com>
---
 .../boot/dts/qcom/msm8916-longcheer-l8150.dts | 41 +++++++++++++++++++
 1 file changed, 41 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
index e4d467e7dedb..d1ccb9472c8b 100644
--- a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
+++ b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
@@ -5,6 +5,7 @@
 #include "msm8916.dtsi"
 #include "pm8916.dtsi"
 #include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
 
 / {
 	model = "Longcheer L8150";
@@ -113,9 +114,36 @@
 		pinctrl-names = "default";
 		pinctrl-0 = <&usb_vbus_default>;
 	};
+
+	gpio-keys {
+		compatible = "gpio-keys";
+
+		pinctrl-names = "default";
+		pinctrl-0 = <&gpio_keys_default>;
+
+		label = "GPIO Buttons";
+
+		volume-up {
+			label = "Volume Up";
+			gpios = <&msmgpio 107 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_VOLUMEUP>;
+		};
+	};
 };
 
 &msmgpio {
+	gpio_keys_default: gpio_keys_default {
+		pinmux {
+			function = "gpio";
+			pins = "gpio107";
+		};
+		pinconf {
+			pins = "gpio107";
+			drive-strength = <2>;
+			bias-pull-up;
+		};
+	};
+
 	usb_vbus_default: usb-vbus-default {
 		pinmux {
 			function = "gpio";
@@ -128,6 +156,19 @@
 	};
 };
 
+&spmi_bus {
+	pm8916@0 {
+		pon@800 {
+			volume-down {
+				compatible = "qcom,pm8941-resin";
+				interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
+				bias-pull-up;
+				linux,code = <KEY_VOLUMEDOWN>;
+			};
+		};
+	};
+};
+
 &smd_rpm_regulators {
 	vdd_l1_l2_l3-supply = <&pm8916_s3>;
 	vdd_l4_l5_l6-supply = <&pm8916_s4>;
-- 
2.19.1


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

* Re: [PATCH 1/2] arm64: dts: msm8916-longcheer-l8150: Enable WCNSS for WiFi and BT
  2019-10-12 14:58 [PATCH 1/2] arm64: dts: msm8916-longcheer-l8150: Enable WCNSS for WiFi and BT nikitos.tr
  2019-10-12 14:58 ` [PATCH 2/2] arm64: dts: msm8916-longcheer-l8150: Add Volume buttons nikitos.tr
@ 2019-10-12 15:08 ` Stephan Gerhold
  2019-10-15  6:27 ` Bjorn Andersson
  2 siblings, 0 replies; 5+ messages in thread
From: Stephan Gerhold @ 2019-10-12 15:08 UTC (permalink / raw)
  To: nikitos.tr
  Cc: agross, bjorn.andersson, robh+dt, mark.rutland, linux-arm-msm,
	devicetree, linux-kernel

On Sat, Oct 12, 2019 at 07:58:20PM +0500, nikitos.tr@gmail.com wrote:
> From: Nikita Travkin <nikitos.tr@gmail.com>
> 
> WCNSS is used on L8150 for WiFi and BT.
> Its firmware isn't relocatable and must be loaded at specific address.
> 
> Signed-off-by: Nikita Travkin <nikitos.tr@gmail.com>

Reviewed-by: Stephan Gerhold <stephan@gerhold.net>

> ---
>  .../boot/dts/qcom/msm8916-longcheer-l8150.dts      | 14 ++++++++++++++
>  1 file changed, 14 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
> index 2b28e383fd0b..e4d467e7dedb 100644
> --- a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
> +++ b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
> @@ -18,6 +18,16 @@
>  		stdout-path = "serial0";
>  	};
>  
> +	reserved-memory {
> +		// wcnss.mdt is not relocatable, so it must be loaded at 0x8b600000
> +		/delete-node/ wcnss@89300000;
> +
> +		wcnss_mem: wcnss@8b600000 {
> +			reg = <0x0 0x8b600000 0x0 0x600000>;
> +			no-map;
> +		};
> +	};
> +
>  	soc {
>  		sdhci@7824000 {
>  			status = "okay";
> @@ -68,6 +78,10 @@
>  			};
>  		};
>  
> +		wcnss@a21b000 {
> +			status = "okay";
> +		};
> +
>  		/*
>  		 * Attempting to enable these devices causes a "synchronous
>  		 * external abort". Suspected cause is that the debug power
> -- 
> 2.19.1
> 

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

* Re: [PATCH 2/2] arm64: dts: msm8916-longcheer-l8150: Add Volume buttons
  2019-10-12 14:58 ` [PATCH 2/2] arm64: dts: msm8916-longcheer-l8150: Add Volume buttons nikitos.tr
@ 2019-10-12 15:10   ` Stephan Gerhold
  0 siblings, 0 replies; 5+ messages in thread
From: Stephan Gerhold @ 2019-10-12 15:10 UTC (permalink / raw)
  To: nikitos.tr
  Cc: agross, bjorn.andersson, robh+dt, mark.rutland, linux-arm-msm,
	devicetree, linux-kernel

On Sat, Oct 12, 2019 at 07:58:21PM +0500, nikitos.tr@gmail.com wrote:
> From: Nikita Travkin <nikitos.tr@gmail.com>
> 
> Add nodes for Volume UP button connected to GPIO and Volume DOWN button,
> which is handled by the pm8916 as is common with msm8916 devices.
> 
> Signed-off-by: Nikita Travkin <nikitos.tr@gmail.com>

Reviewed-by: Stephan Gerhold <stephan@gerhold.net>

> ---
>  .../boot/dts/qcom/msm8916-longcheer-l8150.dts | 41 +++++++++++++++++++
>  1 file changed, 41 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
> index e4d467e7dedb..d1ccb9472c8b 100644
> --- a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
> +++ b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
> @@ -5,6 +5,7 @@
>  #include "msm8916.dtsi"
>  #include "pm8916.dtsi"
>  #include <dt-bindings/gpio/gpio.h>
> +#include <dt-bindings/input/input.h>
>  
>  / {
>  	model = "Longcheer L8150";
> @@ -113,9 +114,36 @@
>  		pinctrl-names = "default";
>  		pinctrl-0 = <&usb_vbus_default>;
>  	};
> +
> +	gpio-keys {
> +		compatible = "gpio-keys";
> +
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&gpio_keys_default>;
> +
> +		label = "GPIO Buttons";
> +
> +		volume-up {
> +			label = "Volume Up";
> +			gpios = <&msmgpio 107 GPIO_ACTIVE_LOW>;
> +			linux,code = <KEY_VOLUMEUP>;
> +		};
> +	};
>  };
>  
>  &msmgpio {
> +	gpio_keys_default: gpio_keys_default {
> +		pinmux {
> +			function = "gpio";
> +			pins = "gpio107";
> +		};
> +		pinconf {
> +			pins = "gpio107";
> +			drive-strength = <2>;
> +			bias-pull-up;
> +		};
> +	};
> +
>  	usb_vbus_default: usb-vbus-default {
>  		pinmux {
>  			function = "gpio";
> @@ -128,6 +156,19 @@
>  	};
>  };
>  
> +&spmi_bus {
> +	pm8916@0 {
> +		pon@800 {
> +			volume-down {
> +				compatible = "qcom,pm8941-resin";
> +				interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
> +				bias-pull-up;
> +				linux,code = <KEY_VOLUMEDOWN>;
> +			};
> +		};
> +	};
> +};
> +
>  &smd_rpm_regulators {
>  	vdd_l1_l2_l3-supply = <&pm8916_s3>;
>  	vdd_l4_l5_l6-supply = <&pm8916_s4>;
> -- 
> 2.19.1
> 

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

* Re: [PATCH 1/2] arm64: dts: msm8916-longcheer-l8150: Enable WCNSS for WiFi and BT
  2019-10-12 14:58 [PATCH 1/2] arm64: dts: msm8916-longcheer-l8150: Enable WCNSS for WiFi and BT nikitos.tr
  2019-10-12 14:58 ` [PATCH 2/2] arm64: dts: msm8916-longcheer-l8150: Add Volume buttons nikitos.tr
  2019-10-12 15:08 ` [PATCH 1/2] arm64: dts: msm8916-longcheer-l8150: Enable WCNSS for WiFi and BT Stephan Gerhold
@ 2019-10-15  6:27 ` Bjorn Andersson
  2 siblings, 0 replies; 5+ messages in thread
From: Bjorn Andersson @ 2019-10-15  6:27 UTC (permalink / raw)
  To: nikitos.tr
  Cc: agross, robh+dt, mark.rutland, linux-arm-msm, devicetree,
	linux-kernel, stephan

On Sat 12 Oct 07:58 PDT 2019, nikitos.tr@gmail.com wrote:

> From: Nikita Travkin <nikitos.tr@gmail.com>
> 
> WCNSS is used on L8150 for WiFi and BT.
> Its firmware isn't relocatable and must be loaded at specific address.
> 
> Signed-off-by: Nikita Travkin <nikitos.tr@gmail.com>

Both patches applied

Thank you,
Bjorn

> ---
>  .../boot/dts/qcom/msm8916-longcheer-l8150.dts      | 14 ++++++++++++++
>  1 file changed, 14 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
> index 2b28e383fd0b..e4d467e7dedb 100644
> --- a/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
> +++ b/arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dts
> @@ -18,6 +18,16 @@
>  		stdout-path = "serial0";
>  	};
>  
> +	reserved-memory {
> +		// wcnss.mdt is not relocatable, so it must be loaded at 0x8b600000
> +		/delete-node/ wcnss@89300000;
> +
> +		wcnss_mem: wcnss@8b600000 {
> +			reg = <0x0 0x8b600000 0x0 0x600000>;
> +			no-map;
> +		};
> +	};
> +
>  	soc {
>  		sdhci@7824000 {
>  			status = "okay";
> @@ -68,6 +78,10 @@
>  			};
>  		};
>  
> +		wcnss@a21b000 {
> +			status = "okay";
> +		};
> +
>  		/*
>  		 * Attempting to enable these devices causes a "synchronous
>  		 * external abort". Suspected cause is that the debug power
> -- 
> 2.19.1
> 

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

end of thread, back to index

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-12 14:58 [PATCH 1/2] arm64: dts: msm8916-longcheer-l8150: Enable WCNSS for WiFi and BT nikitos.tr
2019-10-12 14:58 ` [PATCH 2/2] arm64: dts: msm8916-longcheer-l8150: Add Volume buttons nikitos.tr
2019-10-12 15:10   ` Stephan Gerhold
2019-10-12 15:08 ` [PATCH 1/2] arm64: dts: msm8916-longcheer-l8150: Enable WCNSS for WiFi and BT Stephan Gerhold
2019-10-15  6:27 ` Bjorn Andersson

Linux-ARM-MSM Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-arm-msm/0 linux-arm-msm/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-arm-msm linux-arm-msm/ https://lore.kernel.org/linux-arm-msm \
		linux-arm-msm@vger.kernel.org
	public-inbox-index linux-arm-msm

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-arm-msm


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git