Hi Yongcong, 2012/8/21 yongcong-github.master <community@xxxxxxxxxxxx>: > + cpuid_info cpuid; > + get_current_cpuid(&cpuid, 5); > + /* ecx[0] monitor/mwait extension supported > + * ecx[1] support for treating interrupts as break-events for mwait > + * edx number of sub-states > + */ > + if (!((cpuid.regs.ecx & 0x1) && (cpuid.regs.ecx & 0x2) && > + cpuid.regs.edx)) { > + return B_ERROR; > + } x86_check_feature() could have been used for these checks, provided definitions are correctly added to headers/private/kernel/arch/x86/arch_cpu.h and features loaded in src/system/kernel/arch/x86/arch_cpu.cpp#detect_cpu() As it's a private kernel API, that's probably not a good idea though. BTW coding style recommands the use of != 0 for such checks ie: ((cpuid.regs.ecx & 0x2) != 0) Bye, Jérôme