Subversion Repositories HelenOS

Compare Revisions

Ignore whitespace Rev 3706 → Rev 3707

/trunk/kernel/arch/ia32/include/drivers/ega.h
40,6 → 40,7
#define ROWS 25
#define SCREEN (ROW * ROWS)
 
extern void ega_redraw(void);
extern void ega_init(void);
 
#endif
/trunk/kernel/arch/ia32/include/drivers/vesa.h
36,6 → 36,7
#define KERN_ia32_VESA_H_
 
extern int vesa_present(void);
extern void vesa_redraw(void);
extern void vesa_init(void);
 
#endif
/trunk/kernel/arch/ia32/src/ia32.c
93,7 → 93,7
vesa_init();
else
#endif
ega_init(); /* video */
ega_init(); /* video */
/* Enable debugger */
debugger_init();
159,8 → 159,15
*/
void arch_grab_console(void)
{
#ifdef CONFIG_FB
vesa_redraw();
#else
ega_redraw();
#endif
i8042_grab();
}
 
/** Return console to userspace
*
*/
/trunk/kernel/arch/ia32/src/cpu/cpu.c
65,8 → 65,8
 
static char *vendor_str[] = {
"Unknown Vendor",
"AuthenticAMD",
"GenuineIntel"
"AMD",
"Intel"
};
 
void fpu_disable(void)
77,7 → 77,7
"mov %%eax,%%cr0;"
:
:
:"%eax"
: "%eax"
);
}
 
89,7 → 89,7
"mov %%eax,%%cr0;"
:
:
:"%eax"
: "%eax"
);
}
 
140,29 → 140,31
/*
* Check for AMD processor.
*/
if (info.cpuid_ebx==AMD_CPUID_EBX && info.cpuid_ecx==AMD_CPUID_ECX && info.cpuid_edx==AMD_CPUID_EDX) {
if ((info.cpuid_ebx == AMD_CPUID_EBX)
&& (info.cpuid_ecx == AMD_CPUID_ECX)
&& (info.cpuid_edx == AMD_CPUID_EDX))
CPU->arch.vendor = VendorAMD;
}
 
/*
* Check for Intel processor.
*/
if (info.cpuid_ebx==INTEL_CPUID_EBX && info.cpuid_ecx==INTEL_CPUID_ECX && info.cpuid_edx==INTEL_CPUID_EDX) {
if ((info.cpuid_ebx == INTEL_CPUID_EBX)
&& (info.cpuid_ecx == INTEL_CPUID_ECX)
&& (info.cpuid_edx == INTEL_CPUID_EDX))
CPU->arch.vendor = VendorIntel;
}
cpuid(1, &info);
CPU->arch.family = (info.cpuid_eax>>8)&0xf;
CPU->arch.model = (info.cpuid_eax>>4)&0xf;
CPU->arch.stepping = (info.cpuid_eax>>0)&0xf;
CPU->arch.family = (info.cpuid_eax >> 8) & 0x0f;
CPU->arch.model = (info.cpuid_eax >> 4) & 0x0f;
CPU->arch.stepping = (info.cpuid_eax >> 0) & 0x0f;
}
}
 
void cpu_print_report(cpu_t* m)
void cpu_print_report(cpu_t* cpu)
{
printf("cpu%d: (%s family=%d model=%d stepping=%d) %dMHz\n",
m->id, vendor_str[m->arch.vendor], m->arch.family, m->arch.model, m->arch.stepping,
m->frequency_mhz);
printf("cpu%u: (%s family=%u model=%u stepping=%u) %" PRIu16 " MHz\n",
cpu->id, vendor_str[cpu->arch.vendor], cpu->arch.family,
cpu->arch.model, cpu->arch.stepping, cpu->frequency_mhz);
}
 
/** @}
/trunk/kernel/arch/ia32/src/drivers/vesa.c
97,6 → 97,11
fb_init(&vesa_props);
}
 
void vesa_redraw(void)
{
fb_redraw();
}
 
#endif
 
/** @}