linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "tip-bot2 for Giovanni Gherdovich" <tip-bot2@linutronix.de>
To: linux-tip-commits@vger.kernel.org
Cc: Giovanni Gherdovich <ggherdovich@suse.cz>,
	"Peter Zijlstra (Intel)" <peterz@infradead.org>,
	x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [tip: sched/core] x86: Print ratio freq_max/freq_base used in frequency invariance calculations
Date: Thu, 03 Dec 2020 09:13:20 -0000	[thread overview]
Message-ID: <160698680049.3364.3119999970508477644.tip-bot2@tip-bot2> (raw)
In-Reply-To: <20201112182614.10700-4-ggherdovich@suse.cz>

The following commit has been merged into the sched/core branch of tip:

Commit-ID:     24f326686c925a848d603a2c22f1f6ed1b7786e2
Gitweb:        https://git.kernel.org/tip/24f326686c925a848d603a2c22f1f6ed1b7786e2
Author:        Giovanni Gherdovich <ggherdovich@suse.cz>
AuthorDate:    Thu, 12 Nov 2020 19:26:14 +01:00
Committer:     Peter Zijlstra <peterz@infradead.org>
CommitterDate: Thu, 03 Dec 2020 10:00:35 +01:00

x86: Print ratio freq_max/freq_base used in frequency invariance calculations

The value freq_max/freq_base is a fundamental component of frequency
invariance calculations. It may come from a variety of sources such as MSRs
or ACPI data, tracking it down when troubleshooting a system could be
non-trivial. It is worth saving it in the kernel logs.

 # dmesg | grep 'Estimated ratio of average max'
 [   14.024036] smpboot: Estimated ratio of average max frequency by base frequency (times 1024): 1289

Signed-off-by: Giovanni Gherdovich <ggherdovich@suse.cz>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20201112182614.10700-4-ggherdovich@suse.cz
---
 arch/x86/kernel/smpboot.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c
index c5dd5f6..3577bb7 100644
--- a/arch/x86/kernel/smpboot.c
+++ b/arch/x86/kernel/smpboot.c
@@ -2110,6 +2110,7 @@ static void init_freq_invariance(bool secondary, bool cppc_ready)
 	if (ret) {
 		init_counter_refs();
 		static_branch_enable(&arch_scale_freq_key);
+		pr_info("Estimated ratio of average max frequency by base frequency (times 1024): %llu\n", arch_max_freq_ratio);
 	} else {
 		pr_debug("Couldn't determine max cpu frequency, necessary for scale-invariant accounting.\n");
 	}

  reply	other threads:[~2020-12-03  9:14 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-12 18:26 [PATCH v4 0/3] Add support for frequency invariance to AMD EPYC Zen2 Giovanni Gherdovich
2020-11-12 18:26 ` [PATCH v4 1/3] x86, sched: Calculate frequency invariance for AMD systems Giovanni Gherdovich
2020-12-03  9:13   ` [tip: sched/core] " tip-bot2 for Nathan Fontenot
2020-12-11  9:34   ` tip-bot2 for Nathan Fontenot
2020-11-12 18:26 ` [PATCH v4 2/3] x86, sched: Use midpoint of max_boost and max_P for frequency invariance on AMD EPYC Giovanni Gherdovich
2020-12-03  9:13   ` [tip: sched/core] " tip-bot2 for Giovanni Gherdovich
2020-12-04 17:03   ` [PATCH v4 RESEND] " Giovanni Gherdovich
2020-12-04 17:10     ` Giovanni Gherdovich
2020-12-11  9:34   ` [tip: sched/core] " tip-bot2 for Giovanni Gherdovich
2020-11-12 18:26 ` [PATCH v4 3/3] x86: Print ratio freq_max/freq_base used in frequency invariance calculations Giovanni Gherdovich
2020-12-03  9:13   ` tip-bot2 for Giovanni Gherdovich [this message]
2020-12-11  9:34   ` [tip: sched/core] " tip-bot2 for Giovanni Gherdovich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=160698680049.3364.3119999970508477644.tip-bot2@tip-bot2 \
    --to=tip-bot2@linutronix.de \
    --cc=ggherdovich@suse.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=peterz@infradead.org \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).