From mboxrd@z Thu Jan 1 00:00:00 1970 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 56B15EB64D7 for ; Fri, 16 Jun 2023 12:52:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=p9aRteCBMnTvCBgW8GcqhlMZzZ6T5vzDWLjS88P27Z4=; b=WEFMgGWD33pDAZ QhfmmfBxz1gZKJw5/tdcw50IKmNSo6NBdt04QlF9yhlTK/QhJh62lgS77PhqM5dSPHp3l0FNGy9VQ CyamQgp1VgZcIMG0TeFrOHd+KVfxBdIUTpZ0jJihwi14y7ir4QWwxZzB5lameFkaf1rU1NoR1QovG O6MKRiVoM6e6GqEkhMl/V4iv8hL5vBDht+ayzjHsc2m/MyhtQzEy4lVejHvobKpQZAoLuHGALS6/Y IqP8cfhV0qjxDBNsf3tYkEbSxJntnn9sKbP/7Nor9qGJORvT/ovcUUap+HJn3vqP37wFxLwQcNTS2 sTEDc8mRt59Syh9rbK5Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qA8wB-000bnL-1z; Fri, 16 Jun 2023 12:52:23 +0000 Received: from casper.infradead.org ([2001:8b0:10b:1236::1]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qA8wA-000bn8-2j for linux-arm-kernel@bombadil.infradead.org; Fri, 16 Jun 2023 12:52:22 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=Pc2nHptoZyvja0c5oQk9KVyr6kxRddZ7zBs/vCuF+04=; b=UWzwiNkzX105QrRhSoW5b6JVvK jlUrrcskV14PjmWR0YtuSThtVVaqhVEiC9ThwV4dmiIMRPb/rVyUmPeG2WVzhw+ZQ9EH9+P4kTo8Q ZHJP+aKZOwkM1Cb3pDd1IO5cHgvOV8nV9yrSpTkunzC5r7ObWCnamOLWjR0AiZejVSofQLbZZVssv C43IXwhUHESuAJ6kBSLfRZedMHRbG6U5+sEdteufFSeAlYve+SEj4AoOA3LAQIB6ZGsNzA5VfyuRz KfQ+IFRL2YABACnV7EMz3IiJi3Q4oEzqNg5Aol2nq4KNgrYt3uB5lA52RRXt/i/+0y+hxQd/uuTon aG8a3Tbw==; Received: from j130084.upc-j.chello.nl ([24.132.130.84] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1qA8w9-0090kh-05; Fri, 16 Jun 2023 12:52:21 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id B440530020B; Fri, 16 Jun 2023 14:52:19 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 955AA27438941; Fri, 16 Jun 2023 14:52:19 +0200 (CEST) Date: Fri, 16 Jun 2023 14:52:19 +0200 From: Peter Zijlstra To: Marc Zyngier Cc: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Reiji Watanabe , Mark Rutland , Will Deacon Subject: Re: [PATCH v2] perf/core: Drop __weak attribute from arch_perf_update_userpage() prototype Message-ID: <20230616125219.GF4253@hirez.programming.kicks-ass.net> References: <20230616114831.3186980-1-maz@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20230616114831.3186980-1-maz@kernel.org> X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Fri, Jun 16, 2023 at 12:48:31PM +0100, Marc Zyngier wrote: > Reiji reports that the arm64 implementation of arch_perf_update_userpage() > is now ignored and replaced by the dummy stub in core code. > This seems to happen since the PMUv3 driver was moved to driver/perf. > > As it turns out, dropping the __weak attribute from the *prototype* > of the function solves the problem. You're right, this doesn't seem > to make much sense. And yet... It appears that both symbols get > flagged as weak, and that the first one to appear in the link order > wins: > > $ nm drivers/perf/arm_pmuv3.o|grep arch_perf_update_userpage > 0000000000001db0 W arch_perf_update_userpage > > Dropping the attribute from the prototype restores the expected > behaviour, and arm64 is able to enjoy arch_perf_update_userpage() > again. > > Fixes: 7755cec63ade ("arm64: perf: Move PMUv3 driver to drivers/perf") > Fixes: f1ec3a517b43 ("kernel/events: Add a missing prototype for arch_perf_update_userpage()") > Reported-by: Reiji Watanabe > Tested-by: Reiji Watanabe > Acked-by: Mark Rutland > Signed-off-by: Marc Zyngier > Cc: Peter Zijlstra > Cc: Will Deacon Thanks! in perf/urgent it goes _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel From mboxrd@z Thu Jan 1 00:00:00 1970 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 54005EB64D7 for ; Fri, 16 Jun 2023 12:52:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344036AbjFPMwa (ORCPT ); Fri, 16 Jun 2023 08:52:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46710 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229560AbjFPMw2 (ORCPT ); Fri, 16 Jun 2023 08:52:28 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7500E30F7 for ; Fri, 16 Jun 2023 05:52:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=Pc2nHptoZyvja0c5oQk9KVyr6kxRddZ7zBs/vCuF+04=; b=UWzwiNkzX105QrRhSoW5b6JVvK jlUrrcskV14PjmWR0YtuSThtVVaqhVEiC9ThwV4dmiIMRPb/rVyUmPeG2WVzhw+ZQ9EH9+P4kTo8Q ZHJP+aKZOwkM1Cb3pDd1IO5cHgvOV8nV9yrSpTkunzC5r7ObWCnamOLWjR0AiZejVSofQLbZZVssv C43IXwhUHESuAJ6kBSLfRZedMHRbG6U5+sEdteufFSeAlYve+SEj4AoOA3LAQIB6ZGsNzA5VfyuRz KfQ+IFRL2YABACnV7EMz3IiJi3Q4oEzqNg5Aol2nq4KNgrYt3uB5lA52RRXt/i/+0y+hxQd/uuTon aG8a3Tbw==; Received: from j130084.upc-j.chello.nl ([24.132.130.84] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1qA8w9-0090kh-05; Fri, 16 Jun 2023 12:52:21 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id B440530020B; Fri, 16 Jun 2023 14:52:19 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 955AA27438941; Fri, 16 Jun 2023 14:52:19 +0200 (CEST) Date: Fri, 16 Jun 2023 14:52:19 +0200 From: Peter Zijlstra To: Marc Zyngier Cc: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Reiji Watanabe , Mark Rutland , Will Deacon Subject: Re: [PATCH v2] perf/core: Drop __weak attribute from arch_perf_update_userpage() prototype Message-ID: <20230616125219.GF4253@hirez.programming.kicks-ass.net> References: <20230616114831.3186980-1-maz@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230616114831.3186980-1-maz@kernel.org> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jun 16, 2023 at 12:48:31PM +0100, Marc Zyngier wrote: > Reiji reports that the arm64 implementation of arch_perf_update_userpage() > is now ignored and replaced by the dummy stub in core code. > This seems to happen since the PMUv3 driver was moved to driver/perf. > > As it turns out, dropping the __weak attribute from the *prototype* > of the function solves the problem. You're right, this doesn't seem > to make much sense. And yet... It appears that both symbols get > flagged as weak, and that the first one to appear in the link order > wins: > > $ nm drivers/perf/arm_pmuv3.o|grep arch_perf_update_userpage > 0000000000001db0 W arch_perf_update_userpage > > Dropping the attribute from the prototype restores the expected > behaviour, and arm64 is able to enjoy arch_perf_update_userpage() > again. > > Fixes: 7755cec63ade ("arm64: perf: Move PMUv3 driver to drivers/perf") > Fixes: f1ec3a517b43 ("kernel/events: Add a missing prototype for arch_perf_update_userpage()") > Reported-by: Reiji Watanabe > Tested-by: Reiji Watanabe > Acked-by: Mark Rutland > Signed-off-by: Marc Zyngier > Cc: Peter Zijlstra > Cc: Will Deacon Thanks! in perf/urgent it goes