From patchwork Wed Feb 6 10:54:09 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 14624 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 9FB592423C for ; Wed, 6 Feb 2013 10:56:14 +0000 (UTC) Received: from mail-vb0-f48.google.com (mail-vb0-f48.google.com [209.85.212.48]) by fiordland.canonical.com (Postfix) with ESMTP id 59178A187B7 for ; Wed, 6 Feb 2013 10:56:14 +0000 (UTC) Received: by mail-vb0-f48.google.com with SMTP id fc21so733070vbb.21 for ; Wed, 06 Feb 2013 02:56:13 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:x-forwarded-to:x-forwarded-for:delivered-to:x-received :received-spf:x-received:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references:x-gm-message-state; bh=VQhyldiTgLWcOy/WcMP/72rDAYn99JY61OyS8DT5XEU=; b=AKjMSbEd+7EXeLq49O3EHCoRO3mSCqQE+8xm5vHgZaI/I1sTGibnsWq+TlhrciVK88 bZTMW2A+zt4lFe2ki4P/lptHpfoPZQiFSaAtPqi4JF5piJUhe3lYP5pvQE8ZxI4kOS0K panklDnZAPiWOQT4TL+mBVNxtReIb2A24OuT/X6a3MO6+SOqmo9FznPQdW47DmD2hVDR jqPPtujDBDR+ly4UbRs6M9+Igy283/C251OSFKxOyuXJn33lsI/J1ugt8dEQKRYUCwKx EFEywrSMrcVDtHSKblOGLqNvBbrcb/PhT4rOWwpVFJmQYahjxf02hvujpOgjdMMOK0hz UeGg== X-Received: by 10.52.21.146 with SMTP id v18mr27871637vde.79.1360148173894; Wed, 06 Feb 2013 02:56:13 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.58.252.8 with SMTP id zo8csp13022vec; Wed, 6 Feb 2013 02:56:10 -0800 (PST) X-Received: by 10.194.19.170 with SMTP id g10mr48836444wje.56.1360148123556; Wed, 06 Feb 2013 02:55:23 -0800 (PST) Received: from mail-we0-x236.google.com ([2a00:1450:400c:c03::236]) by mx.google.com with ESMTPS id dg4si502474wib.104.2013.02.06.02.55.23 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 06 Feb 2013 02:55:23 -0800 (PST) Received-SPF: neutral (google.com: 2a00:1450:400c:c03::236 is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) client-ip=2a00:1450:400c:c03::236; Authentication-Results: mx.google.com; spf=neutral (google.com: 2a00:1450:400c:c03::236 is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) smtp.mail=lee.jones@linaro.org Received: by mail-we0-f182.google.com with SMTP id t57so1039020wey.13 for ; Wed, 06 Feb 2013 02:55:23 -0800 (PST) X-Received: by 10.194.242.69 with SMTP id wo5mr48837046wjc.10.1360148123086; Wed, 06 Feb 2013 02:55:23 -0800 (PST) Received: from localhost.localdomain (cpc34-aztw25-2-0-cust250.18-1.cable.virginmedia.com. [86.16.136.251]) by mx.google.com with ESMTPS id be1sm2406649wib.10.2013.02.06.02.55.22 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 06 Feb 2013 02:55:22 -0800 (PST) From: Lee Jones To: linux-kernel@vger.kernel.org Cc: broonie@opensource.wolfsonmicro.com, linus.walleij@linaro.org, Lee Jones Subject: [PATCH 47/49] regulator: ab8500: Remove the need for a 'delay' property Date: Wed, 6 Feb 2013 10:54:09 +0000 Message-Id: <1360148051-7560-48-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1360148051-7560-1-git-send-email-lee.jones@linaro.org> References: <1360148051-7560-1-git-send-email-lee.jones@linaro.org> X-Gm-Message-State: ALoCoQln6HOyPsCLAT7GSo87BK3GAYbjXFHkfiNzcuDh9TuDXHPvwrrnJFOvB63E4ECwrp1Q3Yhi The regulator framework now has provisions to read a regulator's start-up time via the 'enable_time' attribute. So let's remove all 'enable_time'/'delay' duplication and just stick with 'enable_time' from now on. Signed-off-by: Lee Jones --- drivers/regulator/ab8500.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/regulator/ab8500.c b/drivers/regulator/ab8500.c index 791a442..ee7ce92 100644 --- a/drivers/regulator/ab8500.c +++ b/drivers/regulator/ab8500.c @@ -63,7 +63,6 @@ struct ab8500_shared_mode { * @voltage_reg: register to control regulator voltage * @voltage_mask: mask to control regulator voltage * @voltage_shift: shift to control regulator voltage - * @delay: startup/set voltage delay in us */ struct ab8500_regulator_info { struct device *dev; @@ -87,7 +86,6 @@ struct ab8500_regulator_info { u8 voltage_reg; u8 voltage_mask; u8 voltage_shift; - unsigned int delay; struct { u8 voltage_limit; u8 voltage_bank; @@ -652,7 +650,7 @@ static int ab8500_regulator_set_voltage_time_sel(struct regulator_dev *rdev, { struct ab8500_regulator_info *info = rdev_get_drvdata(rdev); - return info->delay; + return info->desc.enable_time; } static struct regulator_ops ab8500_regulator_volt_mode_ops = { @@ -829,7 +827,6 @@ static struct ab8500_regulator_info .volt_table = fixed_2000000_voltage, .enable_time = 500, }, - .delay = 500, .load_lp_uA = 1000, .update_bank = 0x03, .update_reg = 0x80, @@ -1099,7 +1096,6 @@ static struct ab8500_regulator_info .volt_table = fixed_2000000_voltage, .enable_time = 10000, }, - .delay = 10000, .load_lp_uA = 1000, .update_bank = 0x03, .update_reg = 0x80, @@ -1364,7 +1360,6 @@ static struct ab8500_regulator_info .volt_table = fixed_2000000_voltage, .enable_time = 10000, }, - .delay = 10000, .load_lp_uA = 1000, .update_bank = 0x03, .update_reg = 0x80, @@ -1662,7 +1657,6 @@ static struct ab8500_regulator_info .n_voltages = 1, .enable_time = 10000, }, - .delay = 10000, .load_lp_uA = 1000, .update_bank = 0x03, .update_reg = 0x80,