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 bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1i1uum-0008Tg-3H for barebox@lists.infradead.org; Sun, 25 Aug 2019 15:58:50 +0000 From: =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= Date: Sun, 25 Aug 2019 17:58:44 +0200 Message-Id: <20190825155844.18455-8-u.kleine-koenig@pengutronix.de> In-Reply-To: <20190825155844.18455-1-u.kleine-koenig@pengutronix.de> References: <20190825155844.18455-1-u.kleine-koenig@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: [PATCH v2 7/7] oftree: expose reset_source device in device tree To: barebox@lists.infradead.org U2lnbmVkLW9mZi1ieTogVXdlIEtsZWluZS1Lw7ZuaWcgPHUua2xlaW5lLWtvZW5pZ0BwZW5ndXRy b25peC5kZT4KLS0tCiBjb21tb24vb2Z0cmVlLmMgfCAxNCArKysrKysrKysrKysrKwogMSBmaWxl IGNoYW5nZWQsIDE0IGluc2VydGlvbnMoKykKCmRpZmYgLS1naXQgYS9jb21tb24vb2Z0cmVlLmMg Yi9jb21tb24vb2Z0cmVlLmMKaW5kZXggMjhhM2I5NjVmZmVlLi4wOWNiNjYwMjEyMTcgMTAwNjQ0 Ci0tLSBhL2NvbW1vbi9vZnRyZWUuYworKysgYi9jb21tb24vb2Z0cmVlLmMKQEAgLTE0NSw2ICsx NDUsNyBAQCBzdGF0aWMgaW50IG9mX2ZpeHVwX2Jvb3RhcmdzKHN0cnVjdCBkZXZpY2Vfbm9kZSAq cm9vdCwgdm9pZCAqdW51c2VkKQogCWNvbnN0IGNoYXIgKnN0cjsKIAlpbnQgZXJyOw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