Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp986029imu; Thu, 20 Dec 2018 08:19:31 -0800 (PST) X-Google-Smtp-Source: AFSGD/VEZOXleIHenUjNeKY7Sd+5Cxmc6KU7kHyt56PLziE7fbzRn1Yej/CuEmn5BB7fJ15/rDQ5 X-Received: by 2002:a62:db41:: with SMTP id f62mr25410299pfg.123.1545322771906; Thu, 20 Dec 2018 08:19:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1545322771; cv=none; d=google.com; s=arc-20160816; b=YqGWTOjfQu83oH6qdcuMxWB+7H+omNhxewj4j3dIYYalNi7PWSfwiCyrPtzj02NHuA s/G0HvPIejUokapiCUKGQCReq1aYYOVqK4+mjykR4/X0jDpsYSDaNaNBp/U1jjB6vz58 IDd5onUh8dkYZTgvZTrWaFjyiTp2hpDn06L/OBjubNQ7buOJXpwm9QWuRGxDG4KxhuDm m5CM2pRnNUW4WeFXEelXkzsILI0xYz/5ovJ9YFWqLTxLRn7omCSzJ/v8W0XLuHfOg5Se llO5R0kYIlffVX37n64cC/W+ck4xUBwYNFXgdTRy7un8W/kFGwieQbNyPqX4rzX133js GYMw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-id:content-language:accept-language:in-reply-to:references :message-id:date:thread-index:thread-topic:subject:cc:to:from; bh=U8h8rnB2m/7ndkUqXXXPrjW2GLgo62QhjYGhBQ4owEo=; b=b1xHhV0HDTWLwyzeUJ9Cv0dzEFAK8Wiahr8yMIHU9liCbP+KkKNlgGDAPron0LYrKf Ey35ynaH57a2YwU46OxjGODh1K3LpyUhOubHXvQE0ZZAcaTm8T7SqC7r6M+7UOhIGHph 6Jh0QlIcNRKLLCJHSlBKAyj6ffJSW6J5Lupw+1PXSmUgEPB+SLPk0YWkW8qDex/pX3Jq 172n3g3KUvR/S5abvRJP+ANaBpYbgKv0ikXdTzuwASl6Ozn8WrdQQQtgd1K1JnlSmiSu nEKi4mtX6HfPxxZqPE1URbJG/Eo61kUBjStBWNguEqgGwUfenVkAAgXWHIAQMEer6thM hKYA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f4si16193666plf.370.2018.12.20.08.19.13; Thu, 20 Dec 2018 08:19:31 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387653AbeLTOfK (ORCPT + 99 others); Thu, 20 Dec 2018 09:35:10 -0500 Received: from skedge03.snt-world.com ([91.208.41.68]:34284 "EHLO skedge03.snt-world.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1733267AbeLTOfJ (ORCPT ); Thu, 20 Dec 2018 09:35:09 -0500 Received: from sntmail14r.snt-is.com (unknown [10.203.32.184]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by skedge03.snt-world.com (Postfix) with ESMTPS id 98A9E67B8D5; Thu, 20 Dec 2018 15:35:05 +0100 (CET) Received: from sntmail12r.snt-is.com (10.203.32.182) by sntmail14r.snt-is.com (10.203.32.184) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1466.3; Thu, 20 Dec 2018 15:35:05 +0100 Received: from sntmail12r.snt-is.com ([fe80::e551:8750:7bba:3305]) by sntmail12r.snt-is.com ([fe80::e551:8750:7bba:3305%5]) with mapi id 15.01.1466.003; Thu, 20 Dec 2018 15:35:05 +0100 From: Schrempf Frieder To: Boris Brezillon CC: "miquel.raynal@bootlin.com" , "richard@nod.at" , "linux-kernel@vger.kernel.org" , David Woodhouse , "Brian Norris" , "linux-mtd@lists.infradead.org" , Marek Vasut Subject: Re: [PATCH 1/3] mtd: rawnand: Support bad block markers in first, second or last page Thread-Topic: [PATCH 1/3] mtd: rawnand: Support bad block markers in first, second or last page Thread-Index: AQHUliALbj7sZ4eBT0aRyPBxGaehf6WHm40AgAAJ0wA= Date: Thu, 20 Dec 2018 14:35:05 +0000 Message-ID: References: <1545061693-29216-1-git-send-email-frieder.schrempf@kontron.de> <1545061693-29216-2-git-send-email-frieder.schrempf@kontron.de> <20181220145954.55ae36e9@bbrezillon> In-Reply-To: <20181220145954.55ae36e9@bbrezillon> Accept-Language: de-DE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [172.25.9.42] x-c2processedorg: 51b406b7-48a2-4d03-b652-521f56ac89f3 Content-Type: text/plain; charset="utf-8" Content-ID: Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-SnT-MailScanner-Information: Please contact the ISP for more information X-SnT-MailScanner-ID: 98A9E67B8D5.A0513 X-SnT-MailScanner: Found to be clean X-SnT-MailScanner-SpamCheck: X-SnT-MailScanner-From: frieder.schrempf@kontron.de X-SnT-MailScanner-To: boris.brezillon@bootlin.com, computersforpeace@gmail.com, dwmw2@infradead.org, linux-kernel@vger.kernel.org, linux-mtd@lists.infradead.org, marek.vasut@gmail.com, miquel.raynal@bootlin.com, richard@nod.at X-Spam-Status: No Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org T24gMjAuMTIuMTggMTQ6NTksIEJvcmlzIEJyZXppbGxvbiB3cm90ZToNCj4gT24gTW9uLCAxNyBE ZWMgMjAxOCAxNTo0OTowNyArMDAwMA0KPiBTY2hyZW1wZiB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