[FIX] apm.c: ignore_normal_resume is set to 1 a bit too late

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This message contains a fix for a bug in the apm driver.

A bug report was submitted to the Debian BTS saying that on the
submitter's system the apmd proxy script was being run twice on resume.

Having seen exactly the same problem some years ago and knowing that the
solution then was to ensure that the ignore_normal_resume flag got set
before there was any chance of an APM RESUME event being processed, I
checked the current apm.c and I found that ignore_normal_resume was once
again being set too late.  I asked the submitter to move the line where
the flag was set and he reported that this change solved the problem.  I
append the message in question.  The line numbers I mention there are
for Linux 2.6.11.

Please make the indicated change to the apm driver.

-------- Forwarded Message --------
[email protected] wrote to the submitter of Debian bug #310865:
> In arch/i386/kernel/apm.c there is at approximately line 1229:
> 
>         ignore_normal_resume = 1;
> 
> Move this up so that it occurs right after line 1222:
> 
>         err = set_system_power_state(APM_STATE_SUSPEND);
> 
> Let us know if that helps.


It does. Very nice.
I don't understand what I did and how it works. Will you try to
push that into kernel sources or is this no permanent fix?
-- 
Thomas Hood <[email protected]>

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux