From patchwork Thu Apr 30 17:17:32 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinivas Kandagatla X-Patchwork-Id: 47866 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f200.google.com (mail-wi0-f200.google.com [209.85.212.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 9784E20553 for ; Thu, 30 Apr 2015 17:17:58 +0000 (UTC) Received: by wiun10 with SMTP id n10sf6671867wiu.1 for ; Thu, 30 Apr 2015 10:17:57 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=BDKahagKnOa9r3akGxC8iK786/quHzlY4TnJ1GPRhlU=; b=QPFtxppa1n6E/dRnKvDx7JQ3D9ziKYj2TWPmnH4SUBgSoWdFHUgXPdhX0SVT0PiDoL rxJIqgs/2wh2RDFcv8/q2Fy+XPTrI+MsljLPcwkX1MvQLAw+Q+lFVEMSUiuLD8YPR9gs MS3SwW9Ewxfuvxqd5hx6EDXjAWJCAs6gh6QhnuTHuTrhXopzizEU0giaikqaTqmEzGju fa7p6GVOGrVyQ3qhRnSr75dc/Cb984iZbLQoJU95c5pgtKSwsy2Xl9VJat2kRkpZG2fP g6uMv34RiVDrQLi81dm767WLo7h061EkzbSHnFGxUxu3fwCjonptBwqVvhhVSp1PAxq5 VIVQ== X-Gm-Message-State: ALoCoQlOhUo1Gtg2cA1layRf87cL7/WzvM9sDDw3vzA8WTabZJHbGSmo0i8UmZNUiUHnrOpsn4v7 X-Received: by 10.112.118.162 with SMTP id kn2mr3170111lbb.22.1430414277911; Thu, 30 Apr 2015 10:17:57 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.178.195 with SMTP id da3ls418022lac.43.gmail; Thu, 30 Apr 2015 10:17:57 -0700 (PDT) X-Received: by 10.152.5.134 with SMTP id s6mr4096361las.99.1430414277757; Thu, 30 Apr 2015 10:17:57 -0700 (PDT) Received: from mail-la0-f46.google.com (mail-la0-f46.google.com. [209.85.215.46]) by mx.google.com with ESMTPS id dk9si2178104lad.162.2015.04.30.10.17.57 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 30 Apr 2015 10:17:57 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.46 as permitted sender) client-ip=209.85.215.46; Received: by labbd9 with SMTP id bd9so49491834lab.2 for ; Thu, 30 Apr 2015 10:17:57 -0700 (PDT) X-Received: by 10.152.36.2 with SMTP id m2mr4766934laj.72.1430414277444; Thu, 30 Apr 2015 10:17:57 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.67.65 with SMTP id l1csp3242903lbt; Thu, 30 Apr 2015 10:17:56 -0700 (PDT) X-Received: by 10.66.63.41 with SMTP id d9mr8022994pas.47.1430414275740; Thu, 30 Apr 2015 10:17:55 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id gv7si4340696pac.201.2015.04.30.10.17.54; Thu, 30 Apr 2015 10:17:55 -0700 (PDT) Received-SPF: none (google.com: linux-arm-msm-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752044AbbD3RRm (ORCPT + 5 others); Thu, 30 Apr 2015 13:17:42 -0400 Received: from mail-wg0-f41.google.com ([74.125.82.41]:36502 "EHLO mail-wg0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752511AbbD3RRh (ORCPT ); Thu, 30 Apr 2015 13:17:37 -0400 Received: by wgen6 with SMTP id n6so69759632wge.3 for ; Thu, 30 Apr 2015 10:17:36 -0700 (PDT) X-Received: by 10.194.248.132 with SMTP id ym4mr10894678wjc.74.1430414256483; Thu, 30 Apr 2015 10:17:36 -0700 (PDT) Received: from srini-ThinkPad-X1-Carbon-2nd.dlink.com (host-2-98-219-188.as13285.net. [2.98.219.188]) by mx.google.com with ESMTPSA id qt2sm4176554wjc.7.2015.04.30.10.17.34 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 30 Apr 2015 10:17:35 -0700 (PDT) From: Srinivas Kandagatla To: Patrick Lai , Mark Brown Cc: Rob Herring , Pawel Moll , Ian Campbell , Kumar Gala , Banajit Goswami , Kenneth Westfield , Liam Girdwood , Jaroslav Kysela , Takashi Iwai , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org, linux-arm-msm@vger.kernel.org, Srinivas Kandagatla Subject: [RFC PATCH 08/14] ASoC: qcom: add dma channel control offset to variant data Date: Thu, 30 Apr 2015 18:17:32 +0100 Message-Id: <1430414252-11210-1-git-send-email-srinivas.kandagatla@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1430414148-10869-1-git-send-email-srinivas.kandagatla@linaro.org> References: <1430414148-10869-1-git-send-email-srinivas.kandagatla@linaro.org> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: srinivas.kandagatla@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.46 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , This patch adds ability to pass dma channel control bits start offset, which differ in differnet qcom SOCs. On apq8016 dma channel control bits start after an offset of 1. Signed-off-by: Srinivas Kandagatla --- sound/soc/qcom/lpass-platform.c | 2 +- sound/soc/qcom/lpass.h | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/sound/soc/qcom/lpass-platform.c b/sound/soc/qcom/lpass-platform.c index fc08891..8ab0ac1 100644 --- a/sound/soc/qcom/lpass-platform.c +++ b/sound/soc/qcom/lpass-platform.c @@ -91,7 +91,7 @@ static int lpass_platform_pcmops_hw_params(struct snd_pcm_substream *substream, unsigned int channels = params_channels(params); unsigned int regval; int bitwidth; - int ret, rdma_port = pcm_data->i2s_port; + int ret, rdma_port = pcm_data->i2s_port + v->rdmactl_audif_start; bitwidth = snd_pcm_format_width(format); if (bitwidth < 0) { diff --git a/sound/soc/qcom/lpass.h b/sound/soc/qcom/lpass.h index 301f784..e07ed52 100644 --- a/sound/soc/qcom/lpass.h +++ b/sound/soc/qcom/lpass.h @@ -61,6 +61,12 @@ struct lpass_variant { u32 rdma_reg_stride; u32 rdma_channels; + /** + * on SOCs like APQ8016 the channel control bits start + * at different offset to ipq806x + **/ + u32 rdmactl_audif_start; + /* OCR clock is not present in SOCs like APQ8016 */ bool no_osr_clk; /* SOC specific intialization like clocks */