Page 1 of 2 12 LastLast
Results 1 to 15 of 30

Thread: Want to instantly get a 15% performance boost?

  1. #1

    Want to instantly get a 15% performance boost?

    Then issue the following command:

    echo "interrupt=no" > /proc/miscio/power_enable_config

    I finally found out what is causing ksoftirqd so much grief! It is the gpio driver. Turns out the +5V power on/off gpio is configured as an output (OK) and also an interrupt source (not OK). This results in a gpio interrupt storm.

    The only thing that keeps the problem from being *much* worse is that the gpio driver disables gpio interrupts while it applies a 10mS debounce period to the input pins. This action limits the total number of actual interrupts to only 100 / sec which is not so bad.

    The performance hit comes from the way the debounce actually happens. In the driver, input pins are debounced by continuously rescheduling a bottom half tasklet until the 10mS debounce period has expired. Ksoftirqd was being charged with this CPU time. The sharing of time slices between this tasklet and other runnable, cpu bound, processes resulted in the degraded performance.

    Here's the before and after execution time of a cpu intensive task:

    # time /bin/tar tvzf junk.tgz > /opt/tmp/file.txt
    real 4m 40.36s
    user 3m 54.46s
    sys 0m 3.02s
    # echo "interrupt=no" > /proc/miscio/power_enable_config
    # time /bin/tar tvzf junk.tgz > /opt/tmp/file.txt
    real 4m 0.15s
    user 3m 54.14s
    sys 0m 3.04s

    See how the real time went from 4:40.36 to 4:00.15? That's 16.7% faster!

    One final thing, here's the new load average of my box:

    load average: 0.14, 0.03, 0.01 ;-)

    - K.C.
    Last edited by kfurge; 12-03-2007 at 02:07.

  2. #2
    Well done KC! Great work!

    LK

  3. #3
    Is this a switch I have to execute once or do I have to add this to the rc.local file?

    Thanks,

    Bart

  4. #4
    Quote Originally Posted by Fatboysec View Post
    Is this a switch I have to execute once or do I have to add this to the rc.local file?
    It must be executed after every reset. So the best place to do it is in rc.local.

    - K.C.

  5. #5
    Did it, thanks.

    Sollie.

  6. #6
    I tried issuing the command and got:

    [kenn@WL700gE /]$ echo "interrupt=no" > /proc/miscio/power_enable_config
    -bash: /proc/miscio/power_enable_config: Permission denied


    I'm stumped....

  7. #7
    Join Date
    Jan 2007
    Location
    Netherlands
    Posts
    190
    Quote Originally Posted by fireflash View Post
    I tried issuing the command and got:

    [kenn@WL700gE /]$ echo "interrupt=no" > /proc/miscio/power_enable_config
    -bash: /proc/miscio/power_enable_config: Permission denied


    I'm stumped....
    sudo bash --to get a root shell

    then

    echo "interrupt=no" > /proc/miscio/power_enable_config

    Openwrt or Custom Firmware on asus? - http://wl700ge.hezik.nl/ - Http://wl700g.homelinux.net

    My ASUS collection: WL500gp(80GB usb-hdd - Running OpenWrt Kamikaze 7.09) | WL700gE(250GB - Running OpenWrt Kamikaze 8.09rc1)

  8. #8
    are there any disadvantages for the box if i do that?

    grat182

  9. #9
    Quote Originally Posted by gratitude182 View Post
    are there any disadvantages for the box if i do that?

    grat182
    Absolutely not.

    - K.C.

  10. #10
    nice to hear :-)

    thanks again kfurge!

  11. Any ideas if it's also for the 500g (deluxe) versions?

  12. #12
    Quote Originally Posted by Elect View Post
    Any ideas if it's also for the 500g (deluxe) versions?
    Dunno. The thing to look for is whether or not the /proc/miscio/power_enable is configured as an output with interrupts enabled and your average inactive cpu load is 1.00. If so, then the countermeasure will probably help.

    To test, type 'cat /proc/miscio/power_enable_config'.

    These two lines matter:

    direction=out
    interrupt=no

    If interrupt=yes, change it as posted.

    - K.C.

  13. #13
    Quote Originally Posted by back2basic View Post
    sudo bash --to get a root shell

    then

    echo "interrupt=no" > /proc/miscio/power_enable_config
    Sometimes it's the simplest things.

    Thanks, works great! Fired up TOP right after issuing the command and watched the load average take a nose dive. I'm sure our little router's processors thank us for doing this

  14. #14

    Where ist top

    Hi,
    where can I watch at the performance?
    On my router is no top command. Is there anything else ??

    -Magnus

  15. #15

    Talking Amazing

    Wow this worked amazing

    I have to say a big thankyou to kfurge, d3viant and everyone on these boards. I never used unix before at all and spent 13 hours total, but I got it running great. I successfully installed mt-daapd and have itunes share running AMAZING on the router. AND IT SUPPORTS MY ID3 tagging for once!

    Just a big thank you for everyone who contributed to this project. I must I'm feeling a lot better being able to have a router actually capable of running the apps it's suppose too. (I'll stick with utorrent on the pc instead of the router since I've heard problems with reserf and dl speeds being horribly slow_

    I simply was able to add the echo into my rc.local and it's running a good bit faster. If you've down the firmware hack, you must be sure to vi or nano ur rc.local and add this in.

    Also, is it possible that I'm ftp'ing locally faster? I was ftp around 3000 kbs, now it's around 3600? Anyways, thanks kfurg and everyone..This is well worth it unlike my first impressions. I'm glad I came across this site. I was about to ebay it

Page 1 of 2 12 LastLast

Similar Threads

  1. WL-HDD performance tweaking
    By rumagent in forum WL-HDD Q&A
    Replies: 10
    Last Post: 22-04-2007, 09:35
  2. Any way to boost the tranfer speed to extern HD?
    By Rasmuskarlsen in forum WL-500gP Q&A
    Replies: 6
    Last Post: 31-10-2006, 21:16
  3. Wifi performance
    By samitro in forum WL-500gP Q&A
    Replies: 5
    Last Post: 11-09-2006, 20:57
  4. Significant USB performance enhancement
    By Cryptic in forum WL-500g Custom Development
    Replies: 16
    Last Post: 08-08-2006, 19:06

Posting Permissions

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