Thread (34 messages) 34 messages, 4 authors, 2025-05-02

Re: [PATCH v4 02/15] x86/msr: Move rdtsc{,_ordered}() to <asm/tsc.h>

From: Ingo Molnar <mingo@kernel.org>
Date: 2025-05-02 08:18:41
Also in: kvm, linux-acpi, linux-edac, linux-hwmon, linux-hyperv, linux-perf-users, linux-pm, lkml, platform-driver-x86, virtualization, xen-devel

* Xin Li (Intel) [off-list ref] wrote:
For some reason, there are some TSC-related functions in the MSR
  ^^^^^^^^^^^^^^^
header even though there is a tsc.h header.
The real reason is that the rdtsc{,_ordered}() methods use the 
EAX_EDX_*() macros to optimize their EDX/EAX assembly accessors, which 
is why these methods were in <asm/msr.h>.

Your followup patch tacitly acknowledges this by silently creating 
duplicate copies of these facilities in both headers ...

I've cleaned it all up in tip:x86/msr via these preparatory patches:

  x86/msr: Improve the comments of the DECLARE_ARGS()/EAX_EDX_VAL()/EAX_EDX_RET() facility
  x86/msr: Rename DECLARE_ARGS() to EAX_EDX_DECLARE_ARGS
  x86/msr: Move the EAX_EDX_*() methods from <asm/msr.h> to <asm/asm.h>

Thanks,

	Ingo
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help