From patchwork Thu Mar 21 15:59:28 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 15505 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 640AC23E14 for ; Thu, 21 Mar 2013 16:01:08 +0000 (UTC) Received: from mail-ve0-f181.google.com (mail-ve0-f181.google.com [209.85.128.181]) by fiordland.canonical.com (Postfix) with ESMTP id C664BA19E7C for ; Thu, 21 Mar 2013 16:01:07 +0000 (UTC) Received: by mail-ve0-f181.google.com with SMTP id pa12so1048465veb.12 for ; Thu, 21 Mar 2013 09:01:07 -0700 (PDT) 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=w2rlsYF5snLKDqaladGBW6eG9TpDGMRk9C/Q3vVsveI=; b=ZUs+PBiBYnBiQOoL3XX9updEKiejG9d0BIt7sFSrCEPg+NCAODTFE6WnbjyB0j5LSx hzI+9bSLd8WxWxwTgrRZ98ODe4cZk/lTglkjgU+MoW4u+PyqdSw4JI9chaHaflntTzjw gcPeH8Nay7yB/+2FJZBsrFBIJ3eadzdA46CcIsfRUGgWKAhXiVV5bLjTlMG7mwj8cvNl KqrxFpBwvJPFBMWptKRVldHOEsag8pZEFA0vB/cvhk/CkJT7O0FW12wAy0a0CAxfyGmE irsMAGCYpjLvwoE3kltXpeVz+glP+MS0y9KLMpcA0LY2IhUu2fMGfr3yuv+OFgokRGQl Sd0A== X-Received: by 10.52.233.225 with SMTP id tz1mr12447294vdc.54.1363881667231; Thu, 21 Mar 2013 09:01:07 -0700 (PDT) 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.233.198 with SMTP id ty6csp66809vec; Thu, 21 Mar 2013 09:01:06 -0700 (PDT) X-Received: by 10.194.71.110 with SMTP id t14mr97132wju.53.1363881665347; Thu, 21 Mar 2013 09:01:05 -0700 (PDT) Received: from mail-wi0-x22a.google.com ([2a00:1450:400c:c05::22a]) by mx.google.com with ESMTPS id ep8si1425168wid.80.2013.03.21.09.01.05 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 21 Mar 2013 09:01:05 -0700 (PDT) Received-SPF: neutral (google.com: 2a00:1450:400c:c05::22a is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) client-ip=2a00:1450:400c:c05::22a; Authentication-Results: mx.google.com; spf=neutral (google.com: 2a00:1450:400c:c05::22a 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-wi0-f170.google.com with SMTP id hm11so7412490wib.1 for ; Thu, 21 Mar 2013 09:01:05 -0700 (PDT) X-Received: by 10.180.109.82 with SMTP id hq18mr5809154wib.0.1363881664772; Thu, 21 Mar 2013 09:01:04 -0700 (PDT) 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 h10sm6110847wic.8.2013.03.21.09.01.02 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 21 Mar 2013 09:01:03 -0700 (PDT) From: Lee Jones To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, broonie@opensource.wolfsonmicro.com Cc: arnd@arndb.de, linus.walleij@stericsson.com, Rabin Vincent , Lee Jones Subject: [PATCH 31/46] regulator: ab8500: Don't register external regulators on AB8505 Date: Thu, 21 Mar 2013 15:59:28 +0000 Message-Id: <1363881583-15234-32-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1363881583-15234-1-git-send-email-lee.jones@linaro.org> References: <1363881583-15234-1-git-send-email-lee.jones@linaro.org> X-Gm-Message-State: ALoCoQkxF9wxZloTRRrWhyG+l4jH35SIKmJIesLt58MffFBYFjPP0NslIL2/NvIn5WGaMreU1pd/ From: Rabin Vincent ExtSupply regulators are not included on AB8505 based platforms. Signed-off-by: Rabin Vincent Signed-off-by: Lee Jones Tested-by: Marcus COOPER --- drivers/regulator/ab8500.c | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/drivers/regulator/ab8500.c b/drivers/regulator/ab8500.c index 840f23b..c1e1cf9 100644 --- a/drivers/regulator/ab8500.c +++ b/drivers/regulator/ab8500.c @@ -2767,10 +2767,12 @@ static int ab8500_regulator_probe(struct platform_device *pdev) return err; } - /* register external regulators (before Vaux1, 2 and 3) */ - err = ab8500_ext_regulator_init(pdev); - if (err) - return err; + if (!is_ab8505(ab8500)) { + /* register external regulators (before Vaux1, 2 and 3) */ + err = ab8500_ext_regulator_init(pdev); + if (err) + return err; + } /* register all regulators */ for (i = 0; i < regulator_info_size; i++) { @@ -2812,10 +2814,12 @@ static int ab8500_regulator_remove(struct platform_device *pdev) regulator_unregister(info->regulator); } - /* remove external regulators (after Vaux1, 2 and 3) */ - err = ab8500_ext_regulator_exit(pdev); - if (err) - return err; + if (!is_ab8505(ab8500)) { + /* remove external regulators (after Vaux1, 2 and 3) */ + err = ab8500_ext_regulator_exit(pdev); + if (err) + return err; + } /* remove regulator debug */ err = ab8500_regulator_debug_exit(pdev);