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: 921122 X-Patchwork-Delegate: me@felipebalbi.com Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.4) with ESMTP id p5RF2Ls7017096 for ; Mon, 27 Jun 2011 15:02:21 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751170Ab1F0PCU (ORCPT ); Mon, 27 Jun 2011 11:02:20 -0400 Received: from mail-pv0-f174.google.com ([74.125.83.174]:43278 "EHLO mail-pv0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751242Ab1F0PCT (ORCPT ); Mon, 27 Jun 2011 11:02:19 -0400 Received: by pvg12 with SMTP id 12so2903557pvg.19 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> Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Mon, 27 Jun 2011 15:02:22 +0000 (UTC) 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 = {