91 feature_reg = (
opts.ecx ? feature_regs->
ecx : feature_regs->
edx );
94 return ( ( feature_reg & ( 1 <<
bit ) ) ? 0 : -
ENOENT );
int parse_integer(char *text, unsigned int *value)
Parse integer value.
struct command cpuid_command __command
x86 CPU feature detection command
struct arbelprm_rc_send_wqe rc
int ecx
Check features defined via ecx.
static unsigned int unsigned int bit
int optind
Current option index.
FILE_LICENCE(GPL2_OR_LATER_OR_UBDL)
int amd
Check AMD-defined features (eax=0x80000001)
#define ENOENT
No such file or directory.
void x86_features(struct x86_features *features)
Get x86 CPU features.
int parse_options(int argc, char **argv, struct command_descriptor *cmd, void *opts)
Parse command-line options.
static int cpuid_exec(int argc, char **argv)
The "cpuid" command.
Parse command-line options.
int parse_flag(char *text __unused, int *flag)
Parse flag.
uint32_t ecx
Features returned via ecx.
static uint32_t uint32_t uint32_t uint32_t * ecx
x86 CPU feature detection
uint32_t features
Supported features.
Command line option parsing.
Option does not take an argument.
const char * name
Name of the command.
static struct option_descriptor cpuid_opts[]
"cpuid" option list
#define OPTION_DESC(_longopt, _shortopt, _has_arg, _struct, _field, _parse)
Construct option descriptor.
A command-line option descriptor.
#define COMMAND_DESC(_struct, _options, _min_args, _max_args, _usage)
Construct command descriptor.
uint32_t edx
Features returned via edx.
static struct command_descriptor cpuid_cmd
"cpuid" command descriptor
static union @438 opts
"cert<xxx>" option list
An x86 CPU feature register set.