plm> In contract, if I suspend in Linux of Windows, the computer shuts up
plm> immediateley and is quiet. Only sometimes there is a (not too loud)
plm> little fan (I think it is the CPU fan) running for a few more minutes.

I've read Linux code (v2.2.9) closely, noticed they put cli 
before APM BIOS call and save & restore segment registers.
I suspect these two (or only cli?) affect the suspending state.
To clarify, could you try attached patches (for sys/i386/i386/bioscall.s) 
one by one?

# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#       bioscall-1
#       bioscall-2
#       bioscall-3
#
echo x - bioscall-1
sed 's/^X//' >bioscall-1 << 'END-of-bioscall-1'
X--- i386/i386/bioscall.s.org   Mon Aug  9 17:51:31 1999
X+++ i386/i386/bioscall.s       Mon Aug  9 17:53:07 1999
X@@ -64,9 +64,16 @@
X       movl    12(%ebp),%edx
X       movl    16(%ebp),%esi
X       movl    20(%ebp),%edi
X+#if 1 /* cli hack */
X+      pushfl
X+      cli
X+#endif
X       pushl   %ebp
X       lcall   _bioscall_vector
X       popl    %ebp
X+#if 1 /* cli hack */
X+      popfl
X+#endif
X       movl    %eax,0(%ebp)
X       movl    %ebx,4(%ebp)
X       movl    %ecx,8(%ebp)
END-of-bioscall-1
echo x - bioscall-2
sed 's/^X//' >bioscall-2 << 'END-of-bioscall-2'
X--- i386/i386/bioscall.s.org   Mon Aug  9 17:51:31 1999
X+++ i386/i386/bioscall.s       Mon Aug  9 18:01:36 1999
X@@ -64,9 +64,17 @@
X       movl    12(%ebp),%edx
X       movl    16(%ebp),%esi
X       movl    20(%ebp),%edi
X+#if 1 /* segment regs hack */
X+      pushl   %fs
X+      pushl   %gs
X+#endif
X       pushl   %ebp
X       lcall   _bioscall_vector
X       popl    %ebp
X+#if 1 /* segment regs hack */
X+      popl    %gs
X+      popl    %fs
X+#endif
X       movl    %eax,0(%ebp)
X       movl    %ebx,4(%ebp)
X       movl    %ecx,8(%ebp)
END-of-bioscall-2
echo x - bioscall-3
sed 's/^X//' >bioscall-3 << 'END-of-bioscall-3'
X--- i386/i386/bioscall.s.org   Mon Aug  9 17:51:31 1999
X+++ i386/i386/bioscall.s       Mon Aug  9 18:00:07 1999
X@@ -64,9 +64,20 @@
X       movl    12(%ebp),%edx
X       movl    16(%ebp),%esi
X       movl    20(%ebp),%edi
X+#if 1 /* cli + segment regs hack */
X+      pushfl
X+      cli
X+      pushl   %fs
X+      pushl   %gs
X+#endif
X       pushl   %ebp
X       lcall   _bioscall_vector
X       popl    %ebp
X+#if 1 /* cli + segment regs hack */
X+      popl    %gs
X+      popl    %fs
X+      popfl
X+#endif
X       movl    %eax,0(%ebp)
X       movl    %ebx,4(%ebp)
X       movl    %ecx,8(%ebp)
END-of-bioscall-3
exit



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to