Hi, I merged 2., 3. and 4. (attached) with some modifications. 1. There is now a module parameter apm-idle-threshold which allows to override the compiled in idle percentage threshold above which BIOS idle calls are done. 2. I modified Andrej's mechanism to detect a defunct BIOS (stating 'does stop CPU' when it actually doesn't) to take into account that there's other interrupts than the timer interrupt that could reactivate the cpu. As there's 16 hardware interrupts on x86 (apm is arch specific anyway) I do use a leaky bucket counter for a maximum of 16 idle rounds until jiffies is increased. When the counter reaches zero it stays at this value and the system idle routine is called. If BIOS idle is a noop then the counter reaches zero fast, thus effectively halting the cpu. Andrej, could you please test the patch if it works for your laptop? On 22-Dec-2001 Thomas Hood wrote: > I wrote: > --------------------------------------------------------------------- > Here is an updated list of the patches: > 1. Notify listener of suspend before drivers (Russell King, me) > (appended) > 2. Fix idle handling (Andreas Steinmetz) > http://marc.theaimsgroup.com/?l=linux-kernel&m=100754277600661&w=2 > 3. Control apm idle calling by runtime parameter (Andrej Borsenkow) > http://marc.theaimsgroup.com/?l=linux-kernel&m=100852862320955&w=2 > 4. Detect failure to stop CPU on apm idle call (Andrej Borsenkow) > http://marc.theaimsgroup.com/?l=linux-kernel&m=100869841008117&w=2 > --------------------------------------------------------------------- > > I have just tried to combine these and I have run into trouble. > Patch 4 applies on top of patch 3, but neither of these applies > on top of patch 2. Can you guys sort these out into one big > "fix idle calling" patch that includes a runtime parameter > to control idle calling, which overrides a default selected > either by CONFIG_APM_CPU_IDLE or by a bit of code that checks > for CPU stoppage? > > Or has someone already done this? > > The latest Russell King (modified by me) patch is now at: > http://panopticon.csustan.edu/thood/apm.html > > -- > Thomas Hood > > > Andreas Steinmetz D.O.M. Datenverarbeitung GmbH