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 #3 (Red Hat Linux)) id 1iwQbD-0006NY-Lv for barebox@lists.infradead.org; Tue, 28 Jan 2020 13:08:13 +0000 From: =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= Date: Tue, 28 Jan 2020 14:08:01 +0100 Message-Id: <20200128130801.24890-4-u.kleine-koenig@pengutronix.de> In-Reply-To: <20200128130801.24890-1-u.kleine-koenig@pengutronix.de> References: <20200128130801.24890-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 3/3] commands/test: Implement -b and -c to test for character and block devices To: barebox@lists.infradead.org VGhlc2UgbWF0Y2ggdGhlIHNhbWUgb3B0aW9ucyBvbiBjb3JldXRpbCdzIHRlc3QoMSkuCgpTaWdu ZWQtb2ZmLWJ5OiBVd2UgS2xlaW5lLUvDtm5pZyA8dS5rbGVpbmUta29lbmlnQHBlbmd1dHJvbml4 LmRlPgotLS0KIGNvbW1hbmRzL3Rlc3QuYyB8IDE0ICsrKysrKysrKysrKysrCiAxIGZpbGUgY2hh bmdlZCwgMTQgaW5zZXJ0aW9ucygrKQoKZGlmZiAtLWdpdCBhL2NvbW1hbmRzL3Rlc3QuYyBiL2Nv bW1hbmRzL3Rlc3QuYwppbmRleCA5MDcwZTQ5MDc0OTYuLjg2NjM2ZGUxYzI4MyAxMDA2NDQKLS0t IGEvY29tbWFuZHMvdGVzdC5jCisrKyBiL2NvbW1hbmRzL3Rlc3QuYwpAQCAtNDAsNiArNDAsOCBA QCB0eXBlZGVmIGVudW0gewogCU9QVF9ESVJFQ1RPUlksCiAJ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