From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mark Brown Subject: Re: [PATCH v3] mmc_spi.c: add support for the regulator framework Date: Wed, 11 May 2011 22:57:04 +0200 Message-ID: <20110511205703.GA24486@opensource.wolfsonmicro.com> References: <1303476191-20663-1-git-send-email-ospite@studenti.unina.it> <1305110379-17218-1-git-send-email-ospite@studenti.unina.it> <20110511130852.GB12469@opensource.wolfsonmicro.com> <20110511225337.094839a2.ospite@studenti.unina.it> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: linux-mmc@vger.kernel.org, Chris Ball , Grant Likely , openezx-devel@lists.openezx.org, spi-devel-general@lists.sourceforge.net To: Antonio Ospite Return-path: Content-Disposition: inline In-Reply-To: <20110511225337.094839a2.ospite@studenti.unina.it> Sender: linux-mmc-owner@vger.kernel.org List-Id: linux-spi.vger.kernel.org On Wed, May 11, 2011 at 10:53:37PM +0200, Antonio Ospite wrote: > OK, avoiding some duplication will be good, I agree. > I am resending a v4 with the equivalent code: > > if (host->vcc) { > int ret; > > if (power_mode == MMC_POWER_OFF) > vdd = 0; > This isn't really what I meant - what I meant was that all this logic looks like it's generic to multiple drivers. We either set a regulator or call a pdata callback to set power, both of which are completely external to the controller.