Re: suspend on 'idle'
Hi, > One method also to keep the XO from going into 'keyboard-idle' > mode... Sometimes what I do, is hit one of the 'modifer' keys on > the keyboard to keep the machine awake. (i.e. Hand, Fn, Ctrl, > Shift, Top row function keys, etc) > I wonder if there's a method to simulate this in software, so one > could keep a 'console' window (2 or 3?) open running the > 'non-idle-keyboard' application and keep the laptop awake when you > want it ? :) Why not just `touch /etc/ohm/inhibit-idle-suspend`? - Chris. -- Chris Ball <[EMAIL PROTECTED]> ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel
Re: suspend on 'idle'
2008/8/8 Ixo X oxI <[EMAIL PROTECTED]>: > One method also to keep the XO from going into 'keyboard-idle' mode... > > Sometimes what I do, is hit one of the 'modifer' keys on the keyboard to > keep the machine awake. (i.e. Hand, Fn, Ctrl, Shift, Top row function keys, > etc) > > I wonder if there's a method to simulate this in software, so one could keep > a 'console' window (2 or 3?) open running the 'non-idle-keyboard' > application and keep the laptop awake when you want it ? :) http://xkcd.com/196/ :) ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel
Re: suspend on 'idle'
One method also to keep the XO from going into 'keyboard-idle' mode... Sometimes what I do, is hit one of the 'modifer' keys on the keyboard to keep the machine awake. (i.e. Hand, Fn, Ctrl, Shift, Top row function keys, etc) I wonder if there's a method to simulate this in software, so one could keep a 'console' window (2 or 3?) open running the 'non-idle-keyboard' application and keep the laptop awake when you want it ? :) -iXo On Wed, Aug 6, 2008 at 21:01, Mikus Grinbergs <[EMAIL PROTECTED]> wrote: > First of all. I want to mention that when I first install a Joyride > build, the initial state of the 'inhibit' flags (i.e., filenames) in > /etc and /etc/ohm is "not present" -- that allows the XO to > 'suspend'. Yet on the 'Power' sub-panel within the olpc 'Control > Panel', the 'Automatic power management' box is __NOT__ checked. I > thought that box would control 'suspend' -- and leaving it unchecked > would mean "I don't want my XO to suspend". Seems like an > incompatibility somewhere. > > More to the point, I perform a number of actions as part of > "installing" a new build. Lately, if I forget to first set > 'inhibit-idle-suspend', the XO is __suspending__ on me while > performing downloads (via yum) of modules to augment what the build > contained. [I use ethernet, and 'suspend' currently kills it - so I > have to reboot to again have an ethernet connection.] I *really* > would like 'idle' to mean "processor is idle" -- not just "keyboard > is idle" (of course my keyboard is idle -- I'm waiting for the > still-ongoing downloads to finish before I type the next command). > > mikus > > ___ > Devel mailing list > Devel@lists.laptop.org > http://lists.laptop.org/listinfo/devel > ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel
Re: suspend on 'idle'
Mikus Grinbergs wrote: > But what got me started on this topic was that on one XO I run a > background (nice 19) task 24/7. If I don't "inhibit" it, I've seen > that XO 'suspend' - even though its CPU was 100% utilized! That is > a Linux application for which I only have the binary -- it would be > out of the question for me to "patch" the application so as to give > "hints" to ohm. You would not have to patch it. Simply wrapper it in script that sends the appropriate dbus messages when the script starts and exits. But if it really is using 100% of cpu then the system should not be suspending. -- Richard Smith <[EMAIL PROTECTED]> One Laptop Per Child ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel
Re: suspend on 'idle'
> ... but the idleness threshold obviously isn't working for you. > If I allowed any CPU use at all (ie. the minimal amount you're using > to write to the NAND from the network) to inhibit suspend, suspend would > never happen; kernel threads use CPU in the background all the time. > We look for CPU use over 20% for a few seconds of time when deciding > whether to suspend. Originally, I distrusted 'suspend' because of reports of it corrupting the partition tables of removable storage devices. Even though that problem is supposed to have been fixed, I still turn off suspend because it interferes with other things I do. I believe I now remember -- I recently needed 'inhibit-idle-suspend' to prevent my XO from suspending during long ethernet downloads. But what got me started on this topic was that on one XO I run a background (nice 19) task 24/7. If I don't "inhibit" it, I've seen that XO 'suspend' - even though its CPU was 100% utilized! That is a Linux application for which I only have the binary -- it would be out of the question for me to "patch" the application so as to give "hints" to ohm. Actually, I posted in order to "let others know" what I've experienced. Now that I've seen your thoughts, my opinion is that I do NOT wish for any changes to your code. As long as the Control Panel makes it easy, I'm willing to manually specify "inhibit suspend" for when I'm executing long-duration tasks on my XO, and willing to manually specify "allow suspend" for when I'm using the XO as an ebook reader. ["Please, mom - I'd rather do it myself".] mikus ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel
Re: suspend on 'idle'
Mikus Grinbergs wrote: > would like 'idle' to mean "processor is idle" -- not just "keyboard > is idle" (of course my keyboard is idle -- I'm waiting for the > still-ongoing downloads to finish before I type the next command). Good idle detection is hard. What you are really wanting is "system idle" which requires a holistic approach rather than just a few subsystems. For example any device that is doing a large ammount of bus mastered DMA transactions will have a fairly low CPU usage but the system is certainly not idle. There are many workloads where our current heuristics fail. We hope to use the cpuidle subsystem + hints from apps to manage this but theres still a lot of work do me done here. -- Richard Smith <[EMAIL PROTECTED]> One Laptop Per Child ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel
Re: suspend on 'idle'
chris wrote: > > I think what you actually want is one of two things: > >* Not to suspend in the presence of any large network transfer. > I think this would only be necessary for your ethernet case, since > on wireless we're just going to be woken up by the next incoming > packet. As a result, I'm not so interested in adding this given > that you can inhibit suspend manually. > >* Not to suspend when a USB device capable of generating external > interrupts (USB keyboard, USB ethernet) is plugged in. I'd be > willing to add that, but I haven't worked out what the best way > to detect what classes of USB devices are being used is. Maybe > that's something you can help with? this might be an approach for the first problem, too -- inhibit suspend in the presence of a USB ethernet adapter (perhaps conditioned on UP and RUNNING as well). paul =- paul fox, [EMAIL PROTECTED] ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel
Re: suspend on 'idle'
Hi, [Removing sugar@ from CC: to keep this to one list.] > First of all. I want to mention that when I first install a Joyride > build, the initial state of the 'inhibit' flags (i.e., filenames) > in /etc and /etc/ohm is "not present" -- that allows the XO to > 'suspend'. Yet on the 'Power' sub-panel within the olpc 'Control > Panel', the 'Automatic power management' box is __NOT__ checked. I > thought that box would control 'suspend' -- and leaving it > unchecked would mean "I don't want my XO to suspend". Seems like > an incompatibility somewhere. Yup, noticed that yesterday. It's not an incompatibility, it's just that OHM doesn't start out by reading the control panel value; if you change the control panel value once, the two will stay in sync from then on. Will fix. > More to the point, I perform a number of actions as part of > "installing" a new build. Lately, if I forget to first set > 'inhibit-idle-suspend', the XO is __suspending__ on me while > performing downloads (via yum) of modules to augment what the build > contained. [I use ethernet, and 'suspend' currently kills it - so > I have to reboot to again have an ethernet connection.] Could you file a bug? I don't understand why you have to reboot to regain your ethernet connection after suspending. > I *really* would like 'idle' to mean "processor is idle" -- not > just "keyboard is idle" (of course my keyboard is idle -- I'm > waiting for the still-ongoing downloads to finish before I type the > next command). It does, but the idleness threshold obviously isn't working for you. If I allowed any CPU use at all (ie. the minimal amount you're using to write to the NAND from the network) to inhibit suspend, suspend would never happen; kernel threads use CPU in the background all the time. We look for CPU use over 20% for a few seconds of time when deciding whether to suspend. I think what you actually want is one of two things: * Not to suspend in the presence of any large network transfer. I think this would only be necessary for your ethernet case, since on wireless we're just going to be woken up by the next incoming packet. As a result, I'm not so interested in adding this given that you can inhibit suspend manually. * Not to suspend when a USB device capable of generating external interrupts (USB keyboard, USB ethernet) is plugged in. I'd be willing to add that, but I haven't worked out what the best way to detect what classes of USB devices are being used is. Maybe that's something you can help with? Thanks, - Chris. -- Chris Ball <[EMAIL PROTECTED]> ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel
Re: suspend on 'idle'
On Thu, Aug 7, 2008 at 1:30 AM, Mikus Grinbergs <[EMAIL PROTECTED]> wrote: > Please don't forget to think about what 'idle' means. Chris Ball is the power guru; if you can come up with a succinct test that ohm can do to determine if there is 'real work' going on that should inhibit idle, I'm sure he'd be interested. On the other hand, ohm has both a dbus and a filesystem interface to temporarily inhibit suspend; long CPU intensive tasks like yours should probably be using this to give ohm a hint -- that's what olpc-update does, for instance. --scott -- ( http://cscott.net/ ) ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel
Re: suspend on 'idle'
On Thu, Aug 7, 2008 at 12:01 AM, Mikus Grinbergs <[EMAIL PROTECTED]> wrote: > More to the point, I perform a number of actions as part of > "installing" a new build. Lately, if I forget to first set > 'inhibit-idle-suspend', the XO is __suspending__ on me while > performing downloads (via yum) of modules to augment what the build > contained. [I use ethernet, and 'suspend' currently kills it - so I You may find http://dev.laptop.org/ticket/6432 useful. --scott -- ( http://cscott.net/ ) ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel
suspend on 'idle'
First of all. I want to mention that when I first install a Joyride build, the initial state of the 'inhibit' flags (i.e., filenames) in /etc and /etc/ohm is "not present" -- that allows the XO to 'suspend'. Yet on the 'Power' sub-panel within the olpc 'Control Panel', the 'Automatic power management' box is __NOT__ checked. I thought that box would control 'suspend' -- and leaving it unchecked would mean "I don't want my XO to suspend". Seems like an incompatibility somewhere. More to the point, I perform a number of actions as part of "installing" a new build. Lately, if I forget to first set 'inhibit-idle-suspend', the XO is __suspending__ on me while performing downloads (via yum) of modules to augment what the build contained. [I use ethernet, and 'suspend' currently kills it - so I have to reboot to again have an ethernet connection.] I *really* would like 'idle' to mean "processor is idle" -- not just "keyboard is idle" (of course my keyboard is idle -- I'm waiting for the still-ongoing downloads to finish before I type the next command). mikus ___ Devel mailing list Devel@lists.laptop.org http://lists.laptop.org/listinfo/devel