Devicetree
 help / color / mirror / Atom feed
* [PATCH v3 1/3] arm64: dts: qcom: eliza: Sort nodes by unit address
From: Alexander Koskovich @ 2026-04-18 10:39 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Bjorn Andersson,
	Konrad Dybcio
  Cc: devicetree, linux-kernel, linux-arm-msm, Alexander Koskovich,
	Krzysztof Kozlowski, Konrad Dybcio
In-Reply-To: <20260418-eliza-imem-v3-0-bfbd499b6e77@pm.me>

Qualcomm DTS uses sorting of MMIO nodes by the unit address, so move
few nodes in Eliza DTSI to fix that.

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Signed-off-by: Alexander Koskovich <akoskovich@pm.me>
---
 arch/arm64/boot/dts/qcom/eliza.dtsi | 74 ++++++++++++++++++-------------------
 1 file changed, 37 insertions(+), 37 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/eliza.dtsi b/arch/arm64/boot/dts/qcom/eliza.dtsi
index 4a7a0ac40ce6..6fa5679c1a62 100644
--- a/arch/arm64/boot/dts/qcom/eliza.dtsi
+++ b/arch/arm64/boot/dts/qcom/eliza.dtsi
@@ -662,16 +662,16 @@ &clk_virt SLAVE_QUP_CORE_2 QCOM_ICC_TAG_ALWAYS>,
 			};
 		};
 
