From owner-freebsd-current Mon Aug 9 7:34:11 1999 Delivered-To: freebsd-current@freebsd.org Received: from tasogare.imasy.or.jp (tasogare.imasy.or.jp [202.227.24.5]) by hub.freebsd.org (Postfix) with ESMTP id 9D5AF151EE for ; Mon, 9 Aug 1999 07:34:03 -0700 (PDT) (envelope-from iwasaki@jp.FreeBSD.org) Received: from localhost (isdn41.imasy.or.jp [202.227.24.233]) by tasogare.imasy.or.jp (8.9.3+3.2W/3.7W-tasogare/smtpfeed 1.01) with ESMTP id XAA01774; Mon, 9 Aug 1999 23:31:26 +0900 (JST) (envelope-from iwasaki@jp.FreeBSD.org) Message-Id: <199908091431.XAA01774@tasogare.imasy.or.jp> To: plm@xs4all.nl Cc: iwasaki@jp.FreeBSD.org, freebsd-current@FreeBSD.ORG, imp@village.org Subject: Re: recent apm changes In-Reply-To: Your message of "Sun, 8 Aug 1999 21:52:32 +0200 (CEST)" <14253.57344.873947.122158@muon.xs4all.nl> References: <14253.57344.873947.122158@muon.xs4all.nl> X-Mailer: Mew version 1.93 on Emacs 19.34 / Mule 2.3 (SUETSUMUHANA) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Mon, 09 Aug 1999 23:35:12 +0900 From: Mitsuru IWASAKI X-Dispatcher: imput version 980905(IM100) Lines: 94 Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG 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 majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message