From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=49490 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PZtNS-0002It-Bg for qemu-devel@nongnu.org; Mon, 03 Jan 2011 17:59:47 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PZtNQ-0008ME-JU for qemu-devel@nongnu.org; Mon, 03 Jan 2011 17:59:46 -0500 Received: from mail.serverraum.org ([78.47.150.89]:42216) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PZtNQ-0008Ls-C6 for qemu-devel@nongnu.org; Mon, 03 Jan 2011 17:59:44 -0500 From: Michael Walle Subject: Re: [Qemu-devel] [PATCH] noaudio: use audio_pcm_sw_read() in no_read() Date: Mon, 3 Jan 2011 23:59:41 +0100 References: <1294094404-20397-1-git-send-email-michael@walle.cc> In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201101032359.41230.michael@walle.cc> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: malc Cc: qemu-devel@nongnu.org On Mon, 3 Jan 2011, 23:46:34 malc wrote: > On Mon, 3 Jan 2011, Michael Walle wrote: > > Instead of returning a self-calculated empty buffer use the proper method > > supplied by the audio subsystem. This will fix the return value of the > > no_read() function which otherwise returns too many samples because > > total_hw_samples_acquired isn't correctly accounted. > > What and how is incorrectly accounted? FWIW the audio_pcm_sw_read will > perform useless resampling/mixing that's why custom code is used. total_hw_samples_acquired is never incremented (see audio_pcm_sw_read()). As a result the noaudio driver returns too many bytes per second. -- Michael