From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1030626AbeAONcN (ORCPT + 1 other); Mon, 15 Jan 2018 08:32:13 -0500 Received: from mx1.redhat.com ([209.132.183.28]:2226 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S966769AbeAONcK (ORCPT ); Mon, 15 Jan 2018 08:32:10 -0500 Subject: Re: arch/x86/kvm/x86.c:7111:23: warning: this statement may fall through [-Wimplicit-fallthrough=] To: David Binderman , "rkrcmar@redhat.com" , "tglx@linutronix.de" , "mingo@redhat.com" , "hpa@zytor.com" , "x86@kernel.org" , "kvm@vger.kernel.org" , "linux-kernel@vger.kernel.org" References: From: Paolo Bonzini Message-ID: Date: Mon, 15 Jan 2018 14:32:06 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Language: en-US Content-Transfer-Encoding: 8bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Mon, 15 Jan 2018 13:32:09 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: On 15/01/2018 13:34, David Binderman wrote: > Hello there, > > > Source code is > > >     switch(vcpu->arch.mp_state) { >     case KVM_MP_STATE_HALTED: >         vcpu->arch.pv.pv_unhalted = false; >         vcpu->arch.mp_state = >             KVM_MP_STATE_RUNNABLE; >     case KVM_MP_STATE_RUNNABLE: >         vcpu->arch.apf.halted = false; >         break; > > Suggest either add the missing break or add a fallthrough comment. It's meant to be a fall-through to the "runnable" case (note that mp_state becomes KVM_MP_STATE_RUNNABLE at the end of the first "case"). Would you like to post a patch yourself? Thanks, Paolo > > > Regards > > > David Binderman > >