From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751611AbcKIGHM (ORCPT ); Wed, 9 Nov 2016 01:07:12 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:53682 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750803AbcKIGHJ (ORCPT ); Wed, 9 Nov 2016 01:07:09 -0500 DMARC-Filter: OpenDMARC Filter v1.3.1 smtp.codeaurora.org 8491B6124D Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=pass smtp.mailfrom=kwestfie@codeaurora.org Date: Tue, 8 Nov 2016 22:06:43 -0800 From: Kenneth Westfield To: Arnd Bergmann Cc: Mark Brown , Patrick Lai , Banajit Goswami , Liam Girdwood , Srinivas Kandagatla , Kenneth Westfield , alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] ASoC: lpass-platform: initialize dma channel number Message-ID: <20161109060642.GA1486@kwestfie-linux.qualcomm.com> Mail-Followup-To: Arnd Bergmann , Mark Brown , Patrick Lai , Banajit Goswami , Liam Girdwood , Srinivas Kandagatla , alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org References: <20161108133916.1742379-1-arnd@arndb.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20161108133916.1742379-1-arnd@arndb.de> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 08, 2016 at 02:38:52PM +0100, Arnd Bergmann wrote: > A bugfix accidentally removed the implicit initialization of the > dma channel number, causing undefined behavior when > v->alloc_dma_channel is NULL: > > sound/soc/qcom/lpass-platform.c: In function ‘lpass_platform_pcmops_open’: > sound/soc/qcom/lpass-platform.c:83:29: error: ‘dma_ch’ may be used uninitialized in this function [-Werror=maybe-uninitialized] > > This adds back an explicit initialization to zero, restoring the > previous behavior for that case. > > Fixes: 022d00ee0b55 ("ASoC: lpass-platform: Fix broken pcm data usage") > Signed-off-by: Arnd Bergmann > --- > sound/soc/qcom/lpass-platform.c | 3 +++ > 1 file changed, 3 insertions(+) Good catch. Acked-by: Kenneth Westfield -- Kenneth Westfield Qualcomm Innovation Center, Inc. The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project