Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2146534rwd; Wed, 17 May 2023 06:27:12 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5Bw3E+EV0yZ3oX/TLLsJWO/q/TG93eumS0YDvI06oI92y/VdnkNyDgVsZpSx32hBwKzAtx X-Received: by 2002:a05:6a20:8e19:b0:105:12ab:8785 with SMTP id y25-20020a056a208e1900b0010512ab8785mr8563239pzj.9.1684330032343; Wed, 17 May 2023 06:27:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684330032; cv=none; d=google.com; s=arc-20160816; b=SPXsKoSpzkWGtLUoHNpLi3VYK6QcubS99grQanFP2Kn1blpbIMpOTwnLDUvim5o3KD plrD7Jl4XAdvCrcmyjv0d/Yx874aloZZjHcK5I1ZlBwrQVC9Cqw6L2Sz50VkpwksmWSB ExatPCsHTudnf8T67uZgmo20gmJ69RgFozkeJkmmfg9Cue/SfN6C2bZ3XKqf0yMcZvYH xT5b9xSpU4AXrMxuFIvHmAGPTsao19ZxYJiPJ+xbwLLfoCXlonjwOl+yFf0Q2ZYnagEc H5iGVpYHNzt+UzkUATmx+tAiri09t5EeYbbA54oqWKXRdroE3cTzKJLUiSO2uvCwTFTJ UF2g== 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:date:subject:cc:to:from :dkim-signature; bh=GVfsbqLiF9i79x+pHeUZZ1ybbBkINPX5Op88jIPkJDY=; b=j2j65hnFFy6qQ6AWIo6IOlWOPnjtwPtWGxnLB0zpJB0kxHld+D5g4mXwMlAVI3c8kP KVdxXfvTbDJ12fbvPPxbJUI+xUcvYMFKiK3mrrbwto5AotJcP9B/RXiP0EvRwZJK0CHD lPmM2G+L+cqmImX+eA7sQ07+1as8BhB425vGIZvd5SafVIXvTFZ2nN734NXpHhnCvLNs h2vJzYDNSwnMN+nTObLXUR1ikT3+umts4yi+b7MIKvVmIlQQnJQBL9z/0OYkblptLAy7 ZnXF4KjBuyqDqCUWAyuAVFyvvo/R1jO3eg83XdDFAyeze4mckWPWPb42PT7MkKrvuXk9 rRjg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=sUL++CNi; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id l71-20020a63914a000000b005308b2910c5si15267698pge.338.2023.05.17.06.26.58; Wed, 17 May 2023 06:27:12 -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=sUL++CNi; 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 S232071AbjEQNN4 (ORCPT + 99 others); Wed, 17 May 2023 09:13:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52016 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232001AbjEQNNo (ORCPT ); Wed, 17 May 2023 09:13:44 -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 947EE7D86; Wed, 17 May 2023 06:13:27 -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 A8129642AE; 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 Content-Transfer-Encoding: 8bit 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 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 */ -- 2.39.2