Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 108660
b: refs/heads/master
c: 7b27718
h: refs/heads/master
v: v3
  • Loading branch information
Joerg Roedel authored and Ingo Molnar committed Aug 13, 2008
1 parent 7132bc1 commit 65e5517
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0ed89b06e49c326bff81d81f24b9ba955eb912d5
refs/heads/master: 7b27718bdb1b70166383dec91391df5534d449ee
8 changes: 8 additions & 0 deletions trunk/arch/x86/boot/boot.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@
#include <asm/boot.h>
#include <asm/setup.h>

#define NCAPINTS 8

/* Useful macros */
#define BUILD_BUG_ON(condition) ((void)sizeof(char[1 - 2*!!(condition)]))

Expand Down Expand Up @@ -242,6 +244,12 @@ int cmdline_find_option(const char *option, char *buffer, int bufsize);
int cmdline_find_option_bool(const char *option);

/* cpu.c, cpucheck.c */
struct cpu_features {
int level; /* Family, or 64 for x86-64 */
int model;
u32 flags[NCAPINTS];
};
extern struct cpu_features cpu;
int check_cpu(int *cpu_level_ptr, int *req_level_ptr, u32 **err_flags_ptr);
int validate_cpu(void);

Expand Down
8 changes: 1 addition & 7 deletions trunk/arch/x86/boot/cpucheck.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,7 @@
#include <asm/required-features.h>
#include <asm/msr-index.h>

struct cpu_features {
int level; /* Family, or 64 for x86-64 */
int model;
u32 flags[NCAPINTS];
};

static struct cpu_features cpu;
struct cpu_features cpu;
static u32 cpu_vendor[3];
static u32 err_flags[NCAPINTS];

Expand Down
4 changes: 4 additions & 0 deletions trunk/arch/x86/boot/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,10 @@ static void keyboard_set_repeat(void)
*/
static void query_ist(void)
{
/* Some 486 BIOSes apparently crash on this call */
if (cpu.level < 6)
return;

asm("int $0x15"
: "=a" (boot_params.ist_info.signature),
"=b" (boot_params.ist_info.command),
Expand Down

0 comments on commit 65e5517

Please sign in to comment.