Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp504773ybi; Tue, 16 Jul 2019 00:47:12 -0700 (PDT) X-Google-Smtp-Source: APXvYqyhVsVlDvWKmEJ4HjqAM2ftWLsieXH7ECJ/dqNu7Pz/zzdVuSgaa9TjlawDK3mRRmn+Wp/U X-Received: by 2002:a63:505a:: with SMTP id q26mr31008302pgl.18.1563263232724; Tue, 16 Jul 2019 00:47:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1563263232; cv=none; d=google.com; s=arc-20160816; b=ljd+ElQlrifDMCoR0wHFvOp3qv2Uj/lreW574eYdg8egc86Wp/1jPkxrRxs7CXnamN RY5te6L6psAxlbU/Aa21kQ/c4xlnqSWwEMUjJXu8yt+e2Bz4VFr04sN4H6NYbYp+IYEU wG/jm83UdjnzhVXX6GJFHziQ06tW3cVti1RwEdptqwDAyshRZYf0RarmWaSzFr0bet6R nAzG9E/f4iTnug4521KPPTWmuimI/WyBgNFDdourf2y/nHJXjdxcP8ucPj690LjbvyvQ ++ZtrK11NlkK5Oi30u/wD6KaeEjwIin7Wf0kJLC7LmvQTj9W3eCONTdpiOHTa0rlBbbK T+3g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date; bh=VAWMVWhZTNhHU2Sa5FydmI1A3vKwRjaqfeyD2Wet3d8=; b=b2eaXnBP0z3ZE4GUcKoCtNnjTm8I5XL6KFGXN9X/sEYnDFOmssZ7YrZbiE8szONUmt XDSoIUrp7TfsaPIa12+5YPF4qEmzQZH0w/yxN0i3G16YKRI8RNY8HpD4m+1JOMaNEFuR b2drDCt0hI7uSd3iLP9uCE834u+LNLB9v9OUFa8U2GSyohTilqonnEccOd+1RpIzaaby u1nPJZrZx3STd25QZWotoQFKcaih1VPbFD/MUDXHplAiYHDUXpBHzEjMd2qrjolzX24J zNhI1GCRuVsyrS7rTVODck788EtrI9yAp3gbQEJUvGpVqQB6tjMmEqUXXc7+ejh267U/ jKXw== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y134si18590667pfc.285.2019.07.16.00.46.56; Tue, 16 Jul 2019 00:47:12 -0700 (PDT) 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728118AbfGPHoz (ORCPT + 99 others); Tue, 16 Jul 2019 03:44:55 -0400 Received: from bhuna.collabora.co.uk ([46.235.227.227]:57888 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726537AbfGPHoy (ORCPT ); Tue, 16 Jul 2019 03:44:54 -0400 Received: from pc-375.home (2a01cb0c88d94a005820d607da339aae.ipv6.abo.wanadoo.fr [IPv6:2a01:cb0c:88d9:4a00:5820:d607:da33:9aae]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: bbrezillon) by bhuna.collabora.co.uk (Postfix) with ESMTPSA id 645C928B69A; Tue, 16 Jul 2019 08:44:53 +0100 (BST) Date: Tue, 16 Jul 2019 09:44:50 +0200 From: Boris Brezillon To: Naga Sureshkumar Relli Cc: miquel.raynal@bootlin.com, bbrezillon@kernel.org, richard@nod.at, dwmw2@infradead.org, computersforpeace@gmail.com, marek.vasut@gmail.com, vigneshr@ti.com, yamada.masahiro@socionext.com, linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org, michal.simek@xilinx.com, svemula@xilinx.com, nagasuresh12@gmail.com Subject: Re: [LINUX PATCH v18 1/2] mtd: rawnand: nand_micron: Do not over write driver's read_page()/write_page() Message-ID: <20190716094450.122ba6e7@pc-375.home> In-Reply-To: <20190716093137.3d8e8c1f@pc-375.home> References: <20190716053051.11282-1-naga.sureshkumar.relli@xilinx.com> <20190716093137.3d8e8c1f@pc-375.home> Organization: Collabora X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; x86_64-redhat-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 16 Jul 2019 09:31:37 +0200 Boris Brezillon wrote: > On Mon, 15 Jul 2019 23:30:51 -0600 > Naga Sureshkumar Relli wrote: > > > Add check before assigning chip->ecc.read_page() and chip->ecc.write_page() > > > > Signed-off-by: Naga Sureshkumar Relli > > --- > > Changes in v18 > > - None > > --- > > drivers/mtd/nand/raw/nand_micron.c | 7 +++++-- > > 1 file changed, 5 insertions(+), 2 deletions(-) > > > > diff --git a/drivers/mtd/nand/raw/nand_micron.c b/drivers/mtd/nand/raw/nand_micron.c > > index cbd4f09ac178..565f2696c747 100644 > > --- a/drivers/mtd/nand/raw/nand_micron.c > > +++ b/drivers/mtd/nand/raw/nand_micron.c > > @@ -500,8 +500,11 @@ static int micron_nand_init(struct nand_chip *chip) > > chip->ecc.size = 512; > > chip->ecc.strength = chip->base.eccreq.strength; > > chip->ecc.algo = NAND_ECC_BCH; > > - chip->ecc.read_page = micron_nand_read_page_on_die_ecc; > > - chip->ecc.write_page = micron_nand_write_page_on_die_ecc; > > + if (!chip->ecc.read_page) > > + chip->ecc.read_page = micron_nand_read_page_on_die_ecc; > > + > > + if (!chip->ecc.write_page) > > + chip->ecc.write_page = micron_nand_write_page_on_die_ecc; > > > > Seriously?! I told you this was inappropriate and you keep sending this > patch. So let's make it clear: > > Nacked-by: Boris Brezillon > > Fix your controller driver instead of adding hacks to the Micron logic! Not even going to review the other patch: if you have to do that, that means the driver is broken. On a side note, this patch series is still not threaded as it should be and it's a v18 for a damn NAND controller driver! Sorry but you reached the limit of my patience. Please find someone to help you with that task.