From patchwork Wed May 17 13:11:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 13244904 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3F73CC77B75 for ; Wed, 17 May 2023 13:13:30 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id CF51C900003; Wed, 17 May 2023 09:13:29 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id CA5DA280006; Wed, 17 May 2023 09:13:29 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B6DD1900007; Wed, 17 May 2023 09:13:29 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id AA1D4900003 for ; Wed, 17 May 2023 09:13:29 -0400 (EDT) Received: from smtpin02.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id 557F812053F for ; Wed, 17 May 2023 13:13:29 +0000 (UTC) X-FDA: 80799788538.02.A8445DC Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by imf27.hostedemail.com (Postfix) with ESMTP id 7D74440014 for ; Wed, 17 May 2023 13:13:27 +0000 (UTC) Authentication-Results: imf27.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=sUL++CNi; spf=pass (imf27.hostedemail.com: domain of arnd@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=arnd@kernel.org; dmarc=pass (policy=none) header.from=kernel.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1684329207; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=GVfsbqLiF9i79x+pHeUZZ1ybbBkINPX5Op88jIPkJDY=; b=8V9ld5eFDaGJ0JyvtpRDp7qrd1FMXNLN3yP7y/rHZ21lRlSZEU4iR+bgict79AfL1QWoGS bqzuo5GVoxNSrvNWxJtGQuMg4DuobfzLibDZMpPp4rXXPSsNGomvC+DGDJH1C0tRh1dRHg c5VufQfy3zQi2yRee3Ke1TZPf2MkP0o= ARC-Authentication-Results: i=1; imf27.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=sUL++CNi; spf=pass (imf27.hostedemail.com: domain of arnd@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=arnd@kernel.org; dmarc=pass (policy=none) header.from=kernel.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1684329207; a=rsa-sha256; cv=none; b=V3qmwC2AEDmycF9FUqRl2yke5K/bWf0DICol7kc0B3jZinP+vo0fPO4GpdWNEhcuvZWGUA DAX+C0EsRlMA7aSzNHviyKhQkUaD3REdsyd0EBRbjo+rkQYrFFmSLHB3HdYseg7FmPu+Ux 6gTqFmTMM60FaBf+ymDGrMBn9sPj57o= 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 A47C163E73; Wed, 17 May 2023 13:13:26 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E19EFC433A0; Wed, 17 May 2023 13:13:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1684329206; bh=JGGRsTfqJlmibWTBDdmhkqjrT8ru+5vGeLr90vAqN7A=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=sUL++CNilYTKBfXlj2dPw8lmLxduHSA+47PUjO45sLxz4n2hEzFLajiqXD05oRvI8 26qxQpUDKHthdA9YwLEN/YHntIwAjq5IVk/J7nX75CJFm0yAiW/fp8Unf6Rbj8LRNG UuAyk54JKmTtRzRbemmz9tzUGfiyIgAB+TQe5EXHbuj+wPEfM/oRJtkiWyMRQrpic3 qOjN6jBo+fGjO/IUX/iF6ln8D5N66od5Gncx4RdpQj8+TWomVhhGXJRHHJK3AEjfup 2fvc0cvn3xNc2dtggIu38wLBvRDjizWLgiEZ0mpy6+j/cgELWKA2rntPrjWLUxoYaK TbULgVLN3CPyA== From: Arnd Bergmann To: Andrew Morton Cc: linux-mm@kvack.org, Arnd Bergmann , Russell King , Catalin Marinas , Will Deacon , Michal Simek , Thomas Bogendoerfer , Helge Deller , Michael Ellerman , Palmer Dabbelt , Heiko Carstens , Thomas Gleixner , Ingo Molnar , x86@kernel.org, "Rafael J. Wysocki" , Paul Moore , Eric Paris , Dennis Zhou , Tejun Heo , Christoph Lameter , Pavel Machek , Peter Zijlstra , Waiman Long , Boqun Feng , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, linux-parisc@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, linux-sh@vger.kernel.org, audit@vger.kernel.org, linux-pm@vger.kernel.org, linux-kselftest@vger.kernel.org, kunit-dev@googlegroups.com Subject: [PATCH 14/14] time_namespace: always provide arch_get_vdso_data() prototype for vdso Date: Wed, 17 May 2023 15:11:02 +0200 Message-Id: <20230517131102.934196-15-arnd@kernel.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230517131102.934196-1-arnd@kernel.org> References: <20230517131102.934196-1-arnd@kernel.org> MIME-Version: 1.0 X-Rspam-User: X-Rspamd-Server: rspam01 X-Rspamd-Queue-Id: 7D74440014 X-Stat-Signature: 5cdmw9qu3sifocztuk44owsfwe7qeg1y X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vi6s31CZfgnONmZnRXu2I3X/yDpRByMYPux7zLtWIAYAg26qPyMxh1UNhNLAcbadiMagDfuaaQ1+ANdhZ1h6yxogqSG+flwbxnSuHP9efIbCSHfsPhXxGijubETQi8hcPJ6vgkSDJNYFv6mEzaz6o+Jqbcg5D0de0+VaWnWOrm9reJVUCCz5PmrVe5qApWLLgeBFEqMUq0FfyFs98Pzsw+AELYO3Xb/dmbOtUG5h/JuNA0u7wZ3UJQzW/156KcCzVOZo090O4jOapfl4lRsj0PF/x/mYJEFW2zfr2nsPLpbKg3itzpiBhSbHc779BQOjDGXrsYRY43uKUsdxM= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: From: Arnd Bergmann The arch_get_vdso_data() function is defined separately on each architecture, but only called when CONFIG_TIME_NS is set. If the definition is a global function, this causes a W=1 warning without TIME_NS: arch/x86/entry/vdso/vma.c:35:19: error: no previous prototype for 'arch_get_vdso_data' [-Werror=missing-prototypes] Move the prototype out of the #ifdef block to reliably turn off that warning. Signed-off-by: Arnd Bergmann --- include/linux/time_namespace.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/linux/time_namespace.h b/include/linux/time_namespace.h index bb9d3f5542f8..03d9c5ac01d1 100644 --- a/include/linux/time_namespace.h +++ b/include/linux/time_namespace.h @@ -44,7 +44,6 @@ struct time_namespace *copy_time_ns(unsigned long flags, struct time_namespace *old_ns); void free_time_ns(struct time_namespace *ns); void timens_on_fork(struct nsproxy *nsproxy, struct task_struct *tsk); -struct vdso_data *arch_get_vdso_data(void *vvar_page); struct page *find_timens_vvar_page(struct vm_area_struct *vma); static inline void put_time_ns(struct time_namespace *ns) @@ -163,4 +162,6 @@ static inline ktime_t timens_ktime_to_host(clockid_t clockid, ktime_t tim) } #endif +struct vdso_data *arch_get_vdso_data(void *vvar_page); + #endif /* _LINUX_TIMENS_H */