From pfeifer@sputnik1.dbai.tuwien.ac.at  Sun May  8 01:56:08 2011
Return-Path: <pfeifer@sputnik1.dbai.tuwien.ac.at>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 7C7521065670
	for <FreeBSD-gnats-submit@freebsd.org>; Sun,  8 May 2011 01:56:08 +0000 (UTC)
	(envelope-from pfeifer@sputnik1.dbai.tuwien.ac.at)
Received: from sputnik1.dbai.tuwien.ac.at (sputnik1.dbai.tuwien.ac.at [128.131.111.141])
	by mx1.freebsd.org (Postfix) with ESMTP id 106778FC0A
	for <FreeBSD-gnats-submit@freebsd.org>; Sun,  8 May 2011 01:56:07 +0000 (UTC)
Received: from sputnik1.dbai.tuwien.ac.at (localhost [127.0.0.1])
	by sputnik1.dbai.tuwien.ac.at (8.14.4/8.14.4) with ESMTP id p481W89X092038;
	Sun, 8 May 2011 03:32:08 +0200 (CEST)
	(envelope-from pfeifer@sputnik1.dbai.tuwien.ac.at)
Received: (from pfeifer@localhost)
	by sputnik1.dbai.tuwien.ac.at (8.14.4/8.14.4/Submit) id p481W7v2092037;
	Sun, 8 May 2011 03:32:07 +0200 (CEST)
	(envelope-from pfeifer)
