From nobody@FreeBSD.org  Wed Feb 28 17:42:07 2001
Return-Path: <nobody@FreeBSD.org>
Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21])
	by hub.freebsd.org (Postfix) with ESMTP id A38F837B71B
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 28 Feb 2001 17:42:06 -0800 (PST)
	(envelope-from nobody@FreeBSD.org)
Received: (from nobody@localhost)
	by freefall.freebsd.org (8.11.1/8.11.1) id f211g6e65638;
	Wed, 28 Feb 2001 17:42:06 -0800 (PST)
	(envelope-from nobody)
Message-Id: <200103010142.f211g6e65638@freefall.freebsd.org>
Date: Wed, 28 Feb 2001 17:42:06 -0800 (PST)
From: davidx@viasoft.com.cn
To: freebsd-gnats-submit@FreeBSD.org
Subject: wrong code in /sys/i386/isa/asc.c
X-Send-Pr-Version: www-1.0

>Number:         25465
>Category:       i386
>Synopsis:       wrong code in /sys/i386/isa/asc.c
>Confidential:   no
>Severity:       critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Feb 28 17:50:00 PST 2001
>Closed-Date:    Wed Feb 28 19:22:52 PST 2001
>Last-Modified:  Wed Feb 28 19:23:05 PST 2001
>Originator:     David Xu
>Release:        FreeBSD 4.2-stable
>Organization:
viasoft
>Environment:
FreeBSD davidbsd.viasoft.com.cn 4.2-STABLE FreeBSD 4.2-STABLE #8: Wed Feb 28 13:
26:35 CST 2001     root@davidbsd.viasoft.com.cn:/usr/src/sys/compile/xu  i386
>Description:
I hope I don't misunderstand author's code, 
in file /sys/i386/isa/asc.c, the function 
STATIC int ascpoll(dev_t dev, int events, struct proc *p)
always return 0. I think it is wrong, it never returns a true poll 
event mask.


>How-To-Repeat:

>Fix:
following is a patch.

--- asc.c.orig  Thu Mar  1 09:34:46 2001
+++ asc.c   Thu Mar  1 09:35:01 2001
@@ -874,5 +874,5 @@
    }
     }
     splx(sps);
-    return 0;
+    return revents;
 }

>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: jlemon 
State-Changed-When: Wed Feb 28 19:22:52 PST 2001 
State-Changed-Why:  
Fix applied, thanks. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=25465 
>Unformatted:
