Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp370797pxb; Fri, 22 Apr 2022 02:49:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwMyaQIA+6lQQa5kRA2tbbY16gxdtPB/qpF24MkKFu8bByU8gGz5Z7zXjGAv6jv41LOFuT2 X-Received: by 2002:a17:902:76c4:b0:15a:3724:b27b with SMTP id j4-20020a17090276c400b0015a3724b27bmr3501991plt.98.1650620955249; Fri, 22 Apr 2022 02:49:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650620955; cv=none; d=google.com; s=arc-20160816; b=WrQKGs16uNvBQN2/vz9GqUitI2x4vSb4HPgbsqza31rcMNPsGsG/RZr0GtPHt8xhTY IzdVyZ8gzKxPFhFc6M49tPSe02BZX8Vnj2NojG7ScOooAN6tM6nZx0hJY8KXJ/Cy4ps7 fy+sPpvY8AxwWUf6QxtXjU0XFdvoTKjTVrJ8+YLlkxv3roNHBpctNH3OPmTLusunckBS 3IVeNPK/Enb6wFOoPXylgVwn2SW3UMuOEci7wQ+0li/kEQR7C5gJmBBFCnx7DbhdGvHw DIr1FqttOWX2yC2ZCbkIkA9pk/oJ4hw04nbsbBDCOtRHrPfS9K7hVDQ2RI1OWj/ZAZDP 1nKg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:references :in-reply-to:subject:cc:to:dkim-signature:dkim-signature:from; bh=r/aQIgWXxwBmFGO013/E4FwX4lEBkuaiUJLDZEQdNAE=; b=ZOZkCyRXm2torJAZ+MwHZJt1UZAQW3MXxXP1Ba4veDSHVttyqQuC6imbzNqqHZauFD yRFzR8qYmrrJaemjRXHKTqN8yU6Huy6eE8ZMib1Qe9X5pHyaFqTqfsIPTltNgt3Q42DQ YVj1FKPLx6SGMU9zSw07yQgTylJ7IyTXlxGd+goRw0PvrqY0dnqV5jUXiyW0PG+NUHBV 6DgtcWHGVeLfS7LsQeLxKaQ6ykCd9FkV0nwRqpAGjh51Vuv7BqwxIZ4XCDFlCi2ux30x RbL1VSPEiKobipbDuEV7maJAwCgNq5crJApkGABOunO1gk4x8+hawLmiNcgQmp2yf6If HdgQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=cr7Djwyr; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; 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=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i2-20020a170902cf0200b001587eff792esi8605424plg.52.2022.04.22.02.49.00; Fri, 22 Apr 2022 02:49:15 -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=@linutronix.de header.s=2020 header.b=cr7Djwyr; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; 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=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1357564AbiDSVOF (ORCPT + 99 others); Tue, 19 Apr 2022 17:14:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40792 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346674AbiDSVOD (ORCPT ); Tue, 19 Apr 2022 17:14:03 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0E18721257; Tue, 19 Apr 2022 14:11:20 -0700 (PDT) From: Thomas Gleixner DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1650402678; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=r/aQIgWXxwBmFGO013/E4FwX4lEBkuaiUJLDZEQdNAE=; b=cr7DjwyrwAC1xj1sLtRiFpR+sBqbFVqNojlImLNsKBdnAmjfYqaOuoyb9phyuVLp5ppfSZ dtd707TV/x8I5HqP5QwypxYvQrB5bsc1xtoRYRRi6X2QBApCbIeDQWRYRCuRDi1d63KMp/ 9CPBxYNvr9X5pIERJXjRlaVFEjvunetwb8HJnLkHQAYQ6NhZPXkor/ZP6gH2DJEn7OojgC Juhad1bgturpCdcAWMOtN7jCOAz7u0btW9CHX2J9A7M2hta+p4F4hrgttf4QUPyofTkqo7 R/y16yc54zp7n2lCSwLKMEC5OmpD9vEyV8Q09kZ3qtlLdPE7oHtP9CF0dvnoGQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1650402678; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=r/aQIgWXxwBmFGO013/E4FwX4lEBkuaiUJLDZEQdNAE=; b=j72MpmW6lV/Z3DmwOd+aLbRYakj1ZRkHArWZR6R0Wo3oy/I0Ex81jvVCg7qxWbJZhpMRbN dlCbsXjQ7RVaHeDg== To: "Rafael J. Wysocki" , Doug Smythies Cc: the arch/x86 maintainers , "Rafael J. Wysocki" , Linux PM , Eric Dumazet , "Paul E. McKenney" , LKML Subject: Re: [patch 00/10] x86/cpu: Consolidate APERF/MPERF code In-Reply-To: References: <20220415133356.179706384@linutronix.de> <005001d85413$75e5dce0$61b196a0$@telus.net> Date: Tue, 19 Apr 2022 23:11:17 +0200 Message-ID: <87bkwwvkwa.ffs@tglx> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,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 On Tue, Apr 19 2022 at 20:49, Rafael J. Wysocki wrote: > On Tue, Apr 19, 2022 at 7:32 PM Doug Smythies wrote: >> For intel_pstate (active), both HWP enabled or disabled, the behaviour >> of scaling_cur_freq is inconsistent with prior to this patch set and other >> scaling driver governor combinations. >> >> Note there is no issue with " grep MHz /proc/cpuinfo" for any >> combination. >> >> Examples: >> >> No-HWP: >> >> active/powersave: >> doug@s19:~/freq-scalers/trace$ grep . /sys/devices/system/cpu/cpu*/cpufreq/scaling_cur_freq >> /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq:2300418 >> /sys/devices/system/cpu/cpu10/cpufreq/scaling_cur_freq:0 >> /sys/devices/system/cpu/cpu11/cpufreq/scaling_cur_freq:0 >> /sys/devices/system/cpu/cpu1/cpufreq/scaling_cur_freq:0 >> /sys/devices/system/cpu/cpu2/cpufreq/scaling_cur_freq:0 >> /sys/devices/system/cpu/cpu3/cpufreq/scaling_cur_freq:0 >> /sys/devices/system/cpu/cpu4/cpufreq/scaling_cur_freq:0 >> /sys/devices/system/cpu/cpu5/cpufreq/scaling_cur_freq:0 >> /sys/devices/system/cpu/cpu6/cpufreq/scaling_cur_freq:0 >> /sys/devices/system/cpu/cpu7/cpufreq/scaling_cur_freq:2300006 >> /sys/devices/system/cpu/cpu8/cpufreq/scaling_cur_freq:2300005 >> /sys/devices/system/cpu/cpu9/cpufreq/scaling_cur_freq:0 > > That's because after the changes in this series scaling_cur_freq > returns 0 if the given CPU is idle. Which is sensible IMO as there is really no point in waking an idle CPU just to read those MSRs, then wait 20ms wake it up again to read those MSRs again. > I guess it could return the last known result, but that wouldn't be > more meaningful. Right. Thanks, tglx