From mboxrd@z Thu Jan 1 00:00:00 1970 From: Clemens Ladisch Subject: Re: Audio Driver Works In Ubuntu but Crash in Debian After 2nd Run Date: Fri, 19 Jun 2015 10:01:02 +0200 Message-ID: <5583CC3E.1090601@ladisch.de> References: <557FD536.3020906@ladisch.de> <55812940.5050906@ladisch.de> <1434531934.2471.9.camel@loki> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from dehamd003.servertools24.de (dehamd003.servertools24.de [31.47.254.18]) by alsa0.perex.cz (Postfix) with ESMTP id B20CB26053B for ; Fri, 19 Jun 2015 10:01:06 +0200 (CEST) In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org To: Azizul Hakim , Liam Girdwood Cc: Peter Ujfalusi , alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org Azizul Hakim wrote: > So when a audio playback starts I initialize the buffer pointer to "0" > in the *.prepare* function. This is correct. > https://gist.github.com/azizulhakim/d24a36ef753f9a1536fa > https://gist.github.com/azizulhakim/b15b002f74e77f88cd5a This is not; the code confuses bytes and frames. When in doubt, give _all_ variables a "_bytes" or "_frames" suffix, and check that _every_ access uses the correct units. Regards, Clemens