Received: by 2002:a05:6358:701b:b0:131:369:b2a3 with SMTP id 27csp3036762rwo; Mon, 24 Jul 2023 05:27:55 -0700 (PDT) X-Google-Smtp-Source: APBJJlGnqs8KmdYTCVuwpI3vCQR922oBlCGT+CUgqwmwVK+VTsus4oB24ajgbqvb1dJXvYqfT+XA X-Received: by 2002:a05:6e02:d4a:b0:345:af1c:29c4 with SMTP id h10-20020a056e020d4a00b00345af1c29c4mr5100443ilj.25.1690201675288; Mon, 24 Jul 2023 05:27:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690201675; cv=none; d=google.com; s=arc-20160816; b=FRdBY7Eb3vjBOieb4tHQDrbtgDnZdoxPX54Y82NPorJHmW9VTMlpnPVTFzqbJkSyfG fH89D7asDcWFHfkIGQbxYFOyyqOHu2XoZG8NbqL/fSGxMLvAbiEw9AEbmsvWownBB4z1 FnySG+QChMR+D9YNjYoVGsV6dKAoxFK4ER2j+InAs7gWoPZcGh5t7wGex1HSZ7Ybd5yA PXLsk8pwPznrWadUtLWyTKeaB3oN9PgLh3DfCzf1DU09clHy4IPIKmP5NdRXda/4yGij AL8oqjJAwVsNTVNcg/oOgAzh6QJphWTX+NyI5PuVZroF8ExmV+1pmxnCrStV0nMJOgMb DxFA== 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=fVBJNvo0vpEOVvbi8tDH1SUCnXDkNFPI+kemETRFq+U=; fh=xL82IOqQdfdNiudujm9n8zcaD6Z4+1QBDj4sXt+muv4=; b=FXZsc12JmSEgTvKpbL8k07r5+5pH1udkyrkkdpDO8mNZi+jqvjDwkk7S7MaAhdA/1M ywfisJyC/9MYw9HkEL5qQpsAVwpQoc6PdyM4M6DBS9kmVBp6iZetE/WmFDDNDwAtEtep Q/WhVkIPxMf7LbJiaSRb8mJs+Ud8Z4bp9mOUdnytDSyMf0gpHZb4EYPocblxsNlQrXIn TEubwYtCRvo+HSGgp3YjEC2fBDUcmv63jKnwQEgjZdsSrvtR1sDw2ltzH+AZ04xzk9W/ fcXXBdXm+cJOdpw4WQ2X9hsPLrzR1TfiHJswDUz4Cy3Iu+mSKKEKUWRCgk3qiiTuwPZ0 4khg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Qc1oPZGL; 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 g7-20020a63e607000000b005575b3902c1si8990704pgh.346.2023.07.24.05.27.41; Mon, 24 Jul 2023 05:27:55 -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=Qc1oPZGL; 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 S230454AbjGXMTN (ORCPT + 99 others); Mon, 24 Jul 2023 08:19:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49358 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230458AbjGXMSx (ORCPT ); Mon, 24 Jul 2023 08:18:53 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9FF8F1BFB for ; Mon, 24 Jul 2023 05:18:29 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 21ED261124 for ; Mon, 24 Jul 2023 12:18:29 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7062EC433C9; Mon, 24 Jul 2023 12:18:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1690201108; bh=45Se94dVdCFvx+5A8Mg8jjIemAM8HzFY/Qq3WqvS/Bk=; h=From:To:Cc:Subject:Date:From; b=Qc1oPZGLNJH1Km8MPHyzHZaxb8mD43sAp4g8VKyN7oPUXoA75Hf6LrR7WGsX1HzXt 1FsBi+NbH6djpiLlqWgtc/TYjqomaQziy642wxU0y+M7G/3BAE6ZuUjWE1rsxnMuWz tAEFTXkxNvMhw0HK4Qe1zFL8PqOXadTgTBRPXEgk4R6jpu/8K+X8m4NkMr3hEAEFb1 5e6jX4z/3LIB6a6a491Zm29vnzjnLLV32Csf994rL9ZeJ7Iru7plwB0+sdDH4pQOTm /fjrorE1pEtoY+lJVrSJh9LjWc17m1PaT1cA3t7no7xniMNo99DFHyrUSjCmRgIA8O G3BmTjZhncoSQ== From: Arnd Bergmann To: Greg Kroah-Hartman , Tejun Heo , "Peter Zijlstra (Intel)" , Suren Baghdasaryan , Andrew Morton , Johannes Weiner Cc: Arnd Bergmann , Chengming Zhou , linux-kernel@vger.kernel.org Subject: [PATCH] kernfs: add stub helper for kernfs_generic_poll() Date: Mon, 24 Jul 2023 14:18:16 +0200 Message-Id: <20230724121823.1357562-1-arnd@kernel.org> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, 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 In some randconfig builds, kernfs ends up being disabled, so there is no prototype for kernfs_generic_poll() In file included from kernel/sched/build_utility.c:97: kernel/sched/psi.c:1479:3: error: implicit declaration of function 'kernfs_generic_poll' is invalid in C99 [-Werror,-Wimplicit-function-declaration] kernfs_generic_poll(t->of, wait); ^ Add a stub helper for it, as we have it for other kernfs functions. Fixes: aff037078ecae ("sched/psi: use kernfs polling functions for PSI trigger polling") Fixes: 147e1a97c4a0b ("fs: kernfs: add poll file operation") Signed-off-by: Arnd Bergmann --- While the stub was always missing, this only caused problems now that sched/psi.c calls it unconditionally. The patch that caused it was already merged into v6.5-rc2 --- include/linux/kernfs.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/linux/kernfs.h b/include/linux/kernfs.h index 73f5c120def88..2a36f3218b510 100644 --- a/include/linux/kernfs.h +++ b/include/linux/kernfs.h @@ -550,6 +550,10 @@ static inline int kernfs_setattr(struct kernfs_node *kn, const struct iattr *iattr) { return -ENOSYS; } +static inline __poll_t kernfs_generic_poll(struct kernfs_open_file *of, + struct poll_table_struct *pt) +{ return -ENOSYS; } + static inline void kernfs_notify(struct kernfs_node *kn) { } static inline int kernfs_xattr_get(struct kernfs_node *kn, const char *name, -- 2.39.2