Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp3857025rdh; Fri, 29 Sep 2023 04:42:52 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHttXyexbDU3FtRzu3lGURRQQpve//7wMcmZbyONl47b3IRM9+n5Bs//VKUI3dGqHdOXcAH X-Received: by 2002:a05:6a20:1456:b0:15e:dc75:66a7 with SMTP id a22-20020a056a20145600b0015edc7566a7mr4012034pzi.24.1695987772503; Fri, 29 Sep 2023 04:42:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695987772; cv=none; d=google.com; s=arc-20160816; b=JcePMLdONShP8krrdtzviKlEd9P30mmOIhbpBQOgu8sukhpzVKm0oMDc9DbHKOWBz+ vcNKzVZDz86MCZeCwihia9qXyR1acciwjWafbD3Meiw4E3xwP2cHWQzLpIlsotrp2yRd IgMif5DsupW6Q4n+TGkTHuaWXogLlYfabioXs8e8r6NTo/3TGBKbA/NeILo9q2w7FnxN q6RathZmVqkrmTdl0hq5NRYILEoS3gzMKVi7kkO5qcIeD3/03RR8Cj2JwUqPhwVPViEK 7PkBJWY9a1AoVKV4+wNsX23dCNxES2AG3W3ZMjGxoFy+oLyd7coGCq1Zeb2BToyMgFrl LgJw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=ic+NR5qfY8/fztBsnMcqlAiuCjbt5D8q/7Kb4UyI4zA=; fh=MJ46qFuEW/qkQCGw4sIVh2k52VzNKuZMegNkl7iTbho=; b=gwGMSlI6ioDMwPRONGCgPwAdq2tgA2tjr6p3Gaqjvm0OHTxra1OkZv1W33/kyMXLP9 D1Ih8DNk+N9OobfZQNWwCedpbx6+PeXnOKnQKhZlvZyfQEWabXnoQONXNo6O5YJKFiRd 9p2Uq8KHbA2IxRNm/FHg9dU0YfWN5Rqrygs8HZMnlB0I/5RwCQy43nE8Dou1yc/S7+po uVGtEcDlQNY6RFiiNyjNJvPMsyH1FQkC3Tj2YVIbFBh5DQrrb9sBfQ0LvWXK63sIbC4p 6BDgkGTTyhbB1hoZIwzj+l28a3GHRbrPZBw2e/EwHUvdvN26W3vSdUeGTf1vNi3XzEm/ r1Sw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=QEOxmNpB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 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 agentk.vger.email (agentk.vger.email. [2620:137:e000::3:2]) by mx.google.com with ESMTPS id p13-20020a170902e74d00b001c72dbaf7b9si6628903plf.415.2023.09.29.04.42.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Sep 2023 04:42:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) client-ip=2620:137:e000::3:2; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=QEOxmNpB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id B4CC381C36F6; Fri, 29 Sep 2023 04:33:13 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232993AbjI2LdH (ORCPT + 99 others); Fri, 29 Sep 2023 07:33:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59124 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229508AbjI2LdF (ORCPT ); Fri, 29 Sep 2023 07:33:05 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F2C4A94; Fri, 29 Sep 2023 04:33:03 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id CE011C433C7; Fri, 29 Sep 2023 11:33:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1695987183; bh=ext+jvw1wYtQkqXLamyev8P69HV+CW6d/4Z5KiCqMTg=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=QEOxmNpBXq8nrAg8/RoyOmmBLqY0ECrXlK6QkmYCZPBFdtNUj8vjAtiqhRLxiz6Hv +vtzZReLChWzpZpzsH3MEOYzv3i9Gq29+Zs+wZH/WyKkc5xfUH1QAT0pIUu+oRDnxK bOR12gEBo4TZfB80OzxrLCWjJ/HioOBE5nJHrKOiiV1pPV1NstVEgy8n1L1PFoKQuQ p+xqKgpCAS5ldtY+89v9MFKEoFjhw5v0vU/ZV3fCfNxPa36nBRuSw7XOjA96/UoHld 2teBaiOJKqJ///DhEn4CpukRShl+iar2k1IcSg+9kbFMuh0ZC7gmsb29F5LsvFIIgB JFgBkXWy9jQzg== Date: Fri, 29 Sep 2023 20:32:59 +0900 From: Masami Hiramatsu (Google) To: Julia Lawall Cc: Steven Rostedt , kernel-janitors@vger.kernel.org, Masami Hiramatsu , linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org Subject: Re: [PATCH] tracing/eprobe: drop unneeded breaks Message-Id: <20230929203259.74d4ba263b3455172ef37f06@kernel.org> In-Reply-To: <20230928104334.41215-1-Julia.Lawall@inria.fr> References: <20230928104334.41215-1-Julia.Lawall@inria.fr> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.5 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI,NICE_REPLY_A, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Fri, 29 Sep 2023 04:33:13 -0700 (PDT) On Thu, 28 Sep 2023 12:43:34 +0200 Julia Lawall wrote: > Drop break after return. > Good catch! This looks good to me. Acked-by: Masami Hiramatsu (Google) And Fixes: 7491e2c44278 ("tracing: Add a probe that attaches to trace events") > Signed-off-by: Julia Lawall > > --- > kernel/trace/trace_eprobe.c | 5 +---- > 1 file changed, 1 insertion(+), 4 deletions(-) > > diff --git a/kernel/trace/trace_eprobe.c b/kernel/trace/trace_eprobe.c > index 72714cbf475c..03c851f57969 100644 > --- a/kernel/trace/trace_eprobe.c > +++ b/kernel/trace/trace_eprobe.c > @@ -788,12 +788,9 @@ find_and_get_event(const char *system, const char *event_name) > name = trace_event_name(tp_event); > if (!name || strcmp(event_name, name)) > continue; > - if (!trace_event_try_get_ref(tp_event)) { > + if (!trace_event_try_get_ref(tp_event)) > return NULL; > - break; > - } > return tp_event; > - break; > } > return NULL; > } > -- Masami Hiramatsu (Google)