From oberman@es.net  Wed Jul 12 17:02:49 2006
Return-Path: <oberman@es.net>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id DDA0816A4DE
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 12 Jul 2006 17:02:49 +0000 (UTC)
	(envelope-from oberman@es.net)
Received: from postal1.es.net (postal1.es.net [198.128.3.205])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 740AC43D49
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 12 Jul 2006 17:02:49 +0000 (GMT)
	(envelope-from oberman@es.net)
Received: from pak.es.net ([198.128.1.13])
        by postal1.es.net (Postal Node 1) with ESMTP (SSL) id IBA74465
        for <FreeBSD-gnats-submit@freebsd.org>; Wed, 12 Jul 2006 10:02:48 -0700
Received: by pak.es.net (Postfix, from userid 9381)
	id 81646273; Wed, 12 Jul 2006 10:02:48 -0700 (PDT)
Message-Id: <20060712170248.81646273@pak.es.net>
Date: Wed, 12 Jul 2006 10:02:48 -0700 (PDT)
From: Kevin Oberman <oberman@es.net>
Reply-To: Kevin Oberman <oberman@es.net>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: snd_ich broken on Dell PIII system
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         100169
>Category:       kern
>Synopsis:       [snd_ich] snd_ich broken on Dell PIII system
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    ariff
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Jul 12 17:10:15 GMT 2006
>Closed-Date:    Sun Nov 26 12:33:44 GMT 2006
>Last-Modified:  Mon May 28 21:10:04 GMT 2007
>Originator:     Kevin Oberman
>Release:        FreeBSD 7.0-CURRENT i386
>Organization:
ESnet-The Energy Sciences Network
>Environment:
System: FreeBSD pak.es.net 7.0-CURRENT FreeBSD 7.0-CURRENT #2: Thu Jun 29 11:29:46 PDT 2006 root@pak.es.net:/usr/obj/usr/src/sys/PAK i386

>Description:

Sometime between May and July the snd_ich driver failed on my Dell
system. Sound now is playing at the raw deivce rate instead of
48K. The raw rate is 56K, so sound it way too fast and simply broken
for playing streams as the buffer continually underruns.

Previously I could use a sysctl (hw.snd.ac97rate) to adjust this, but
now that defaults to the raw rate (56K) and setting it to 48K does not
seem to make any difference.

Here is the non-verbose probe information:
pcm0: <Intel ICH2 (82801BA)> port 0xd800-0xd8ff,0xdc40-0xdc7f irq 11 at device 31.5 on pci0
pcm0: <Analog Devices AD1885 AC97 Codec>
pcm0: measured ac97 link rate at 55948 Hz
	
>How-To-Repeat:

Play any audio on the system
>Fix:

No idea at this time, but I am still looking at the sources and the
changes for a clue. 
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-multimedia 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Wed Jul 12 18:42:04 UTC 2006 
Responsible-Changed-Why:  
Over to maintainer(s). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=100169 
Responsible-Changed-From-To: freebsd-multimedia->ariff 
Responsible-Changed-By: ariff 
Responsible-Changed-When: Sat Nov 11 02:53:28 UTC 2006 
Responsible-Changed-Why:  
Take it (with a little doubt that this has anything to do with the driver). 

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

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: kern/100169: commit references a PR
Date: Sun, 26 Nov 2006 12:24:37 +0000 (UTC)

 ariff       2006-11-26 12:24:06 UTC
 
   FreeBSD src repository
 
   Modified files:
     sys/sys              param.h 
     .                    UPDATING 
     sys/dev/sound/pci    atiixp.c cmi.c es137x.c ich.c via8233.c 
     sys/dev/sound/pci/hda hda_reg.h hdac.c hdac_private.h 
     sys/dev/sound/pcm    ac97.c ac97.h buffer.c buffer.h channel.c 
                          channel.h dsp.c fake.c feeder.c feeder.h 
                          feeder_fmt.c feeder_rate.c 
                          feeder_volume.c mixer.c sndstat.c sound.c 
                          sound.h vchan.c 
     sys/dev/sound/usb    uaudio.c 
   Log:
   Welcome to Once-a-year Sound Mega-Commit. Enjoy numerous updates and fixes
   in every sense.
   
   General
   -------
   
   - Multichannel safe, endian safe, format safe
      * Large part of critical pcm filters such as vchan.c, feeder_rate.c,
        feeder_volume.c, feeder_fmt.c and feeder.c has been rewritten so that
        using them does not cause the pcm data to be converted to 16bit little
        endian.
      * Macrosses for accessing pcm data safely are defined within sound.h in
        the form of PCM_READ_* / PCM_WRITE_*
      * Currently, most of them are probably limited for mono/stereo handling,
        but the future addition of true multichannel will be much easier.
   
   - Low latency operation
     * Well, this require lot more works to do not just within sound driver,
       but we're heading towards right direction. Buffer/block sizing within
       channel.c is rewritten to calculate precise allocation for various
       combination of sample/data/rate size. As a result, applying correct
       SNDCTL_DSP_POLICY value will achive expected latency behaviour simmilar
       to what commercial 4front driver do.
     * Signal handling fix. ctrl+c of "cat /dev/zero > /dev/dsp" does not
       result long delay.
     * Eliminate sound truncation if the sound data is too small.
       DIY:
         1) Download / extract
            http://people.freebsd.org/~ariff/lowlatency/shortfiles.tar.gz
         2) Do a comparison between "cat state*.au > /dev/dsp" and
            "for x in state*.au ; do cat $x > /dev/dsp ; done"
            - there should be no "perceivable" differences.
       Double close for PR kern/31445.
   
     CAVEAT: Low latency come with (unbearable) price especially for poorly
             written applications. Applications that trying to act smarter
             by requesting (wrong) blocksize/blockcount will suffer the most.
             Fixup samples/patches can be found at:
             http://people.freebsd.org/~ariff/ports/
   
   - Switch minimum/maximum sampling rate limit to "1" and "2016000" (48k * 42)
     due to closer compatibility with 4front driver.
     Discussed with: marcus@ (long time ago?)
   
   - All driver specific sysctls in the form of "hw.snd.pcm%d.*" have been
     moved to their own dev sysctl nodes, notably:
     hw.snd.pcm%d.vchans -> dev.pcm.%d.vchans
     Bump __FreeBSD_version.
   
   Driver specific
   ---------------
   
   - Ditto for sysctls.
   
   - snd_atiixp, snd_es137x, snd_via8233, snd_hda
     * Numerous cleanups and fixes.
     * _EXPERIMENTAL_ polling mode support using simple callout_* mechanisme.
      This was intended for pure debugging and latency measurement, but proven
      good enough in few unexpected and rare cases (such as problematic shared
      IRQ with GIANT devices - USB). Polling can be enabled/disabled through
      dev.pcm.0.polling. Disabled by default.
   
   - snd_ich
     * Fix possible overflow during speed calibration. Delay final
       initialization (pcm_setstatus) after calibration finished.
       PR: kern/100169
       Tested by: Kevin Overman <oberman@es.net>
     * Inverted EAPD for few Nec VersaPro.
       PR: kern/104715
       Submitted by: KAWATA Masahiko <kawata@mta.biglobe.ne.jp>
   
   Thanks to various people, notably Joel Dahl, Yuriy Tsibizov, Kevin Oberman,
   those at #freebsd-azalia @ freenode and others for testing.
   
   Joel Dahl will do the manpage update.
   
   Revision  Changes    Path
   1.466     +13 -0     src/UPDATING
   1.8       +354 -196  src/sys/dev/sound/pci/atiixp.c
   1.38      +3 -3      src/sys/dev/sound/pci/cmi.c
   1.61      +622 -371  src/sys/dev/sound/pci/es137x.c
   1.2       +24 -24    src/sys/dev/sound/pci/hda/hda_reg.h
   1.9       +456 -171  src/sys/dev/sound/pci/hda/hdac.c
   1.3       +10 -1     src/sys/dev/sound/pci/hda/hdac_private.h
   1.68      +228 -103  src/sys/dev/sound/pci/ich.c
   1.26      +558 -275  src/sys/dev/sound/pci/via8233.c
   1.64      +86 -18    src/sys/dev/sound/pcm/ac97.c
   1.19      +0 -2      src/sys/dev/sound/pcm/ac97.h
   1.29      +60 -26    src/sys/dev/sound/pcm/buffer.c
   1.13      +3 -0      src/sys/dev/sound/pcm/buffer.h
   1.112     +721 -311  src/sys/dev/sound/pcm/channel.c
   1.34      +39 -1     src/sys/dev/sound/pcm/channel.h
   1.100     +16 -17    src/sys/dev/sound/pcm/dsp.c
   1.17      +2 -1      src/sys/dev/sound/pcm/fake.c
   1.38      +452 -134  src/sys/dev/sound/pcm/feeder.c
   1.14      +26 -3     src/sys/dev/sound/pcm/feeder.h
   1.21      +623 -203  src/sys/dev/sound/pcm/feeder_fmt.c
   1.19      +320 -546  src/sys/dev/sound/pcm/feeder_rate.c
   1.3       +178 -33   src/sys/dev/sound/pcm/feeder_volume.c
   1.56      +5 -3      src/sys/dev/sound/pcm/mixer.c
   1.23      +11 -10    src/sys/dev/sound/pcm/sndstat.c
   1.107     +40 -48    src/sys/dev/sound/pcm/sound.c
   1.73      +280 -7    src/sys/dev/sound/pcm/sound.h
   1.26      +458 -131  src/sys/dev/sound/pcm/vchan.c
   1.23      +1 -1      src/sys/dev/sound/usb/uaudio.c
   1.280     +1 -1      src/sys/sys/param.h
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 
State-Changed-From-To: open->closed 
State-Changed-By: ariff 
State-Changed-When: Sun Nov 26 12:32:46 UTC 2006 
State-Changed-Why:  
Fix committed. Does not affect other branches. 

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

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: kern/100169: commit references a PR
Date: Mon, 28 May 2007 21:07:48 +0000 (UTC)

 ariff       2007-05-28 21:07:41 UTC
 
   FreeBSD src repository
 
   Modified files:        (Branch: RELENG_6)
     sys/dev/sound/pci    ich.c 
   Log:
   MFC (revision 1.75)
   
   * Fix possible integer overflow during speed calibration. Delay final
     initialization (pcm_setstatus) after calibration finished.
   
   PR:             kern/100169
   Tested by:      Kevin Overman <oberman@es.net>
   
   * Fix (or rather workaround) Intel 440MX Errata #36
     - http://www.intel.com/design/chipsets/specupdt/245051.htm
   
   AC97 Soft Audio and Soft Modem Master Abort Errata
   
   Issue:
     Use of either soft audio or soft modem on an Intel 82443MX PCISet
     based platform running a 100 MHz Processor System Bus and an AC97 codec
     may result in failures. The system continues to function normally while
     the AC97 hardware may not resume and may require a cold-boot to
     recover. As a result of the failure, the Master Abort Status bit will
     be set in the audio or modem function PCI header space.
   
   Workaround:
     Force uncacheable DMA on both BDL and pcm buffers.
   
   Tested by:      Emil Holmstr|m <emil@linux.se>
   
   Revision   Changes    Path
   1.53.2.11  +339 -126  src/sys/dev/sound/pci/ich.c
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 
>Unformatted:
