From nobody@FreeBSD.org  Sun Jun 30 04:37:39 2002
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id AC66337B405
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 30 Jun 2002 04:37:39 -0700 (PDT)
Received: from www.freebsd.org (www.FreeBSD.org [216.136.204.117])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 5590243E13
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 30 Jun 2002 04:37:39 -0700 (PDT)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.12.4/8.12.4) with ESMTP id g5UBbXOT054472
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 30 Jun 2002 04:37:33 -0700 (PDT)
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.12.4/8.12.4/Submit) id g5UBbX2D054471;
	Sun, 30 Jun 2002 04:37:33 -0700 (PDT)
Message-Id: <200206301137.g5UBbX2D054471@www.freebsd.org>
Date: Sun, 30 Jun 2002 04:37:33 -0700 (PDT)
From: Christian Mller <smoki@irrenhaus.org>
To: freebsd-gnats-submit@FreeBSD.org
Subject: AD1816A need a fix!
X-Send-Pr-Version: www-1.0

>Number:         40034
>Category:       kern
>Synopsis:       AD1816A need a fix!
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Jun 30 04:40:01 PDT 2002
>Closed-Date:    Sun Jul 07 04:51:14 PDT 2002
>Last-Modified:  Sun Jul 07 04:51:14 PDT 2002
>Originator:     Christian Mller
>Release:        FreeBSD 4.6
>Organization:
>Environment:
FreeBSD twain.franken.de 4.6-RELEASE FreeBSD 4.6-RELEASE #7: Sun Jun 30 12:38:41 CEST 2002     root@twain.franken.de:/usr/src/sys/compile/SMOKI  i386
>Description:
The Soundcard AD1816A will be detected correctly, but i can not play any sound. The System gives me "/dev/dsp is busy"
>How-To-Repeat:
Install a AD1816A and play music.
>Fix:
static int ad1816chan_setformat(kobj_t obj, void *data, u_int32_t format)

Should return 0 and not the format, becouse the other soundcards return 0 too.

Here the patch:

twain# pwd
/usr/src/sys/dev/sound/isa
twain# diff -crN ad1816.c.orig ad1816.c
*** ad1816.c.orig	Sun Jun 30 13:29:29 2002
--- ad1816.c	Sun Jun 30 12:15:53 2002
***************
*** 373,379 ****
      	if (format & AFMT_STEREO) fmt |= AD1816_STEREO;
      	io_wr(ad1816, reg, fmt);
  	ad1816_unlock(ad1816);
!     	return format;
  }
  
  static int
--- 373,380 ----
      	if (format & AFMT_STEREO) fmt |= AD1816_STEREO;
      	io_wr(ad1816, reg, fmt);
  	ad1816_unlock(ad1816);
!     	return 0;
!     	/* return format; */
  }
  
  static int



>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: robert 
State-Changed-When: Sun Jul 7 04:50:32 PDT 2002 
State-Changed-Why:  
A fix was commited to -stable.  Thank you for reporting 
the bug! 

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