From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pl1-f202.google.com (mail-pl1-f202.google.com [209.85.214.202]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 63D3B3F6C30 for ; Fri, 29 May 2026 14:45:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.202 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780065908; cv=none; b=CQ0mruoLRRYfqiLWBow9zW0VmXLYjsAhDkzXz6DCjUa4O5na0zAKSxdIAAHnoWEjk0495nBd5+DTZF9Lv4NAvqlT4ldiT0ZRMQYr3/sTu6MDBCifGRrAuovkxzmbc3En93xecDz+h16i5UZohzmpVHQdRoty1w/wY94QXvb1gt8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780065908; c=relaxed/simple; bh=QsGKR47k87jDmABsbb6wIJ/Oo6leqTzO1mrFX7LbN8Y=; h=Date:In-Reply-To:Mime-Version:References:Message-ID:Subject:From: To:Cc:Content-Type; b=kqopZDglOXWwLJecnxrEXCsZ9owC0nyC8cZnJQVBCkYkqEw73IijuVvlsq+nFcxh61kGWP+bAJWf87ZsK5f9M0R9yJTeSRLK4Il+mJ0C1TS0Ow1yc3dqtE48s/BY93GYMd7MTHFCErKoaQ0BIqBzUxEQYJ0p0TzdOrT6DYa89gM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--seanjc.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=pKCQwTpi; arc=none smtp.client-ip=209.85.214.202 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--seanjc.bounces.google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="pKCQwTpi" Received: by mail-pl1-f202.google.com with SMTP id d9443c01a7336-2ba054e0304so120625405ad.0 for ; Fri, 29 May 2026 07:45:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20251104; t=1780065906; x=1780670706; darn=vger.kernel.org; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:reply-to:from:to:cc:subject:date:message-id:reply-to; bh=Ep5voyn6wy8bCsLD4fpqMEGPbCHcjvgsIyxbB5uxkeU=; b=pKCQwTpizj1qUYd60Xj+63HosG5aEgFa00/oSzODrzD5VXcTzkD1lVn8TVu7LlBH9r FZ8TJebytJF2vp7ictkpBxtYqkw9AetgYd4zV84xKr33FlGp/wA3cCJlWnQFQwC2epMV MAlSyCHyJ2ua7wKHzCHZhg/jjH6DM3QybPukdKYVMrWz2GVLv61+GqKJi3F8/CbzE0b6 xtTxkqgyit9E8cxUA/8b3qOM3ByF86cu1+/yrUon1nyvGonTCsYgnCTdB/zg0LXIDzBz bcvz3MQxaOcsKKwxzqz1vK19hWBe+Kf8NOrBt/SKnfEPALdUAVWF5EH56wWEy/4IQUhm qVNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1780065906; x=1780670706; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:reply-to:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=Ep5voyn6wy8bCsLD4fpqMEGPbCHcjvgsIyxbB5uxkeU=; b=jfxMF/gI77S/uWOsNr9XFa7loXIZrm46nDHoHO2T7IQtNRvVqxrQo9+uYGZCaashiO Ue2TZhU3u/UBoRAOR0EicyJY/7QumJhQMbtuw1RtyQmJ2+mCGqIKCmCpwUAcoXfoWwql qRrwU9iGuJWikdcVia5cIf6vbut/opkKLkEF6E9PTIgL4KCjaDgytuXTFhm9TBlU6znv SZq+vIhKU2f1IBxKciv6sOnNmbVZi+oOp+1aB/kq78G+7Zz5BMUrZaKGDIHD3gWJGGvB UEGlabvm4ASGcWfJqav+uNGg91dSSUeBnfWkGqt47S+XKKYA+QplJFDC9EZ5bobPM5Ip eNng== X-Forwarded-Encrypted: i=1; AFNElJ9b8rzHuyJdarTb5HzQ689wEeWkj2iB2kXkjquHct+Gm4oNAreyLS5v+JpEaID0UIQF73+Klvy5fmWlVUU=@vger.kernel.org X-Gm-Message-State: AOJu0YwAscc0Pjng+Gl+a9hOTaU32biOyR5huPdNKlYGqyR9s4VBZ2wl p2n4PGDFYULfKPwTSfDmkY0BysRIfg0Gu+4ICLJtfa+fn0cERo69xxxQJf0kQtROKCbW7f/OEPs TWMIvaA== X-Received: from plbv2.prod.google.com ([2002:a17:903:44c2:b0:2bf:2808:7225]) (user=seanjc job=prod-delivery.src-stubby-dispatcher) by 2002:a17:903:144b:b0:2bc:dca9:f0ed with SMTP id d9443c01a7336-2bf20dbeeb3mr34014545ad.15.1780065905419; Fri, 29 May 2026 07:45:05 -0700 (PDT) Reply-To: Sean Christopherson Date: Fri, 29 May 2026 07:43:59 -0700 In-Reply-To: <20260529144435.704127-1-seanjc@google.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20260529144435.704127-1-seanjc@google.com> X-Mailer: git-send-email 2.54.0.823.g6e5bcc1fc9-goog Message-ID: <20260529144435.704127-13-seanjc@google.com> Subject: [PATCH v4 12/47] x86/tsc: Rename pit_hpet_ptimer_calibrate_cpu() => native_calibrate_cpu_late() From: Sean Christopherson To: Paolo Bonzini , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, Kiryl Shutsemau , Sean Christopherson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Ajay Kaher , Alexey Makhalov , Jan Kiszka , Andy Lutomirski , Peter Zijlstra , Juergen Gross , Daniel Lezcano , John Stultz Cc: "H. Peter Anvin" , Rick Edgecombe , Vitaly Kuznetsov , Broadcom internal kernel review list , Boris Ostrovsky , Stephen Boyd , kvm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-coco@lists.linux.dev, linux-hyperv@vger.kernel.org, virtualization@lists.linux.dev, xen-devel@lists.xenproject.org, David Woodhouse , Tom Lendacky , Nikunj A Dadhania , David Woodhouse , Michael Kelley , Thomas Gleixner Content-Type: text/plain; charset="UTF-8" Rename the late CPU calibration routine so that its relationship to the early routine is more obvious and intuitive. No functional change intended. Signed-off-by: Sean Christopherson --- arch/x86/kernel/tsc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c index 5b4b6e43c94c..534462c81c78 100644 --- a/arch/x86/kernel/tsc.c +++ b/arch/x86/kernel/tsc.c @@ -779,7 +779,7 @@ static unsigned long cpu_khz_from_cpuid(void) * calibrate cpu using pit, hpet, and ptimer methods. They are available * later in boot after acpi is initialized. */ -static unsigned long pit_hpet_ptimer_calibrate_cpu(void) +static unsigned long native_calibrate_cpu_late(void) { u64 tsc1, tsc2, delta, ref1, ref2; unsigned long tsc_pit_min = ULONG_MAX, tsc_ref_min = ULONG_MAX; @@ -954,7 +954,7 @@ static unsigned long native_calibrate_cpu(void) unsigned long tsc_freq = native_calibrate_cpu_early(); if (!tsc_freq) - tsc_freq = pit_hpet_ptimer_calibrate_cpu(); + tsc_freq = native_calibrate_cpu_late(); return tsc_freq; } @@ -1497,7 +1497,7 @@ static bool __init determine_cpu_tsc_frequencies(bool early, else tsc_khz = native_calibrate_tsc(); } else { - cpu_khz = pit_hpet_ptimer_calibrate_cpu(); + cpu_khz = native_calibrate_cpu_late(); } /* -- 2.54.0.823.g6e5bcc1fc9-goog