[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: CPUID module
From: |
Robert Millan |
Subject: |
Re: CPUID module |
Date: |
Sat, 19 May 2007 12:55:35 +0200 |
User-agent: |
Mutt/1.5.13 (2006-08-11) |
On Fri, May 18, 2007 at 08:35:35PM +0200, Yoshinori K. Okuji wrote:
> > This module checks for CPU features
> > (currently only the long_mode flag, but more could be added if needed)
> > using cpuid. The idea behind this is that grub.cfg scripts can use it to
> > decide wether a 64-bit or 32-bit Linux image should be boot (e.g. like
> > Debian multiarch CDs do). I haven't investigated what the syntax for that
> > hack would be, although I assume it's possible.
>
> Personally, I think it would be cleaner to just return true or false (like
> test) rather than setting an environment variable. For instance:
Done.
> if cpuid --long-mode; then ...; else ...; fi
The return value ($?) is set, but this syntax doesn't work. How can this
functionality be tested?
> No. Please use commands/i386/. "util" is strictly for utilities for an host
> operating system.
Done.
Please have a look at the new patch.
2007-05-19 Robert Millan <address@hidden>
* commands/i386/cpuid.c: New module.
* DISTLIST: Add it.
* conf/i386-efi.rmk: Enable cpuid.mod.
* conf/i386-pc.rmk: Likewise.
--
Robert Millan
My spam trap is address@hidden Note: this address is only intended
for spam harvesters. Writing to it will get you added to my black list.
cpuid.diff
Description: Text Data