From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mx1.emlix.com ([188.40.240.192]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jksn8-0006lA-6z for barebox@lists.infradead.org; Mon, 15 Jun 2020 17:21:05 +0000 From: =?UTF-8?q?Daniel=20Gl=C3=B6ckner?= Date: Mon, 15 Jun 2020 19:20:35 +0200 Message-Id: In-Reply-To: References: In-Reply-To: References: 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 v3 02/14] Introduce idle slice To: Barebox List Cc: =?UTF-8?q?Daniel=20Gl=C3=B6ckner?= U29tZSBjb2RlIGNhbid0IGZvcmVzZWUgd2hpY2ggcmVzb3VyY2VzIHdpbGwgYmUgdXNlZCBieSBp dHMgcG9sbGVyLiBUaGlzCmlzIHRoZSBjYXNlIGVzcGVjaWFsbHkgaW4gcG9sbGVycyB0aGF0IHdp bGwgZXhlY3V0ZSBhcmJpdHJhcnkgY29tbWFuZHMKaW5wdXQgYnkgdGhlIHVzZXIuIFdpdGggdGhp cyBjb21taXQgYSBzcGVjaWFsIHNsaWNlIGlzIGludHJvZHVjZWQgdGhhdCBpcwpyZWxlYXNlZCBv bmx5IHdoZW4gQmFyZWJveCBpcyB3YWl0aW5nIGZvciBjb25zb2xlIGlucHV0IGFuZCBvbmx5IHdo ZW4gaXQKaXMgZG9pbmcgdGhhdCBvdXRzaWRlIG9mIGFueSBjb21tYW5kLiBDb2RlIHRoYXQgd2Fu dHMgdG8gZGVwZW5kIG9uIHRoZQppZGxlIHNsaWNlIG11c3Qgc2VsZWN0IENPTkZJR19JRExFX1NM SUNFIHRvIG1ha2UgaXQgYXZhaWxhYmxlLgoKU2lnbmVkLW9mZi1ieTogRGFuaWVsIEdsw7Zja25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