From patchwork Wed May 17 13:10:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 13244896 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 CD89EC7EE23 for ; Wed, 17 May 2023 13:12:28 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 68E00280005; Wed, 17 May 2023 09:12:28 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 63E10280003; Wed, 17 May 2023 09:12:28 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 52BE6280005; Wed, 17 May 2023 09:12:28 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id 423B5280003 for ; Wed, 17 May 2023 09:12:28 -0400 (EDT) Received: from smtpin15.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 1A9A3AD4EA for ; Wed, 17 May 2023 13:12:28 +0000 (UTC) X-FDA: 80799785976.15.9E0F259 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by imf25.hostedemail.com (Postfix) with ESMTP id 3F0E2A000B for ; Wed, 17 May 2023 13:12:25 +0000 (UTC) Authentication-Results: imf25.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=hhmQcB6W; dmarc=pass (policy=none) header.from=kernel.org; spf=pass (imf25.hostedemail.com: domain of arnd@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=arnd@kernel.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1684329146; 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=OKzeRdedpEc9gpshyDG/mck0jdPGYi7vz5VbYeuS6aU=; b=eTBz+WmWYscRu/P9TFb/8EqHCxoqgIkMOnPEGCDBL8f2vxfbKWijgVQ1ZMS3OHX+mqIhZi w9Lw5WULORcEou05SBGYPnc78OpqsJaMJhHP7JsX3K68a0NCCSpqX7kc3sFYPOL6uQrB3w z7epFdtyAd9gK+yItTLojbAZZm0RAKE= ARC-Authentication-Results: i=1; imf25.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=hhmQcB6W; dmarc=pass (policy=none) header.from=kernel.org; spf=pass (imf25.hostedemail.com: domain of arnd@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=arnd@kernel.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1684329146; a=rsa-sha256; cv=none; b=tEdUUNHDB5o21oTrOc9R/ReWzJ3l/u0x5yfAudAkLh3rj7iRQGQkgAOdtvYaZyFKDhnmEt J0IQ441nMoTDf+uM3zdpr/DobjihXLx56AHxkxEuBRAnTZVofSpMgCA90KZC2s3rlGpP3Q 3NS5qTq1aBt1eNN+AQveK+hN4z7CLs0= 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 5223764715; Wed, 17 May 2023 13:12:25 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7FF66C4339C; Wed, 17 May 2023 13:12:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1684329144; bh=gekqQcdwspAqcYmV4wkiul0gbNa5okADC3lRsox7SxY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=hhmQcB6Wb+ZcCRzLdjmx7/zFED4SNzs0NBaokc4G4Ef+SjGqplVRCUUlj8VOql7xc tVzUvC/YohY4HXanpHjF8gzBHtwkxcmoYXP+MIQ4qBiVNrFkbviwAVNhlQFEM5aG9z u0KG2wrGCIiO4fxkS7CsDg7SKssZvao8JQ1WexuQEtCpz47qaTuW3Z1bOQL/MmRcVt J43Gz9r687q17jYwvjwLN9fs0kn3xObEo5/anSq7dT5iAh0lVVtxnk6xLq54trRwvy bwp4gagapMiXtQeSik0KOYf0nVPAhKydrIyt2a5DIE7rfoyB8tfvUPUW3O+QL/VQu3 AKt6l4x3F+ppA== 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 06/14] locking: add lockevent_read() prototype Date: Wed, 17 May 2023 15:10:54 +0200 Message-Id: <20230517131102.934196-7-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-Stat-Signature: br8uybpzbjaddqt3ak881yabjhwacgei X-Rspam-User: X-Rspamd-Queue-Id: 3F0E2A000B X-Rspamd-Server: rspam07 X-HE-Tag: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H4P7BNuFnOGkiEfXIdXNIeYm0EOkGptm8dQS6w8tfDH81HoiKU9pieHOlE9d3FuifgsmVEz+lbY9O8w+m1WY9HOLi25TbbFa5jOQrhaTUeyMWCSEpQTLnCF71htCL9mqktXAr8v2bwlr/0R19Qmk0Dj+3kR+u4KnB6P11puNb6Da5RZXr/S4ygX78cedELYAdwZDllx0+lx517AuY+sZh8fa7LLhslZRSOViRHIiQ/xTWnIRaEbbOfaZMAn4fU+t5n6nx9NhOq+9FE6A1edGqOx/B72KVw7gQpRD3okGwVdoJfk7KxDvX5vridRW3ZlwJ9P8h4Y= 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 lockevent_read() has a __weak definition and the only caller in kernel/locking/lock_events.c, plus a strong definition in qspinlock_stat.h that overrides it, but no other declaration. This causes a W=1 warning: kernel/locking/lock_events.c:61:16: error: no previous prototype for 'lockevent_read' [-Werror=missing-prototypes] Add shared prototype to avoid the warnings. Signed-off-by: Arnd Bergmann --- kernel/locking/lock_events.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/kernel/locking/lock_events.h b/kernel/locking/lock_events.h index 8c7e7d25f09c..a6016b91803d 100644 --- a/kernel/locking/lock_events.h +++ b/kernel/locking/lock_events.h @@ -57,4 +57,8 @@ static inline void __lockevent_add(enum lock_events event, int inc) #define lockevent_cond_inc(ev, c) #endif /* CONFIG_LOCK_EVENT_COUNTS */ + +ssize_t lockevent_read(struct file *file, char __user *user_buf, + size_t count, loff_t *ppos); + #endif /* __LOCKING_LOCK_EVENTS_H */