4

There are two SLES 11 servers:

SERVER311:~ # cat /sys/devices/system/cpu/cpuidle/current_driver
acpi_idle
SERVER311:~ #

and:

SERVER705:~ # cat /sys/devices/system/cpu/cpuidle/current_driver
intel_idle
SERVER705:~ #

Both having the:

intel_idle.max_cstate=0 processor.max_cstate=0

in the: "/boot/grub/menu.lst", were rebooted.

The question: what is the difference between acpi_idle and intel_idle ?

Peter
  • 521
  • 10
  • 21
  • 1
    [This question](https://unix.stackexchange.com/q/454896/120445) and [its answer](https://unix.stackexchange.com/a/454980/120445) contain a deep dive into the `intel_idle` driver and also compare its behavior to the `acpi_driver`. – Parker Aug 13 '18 at 16:59
  • I just want to point out that the question was asked by Peter and commented upon by Parker. What are the odds? – Mike S Sep 15 '22 at 13:32

2 Answers2

6

Short Answer: Both are different implementations of CPU idle drivers. acpi_idle is the default driver, supports all CPU architectures, while intel_idle is Intel CPUs specific.

More details: The API for a CPU idle driver is defined in include/linux/cpuidle.h. It defines the "generic framework for CPU idle power management". acpi_idle driver (defined in drivers/acpi/processor_idle.c) implements this behaviour for all CPU architectures. intel_idle (defined in drivers/idle/intel_idle.c) is an idle driver designed specifically for modern Intel CPUs (from the comments in the intel_idle.c header):

/* * intel_idle.c - native hardware idle loop for modern Intel processors * ...

/* * intel_idle is a cpuidle driver that loads on specific Intel processors * in lieu of the legacy ACPI processor_idle driver. The intent is to * make Linux more efficient on these processors, as intel_idle knows * more than ACPI, as well as make Linux more immune to ACPI BIOS bugs. */

So for modern Intel CPUs you should use the intel_idle driver since it is designed specifically for increasing Intel CPUs' efficiency.

So why would some setups load with intel_idle and some with acpi_idle? This is what stated in the commit message introducing the intel_idle driver:

commit 2671717265ae6e720a9ba5f13fbec3a718983b65

Author: Len Brown Date: Mon Mar 8 14:07:30 2010 -0500

intel_idle: native hardware cpuidle driver for latest Intel processors

This EXPERIMENTAL driver supersedes acpi_idle on Intel Atom Processors, Intel Core i3/i5/i7 Processors and associated Intel Xeon processors.

It does not support the Intel Core2 processor or earlier.

For kernels configured with ACPI, CONFIG_INTEL_IDLE=y allows intel_idle to probe before the ACPI processor driver. Booting with "intel_idle.max_cstate=0" disables intel_idle and the system will fall back on ACPI's "acpi_idle".

Typical Linux distributions load ACPI processor module early, making CONFIG_INTEL_IDLE=m not easily useful on ACPI platforms.

intel_idle probes all processors at module_init time. Processors that are hot-added later will be limited to using C1 in idle.

Signed-off-by: Len Brown

So the reasons are:

  1. Non-Intel CPU on the system or older Intel architectures.
  2. Not marked CONFIG_INTEL_IDLE=y in .config
  3. Booting with intel_idle.max_cstate=0 in cmdline

Since you said you set #3 on both setups the question is why one of them loaded with intel_idle. Try 'cat /proc/cmdline' and make sure the option is really set. Also, check the differences between the architectures with 'lscpu' or 'cat /proc/cpuinfo'

Rui F Ribeiro
  • 55,929
  • 26
  • 146
  • 227
Tgilgul
  • 443
  • 1
  • 3
  • 10
0

The other answer summarized differences really well, intel_idle vs acpi_idle.

Giving additional info on how to enable each of the drivers. This assumes kernel was built with CONFIG_INTEL_IDLE=y.

  • intel_idle: Enable C-States on platform BIOS, and do not use any kernel boot argument, then check that /sys/devices/system/cpu/cpuidle/current_driver shows intel_idle.
  • acpi_idle: Enable C-States on platform BIOS, use intel_idle.max_cstate=0 kernel boot argument, check current_driver is acpi_idle.
  • Fully disable C-States: Disable C-States on platform BIOS, include intel_idle.max_cstate=0 kernel boot argument, check current_driver is none.
milpita
  • 101
  • 1