From nobody Wed May 22 02:07:52 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 171041913599015.036477094694078; Thu, 14 Mar 2024 05:25:35 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.693179.1080903 (Exim 4.92) (envelope-from ) id 1rkk95-0004ms-Pa; Thu, 14 Mar 2024 12:25:15 +0000 Received: by outflank-mailman (output) from mailman id 693179.1080903; Thu, 14 Mar 2024 12:25:15 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1rkk95-0004ml-Mv; Thu, 14 Mar 2024 12:25:15 +0000 Received: by outflank-mailman (input) for mailman id 693179; Thu, 14 Mar 2024 12:25:14 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1rkk94-0004mf-U1 for xen-devel@lists.xenproject.org; Thu, 14 Mar 2024 12:25:14 +0000 Received: from support.bugseng.com (mail.bugseng.com [162.55.131.47]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id e7c3289b-e1fd-11ee-a1ee-f123f15fe8a2; Thu, 14 Mar 2024 13:25:12 +0100 (CET) Received: from truciolo.bugseng.com (unknown [78.209.105.118]) by support.bugseng.com (Postfix) with ESMTPSA id 805554EE0739; Thu, 14 Mar 2024 13:25:11 +0100 (CET) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: e7c3289b-e1fd-11ee-a1ee-f123f15fe8a2 From: Federico Serafini To: xen-devel@lists.xenproject.org Cc: consulting@bugseng.com, Federico Serafini , Andrew Cooper , George Dunlap , Jan Beulich , Julien Grall , Stefano Stabellini , Wei Liu Subject: [XEN PATCH] perfc: add pseudo-keyword fallthrough Date: Thu, 14 Mar 2024 13:25:02 +0100 Message-Id: <47eb1f8316672af172d9c34bfa6e7dda6bd7ce37.1710403601.git.federico.serafini@bugseng.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZM-MESSAGEID: 1710419137957100001 Content-Type: text/plain; charset="utf-8" Add pseudo-keyword fallthrough to make explicit the intention of the code and meet requirements to deviate MISRA C:2012 Rule 16.3 ("An unconditional `break' statement shall terminate every switch-clause"). No functional change. Signed-off-by: Federico Serafini Acked-by: Jan Beulich --- xen/common/perfc.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/xen/common/perfc.c b/xen/common/perfc.c index 7400667bf0..80480aa776 100644 --- a/xen/common/perfc.c +++ b/xen/common/perfc.c @@ -134,6 +134,7 @@ void cf_check perfc_reset(unsigned char key) case TYPE_SINGLE: for_each_online_cpu ( cpu ) per_cpu(perfcounters, cpu)[j] =3D 0; + fallthrough; case TYPE_S_SINGLE: ++j; break; @@ -141,6 +142,7 @@ void cf_check perfc_reset(unsigned char key) for_each_online_cpu ( cpu ) memset(per_cpu(perfcounters, cpu) + j, 0, perfc_info[i].nr_elements * sizeof(perfc_t)); + fallthrough; case TYPE_S_ARRAY: j +=3D perfc_info[i].nr_elements; break; --=20 2.34.1