Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp3939322rdh; Tue, 28 Nov 2023 07:42:41 -0800 (PST) X-Google-Smtp-Source: AGHT+IEoscEJa4/7YVm1irY3lI6FJPdQpsTRoeQD931CWWivDRX0U5hfHZSFiLm06hb9cFUIoQjW X-Received: by 2002:a17:903:32d1:b0:1cf:6656:69cf with SMTP id i17-20020a17090332d100b001cf665669cfmr17908001plr.21.1701186160813; Tue, 28 Nov 2023 07:42:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701186160; cv=none; d=google.com; s=arc-20160816; b=RjrPwbFrkPzWBydtSWTiD80brIwmN+d7FWvCWXlf7gzirWohu+Zf5sCej4zxon/fGd ECrv+Kn6BHkXC3cYg9ohSNVrXiw5vICeFjDiTF7EPUyWlBt2iz1bzHufhuKZvTyi8cn5 OYo0GMhgMr2hbU8gw+zMrpO+9IRGzTIL4S1e/yXJv7yRfAC1x97ShGegWEK7bqzq2G1p 2e6us4WX2fOuFzoW3rWMoTyNQNizU6HdPhhF6EJ5Z9iPR1FjSuhkUO8XavPLApjGI6oC tFWexxzi7EtJ4R33d+fv0sM2d3B+DFBL4vd/m/dDvCpxBG8/ETuuTpknD1aREo4093ra 6zgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=IMKJEnNn+G4rdqFGH3iRHztZa/N2RADNEAueBo8O0cY=; fh=6yiGQOgEm2Fmpq0pavzXuVutg0eZTM43w9JXQi2N3lI=; b=cLu0o2mlzLVeIKmOICFZrFxzfjNsrt+EjXZDNIGRB5RCkpxAkTKuJy8dyPSVI/h8Dp b4RLoX8mALO28Xy12Sz5lfRAM3IzQt3yWnYdff3wSW5vA3yT1If5LqOMkEo6TpBZDm9c k+XfjqS0+r4vWA6rrQjNC7dkOGz00j1b7NNkpgYU9iB4ZF65UiiD5Ke5FRcw2fV4m6ef JmQE/VFG722oqvwBhz6yolWOdPtJuwkPZneBWw5ijdT9V0oaBlWUF6WM6Qn7oZpnXO56 z9bP82dMHdxZ1gkHzG6ZHk946satDE6w19y6oj2spJ/EHSXAIdstKNZo+cVIr24zMRqT nDXw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=z16DHxP0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id iy3-20020a170903130300b001cfcbf477c5si4939516plb.30.2023.11.28.07.42.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 28 Nov 2023 07:42:40 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=z16DHxP0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id DDEF0808D23B; Tue, 28 Nov 2023 07:42:37 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345879AbjK1PmW (ORCPT + 99 others); Tue, 28 Nov 2023 10:42:22 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40492 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345899AbjK1PmV (ORCPT ); Tue, 28 Nov 2023 10:42:21 -0500 Received: from pandora.armlinux.org.uk (pandora.armlinux.org.uk [IPv6:2001:4d48:ad52:32c8:5054:ff:fe00:142]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 416D612A; Tue, 28 Nov 2023 07:42:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=IMKJEnNn+G4rdqFGH3iRHztZa/N2RADNEAueBo8O0cY=; b=z16DHxP08aFFFJ47LD9uxtJpsn +t0RB0TyQ2KyCYVbEMXvvjymQCwHExD6/vKRXzXzkjojJ7IP2XE8qmxVC8cAHrtCd0+IIrVCm7qdN ZdkxE7l6xOULssxdV73BHOuaELu62t9SvZuDP9ZN1aCfYYnQMrGlQxH4qVoIMelPnGvcPnaF38Pkr h5A/PWeMHMTxSr3BM1Zuta51o2q+gTVoiMVbBs0Dc0KEwgofXauGinHENQ/qNDFrdL2D7Y0vYeL4i sMNspndTH56fozoySkkm+Xwt+BdU09U7Sw0FK8bN/SgdK1YxaDQXRaJcCIRC8UP2EoMRf9O+b1H83 t070MZQg==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:54994) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1r80E9-0007Xq-1d; Tue, 28 Nov 2023 15:42:21 +0000 Received: from linux by shell.armlinux.org.uk with local (Exim 4.94.2) (envelope-from ) id 1r80EA-00034k-5Y; Tue, 28 Nov 2023 15:42:22 +0000 Date: Tue, 28 Nov 2023 15:42:22 +0000 From: "Russell King (Oracle)" To: Jonathan Cameron Cc: linux-pm@vger.kernel.org, loongarch@lists.linux.dev, linux-acpi@vger.kernel.org, linux-arch@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-riscv@lists.infradead.org, kvmarm@lists.linux.dev, x86@kernel.org, linux-csky@vger.kernel.org, linux-doc@vger.kernel.org, linux-ia64@vger.kernel.org, linux-parisc@vger.kernel.org, Salil Mehta , Jean-Philippe Brucker , jianyong.wu@arm.com, justin.he@arm.com, James Morse , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , "H. Peter Anvin" Subject: Re: [PATCH RFC 02/22] x86: intel_epb: Don't rely on link order Message-ID: References: <20231128144059.000042c8@Huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231128144059.000042c8@Huawei.com> Sender: Russell King (Oracle) X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Tue, 28 Nov 2023 07:42:38 -0800 (PST) On Tue, Nov 28, 2023 at 02:40:59PM +0000, Jonathan Cameron wrote: > On Tue, 07 Nov 2023 10:29:28 +0000 > Russell King wrote: > > > From: James Morse > > > > intel_epb_init() is called as a subsys_initcall() to register cpuhp > > callbacks. The callbacks make use of get_cpu_device() which will return > > NULL unless register_cpu() has been called. register_cpu() is called > > from topology_init(), which is also a subsys_initcall(). > > > > This is fragile. Moving the register_cpu() to a different > > subsys_initcall() leads to a NULL dereference during boot. > > > > Make intel_epb_init() a late_initcall(), user-space can't provide a > > policy before this point anyway. > > > > Signed-off-by: James Morse > > Signed-off-by: Russell King (Oracle) > > Seems reasonable. FWIW > Reviewed-by: Jonathan Cameron Thanks, however this has already been merged into the tip tree since Rafael suggested sending it separately. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!