From nobody Sun May 10 19:14:27 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B74CBC433EF for ; Wed, 27 Apr 2022 07:36:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1358920AbiD0HjZ (ORCPT ); Wed, 27 Apr 2022 03:39:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46266 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1358915AbiD0HjT (ORCPT ); Wed, 27 Apr 2022 03:39:19 -0400 Received: from mail.nfschina.com (unknown [IPv6:2400:dd01:100f:2:72e2:84ff:fe10:5f45]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 300959BACF for ; Wed, 27 Apr 2022 00:36:06 -0700 (PDT) Received: from localhost (unknown [127.0.0.1]) by mail.nfschina.com (Postfix) with ESMTP id E25951E80D5E; Wed, 27 Apr 2022 15:32:43 +0800 (CST) X-Virus-Scanned: amavisd-new at test.com Received: from mail.nfschina.com ([127.0.0.1]) by localhost (mail.nfschina.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id TNAfY1qQKF8J; Wed, 27 Apr 2022 15:32:41 +0800 (CST) Received: from localhost.localdomain (unknown [117.136.0.154]) (Authenticated sender: kunyu@nfschina.com) by mail.nfschina.com (Postfix) with ESMTPA id E01EA1E80D2D; Wed, 27 Apr 2022 15:32:40 +0800 (CST) From: Li kunyu To: ebiederm@xmission.com, keescook@chromium.org, tglx@linutronix.de, elver@google.com Cc: oleg@redhat.com, legion@kernel.org, linux-kernel@vger.kernel.org, Li kunyu Subject: [PATCH] kernel: Optimize unused integer return values Date: Wed, 27 Apr 2022 15:34:48 +0800 Message-Id: <20220427073448.10730-1-kunyu@nfschina.com> X-Mailer: git-send-email 2.18.2 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Optimize unused integer return values Signed-off-by: Li kunyu Reported-by: kernel test robot --- kernel/signal.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/kernel/signal.c b/kernel/signal.c index 30cd1ca43bcd..ae58a966c8de 100644 --- a/kernel/signal.c +++ b/kernel/signal.c @@ -3464,7 +3464,7 @@ int __copy_siginfo_to_user32(struct compat_siginfo __= user *to, return 0; } =20 -static int post_copy_siginfo_from_user32(kernel_siginfo_t *to, +static void post_copy_siginfo_from_user32(kernel_siginfo_t *to, const struct compat_siginfo *from) { clear_siginfo(to); @@ -3548,7 +3548,8 @@ static int __copy_siginfo_from_user32(int signo, stru= ct kernel_siginfo *to, return -EFAULT; =20 from.si_signo =3D signo; - return post_copy_siginfo_from_user32(to, &from); + post_copy_siginfo_from_user32(to, &from); + return 0; } =20 int copy_siginfo_from_user32(struct kernel_siginfo *to, @@ -3559,7 +3560,8 @@ int copy_siginfo_from_user32(struct kernel_siginfo *t= o, if (copy_from_user(&from, ufrom, sizeof(struct compat_siginfo))) return -EFAULT; =20 - return post_copy_siginfo_from_user32(to, &from); + post_copy_siginfo_from_user32(to, &from); + return 0; } #endif /* CONFIG_COMPAT */ =20 --=20 2.18.2