NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: kern/52175: audio sometimes stutters



The following reply was made to PR kern/52175; it has been noted by GNATS.

From: Manuel Bouyer <bouyer%antioche.eu.org@localhost>
To: gnats-bugs%netbsd.org@localhost
Cc: kern-bug-people%netbsd.org@localhost, gnats-admin%netbsd.org@localhost, netbsd-bugs%netbsd.org@localhost
Subject: Re: kern/52175: audio sometimes stutters
Date: Wed, 26 Apr 2017 12:03:36 +0200

 On Tue, Apr 25, 2017 at 10:17:35PM +0200, Manuel Bouyer wrote:
 > [...]
 > Also, playing a sound from opencpn (which uses portaudio2, which uses
 > ossaudio). It hangs. ktrace shows what looks like an endless loop writing
 > the same 64k data block again and again (the file itself is less than 128KB,
 > but larger files shows the same behavior), at a very low rate.
 > I don't hear anything on output but maybe that's because the file
 > is played at a very low rate.
 
 Here is what I see with AUDIO_DEBUG=1 when opencpn opens the device to
 play the file (the file is:
 RIFF (little-endian) data, WAVE audio, Microsoft PCM, 16 bit, mono 22050 Hz
 )
 
 audio_open: flags=0x6 sc=0xbfaef808 hdl=0xbfd54688
 audio_initbufs: mode=0x5
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audiosetinfo sc=0xbfaef808 ai=0xbd1c5b20
 audiosetinfo p rate 8000 p encoding 1 p precision 8 p channels 1 np 4
 audiosetinfo() Setting record params: enc=1 1ch 8/8bit 8000Hz
 audiosetinfo() Setting play params: enc=1 1ch 8/8bit 8000Hz
 audio_setup_pfilters: HW-buffer=0xbf86e1d4 pustream=0xbf86e034
 [0] enc=1 1ch 8/8bit 8000Hz
 [1] enc=6 1ch 16/16bit 8000Hz
 [HW] enc=6 2ch 16/16bit 48000Hz
 audio_setup_rfilters: HW-buffer=0xbf86e238 pustream=0xbf86e2e4
 [HW] enc=6 2ch 16/16bit 48000Hz
 [0] enc=6 1ch 16/16bit 8000Hz
 [1] enc=1 1ch 8/8bit 8000Hz
 audiosetinfo: filter setup is completed.
 audio_calc_blksize: record blksize=9600
 audio_calc_blksize: play blksize=9600
 audio_initbufs: mode=0x5
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_calcwater: plow=49152 phigh=65536 rlow=0 rhigh=55936
 audiostartp: start=0xc0f94000 used=0(hi=65536 blk=9600) mmapped=0
 audiostartp: wakeup and return
 audio_calcwater: plow=49152 phigh=65536 rlow=0 rhigh=55936
 audio_open: done sc_mode = 0x5
 audio_ioctl(4,'f',126)
 audio_ioctl(4,'f',126) result 0
 audio_ioctl(32,'A',28)
 AUDIO_GETENC
 audio_ioctl(32,'A',28) result 0
 audio_ioctl(32,'A',28)
 AUDIO_GETENC
 audio_ioctl(32,'A',28) result 0
 audio_ioctl(32,'A',28)
 AUDIO_GETENC
 audio_ioctl(32,'A',28) result 0
 audio_ioctl(32,'A',28)
 AUDIO_GETENC
 audio_ioctl(32,'A',28) result 0
 audio_ioctl(32,'A',28)
 AUDIO_GETENC
 audio_ioctl(32,'A',28) result 0
 audio_ioctl(32,'A',28)
 AUDIO_GETENC
 audio_ioctl(32,'A',28) result 0
 audio_ioctl(32,'A',28)
 AUDIO_GETENC
 audio_ioctl(32,'A',28) result 22
 audio_ioctl(136,'A',22)
 AUDIO_SETINFO mode=0x5
 audiosetinfo sc=0xbfaef808 ai=0xba310838
 audiosetinfo np 0
 audio_ioctl(136,'A',22) result 0
 audio_ioctl(136,'A',35)
 AUDIO_GETBUFINFO
 audio_ioctl(136,'A',35) result 0
 audio_ioctl(136,'A',22)
 AUDIO_SETINFO mode=0x5
 audiosetinfo sc=0xbfaef808 ai=0xba310838
 audiosetinfo p encoding 6 p precision 16 np 2
 audiosetinfo() Setting record params: enc=6 1ch 16/16bit 8000Hz
 audiosetinfo() Setting play params: enc=6 1ch 16/16bit 8000Hz
 audio_setup_pfilters: HW-buffer=0xbf86e1d4 pustream=0xbf86e034
 [0] enc=6 1ch 16/16bit 8000Hz
 [HW] enc=6 2ch 16/16bit 48000Hz
 audio_setup_rfilters: HW-buffer=0xbf86e238 pustream=0xbf86e2b4
 [HW] enc=6 2ch 16/16bit 48000Hz
 [0] enc=6 1ch 16/16bit 8000Hz
 audiosetinfo: filter setup is completed.
 audio_calc_blksize: record blksize=9600
 audio_calc_blksize: play blksize=9600
 audio_initbufs: mode=0x5
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_calcwater: plow=49152 phigh=65536 rlow=0 rhigh=55936
 audio_ioctl(136,'A',22) result 0
 audio_ioctl(136,'A',35)
 AUDIO_GETBUFINFO
 audio_ioctl(136,'A',35) result 0
 audio_ioctl(136,'A',22)
 AUDIO_SETINFO mode=0x5
 audiosetinfo sc=0xbfaef808 ai=0xba310838
 audiosetinfo p channels 1 np 1
 audiosetinfo() Setting play params: enc=6 1ch 16/16bit 8000Hz
 audio_setup_pfilters: HW-buffer=0xbf86e1d4 pustream=0xbf86e034
 [0] enc=6 1ch 16/16bit 8000Hz
 [HW] enc=6 2ch 16/16bit 48000Hz
 audiosetinfo: filter setup is completed.
 audio_calc_blksize: record blksize=9600
 audio_calc_blksize: play blksize=9600
 audio_initbufs: mode=0x5
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_ioctl(136,'A',22) result 0
 audio_ioctl(136,'A',22)
 AUDIO_SETINFO mode=0x5
 audiosetinfo sc=0xbfaef808 ai=0xba310838
 audiosetinfo np 0
 audiosetinfo() Setting record params: enc=6 1ch 16/16bit 8000Hz
 audio_setup_rfilters: HW-buffer=0xbf86e238 pustream=0xbf86e2b4
 [HW] enc=6 2ch 16/16bit 48000Hz
 [0] enc=6 1ch 16/16bit 8000Hz
 audiosetinfo: filter setup is completed.
 audio_calc_blksize: record blksize=9600
 audio_calc_blksize: play blksize=9600
 audio_initbufs: mode=0x5
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_ioctl(136,'A',22) result 0
 audio_ioctl(136,'A',35)
 AUDIO_GETBUFINFO
 audio_ioctl(136,'A',35) result 0
 audio_ioctl(136,'A',22)
 AUDIO_SETINFO mode=0x5
 audiosetinfo sc=0xbfaef808 ai=0xba310838
 audiosetinfo p rate 22050 np 1
 audiosetinfo() Setting record params: enc=6 1ch 16/16bit 22050Hz
 audiosetinfo() Setting play params: enc=6 1ch 16/16bit 22050Hz
 audio_setup_pfilters: HW-buffer=0xbf86e1d4 pustream=0xbf86e034
 [0] enc=6 1ch 16/16bit 22050Hz
 [HW] enc=6 2ch 16/16bit 48000Hz
 audio_setup_rfilters: HW-buffer=0xbf86e238 pustream=0xbf86e2b4
 [HW] enc=6 2ch 16/16bit 48000Hz
 [0] enc=6 1ch 16/16bit 22050Hz
 audiosetinfo: filter setup is completed.
 audio_calc_blksize: record blksize=9600
 audio_calc_blksize: play blksize=9600
 audio_initbufs: mode=0x5
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_init_ringbuffer: MI blksize=9600
 audio_init_ringbuffer: final blksize=9600
 audio_ioctl(136,'A',22) result 0
 audio_ioctl(136,'A',35)
 AUDIO_GETBUFINFO
 audio_ioctl(136,'A',35) result 0
 audio_ioctl(136,'A',35)
 AUDIO_GETBUFINFO
 audio_ioctl(136,'A',35) result 0
 audio_ioctl(136,'A',22)
 AUDIO_SETINFO mode=0x5
 audiosetinfo sc=0xbfaef808 ai=0xba310838
 audiosetinfo np 0
 audio_ioctl(136,'A',22) result 0
 audio_ioctl(136,'A',35)
 AUDIO_GETBUFINFO
 audio_ioctl(136,'A',35) result 0
 audio_ioctl(136,'A',35)
 AUDIO_GETBUFINFO
 audio_ioctl(136,'A',35) result 0
 audio_ioctl(136,'A',22)
 AUDIO_SETINFO mode=0x5
 audiosetinfo sc=0xbfaef808 ai=0xba310838
 audiosetinfo np 0
 audio_ioctl(136,'A',22) result 0
 audio_ioctl(136,'A',35)
 AUDIO_GETBUFINFO
 audio_ioctl(136,'A',35) result 0
 audio_ioctl(4,'f',126)
 audio_ioctl(4,'f',126) result 0
 audiostartp: start=0xc0f94000 used=19200(hi=65536 blk=9600) mmapped=0
 mix_write: call trigger_output
 
 -- 
 Manuel Bouyer <bouyer%antioche.eu.org@localhost>
      NetBSD: 26 ans d'experience feront toujours la difference
 --
 


Home | Main Index | Thread Index | Old Index