From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from metis.ext.pengutronix.de ([2001:67c:670:201:290:27ff:fe1d:cc33]) by casper.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hubqr-0002UL-6k for barebox@lists.infradead.org; Mon, 05 Aug 2019 12:12:35 +0000 Message-ID: <1565007134.2323.9.camel@pengutronix.de> From: Lucas Stach Date: Mon, 05 Aug 2019 14:12:14 +0200 In-Reply-To: <03ea3dc20571d075cee01127c189e4db4e2a36f9.1564997015.git-series.r.czerwinski@pengutronix.de> References: <03ea3dc20571d075cee01127c189e4db4e2a36f9.1564997015.git-series.r.czerwinski@pengutronix.de> Mime-Version: 1.0 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Sender: "barebox" Errors-To: barebox-bounces+u.kleine-koenig=pengutronix.de@lists.infradead.org Subject: Re: [PATCH v2 02/16] i.MX: HABv4: implement interface for i.MX8MQ To: Rouven Czerwinski , barebox@lists.infradead.org QW0gTW9udGFnLCBkZW4gMDUuMDguMjAxOSwgMTE6MjMgKzAyMDAgc2NocmllYiBSb3V2ZW4gQ3pl cndpbnNraToKPiBUaGUgSEFCIGludGVyZmFjZSBmb3IgaS5NWDhNUSBvbmx5IGltcGxlbWVudHMg dGhlIHJldHJpZXZhbCBvZiBzdGF0dXMKPiBhbmQgZXZlbnRzLiBUaGUgU29DIHN0YXR1cyBpcyBy ZXRyaWV2ZWQgdXNpbmcgdGhlIFRGLUEgU0lQIEFQSSBmb3VuZCBpbgo+IHRoZSBkb3duc3RyZWFt IGlteCBURi1BLiBBZnRlciBjYWxsaW5nIGludG8gdGhlIFRGLUEgdGhlIHBhc3NlZCBkYXRhCj4g c3RydWN0dXJlcyBuZWVkIHRvIGJlIGludmFsaWRhdGVkLCBzaW5jZSBvdGhlcndpc2UgdGhlIGNh Y2hlZCB6ZXJvIHZhbHVlCj4gaXMgdXNlZC4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