Received: by 2002:a05:6a10:6006:0:0:0:0 with SMTP id w6csp207261pxa; Wed, 26 Aug 2020 23:08:59 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxYwAPQ3+oDdoZZdP1WOOZMS+jbg0FioCIBv5eLX5WNBcgncG/ottwfahK0YJWpzBmEDi3T X-Received: by 2002:a17:906:4813:: with SMTP id w19mr18672519ejq.159.1598508539564; Wed, 26 Aug 2020 23:08:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598508539; cv=none; d=google.com; s=arc-20160816; b=C3lPG+NnWtWz+6T2j+18jWhmPD4nK/ojS57i/AiRUD6hNAUzL6EGYBJh4YF0OHbhtR CG1E9cy/R3UqXBfRtKm2ObLko/uXR9BoJa9buvLmbhFvpmiXFkcvtQ9Gi3mNbhoRoDkv 9R9f5OwdE3TJye7q44jKLg2wvor2qd5JQdlH2NNg71Kw8mtS2zs1JRvf8MtXWKRmYx1g LrIWxlNQvF13UyetkejTqNh7BQXetpghy65poScrCnTCLt1cN6GvU/my6oJ/6rXKhmC0 14zO7Ixu/4eS4vN9DuekubIZoKwi4AKLincv+zHEnAN5c9j4LpZlWywhg8z7IL2dhsCk iWBQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:references:in-reply-to:subject:to:from :dkim-signature; bh=44uY6wuEUM9I0JSFoXE1y1Uy0dwu2ymTti2d/hjXB9Q=; b=ujAPThw/I/e2QCT2KLSJNZ3K7e08SYOCzGhWkBrTavI3hXKqTmo35JkMsn/s1dX/6h qBeQG3AioPzHcfM1tBNSVL3JQ6sNbL4R/NkBCUJwxNept2UK9NGMTA5GJNdbjrtTfurq Rq/idU8u2p6u+LC9kjfjPm3q7UTSJH/z2uKBLGuRS9PnfPZ6xAEE+49q9JlQgcuaU/QQ 2VE0r0Sf2mi1QTeIAxAqvvzKkgPLMPWsD7GlgmKK//Fg0oHxc96LIEJOMPNfmrVI52dB uCoyAIP/Uu9fWWpGC8Vad9frKrAnRKTgStEo32zBXfbZV8WZ6HDj81g3FvHxXYBNJF9d KDdQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ellerman.id.au header.s=201909 header.b=q5xjA01W; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b6si726608eja.208.2020.08.26.23.08.37; Wed, 26 Aug 2020 23:08:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@ellerman.id.au header.s=201909 header.b=q5xjA01W; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727772AbgH0GHs (ORCPT + 99 others); Thu, 27 Aug 2020 02:07:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35776 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726157AbgH0GHs (ORCPT ); Thu, 27 Aug 2020 02:07:48 -0400 Received: from ozlabs.org (bilbo.ozlabs.org [IPv6:2401:3900:2:1::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0B71DC061249 for ; Wed, 26 Aug 2020 23:07:48 -0700 (PDT) Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.ozlabs.org (Postfix) with ESMTPSA id 4BcXML6TWyz9sRK; Thu, 27 Aug 2020 16:07:42 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ellerman.id.au; s=201909; t=1598508462; bh=44uY6wuEUM9I0JSFoXE1y1Uy0dwu2ymTti2d/hjXB9Q=; h=From:To:Subject:In-Reply-To:References:Date:From; b=q5xjA01W3XD/TpFExMucgl8Kri5f+Ef7AP9pCxS/DNeYTKW91Auy3P2tubG3me3K2 qWyWAZje2GB3pVju7H/Kw6mDMujUnwSZZBkQkW2KMi3k46JzNFdhgPtMs2YDQ4rC3B POEZ8aqWMNLIYkhuR+PtLzhoT2oyXZJqPUHNE+QfFqPqB/XS7Bp67VkB79XqEhNB2g 5CXaXMMh15tJkKGyFc4wi9rYnuwXpJdWcDrtxwq5tqXXgeEzluv18u1FGARDgAAKcE K2qA8YVj/U3EchXV21UlLwNP+LdZrmYDX8CWPxD3Bv2yb9JJ4wvKUQWr4AvMLbrYBi jyG0oLrUO1qbA== From: Michael Ellerman To: Pratik Sampat , Christophe Leroy , linuxppc-dev@lists.ozlabs.org, npiggin@gmail.com, mikey@neuling.org, ego@linux.vnet.ibm.com, svaidy@linux.ibm.com, linux-kernel@vger.kernel.org, pratik.r.sampat@gmail.com Subject: Re: [PATCH] Revert "powerpc/powernv/idle: Replace CPU feature check with PVR check" In-Reply-To: <170e1919-bc45-6b99-dc4d-713418c98be1@linux.ibm.com> References: <20200826082918.89306-1-psampat@linux.ibm.com> <1fb7fcef-a39d-d36e-35d5-021a5c9ea82c@csgroup.eu> <170e1919-bc45-6b99-dc4d-713418c98be1@linux.ibm.com> Date: Thu, 27 Aug 2020 16:07:39 +1000 Message-ID: <87imd439lg.fsf@mpe.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Pratik Sampat writes: > On 26/08/20 2:07 pm, Christophe Leroy wrote: >> Le 26/08/2020 =C3=A0 10:29, Pratik Rajesh Sampat a =C3=A9crit=C2=A0: >>> Cpuidle stop state implementation has minor optimizations for P10 >>> where hardware preserves more SPR registers compared to P9. >>> The current P9 driver works for P10, although does few extra >>> save-restores. P9 driver can provide the required power management >>> features like SMT thread folding and core level power savings >>> on a P10 platform. >>> >>> Until the P10 stop driver is available, revert the commit which >>> allows for only P9 systems to utilize cpuidle and blocks all >>> idle stop states for P10. >>> Cpu idle states are enabled and tested on the P10 platform >>> with this fix. >>> >>> This reverts commit 8747bf36f312356f8a295a0c39ff092d65ce75ae. >>> >>> Fixes: 8747bf36f312 ("powerpc/powernv/idle: Replace CPU feature check=20 >>> with PVR check") >>> Signed-off-by: Pratik Rajesh Sampat >>> --- >>> =C2=A0 @mpe: This revert would resolve a staging issue wherein the P10 = stop >>> =C2=A0 driver is not yet ready while cpuidle stop states need not be bl= ocked >>> =C2=A0 on 5.9 for Power10 systems which could cause SMT folding related >>> =C2=A0 performance issues. >>> >>> =C2=A0 The P10 stop driver is in the works here: >>> https://lists.ozlabs.org/pipermail/linuxppc-dev/2020-August/216773.html >>> >>> =C2=A0 arch/powerpc/platforms/powernv/idle.c | 2 +- >>> =C2=A0 1 file changed, 1 insertion(+), 1 deletion(-) >>> >>> diff --git a/arch/powerpc/platforms/powernv/idle.c=20 >>> b/arch/powerpc/platforms/powernv/idle.c >>> index 77513a80cef9..345ab062b21a 100644 >>> --- a/arch/powerpc/platforms/powernv/idle.c >>> +++ b/arch/powerpc/platforms/powernv/idle.c >>> @@ -1223,7 +1223,7 @@ static void __init pnv_probe_idle_states(void) >>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 return; >>> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 } >>> =C2=A0 -=C2=A0=C2=A0=C2=A0 if (pvr_version_is(PVR_POWER9)) >>> +=C2=A0=C2=A0=C2=A0 if (cpu_has_feature(CPU_FTR_ARCH_300)) >> >> Why not something like: >> >> =C2=A0=C2=A0=C2=A0=C2=A0if (pvr_version_is(PVR_POWER9) || pvr_version_is= (PVR_POWER10)) >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 pnv_power9_idle_init();=20 > > In order to use PVR_POWER10 I would need to define it under > arch/powerpc/include/asm/reg.h, which is not present in 5.9 yet. > > However, if it okay with @mpe I could split out Nick's P10 stop driver > (https://lists.ozlabs.org/pipermail/linuxppc-dev/2020-August/216773.html) > into two parts: I'll just take this for now, it's the simplest option. cheers