Re: [PATCH] KVM: selftests: Use __GLIBC__, not _GNU_SOURCE, to detect actual glibc

From: Sean Christopherson

Date: Mon Sep 21 2026 - 10:47:10 EST


On Wed, 26 Aug 2026 09:14:30 -0700, Sean Christopherson wrote:
> Use __GLIBC__ in the hardware disable test to detect when selftests are
> being built/linked against glibc and thus pthread_attr_setaffinity_np() is
> (hopefully) available. As pointed out by Sashiko and Hisam, _GNU_SOURCE is
> effectively a "request" macro to enable functionality, whereas __GLIBC__ is
> an announcement of support and selftests' idiomatic way of guarding code
> that's specific to glibc.
>
> [...]

Applied to kvm-x86 fixes, thanks!

[1/1] KVM: selftests: Use __GLIBC__, not _GNU_SOURCE, to detect actual glibc
https://github.com/kvm-x86/linux/commit/f13368e0acff

--
https://github.com/kvm-x86/linux/tree/next