Comment 31 for bug 322610

Revision history for this message
Dominik Stadler (dominik-stadler) wrote : Re: [Regression] Screen brightness not 100% at boot or resume from monitor sleep

As a workaround I use the following script as /etc/pm/sleep.d/01LCD to fix this for resume from sleep/hibernate. This is on a Thinkpad T500. A similar thing should be possible somewhere in the boot scripts as well.

#!/bin/sh
# Workaround for LCD brightness bug
# Save this as /etc/pm/sleep.d/01LCD

#. "${PM_FUNCTIONS}"
. "/usr/lib/pm-utils/functions"

case "$1" in
        hibernate|suspend)
                ;;
        thaw|resume)
                # for some reason the backlight brightness is reset and not set correctly any more, try
                # to get and set the current brightness to re-set the correct one here

                BACKLIGHT=`cat /proc/acpi/video/VID/LCD0/brightness | grep current | awk '{print $2}'`
                logger -t resume -p user.notice "Applying quirk to set full backlight brightness back to $BACKLIGHT"
                echo $BACKLIGHT > /proc/acpi/video/VID/LCD0/brightness
                ;;
        *)
                ;;
esac