挂起/休眠在华硕笔记本电脑上不起作用

Modified on: Sun, 10 Jun 2018 02:30:53 +0800

我在我的新华硕U30SD-XA1笔记本电脑上暂停Ubuntu 11.04(Natty Narwhal)时出现问题。这是市场上的一款新笔记本电脑。这是一个已知问题,是否有解决方法?

基本上,每当我关闭笔记本电脑或让笔记本电脑进入睡眠状态时,屏幕会变黑,但视频卡实际上并没有关闭,然后风扇转动的速度比之前更快并且变热。

我确实看到有些人在其他笔记本电脑上遇到了类似的问题,他们将内核设置回来了。我对Ubuntu很新,而且我不太习惯搞乱内核。

我没有使用520M Nvidia驱动程序,因为它无法加载 Unity 。我也听过很多关于Ubuntu论坛驱动程序的坏事,所以我停用了驱动程序。

最佳答案

这似乎是许多华硕笔记本电脑的常见问题。试试这个:

  

来源: http://thecodecentral.com/2011/01/18/fix-ubuntu-10-10-suspendhibernate-not-working-bug

在终端中运行:

gksu gedit /etc/pm/sleep.d/20_custom-ehci_hcd 

将以下内容复制并粘贴到文本编辑器中:

#!/bin/sh #inspired by http://art.ubuntuforums.org/showpost.php?p=9744970&postcount=19 #...and http://thecodecentral.com/2011/01/18/fix-ubuntu-10-10-suspendhibernate-not-working-bug # tidied by tqzzaa :) VERSION=1.1 DEV_LIST=/tmp/usb-dev-list DRIVERS_DIR=/sys/bus/pci/drivers DRIVERS="ehci xhci" # ehci_hcd, xhci_hcd HEX="[[:xdigit:]]" MAX_BIND_ATTEMPTS=2 BIND_WAIT=0.1 unbindDev() { echo -n > $DEV_LIST 2>/dev/null for driver in $DRIVERS; do DDIR=$DRIVERS_DIR/${driver}_hcd for dev in `ls $DDIR 2>/dev/null | egrep "^$HEX+:$HEX+:$HEX"`; do echo -n "$dev" > $DDIR/unbind echo "$driver $dev" >> $DEV_LIST done done } bindDev() { if [ -s $DEV_LIST ]; then while read driver dev; do DDIR=$DRIVERS_DIR/${driver}_hcd while [ $((MAX_BIND_ATTEMPTS)) -gt 0 ]; do echo -n "$dev" > $DDIR/bind if [ ! -L "$DDIR/$dev" ]; then sleep $BIND_WAIT else break fi MAX_BIND_ATTEMPTS=$((MAX_BIND_ATTEMPTS-1)) done done < $DEV_LIST fi rm $DEV_LIST 2>/dev/null } case "$1" in hibernate|suspend) unbindDev;; resume|thaw) bindDev;; esac

保存,然后

#!/bin/sh
#inspired by http://art.ubuntuforums.org/showpost.php?p=9744970&postcount=19
#...and http://thecodecentral.com/2011/01/18/fix-ubuntu-10-10-suspendhibernate-not-working-bug    
# tidied by tqzzaa :)

VERSION=1.1
DEV_LIST=/tmp/usb-dev-list
DRIVERS_DIR=/sys/bus/pci/drivers
DRIVERS="ehci xhci" # ehci_hcd, xhci_hcd
HEX="[[:xdigit:]]"
MAX_BIND_ATTEMPTS=2
BIND_WAIT=0.1

unbindDev() {
  echo -n > $DEV_LIST 2>/dev/null
  for driver in $DRIVERS; do
    DDIR=$DRIVERS_DIR/${driver}_hcd
    for dev in `ls $DDIR 2>/dev/null | egrep "^$HEX+:$HEX+:$HEX"`; do
      echo -n "$dev" > $DDIR/unbind
      echo "$driver $dev" >> $DEV_LIST
    done
  done
}

bindDev() {
  if [ -s $DEV_LIST ]; then
    while read driver dev; do
      DDIR=$DRIVERS_DIR/${driver}_hcd
      while [ $((MAX_BIND_ATTEMPTS)) -gt 0 ]; do
          echo -n "$dev" > $DDIR/bind
          if [ ! -L "$DDIR/$dev" ]; then
            sleep $BIND_WAIT
          else
            break
          fi
          MAX_BIND_ATTEMPTS=$((MAX_BIND_ATTEMPTS-1))
      done  
    done < $DEV_LIST
  fi
  rm $DEV_LIST 2>/dev/null
}

case "$1" in
  hibernate|suspend) unbindDev;;
  resume|thaw)       bindDev;;
esac

相关问答

添加新评论