public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "H. Peter Anvin" <hpa@zytor.com>
To: Borislav Petkov <bp@alien8.de>, Huaitong Han <huaitong.han@intel.com>
Cc: tglx@linutronix.de, mingo@redhat.com, david.vrabel@citrix.com,
	rusty@rustcorp.com.au, x86@kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH V2] x86: use enum cpuid_leafs instead of magic numbers
Date: Thu, 21 Jan 2016 13:04:57 -0800	[thread overview]
Message-ID: <56A147F9.1000306@zytor.com> (raw)
In-Reply-To: <20160121114250.GD21930@pd.tnic>

On 01/21/16 03:42, Borislav Petkov wrote:
> On Thu, Jan 21, 2016 at 07:02:40PM +0800, Huaitong Han wrote:
>> v2:add a commit message.
>>
>> Most of magic numbers of x86_capability have been converted to enum
>> cpuid_leafs, and this patch does update the remaining part.
>>
>> Signed-off-by: Huaitong Han <huaitong.han@intel.com>
>> ---
>>  arch/x86/include/asm/elf.h | 2 +-
>>  arch/x86/kernel/mpparse.c  | 2 +-
>>  arch/x86/lguest/boot.c     | 2 +-
>>  arch/x86/xen/enlighten.c   | 2 +-
>>  4 files changed, 4 insertions(+), 4 deletions(-)
> 

I'm wondering, though, if it wouldn't be better to turn these into
macros so that they can be used in assembly code.  That way the
definitions can be interspersed with the X86_FEATURE_ definitions, too.

	-hpa

  reply	other threads:[~2016-01-21 21:05 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-21 11:02 [PATCH V2] x86: use enum cpuid_leafs instead of magic numbers Huaitong Han
2016-01-21 11:42 ` Borislav Petkov
2016-01-21 21:04   ` H. Peter Anvin [this message]
2016-01-21 21:21     ` Borislav Petkov
2016-01-21 21:25       ` H. Peter Anvin
2016-01-21 21:33         ` Borislav Petkov
2016-01-21 21:37           ` H. Peter Anvin
2016-01-21 21:47             ` Borislav Petkov
2016-01-21 21:52               ` H. Peter Anvin
2016-01-21 21:05 ` 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=56A147F9.1000306@zytor.com \
    --to=hpa@zytor.com \
    --cc=bp@alien8.de \
    --cc=david.vrabel@citrix.com \
    --cc=huaitong.han@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=rusty@rustcorp.com.au \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.org \
    /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