Date: Sun, 10 Apr 2016 18:13:12 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 208678] Sound: analogue audio output on Raspberry pi Message-ID: <bug-208678-8@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D208678 Bug ID: 208678 Summary: Sound: analogue audio output on Raspberry pi Product: Base System Version: 11.0-CURRENT Hardware: arm OS: Any Status: New Severity: Affects Only Me Priority: --- Component: kern Assignee: freebsd-bugs@FreeBSD.org Reporter: sylvain@sylvaingarrigues.com The first point of this bug is a continuous flow of warnings when using sys= ctl hw.snd.verbose=3D4 and playing sound (see "how to reproduce" below). The second point is that since February, a new firmware option (audio_pwm_mode=3D2) has been added which greatly improves the analogue aud= io output: https://www.raspberrypi.org/forums/viewtopic.php?f=3D29&t=3D136445 With this option, there is almost no more white noise on analogue output, making the RPI2 great again for music listening. Except that there are small distortions in the sound and I believe they are related to our kernel driver anyway (related to first point?) as=20 1/ there are no distortions when using omxplayer to play the sound in userl= and 2/ I have no such problem using NetBSD. I looked at the difference in the driver and they do some prefilling before playing and have a bigger VCHIQ a= udio buffer size and send more audio messages at once if I am correct. How to reproduce: # pkg install mpg123 # sysctl hw.snd.verbose=3D4 # fetch http://www.noiseaddicts.com/samples_1w72b820/4190.mp3=20=20=20=20=20 # mpg123 4190.mp3 =3D=3D> sound is distorted with audio_pwm_mode=3D2, it is= not without this option, but in both cases I have LOTS of warnings in dmesg Check dmesg: =E2=80=A6. pcm0: WARNING: PCMDIR_PLAY DMA completion too fast/slow ! hwptr=3D124000, old=3D124000 delta=3D0 amt=3D0 ready=3D8192 free=3D119808 pcm0: WARNING: PCMDIR_PLAY DMA completion too fast/slow ! hwptr=3D0, old=3D0 delta=3D0 amt=3D0 ready=3D8192 free=3D119808 pcm0: WARNING: PCMDIR_PLAY DMA completion too fast/slow ! hwptr=3D0, old=3D0 delta=3D0 amt=3D0 ready=3D8192 free=3D119808 pcm0: WARNING: PCMDIR_PLAY DMA completion too fast/slow ! hwptr=3D4000, old= =3D4000 delta=3D0 amt=3D0 ready=3D8192 free=3D119808 pcm0: WARNING: PCMDIR_PLAY DMA completion too fast/slow ! hwptr=3D8000, old= =3D8000 delta=3D0 amt=3D0 ready=3D8192 free=3D119808 pcm0: WARNING: PCMDIR_PLAY DMA completion too fast/slow ! hwptr=3D12000, old=3D12000 delta=3D0 amt=3D0 ready=3D8192 free=3D119808 pcm0: WARNING: PCMDIR_PLAY DMA completion too fast/slow ! hwptr=3D16000, old=3D16000 delta=3D0 amt=3D0 ready=3D8192 free=3D119808 pcm0: WARNING: PCMDIR_PLAY DMA completion too fast/slow ! hwptr=3D20000, old=3D20000 delta=3D0 amt=3D0 ready=3D8192 free=3D119808 pcm0: WARNING: PCMDIR_PLAY DMA completion too fast/slow ! hwptr=3D24000, old=3D24000 delta=3D0 amt=3D0 ready=3D8192 free=3D119808 feed_root: (virtual) appending 3128 bytes (count=3D3364 l=3D236 feed=3D480) pcm0: chn_sync(): timeout=3D4 count=3D51 hcount=3D51 resid=3D0 residp=3D0 m= inflush=3D0 ret=3D0 pcm0: WARNING: PCMDIR_PLAY DMA completion too fast/slow ! hwptr=3D28000, old=3D28000 delta=3D0 amt=3D0 ready=3D8192 free=3D119808 pcm0: chn_trigger() pcm0:play:dsp0.p0: calling go=3D0xffffffff , prev=3D0x0= 0000001 pcm0: chn_trigger() pcm0:virtual:dsp0.vp0: calling go=3D0xffffffff , prev=3D0x00000001 pcm0: chn_resizebuf(): PCMDIR_PLAY (hardware) timeout=3D4 b[128000/4000/2] bs[8192/4096/2] limit=3D0 pcm0: chn_resizebuf(): PCMDIR_PLAY (virtual) timeout=3D4 b[0/0/0] bs[65536/2048/32] limit=3D7526 --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-208678-8>