[BACK]Return to acpi.h CVS log [TXT][DIR] Up to [Development] / linux-2.6-xfs / include / asm-x86

File: [Development] / linux-2.6-xfs / include / asm-x86 / acpi.h (download)

Revision 1.2, Mon Jan 7 15:11:45 2008 UTC (9 years, 9 months ago) by lachlan.longdrop.melbourne.sgi.com
Branch: MAIN
Changes since 1.1: +27 -0 lines

Merge up to 2.6.24-rc6
Merge of 2.6.x-xfs-melb:linux:30301a by kenmcd.

#ifndef _ASM_X86_ACPI_H
#define _ASM_X86_ACPI_H

#ifdef CONFIG_X86_32
# include "acpi_32.h"
#else
# include "acpi_64.h"
#endif

#include <asm/processor.h>

/*
 * Check if the CPU can handle C2 and deeper
 */
static inline unsigned int acpi_processor_cstate_check(unsigned int max_cstate)
{
	/*
	 * Early models (<=5) of AMD Opterons are not supposed to go into
	 * C2 state.
	 *
	 * Steppings 0x0A and later are good
	 */
	if (boot_cpu_data.x86 == 0x0F &&
	    boot_cpu_data.x86_vendor == X86_VENDOR_AMD &&
	    boot_cpu_data.x86_model <= 0x05 &&
	    boot_cpu_data.x86_mask < 0x0A)
		return 1;
	else
		return max_cstate;
}

#endif