/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
/*
* Copyright (c) 2009, Intel Corporation.
* All rights reserved.
*/
/*
* Intel specific CPU power management support.
*/
#include <sys/x86_archext.h>
#include <sys/cpu_acpi.h>
#include <sys/speedstep.h>
#include <sys/cpupm_throttle.h>
#include <sys/cpu_idle.h>
#include <sys/archsystm.h>
/*
* The Intel Processor Driver Capabilities (_PDC).
* See Intel Processor Vendor-Specific ACPI Interface Specification
* for details.
*/
/*
* MSR for Intel ENERGY_PERF_BIAS feature.
* The default processor power operation policy is max performance.
* Power control unit drives to max performance at any energy cost.
* This MSR is designed to be a power master control knob,
* it provides 4-bit OS input to the HW for the logical CPU, based on
* user power-policy preference(scale of 0 to 15). 0 is highest
* performance, 15 is minimal energy consumption.
* 7 is a good balance between performance and energy consumption.
*/
#define EPB_MAX_PERF 0
/*
* The value is used to initialize the user power policy preference
* in IA32_ENERGY_PERF_BIAS_MSR. Variable is used here to allow tuning
*/
{
if (x86_vendor != X86_VENDOR_Intel)
return (B_FALSE);
/*
* If we support SpeedStep on this processor, then set the
* correct cma_ops for the processor and enable appropriate
* _PDC bits.
*/
} else {
}
/*
* Set the correct tstate_ops for the processor and
* enable appropriate _PDC bits.
*/
/*
* If we support deep cstates on this processor, then set the
* correct cstate_ops for the processor and enable appropriate
* _PDC bits.
*/
/*
* _PDC support is optional and the driver should
* function even if the _PDC write fails.
*/
/*
* If Intel ENERGY PERFORMANCE BIAS feature is supported,
* provides input to the HW, based on user power-policy.
*/
if (cpuid_iepb_supported(cp)) {
}
return (B_TRUE);
}
/*
* ENERGY_PERF_BIAS setting,
* A hint to HW, based on user power-policy
*/
static void
{
iflag = intr_clear();
}