From patchwork Thu Jul 9 15:35:27 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 50974 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f72.google.com (mail-la0-f72.google.com [209.85.215.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 5AA89213FD for ; Thu, 9 Jul 2015 15:35:59 +0000 (UTC) Received: by lagc2 with SMTP id c2sf31348004lag.0 for ; Thu, 09 Jul 2015 08:35:57 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=c6JxZGDyWo36Nj0OaHXJk3qsqy4+iMY/Po/OT27+g0Q=; b=Ivo7tnzcysDlrsxQdK4bMuEBIbpkk3FPXV6QBB0zvcus3MLn8s/YiBXDgOiLhHCKsF RQT/lt9RdW83Z9zemwGX7oFUPM9q6sSQ2To1xRNscdnSxuHL69xnJs9EWufBrOPVoCGq GlQ3Ahps7VwANEzOQMrkF2z2vcszCVsXPfKIA0C/BOgeSOP7NlvN28UMtkPCIXUOJCr7 MRU6RcDHxIW4koGan9bk4kjgxnvPGzF1KTPbXhCr/ggEptti9W4Uq64/si9acmFGVsmf pEwqX6o9QIc5kZ6UxEhYtzw2ZhZQ2+pRot2DrNP+TSzZjrQvs7ApIbf2QEdq+6Kil8Ii jAhA== X-Gm-Message-State: ALoCoQkEaKAzPz/uQEflHSFaAADvM2bqglplbCYjp7mBO0Ol0nP3u8lTycdLeED/jbR5HMwGxdtw X-Received: by 10.180.89.231 with SMTP id br7mr24122661wib.0.1436456157873; Thu, 09 Jul 2015 08:35:57 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.5.67 with SMTP id q3ls1002302laq.78.gmail; Thu, 09 Jul 2015 08:35:57 -0700 (PDT) X-Received: by 10.112.167.202 with SMTP id zq10mr15083830lbb.118.1436456157590; Thu, 09 Jul 2015 08:35:57 -0700 (PDT) Received: from mail-la0-f44.google.com (mail-la0-f44.google.com. [209.85.215.44]) by mx.google.com with ESMTPS id c5si4765968lag.135.2015.07.09.08.35.57 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 09 Jul 2015 08:35:57 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.44 as permitted sender) client-ip=209.85.215.44; Received: by lagc2 with SMTP id c2so245799474lag.3 for ; Thu, 09 Jul 2015 08:35:57 -0700 (PDT) X-Received: by 10.112.198.74 with SMTP id ja10mr15458728lbc.19.1436456157499; Thu, 09 Jul 2015 08:35:57 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.108.230 with SMTP id hn6csp744138lbb; Thu, 9 Jul 2015 08:35:56 -0700 (PDT) X-Received: by 10.66.157.167 with SMTP id wn7mr32491903pab.119.1436456154257; Thu, 09 Jul 2015 08:35:54 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id pi2si9790109pbb.128.2015.07.09.08.35.53; Thu, 09 Jul 2015 08:35:54 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753350AbbGIPfw (ORCPT + 8 others); Thu, 9 Jul 2015 11:35:52 -0400 Received: from mail-wi0-f173.google.com ([209.85.212.173]:32912 "EHLO mail-wi0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751164AbbGIPfg (ORCPT ); Thu, 9 Jul 2015 11:35:36 -0400 Received: by wiwl6 with SMTP id l6so22398697wiw.0 for ; Thu, 09 Jul 2015 08:35:35 -0700 (PDT) X-Received: by 10.194.122.132 with SMTP id ls4mr29786937wjb.130.1436456135402; Thu, 09 Jul 2015 08:35:35 -0700 (PDT) Received: from localhost.localdomain (host86-178-207-130.range86-178.btcentralplus.com. [86.178.207.130]) by smtp.gmail.com with ESMTPSA id e7sm8822001wib.22.2015.07.09.08.35.33 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 09 Jul 2015 08:35:34 -0700 (PDT) From: Lee Jones To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: kernel@stlinux.com, broonie@kernel.org, lgirdwood@gmail.com, devicetree@vger.kernel.org, Lee Jones Subject: [PATCH 2/3] regulator: pwm-regulator: Remove obsoleted property Date: Thu, 9 Jul 2015 16:35:27 +0100 Message-Id: <1436456128-18278-2-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1436456128-18278-1-git-send-email-lee.jones@linaro.org> References: <1436456128-18278-1-git-send-email-lee.jones@linaro.org> Sender: devicetree-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: devicetree@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: lee.jones@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.44 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , In "[3d7ef30] regulator: pwm-regulator: Simplify voltage to duty-cycle call" we stopped using max_duty_cycle, so we can retire it from device data and DT. There is no need to deprecate this property, as it hasn't hit Mainline yet. Signed-off-by: Lee Jones --- Documentation/devicetree/bindings/regulator/pwm-regulator.txt | 11 ++++------- drivers/regulator/pwm-regulator.c | 9 --------- 2 files changed, 4 insertions(+), 16 deletions(-) diff --git a/Documentation/devicetree/bindings/regulator/pwm-regulator.txt b/Documentation/devicetree/bindings/regulator/pwm-regulator.txt index 23b4772..ed936f0 100644 --- a/Documentation/devicetree/bindings/regulator/pwm-regulator.txt +++ b/Documentation/devicetree/bindings/regulator/pwm-regulator.txt @@ -29,15 +29,14 @@ Required properties: - pwms: PWM specification (See: ../pwm/pwm.txt) -One of these must be provided: +Only required for Voltage Table Mode: - voltage-table: Voltage and Duty-Cycle table consisting of 2 cells First cell is voltage in microvolts (uV) Second cell is duty-cycle in percent (%) -- max-duty-cycle: Maximum Duty-Cycle value -- this will normally be - 255 (0xff) for an 8 bit PWM device - -If both are provided, the current default is voltage-table mode. +NB: To be clear, if voltage-table is provided, then the device will be used +in Voltage Table Mode. If no voltage-table is provided, then the device will +be used in Continuous Voltage Mode. Any property defined as part of the core regulator binding can also be used. (See: ../regulator/regulator.txt) @@ -49,8 +48,6 @@ Continuous Voltage Example: regulator-min-microvolt = <1016000>; regulator-max-microvolt = <1114000>; regulator-name = "vdd_logic"; - - max-duty-cycle = <255>; /* 8bit PWM */ }; Voltage Table Example: diff --git a/drivers/regulator/pwm-regulator.c b/drivers/regulator/pwm-regulator.c index cb48208..d92e667 100644 --- a/drivers/regulator/pwm-regulator.c +++ b/drivers/regulator/pwm-regulator.c @@ -30,7 +30,6 @@ struct pwm_regulator_data { int state; /* Continuous voltage */ - u32 max_duty_cycle; int volt_uV; }; @@ -201,14 +200,6 @@ static int pwm_regulator_init_continuous(struct platform_device *pdev, struct pwm_regulator_data *drvdata) { struct device_node *np = pdev->dev.of_node; - int ret; - - ret = of_property_read_u32(np, "max-duty-cycle", - &drvdata->max_duty_cycle); - if (ret) { - dev_err(&pdev->dev, "Failed to read \"pwm-max-value\"\n"); - return ret; - } pwm_regulator_desc.ops = &pwm_regulator_voltage_continuous_ops; pwm_regulator_desc.continuous_voltage_range = true;