linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] selftests: Remove duplicate CPUID wrappers
@ 2022-02-04 19:17 Reinette Chatre
  2022-02-04 19:17 ` [PATCH 1/3] selftests/vm/pkeys: Use existing __cpuid_count() macro Reinette Chatre
  2022-02-04 23:39 ` [PATCH 0/3] selftests: Remove duplicate CPUID wrappers Shuah Khan
  0 siblings, 2 replies; 6+ messages in thread
From: Reinette Chatre @ 2022-02-04 19:17 UTC (permalink / raw)
  To: shuah, linux-kselftest
  Cc: linux-kernel, Reinette Chatre, Dave Hansen, Ram Pai,
	Sandipan Das, Florian Weimer, Desnes A. Nunes do Rosario,
	Ingo Molnar, Thiago Jung Bauermann, Michael Ellerman,
	Michal Suchanek, linux-mm, Chang S . Bae, Borislav Petkov,
	Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86,
	Andy Lutomirski

A few tests that require running CPUID do so with a private
implementation of a wrapper for CPUID. This duplication of
the CPUID wrapper should be avoided but having one is also
unnecessary because of the existence of a macro that can
be used instead.

This series replaces private CPUID wrappers with calls
to the __cpuid_count() macro from cpuid.h as made available
by gcc and clang/llvm.

Cc: Dave Hansen <dave.hansen@linux.intel.com>
Cc: Ram Pai <linuxram@us.ibm.com>
Cc: Sandipan Das <sandipan@linux.ibm.com>
Cc: Florian Weimer <fweimer@redhat.com>
Cc: "Desnes A. Nunes do Rosario" <desnesn@linux.vnet.ibm.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Thiago Jung Bauermann <bauerman@linux.ibm.com>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: Michal Suchanek <msuchanek@suse.de>
Cc: linux-mm@kvack.org
Cc: Chang S. Bae <chang.seok.bae@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: x86@kernel.org
Cc: Andy Lutomirski <luto@kernel.org>

Reinette Chatre (3):
  selftests/vm/pkeys: Use existing __cpuid_count() macro
  selftests/x86/amx: Use existing __cpuid_count() macro
  selftests/x86/corrupt_xstate_header: Use existing __cpuid_count()
    macro

 tools/testing/selftests/vm/pkey-x86.h         | 22 +++---------------
 tools/testing/selftests/x86/amx.c             | 23 +++++--------------
 .../selftests/x86/corrupt_xstate_header.c     | 17 ++------------
 3 files changed, 11 insertions(+), 51 deletions(-)

-- 
2.25.1



^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2022-02-07 19:13 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-04 19:17 [PATCH 0/3] selftests: Remove duplicate CPUID wrappers Reinette Chatre
2022-02-04 19:17 ` [PATCH 1/3] selftests/vm/pkeys: Use existing __cpuid_count() macro Reinette Chatre
2022-02-04 23:39 ` [PATCH 0/3] selftests: Remove duplicate CPUID wrappers Shuah Khan
2022-02-05  0:11   ` Reinette Chatre
2022-02-07 18:00     ` Shuah Khan
2022-02-07 19:13       ` Reinette Chatre

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).