Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753680Ab0AYLBx (ORCPT ); Mon, 25 Jan 2010 06:01:53 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753659Ab0AYLBs (ORCPT ); Mon, 25 Jan 2010 06:01:48 -0500 Received: from mail-pz0-f190.google.com ([209.85.222.190]:56226 "EHLO mail-pz0-f190.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751042Ab0AYLBm (ORCPT ); Mon, 25 Jan 2010 06:01:42 -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=V88yxmNl9lnGJ2RA4gEcqYCJsFuNyAD0xBiNcE0OIMhmc0p5QcuZPtR3VehbLh+u8D 15dBU8/FkCfzKc47CN+cNN4A/ALmsdX4uCj0DoKLQVSBddrBf11Eyedg2bgH+HHJTtlN TcjA4OYGkSip9W7PYOjuN50qrBqhKMkWz5Cvc= MIME-Version: 1.0 In-Reply-To: <20100112115156.GA546@rakim.wolfsonmicro.main> References: <771cded01001120041ue24edabk8e4638ef7151c947@mail.gmail.com> <771cded01001120051l44fd76bx80d2fd4b6f60bd0b@mail.gmail.com> <20100112115156.GA546@rakim.wolfsonmicro.main> Date: Mon, 25 Jan 2010 06:01:41 -0500 Message-ID: <771cded01001250301q465a9f8ma484f597ae9a292f@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=000e0cd32f161c4483047dfb18a5 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 19302 Lines: 278 --000e0cd32f161c4483047dfb18a5 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On Tue, Jan 12, 2010 at 6:51 AM, Mark Brown wrote: > On Tue, Jan 12, 2010 at 03:51:09AM -0500, Haojian Zhuang wrote: > >> Enable Maxim max8649 regulator driver. > > This seems basically fine but there's a few relatively minor issues > below, mostly coding style rather than anything serious. > > >> + =A0 =A0 if (pdata->ramp_timing) { >> + =A0 =A0 =A0 =A0 =A0 =A0 info->ramp_timing =3D pdata->ramp_timing; >> + =A0 =A0 =A0 =A0 =A0 =A0 max8649_set_bits(info->i2c, MAX8649_RAMP, MAX8= 649_RAMP_MASK, >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0info->ramp_= timing << 5); >> + =A0 =A0 } > > You might want to implement the new enable_time() API for this. > This ramp timing is the time interval of each step on adjusting voltage. I just want to control the timing in initialization. enable_time() is only called before enabling regulator. And I don't understand what would be done in enable_time(). Others are updated in this attached patch. Thanks Haojian --000e0cd32f161c4483047dfb18a5 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_g4vlvfpe0 RnJvbSA5N2RhZjVkY2FjNTA3M2JkYjkxNWVjYTBjMzllY2ViMmU3NGU3ODdmIE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiBIYW9qaWFuIFpodWFuZyA8aGFvamlhbi56aHVhbmdAbWFydmVs bC5jb20+CkRhdGU6IE1vbiwgMjUgSmFuIDIwMTAgMTA6MjQ6MDkgLTA1MDAKU3ViamVjdDogW1BB VENIXSByZWd1bGF0b3I6IGVuYWJsZSBtYXg4NjQ5IHJlZ3VsYXRvciBkcml2ZXIKClNpZ25lZC1v ZmYtYnk6IEhhb2ppYW4gWmh1YW5nIDxoYW9qaWFuLnpodWFuZ0BtYXJ2ZWxsLmNvbT4KLS0tCiBk cml2ZXJzL3JlZ3VsYXRvci9LY29uZmlnICAgICAgICAgfCAgICA3ICsKIGRy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ZJRDAgKi8KKwl1bnNpZ25lZAlleHRjbGtfZnJlcToyOworCXVuc2ln bmVkCWV4dGNsazoxOworCXVuc2lnbmVkCXJhbXBfdGltaW5nOjM7CisJdW5zaWduZWQJcmFtcF9k b3duOjE7Cit9OworCisvKiBJMkMgb3BlcmF0aW9ucyAqLworCitzdGF0aWMgaW5saW5lIGludCBt YXg4NjQ5X3JlYWRfZGV2aWNlKHN0cnVjdCBpMmNfY2xpZW50ICppMmMsCisJCQkJICAgICAgaW50 IHJlZywgaW50IGJ5dGVzLCB2b2lkICpkZXN0KQoreworCXVuc2lnbmVkIGNoYXIgZGF0YTsKKwlp bnQgcmV0OworCisJZGF0YSA9ICh1bnNpZ25lZCBjaGFyKXJlZzsKKwlyZXQgPSBpMmNfbWFzdGVy X3NlbmQoaTJjLCAmZGF0YSwgMSk7CisJaWYgKHJldCA8IDApCisJCXJldHVybiByZXQ7CisJcmV0 ID0gaTJjX21hc3Rlcl9yZWN2KGkyYywgZGVzdCwgYnl0ZXMpOworCWlmIChyZXQgPCAwKQorCQly ZXR1cm4gcmV0OworCXJldHVybiAwOworfQorCitzdGF0aWMgaW5saW5lIGludCBtYXg4NjQ5X3dy aXRlX2RldmljZShzdHJ1Y3QgaTJjX2NsaWVudCAqaTJjLAorCQkJCSAgICAgICBpbnQgcmVnLCBp bnQgYnl0ZXMsIHZvaWQgKnNyYykKK3sKKwl1bnNpZ25lZCBjaGFyIGJ1ZltieXRlcyArIDFdOwor CWludCByZXQ7CisKKwlidWZbMF0gPSAodW5zaWduZWQgY2hhcilyZWc7CisJbWVtY3B5KCZidWZb MV0sIHNyYywgYnl0ZXMpOworCisJcmV0ID0gaTJjX21hc3Rlcl9zZW5kKGkyYywgYnVmLCBieXRl cyArIDEpOworCWlmIChyZXQgPCAwKQorCQlyZXR1cm4gcmV0OworCXJldHVybiAwOworfQorCitz dGF0aWMgaW50IG1heDg2NDlfcmVnX3JlYWQoc3RydWN0IGkyY19jbGllbnQgKmkyYywgaW50IHJ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xM01IWiwKKwlNQVg4NjQ5X0VYVENMS18xOU1IWiwJLyogMTkuMk1I eiAqLworfTsKKworZW51bSB7CisJTUFYODY0OV9SQU1QXzMyTVYgPSAwLAorCU1BWDg2NDlfUkFN UF8xNk1WLAorCU1BWDg2NDlfUkFNUF84TVYsCisJTUFYODY0OV9SQU1QXzRNViwKKwlNQVg4NjQ5 X1JBTVBfMk1WLAorCU1BWDg2NDlfUkFNUF8xTVYsCisJTUFYODY0OV9SQU1QXzBfNU1WLAorCU1B WDg2NDlfUkFNUF8wXzI1TVYsCit9OworCitzdHJ1Y3QgbWF4ODY0OV9wbGF0Zm9ybV9kYXRhIHsK KwlzdHJ1Y3QgcmVndWxhdG9yX2luaXRfZGF0YSAqcmVndWxhdG9yOworCisJdW5zaWduZWQJbW9k ZToyOwkJLyogYml0WzE6MF0gPSBWSUQxLFZJRDAgKi8KKwl1bnNpZ25lZAlleHRjbGtfZnJlcToy OworCXVuc2lnbmVkCWV4dGNsazoxOworCXVuc2lnbmVkCXJhbXBfdGltaW5nOjM7CisJdW5zaWdu ZWQJcmFtcF9kb3duOjE7Cit9OworCisjZW5kaWYJLyogX19MSU5VWF9SRUdVTEFUT1JfTUFYODY0 OV9IICovCi0tIAoxLjUuNi41Cgo= --000e0cd32f161c4483047dfb18a5-- -- 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/