Received: by 10.223.185.116 with SMTP id b49csp1015257wrg; Fri, 16 Feb 2018 10:51:16 -0800 (PST) X-Google-Smtp-Source: AH8x22456JF/BG2Mu7GOQJ6ty16Cjh9c+AthX4hTu2uL9p/DWeHeAJQn4AIIyPlz9FquRgeZ8CCX X-Received: by 10.101.101.200 with SMTP id y8mr5845214pgv.356.1518807075910; Fri, 16 Feb 2018 10:51:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518807075; cv=none; d=google.com; s=arc-20160816; b=SdrD5v8uHOoVI1e3/89qVd9qBrvwuamA5jLyTdLsJ39vbSJK3WlV5fERYCtbF2yNPT awlyAllrGDJcFyGWCzP/W41ka07/zmwRRomk1vDqs+4lBGfBTMXZCpzusDpA6iEs5wCm ZC3CIBT+b4c/ttdBDloCEqxFAYAsv+u901v5zQHSRXy0ov/eZVYsXQlyvOAcnEV7dofs 6fHYjuGYfg2Vd2t7k054DdMrqmO+Wi5wkyrf65o6QAhy7Gkd1jumaPE/c+kPOS7z5fWb WfRwR6GhldVqQgDn3gVvlW8ghR7z7Iu7GH5tLhe/zeWLk+C498QRz0/8GFjpZubg8bxr CEug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:arc-authentication-results; bh=aAjLBraNp8r+oonFVpf4E2BLFKekoNVSFhTcxJ9EhtM=; b=M0Xl6RbaP8908zNGY910wnzDIIN8wnsZTBWQmhKTIEvbXBfBI7vPrhya4uLjW1FuB8 945OevGtcEYJ+itHVJCbZ34Eis8S1/G5AEc3oNAi8g+kXHXoI5n8e9VaBRhHwB6gwrRl Smu5oTSwSH9ypbWYxJWsLZaVYuXaSX1uA4ALhJ/oEbYeq33KJ+mlF3seqPe+doWeBVWz URBOPZMPeX7KGyOAV6qpDsjkZbhTPpwZMXI8zxAXDqFW6/8Si7OiIm+s9CNRrbPW/t+x y1tGrtycWCKSI/rkWTe80gCrXl+kpeIvmSyQwQcQvSBwwHEpHAZ0BbBVcGaedENWxoR5 2iHQ== 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 p33-v6si2409208pld.310.2018.02.16.10.51.01; Fri, 16 Feb 2018 10:51:15 -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 S1754504AbeBPI1n (ORCPT + 99 others); Fri, 16 Feb 2018 03:27:43 -0500 Received: from mga06.intel.com ([134.134.136.31]:4720 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754326AbeBPI1E (ORCPT ); Fri, 16 Feb 2018 03:27:04 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 16 Feb 2018 00:27:03 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.46,519,1511856000"; d="scan'208";a="204771811" Received: from helenma-mobl.ccr.corp.intel.com (HELO [10.255.28.216]) ([10.255.28.216]) by fmsmga006.fm.intel.com with ESMTP; 16 Feb 2018 00:27:02 -0800 Subject: Re: [PATCH] ipmi: kcs_bmc: mark expected switch fall-through in kcs_bmc_handle_data To: minyard@acm.org, "Gustavo A. R. Silva" , Arnd Bergmann , Greg Kroah-Hartman Cc: openipmi-developer@lists.sourceforge.net, linux-kernel@vger.kernel.org References: <20180214173029.GA15661@embeddedor.com> <9098c6c8-83e5-5e1f-519b-68e14738c24a@acm.org> From: "Wang, Haiyue" Message-ID: <3b2c65e6-a8bd-9b6c-5b13-c1d80f546215@linux.intel.com> Date: Fri, 16 Feb 2018 16:27:01 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <9098c6c8-83e5-5e1f-519b-68e14738c24a@acm.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2018-02-15 05:46, Corey Minyard wrote: > On 02/14/2018 11:30 AM, Gustavo A. R. Silva wrote: >> In preparation to enabling -Wimplicit-fallthrough, mark switch cases >> where we are expecting to fall through. > > Thanks, queued for next release. > > -corey > >> Addresses-Coverity-ID: 1465255 ("Missing break in switch") >> Signed-off-by: Gustavo A. R. Silva >> --- >> This code was compiled with GCC 7.3.0 >> >>   drivers/char/ipmi/kcs_bmc.c | 1 + >>   1 file changed, 1 insertion(+) >> >> diff --git a/drivers/char/ipmi/kcs_bmc.c b/drivers/char/ipmi/kcs_bmc.c >> index 3a3498a..6476bfb 100644 >> --- a/drivers/char/ipmi/kcs_bmc.c >> +++ b/drivers/char/ipmi/kcs_bmc.c >> @@ -95,6 +95,7 @@ static void kcs_bmc_handle_data(struct kcs_bmc >> *kcs_bmc) >>       switch (kcs_bmc->phase) { >>       case KCS_PHASE_WRITE_START: >>           kcs_bmc->phase = KCS_PHASE_WRITE_DATA; >> +        /* fall through */ Thanks, Gustavo. I see many modules have '/* fall through */', but I thought it was a just C comment, I didn't add it for making code clean. Learned it, thank you! :-) >>         case KCS_PHASE_WRITE_DATA: >>           if (kcs_bmc->data_in_idx < KCS_MSG_BUFSIZ) { > >