Message ID | 20230704201056.3352-1-zeming@nfschina.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9f45:0:b0:3ea:f831:8777 with SMTP id v5csp262855vqx; Sun, 2 Jul 2023 20:48:00 -0700 (PDT) X-Google-Smtp-Source: APBJJlG6B2YyKYoHOjcUhUhaXtD/Ns0/BLnezjQsIoJmi+3huRYoOPnVMCprSF4QheBPb1pD/o6i X-Received: by 2002:a05:6a00:1d05:b0:67d:308b:97ef with SMTP id a5-20020a056a001d0500b0067d308b97efmr10533376pfx.2.1688356080678; Sun, 02 Jul 2023 20:48:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688356080; cv=none; d=google.com; s=arc-20160816; b=zA4GmuBtRXMyhgQN3ULQKH5RCF0eS9V6Cg4F5tf9DPVt7Sh6Eh/fiM9+HtAL5xsXHD f7hAIRkEqPN+lpu4wnyk7cMRQHiDWKY0zyQh76qQ0rCZDS6dyFebUqnj6XRMEtWLby4F Tbcrv0v+kssYcy9tW8DUjuMUlNXLD5tDbll4da+6aAw8gYlYRlLRnljpzZ3SAmDVJ5t7 Moc4QFSWdBCkkceadwEzkuX6ZPvNeDGyr+WFMYOl8h/WoW89dP27SfH7hXiv/KNuA7rM KfEjjNBJWAZ97gnNxoxR7f5QQW1EdTTzj1GN9wPV7OOw539QnTYKIpXdiES/HXqqZ5Dp fnng== 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 :message-id:date:subject:cc:to:from; bh=HyysLXI6Wdq/NTfrXqefDS0k0w1pocUm56M2Jhqy9pc=; fh=MDcLyW7gnQ7zhVrwu4ydSY34K8iXsxgpLnkzEl2cuwA=; b=zgpXTQGp/G9Nb1T8oHrXCjAZ2Ips8XyB3MB8YZz3Et5Cy+bQzMTejIU1IuB7a3cegf 1EpcNQseP9NY8fnr7WEZtZEELv6Y5cGDY/I45Csecssm9EdfzaaA8Ic/9WoA2aI9l7Sk nx747n/LAxAVN25ZsuBP7s13CwrPtWF+ksQXp0sWsDxkhmFOE/usN2szTkpJ+xdky+7S UetQjHxniQKXlhVBDQk8abqSRNw+759D7yUsGmr5W/47F18QbeBBjIddxizck8UbSE69 PsTkiwLpyH/9Hh4TdYRVA6lLJtxyS0StB91kZEI6eQWDLWpxDEDh9UC108C2S+lDaUn8 UgTQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x31-20020a056a00189f00b0066db06a5cf1si17502800pfh.43.2023.07.02.20.47.48; Sun, 02 Jul 2023 20:48:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229899AbjGCDju (ORCPT <rfc822;ivan.orlov0322@gmail.com> + 99 others); Sun, 2 Jul 2023 23:39:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34076 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229482AbjGCDjs (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Sun, 2 Jul 2023 23:39:48 -0400 Received: from mail.nfschina.com (unknown [42.101.60.195]) by lindbergh.monkeyblade.net (Postfix) with SMTP id 60B23123; Sun, 2 Jul 2023 20:39:47 -0700 (PDT) Received: from localhost.localdomain (unknown [219.141.250.2]) by mail.nfschina.com (Maildata Gateway V2.8.8) with ESMTPA id C32586091588A; Mon, 3 Jul 2023 11:39:37 +0800 (CST) X-MD-Sfrom: zeming@nfschina.com X-MD-SrcIP: 219.141.250.2 From: Li zeming <zeming@nfschina.com> To: naveen.n.rao@linux.ibm.com, anil.s.keshavamurthy@intel.com, davem@davemloft.net, mhiramat@kernel.org Cc: linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org, Li zeming <zeming@nfschina.com> Subject: [PATCH] =?utf-8?q?kernel=3A_kprobes=3A_Remove_unnecessary_=E2=80=98?= =?utf-8?q?0=E2=80=99_values_from_ret?= Date: Wed, 5 Jul 2023 04:10:56 +0800 Message-Id: <20230704201056.3352-1-zeming@nfschina.com> X-Mailer: git-send-email 2.18.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=0.9 required=5.0 tests=BAYES_00,DATE_IN_FUTURE_24_48, RDNS_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1770369665614953533?= X-GMAIL-MSGID: =?utf-8?q?1770369665614953533?= |
Series |
kernel: kprobes: Remove unnecessary ‘0’ values from ret
|
|
Commit Message
Li zeming
July 4, 2023, 8:10 p.m. UTC
ret is assigned first, so it does not need to initialize the assignment.
Signed-off-by: Li zeming <zeming@nfschina.com>
---
kernel/kprobes.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Comments
On Wed, 5 Jul 2023 04:10:56 +0800 Li zeming <zeming@nfschina.com> wrote: > ret is assigned first, so it does not need to initialize the assignment. > OK, but can you merge this to the first one? https://lore.kernel.org/all/20230704192107.2944-1-zeming@nfschina.com/ Thank you, > Signed-off-by: Li zeming <zeming@nfschina.com> > --- > kernel/kprobes.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/kernel/kprobes.c b/kernel/kprobes.c > index ec50f9f380c1..a009c8ccd8ea 100644 > --- a/kernel/kprobes.c > +++ b/kernel/kprobes.c > @@ -2692,7 +2692,7 @@ void kprobe_free_init_mem(void) > > static int __init init_kprobes(void) > { > - int i, err = 0; > + int i, err; > > /* FIXME allocate the probe table, currently defined statically */ > /* initialize all list heads */ > -- > 2.18.2 >
diff --git a/kernel/kprobes.c b/kernel/kprobes.c index ec50f9f380c1..a009c8ccd8ea 100644 --- a/kernel/kprobes.c +++ b/kernel/kprobes.c @@ -2692,7 +2692,7 @@ void kprobe_free_init_mem(void) static int __init init_kprobes(void) { - int i, err = 0; + int i, err; /* FIXME allocate the probe table, currently defined statically */ /* initialize all list heads */