From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from metis.ext.pengutronix.de ([2001:6f8:1178:4:290:27ff:fe1d:cc33]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1SR5qH-0003ss-1b for barebox@lists.infradead.org; Sun, 06 May 2012 18:05:58 +0000 Date: Sun, 6 May 2012 20:05:55 +0200 From: Sascha Hauer Message-ID: <20120506180555.GX4141@pengutronix.de> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: 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-bounces@lists.infradead.org Errors-To: barebox-bounces+u.kleine-koenig=pengutronix.de@lists.infradead.org Subject: Re: RFC: memmap() now returns NULL on failure. To: Krzysztof Halasa Cc: barebox@lists.infradead.org T24gU2F0LCBNYXkgMDUsIDIwMTIgYXQgMTE6NDU6MDdQTSArMDIwMCwgS3J6eXN6dG9mIEhhbGFz YSB3cm90ZToKPiBPcmlnaW5hbGx5LCBtb3N0IGNhbGxlcnMgZXhwZWN0ZWQgLTEgd2hpbGUgc29t ZSB0aG91Z2h0IHRoZXknZCBnZXQgTlVMTAo+IG9uIGZhaWx1cmUuIE5VTEwgc2VlbXMgY2xlYW5l ciB0byBtZS4KClVuaXggbW1hcCBhbHNvIHJldHVybnMgKHZvaWQgKiktMSwgc28gcmV0dXJuaW5n IHRoaXMgdmFsdWUgaXMgbm90IHRoYXQKdW51c3VhbC4gSSB0aGluayB3ZSBzaG91bGQga2VlcCB0 aGlzIGFuZCBmaXggdGhlIGVycm9yIGNoZWNrcyBpbnN0ZWFkLApmb3IgdGhlIHJlYXNvbiB5b3Ug bWVudGlvbiBiZWxvdy4KClNhc2NoYQoKPiAKPiBPZiBjb3Vyc2UgaXMgd2Ugd2FudCB0byBhbGxv dyBtZW1tYXBwaW5nIG9mICIvZGV2L3JhbSIgb3Igc29tZXRoaW5nCj4gYWxpa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