From patchwork Wed Jun 7 14:28:45 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 104546 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp253389vqr; Wed, 7 Jun 2023 07:47:39 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7hQPpXKWN397ptYNj9mG9uwlEtww6Hzu24T0oImG34rFPoq5h82czcu4ZBA999P6dwHa83 X-Received: by 2002:a05:6a21:151a:b0:10e:f1e3:8217 with SMTP id nq26-20020a056a21151a00b0010ef1e38217mr1080824pzb.17.1686149259586; Wed, 07 Jun 2023 07:47:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686149259; cv=none; d=google.com; s=arc-20160816; b=BG9acpS0EoO4ZJ82Oh8QrGOwWyjlISLsRyohgfOfLLpgQ9eobu3BVeAy7MnAjd+eUy txLC31PDldqCmKKiz3oqPZ3vNEkZD6AmZx795SGo3FYgO/b+zPHBNkYymUMhRUs/ERXb rHnrlz+sW1Dkoyx70R78LFXHZnA6MGVdA6KtYY2wGMGluWCYolyW6vcNbIhtbeUxtbjk JFIJigEuSRNrFAC4jTP9zhOWBxOtBWQTsJNw4EasGQJBplYBSHWM16FKo/9mXBZS9uT2 vDiZnKDSJHUQoke5RbVhlghWyIQTvFZzI5Ur6hvlQug19lA/HNTG6QHGTLFb5YFGU5xi zMTQ== 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:dkim-signature; bh=/KXsPdtlze5p3MMaQ3nDdUq0gBoFKSii6qRyoTqVJ7k=; b=DhR9B6eNKK5Zysm4QrBQcXg5bQnQO6viGY9qm9LT4E5issjnKz+E3CvHPvE0ghyb7m VPDXw9LzZp3t9yXMDdONxB8x2MDj4OBGSWrTJ0iynGqQs/mSwIo8GhyCdu6yA7WujCwb 6YRfxc9zzy8CIdw/hcpew1lGfVIb1t6HxP4+7oyJO1bpi3W9iB11x4YMWUH0aL5a46h7 Z1dbf1UTEP3m2GndAnCbUbwHyUYtrq5/MgtUTmiwsVkbO09Cya8ko9ohcQI4x4t5+PPB h3lwBnkwFWAAzwHTbuwKYXNTkVjEEyOfkGA9BVc+jrZ8Km3nNhlphGIKjgljZz8vqSAW zR0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=YkDMsm6w; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t5-20020a170902e84500b001ab0e3e0c1asi9302605plg.553.2023.06.07.07.47.24; Wed, 07 Jun 2023 07:47:39 -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; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=YkDMsm6w; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235414AbjFGO3i (ORCPT + 99 others); Wed, 7 Jun 2023 10:29:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56306 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239550AbjFGO3h (ORCPT ); Wed, 7 Jun 2023 10:29:37 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 403F31AE; Wed, 7 Jun 2023 07:29:36 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id C75E06100A; Wed, 7 Jun 2023 14:29:35 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 41D04C433EF; Wed, 7 Jun 2023 14:29:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1686148175; bh=1oDAIKxqgonf8S4LzAAuCNQtNjMJBLSiZTFS9TB1jIU=; h=From:To:Cc:Subject:Date:From; b=YkDMsm6w7qGxO3FxoqRiqvl4sX8dmEbs9oajMHBUjJdvy3sNOV0h2g1z6zYtoaO6y F+VUHFf4V1ReVfsVnktrUVqJgszeG8b+ocxybxUNsPXGoC+Tx0uYyPaUwcuAZ7+gRZ 69hKhJAhjFL1MNCc92xGVPP8ICfnBRUbzuQuZiqQFWelr4eV06qitlMbneZXW5uWQz uFs4R5l7UmAJHmF0CTYoEDhm7hSq4oIv8Wa3FvJAHqqzCH0/6uHO773Ly1bz/61YJZ oAczK+G2I9Psnt7Jv/HeFkaqBTL0VLmntQsqwOfzvvr/3tW3HDpwV5bcVgkMKJhvFj PEU5tC0IK0smQ== From: Arnd Bergmann To: Andrew Morton Cc: Arnd Bergmann , Richard Henderson , Ivan Kokshaysky , Matt Turner , Kees Cook , "Eric W. Biederman" , Borislav Petkov , Thomas Gleixner , Jann Horn , linux-alpha@vger.kernel.org, linux-kernel@vger.kernel.org, linux-api@vger.kernel.org Subject: [PATCH] syscalls: add sys_ni_posix_timers prototype Date: Wed, 7 Jun 2023 16:28:45 +0200 Message-Id: <20230607142925.3126422-1-arnd@kernel.org> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1768055646206386130?= X-GMAIL-MSGID: =?utf-8?q?1768055646206386130?= From: Arnd Bergmann The sys_ni_posix_timers() definition causes a warning when the declaration is missing, so this needs to be added along with the normal syscalls, outside of the #ifdef. kernel/time/posix-stubs.c:26:17: error: no previous prototype for 'sys_ni_posix_timers' [-Werror=missing-prototypes] Signed-off-by: Arnd Bergmann Reviewed-by: Kees Cook --- I missed sending this out in the initial submission of my Wmissing-prototype patches --- arch/alpha/kernel/osf_sys.c | 2 -- include/linux/syscalls.h | 1 + kernel/time/posix-stubs.c | 1 + 3 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/alpha/kernel/osf_sys.c b/arch/alpha/kernel/osf_sys.c index 2a9a877a05083..d98701ee36c6a 100644 --- a/arch/alpha/kernel/osf_sys.c +++ b/arch/alpha/kernel/osf_sys.c @@ -1014,8 +1014,6 @@ SYSCALL_DEFINE2(osf_settimeofday, struct timeval32 __user *, tv, return do_sys_settimeofday64(tv ? &kts : NULL, tz ? &ktz : NULL); } -asmlinkage long sys_ni_posix_timers(void); - SYSCALL_DEFINE2(osf_utimes, const char __user *, filename, struct timeval32 __user *, tvs) { diff --git a/include/linux/syscalls.h b/include/linux/syscalls.h index 4627b9cf4b4d9..712f4e1dc6a69 100644 --- a/include/linux/syscalls.h +++ b/include/linux/syscalls.h @@ -1286,6 +1286,7 @@ asmlinkage long sys_ni_syscall(void); #endif /* CONFIG_ARCH_HAS_SYSCALL_WRAPPER */ +asmlinkage long sys_ni_posix_timers(void); /* * Kernel code should not call syscalls (i.e., sys_xyzyyz()) directly. diff --git a/kernel/time/posix-stubs.c b/kernel/time/posix-stubs.c index 828aeecbd1e8a..39769b2d1005e 100644 --- a/kernel/time/posix-stubs.c +++ b/kernel/time/posix-stubs.c @@ -16,6 +16,7 @@ #include #include #include +#include #ifdef CONFIG_ARCH_HAS_SYSCALL_WRAPPER /* Architectures may override SYS_NI and COMPAT_SYS_NI */