From patchwork Tue Jun 3 18:27:45 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Kayode via B4 Relay X-Patchwork-Id: 894100 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 85FEB288C8A; Tue, 3 Jun 2025 18:27:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1748975278; cv=none; b=h71xnQSyuys6cnvxOpGvLS7ZjOTgG6fBtAKfmgKWYgRgIsAAfo2aYOCa46puHDun5OAwPIXnHR+phmjXy0leMfDFZnOEuWCvWXzJkfCMZiTXD/XQJXGrWC9J4goh6wWwKO8eX+5ck63TvwKTODuw59Z0TIsPXnJu8L8clcd0yBc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1748975278; c=relaxed/simple; bh=6Hb65QoBWOuelj3WUTD6CUgcvo7Wmh0qrkmu8gd0ji4=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=AFmb/BOd+KSMDoF4y/ZHSlDo7XZknDbhOTASFfsL6CPgRVVR57uUfMT5pV8eLmZmK65ovwG4wxWtdK87HqO1NIgUU4ao8vVLn712qQoP2rYB9SNZUH2wwG/MW5LSYxC+KeDCW3tbxhcLTwoGOaabHqmQNp0wys7aIslSGM3y4Bc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=fXaFENXA; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="fXaFENXA" Received: by smtp.kernel.org (Postfix) with ESMTPS id 06B20C4CEEF; Tue, 3 Jun 2025 18:27:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1748975278; bh=6Hb65QoBWOuelj3WUTD6CUgcvo7Wmh0qrkmu8gd0ji4=; h=From:Date:Subject:References:In-Reply-To:To:Cc:Reply-To:From; b=fXaFENXAjNK9itqxOzRk6ZZii+6QxcOSOXIa1wu3NN+hG8KC3U2LNC4hoZRpLExEh quukE6KIxw4yF2RqyFngkX11BS4MVX0LTx45c8CfHiFZ5YEqOC3mY2vR5F4hcRNLW3 Jq2KxGoE8s9S2JCZdPfDGui3ayEOtOHYqzsBYe43tLVuahjCUuK+BA9njB9m1kh5FX zpm4XwTzr/rOpZYOXg0YJ3zOvh56wTFUs/9Jnf+tT0/+VntIlxIPgQePJ902NaXl4n QBCUKYgKFAAVoU5h6ZfHaPQyCPr2H/n2zzHON39kiuuLMpCuk0KIIVp4lYZo5bst7s bVBYHSKtBHKgQ== Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id E8887C5B552; Tue, 3 Jun 2025 18:27:57 +0000 (UTC) From: Samuel Kayode via B4 Relay Date: Tue, 03 Jun 2025 14:27:45 -0400 Subject: [PATCH v4 1/6] dt-bindings: mfd: add pf1550 Precedence: bulk X-Mailing-List: linux-input@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250603-pf1550-v4-1-bfdf51ee59cc@savoirfairelinux.com> References: <20250603-pf1550-v4-0-bfdf51ee59cc@savoirfairelinux.com> In-Reply-To: <20250603-pf1550-v4-0-bfdf51ee59cc@savoirfairelinux.com> To: Lee Jones , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Liam Girdwood , Mark Brown , Dmitry Torokhov , Sebastian Reichel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-input@vger.kernel.org, linux-pm@vger.kernel.org, Abel Vesa , Abel Vesa , Robin Gong , Enric Balletbo i Serra , Samuel Kayode X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1748975277; l=5637; i=samuel.kayode@savoirfairelinux.com; s=20250527; h=from:subject:message-id; bh=/LjZpIGyyBmQxRSfMbmf+8phLgZ3fhYVZkvqK2HSnGg=; b=g+HZtsREbSuPTJ2VArnUlTN1ZxUHppd6wD/vSX5hGt0v3ReHYSpVsNDgA2KJNJL9/db0D02h0 UVv7FjsxbMVARWM6deoob7zefaYwe4YNgoKnh7BST6c6449v+i1zjeW X-Developer-Key: i=samuel.kayode@savoirfairelinux.com; a=ed25519; pk=TPSQGQ5kywnnPyGs0EQqLajLFbdDu17ahXz8/gxMfio= X-Endpoint-Received: by B4 Relay for samuel.kayode@savoirfairelinux.com/20250527 with auth_id=412 X-Original-From: Samuel Kayode Reply-To: samuel.kayode@savoirfairelinux.com From: Samuel Kayode Add a DT binding document for pf1550 PMIC. This describes the core mfd device along with its children: regulators, charger and onkey. Signed-off-by: Samuel Kayode --- v4: - Address Krzystof's feedback: - Filename changed to nxp,pf1550.yaml - Replace Freescale with NXP - Define include before battery-cell - Drop operating-range-celsius in example since nxp,thermal-regulation-celsisus already exists - Not sure if there is similar binding to thermal-regulation... for regulating temperature on thermal-zones? @Sebastian and @Krzysztof v3: - Address Krzysztof's feedback: - Fold charger and onkey objects - Drop compatible for sub-devices: onkey, charger and regulator. - Drop constant voltage property already included in monitored-battery - Fix whitespace warnings - Fix license v2: - Add yamls for the PMIC and the sub-devices --- .../devicetree/bindings/mfd/nxp,pf1550.yaml | 139 +++++++++++++++++++++ 1 file changed, 139 insertions(+) diff --git a/Documentation/devicetree/bindings/mfd/nxp,pf1550.yaml b/Documentation/devicetree/bindings/mfd/nxp,pf1550.yaml new file mode 100644 index 0000000000000000000000000000000000000000..add895311b892a6731f54e47fcaaba8dfdac14b3 --- /dev/null +++ b/Documentation/devicetree/bindings/mfd/nxp,pf1550.yaml @@ -0,0 +1,139 @@ +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/mfd/nxp,pf1550.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: NXP PF1550 Power Management IC + +maintainers: + - Samuel Kayode + +description: | + PF1550 PMIC provides battery charging and power supply for low power IoT and + wearable applications. This device consists of an i2c controlled MFD that + includes regulators, battery charging and an onkey/power button. + +$ref: /schemas/power/supply/power-supply.yaml + +properties: + compatible: + const: nxp,pf1550 + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + wakeup-source: true + + regulators: + type: object + + patternProperties: + "^(ldo[1-3]|sw[1-3]|vrefddr)$": + type: object + $ref: /schemas/regulator/regulator.yaml + description: + regulator configuration for ldo1-3, buck converters(sw1-3) + and DDR termination reference voltage (vrefddr) + unevaluatedProperties: false + + additionalProperties: false + + monitored-battery: + $ref: /schemas/types.yaml#/definitions/phandle + description: | + A phandle to a monitored battery node that contains a valid value + for: + constant-charge-voltage-max-microvolt. + + nxp,thermal-regulation-celsius: + description: + Temperature threshold for thermal regulation of charger in celsius. + enum: [ 60, 75, 90, 105 ] + + nxp,min-system-microvolt: + description: + System specific lower limit voltage. + enum: [ 3500000, 3700000, 4300000 ] + +required: + - compatible + - reg + - interrupts + +additionalProperties: false + +examples: + - | + #include + #include + + battery: battery-cell { + compatible = "simple-battery"; + constant-charge-voltage-max-microvolt = <4400000>; + }; + + i2c { + #address-cells = <1>; + #size-cells = <0>; + + pmic@8 { + compatible = "nxp,pf1550"; + reg = <0x8>; + + interrupt-parent = <&gpio1>; + interrupts = <2 IRQ_TYPE_LEVEL_LOW>; + wakeup-source; + monitored-battery = <&battery>; + nxp,min-system-microvolt = <4300000>; + nxp,thermal-regulation-celsius = <75>; + + regulators { + sw1_reg: sw1 { + regulator-name = "sw1"; + regulator-min-microvolt = <600000>; + regulator-max-microvolt = <1387500>; + regulator-always-on; + regulator-ramp-delay = <6250>; + }; + + sw2_reg: sw2 { + regulator-name = "sw2"; + regulator-min-microvolt = <600000>; + regulator-max-microvolt = <1387500>; + regulator-always-on; + }; + + sw3_reg: sw3 { + regulator-name = "sw3"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <3300000>; + regulator-always-on; + }; + + vldo1_reg: ldo1 { + regulator-name = "ldo1"; + regulator-min-microvolt = <750000>; + regulator-max-microvolt = <3300000>; + regulator-always-on; + }; + + vldo2_reg: ldo2 { + regulator-name = "ldo2"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <3300000>; + regulator-always-on; + }; + + vldo3_reg: ldo3 { + regulator-name = "ldo3"; + regulator-min-microvolt = <750000>; + regulator-max-microvolt = <3300000>; + regulator-always-on; + }; + }; + }; + };