Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp141246ybh; Mon, 9 Mar 2020 18:07:52 -0700 (PDT) X-Google-Smtp-Source: ADFU+vswDaaWf7dBIsFxHAhb7WNUh+63Ro9/+kkS/vGnOrGxh1B3RmiRt8kO2qmy4Yjm2CZGbQ8q X-Received: by 2002:a05:6830:186:: with SMTP id q6mr14488712ota.10.1583802472351; Mon, 09 Mar 2020 18:07:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1583802472; cv=none; d=google.com; s=arc-20160816; b=Fo+ffutG4tKKe/xoRnPCZSHEGzv4sEw68aMkEU7mSnPaGD0m6LZQcoOXc6yIfBOT+Z 66WGLZhTi3IRqKkqut4dEq0Udfl06+zqIaxNA2CxSXNj9uy61z8NwnhZRcfcTPCnllBg 6o1qKDkmq0VxI9kYicSgMTYfKTh4cw+PrGfVIArXdBd9RnZd/d2e2UhRwZiA6VHFUhXK mtl91rpaCBi4eFZNe+ROgqhg92POvFg0jvwyOiX7TtN7tDVtJ/+SKdZw5FrGFweXMiky 7xF7lMbvUetFBYHEZe/UILssYt81vSL6XxQBdsQzlpJIEDGIgv/gUom/jYmeuQQxtSZQ Ah+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:subject:cc:to:from:date; bh=fldpAdj5Rjek+TOzwKLhfdpRQ/93BsJObzxoYKpuIck=; b=xod9p137W17W+08sVoMwSJUKzNcp/OEKKZFRJGm1CiFQFFXiLRWryl8cpYPx37XdEB 8s6+oHFO8kuO6QhPjsgaUQ4JgKpgAFoi4SiyiUL8Jc2x4+FnzgeuTex0y4pcVmsZxprp GjVUMSow+MH96ruyr/1SCoVzslj7iV7Az9Sm6MJXwEDHAaZrefBJl1Fq7ilOixaCFGWT 3UkY+G/f56Rr7TaUQDnBhgOdFcYsd6D2DI7/IJe5oegd8SHoanUV5dEpJtQuji/hwNgy n1KihW41tPYeUKwa2u0mbe0CIZSxBLt6LNNKKKmTl33LuPolOE6y/r3i841xmVbtwa8b cxFA== 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 o18si6888766otk.80.2020.03.09.18.07.41; Mon, 09 Mar 2020 18:07:52 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726451AbgCJBGz (ORCPT + 99 others); Mon, 9 Mar 2020 21:06:55 -0400 Received: from mail.baikalelectronics.com ([87.245.175.226]:44568 "EHLO mail.baikalelectronics.ru" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726115AbgCJBGz (ORCPT ); Mon, 9 Mar 2020 21:06:55 -0400 Received: from localhost (unknown [127.0.0.1]) by mail.baikalelectronics.ru (Postfix) with ESMTP id 9DE7380307C5; Tue, 10 Mar 2020 01:06:53 +0000 (UTC) X-Virus-Scanned: amavisd-new at baikalelectronics.ru Received: from mail.baikalelectronics.ru ([127.0.0.1]) by localhost (mail.baikalelectronics.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7s97QYij5BRW; Tue, 10 Mar 2020 04:06:53 +0300 (MSK) Date: Tue, 10 Mar 2020 04:06:03 +0300 From: Sergey Semin To: Jiri Slaby CC: Greg Kroah-Hartman , Alexey Malahov , Thomas Bogendoerfer , Paul Burton , Ralf Baechle , Subject: Re: [PATCH 18/22] tty: mips_ejtag_fdc: Mark expected switch fall-through References: <20200306124705.6595-1-Sergey.Semin@baikalelectronics.ru> <20200306124913.151A68030792@mail.baikalelectronics.ru> <20200309161243.D5D5180307C7@mail.baikalelectronics.ru> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20200309161243.D5D5180307C7@mail.baikalelectronics.ru> X-ClientProxiedBy: MAIL.baikal.int (192.168.51.25) To mail (192.168.51.25) Message-Id: <20200310010653.9DE7380307C5@mail.baikalelectronics.ru> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 09, 2020 at 05:12:40PM +0100, Jiri Slaby wrote: > On 06. 03. 20, 13:47, Sergey.Semin@baikalelectronics.ru wrote: > > From: Serge Semin > > > > Mark mips_ejtag_fdc_encode() methods switch-case-4 as expecting to > > fall through. > > > > This patch fixes the following warning: > > > > drivers/tty/mips_ejtag_fdc.c: In function ‘mips_ejtag_fdc_encode’: > > drivers/tty/mips_ejtag_fdc.c:245:13: warning: this statement may fall through [-Wimplicit-fallthrough=] > > word.word &= 0x00ffffff; > > ~~~~~~~~~~^~~~~~~~~~~~~ > > drivers/tty/mips_ejtag_fdc.c:246:2: note: here > > case 3: > > ^~~~ > > > > Signed-off-by: Serge Semin > > Signed-off-by: Alexey Malahov > > Cc: Thomas Bogendoerfer > > Cc: Paul Burton > > Cc: Ralf Baechle > > --- > > drivers/tty/mips_ejtag_fdc.c | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/drivers/tty/mips_ejtag_fdc.c b/drivers/tty/mips_ejtag_fdc.c > > index 620d8488b83e..21e76a2ec182 100644 > > --- a/drivers/tty/mips_ejtag_fdc.c > > +++ b/drivers/tty/mips_ejtag_fdc.c > > @@ -243,6 +243,7 @@ static struct fdc_word mips_ejtag_fdc_encode(const char **ptrs, > > /* Fall back to a 3 byte encoding */ > > word.bytes = 3; > > word.word &= 0x00ffffff; > > + /* Fall through */ > > We now have "fallthrough;", so I believe you should use that instead of > comments. > Hello Jiri, Thanks for the comment. I didn't know about that new macro. Since Greg already pulled this patch in his tty-next branch, I won't send an update in the next patchset revision. But I'll certainly remember that there is a specific macro to fix the fallthrough warning in the kernel and will use it next time I find the same problem someplace else. Regards, -Sergey > thanks, > -- > js > suse labs