ACPI组/操作未定义:处理器/ LNXCPU


12

如果从交流电源适配器上拔下笔记本电脑的电源,会出现如下所示的ACPI错误:

May 07 21:45:04 veritas root[7067]: ACPI group/action undefined: processor / LNXCPU:00
May 07 21:45:04 veritas root[7076]: ACPI group/action undefined: processor / LNXCPU:01
May 07 21:45:04 veritas root[7078]: ACPI group/action undefined: processor / LNXCPU:02
May 07 21:45:04 veritas root[7080]: ACPI group/action undefined: processor / LNXCPU:03

acpi_listen 转储

ac_adapter ACPI0003:00 00000080 00000000
battery PNP0C0A:00 00000080 00000001
processor LNXCPU:00 00000080 00000015
processor LNXCPU:01 00000080 00000015
processor LNXCPU:02 00000080 00000015
processor LNXCPU:03 00000080 00000015
processor LNXCPU:00 00000081 00000000
processor LNXCPU:01 00000081 00000000
processor LNXCPU:02 00000081 00000000
processor LNXCPU:03 00000081 00000000
...
processor LNXCPU:00 00000080 00000000
processor LNXCPU:01 00000080 00000000
processor LNXCPU:02 00000080 00000000
processor LNXCPU:03 00000080 00000000

/etc/acpi/handler.sh 似乎无法处理处理器/ LNXCPU事件...

#!/bin/bash
# Default acpi script that takes an entry for all actions

case "$1" in
    button/power)
        case "$2" in
            PBTN|PWRF)
                logger 'PowerButton pressed'
                ;;
            *)
                logger "ACPI action undefined: $2"
                ;;
        esac
        ;;
    button/sleep)
        case "$2" in
            SLPB|SBTN)
                logger 'SleepButton pressed'
                ;;
            *)
                logger "ACPI action undefined: $2"
                ;;
        esac
        ;;
    ac_adapter)
        case "$2" in
            AC|ACAD|ADP0)
                case "$4" in
                    00000000)
                        logger 'AC unpluged'
                        ;;
                    00000001)
                        logger 'AC pluged'
                        ;;
                esac
                ;;
            *)
                logger "ACPI action undefined: $2"
                ;;
        esac
        ;;
    battery)
        case "$2" in
            BAT0)
                case "$4" in
                    00000000)
                        logger 'Battery online'
                        ;;
                    00000001)
                        logger 'Battery offline'
                        ;;
                esac
                ;;
            CPU0)
                ;;
            *)  logger "ACPI action undefined: $2" ;;
        esac
        ;;
    button/lid)
        case "$3" in
            close)
                logger 'LID closed'
                ;;
            open)
                logger 'LID opened'
                ;;
            *)
                logger "ACPI action undefined: $3"
                ;;
    esac
    ;;
    *)
        logger "ACPI group/action undefined: $1 / $2"
        ;;
esac

更糟糕的是,我将遇到严重的性能问题。(一切都会滞后!)我想这是由于处理器/ LNXCPU的反复尝试,因为性能问题与未定义的ACPI动作的错误密切相关,并且如果重新启动,性能将再次恢复正常。

但是,我不知道是什么原因...我试图cpupower控制CPU模式(节能或性能)并禁用tlp,但两者都没有帮助。

这是怎么发生的?是什么导致这个问题?而且,更重要的是,我该如何解决呢?非常感谢!

跟进:我注意到CPU的频率为400MHz(选择性能模式不起作用),但是重新启动后则变为800MHz(选择性能模式,频率为2.8GHz)。

Answers:


0

如果从交流电源适配器上拔下笔记本电脑的电源,会出现类似以下的ACPI错误...

在以下位置建议使用此方法:“ 未识别到ACPI AC适配器的插入/关闭 ”。

rzepaczyk-我的handler.sh:

# Default acpi script that takes an entry for all actions

minspeed=`cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_min_freq`
maxspeed=`cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq`
setspeed1="/sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed"
setspeed2="/sys/devices/system/cpu/cpu1/cpufreq/scaling_setspeed"
setspeed3="/sys/devices/system/cpu/cpu2/cpufreq/scaling_setspeed"
setspeed4="/sys/devices/system/cpu/cpu3/cpufreq/scaling_setspeed"

set $*

case "$1" in
    button/power)
        #echo "PowerButton pressed!">/dev/tty5
        case "$2" in
            PBTN|PWRF)  logger "PowerButton pressed: $2" ;;
            *)          logger "ACPI action undefined: $2" ;;
        esac
        ;;
    button/sleep)
        case "$2" in
            SLPB)   echo -n mem >/sys/power/state ;;
            *)      logger "ACPI action undefined: $2" ;;
        esac
        ;;
    ac_adapter)
        case "$2" in
            AC*|ACAD*|ADP0*|AD*)
                case "$4" in
                    00000000)
                        echo -n $minspeed >$setspeed1
                        echo -n $minspeed >$setspeed2
                        echo -n $minspeed >$setspeed3
                        echo -n $minspeed >$setspeed4
                        #/etc/laptop-mode/laptop-mode start
                    ;;
                    00000001)
                        echo -n $maxspeed >$setspeed1
                        echo -n $maxspeed >$setspeed2
                        echo -n $maxspeed >$setspeed3
                        echo -n $maxspeed >$setspeed4
                        #/etc/laptop-mode/laptop-mode stop
                    ;;
                esac
                ;;
            *)  logger "ACPI action undefined: $2" ;;
        esac
        ;;
    battery)
        case "$2" in
            BAT0)
                case "$4" in
                    00000000)   #echo "offline" >/dev/tty5
                    ;;
                    00000001)   #echo "online"  >/dev/tty5
                    ;;
                esac
                ;;
            CPU0)
                ;;
            *)  logger "ACPI action undefined: $2" ;;
        esac
        ;;
    button/lid)
        case "$3" in
            close)
                #echo "LID closed!">/dev/tty5
                ;;
            open)
                #echo "LID opened!">/dev/tty5
                ;;
        esac
        ;;

    *)
        logger "ACPI group/action undefined: $1 / $2"
        ;;
esac

我想做的是在插入适配器时将cpu调速器设置为ondemand,而在拔出适配器时将节电。我看到动作是不确定的,所以我假设acpi无法识别动作(即使这样:

ac_adapter)
           case "$2" in
           AC*|ACAD*|ADP0*|AD*)

handler.sh中的条目。

Raynman-看起来像被处理了。acpi_listen除了显示日志中未定义的事件外,还显示ac_adapter事件。这些由您上次报价中的案例处理。然后在$ 4上有另一个case语句,以区分插入(00000001)和拔出(00000000)。如果您通过调用cpufreq-set(或您能想到的其他任何方法)替换那些echo语句,则它应该可以工作。

rzepaczyk-工作正常,谢谢您的帮助。

By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.