From: Dave Hansen <dave.hansen@intel.com>
To: Xin Li <xin3.li@intel.com>, linux-kernel@vger.kernel.org, x86@kernel.org
Cc: tglx@linutronix.de, mingo@redhat.com, bp@alien8.de,
dave.hansen@linux.intel.com, hpa@zytor.com,
bigeasy@linutronix.de, yujie.liu@intel.com, shan.kang@intel.com
Subject: Re: [PATCH 1/1] x86/vdso: use the right GDT_ENTRY_CPUNODE for 32-bit getcpu() on 64-bit kernel
Date: Mon, 13 Mar 2023 08:22:32 -0700 [thread overview]
Message-ID: <5e84fd48-459d-8850-d26f-860c6d34a9ad@intel.com> (raw)
In-Reply-To: <20230311084824.2340-1-xin3.li@intel.com>
On 3/11/23 00:48, Xin Li wrote:
> #define GDT_ENTRY_ESPFIX_SS 26
> #define GDT_ENTRY_PERCPU 27
> +#ifndef BUILD_VDSO32_64
> #define GDT_ENTRY_CPUNODE 28
> +#else
> +#define GDT_ENTRY_CPUNODE 15
> +#endif
Isn't this kinda a hack?
First, it means that we'll now have two duplicate versions of this:
#define GDT_ENTRY_CPUNODE 15
in the same file.
Second, if any other users of fake_32bit_build.h for the VDSO show up,
they'll need a similar #ifdef.
I think I'd much rather if we define all of the GDT_ENTRY_* macros in
*one* place, then make that *one* place depend on BUILD_VDSO32_64.
Also, about the *silent* failure... Do we not have a selftest for this
somewhere?
next prev parent reply other threads:[~2023-03-13 15:22 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-11 8:48 Xin Li
2023-03-13 15:22 ` Dave Hansen [this message]
2023-03-13 17:42 ` Li, Xin3
2023-03-18 8:14 ` Li, Xin3
2023-03-29 8:50 ` Li, Xin3
2023-03-29 23:11 ` Li, Xin3
2023-03-29 23:59 ` H. Peter Anvin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5e84fd48-459d-8850-d26f-860c6d34a9ad@intel.com \
--to=dave.hansen@intel.com \
--cc=bigeasy@linutronix.de \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=shan.kang@intel.com \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
--cc=xin3.li@intel.com \
--cc=yujie.liu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®