Page 5 of 6 FirstFirst ... 3456 LastLast
Results 41 to 50 of 55

Thread: Linux 3.1 Kernel Draws More Power With Another Regression

  1. #41

    Default

    Quote Originally Posted by Cyborg16 View Post
    Bisecting isn't difficult, but it still takes time... lots of time considering there are probably a few thousand commits to go through and half an hour or so per commit with building a kernel and testing.
    I have been too busy to learn it. Hopefully I will have some time next month.

    Quote Originally Posted by Cyborg16 View Post
    As you can see, I never bothered to learn bash/sh very well. Thanks for that (but I still prefer indentation ;D ).
    Anytime.

    Quote Originally Posted by Cyborg16 View Post
    I never tried enabling this script at boot (I just run it when I need long(er) battery life). Other than powering down of USB mice I've not noticed side-effects, though I haven't tested much.
    I use Gentoo and I put it in /etc/local.d/boot.start. On gentoo, all /etc/local.d/*.start files are executed at system boot. Other distributions might use /etc/conf.d/local for this.

  2. #42

    Default

    I seem to have identified a side effect of doing this. It breaks ethtool. I need to force my ethernet interface to on in order for ethtool to return information:

    Code:
    echo "on" > /sys/devices/pci0000:00/0000:00:19.0/power/control
    I wonder if this is a kernel bug.

    By the way, Wake On LAN seems to be enabled on my laptop. Since it will never need that feature, I turned it off via "ethtool -s eth0 wol d".

  3. #43
    Join Date
    Jan 2009
    Posts
    1,309

    Default

    Quote Originally Posted by Cyborg16 View Post
    I have a T410 and I don't think this generation of lenovo machines have brilliant run-times; the lowest wattage I've got out of my machine is about 10W, but usually it's more like 13W. First tip: use powertop and close high-usage applications. In some cases KDE seems to suck a lot of power (though not always); a simpler DE like LXDE or even gnome 2 may save power. Firefox may not be the best web-browser for power-usage.

    Second, here's some notes for driver tuning:

    Code:
    #!/bin/bash
    
    # This is a collection of notes about various laptop power-tuning I've found on
    # the internet and tested on a lenovo T410.
    
    # Booting with the pcie_aspm=force kernel option helps:
    # Force ASPM:
    # 13.4W idle, 34W glxgears
    # Without:
    # 14.6W idle, 35W glxgears
    
    # Wifi appears to use about 1.8W
    # Wifi power saving (enabled by powertop) saves perhaps half a watt
    
    # Screen uses perhaps 4.5W more on full brightness than on minimum
    
    # These tweaks can only be done by root
    if [ "$(id -u)" != "0" ]; then
       echo "This script must be run as root" 1>&2
       exit 1
    fi
    
    # Setting power control of all devices to auto possibly saves about 0.8W (need
    # to do a better test):
    # (Note that this appears to disable external mice until you re-plug them in.)
    setauto() {
        file=$1
        
        if [[ "$file" =~ 'power' ]]
        then
            if [[ "$(cat $file)" != "auto" ]]
            then
                echo -n $file: 
                cat $file
                echo "auto" > $file
            fi
        fi
    }
    for f in $(find /sys/devices/pci* -name "control")
    do
        setauto $f
    done
    
    # Disabling nmi_watchdog has no obvious effect:
    # echo 0 > /proc/sys/kernel/nmi_watchdog
    
    # Turning off USB (instead of leaving auto) appears to have no effect:
    # (I seem to have lost the commands to do this. Never mind.)
    This is brilliant! Thanks for these.
    I'll go over this script and see what effect these have and report back.

  4. #44
    Join Date
    Jan 2009
    Posts
    1,309

    Default

    Quote Originally Posted by Med_ View Post
    Well, Cyborg16 already gave all the useful hints. All i did was adding the following to my rc.local:
    Code:
    echo 1 > /sys/module/snd_hda_intel/parameters/power_save
    
    for i in /sys/class/scsi_host/host?/link_power_management_policy; do
        echo min_power > $i
    done
    
    for i in /sys/bus/usb/devices/*/power/autosuspend; do
        echo 1 > $i
    done
    
    for i in /sys/bus/{pci,i2c}/devices/*/power/control; do
        echo auto > $i
    done
    In addition i pass pcie_aspm=force i915.i915_enable_rc6=1 to the kernel at boot. Of course laptop-mode is activated. That was enough to drop to 9W when idle and for powertop2 not to find anything extra to save power.
    Thanks _med.
    I'm not sure the i915 option does much if you're not SB.
    Best/Liam

  5. #45

    Default

    Quote Originally Posted by liam View Post
    Thanks _med.
    I'm not sure the i915 option does much if you're not SB.
    Best/Liam
    We would need to check the code, but anything that relies on the i915 driver might benefit. Either that or it could crash horribly, which is why this was disabled in the first place

  6. #46

    Default

    I found another issue with setting everything to auto. My laptop no longer shuts down properly. I am trying to identify the cause.

    Edit: It doesn't seem like only 1 device is causing this problem and I don't have time to understand it better right now. For the moment, I have configured a shutdown script to set everything to "on" immediately prior to shutdown, which allows my laptop to shutdown properly.
    Last edited by Shining Arcanine; 08-24-2011 at 01:23 AM.

  7. #47
    Join Date
    Aug 2011
    Posts
    58

    Default

    I have questions:
    * Which Sandy Bridge notebook was tested in article?
    * I have Sandy Bridge notebook with discreate Radeon card and I do not see integrated Radeon in lspci (module i915 is not loading). Should be problem on my notebook too?
    * What Sandy Bridge functionaly was added to kernels 3.0 and 3.1? Can I use old kernel (2.6.35) on my Sandy Bridge notebook?

  8. #48

    Default

    The Linux kernel is being developed for servers. It's time for a fork that creates a desktop oriented kernel.

    Maybe Canonical should stop patching the official kernel and start that fork.

  9. #49
    Join Date
    Apr 2011
    Posts
    31

    Default

    Quote Originally Posted by Aleve Sicofante View Post
    The Linux kernel is being developed for servers. It's time for a fork that creates a desktop oriented kernel.

    Maybe Canonical should stop patching the official kernel and start that fork.
    There are already Desktop oriented forks and see how popular they are, oh wait.

    Also Power consumption is very important in severs, lower power means less heat and lower operating costs for the datacenter. The issue here was that the power saving features or w/e "rc6" is was buggy on sandybridge they disabled it so that you could actually use your laptop, which is much more important than how long the battery lasts.

  10. #50
    Join Date
    Feb 2010
    Location
    Sweden
    Posts
    58

    Default

    Yes Power is important for server farms, but usually this means that one uses virtualization techniques to pack each server more resource wise so that you can completely shut the idle ones down (and then wake them on lan when usage requires more servers). Also one has to consider whether IBM, Google and Red Hat even uses the kernels in question yet.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •