From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-ot1-f47.google.com (mail-ot1-f47.google.com [209.85.210.47]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A01C617C992 for ; Mon, 19 Aug 2024 16:48:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.47 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724086129; cv=none; b=O3N9KJ1ET87Y4n8Cv6oRchjGklLSTOk5qlUlsYXuLBwsvSzIVi6ehBM5H2bKAW8ksy9IJaT/9Cx5FHxvyoSwmesPvgvCryt0iL0DWodjEtBlv58Z9g4b+OrumpQ7YHYTrEOrkXhiuUCDRQBSyPKhjvaTP39omhfwmXlFUpu5A4o= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1724086129; c=relaxed/simple; bh=V/didJfH9Mli5oAKhwkzsu03vK9Kmk0ArxEypPCD82w=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=BqQhBOQwYCdqbX64ttk5yP0FDx75PWCjul2hUvsSGCmrpaT0lkwSkEMM+KH/4XYtoQ8AdMk/g92lfVwlx6pEZneGXOYbvwVEOsdT3RIzbmLY1EyoNx9yF1FK6aDtMVnVijEwqHMsMrBTw523AcRQy3evH6b+BxqzO6G134Q19sM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=dxLubRsb; arc=none smtp.client-ip=209.85.210.47 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="dxLubRsb" Received: by mail-ot1-f47.google.com with SMTP id 46e09a7af769-7093ba310b0so1929397a34.2 for ; Mon, 19 Aug 2024 09:48:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1724086126; x=1724690926; darn=lists.linux.dev; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=LDis15Hzp2Vx+5TQlBnC0YVroTqVlccFthHOCI8Z73Q=; b=dxLubRsb4hpsy4qIRgquuOFl3/0zSiZOHPXukyJEU/FpaGXKjt2MVvGa6wrNIZP5u/ bQImZSH+kDEOqZlMlUjugSKxogBJ/y9Ga6ANzbVV6AZbZvynunDoMLFGQWt3G8SRnaB+ EfwxK3ubZWMf1A5WODIe1sBR3852TjYYcx6esRNXK5EcbA4gFSdxq3uEOteKKG1IZo/8 NyCDzlGKGlzNaBmCw/00QodpNmNgFhSEN6alLpMyWOy5Nst4HHnvJvhZ8F4jALxbVVoh XVtAm1mCYUxDwxFwcUtD0gBxheVwyx2oKPpyII2lOOCqc7OgbS6kKz5nEXgk0TZfVBDE 8W4w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724086126; x=1724690926; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LDis15Hzp2Vx+5TQlBnC0YVroTqVlccFthHOCI8Z73Q=; b=RxP6J7oQk5yCWOw2DZyubWZLZ3Yxfxa1nBcA9W9iWDSXJ6AtACfAR+D7Pku1A9/3yI AnA4Rbpwb1nSizPzGR1y5vNbxMXoAuVoUJ7aLzgwDRexcFA0r0Mf135BEZ/rr5NtONi2 8nrXRbizVLEyHyXFsqBiF1CH1khsYZNpzmcZLhwqlpkvqlDzre3fF6q6MEPrsbnp5D5N fioYmsIwveasXS+SloVxZ3mvfmtKjaq5NDi04JVFqXNX7qPl8seltxKA1DWFmB9DGPTt vzj9r7AaBUihllahqOCK4wf7s0FNoN3eywRGX6d26080i642GXU2OQGq9h+DfQarcVHS 5NYw== X-Gm-Message-State: AOJu0Yy7nFu75VeO+K6qSWgpWILJbOH/GYBjA9qpbfoW0zEttwXz/mtN 9qztOpY1ep8MdvoPVmz4bj3TBSufQOImCiTXffH8z/sk92qTc4G1HAVfuQ== X-Google-Smtp-Source: AGHT+IHJmQOitznYw7nxXig16L2gz0qkKmEqys1jVwJ8LH/stIDVmGhzuz59B5CSI59rRM0lCJakKQ== X-Received: by 2002:a05:6830:448a:b0:70c:a547:1c3c with SMTP id 46e09a7af769-70cac83c080mr14115806a34.5.1724086126620; Mon, 19 Aug 2024 09:48:46 -0700 (PDT) Received: from localhost.localdomain ([2600:1700:fb0:1bcf::54]) by smtp.gmail.com with ESMTPSA id 46e09a7af769-70ca649c61csm2332428a34.26.2024.08.19.09.48.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Aug 2024 09:48:46 -0700 (PDT) From: Chris Morgan To: linux-sunxi@lists.linux.dev Cc: linux-pm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-iio@vger.kernel.org, quentin.schulz@free-electrons.com, mripard@kernel.org, tgamblin@baylibre.com, aidanmacdonald.0x0@gmail.com, u.kleine-koenig@pengutronix.de, lee@kernel.org, samuel@sholland.org, jernej.skrabec@gmail.com, sre@kernel.org, wens@csie.org, conor+dt@kernel.org, krzk+dt@kernel.org, robh@kernel.org, lars@metafoo.de, jic23@kernel.org, jonathan.cameron@huawei.com, Chris Morgan Subject: [PATCH V3 05/15] dt-bindings: power: supply: axp20x: Add input-current-limit-microamp Date: Mon, 19 Aug 2024 11:46:09 -0500 Message-Id: <20240819164619.556309-6-macroalpha82@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240819164619.556309-1-macroalpha82@gmail.com> References: <20240819164619.556309-1-macroalpha82@gmail.com> Precedence: bulk X-Mailing-List: linux-sunxi@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: Chris Morgan Allow specifying a hard limit of the maximum input current. Some PMICs such as the AXP717 can pull up to 3.25A, so allow a value to be specified that clamps this in the event the hardware is not designed for it. Signed-off-by: Chris Morgan --- .../x-powers,axp20x-usb-power-supply.yaml | 69 ++++++++++++++++++- 1 file changed, 66 insertions(+), 3 deletions(-) diff --git a/Documentation/devicetree/bindings/power/supply/x-powers,axp20x-usb-power-supply.yaml b/Documentation/devicetree/bindings/power/supply/x-powers,axp20x-usb-power-supply.yaml index 34b7959d6772..9cc300e78f60 100644 --- a/Documentation/devicetree/bindings/power/supply/x-powers,axp20x-usb-power-supply.yaml +++ b/Documentation/devicetree/bindings/power/supply/x-powers,axp20x-usb-power-supply.yaml @@ -15,9 +15,6 @@ maintainers: - Chen-Yu Tsai - Sebastian Reichel -allOf: - - $ref: power-supply.yaml# - properties: compatible: oneOf: @@ -31,8 +28,74 @@ properties: - const: x-powers,axp803-usb-power-supply - const: x-powers,axp813-usb-power-supply + input-current-limit-microamp: + description: + Optional value to clamp the maximum input current limit to for + the device. If omitted, the programmed value from the EFUSE will + be used. required: - compatible +allOf: + - $ref: power-supply.yaml# + - if: + properties: + compatible: + contains: + enum: + - x-powers,axp192-usb-power-supply + then: + properties: + input-current-limit-microamp: + enum: [100000, 500000] + + - if: + properties: + compatible: + contains: + enum: + - x-powers,axp202-usb-power-supply + - x-powers,axp223-usb-power-supply + then: + properties: + input-current-limit-microamp: + enum: [100000, 500000, 900000] + + - if: + properties: + compatible: + contains: + enum: + - x-powers,axp221-usb-power-supply + then: + properties: + input-current-limit-microamp: + enum: [500000, 900000] + + - if: + properties: + compatible: + contains: + enum: + - x-powers,axp717-usb-power-supply + then: + properties: + input-current-limit-microamp: + description: Maximum input current in increments of 50000 uA. + minimum: 100000 + maximum: 3250000 + + - if: + properties: + compatible: + contains: + enum: + - x-powers,axp813-usb-power-supply + then: + properties: + input-current-limit-microamp: + enum: [100000, 500000, 900000, 1500000, 2000000, 2500000, + 3000000, 3500000, 4000000] + additionalProperties: false -- 2.34.1