From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mail.phycard.co.uk ([217.6.246.34] helo=root.phytec.de) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UN0dN-0001av-Jd for barebox@lists.infradead.org; Tue, 02 Apr 2013 12:48:19 +0000 Received: from idefix.phytec.de (idefix.phytec.de [172.16.0.10]) by root.phytec.de (Postfix) with ESMTP id 2F982BF0F7 for ; Tue, 2 Apr 2013 14:47:47 +0200 (CEST) From: =?UTF-8?q?Teresa=20G=C3=A1mez?= Date: Tue, 2 Apr 2013 14:48:07 +0200 Message-Id: <1364906887-21907-2-git-send-email-t.gamez@phytec.de> In-Reply-To: <1364906887-21907-1-git-send-email-t.gamez@phytec.de> References: <1364906887-21907-1-git-send-email-t.gamez@phytec.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: [RFCv2 PATCH 2/2] OMAP: Add option to use environment from MMC To: barebox@lists.infradead.org TWFrZSBsb2FkaW5nIGVudmlyb25tZW50IGZyb20gTU1DIGdlbmVyaWMgZm9yIGFsbCBPTUFQLgoK VGVzdGVkIG9uIEFNMzM1eCwgT01BUDQuCgpTaWduZWQtb2ZmLWJ5OiBUZXJlc2EgR8OhbWV6IDx0 LmdhbWV6QHBoeXRlYy5kZT4KVGVzdGVkLWJ5OiBKYW4gV2VpdHplbCA8ai53ZWl0emVsQHBoeXRl Yy5kZT4KLS0tCnYyOgoJLSByZW1vdmVkIGVudmlyb25tZW50IGNvZGUgYWxzbyBmcm9tIGJlYWds ZWJvbmUKCiBhcmNoL2FybS9ib2FyZHMvYmVhZ2xlYm9uZS9ib2FyZC5jICAgICAgICB8ICAgMzIg LS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLQogYXJjaC9hcm0v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