Message-Id: <201105080132.p481W7v2092037@sputnik1.dbai.tuwien.ac.at>
Date: Sun, 8 May 2011 03:32:07 +0200 (CEST)
From: Gerald Pfeifer <gerald@pfeifer.com>
To: FreeBSD-gnats-submit@freebsd.org
Subject: OSS lacks SNDCTL_DSP_HALT
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         156874
>Category:       kern
>Synopsis:       [sound] [patch] OSS lacks SNDCTL_DSP_HALT
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    avg
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sun May 08 02:00:18 UTC 2011
>Closed-Date:    Fri Jul 29 22:14:24 UTC 2011
>Last-Modified:  Fri Jul 29 22:20:09 UTC 2011
>Originator:     Gerald Pfeifer
>Release:        FreeBSD 8.2-RELEASE i386
>Organization:
>Environment:
System: FreeBSD sputnik1.dbai.tuwien.ac.at 8.2-RELEASE FreeBSD 8.2-RELEASE #0: Fri Feb 18 02:24:46 UTC 2011 root@almeida.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386
>Description:
	When compiling current versions of Wine, I ran into the problem
	that FreeBSD does not feature SNDCTL_DSP_HALT in its OSS stack.

	The standard documentation at
	  http://manuals.opensound.com/developer/SNDCTL_DSP_HALT.html
	notes that
	  In the earlier OSS versions this ioctl call was called as
	  SNDCTL_DSP_RESET. This name is still valid but for clarity
	  reasons it is not recommended in new programs (designed for
	  OSS 4.0 or later). 

	Indeed FreeBSD features SNDCTL_DSP_RESET, so this should just
	be a matter of something like the patch below?

	(I'm a ports committer, not src, and cannot test/commit.)
>How-To-Repeat:
>Fix:

Submitted by: 	gerald

--- /usr/include/sys/soundcard.h	2011-04-17 18:48:28.000000000 +0200
+++ ./soundcard.h	2011-05-08 03:27:52.000000000 +0200
@@ -311,7 +311,8 @@
  * IOCTL Commands for /dev/sequencer
  */
 
-#define SNDCTL_SEQ_RESET	_IO  ('Q', 0)
+#define SNDCTL_SEQ_HALT		_IO  ('Q', 0)
+#define SNDCTL_SEQ_RESET	SNDCTL_SEQ_HALT    /* Historic interface */
 #define SNDCTL_SEQ_SYNC		_IO  ('Q', 1)
 #define SNDCTL_SYNTH_INFO	_IOWR('Q', 2, struct synth_info)
 #define SNDCTL_SEQ_CTRLRATE	_IOWR('Q', 3, int) /* Set/get timer res.(hz) */
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-multimedia 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Tue May 10 19:12:06 UTC 2011 
Responsible-Changed-Why:  
Over to maintainer(s). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=156874 

From: Andriy Gapon <avg@FreeBSD.org>
To: bug-followup@FreeBSD.org, gerald@pfeifer.com
Cc:  
Subject: Re: kern/156874: [sound] [patch] OSS lacks SNDCTL_DSP_HALT
Date: Wed, 11 May 2011 13:49:43 +0300

 The patch looks good to me.
 I think that I will commit it if nobody objects.
 
 Thanks!
 -- 
 Andriy Gapon

From: Gerald Pfeifer <gerald@pfeifer.com>
To: Andriy Gapon <avg@freebsd.org>
Cc: bug-followup@freebsd.org
Subject: Re: kern/156874: [sound] [patch] OSS lacks SNDCTL_DSP_HALT
Date: Sat, 4 Jun 2011 15:09:29 +0200 (CEST)

 On Wed, 11 May 2011, Andriy Gapon wrote:
 > The patch looks good to me.
 > I think that I will commit it if nobody objects.
 
 Thanks, Andriy.  I did not see any objections and am wondering whether
 you can commit this for FreeBSD 9.0 and the next 8.x release?
 
 Gerald

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: kern/156874: commit references a PR
Date: Sun,  5 Jun 2011 21:01:56 +0000 (UTC)

 Author: avg
 Date: Sun Jun  5 21:01:41 2011
 New Revision: 222723
 URL: http://svn.freebsd.org/changeset/base/222723
 
 Log:
   add SNDCTL_DSP_HALT specified by OSS
   
   This is really a new name for SNDCTL_DSP_RESET.
   
   PR:		kern/156874
   Submitted by:	gerald
   MFC after:	1 week
 
 Modified:
   head/sys/sys/soundcard.h
 
 Modified: head/sys/sys/soundcard.h
 ==============================================================================
 --- head/sys/sys/soundcard.h	Sun Jun  5 20:22:56 2011	(r222722)
 +++ head/sys/sys/soundcard.h	Sun Jun  5 21:01:41 2011	(r222723)
 @@ -311,7 +311,8 @@ typedef struct _snd_capabilities {
   * IOCTL Commands for /dev/sequencer
   */
  
 -#define SNDCTL_SEQ_RESET	_IO  ('Q', 0)
 +#define SNDCTL_SEQ_HALT		_IO  ('Q', 0)
 +#define SNDCTL_SEQ_RESET	SNDCTL_SEQ_HALT	/* Historic interface */
  #define SNDCTL_SEQ_SYNC		_IO  ('Q', 1)
  #define SNDCTL_SYNTH_INFO	_IOWR('Q', 2, struct synth_info)
  #define SNDCTL_SEQ_CTRLRATE	_IOWR('Q', 3, int) /* Set/get timer res.(hz) */
 _______________________________________________
 svn-src-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/svn-src-all
 To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
 

From: Andriy Gapon <avg@FreeBSD.org>
To: Gerald Pfeifer <gerald@pfeifer.com>
Cc: bug-followup@FreeBSD.org
Subject: Re: kern/156874: [sound] [patch] OSS lacks SNDCTL_DSP_HALT
Date: Mon, 06 Jun 2011 00:03:30 +0300

 on 04/06/2011 16:09 Gerald Pfeifer said the following:
 > On Wed, 11 May 2011, Andriy Gapon wrote:
 >> The patch looks good to me.
 >> I think that I will commit it if nobody objects.
 > 
 > Thanks, Andriy.  I did not see any objections and am wondering whether
 > you can commit this for FreeBSD 9.0 and the next 8.x release?
 
 
 Done, r222723 with MFC planned in ~ 1 week.
 Maybe __FreeBSD_version bump is needed for this?
 
 -- 
 Andriy Gapon

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: kern/156874: commit references a PR
Date: Wed, 29 Jun 2011 08:32:52 +0000 (UTC)

 Author: avg
 Date: Wed Jun 29 08:32:37 2011
 New Revision: 223663
 URL: http://svn.freebsd.org/changeset/base/223663
 
 Log:
   add SNDCTL_DSP_HALT specified by OSS
   
   This is really a new name for SNDCTL_DSP_RESET.
   And this what commit r222723 should really have been in the first place.
   
   PR:		kern/156874
   Submitted by:	gerald
   MFC after:	1 week
 
 Modified:
   head/sys/sys/soundcard.h
 
 Modified: head/sys/sys/soundcard.h
 ==============================================================================
 --- head/sys/sys/soundcard.h	Wed Jun 29 08:28:39 2011	(r223662)
 +++ head/sys/sys/soundcard.h	Wed Jun 29 08:32:37 2011	(r223663)
 @@ -775,7 +775,8 @@ typedef struct {
   * IOCTL commands for /dev/dsp and /dev/audio
   */
  
 -#define SNDCTL_DSP_RESET	_IO  ('P', 0)
 +#define SNDCTL_DSP_HALT		_IO  ('P', 0)
 +#define SNDCTL_DSP_RESET	SNDCTL_DSP_HALT
  #define SNDCTL_DSP_SYNC		_IO  ('P', 1)
  #define SNDCTL_DSP_SPEED	_IOWR('P', 2, int)
  #define SNDCTL_DSP_STEREO	_IOWR('P', 3, int)
 _______________________________________________
 svn-src-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/svn-src-all
 To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: kern/156874: commit references a PR
Date: Fri, 29 Jul 2011 22:00:51 +0000 (UTC)

 Author: avg
 Date: Fri Jul 29 22:00:32 2011
 New Revision: 224500
 URL: http://svn.freebsd.org/changeset/base/224500
 
 Log:
   MFC r223663: add SNDCTL_DSP_HALT specified by OSS
   
   PR:		kern/156874
 
 Modified:
   stable/8/sys/sys/soundcard.h
 Directory Properties:
   stable/8/sys/   (props changed)
   stable/8/sys/amd64/include/xen/   (props changed)
   stable/8/sys/cddl/contrib/opensolaris/   (props changed)
   stable/8/sys/contrib/dev/acpica/   (props changed)
   stable/8/sys/contrib/pf/   (props changed)
   stable/8/sys/geom/label/   (props changed)
 
 Modified: stable/8/sys/sys/soundcard.h
 ==============================================================================
 --- stable/8/sys/sys/soundcard.h	Fri Jul 29 20:38:06 2011	(r224499)
 +++ stable/8/sys/sys/soundcard.h	Fri Jul 29 22:00:32 2011	(r224500)
 @@ -775,7 +775,8 @@ typedef struct {
   * IOCTL commands for /dev/dsp and /dev/audio
   */
  
 -#define SNDCTL_DSP_RESET	_IO  ('P', 0)
 +#define SNDCTL_DSP_HALT		_IO  ('P', 0)
 +#define SNDCTL_DSP_RESET	SNDCTL_DSP_HALT
  #define SNDCTL_DSP_SYNC		_IO  ('P', 1)
  #define SNDCTL_DSP_SPEED	_IOWR('P', 2, int)
  #define SNDCTL_DSP_STEREO	_IOWR('P', 3, int)
 _______________________________________________
 svn-src-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/svn-src-all
 To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
 
State-Changed-From-To: open->closed 
State-Changed-By: avg 
State-Changed-When: Fri Jul 29 22:13:30 UTC 2011 
State-Changed-Why:  
The patch is committed. Take and resolve. 


Responsible-Changed-From-To: freebsd-multimedia->avg 
Responsible-Changed-By: avg 
Responsible-Changed-When: Fri Jul 29 22:13:30 UTC 2011 
Responsible-Changed-Why:  
The patch is committed. Take and resolve. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=156874 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: kern/156874: commit references a PR
Date: Fri, 29 Jul 2011 22:11:17 +0000 (UTC)

 Author: avg
 Date: Fri Jul 29 22:11:05 2011
 New Revision: 224501
 URL: http://svn.freebsd.org/changeset/base/224501
 
 Log:
   MFC r223663: add SNDCTL_DSP_HALT specified by OSS
   
   PR:		kern/156874
 
 Modified:
   stable/7/sys/sys/soundcard.h
 Directory Properties:
   stable/7/sys/   (props changed)
   stable/7/sys/cddl/contrib/opensolaris/   (props changed)
   stable/7/sys/contrib/dev/acpica/   (props changed)
   stable/7/sys/contrib/pf/   (props changed)
 
 Modified: stable/7/sys/sys/soundcard.h
 ==============================================================================
 --- stable/7/sys/sys/soundcard.h	Fri Jul 29 22:00:32 2011	(r224500)
 +++ stable/7/sys/sys/soundcard.h	Fri Jul 29 22:11:05 2011	(r224501)
 @@ -752,7 +752,8 @@ typedef struct {
   * IOCTL commands for /dev/dsp and /dev/audio
   */
  
 -#define SNDCTL_DSP_RESET	_IO  ('P', 0)
 +#define SNDCTL_DSP_HALT		_IO  ('P', 0)
 +#define SNDCTL_DSP_RESET	SNDCTL_DSP_HALT
  #define SNDCTL_DSP_SYNC		_IO  ('P', 1)
  #define SNDCTL_DSP_SPEED	_IOWR('P', 2, int)
  #define SNDCTL_DSP_STEREO	_IOWR('P', 3, int)
 _______________________________________________
 svn-src-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/svn-src-all
 To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
 
>Unformatted:
