From patchwork Mon Jun 27 15:02:03 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jassi Brar X-Patchwork-Id: 2329 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 C233423F18 for ; Mon, 27 Jun 2011 15:02:23 +0000 (UTC) Received: from mail-qy0-f180.google.com (mail-qy0-f180.google.com [209.85.216.180]) by fiordland.canonical.com (Postfix) with ESMTP id 8DA39A187A7 for ; Mon, 27 Jun 2011 15:02:23 +0000 (UTC) Received: by qyk30 with SMTP id 30so3419343qyk.11 for ; Mon, 27 Jun 2011 08:02:23 -0700 (PDT) Received: by 10.229.102.98 with SMTP id f34mr1702462qco.42.1309186942749; Mon, 27 Jun 2011 08:02:22 -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.229.48.135 with SMTP id r7cs43939qcf; Mon, 27 Jun 2011 08:02:21 -0700 (PDT) Received: by 10.150.72.10 with SMTP id u10mr7089619yba.383.1309186940121; Mon, 27 Jun 2011 08:02:20 -0700 (PDT) Received: from mail-pv0-f178.google.com (mail-pv0-f178.google.com [74.125.83.178]) by mx.google.com with ESMTPS id e2si11830213ybg.75.2011.06.27.08.02.19 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 27 Jun 2011 08:02:20 -0700 (PDT) Received-SPF: neutral (google.com: 74.125.83.178 is neither permitted nor denied by best guess record for domain of jaswinder.singh@linaro.org) client-ip=74.125.83.178; Authentication-Results: mx.google.com; spf=neutral (google.com: 74.125.83.178 is neither permitted nor denied by best guess record for domain of jaswinder.singh@linaro.org) smtp.mail=jaswinder.singh@linaro.org Received: by pvg7 with SMTP id 7so3351183pvg.37 for ; Mon, 27 Jun 2011 08:02:18 -0700 (PDT) Received: by 10.68.39.3 with SMTP id l3mr3312123pbk.488.1309186938692; Mon, 27 Jun 2011 08:02:18 -0700 (PDT) Received: from localhost.localdomain ([122.167.86.144]) by mx.google.com with ESMTPS id g8sm4369634pba.53.2011.06.27.08.02.14 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 27 Jun 2011 08:02:17 -0700 (PDT) From: Jassi Brar To: linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: broonie@opensource.wolfsonmicro.com, lrg@ti.com, patches@linaro.org, balbi@ti.com, tony@atomide.com, Jassi Brar Subject: [PATCHv2] OMAP4: PANDA, SDP: Fix EHCI regulator supply Date: Mon, 27 Jun 2011 20:32:03 +0530 Message-Id: <1309186923-29192-1-git-send-email-jaswinder.singh@linaro.org> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1308926240-13888-1-git-send-email-jaswinder.singh@linaro.org> References: <1308926240-13888-1-git-send-email-jaswinder.singh@linaro.org> VUSB is a fixed level line and hence have no set_voltage callback in regulator ops, but has apply_uV set to true. As a result it fails to register with the regulator core. Remove setting apply_uV. Also, assign name to VUSB supply, without which regulator core fails to find it and assigns the default 'dummy' regulator to the ehci-omap device. Signed-off-by: Jassi Brar Reviewed-by: Felipe Balbi --- arch/arm/mach-omap2/board-4430sdp.c | 7 ++++++- arch/arm/mach-omap2/board-omap4panda.c | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-omap2/board-4430sdp.c b/arch/arm/mach-omap2/board-4430sdp.c index 63de2d3..9493cd3 100644 --- a/arch/arm/mach-omap2/board-4430sdp.c +++ b/arch/arm/mach-omap2/board-4430sdp.c @@ -504,16 +504,21 @@ static struct regulator_init_data sdp4430_vdac = { }, }; +static struct regulator_consumer_supply sdp4430_vusb_supply[] = { + REGULATOR_SUPPLY("hsusb0", "ehci-omap.0"), +}; + static struct regulator_init_data sdp4430_vusb = { .constraints = { .min_uV = 3300000, .max_uV = 3300000, - .apply_uV = true, .valid_modes_mask = REGULATOR_MODE_NORMAL | REGULATOR_MODE_STANDBY, .valid_ops_mask = REGULATOR_CHANGE_MODE | REGULATOR_CHANGE_STATUS, }, + .num_consumer_supplies = ARRAY_SIZE(sdp4430_vusb_supply), + .consumer_supplies = sdp4430_vusb_supply, }; static struct regulator_init_data sdp4430_clk32kg = { diff --git a/arch/arm/mach-omap2/board-omap4panda.c b/arch/arm/mach-omap2/board-omap4panda.c index d4f9879..2beb0d5 100644 --- a/arch/arm/mach-omap2/board-omap4panda.c +++ b/arch/arm/mach-omap2/board-omap4panda.c @@ -362,16 +362,21 @@ static struct regulator_init_data omap4_panda_vdac = { }, }; +static struct regulator_consumer_supply omap4_panda_vusb_supply[] = { + REGULATOR_SUPPLY("hsusb0", "ehci-omap.0"), +}; + static struct regulator_init_data omap4_panda_vusb = { .constraints = { .min_uV = 3300000, .max_uV = 3300000, - .apply_uV = true, .valid_modes_mask = REGULATOR_MODE_NORMAL | REGULATOR_MODE_STANDBY, .valid_ops_mask = REGULATOR_CHANGE_MODE | REGULATOR_CHANGE_STATUS, }, + .num_consumer_supplies = ARRAY_SIZE(omap4_panda_vusb_supply), + .consumer_supplies = omap4_panda_vusb_supply, }; static struct regulator_init_data omap4_panda_clk32kg = {