From patchwork Sat Nov 1 03:52:58 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Doug Anderson X-Patchwork-Id: 5208421 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 61FF59F2F0 for ; Sat, 1 Nov 2014 03:57:05 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 87A5E2015A for ; Sat, 1 Nov 2014 03:57:04 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C164120158 for ; Sat, 1 Nov 2014 03:57:03 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1XkPl7-0002QG-4B; Sat, 01 Nov 2014 03:53:49 +0000 Received: from mail-ig0-x236.google.com ([2607:f8b0:4001:c05::236]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1XkPky-0002MQ-8E for linux-arm-kernel@lists.infradead.org; Sat, 01 Nov 2014 03:53:40 +0000 Received: by mail-ig0-f182.google.com with SMTP id hn18so2045641igb.3 for ; Fri, 31 Oct 2014 20:53:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=nBcd5LkR0KllVb90C94zMmueptk0Z9sebeqKbASqLzU=; b=f+lVWfQn9m49pJJiGHW2jkQzRAdbYPLW7i5GRG7xt26rCr0XeRw9iOuygFLGbwlToY InQb3hVxUxREBrAC+OU+kJQB/YNcjt74Ud5ewwjTv2orSUXC+X5R2UP3sPx+IVohDGgf TAMGV+JU+FM/LCoJOhgnK0nh0bJJQNVU6LO98= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=nBcd5LkR0KllVb90C94zMmueptk0Z9sebeqKbASqLzU=; b=AFc8Omo/mARKtZ/YO/5pCPbUVWsDumzeiHhHtJvdzo4GiQt0Aa6gNzz6qdKhnuyxfk m+xRId8WUCtmSINBXtXOudZmEbTzHbhsTLb9+D8jUlCKVFeDHMOJx+ZpOLBLLZkaiyXX jyTkBwSu/6n6PWggqziWDIW9pN3eiGDvji7+7kWGAg3nin3PkXfZyf9AiriHC+zq+VwN QHWxNRtcewo6xkRY7dgQW17lhwG4N4au3EBobLu3SOiJLb6vVrVJGRvgUTJwy+XhTYdE rCiyfIFN8z2B5G3G3cMEFa4rTtH/eDWspG3pBl1OqmTJozE5BSshdhRO3LpFZ5YVTLXZ L6ww== X-Gm-Message-State: ALoCoQn24dRNcO4TxulqnkCBkqwrxEghg2f6xwakbDBWUQnqvPzPLL62uLfXrZ1k/NpYIpfdeULj X-Received: by 10.43.148.74 with SMTP id kf10mr28599960icc.9.1414813997949; Fri, 31 Oct 2014 20:53:17 -0700 (PDT) Received: from tictac.mtv.corp.google.com ([172.22.65.76]) by mx.google.com with ESMTPSA id o130sm6153414ioo.42.2014.10.31.20.53.16 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 31 Oct 2014 20:53:17 -0700 (PDT) From: Doug Anderson To: Mark Brown Subject: [PATCH 2/2] regulator: of: Add support for parsing microvolts for suspend state Date: Fri, 31 Oct 2014 20:52:58 -0700 Message-Id: <1414813978-32233-2-git-send-email-dianders@chromium.org> X-Mailer: git-send-email 2.1.0.rc2.206.gedb03e5 In-Reply-To: <1414813978-32233-1-git-send-email-dianders@chromium.org> References: <1414813978-32233-1-git-send-email-dianders@chromium.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20141031_205340_395148_8D0B1702 X-CRM114-Status: UNSURE ( 9.75 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.1 (/) Cc: Heiko Stuebner , linux-rockchip@lists.infradead.org, Andrew Bresticker , linux-kernel@vger.kernel.org, Doug Anderson , lgirdwood@gmail.com, Chanwoo Choi , Kyungmin Park , Chris Zhong , javier.martinez@collabora.co.uk, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-2.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_NONE,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Leverage all the work that was done in (40e20d6 regulator: of: Add support for parsing regulator_state for suspend state) and throw in the ability to set suspend microvolts from the device tree. Signed-off-by: Doug Anderson Reviewed-by: Javier Martinez Canillas Reviewed-by: Chris Zhong --- drivers/regulator/of_regulator.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/regulator/of_regulator.c b/drivers/regulator/of_regulator.c index f0d19fc..7fe93c5 100644 --- a/drivers/regulator/of_regulator.c +++ b/drivers/regulator/of_regulator.c @@ -107,6 +107,10 @@ static void of_get_regulation_constraints(struct device_node *np, "regulator-off-in-suspend")) suspend_state->disabled = true; + if (!of_property_read_u32(suspend_np, + "regulator-suspend-microvolt", &pval)) + suspend_state->uV = pval; + of_node_put(suspend_np); suspend_state = NULL; suspend_np = NULL;