Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp1683217pxk; Fri, 2 Oct 2020 16:37:50 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyr75mn2b0aVO1kFMkYEFggsbxEPCrR+c154zbzDRNqNq5ACHLCsgIjiSPrPjiWlFFluV2/ X-Received: by 2002:a17:906:5f8a:: with SMTP id a10mr4358227eju.502.1601681870652; Fri, 02 Oct 2020 16:37:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601681870; cv=none; d=google.com; s=arc-20160816; b=Xk5hPdC//WmpvhvnCk6ahDKIxVXq+klOECdMPJifxzPPrKhvIzDnH/XIKCituzNwus 7W6JzGjFLp3azFCxJPfMFIE7qCPTzrZhfKo21kRnZ3ajt+3DP+BIr7S8Z/SJDPW1pFc+ VdECUhRuZ8SxV9jfrM9zsXORZ23SZOEo53NNoh4u1ff5M7gOeZtCOZ3znDLtzqyaBCbW DE4RbpzjrJkoQdpwyQnZksm/4mL/+0nPcT17c9JphnKFtgUUt6bpsR/wSlJiZ8uvNtFX auLe/1RWovXoy45Y9/aiMVCHiFblLCyYZb+RKpHQNN/K6yvG6Bdms31w5GGktMz7M+ix YdQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:content-disposition:mime-version :message-id:subject:cc:to:from:date:dkim-signature; bh=0nXMZJjA8XWd6IifATwAH9fABHd8tp9Yl6bxw3LnDN0=; b=KCeOBiVSIaW63Z2rYaNRDK4D+pzhUi+Z2tOhsii71LdyjV1znhYJoRRHHaDC1fJQTK yyOfr+I5lSeb0QlIQwyr8exb1dkIVuQYfD/GoB7VjynUno1Vk/JWI2LfdXbzY0hOR2js NlktAFObDHbHMlLf3aaDNvXey4tF7fX3rOBO4ywqDTXVQWZPj8xME2loPzNw3li12enL vwhMDAwzYlZ/qhrEY8z8uUN8w0NDCPJjpUx2sVcmbR96c+KrFLrbDulglqTicihvUk7K W7M/ZMd024k0SHxZ/gABx/xuiq3e9IvPS8zWUjijiI74Pf88WWsh0jrT62E8cFJpzjKe XBSQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="VhJb/GwO"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a3si2106469edn.245.2020.10.02.16.37.28; Fri, 02 Oct 2020 16:37:50 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="VhJb/GwO"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725764AbgJBXg3 (ORCPT + 99 others); Fri, 2 Oct 2020 19:36:29 -0400 Received: from mail.kernel.org ([198.145.29.99]:35444 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725283AbgJBXg3 (ORCPT ); Fri, 2 Oct 2020 19:36:29 -0400 Received: from embeddedor (187-162-31-110.static.axtel.net [187.162.31.110]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 8EFBD206B7; Fri, 2 Oct 2020 23:36:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1601681788; bh=iOVObYJsM+EFNqUv+ULTp5M07bWQLZYcS5493ovJNM4=; h=Date:From:To:Cc:Subject:From; b=VhJb/GwO/mAoRHW9/eBJv4/NvJiJX94JViRvsHucqBIgoPhRJjxsMM51Q9/yYoSYm CbefN5tC9q9a7mTBdA/BhW9lu+8gyo8mDhTRv0Vh2Euz1DmowE6LkwSNkoA6sahnjT /eIh+XhXj6eIS5MNieK40/WwquhUCt/B3VZrcMVM= Date: Fri, 2 Oct 2020 18:42:17 -0500 From: "Gustavo A. R. Silva" To: Alexei Starovoitov , Daniel Borkmann , Martin KaFai Lau , Song Liu , Yonghong Song , Andrii Nakryiko , John Fastabend , KP Singh Cc: netdev@vger.kernel.org, bpf@vger.kernel.org, linux-kernel@vger.kernel.org, "Gustavo A. R. Silva" , linux-hardening@vger.kernel.org Subject: [PATCH][next] bpf: verifier: Use fallthrough pseudo-keyword Message-ID: <20201002234217.GA12280@embeddedor> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.9.4 (2018-02-28) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Replace /* fallthrough */ comments with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva --- kernel/bpf/verifier.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/bpf/verifier.c b/kernel/bpf/verifier.c index 015a1c074b6b..fcef04b80b66 100644 --- a/kernel/bpf/verifier.c +++ b/kernel/bpf/verifier.c @@ -2667,7 +2667,7 @@ static bool may_access_direct_pkt_data(struct bpf_verifier_env *env, case BPF_PROG_TYPE_CGROUP_SKB: if (t == BPF_WRITE) return false; - /* fallthrough */ + fallthrough; /* Program types with direct read + write access go here! */ case BPF_PROG_TYPE_SCHED_CLS: @@ -5432,7 +5432,7 @@ static int adjust_ptr_min_max_vals(struct bpf_verifier_env *env, /* smin_val represents the known value */ if (known && smin_val == 0 && opcode == BPF_ADD) break; - /* fall-through */ + fallthrough; case PTR_TO_PACKET_END: case PTR_TO_SOCKET: case PTR_TO_SOCKET_OR_NULL: -- 2.27.0