From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from 27.mail-out.ovh.net ([91.121.30.210]) by bombadil.infradead.org with smtp (Exim 4.69 #1 (Red Hat Linux)) id 1OGqGv-00028C-LQ for barebox@lists.infradead.org; Tue, 25 May 2010 09:18:02 +0000 Message-ID: <4BFB95C3.5090802@eukrea.com> Date: Tue, 25 May 2010 11:17:55 +0200 From: =?UTF-8?B?RXJpYyBCw6luYXJk?= MIME-Version: 1.0 References: <1274776657-6117-1-git-send-email-eric@eukrea.com> <1274776657-6117-2-git-send-email-eric@eukrea.com> <1274776657-6117-3-git-send-email-eric@eukrea.com> <4BFB9224.9030507@pengutronix.de> In-Reply-To: <4BFB9224.9030507@pengutronix.de> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: base64 Content-Type: text/plain; charset="utf-8"; Format="flowed" Sender: barebox-bounces@lists.infradead.org Errors-To: barebox-bounces+u.kleine-koenig=pengutronix.de@lists.infradead.org Subject: Re: [PATCH v4 3/6] commands: add i2c commands To: Marc Kleine-Budde Cc: barebox@lists.infradead.org TGUgMjUvMDUvMjAxMCAxMTowMiwgTWFyYyBLbGVpbmUtQnVkZGUgYSDDqWNyaXQgOgo+PiArCQlj YXNlICdiJzoKPj4gKwkJCWFkYXB0ZXIgPSBpMmNfZ2V0X2FkYXB0ZXIoc2ltcGxlX3N0cnRvdWwo b3B0YXJnLCBOVUxMLCAwKSk7Cj4KPiBJJ2QganVzdCBzYXZlIHRoZSBvcHRhcmcgaW4gYSB2YXJp YWJsZS4uLgo+Cj4+ICsJCQlicmVhazsKPj4gKwkJY2FzZSAndic6Cj4+ICsJCQl2ZXJib3NlID0g MTsKPj4gKwkJCWJyZWFrOwo+PiArCQl9Cj4+ICsJfQo+PiArCj4+ICsJY291bnQgPSBhcmdjIC0g b3B0aW5kOwo+PiArCj4+ICsJaWYgKChhZGRyPCAgMCkgfHwgKHJlZzwgIDApIHx8IChjb3VudCA9 PSAwK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