# TLP

Related articles

- Laptop
- Laptop Mode Tools

TLP is an advanced power management tool for Linux targeted at laptops.

It performs automated background tasks and also provides a command-line tool called `tlp`.

## Installation

Install tlp from the official repositories.

Note: tlp conflicts with pm-utils and other power management tools like laptop-mode-tools.

Optional dependencies are:

- tp_smapi – optional ThinkPad only, tp-smapi is needed for battery charge thresholds and ThinkPad specific status output of tlp-stat
- acpi_call – optional ThinkPad only, acpi_call is needed for battery charge thresholds on Sandy Bridge and newer models (X220/T420, X230/T430)

Enable both provided systemd services:

    # systemctl enable tlp
    # systemctl enable tlp-sleep

## Configuration

The configuration file is located at `/etc/default/tlp` and provides optimized power saving by default. For a full list of options, see: TLP Configuration.

To make use of the ThinkPad-specific battery options, install and configure tp_smapi and/or acpi_call (see Installation).

### CPU frequency scaling governor

Tlp can control the CPU frequency scaling governor:

    CPU_SCALING_GOVERNOR_ON_AC=ondemand
    CPU_SCALING_GOVERNOR_ON_BAT=ondemand

You can even safe more battery (but reduces performance), by disabling Turbo Boost:

    CPU_BOOST_ON_AC=1
    CPU_BOOST_ON_BAT=0

### Hard disk spin down

Tlp can spin down disks to safe battery. However it may reduces performance or even 'brick' the HDD. You can disable this behavior:

    DISK_APM_LEVEL_ON_AC="254 254"
    DISK_APM_LEVEL_ON_BAT="254 254"

### Restore radio device state at boot

Tlp can restore the radio device state for bluetooth, wifi and wwan from the previous shutdown at boot via the following option:

    RESTORE_DEVICE_STATE_ON_STARTUP=1

Alternatively, to enable or disable specific devices at boot, use the following options:

    DEVICES_TO_DISABLE_ON_STARTUP="wifi"
    DEVICES_TO_ENABLE_ON_STARTUP=""

If you make use of one of these three options, it is necessary to mask the systemd service `systemd-rfkill` to avoid conflicts.

    # ln -s /dev/null /etc/systemd/system/systemd-rfkill@.service

## command-line tool

A command-line tool called `tlp` is provided, mainly for debugging purposes.

To generate a report of the loaded configuration and the current power state of the devices, run:

    # tlp stat

It can also be used to control battery charging and discharging on supported laptops.

To force a discharge of the battery even when AC is connected, run (Thinkpad Only):

    # tlp discharge

See `man tlp` for the full set of commands.

## Radio Device Wizard

The tlp radio device wizard manages the power state of bluetooth,wifi, and wwan devices. It requires NetworkManager to be installed as a dependency, and the relevant service to be started.

### Installation

Install tlp-rdw from the official repositories.

Enable the NetworkManager dispatcher service:

    # systemctl enable NetworkManager-dispatcher

### Configuration

The rdw is configured from the main configuration file `/etc/default/tlp`. The options relevant for the rdw are found at the end of this file and commented out by default.

## See also

- TLP - Linux Advanced Power Management - Project homepage & documentation

Category:

- Power management