-		config_noc: interconnect@1600000 {
-			compatible = "qcom,eliza-cnoc-cfg";
-			reg = <0x0 0x01600000 0x0 0x5200>;
+		cnoc_main: interconnect@1500000 {
+			compatible = "qcom,eliza-cnoc-main";
+			reg = <0x0 0x01500000 0x0 0x16080>;
 			qcom,bcm-voters = <&apps_bcm_voter>;
 			#interconnect-cells = <2>;
 		};
 
-		cnoc_main: interconnect@1500000 {
-			compatible = "qcom,eliza-cnoc-main";
-			reg = <0x0 0x01500000 0x0 0x16080>;
+		config_noc: interconnect@1600000 {
+			compatible = "qcom,eliza-cnoc-cfg";
+			reg = <0x0 0x01600000 0x0 0x5200>;
 			qcom,bcm-voters = <&apps_bcm_voter>;
 			#interconnect-cells = <2>;
 		};
@@ -862,13 +862,6 @@ tcsr: clock-controller@1fbf000 {
 			#reset-cells = <1>;
 		};
 
-		lpass_ag_noc: interconnect@7e40000 {
-			compatible = "qcom,eliza-lpass-ag-noc";
-			reg = <0x0 0x07e40000 0x0 0xe080>;
-			qcom,bcm-voters = <&apps_bcm_voter>;
-			#interconnect-cells = <2>;
-		};
-
 		lpass_lpiaon_noc: interconnect@7400000 {
 			compatible = "qcom,eliza-lpass-lpiaon-noc";
 			reg = <0x0 0x07400000 0x0 0x19080>;
@@ -883,6 +876,13 @@ lpass_lpicx_noc: interconnect@7420000 {
 			#interconnect-cells = <2>;
 		};
 
+		lpass_ag_noc: interconnect@7e40000 {
+			compatible = "qcom,eliza-lpass-ag-noc";
+			reg = <0x0 0x07e40000 0x0 0xe080>;
+			qcom,bcm-voters = <&apps_bcm_voter>;
+			#interconnect-cells = <2>;
+		};
+
 		pdc: interrupt-controller@b220000 {
 			compatible = "qcom,eliza-pdc", "qcom,pdc";
 			reg = <0x0 0x0b220000 0x0 0x40000>,
@@ -1005,6 +1005,30 @@ spmi_bus1: spmi@c432000 {
 			};
 		};
 
+		tlmm: pinctrl@f100000 {
+			compatible = "qcom,eliza-tlmm";
+			reg = <0x0 0x0f100000 0x0 0xf00000>;
+
+			interrupts = <GIC_SPI 208 IRQ_TYPE_LEVEL_HIGH>;
+
+			gpio-controller;
+			#gpio-cells = <2>;
+
+			interrupt-controller;
+			#interrupt-cells = <2>;
+
+			gpio-ranges = <&tlmm 0 0 184>;
+			wakeup-parent = <&pdc>;
+
+			qup_uart14_default: qup-uart14-default-state {
+				/* TX, RX */
+				pins = "gpio18", "gpio19";
+				function = "qup2_se5";
+				drive-strength = <2>;
+				bias-pull-up;
+			};
+		};
+
 		apps_smmu: iommu@15000000 {
 			compatible = "qcom,eliza-smmu-500", "qcom,smmu-500", "arm,mmu-500";
 			reg = <0x0 0x15000000 0x0 0x100000>;
@@ -1319,30 +1343,6 @@ cpufreq_hw: cpufreq@17d91000 {
 			#clock-cells = <1>;
 		};
 
-		tlmm: pinctrl@f100000 {
-			compatible = "qcom,eliza-tlmm";
-			reg = <0x0 0x0f100000 0x0 0xf00000>;
-
-			interrupts = <GIC_SPI 208 IRQ_TYPE_LEVEL_HIGH>;
-
-			gpio-controller;
-			#gpio-cells = <2>;
-
-			interrupt-controller;
-			#interrupt-cells = <2>;
-
-			gpio-ranges = <&tlmm 0 0 184>;
-			wakeup-parent = <&pdc>;
-
-			qup_uart14_default: qup-uart14-default-state {
-				/* TX, RX */
-				pins = "gpio18", "gpio19";
-				function = "qup2_se5";
-				drive-strength = <2>;
-				bias-pull-up;
-			};
-		};
-
 		gem_noc: interconnect@24100000 {
 			compatible = "qcom,eliza-gem-noc";
 			reg = <0x0 0x24100000 0x0 0x163080>;

-- 
2.53.0



^ permalink raw reply related

* [PATCH v3 2/3] dt-bindings: sram: Document qcom,eliza-imem
From: Alexander Koskovich @ 2026-04-18 10:39 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Bjorn Andersson,
	Konrad Dybcio
  Cc: devicetree, linux-kernel, linux-arm-msm, Alexander Koskovich,
	Krzysztof Kozlowski
In-Reply-To: <20260418-eliza-imem-v3-0-bfbd499b6e77@pm.me>

Add compatible for Eliza SoC IMEM.

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Signed-off-by: Alexander Koskovich <akoskovich@pm.me>
---
 Documentation/devicetree/bindings/sram/sram.yaml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/sram/sram.yaml b/Documentation/devicetree/bindings/sram/sram.yaml
index 8985f89170be..27e5e274c3cb 100644
--- a/Documentation/devicetree/bindings/sram/sram.yaml
+++ b/Documentation/devicetree/bindings/sram/sram.yaml
@@ -34,6 +34,7 @@ properties:
         - nvidia,tegra186-sysram
         - nvidia,tegra194-sysram
         - nvidia,tegra234-sysram
+        - qcom,eliza-imem
         - qcom,hawi-imem
         - qcom,kaanapali-imem
         - qcom,milos-imem

-- 
2.53.0



^ permalink raw reply related

* [PATCH v3 3/3] arm64: dts: qcom: eliza: Add IMEM node
From: Alexander Koskovich @ 2026-04-18 10:40 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Bjorn Andersson,
	Konrad Dybcio
  Cc: devicetree, linux-kernel, linux-arm-msm, Alexander Koskovich,
	Konrad Dybcio
In-Reply-To: <20260418-eliza-imem-v3-0-bfbd499b6e77@pm.me>

Add a node for the IMEM found on Eliza, which contains pil-reloc-info
and the modem tables for IPA, among others.

Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Signed-off-by: Alexander Koskovich <akoskovich@pm.me>
---
 arch/arm64/boot/dts/qcom/eliza.dtsi | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/eliza.dtsi b/arch/arm64/boot/dts/qcom/eliza.dtsi
index 6fa5679c1a62..a63e2cbe174e 100644
--- a/arch/arm64/boot/dts/qcom/eliza.dtsi
+++ b/arch/arm64/boot/dts/qcom/eliza.dtsi
@@ -1029,6 +1029,26 @@ qup_uart14_default: qup-uart14-default-state {
 			};
 		};
 
+		sram@14680000 {
+			compatible = "qcom,eliza-imem", "mmio-sram";
+			reg = <0x0 0x14680000 0x0 0x2c000>;
+			ranges = <0x0 0x0 0x14680000 0x2c000>;
+
+			no-memory-wc;
+
+			#address-cells = <1>;
+			#size-cells = <1>;
+
+			pil-reloc-sram@94c {
+				compatible = "qcom,pil-reloc-info";
+				reg = <0x94c 0xc8>;
+			};
+
+			ipa_modem_tables: modem-tables-sram@3000 {
+				reg = <0x3000 0x2000>;
+			};
+		};
+
 		apps_smmu: iommu@15000000 {
 			compatible = "qcom,eliza-smmu-500", "qcom,smmu-500", "arm,mmu-500";
 			reg = <0x0 0x15000000 0x0 0x100000>;

-- 
2.53.0



^ permalink raw reply related

* Re: [PATCH] arm: dts: allwinner: t113s mangopi: enable watchdog for reboot
From: Andre Przywara @ 2026-04-18 11:55 UTC (permalink / raw)
  To: Jernej Škrabec
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai,
	Samuel Holland, Michal Piekos, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel
In-Reply-To: <2825865.mvXUDI8C0e@jernej-laptop>

On Fri, 17 Apr 2026 20:19:20 +0200
Jernej Škrabec <jernej.skrabec@gmail.com> wrote:

> Hi,
> 
> Dne nedelja, 12. april 2026 ob 19:42:10 Srednjeevropski poletni čas je Michal Piekos napisal(a):
> > Reboot hangs on MangoPi MQ-R T113s because no restart handler is
> > available.
> > 
> > Enable the SoC watchdog whose driver registers a restart handler.
> > 
> > Tested on MangoPi MQ-R T113s.
> > 
> > Signed-off-by: Michal Piekos <michal.piekos@mmpsystems.pl>
> > ---
> >  arch/arm/boot/dts/allwinner/sun8i-t113s-mangopi-mq-r-t113.dts | 4 ++++
> >  1 file changed, 4 insertions(+)
> > 
> > diff --git a/arch/arm/boot/dts/allwinner/sun8i-t113s-mangopi-mq-r-t113.dts b/arch/arm/boot/dts/allwinner/sun8i-t113s-mangopi-mq-r-t113.dts
> > index 8b3a75383816..f0232a5e903b 100644
> > --- a/arch/arm/boot/dts/allwinner/sun8i-t113s-mangopi-mq-r-t113.dts
> > +++ b/arch/arm/boot/dts/allwinner/sun8i-t113s-mangopi-mq-r-t113.dts
> > @@ -33,3 +33,7 @@ rtl8189ftv: wifi@1 {
> >  		interrupt-names = "host-wake";
> >  	};
> >  };
> > +
> > +&wdt {
> > +	status = "okay";
> > +};  
> 
> Move this to sun8i-t113s.dtsi. All t113 boards have the same issue.
> Watchdog should be always enabled on ARM.

We actually have that line in U-Boot:
https://github.com/u-boot/u-boot/blob/master/arch/arm/dts/sunxi-u-boot.dtsi#L22-L27

IIRC, the idea was that it is *firmware* that chooses the watchdog, so
the generic DT should not be the place to set this.

If people use $fdtcontroladdr as the DT source, everything falls in
place neatly, no need for changes or runtime patching.

Cheers,
Andre

^ permalink raw reply

* [PATCH] of/fdt: remove redundant memset in __unflatten_device_tree()
From: Sang-Heon Jeon @ 2026-04-18 14:04 UTC (permalink / raw)
  To: robh, saravanak; +Cc: devicetree, Sang-Heon Jeon

All dt_alloc callbacks passed to __unflatten_device_tree() already
return zero-initialized memory.

- kernel_tree_alloc uses kzalloc()
- early_init_dt_alloc_memory_arch() and dt_alloc_memory() both use
  memblock_alloc()

So remove redundant memset after the allocation. No funtional change.

Signed-off-by: Sang-Heon Jeon <ekffu200098@gmail.com>
---
dt-test result

[    0.529540] ### dt-test ### start of unittest - you will see error messages
[    0.532758] ### dt-test ### EXPECT \ : Duplicate name in testcase-data, renamed to "duplicate-name#1"
[    0.537608] ### dt-test ### EXPECT / : Duplicate name in testcase-data, renamed to "duplicate-name#1"

...

[    0.781700] ### dt-test ### EXPECT / : OF: resolver: overlay phandle fixup failed: -22
[    0.781718] ### dt-test ### EXPECT / : OF: resolver: node label 'this_label_does_not_exist' not found in live devicetree symbols table
[    0.781945] ### dt-test ### end of unittest - 423 passed, 0 failed

---
Hello, 

While looking into boot information, I found a minor enhancement point.
If I misunderstood anything, please feel free to let me know.

Thank you for taking valuable time to review this work.

Best Regards,
Sang-Heon Jeon
---
 drivers/of/fdt.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c
index becc855ff8b5..647bff2c4521 100644
--- a/drivers/of/fdt.c
+++ b/drivers/of/fdt.c
@@ -391,8 +391,6 @@ void *__unflatten_device_tree(const void *blob,
 	if (!mem)
 		return NULL;
 
-	memset(mem, 0, size);
-
 	*(__be32 *)(mem + size) = cpu_to_be32(0xdeadbeef);
 
 	pr_debug("  unflattening %p...\n", mem);
-- 
2.43.0


^ permalink raw reply related

* [PATCH v1 0/5] Update APDS990x ALS to support device trees
From: Svyatoslav Ryhel @ 2026-04-18 14:47 UTC (permalink / raw)
  To: Jonathan Cameron, David Lechner, Nuno Sá, Andy Shevchenko,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Arnd Bergmann,
	Greg Kroah-Hartman, Svyatoslav Ryhel, Randy Dunlap
  Cc: linux-iio, devicetree, linux-kernel

Document Avago APDS9900/9901 ALS/Proximity sensor in schema and modernize
its driver to support OF bindings.

Svyatoslav Ryhel (5):
  dt-bindings: iio: light: Document Avago APDS9900/9901 ALS/Proximity
    sensor
  misc: apds990x: Use more device managed approach in the probe
  misc: apds990x: Drop Vled supply
  misc: apds990x: Convert to use OF bindings
  misc: apds990x: Drop IRQF_TRIGGER_LOW trigger

 .../bindings/iio/light/avago,apds9900.yaml    |  83 ++++++++
 drivers/misc/apds990x.c                       | 197 +++++++++---------
 include/linux/platform_data/apds990x.h        |  65 ------
 3 files changed, 187 insertions(+), 158 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml
 delete mode 100644 include/linux/platform_data/apds990x.h

-- 
2.51.0


^ permalink raw reply

* [PATCH v1 1/5] dt-bindings: iio: light: Document Avago APDS9900/9901 ALS/Proximity sensor
From: Svyatoslav Ryhel @ 2026-04-18 14:47 UTC (permalink / raw)
  To: Jonathan Cameron, David Lechner, Nuno Sá, Andy Shevchenko,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Arnd Bergmann,
	Greg Kroah-Hartman, Svyatoslav Ryhel, Randy Dunlap
  Cc: linux-iio, devicetree, linux-kernel
In-Reply-To: <20260418144716.132936-1-clamor95@gmail.com>

Document Avago APDS-9900/9901 combined ALS/IR-LED/Proximity sensor.

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
---
 .../bindings/iio/light/avago,apds9900.yaml    | 83 +++++++++++++++++++
 1 file changed, 83 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml

diff --git a/Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml b/Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml
new file mode 100644
index 000000000000..f5fb79439e56
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml
@@ -0,0 +1,83 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/light/avago,apds9900.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Avago APDS-9900/9901 combined ALS/IR-LED/Proximity sensor
+
+maintainers:
+  - Svyatoslav Ryhel <clamor95@gmail.com>
+
+description: |
+  The APDS-9900/9901 provides digital ambient light sensing (ALS),
+  IR LED and a complete proximity detection system in a single
+  8 pin package over I2C interface.
+  Datasheet at https://docs.broadcom.com/doc/AV02-2867EN
+
+properties:
+  compatible:
+    enum:
+      - avago,apds9900
+      - avago,apds9901
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  vdd-supply: true
+
+  avago,pdrive-microamp:
+    description:
+      The LED drive current is controlled by a regulated current
+      sink on the LDR pin. This feature eliminates the need to use
+      a current limiting resistor to control LED current. The LED
+      drive current can be configured for 12.5 mA, 25 mA, 50 mA
+      or 100 mA. For higher LED drive requirements, an external
+      P type transistor can be used to control the LED current.
+    enum: [12500, 25000, 50000, 100000]
+    default: 100000
+
+  avago,ppcount:
+    $ref: /schemas/types.yaml#/definitions/uint32
+    description:
+      The number of LED pulses can be programmed to a value of 1 to
+      255 pulses as needed. Increasing the number of LED pulses at a
+      given current will increase the sensor sensitivity. Sensitivity
+      grows by the square root of the number of pulses. Each pulse
+      has a 16 mS period.
+    minimum: 1
+    maximum: 255
+    default: 1
+
+additionalProperties: false
+
+required:
+  - compatible
+  - reg
+  - interrupts
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/irq.h>
+
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        light-sensor@39 {
+            compatible = "avago,apds9900";
+            reg = <0x39>;
+
+            interrupt-parent = <&gpio>;
+            interrupts = <82 IRQ_TYPE_EDGE_RISING>;
+
+            vdd-supply = <&vdd_2v85_als>;
+
+            avago,pdrive-microamp = <100000>;
+            avago,ppcount = <3>;
+        };
+    };
+...
-- 
2.51.0


^ permalink raw reply related

* [PATCH v1 2/5] misc: apds990x: Use more device managed approach in the probe
From: Svyatoslav Ryhel @ 2026-04-18 14:47 UTC (permalink / raw)
  To: Jonathan Cameron, David Lechner, Nuno Sá, Andy Shevchenko,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Arnd Bergmann,
	Greg Kroah-Hartman, Svyatoslav Ryhel, Randy Dunlap
  Cc: linux-iio, devicetree, linux-kernel
In-Reply-To: <20260418144716.132936-1-clamor95@gmail.com>

No functional changes to the driver. The probe code was refactored to
switch to devm_ versions of functions and reduce the nesting of labels.
This is in preparation for OF conversion and platform data removal.

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
---
 drivers/misc/apds990x.c | 80 +++++++++++++++--------------------------
 1 file changed, 28 insertions(+), 52 deletions(-)

diff --git a/drivers/misc/apds990x.c b/drivers/misc/apds990x.c
index b69c3a1c94d1..742ab331a221 100644
--- a/drivers/misc/apds990x.c
+++ b/drivers/misc/apds990x.c
@@ -1053,9 +1053,10 @@ static const struct attribute_group apds990x_attribute_group[] = {
 static int apds990x_probe(struct i2c_client *client)
 {
 	struct apds990x_chip *chip;
+	struct device *dev = &client->dev;
 	int err;
 
-	chip = kzalloc_obj(*chip);
+	chip = devm_kzalloc(dev, sizeof(*chip), GFP_KERNEL);
 	if (!chip)
 		return -ENOMEM;
 
@@ -1066,11 +1067,8 @@ static int apds990x_probe(struct i2c_client *client)
 	mutex_init(&chip->mutex);
 	chip->pdata	= client->dev.platform_data;
 
-	if (chip->pdata == NULL) {
-		dev_err(&client->dev, "platform data is mandatory\n");
-		err = -EINVAL;
-		goto fail1;
-	}
+	if (chip->pdata == NULL)
+		return dev_err_probe(dev, -EINVAL, "platform data is mandatory\n");
 
 	if (chip->pdata->cf.ga == 0) {
 		/* set uncovered sensor default parameters */
@@ -1113,75 +1111,61 @@ static int apds990x_probe(struct i2c_client *client)
 	chip->regs[0].supply = reg_vcc;
 	chip->regs[1].supply = reg_vled;
 
-	err = regulator_bulk_get(&client->dev,
-				 ARRAY_SIZE(chip->regs), chip->regs);
-	if (err < 0) {
-		dev_err(&client->dev, "Cannot get regulators\n");
-		goto fail1;
-	}
+	err = devm_regulator_bulk_get(dev, ARRAY_SIZE(chip->regs), chip->regs);
+	if (err)
+		return dev_err_probe(dev, err, "failed to get supplies\n");
 
 	err = regulator_bulk_enable(ARRAY_SIZE(chip->regs), chip->regs);
-	if (err < 0) {
-		dev_err(&client->dev, "Cannot enable regulators\n");
-		goto fail2;
-	}
+	if (err < 0)
+		return dev_err_probe(dev, err, "cannot enable regulators\n");
 
 	usleep_range(APDS_STARTUP_DELAY, 2 * APDS_STARTUP_DELAY);
 
 	err = apds990x_detect(chip);
 	if (err < 0) {
-		dev_err(&client->dev, "APDS990X not found\n");
-		goto fail3;
+		dev_err(dev, "APDS990X not found\n");
+		goto error_regulator;
 	}
 
-	pm_runtime_set_active(&client->dev);
+	pm_runtime_set_active(dev);
 
 	apds990x_configure(chip);
 	apds990x_set_arate(chip, APDS_LUX_DEFAULT_RATE);
 	apds990x_mode_on(chip);
 
-	pm_runtime_enable(&client->dev);
+	pm_runtime_enable(dev);
 
 	if (chip->pdata->setup_resources) {
 		err = chip->pdata->setup_resources();
 		if (err) {
 			err = -EINVAL;
-			goto fail4;
+			goto error_pm;
 		}
 	}
 
-	err = sysfs_create_group(&chip->client->dev.kobj,
-				apds990x_attribute_group);
+	err = devm_device_add_group(dev, apds990x_attribute_group);
 	if (err < 0) {
-		dev_err(&chip->client->dev, "Sysfs registration failed\n");
-		goto fail5;
+		dev_err(dev, "Sysfs registration failed\n");
+		goto error_resourses;
 	}
 
-	err = request_threaded_irq(client->irq, NULL,
-				apds990x_irq,
-				IRQF_TRIGGER_FALLING | IRQF_TRIGGER_LOW |
-				IRQF_ONESHOT,
-				"apds990x", chip);
+	err = devm_request_threaded_irq(dev, client->irq, NULL, apds990x_irq,
+					IRQF_TRIGGER_FALLING | IRQF_TRIGGER_LOW |
+					IRQF_ONESHOT, "apds990x", chip);
 	if (err) {
-		dev_err(&client->dev, "could not get IRQ %d\n",
-			client->irq);
-		goto fail6;
+		dev_err(dev, "could not get IRQ %d\n", client->irq);
+		goto error_resourses;
 	}
+
 	return err;
-fail6:
-	sysfs_remove_group(&chip->client->dev.kobj,
-			&apds990x_attribute_group[0]);
-fail5:
+error_resourses:
 	if (chip->pdata && chip->pdata->release_resources)
 		chip->pdata->release_resources();
-fail4:
-	pm_runtime_disable(&client->dev);
-fail3:
+error_pm:
+	pm_runtime_disable(dev);
+error_regulator:
 	regulator_bulk_disable(ARRAY_SIZE(chip->regs), chip->regs);
-fail2:
-	regulator_bulk_free(ARRAY_SIZE(chip->regs), chip->regs);
-fail1:
-	kfree(chip);
+
 	return err;
 }
 
@@ -1189,10 +1173,6 @@ static void apds990x_remove(struct i2c_client *client)
 {
 	struct apds990x_chip *chip = i2c_get_clientdata(client);
 
-	free_irq(client->irq, chip);
-	sysfs_remove_group(&chip->client->dev.kobj,
-			apds990x_attribute_group);
-
 	if (chip->pdata && chip->pdata->release_resources)
 		chip->pdata->release_resources();
 
@@ -1201,10 +1181,6 @@ static void apds990x_remove(struct i2c_client *client)
 
 	pm_runtime_disable(&client->dev);
 	pm_runtime_set_suspended(&client->dev);
-
-	regulator_bulk_free(ARRAY_SIZE(chip->regs), chip->regs);
-
-	kfree(chip);
 }
 
 #ifdef CONFIG_PM_SLEEP
-- 
2.51.0


^ permalink raw reply related

* [PATCH v1 3/5] misc: apds990x: Drop Vled supply
From: Svyatoslav Ryhel @ 2026-04-18 14:47 UTC (permalink / raw)
  To: Jonathan Cameron, David Lechner, Nuno Sá, Andy Shevchenko,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Arnd Bergmann,
	Greg Kroah-Hartman, Svyatoslav Ryhel, Randy Dunlap
  Cc: linux-iio, devicetree, linux-kernel
In-Reply-To: <20260418144716.132936-1-clamor95@gmail.com>

According to the APDS9900/9901 documentation, this chip has only one
supply, VDD; hence, drop the Vled supply. Additionally, supply has been
set to lowercase for consistency.

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
---
 drivers/misc/apds990x.c | 27 +++++++++++----------------
 1 file changed, 11 insertions(+), 16 deletions(-)

diff --git a/drivers/misc/apds990x.c b/drivers/misc/apds990x.c
index 742ab331a221..264335b581c1 100644
--- a/drivers/misc/apds990x.c
+++ b/drivers/misc/apds990x.c
@@ -113,7 +113,7 @@ struct apds990x_chip {
 	struct apds990x_platform_data	*pdata;
 	struct i2c_client		*client;
 	struct mutex			mutex; /* avoid parallel access */
-	struct regulator_bulk_data	regs[2];
+	struct regulator		*vdd_supply;
 	wait_queue_head_t		wait;
 
 	int	prox_en;
@@ -179,10 +179,6 @@ static const u8 again[]	= {1, 8, 16, 120}; /* ALS gain steps */
 static const u16 arates_hz[] = {10, 5, 2, 1};
 static const u8 apersis[] = {1, 2, 4, 5};
 
-/* Regulators */
-static const char reg_vcc[] = "Vdd";
-static const char reg_vled[] = "Vled";
-
 static int apds990x_read_byte(struct apds990x_chip *chip, u8 reg, u8 *data)
 {
 	struct i2c_client *client = chip->client;
@@ -597,8 +593,9 @@ static int apds990x_detect(struct apds990x_chip *chip)
 #ifdef CONFIG_PM
 static int apds990x_chip_on(struct apds990x_chip *chip)
 {
-	int err	 = regulator_bulk_enable(ARRAY_SIZE(chip->regs),
-					chip->regs);
+	int err;
+
+	err = regulator_enable(chip->vdd_supply);
 	if (err < 0)
 		return err;
 
@@ -615,7 +612,7 @@ static int apds990x_chip_on(struct apds990x_chip *chip)
 static int apds990x_chip_off(struct apds990x_chip *chip)
 {
 	apds990x_write_byte(chip, APDS990X_ENABLE, APDS990X_EN_DISABLE_ALL);
-	regulator_bulk_disable(ARRAY_SIZE(chip->regs), chip->regs);
+	regulator_disable(chip->vdd_supply);
 	return 0;
 }
 
@@ -1108,14 +1105,12 @@ static int apds990x_probe(struct i2c_client *client)
 	chip->prox_persistence = APDS_DEFAULT_PROX_PERS;
 	chip->prox_continuous_mode = false;
 
-	chip->regs[0].supply = reg_vcc;
-	chip->regs[1].supply = reg_vled;
-
-	err = devm_regulator_bulk_get(dev, ARRAY_SIZE(chip->regs), chip->regs);
-	if (err)
-		return dev_err_probe(dev, err, "failed to get supplies\n");
+	chip->vdd_supply = devm_regulator_get(dev, "vdd");
+	if (IS_ERR(chip->vdd_supply))
+		return dev_err_probe(dev, PTR_ERR(chip->vdd_supply),
+				     "failed to get vdd-supply\n");
 
-	err = regulator_bulk_enable(ARRAY_SIZE(chip->regs), chip->regs);
+	err = regulator_enable(chip->vdd_supply);
 	if (err < 0)
 		return dev_err_probe(dev, err, "cannot enable regulators\n");
 
@@ -1164,7 +1159,7 @@ static int apds990x_probe(struct i2c_client *client)
 error_pm:
 	pm_runtime_disable(dev);
 error_regulator:
-	regulator_bulk_disable(ARRAY_SIZE(chip->regs), chip->regs);
+	regulator_disable(chip->vdd_supply);
 
 	return err;
 }
-- 
2.51.0


^ permalink raw reply related

* [PATCH v1 5/5] misc: apds990x: Drop IRQF_TRIGGER_LOW trigger
From: Svyatoslav Ryhel @ 2026-04-18 14:47 UTC (permalink / raw)
  To: Jonathan Cameron, David Lechner, Nuno Sá, Andy Shevchenko,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Arnd Bergmann,
	Greg Kroah-Hartman, Svyatoslav Ryhel, Randy Dunlap
  Cc: linux-iio, devicetree, linux-kernel
In-Reply-To: <20260418144716.132936-1-clamor95@gmail.com>

Predefined IRQF_TRIGGER_LOW causes a conflict when setting triggers in the
device tree node. Remove IRQF_TRIGGER_LOW from the interrupt; it can be
specified in the device tree if needed.

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
---
 drivers/misc/apds990x.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/misc/apds990x.c b/drivers/misc/apds990x.c
index 557c8476ea80..51037cdc2c47 100644
--- a/drivers/misc/apds990x.c
+++ b/drivers/misc/apds990x.c
@@ -1183,8 +1183,8 @@ static int apds990x_probe(struct i2c_client *client)
 	}
 
 	err = devm_request_threaded_irq(dev, client->irq, NULL, apds990x_irq,
-					IRQF_TRIGGER_FALLING | IRQF_TRIGGER_LOW |
-					IRQF_ONESHOT, "apds990x", chip);
+					IRQF_TRIGGER_FALLING | IRQF_ONESHOT,
+					"apds990x", chip);
 	if (err) {
 		dev_err(dev, "could not get IRQ %d\n", client->irq);
 		goto error_pm;
-- 
2.51.0


^ permalink raw reply related

* [PATCH v1 4/5] misc: apds990x: Convert to use OF bindings
From: Svyatoslav Ryhel @ 2026-04-18 14:47 UTC (permalink / raw)
  To: Jonathan Cameron, David Lechner, Nuno Sá, Andy Shevchenko,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Arnd Bergmann,
	Greg Kroah-Hartman, Svyatoslav Ryhel, Randy Dunlap
  Cc: linux-iio, devicetree, linux-kernel
In-Reply-To: <20260418144716.132936-1-clamor95@gmail.com>

Since there are no users of this driver via platform data, remove platform
data and switch to using device tree bindings.

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
---
 drivers/misc/apds990x.c                | 112 +++++++++++++++++--------
 include/linux/platform_data/apds990x.h |  65 --------------
 2 files changed, 76 insertions(+), 101 deletions(-)
 delete mode 100644 include/linux/platform_data/apds990x.h

diff --git a/drivers/misc/apds990x.c b/drivers/misc/apds990x.c
index 264335b581c1..557c8476ea80 100644
--- a/drivers/misc/apds990x.c
+++ b/drivers/misc/apds990x.c
@@ -12,13 +12,14 @@
 #include <linux/module.h>
 #include <linux/i2c.h>
 #include <linux/interrupt.h>
+#include <linux/mod_devicetable.h>
 #include <linux/mutex.h>
+#include <linux/property.h>
 #include <linux/regulator/consumer.h>
 #include <linux/pm_runtime.h>
 #include <linux/delay.h>
 #include <linux/wait.h>
 #include <linux/slab.h>
-#include <linux/platform_data/apds990x.h>
 
 /* Register map */
 #define APDS990X_ENABLE	 0x00 /* Enable of states and interrupts */
@@ -100,6 +101,36 @@
 
 #define APDS990X_LUX_OUTPUT_SCALE 10
 
+#define APDS_IRLED_CURR_12mA	0x3
+#define APDS_IRLED_CURR_25mA	0x2
+#define APDS_IRLED_CURR_50mA	0x1
+#define APDS_IRLED_CURR_100mA	0x0
+
+#define APDS_PARAM_SCALE	4096
+
+/**
+ * struct apds990x_chip_factors - defines effect of the cover window
+ * @ga: Total glass attenuation
+ * @cf1: clear channel factor 1 for raw to lux conversion
+ * @irf1: IR channel factor 1 for raw to lux conversion
+ * @cf2: clear channel factor 2 for raw to lux conversion
+ * @irf2: IR channel factor 2 for raw to lux conversion
+ * @df: device factor for conversion formulas
+ *
+ * Structure for tuning ALS calculation to match with environment.
+ * Values depend on the material above the sensor and the sensor
+ * itself. If the GA is zero, driver will use uncovered sensor default values
+ * format: decimal value * APDS_PARAM_SCALE except df which is plain integer.
+ */
+struct apds990x_chip_factors {
+	int ga;
+	int cf1;
+	int irf1;
+	int cf2;
+	int irf2;
+	int df;
+};
+
 /* Reverse chip factors for threshold calculation */
 struct reverse_factors {
 	u32 afactor;
@@ -110,7 +141,6 @@ struct reverse_factors {
 };
 
 struct apds990x_chip {
-	struct apds990x_platform_data	*pdata;
 	struct i2c_client		*client;
 	struct mutex			mutex; /* avoid parallel access */
 	struct regulator		*vdd_supply;
@@ -131,6 +161,7 @@ struct apds990x_chip {
 	u8	pgain;
 	u8	pdiode;
 	u8	pdrive;
+	u8	ppcount;
 	u8	lux_persistence;
 	u8	prox_persistence;
 
@@ -546,7 +577,7 @@ static int apds990x_configure(struct apds990x_chip *chip)
 			(chip->lux_persistence << APDS990X_APERS_SHIFT) |
 			(chip->prox_persistence << APDS990X_PPERS_SHIFT));
 
-	apds990x_write_byte(chip, APDS990X_PPCOUNT, chip->pdata->ppcount);
+	apds990x_write_byte(chip, APDS990X_PPCOUNT, chip->ppcount);
 
 	/* Start with relatively small gain */
 	chip->again_meas = 1;
@@ -1051,6 +1082,7 @@ static int apds990x_probe(struct i2c_client *client)
 {
 	struct apds990x_chip *chip;
 	struct device *dev = &client->dev;
+	u32 pdrive_ua = 100000, ppcount = 1;
 	int err;
 
 	chip = devm_kzalloc(dev, sizeof(*chip), GFP_KERNEL);
@@ -1062,22 +1094,14 @@ static int apds990x_probe(struct i2c_client *client)
 
 	init_waitqueue_head(&chip->wait);
 	mutex_init(&chip->mutex);
-	chip->pdata	= client->dev.platform_data;
-
-	if (chip->pdata == NULL)
-		return dev_err_probe(dev, -EINVAL, "platform data is mandatory\n");
-
-	if (chip->pdata->cf.ga == 0) {
-		/* set uncovered sensor default parameters */
-		chip->cf.ga = 1966; /* 0.48 * APDS_PARAM_SCALE */
-		chip->cf.cf1 = 4096; /* 1.00 * APDS_PARAM_SCALE */
-		chip->cf.irf1 = 9134; /* 2.23 * APDS_PARAM_SCALE */
-		chip->cf.cf2 = 2867; /* 0.70 * APDS_PARAM_SCALE */
-		chip->cf.irf2 = 5816; /* 1.42 * APDS_PARAM_SCALE */
-		chip->cf.df = 52;
-	} else {
-		chip->cf = chip->pdata->cf;
-	}
+
+	/* set uncovered sensor default parameters */
+	chip->cf.ga = 1966; /* 0.48 * APDS_PARAM_SCALE */
+	chip->cf.cf1 = 4096; /* 1.00 * APDS_PARAM_SCALE */
+	chip->cf.irf1 = 9134; /* 2.23 * APDS_PARAM_SCALE */
+	chip->cf.cf2 = 2867; /* 0.70 * APDS_PARAM_SCALE */
+	chip->cf.irf2 = 5816; /* 1.42 * APDS_PARAM_SCALE */
+	chip->cf.df = 52;
 
 	/* precalculate inverse chip factors for threshold control */
 	chip->rcf.afactor =
@@ -1098,13 +1122,35 @@ static int apds990x_probe(struct i2c_client *client)
 	chip->lux_calib = APDS_LUX_NEUTRAL_CALIB_VALUE;
 
 	chip->prox_thres = APDS_PROX_DEF_THRES;
-	chip->pdrive = chip->pdata->pdrive;
 	chip->pdiode = APDS_PDIODE_IR;
 	chip->pgain = APDS_PGAIN_1X;
 	chip->prox_calib = APDS_PROX_NEUTRAL_CALIB_VALUE;
 	chip->prox_persistence = APDS_DEFAULT_PROX_PERS;
 	chip->prox_continuous_mode = false;
 
+	err = device_property_read_u32(dev, "avago,pdrive-microamp", &pdrive_ua);
+	if (!err) {
+		switch (pdrive_ua) {
+		case 12500:
+			chip->pdrive = APDS_IRLED_CURR_12mA;
+			break;
+		case 25000:
+			chip->pdrive = APDS_IRLED_CURR_25mA;
+			break;
+		case 50000:
+			chip->pdrive = APDS_IRLED_CURR_50mA;
+			break;
+		case 100000:
+			chip->pdrive = APDS_IRLED_CURR_100mA;
+			break;
+		default:
+			return -EINVAL;
+		}
+	}
+
+	device_property_read_u32(dev, "avago,ppcount", &ppcount);
+	chip->ppcount = ppcount;
+
 	chip->vdd_supply = devm_regulator_get(dev, "vdd");
 	if (IS_ERR(chip->vdd_supply))
 		return dev_err_probe(dev, PTR_ERR(chip->vdd_supply),
@@ -1130,18 +1176,10 @@ static int apds990x_probe(struct i2c_client *client)
 
 	pm_runtime_enable(dev);
 
-	if (chip->pdata->setup_resources) {
-		err = chip->pdata->setup_resources();
-		if (err) {
-			err = -EINVAL;
-			goto error_pm;
-		}
-	}
-
 	err = devm_device_add_group(dev, apds990x_attribute_group);
 	if (err < 0) {
 		dev_err(dev, "Sysfs registration failed\n");
-		goto error_resourses;
+		goto error_pm;
 	}
 
 	err = devm_request_threaded_irq(dev, client->irq, NULL, apds990x_irq,
@@ -1149,13 +1187,10 @@ static int apds990x_probe(struct i2c_client *client)
 					IRQF_ONESHOT, "apds990x", chip);
 	if (err) {
 		dev_err(dev, "could not get IRQ %d\n", client->irq);
-		goto error_resourses;
+		goto error_pm;
 	}
 
 	return err;
-error_resourses:
-	if (chip->pdata && chip->pdata->release_resources)
-		chip->pdata->release_resources();
 error_pm:
 	pm_runtime_disable(dev);
 error_regulator:
@@ -1168,9 +1203,6 @@ static void apds990x_remove(struct i2c_client *client)
 {
 	struct apds990x_chip *chip = i2c_get_clientdata(client);
 
-	if (chip->pdata && chip->pdata->release_resources)
-		chip->pdata->release_resources();
-
 	if (!pm_runtime_suspended(&client->dev))
 		apds990x_chip_off(chip);
 
@@ -1224,6 +1256,13 @@ static int apds990x_runtime_resume(struct device *dev)
 
 #endif
 
+static const struct of_device_id apds990x_of_match[] = {
+	{ .compatible = "avago,apds9900" },
+	{ .compatible = "avago,apds9901" },
+	{ }
+};
+MODULE_DEVICE_TABLE(of, apds990x_of_match);
+
 static const struct i2c_device_id apds990x_id[] = {
 	{ "apds990x" },
 	{}
@@ -1242,6 +1281,7 @@ static struct i2c_driver apds990x_driver = {
 	.driver	  = {
 		.name	= "apds990x",
 		.pm	= &apds990x_pm_ops,
+		.of_match_table = apds990x_of_match,
 	},
 	.probe    = apds990x_probe,
 	.remove	  = apds990x_remove,
diff --git a/include/linux/platform_data/apds990x.h b/include/linux/platform_data/apds990x.h
deleted file mode 100644
index 37684f68c04f..000000000000
--- a/include/linux/platform_data/apds990x.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0-only */
-/*
- * This file is part of the APDS990x sensor driver.
- * Chip is combined proximity and ambient light sensor.
- *
- * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
- *
- * Contact: Samu Onkalo <samu.p.onkalo@nokia.com>
- */
-
-#ifndef __APDS990X_H__
-#define __APDS990X_H__
-
-
-#define APDS_IRLED_CURR_12mA	0x3
-#define APDS_IRLED_CURR_25mA	0x2
-#define APDS_IRLED_CURR_50mA	0x1
-#define APDS_IRLED_CURR_100mA	0x0
-
-/**
- * struct apds990x_chip_factors - defines effect of the cover window
- * @ga: Total glass attenuation
- * @cf1: clear channel factor 1 for raw to lux conversion
- * @irf1: IR channel factor 1 for raw to lux conversion
- * @cf2: clear channel factor 2 for raw to lux conversion
- * @irf2: IR channel factor 2 for raw to lux conversion
- * @df: device factor for conversion formulas
- *
- * Structure for tuning ALS calculation to match with environment.
- * Values depend on the material above the sensor and the sensor
- * itself. If the GA is zero, driver will use uncovered sensor default values
- * format: decimal value * APDS_PARAM_SCALE except df which is plain integer.
- */
-struct apds990x_chip_factors {
-	int ga;
-	int cf1;
-	int irf1;
-	int cf2;
-	int irf2;
-	int df;
-};
-#define APDS_PARAM_SCALE 4096
-
-/**
- * struct apds990x_platform_data - platform data for apsd990x.c driver
- * @cf: chip factor data
- * @pdrive: IR-led driving current
- * @ppcount: number of IR pulses used for proximity estimation
- * @setup_resources: interrupt line setup call back function
- * @release_resources: interrupt line release call back function
- *
- * Proximity detection result depends heavily on correct ppcount, pdrive
- * and cover window.
- *
- */
-
-struct apds990x_platform_data {
-	struct apds990x_chip_factors cf;
-	u8     pdrive;
-	u8     ppcount;
-	int    (*setup_resources)(void);
-	int    (*release_resources)(void);
-};
-
-#endif
-- 
2.51.0


^ permalink raw reply related

* Re: [PATCH v3 3/3] arm64: dts: qcom: eliza: Add IMEM node
From: Dmitry Baryshkov @ 2026-04-18 15:14 UTC (permalink / raw)
  To: Alexander Koskovich
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Bjorn Andersson,
	Konrad Dybcio, devicetree, linux-kernel, linux-arm-msm,
	Konrad Dybcio
In-Reply-To: <20260418-eliza-imem-v3-3-bfbd499b6e77@pm.me>

On Sat, Apr 18, 2026 at 10:40:00AM +0000, Alexander Koskovich wrote:
> Add a node for the IMEM found on Eliza, which contains pil-reloc-info
> and the modem tables for IPA, among others.
> 
> Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
> Signed-off-by: Alexander Koskovich <akoskovich@pm.me>
> ---
>  arch/arm64/boot/dts/qcom/eliza.dtsi | 20 ++++++++++++++++++++
>  1 file changed, 20 insertions(+)
> 

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>


-- 
With best wishes
Dmitry

^ permalink raw reply

* Re: [PATCH] arm64: dts: qcom: hamoa: add audio PD remote heap region
From: Dmitry Baryshkov @ 2026-04-18 15:14 UTC (permalink / raw)
  To: ekansh.gupta
  Cc: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Bharath Kumar, Chenna Kesava Raju, linux-arm-msm,
	devicetree, linux-kernel
In-Reply-To: <20260418-hamoaaudio-v1-1-a92866f744a6@oss.qualcomm.com>

On Sat, Apr 18, 2026 at 11:38:15AM +0530, Ekansh Gupta via B4 Relay wrote:
> From: Ekansh Gupta <ekansh.gupta@oss.qualcomm.com>
> 
> Reference the reserved memory region for audio PD dynamic loading
> and remote heap requirements. Add the required VMID list for memory
> ownership transfers.
> 
> Signed-off-by: Ekansh Gupta <ekansh.gupta@oss.qualcomm.com>
> ---
>  arch/arm64/boot/dts/qcom/hamoa.dtsi | 4 ++++
>  1 file changed, 4 insertions(+)
> 

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>

> 

-- 
With best wishes
Dmitry

^ permalink raw reply

* Re: [PATCH] arm64: dts: qcom: talos: Add memory-region for audio PD
From: Dmitry Baryshkov @ 2026-04-18 15:15 UTC (permalink / raw)
  To: Ekansh Gupta
  Cc: konrad.dybcio, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, quic_bkumar, quic_chennak,
	linux-arm-msm, devicetree, linux-kernel
In-Reply-To: <20260418-talosaudio-v1-1-585ab22faaf4@oss.qualcomm.com>

On Sat, Apr 18, 2026 at 11:18:01AM +0530, Ekansh Gupta wrote:
> Reserve memory region for audio PD dynamic loading and remote heap
> requirements. Add the required VMID list for memory ownership
> transfers.
> 
> Signed-off-by: Ekansh Gupta <ekansh.gupta@oss.qualcomm.com>
> ---
>  arch/arm64/boot/dts/qcom/talos.dtsi | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/qcom/talos.dtsi b/arch/arm64/boot/dts/qcom/talos.dtsi
> index ff5afbfce2a4..c36917d6e0a9 100644
> --- a/arch/arm64/boot/dts/qcom/talos.dtsi
> +++ b/arch/arm64/boot/dts/qcom/talos.dtsi
> @@ -11,6 +11,7 @@
>  #include <dt-bindings/clock/qcom,qcs615-videocc.h>
>  #include <dt-bindings/clock/qcom,rpmh.h>
>  #include <dt-bindings/dma/qcom-gpi.h>
> +#include <dt-bindings/firmware/qcom,scm.h>
>  #include <dt-bindings/interconnect/qcom,icc.h>
>  #include <dt-bindings/interconnect/qcom,osm-l3.h>
>  #include <dt-bindings/interconnect/qcom,qcs615-rpmh.h>
> @@ -657,6 +658,11 @@ pil_gpu_mem: pil-gpu@97715000 {
>  			reg = <0x0 0x97715000 0x0 0x2000>;
>  			no-map;
>  		};
> +
> +		adsp_rpc_remote_heap_mem: adsp-rpc-remote-heap@97717000 {
> +			reg = <0x0 0x97717000 0x0 0x800000>;
> +			no-map;
> +		};
>  	};
>  
>  	soc: soc@0 {
> @@ -5100,6 +5106,9 @@ fastrpc {
>  					compatible = "qcom,fastrpc";
>  					qcom,glink-channels = "fastrpcglink-apps-dsp";
>  					label = "adsp";
> +					memory-region = <&adsp_rpc_remote_heap_mem>;
> +					qcom,vmids = <QCOM_SCM_VMID_LPASS
> +							  QCOM_SCM_VMID_ADSP_HEAP>;

Align on '<' symbol.

>  					#address-cells = <1>;
>  					#size-cells = <0>;
>  
> 
> ---
> base-commit: c7275b05bc428c7373d97aa2da02d3a7fa6b9f66
> change-id: 20260418-talosaudio-b8ecf8b9a1b3
> 
> Best regards,
> -- 
> Ekansh Gupta <ekansh.gupta@oss.qualcomm.com>
> 

-- 
With best wishes
Dmitry

^ permalink raw reply

* Re: [PATCH RFC 04/10] arm64: dts: qcom: msm8939: Add venus node
From: Erikas Bitovtas @ 2026-04-18 15:34 UTC (permalink / raw)
  To: Bryan O'Donoghue, Vikash Garodia, Dikshita Agarwal,
	Mauro Carvalho Chehab, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, André Apitzsch, Bjorn Andersson, Konrad Dybcio,
	Michael Turquette, Stephen Boyd
  Cc: linux-media, linux-arm-msm, devicetree, linux-kernel, linux-clk,
	~postmarketos/upstreaming, phone-devel
In-Reply-To: <ac54d018-78e2-4f8d-97f5-3cfdb5151aa0@kernel.org>



On 4/16/26 5:31 PM, Bryan O'Donoghue wrote:
> On 16/04/2026 14:43, Erikas Bitovtas wrote:
>> +            video-decoder {
>> +                compatible = "venus-decoder";
>> +                clocks = <&gcc GCC_VENUS0_CORE0_VCODEC0_CLK>,
>> +                     <&gcc GCC_VENUS0_CORE1_VCODEC0_CLK>;
>> +                clock-names = "core0", "core1";
>> +                power-domains = <&gcc VENUS_CORE0_GDSC>,
>> +                        <&gcc VENUS_CORE1_GDSC>;
> 
> This doesn't make sense.
> 
> You have two cores => assign one to encoder and the other to decoder.
> 

This way during decode only one of the cores gets powered up instead of
both, resulting in power collapse fails.
Core clocks and power domains can be moved into Venus node instead of
sub-nodes, like this:
venus: video-codec@1d00000 {
	compatible = "qcom,msm8939-venus";
	reg = <0x01d00000 0xff000>;
	interrupts = <GIC_SPI 44 IRQ_TYPE_LEVEL_HIGH>;
	clocks = <&gcc GCC_VENUS0_VCODEC0_CLK>,
		 <&gcc GCC_VENUS0_AHB_CLK>,
		 <&gcc GCC_VENUS0_AXI_CLK>,
		 <&gcc GCC_VENUS0_CORE0_VCODEC0_CLK>,
		 <&gcc GCC_VENUS0_CORE1_VCODEC0_CLK>;
	clock-names = "core",
		      "iface",
		      "bus",
		      "core0",
		      "core1";
	power-domains = <&gcc VENUS_GDSC>,
			<&gcc VENUS_C0RE0_GDSC>,
			<&gcc VENUS_CORE1_GDSC>;
	power-domain-names = "venus", "core0", "core1";
};

And then they can be powered up regardless if the session is for
encoding or decoding.
My first question was actually about this - whether these cores should
be powered up only decoding or for encoding as well. Bus configs
downstream signify they are only for decoding:
https://github.com/msm8916-mainline/linux-downstream/blob/b20608408caff817ec874f325127b07609fbaeb8/arch/arm/boot/dts/qcom/msm8939-common.dtsi#L1589
https://github.com/msm8916-mainline/linux-downstream/blob/b20608408caff817ec874f325127b07609fbaeb8/Documentation/devicetree/bindings/media/video/msm-vidc.txt#L35
Unfortunately, I couldn't test encoding on my device. It appears to be
broken.

^ permalink raw reply

* Re: [PATCH 03/10] mfd: qcom_rpm: add msm8960 QDSS clock resource
From: Dmitry Baryshkov @ 2026-04-18 16:11 UTC (permalink / raw)
  To: Konrad Dybcio
  Cc: Antony Kurniawan Soemardi, Bjorn Andersson, Michael Turquette,
	Stephen Boyd, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Lee Jones, Konrad Dybcio, Krzysztof Kozlowski, linux-arm-msm,
	linux-clk, devicetree, linux-kernel, phone-devel, Rudraksha Gupta
In-Reply-To: <00e40481-9e62-437e-ac75-a04594ef6879@oss.qualcomm.com>

On Thu, Apr 16, 2026 at 03:49:33PM +0200, Konrad Dybcio wrote:
> On 4/15/26 5:20 PM, Antony Kurniawan Soemardi wrote:
> > On 4/14/2026 3:07 PM, Konrad Dybcio wrote:
> >> On 4/14/26 10:06 AM, Konrad Dybcio wrote:
> >>> On 4/13/26 8:55 PM, Antony Kurniawan Soemardi via B4 Relay wrote:
> >>>> From: Antony Kurniawan Soemardi <linux@smankusors.com>
> >>>>
> >>>> msm8960 uses the same clock descriptor as apq8064 but lacked the
> >>>
> >>> This doesn't quite seem to be the case, some fields differ and
> >>> apq8064 additionally has:
> >>>
> >>> QCOM_RPM_PM8821_SMPS1
> >>> QCOM_RPM_PM8821_SMPS2
> >>> QCOM_RPM_PM8821_LDO1
> >>> QCOM_RPM_VDDMIN_GPIO
> >>
> >> Ah hmm, the MFD driver seems to provide *all* RPM resources..
> > 
> > What I meant by "clock descriptor" in the commit message was
> > specifically the subset corresponding to RPM managed clocks. From what I
> > can tell based on downstream code, msm8960 and apq8064 seem to share the
> > same set of RPM clocks, even though the overall resource lists differ.
> > 
> > Is that understanding correct?
> 
> If that's struct msm_rpm_map_data on msm-3.x, then I see that 8x60 has:
> 
> +MSM_RPM_MAP(PLL_4, PLL_4, 1),
> +MSM_RPM_MAP(SMI_CLK, SMI_CLK, 1),
> 
> While 8960 has:
> -MSM_RPM_MAP(QDSS_CLK, QDSS_CLK, 1),

You are comparing 8x60 to 8960, while it should be 8960 to 8064.

I see that there are differences, but the QDSS is the same.

-- 
With best wishes
Dmitry

^ permalink raw reply

* Re: [PATCH 03/10] mfd: qcom_rpm: add msm8960 QDSS clock resource
From: Dmitry Baryshkov @ 2026-04-18 16:14 UTC (permalink / raw)
  To: linux
  Cc: Bjorn Andersson, Michael Turquette, Stephen Boyd, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Lee Jones, Konrad Dybcio,
	Krzysztof Kozlowski, linux-arm-msm, linux-clk, devicetree,
	linux-kernel, phone-devel, Rudraksha Gupta
In-Reply-To: <20260414-msm8960-wifi-v1-3-007fda9d6134@smankusors.com>

On Tue, Apr 14, 2026 at 01:55:30AM +0700, Antony Kurniawan Soemardi via B4 Relay wrote:
> From: Antony Kurniawan Soemardi <linux@smankusors.com>
> 
> msm8960 uses the same clock descriptor as apq8064 but lacked the
> corresponding QDSS resource definition in its resource table. Add
> resource ID 209 to msm8960_rpm_resource_table to match apq8064's
> implementation.

I'd rather drop APQ8064 mentions from the commit message and just state
that you are adding the QDSS clock to match msm-3.0 code.

> 
> Without this entry, RPM clock initialization fails on msm8960,
> preventing Bluetooth/Wi-Fi/USB from being enabled.
> 
> Tested-by: Rudraksha Gupta <guptarud@gmail.com>
> Signed-off-by: Antony Kurniawan Soemardi <linux@smankusors.com>
> ---
>  drivers/mfd/qcom_rpm.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/mfd/qcom_rpm.c b/drivers/mfd/qcom_rpm.c
> index 27446f43e3f3..0defb3279af1 100644
> --- a/drivers/mfd/qcom_rpm.c
> +++ b/drivers/mfd/qcom_rpm.c
> @@ -324,6 +324,7 @@ static const struct qcom_rpm_resource msm8960_rpm_resource_table[] = {
>  	[QCOM_RPM_USB_OTG_SWITCH] =		{ 205, 119, 82, 1 },
>  	[QCOM_RPM_HDMI_SWITCH] =		{ 206, 120, 83, 1 },
>  	[QCOM_RPM_DDR_DMM] =			{ 207, 121, 84, 2 },
> +	[QCOM_RPM_QDSS_CLK] =			{ 209, ~0, 7, 1 },
>  };
>  
>  static const struct qcom_rpm_data msm8960_template = {
> 
> -- 
> 2.34.1
> 
> 

-- 
With best wishes
Dmitry

^ permalink raw reply

* Re: [PATCH v1 1/5] dt-bindings: iio: light: Document Avago APDS9900/9901 ALS/Proximity sensor
From: David Lechner @ 2026-04-18 16:21 UTC (permalink / raw)
  To: Svyatoslav Ryhel, Jonathan Cameron, Nuno Sá, Andy Shevchenko,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Arnd Bergmann,
	Greg Kroah-Hartman, Randy Dunlap
  Cc: linux-iio, devicetree, linux-kernel
In-Reply-To: <20260418144716.132936-2-clamor95@gmail.com>

On 4/18/26 9:47 AM, Svyatoslav Ryhel wrote:
> Document Avago APDS-9900/9901 combined ALS/IR-LED/Proximity sensor.

I think we can just add this to iio/light/tsl2772.yaml. It already has
avago,apds9930 which looks similar.

> 
> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
> ---
>  .../bindings/iio/light/avago,apds9900.yaml    | 83 +++++++++++++++++++
>  1 file changed, 83 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml
> 
> diff --git a/Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml b/Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml
> new file mode 100644
> index 000000000000..f5fb79439e56
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml
> @@ -0,0 +1,83 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/iio/light/avago,apds9900.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Avago APDS-9900/9901 combined ALS/IR-LED/Proximity sensor
> +
> +maintainers:
> +  - Svyatoslav Ryhel <clamor95@gmail.com>
> +
> +description: |
> +  The APDS-9900/9901 provides digital ambient light sensing (ALS),
> +  IR LED and a complete proximity detection system in a single
> +  8 pin package over I2C interface.
> +  Datasheet at https://docs.broadcom.com/doc/AV02-2867EN
> +
> +properties:
> +  compatible:
> +    enum:
> +      - avago,apds9900
> +      - avago,apds9901
> +
> +  reg:
> +    maxItems: 1
> +
> +  interrupts:
> +    maxItems: 1
> +
> +  vdd-supply: true
> +
> +  avago,pdrive-microamp:

In tsl2772, this is called led-max-microamp.

> +    description:
> +      The LED drive current is controlled by a regulated current
> +      sink on the LDR pin. This feature eliminates the need to use
> +      a current limiting resistor to control LED current. The LED
> +      drive current can be configured for 12.5 mA, 25 mA, 50 mA
> +      or 100 mA. For higher LED drive requirements, an external
> +      P type transistor can be used to control the LED current.
> +    enum: [12500, 25000, 50000, 100000]
> +    default: 100000
> +
> +  avago,ppcount:

This sounds like something that should be programmed at runtime, not
fixed to a single value in the devicetree. One can easily imaging an
application where the sensitivity needs to be changed as the environment
changes.

> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    description:
> +      The number of LED pulses can be programmed to a value of 1 to
> +      255 pulses as needed. Increasing the number of LED pulses at a
> +      given current will increase the sensor sensitivity. Sensitivity
> +      grows by the square root of the number of pulses. Each pulse
> +      has a 16 mS period.
> +    minimum: 1
> +    maximum: 255
> +    default: 1
> +

^ permalink raw reply

* Re: [PATCH v1 0/5] Update APDS990x ALS to support device trees
From: David Lechner @ 2026-04-18 16:24 UTC (permalink / raw)
  To: Svyatoslav Ryhel, Jonathan Cameron, Nuno Sá, Andy Shevchenko,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Arnd Bergmann,
	Greg Kroah-Hartman, Randy Dunlap
  Cc: linux-iio, devicetree, linux-kernel
In-Reply-To: <20260418144716.132936-1-clamor95@gmail.com>

On 4/18/26 9:47 AM, Svyatoslav Ryhel wrote:
> Document Avago APDS9900/9901 ALS/Proximity sensor in schema and modernize
> its driver to support OF bindings.
> 
> Svyatoslav Ryhel (5):
>   dt-bindings: iio: light: Document Avago APDS9900/9901 ALS/Proximity
>     sensor
>   misc: apds990x: Use more device managed approach in the probe
>   misc: apds990x: Drop Vled supply
>   misc: apds990x: Convert to use OF bindings
>   misc: apds990x: Drop IRQF_TRIGGER_LOW trigger
> 
>  .../bindings/iio/light/avago,apds9900.yaml    |  83 ++++++++
>  drivers/misc/apds990x.c                       | 197 +++++++++---------

As mentioned in my reply to the dt-bindings patch, there is already an
IIO driver that looks like it could be compatible. I'm guessing that
this misc driver pre-dates the IIO subsystem. I would have a look at it
instead (drivers/iio/light/tsl2772.c).

>  include/linux/platform_data/apds990x.h        |  65 ------
>  3 files changed, 187 insertions(+), 158 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/iio/light/avago,apds9900.yaml
>  delete mode 100644 include/linux/platform_data/apds990x.h
> 


^ permalink raw reply

* Re: [PATCH 05/10] ARM: dts: qcom: msm8960: add RPM clock controller and fix USB clocks
From: Dmitry Baryshkov @ 2026-04-18 16:44 UTC (permalink / raw)
  To: Konrad Dybcio
  Cc: linux, Bjorn Andersson, Michael Turquette, Stephen Boyd,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Lee Jones,
	Konrad Dybcio, Krzysztof Kozlowski, linux-arm-msm, linux-clk,
	devicetree, linux-kernel, phone-devel, Rudraksha Gupta
In-Reply-To: <7d25970d-c2e8-432e-b69f-0da99271b581@oss.qualcomm.com>

On Wed, Apr 15, 2026 at 11:28:40AM +0200, Konrad Dybcio wrote:
> On 4/13/26 8:55 PM, Antony Kurniawan Soemardi via B4 Relay wrote:
> > From: Antony Kurniawan Soemardi <linux@smankusors.com>
> > 
> > The RPM clock controller manages clocks shared between the application
> > processor and the RPM firmware, including fabric and bus clocks required
> > by several peripherals.
> > 
> > With the RPM clock controller now available in the device tree, the USB
> > controller must explicitly declare its dependency on
> > RPM_DAYTONA_FABRIC_CLK. Without this declaration, the clock framework
> > would consider it unused and disable it, breaking USB functionality.
> > 
> > This also corrects the previous misuse of USB_HS1_XCVR_CLK as the core
> > clock. The XCVR clock is in fact used for PHY/reset handling rather than
> > as the main core clock.
> > 
> > A similar issue has been observed on APQ8064, where missing the RPM
> > fabric clock dependency leads to broken USB.
> > 
> > Signed-off-by: Antony Kurniawan Soemardi <linux@smankusors.com>
> > ---
> >  arch/arm/boot/dts/qcom/qcom-msm8960.dtsi | 16 ++++++++++++++--
> >  1 file changed, 14 insertions(+), 2 deletions(-)
> > 
> > diff --git a/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi b/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi
> > index fd28401cebb5..1d5e97b6aa4b 100644
> > --- a/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi
> > +++ b/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi
> > @@ -5,6 +5,7 @@
> >  #include <dt-bindings/clock/qcom,gcc-msm8960.h>
> >  #include <dt-bindings/reset/qcom,gcc-msm8960.h>
> >  #include <dt-bindings/clock/qcom,lcc-msm8960.h>
> > +#include <dt-bindings/clock/qcom,rpmcc.h>
> >  #include <dt-bindings/mfd/qcom-rpm.h>
> >  #include <dt-bindings/soc/qcom,gsbi.h>
> >  
> > @@ -98,6 +99,13 @@ rpm: rpm@108000 {
> >  			interrupt-names = "ack",
> >  					  "err",
> >  					  "wakeup";
> > +
> > +			rpmcc: clock-controller {
> > +				compatible = "qcom,rpmcc-msm8960", "qcom,rpmcc";
> > +				#clock-cells = <1>;
> > +				clocks = <&pxo_board>, <&cxo_board>;
> > +				clock-names = "pxo", "cxo";
> 
> nit: one a line would be preferred
> 
> > +			};
> >  		};
> >  
> >  		ssbi: ssbi@500000 {
> > @@ -507,8 +515,12 @@ usb1: usb@12500000 {
> >  			reg = <0x12500000 0x200>,
> >  			      <0x12500200 0x200>;
> >  			interrupts = <GIC_SPI 100 IRQ_TYPE_LEVEL_HIGH>;
> > -			clocks = <&gcc USB_HS1_XCVR_CLK>, <&gcc USB_HS1_H_CLK>;
> > -			clock-names = "core", "iface";
> > +			clocks = <&rpmcc RPM_DAYTONA_FABRIC_CLK>,
> 
> I still have mixed feelings whether this should be a clock or an
> interconnect resource..
> 
> Some internal data tells me this is used by:
> 
> * USB
> * SDCC
> * GSBI
> * INTC
> * APSS?
> * BAM DMA
> 
> or anything that is adjacent to SPS. I think any/all clients vote either
> zero/off or 64 MHz, on MSM8960. It seems to be an IP that wasn't really
> used for a long time (and a long time ago, at that), so it's difficult to
> judge.
> 
> I see that the list above is roughy in line with where msm-3.x attaches
> the votes (also for QSEECOM and friends).. 
> 
> +Dmitry, would you know more?

As per my understadning, those chips had several fixed-speed buses. So,
you are right, these are interconnects, but they are not scalable. When
it comes to such buses (AHB, AXI), we quite frequently model them as
clocks rather than interconnects. For example the same ChipIdea USB core
on MSM8916 or MSM8974 uses "iface" clock for the GCC_USB_HS_AHB_CLK.

-- 
With best wishes
Dmitry

^ permalink raw reply

* Re: [PATCH 06/10] ARM: dts: qcom: msm8960: add SCM
From: Dmitry Baryshkov @ 2026-04-18 16:45 UTC (permalink / raw)
  To: Konrad Dybcio
  Cc: linux, Bjorn Andersson, Michael Turquette, Stephen Boyd,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Lee Jones,
	Konrad Dybcio, Krzysztof Kozlowski, linux-arm-msm, linux-clk,
	devicetree, linux-kernel, phone-devel, Rudraksha Gupta
In-Reply-To: <d53f1499-0afc-43e5-bee9-ae76df3c6910@oss.qualcomm.com>

On Tue, Apr 14, 2026 at 11:46:18AM +0200, Konrad Dybcio wrote:
> On 4/13/26 8:55 PM, Antony Kurniawan Soemardi via B4 Relay wrote:
> > From: Antony Kurniawan Soemardi <linux@smankusors.com>
> > 
> > Add the Secure Channel Manager firmware device node to the MSM8960
> > device tree. The SCM is required for secure communication between the
> > application processor and other subsystems.
> > 
> > Tested-by: Rudraksha Gupta <guptarud@gmail.com>
> > Signed-off-by: Antony Kurniawan Soemardi <linux@smankusors.com>
> > ---
> >  arch/arm/boot/dts/qcom/qcom-msm8960.dtsi | 9 +++++++++
> >  1 file changed, 9 insertions(+)
> > 
> > diff --git a/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi b/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi
> > index 1d5e97b6aa4b..bc3fd55e524a 100644
> > --- a/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi
> > +++ b/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi
> > @@ -77,6 +77,15 @@ l2: l2-cache {
> >  		};
> >  	};
> >  
> > +	firmware {
> > +		scm {
> > +			compatible = "qcom,scm-msm8960", "qcom,scm";
> > +
> > +			clocks = <&rpmcc RPM_DAYTONA_FABRIC_CLK>;
> 
> I'm wondering if this should be an interconnect resource, but from a
> quick grepping, I think this is always supposed to be @ 64 MHz so
> perhaps not really

I'd say, this matches APQ8064. Let's keep the platform enablement
separate from refactorings, especially for those musem-grade platforms.


Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>



> 
> (please tell me if you know more)
> 
> Konrad

-- 
With best wishes
Dmitry

^ permalink raw reply

* Re: [PATCH 07/10] ARM: dts: qcom: msm8960: add SMEM & hwmutex
From: Dmitry Baryshkov @ 2026-04-18 16:46 UTC (permalink / raw)
  To: linux
  Cc: Bjorn Andersson, Michael Turquette, Stephen Boyd, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Lee Jones, Konrad Dybcio,
	Krzysztof Kozlowski, linux-arm-msm, linux-clk, devicetree,
	linux-kernel, phone-devel, Rudraksha Gupta
In-Reply-To: <20260414-msm8960-wifi-v1-7-007fda9d6134@smankusors.com>

On Tue, Apr 14, 2026 at 01:55:34AM +0700, Antony Kurniawan Soemardi via B4 Relay wrote:
> From: Antony Kurniawan Soemardi <linux@smankusors.com>
> 
> Enable shared memory communication and add the SFPB mutex for MSM8960.
> These provide the foundation for inter-processor communication with the
> Riva (BT + Wi-Fi) subsystem.
> 
> Tested-by: Rudraksha Gupta <guptarud@gmail.com>
> Signed-off-by: Antony Kurniawan Soemardi <linux@smankusors.com>
> ---
>  arch/arm/boot/dts/qcom/qcom-msm8960.dtsi | 24 ++++++++++++++++++++++++
>  1 file changed, 24 insertions(+)
> 

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>


-- 
With best wishes
Dmitry

^ permalink raw reply

* Re: [PATCH 08/10] ARM: dts: qcom: msm8960: add SMSM & SPS
From: Dmitry Baryshkov @ 2026-04-18 16:53 UTC (permalink / raw)
  To: linux
  Cc: Bjorn Andersson, Michael Turquette, Stephen Boyd, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Lee Jones, Konrad Dybcio,
	Krzysztof Kozlowski, linux-arm-msm, linux-clk, devicetree,
	linux-kernel, phone-devel, Rudraksha Gupta
In-Reply-To: <20260414-msm8960-wifi-v1-8-007fda9d6134@smankusors.com>

On Tue, Apr 14, 2026 at 01:55:35AM +0700, Antony Kurniawan Soemardi via B4 Relay wrote:
> From: Antony Kurniawan Soemardi <linux@smankusors.com>
> 
> Add the Shared Memory State Machine node to coordinate state transitions
> between the Applications processor and the Riva subsystem.
> 
> Tested-by: Rudraksha Gupta <guptarud@gmail.com>
> Signed-off-by: Antony Kurniawan Soemardi <linux@smankusors.com>
> ---
>  arch/arm/boot/dts/qcom/qcom-msm8960.dtsi | 30 ++++++++++++++++++++++++++++++
>  1 file changed, 30 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi b/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi
> index 218cf3158dfb..107c5613aa4a 100644
> --- a/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi
> +++ b/arch/arm/boot/dts/qcom/qcom-msm8960.dtsi
> @@ -109,6 +109,31 @@ smem {
>  		hwlocks = <&sfpb_mutex 3>;
>  	};
>  
> +	smsm {
> +		compatible = "qcom,smsm";
> +
> +		#address-cells = <1>;
> +		#size-cells = <0>;
> +
> +		qcom,ipc-1 = <&l2cc 8 4>;
> +		qcom,ipc-2 = <&l2cc 8 14>;
> +		qcom,ipc-3 = <&l2cc 8 23>;
> +		qcom,ipc-4 = <&sps_sic_non_secure 0x4094 0>;
> +
> +		apps_smsm: apps@0 {
> +			reg = <0>;
> +			#qcom,smem-state-cells = <1>;
> +		};
> +
> +		wcnss_smsm: wcnss@3 {
> +			reg = <3>;
> +			interrupts = <GIC_SPI 204 IRQ_TYPE_EDGE_RISING>;
> +
> +			interrupt-controller;
> +			#interrupt-cells = <2>;
> +		};

Are there other SMSMs (modem, Q6, DSPS)? If so and if you are going to
send another revision, could you please add those?

Anyway,


Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>



> +	};
> +
>  	soc: soc {
>  		compatible = "simple-bus";
>  		ranges;
> @@ -455,6 +480,11 @@ clock-controller@4000000 {
>  				      "hdmipll";
>  		};
>  
> +		sps_sic_non_secure: interrupt-controller@12100000 {
> +			compatible = "qcom,msm8960-sps-sic", "syscon";

This one is exactly the same as the block on APQ8064.

> +			reg = <0x12100000 0x10000>;
> +		};
> +
>  		sdcc3: mmc@12180000 {
>  			compatible = "arm,pl18x", "arm,primecell";
>  			reg = <0x12180000 0x2000>;
> 
> -- 
> 2.34.1
> 
> 

-- 
With best wishes
Dmitry

^ permalink raw reply

* [PATCH v1 0/2] iio: adc: hx711: add HX710B support
From: Piyush Patle @ 2026-04-18 17:05 UTC (permalink / raw)
  To: jic23, ak, robh, krzk+dt, conor+dt; +Cc: linux-iio, devicetree, linux-kernel

Add support for the HX710B ADC, a variant of the HX711 with the same
GPIO interface but a different channel and gain model.

The first patch updates the devicetree binding to add the
`avia,hx710b` compatible and document the variant-specific behavior.
The second patch extends the driver with per-chip configuration, HX710B
channel selection through trailing pulse counts, and fixed-scale
handling for the variant.

Tested on PocketBeagle2 with an HX710B breakout module. The device
probed successfully and raw readings were stable.

Piyush Patle (2):
  dt-bindings: iio: adc: avia-hx711: add avia,hx710b compatible
  iio: adc: hx711: add support for HX710B

 .../bindings/iio/adc/avia-hx711.yaml          |  36 ++-
 drivers/iio/adc/Kconfig                       |   9 +-
 drivers/iio/adc/hx711.c                       | 222 ++++++++++++++----
 3 files changed, 214 insertions(+), 53 deletions(-)

-- 
2.43.0

^ permalink raw reply

* [PATCH v1 1/2] dt-bindings: iio: adc: avia-hx711: add avia,hx710b compatible
From: Piyush Patle @ 2026-04-18 17:05 UTC (permalink / raw)
  To: jic23, ak, robh, krzk+dt, conor+dt
  Cc: dlechner, nuno.sa, andy, linux-iio, devicetree, linux-kernel

Add the HX710B compatible to the binding and describe the variant-specific
channel and gain model.

Also add an example node for HX710B so the schema covers both supported
parts.

Signed-off-by: Piyush Patle <piyushpatle228@gmail.com>
---
 .../bindings/iio/adc/avia-hx711.yaml          | 36 +++++++++++++++----
 1 file changed, 30 insertions(+), 6 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/avia-hx711.yaml b/Documentation/devicetree/bindings/iio/adc/avia-hx711.yaml
index 9c57eb13f892..19318c4dd994 100644
--- a/Documentation/devicetree/bindings/iio/adc/avia-hx711.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/avia-hx711.yaml
@@ -4,7 +4,7 @@
 $id: http://devicetree.org/schemas/iio/adc/avia-hx711.yaml#
 $schema: http://devicetree.org/meta-schemas/core.yaml#
 
-title: AVIA HX711 ADC chip for weight cells
+title: AVIA HX711 and HX710B ADCs
 
 maintainers:
   - Andreas Klinger <ak@it-klinger.de>
@@ -12,9 +12,19 @@ maintainers:
 description: |
   Bit-banging driver using two GPIOs:
   - sck-gpio gives a clock to the sensor with 24 cycles for data retrieval
-    and up to 3 cycles for selection of the input channel and gain for the
-    next measurement
-  - dout-gpio is the sensor data the sensor responds to the clock
+    and 1 to 3 additional cycles for selection of the input channel and gain
+    for the next measurement
+  - dout-gpio is the sensor data output the sensor drives in response to
+    the clock
+
+  HX711: 24-bit ADC with selectable gain (32/64/128) and two differential
+  input channels. Channel A supports gain 64 and 128; channel B supports
+  gain 32.
+
+  HX710B: 24-bit ADC with fixed gain of 128. Channel 0 is the differential
+  input and channel 1 measures the DVDD-AVDD supply voltage difference.
+  Channel selection for the next conversion is controlled by the number of
+  trailing PD_SCK pulses.
 
   Specifications about the driver can be found at:
   http://www.aviaic.com/ENProducts.aspx
@@ -23,11 +33,12 @@ properties:
   compatible:
     enum:
       - avia,hx711
+      - avia,hx710b
 
   sck-gpios:
     description:
       Definition of the GPIO for the clock (output). In the datasheet it is
-      named PD_SCK
+      named PD_SCK.
     maxItems: 1
 
   dout-gpios:
@@ -43,6 +54,9 @@ properties:
       Definition of the regulator used as analog supply
 
   clock-frequency:
+    description:
+      Bit-bang clock frequency on PD_SCK. Keep the PD_SCK high time below
+      the chip power-down threshold.
     minimum: 20000
     maximum: 2500000
     default: 400000
@@ -58,10 +72,20 @@ additionalProperties: false
 examples:
   - |
     #include <dt-bindings/gpio/gpio.h>
-    weight {
+    /* HX711 example */
+    weight0 {
         compatible = "avia,hx711";
         sck-gpios = <&gpio3 10 GPIO_ACTIVE_HIGH>;
         dout-gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
         avdd-supply = <&avdd>;
         clock-frequency = <100000>;
     };
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+    /* HX710B example */
+    weight1 {
+        compatible = "avia,hx710b";
+        sck-gpios = <&gpio3 11 GPIO_ACTIVE_HIGH>;
+        dout-gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
+        avdd-supply = <&avdd>;
+    };
-- 
2.43.0


^ permalink raw reply related


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox