Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1293636imu; Wed, 16 Jan 2019 16:35:03 -0800 (PST) X-Google-Smtp-Source: ALg8bN4omGwyu9GtdoXrr0fsFox83EETmjFT1Qy9OMEPz+FV0rsL0SMm5bKUqp3kxFQaG51pQDYu X-Received: by 2002:a17:902:bcc7:: with SMTP id o7mr12931537pls.281.1547685302972; Wed, 16 Jan 2019 16:35:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547685302; cv=none; d=google.com; s=arc-20160816; b=Je9HNK399mUMDF2fuXE/J3Qq37eNC5EC6dMFwM79x5vGsBpweguWMaZclTAG2ph2qE I4Tet/2SgHjvwNNjVJL2g0JpSz8lu9ri2nFSARRXmF+L6vrAA8/IpCxmrkl5sKHXQ7/b NeH6MRHR+Y7A6W5n8nXkeQ1nckXjozWAbHH7VofD536Qw2MNT0o4m7OxCATwuEug80tW SNFLAyGIe/5o3Kj7gnROd7dX2K6nXsAJ2kFXpwo2x/mD3UFhnnldRrD79vZF89Uwz3pB XSFAXeWL/IKk0Wzdx4KOP6ZuwguMJrgF0o5dXtd/RhZ+tihCea6qevMsmoi++xhjFvqR aptw== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=9SfLHsFdGJBWSULrI/JrLIMXZuHcal7zVDCKaPfdAxM=; b=Oc8QBYw2V7IzPOdbC5efODtr9OaE1SbiN+FNEKHGai6HUDKDd9KrUOvG2DW47QXFYb 8lSVA2Vq0ZRq2DMNQDRlEx1YV1AgK3t4q14FxbFx/swhKrp2mfAlEbVH0AS1ZVasNUkR 4tHRVbYIcNIe4aZEtHP5XH8AU+GNMeoPQ7lNfo60SXjscDjAvju+2xX95SC2SWFcjgTE JV3AEuOpOqxn7NVqpCFTSY2fbXQ0Bmy5zpT6NUlg9CawfdOslACOwL08ZYZbHAQujnHY 6gLKUHXyLMg2PDhT12QcsV/FpYC/e7sIrA5g8BUVjlL4twMkWwRe6QSkDawjeucG8kKN 164w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=llEKrwug; 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 33si8165050plh.245.2019.01.16.16.34.47; Wed, 16 Jan 2019 16:35:02 -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; dkim=fail header.i=@gmail.com header.s=20161025 header.b=llEKrwug; 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 S1731839AbfAPTvr (ORCPT + 99 others); Wed, 16 Jan 2019 14:51:47 -0500 Received: from mail-wm1-f68.google.com ([209.85.128.68]:39327 "EHLO mail-wm1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731691AbfAPTvr (ORCPT ); Wed, 16 Jan 2019 14:51:47 -0500 Received: by mail-wm1-f68.google.com with SMTP id y8so3327438wmi.4 for ; Wed, 16 Jan 2019 11:51:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=9SfLHsFdGJBWSULrI/JrLIMXZuHcal7zVDCKaPfdAxM=; b=llEKrwugZp6FUFyPmd45CYzhmvyPO4a7wxEVsWDdUGd/Bo6Vl6YS/mY/Wi8ztUfmYx n8JmJ1Sb3SC6zeR+vIiHF1IHulhqNPf6IYpwzmWc5Nk/aTXk0EI/nhuUIxC0bJnP9mxj vFUMuUL1f25DDaiWLG1qO2cJ3XTYYJZHtJpvzIiCNgPdfaEEJfneR9pZ5ZzMEyuWj4Gs NYjEm7DJbt4yk9zjdDgRoP63IvWEWsvjJSunkC2WPcfENmuE1nj5TcDVIeL3j2YLCaZh QMOy55LbXP0+wQoYMsaLX3+dXHWoCHRsgoOAfRfFRZo4xqMdM0YaTjfmANraN8Cncbs4 yKxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=9SfLHsFdGJBWSULrI/JrLIMXZuHcal7zVDCKaPfdAxM=; b=GncCdkuKkTh9BJYvrdq1b6j8ZVZJ9kzy4Ivlk02DrbDk5xFUEq36rHHpI3lznv65oV 49t+ME5E8IyASLJ3lPiUHO/3U/QF6QOL1h55wO81WG4pORMiX3OU88dygu95Q5eaizVV SOTKC6bdocUR8cp9T2c4ebDBEF61u9jlU0tfD1Z9ZrKqbcGvvOzfWrrcBh50es3WqdLt sxwxoghih2TpUDEnIbJRAyWcHpwheMnwKrDwYEqFPzdAwppwmcq1kfEjeV6Dygnbr8MR MY5mw6OOKyb06Vzg6XIdBdQL5KCmW4pfMSQ9QrgdBh7UWR29IzfvhBtWGEsm57N9LyIc K3LA== X-Gm-Message-State: AJcUukfeiixtBw7KoH0ehXB6uA0IcYx2Du5yY8fDeh0ON29iOtkddsi3 6uNSGRyU3RaQ2yVnRBBBIAo= X-Received: by 2002:a1c:f916:: with SMTP id x22mr9198412wmh.87.1547668305893; Wed, 16 Jan 2019 11:51:45 -0800 (PST) Received: from macbookpro.malat.net ([2a01:e34:ee1e:860:6f23:82e6:aa2d:bbd1]) by smtp.gmail.com with ESMTPSA id v6sm34247343wrd.88.2019.01.16.11.51.44 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 16 Jan 2019 11:51:45 -0800 (PST) Received: by macbookpro.malat.net (Postfix, from userid 1000) id CA5C711423A3; Wed, 16 Jan 2019 20:51:38 +0100 (CET) From: Mathieu Malaterre To: Boris Brezillon Cc: Mathieu Malaterre , Miquel Raynal , Richard Weinberger , David Woodhouse , Brian Norris , Marek Vasut , linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/2] mtd: Annotate implicit fall through in nand_scan_tail Date: Wed, 16 Jan 2019 20:50:04 +0100 Message-Id: <20190116195004.2499-2-malat@debian.org> X-Mailer: git-send-email 2.19.2 In-Reply-To: <20190116195004.2499-1-malat@debian.org> References: <20190116195004.2499-1-malat@debian.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org There is a plan to build the kernel with -Wimplicit-fallthrough and these places in the code produced warnings (W=1). This commit removes the following warnings: drivers/mtd/nand/raw/nand_base.c:5556:6: warning: this statement may fall through [-Wimplicit-fallthrough=] drivers/mtd/nand/raw/nand_base.c:5575:6: warning: this statement may fall through [-Wimplicit-fallthrough=] drivers/mtd/nand/raw/nand_base.c:5613:13: warning: this statement may fall through [-Wimplicit-fallthrough=] Signed-off-by: Mathieu Malaterre --- drivers/mtd/nand/raw/nand_base.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/mtd/nand/raw/nand_base.c b/drivers/mtd/nand/raw/nand_base.c index cca4b24d2ffa..da344c276088 100644 --- a/drivers/mtd/nand/raw/nand_base.c +++ b/drivers/mtd/nand/raw/nand_base.c @@ -5555,6 +5555,7 @@ static int nand_scan_tail(struct nand_chip *chip) } if (!ecc->read_page) ecc->read_page = nand_read_page_hwecc_oob_first; + /* fall through */ case NAND_ECC_HW: /* Use standard hwecc read page function? */ @@ -5574,6 +5575,7 @@ static int nand_scan_tail(struct nand_chip *chip) ecc->read_subpage = nand_read_subpage; if (!ecc->write_subpage && ecc->hwctl && ecc->calculate) ecc->write_subpage = nand_write_subpage_hwecc; + /* fall through */ case NAND_ECC_HW_SYNDROME: if ((!ecc->calculate || !ecc->correct || !ecc->hwctl) && @@ -5611,6 +5613,7 @@ static int nand_scan_tail(struct nand_chip *chip) ecc->size, mtd->writesize); ecc->mode = NAND_ECC_SOFT; ecc->algo = NAND_ECC_HAMMING; + /* fall through */ case NAND_ECC_SOFT: ret = nand_set_ecc_soft_ops(chip); -- 2.19.2