From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pf1-f201.google.com (mail-pf1-f201.google.com [209.85.210.201]) (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 9C83438D3EA for ; Fri, 15 May 2026 19:20:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778872846; cv=none; b=GjraDJlAL4X/KXMQNSa+k1DXBHT9xvK5yx4xgnkKWvaAsNjmTtOK/91JCwWwWwiMtT2kX9kW/BAExsbsZxYiT/a3548AQRrG7AvtL6qzyMyIEQ77UyU51r/lJmrLA3Uyk511gTjTZMnta53y/cUBKvl199FljbESEWbLdjZ4CLU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778872846; c=relaxed/simple; bh=nZsHt/XZy1AiJmrHTvYkKp5dep2GnBIAqllpDPOkXUg=; h=Date:In-Reply-To:Mime-Version:References:Message-ID:Subject:From: To:Cc:Content-Type; b=N3DM/BHtrHrDvoo+WBn5Awdg5IqZkzwiblBJXetnbWzZ1iaIbP0YUXuRtB7guQ7PqtRekHF1lvK3RNtTjmQ888NZsEVkzCczb9xRblJwPrHXIv5qjGfkfWOBphLaPvBnisGNC48ZR16utaFVWB7aHARtAZGQ4ZD9ntHeVI2TyUM= 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=D94p4rHg; arc=none smtp.client-ip=209.85.210.201 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="D94p4rHg" Received: by mail-pf1-f201.google.com with SMTP id d2e1a72fcca58-83544d05c5aso66511b3a.2 for ; Fri, 15 May 2026 12:20:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20251104; t=1778872844; x=1779477644; 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=62wrPM0lWE30yV9zyxGJWUHaw5WRQ2hiTxFnD7TdkoU=; b=D94p4rHgTU0yQZ4+STPjHxznCh01PRZ4ZKJRsUHmkOsJcbte49BjU39ZO6VnHgK0L0 MXwpYQAcTF4r8hwgU0fDRgnwwyjy+erRNlRok1Q6TFHpQaqP0uGZqTheQ+ARBDPUQcFv qdQtVTxplpdbUcio41GvTuaEpin8iecAkrS4I3wXpfWFeaNh45EMW251hQZqcFdzOT4p LmuwtwAB73KgnineP3ubWYqORUU8X1lwwLchS5mSaBEccLCl2f5XS/PeC06x5uHOit1F go+jP/4hb7B6KWVBBAvJ3Sh6pwQXfmAGaIST0dnf5oO+OubFW+VzyhFuJ+Dy2HkIsSVm odEw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778872844; x=1779477644; 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=62wrPM0lWE30yV9zyxGJWUHaw5WRQ2hiTxFnD7TdkoU=; b=GEL7kJUq4RkYbv5hetUX3S07mD4JIpJRORiLDJPC1q+WW8CusuU2iiwW2NPxSiOp6r 1XoNoUk5np1o+4Qyoaxawi5nrqoaatQc8bVDegMzfd6ERvrfc4gGJ2YZo1uVcnAExjQY 6+vp3wIlCUR6aZKxpxLNTiBjBjlWc2dbZOSiY7SvIxdiijaP7BVSzdUFICkONux9Nzj6 2qHQetQoxVZc2sMadvjZeTKe62TB9OPpd7YB00cuczyGQJ8XXTI/P7Cnbr3HieMnI1il ybQyW5WP8Gk9F6GxwP4KBZs5/940dUgTuSmHG10nMCb4xqC5pW5UPZDCDEvU2n5uQfyo cjCw== X-Forwarded-Encrypted: i=1; AFNElJ+xJTz11R7TeFZMoGw6C0Bvrin1Hmpq4e2Xq/gRAUJ3cFZw5AhY+wKTCikBay6euAj1kHq2umLl8zSBEvI=@vger.kernel.org X-Gm-Message-State: AOJu0YzqziZumtGhqluw4zX1acGi16som4+5hOlX+6GUxyfBvQGASjgT 96B/MoF5Q+9N2cIeTY9TpC3/MgbujPWIn/lHqS1NKUem4D6GOlXcgIMyQ+i2K3TzdXN7Dlqdm7h 6uMOoyA== X-Received: from pfbg4.prod.google.com ([2002:a05:6a00:ae04:b0:82f:c34b:9799]) (user=seanjc job=prod-delivery.src-stubby-dispatcher) by 2002:a05:6a00:4193:b0:83e:eeab:aff8 with SMTP id d2e1a72fcca58-83f33d24d7cmr6075416b3a.25.1778872843406; Fri, 15 May 2026 12:20:43 -0700 (PDT) Reply-To: Sean Christopherson Date: Fri, 15 May 2026 12:19:13 -0700 In-Reply-To: <20260515191942.1892718-1-seanjc@google.com> Precedence: bulk X-Mailing-List: linux-hyperv@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20260515191942.1892718-1-seanjc@google.com> X-Mailer: git-send-email 2.54.0.563.g4f69b47b94-goog Message-ID: <20260515191942.1892718-13-seanjc@google.com> Subject: [PATCH v3 12/41] x86/paravirt: Remove unnecessary PARAVIRT=n stub for paravirt_set_sched_clock() From: Sean Christopherson To: Kiryl Shutsemau , Paolo Bonzini , Sean Christopherson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Ajay Kaher , Alexey Makhalov , Jan Kiszka , Dave Hansen , Andy Lutomirski , Peter Zijlstra , Juergen Gross , Daniel Lezcano , Thomas Gleixner , John Stultz Cc: Rick Edgecombe , Vitaly Kuznetsov , Broadcom internal kernel review list , Boris Ostrovsky , Stephen Boyd , x86@kernel.org, linux-coco@lists.linux.dev, kvm@vger.kernel.org, linux-hyperv@vger.kernel.org, virtualization@lists.linux.dev, linux-kernel@vger.kernel.org, xen-devel@lists.xenproject.org, Michael Kelley , Tom Lendacky , Nikunj A Dadhania , Thomas Gleixner , David Woodhouse Content-Type: text/plain; charset="UTF-8" Remove the unnecessary paravirt_set_sched_clock() stub for PARAVIRT=n, as all callers are gated by PARAVIRT=y. Eliminating the stub will avoid a pile of pointless churn as the "real" implementation evolves. No functional change intended. Fixes: 39965afb1151 ("x86/paravirt: Move paravirt_sched_clock() related code into tsc.c") Signed-off-by: Sean Christopherson --- arch/x86/include/asm/timer.h | 3 +++ arch/x86/kernel/tsc.c | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/x86/include/asm/timer.h b/arch/x86/include/asm/timer.h index fda18bcb19b4..c71b466d6ace 100644 --- a/arch/x86/include/asm/timer.h +++ b/arch/x86/include/asm/timer.h @@ -12,7 +12,10 @@ extern void recalibrate_cpu_khz(void); extern int no_timer_check; extern bool using_native_sched_clock(void); + +#ifdef CONFIG_PARAVIRT void paravirt_set_sched_clock(u64 (*func)(void)); +#endif /* * We use the full linear equation: f(x) = a + b*x, in order to allow diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c index e00f53e3dd8d..021612c22b84 100644 --- a/arch/x86/kernel/tsc.c +++ b/arch/x86/kernel/tsc.c @@ -288,7 +288,6 @@ void paravirt_set_sched_clock(u64 (*func)(void)) u64 sched_clock_noinstr(void) __attribute__((alias("native_sched_clock"))); bool using_native_sched_clock(void) { return true; } -void paravirt_set_sched_clock(u64 (*func)(void)) { } #endif notrace u64 sched_clock(void) -- 2.54.0.563.g4f69b47b94-goog