Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753020Ab0AZMOR (ORCPT ); Tue, 26 Jan 2010 07:14:17 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752737Ab0AZMOQ (ORCPT ); Tue, 26 Jan 2010 07:14:16 -0500 Received: from mail-px0-f182.google.com ([209.85.216.182]:52779 "EHLO mail-px0-f182.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751913Ab0AZMOO (ORCPT ); Tue, 26 Jan 2010 07:14:14 -0500 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=CGklF6sAYbfmW08mOyTIGvxOd1FeLDkNVzGzWCrZRWOQBdues1edxDNby7BxwKoOH0 tysMD3bzVZRun+eqKuE9qd4GtqDvYrgavS19bfWWZW3sm3U6/DL43NQG4KB1F3Zog2RV 4oMRq98ATW2oC901wZ2ud5zXiV+DbsM8uj+AU= MIME-Version: 1.0 In-Reply-To: <20100126120058.GN15759@rakim.wolfsonmicro.main> References: <771cded01001120041ue24edabk8e4638ef7151c947@mail.gmail.com> <771cded01001120051l44fd76bx80d2fd4b6f60bd0b@mail.gmail.com> <20100112115156.GA546@rakim.wolfsonmicro.main> <771cded01001250301q465a9f8ma484f597ae9a292f@mail.gmail.com> <20100125135628.GB26613@rakim.wolfsonmicro.main> <771cded01001252226k342723b3p3ea235fe79c46843@mail.gmail.com> <20100126110420.GI15759@rakim.wolfsonmicro.main> <771cded01001260354y7c7db25bqa8bbfe000e0c0380@mail.gmail.com> <20100126120058.GN15759@rakim.wolfsonmicro.main> Date: Tue, 26 Jan 2010 07:14:14 -0500 Message-ID: <771cded01001260414q4c8df1e0k303772b87bc725eb@mail.gmail.com> Subject: Re: [PATCH 01/01] regulator: support max8649 From: Haojian Zhuang To: Mark Brown Cc: Liam Girdwood , linux-arm-kernel , linux-kernel@vger.kernel.org Content-Type: multipart/mixed; boundary=001636ed62f9622071047e103992 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 19706 Lines: 277 --001636ed62f9622071047e103992 Content-Type: text/plain; charset=ISO-8859-1 On Tue, Jan 26, 2010 at 7:00 AM, Mark Brown wrote: > On Tue, Jan 26, 2010 at 06:54:48AM -0500, Haojian Zhuang wrote: >> On Tue, Jan 26, 2010 at 6:04 AM, Mark Brown > >> > I'd expect the time taken to enable to be the voltage multipled by the >> > step size rather than divided by the step size? > >> I don't agree at this point. The unit of step is uV/uSec. The function >> should return uSec. So voltage divided by the step is more reasonable. > > Ah, then the variable step is confusingly named since it's actually a > rate of change rather than a step size - I'd suggest rate or something > like that instead. > update this patch. Thanks Haojian --001636ed62f9622071047e103992 Content-Type: text/x-patch; charset=US-ASCII; name="0001-regulator-enable-max8649-regulator-driver.patch" Content-Disposition: attachment; filename="0001-regulator-enable-max8649-regulator-driver.patch" Content-Transfer-Encoding: base64 X-Attachment-Id: f_g4x3zr0e0 RnJvbSA5NDNjZDI0NWQ1MGE4NWIzNjlhZDA3YWY0YzljOTc3ZTE0ODM2YzYzIE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiBIYW9qaWFuIFpodWFuZyA8aGFvamlhbi56aHVhbmdAbWFydmVs bC5jb20+CkRhdGU6IE1vbiwgMjUgSmFuIDIwMTAgMTA6MjQ6MDkgLTA1MDAKU3ViamVjdDogW1BB VENIXSByZWd1bGF0b3I6IGVuYWJsZSBtYXg4NjQ5IHJlZ3VsYXRvciBkcml2ZXIKClNpZ25lZC1v ZmYtYnk6IEhhb2ppYW4gWmh1YW5nIDxoYW9qaWFuLnpodWFuZ0BtYXJ2ZWxsLmNvbT4KLS0tCiBk cml2ZXJzL3JlZ3VsYXRvci9LY29uZmlnICAgICAgICAgfCAgICA3ICsKIGRyaXZlcnMvcmVndWxh dG9yL01ha2VmaWxlICAgICAgICB8ICAgIDEgKwogZHJpdmVycy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VBfMF8yNU1WLAorfTsKKworc3RydWN0IG1heDg2NDlfcGxhdGZvcm1fZGF0 YSB7CisJc3RydWN0IHJlZ3VsYXRvcl9pbml0X2RhdGEgKnJlZ3VsYXRvcjsKKworCXVuc2lnbmVk CW1vZGU6MjsJCS8qIGJpdFsxOjBdID0gVklEMSxWSUQwICovCisJdW5zaWduZWQJZXh0Y2xrX2Zy ZXE6MjsKKwl1bnNpZ25lZAlleHRjbGs6MTsKKwl1bnNpZ25lZAlyYW1wX3RpbWluZzozOworCXVu c2lnbmVkCXJhbXBfZG93bjoxOworfTsKKworI2VuZGlmCS8qIF9fTElOVVhfUkVHVUxBVE9SX01B WDg2NDlfSCAqLwotLSAKMS41LjYuNQoK --001636ed62f9622071047e103992-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/