From patchwork Thu Sep 13 13:37:58 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Ujfalusi X-Patchwork-Id: 1452111 Return-Path: X-Original-To: patchwork-linux-omap@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 95E883FE79 for ; Thu, 13 Sep 2012 13:38:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755164Ab2IMNiQ (ORCPT ); Thu, 13 Sep 2012 09:38:16 -0400 Received: from na3sys009aog101.obsmtp.com ([74.125.149.67]:34650 "EHLO na3sys009aog101.obsmtp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754696Ab2IMNiG (ORCPT ); Thu, 13 Sep 2012 09:38:06 -0400 Received: from mail-ob0-f174.google.com ([209.85.214.174]) (using TLSv1) by na3sys009aob101.postini.com ([74.125.148.12]) with SMTP ID DSNKUFHhvmW1LXZ4XQmDSfSKCc+DCchc7bSR@postini.com; Thu, 13 Sep 2012 06:38:06 PDT Received: by obbuo13 with SMTP id uo13so4469199obb.19 for ; Thu, 13 Sep 2012 06:38:05 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=ed9sZMvA/WSB1qQd0OPezHJ+czcdk8+yLTKIF9N3rWI=; b=WpP0FMpzfzdhQh7E6GhPkIReY7NOEeyInBvx8ZEq8dP/g3DW9h4wMyZSXjk6y/iN65 eAeC3/38oIiONA57qTLfosX4BnJcO4SVrppqKpaT3eITtpsOkZMqMvNIas2afDNnAybq ez8EbzJGroiC+z+irzD7yMBfppzpZuC5OSz2geYljO2TWGxw54B9rferkGaWMZSad1wV KRItOjru3EhPhSG162X1T5yCnDkfNW2HjOQxI3ALjg49NicRGsrlBN8BqSZdzFnSPDuc YkdcmvzXTnRb4Z5wZhxYpGMlE0RMjUB+TCh1Om3GgCxvt/AWPfQmMspu4PbIz8jClXxE 187A== Received: by 10.182.207.6 with SMTP id ls6mr2265996obc.36.1347543485701; Thu, 13 Sep 2012 06:38:05 -0700 (PDT) Received: from barack.emea.dhcp.ti.com (dragon.ti.com. [192.94.94.33]) by mx.google.com with ESMTPS id n8sm19403567oec.5.2012.09.13.06.38.02 (version=SSLv3 cipher=OTHER); Thu, 13 Sep 2012 06:38:05 -0700 (PDT) From: Peter Ujfalusi To: Mark Brown , Liam Girdwood , Tony Lindgren , Russell King , Vinod Koul , Dan Williams , Jarkko Nikula Cc: alsa-devel@alsa-project.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Janusz Krzysztofik , Ricardo Neri , Lars-Peter Clausen Subject: [PATCH v2 08/15] ASoC: OMAP: Remove sync_mode from omap_pcm_dma_data struct Date: Thu, 13 Sep 2012 16:37:58 +0300 Message-Id: <1347543485-339-9-git-send-email-peter.ujfalusi@ti.com> X-Mailer: git-send-email 1.7.12 In-Reply-To: <1347543485-339-1-git-send-email-peter.ujfalusi@ti.com> References: <1347543485-339-1-git-send-email-peter.ujfalusi@ti.com> X-Gm-Message-State: ALoCoQkxXKJ44UamrSw7cYkSNMAt2IFq3jpuGRNrXysfENyiDkeVixSPdIzKWyVY4lmGYmp6vype Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org The omap-pcm platform driver no longer needs this parameter to select between ELEMENT and PACKET mode. The selection is based on the configured packet_size. Signed-off-by: Peter Ujfalusi --- sound/soc/omap/omap-dmic.c | 1 - sound/soc/omap/omap-hdmi.c | 1 - sound/soc/omap/omap-mcbsp.c | 5 +---- sound/soc/omap/omap-mcpdm.c | 2 -- sound/soc/omap/omap-pcm.h | 1 - 5 files changed, 1 insertion(+), 9 deletions(-) diff --git a/sound/soc/omap/omap-dmic.c b/sound/soc/omap/omap-dmic.c index 75f5dca..60b7b8c 100644 --- a/sound/soc/omap/omap-dmic.c +++ b/sound/soc/omap/omap-dmic.c @@ -64,7 +64,6 @@ struct omap_dmic { static struct omap_pcm_dma_data omap_dmic_dai_dma_params = { .name = "DMIC capture", .data_type = OMAP_DMA_DATA_TYPE_S32, - .sync_mode = OMAP_DMA_SYNC_PACKET, }; static inline void omap_dmic_write(struct omap_dmic *dmic, u16 reg, u32 val) diff --git a/sound/soc/omap/omap-hdmi.c b/sound/soc/omap/omap-hdmi.c index a08245d..b194646 100644 --- a/sound/soc/omap/omap-hdmi.c +++ b/sound/soc/omap/omap-hdmi.c @@ -290,7 +290,6 @@ static __devinit int omap_hdmi_probe(struct platform_device *pdev) hdmi_data->dma_params.dma_req = hdmi_rsrc->start; hdmi_data->dma_params.name = "HDMI playback"; - hdmi_data->dma_params.sync_mode = OMAP_DMA_SYNC_PACKET; /* * TODO: We assume that there is only one DSS HDMI device. Future diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c index fe3debc..5b3bacc 100644 --- a/sound/soc/omap/omap-mcbsp.c +++ b/sound/soc/omap/omap-mcbsp.c @@ -225,7 +225,7 @@ static int omap_mcbsp_dai_hw_params(struct snd_pcm_substream *substream, struct omap_mcbsp *mcbsp = snd_soc_dai_get_drvdata(cpu_dai); struct omap_mcbsp_reg_cfg *regs = &mcbsp->cfg_regs; struct omap_pcm_dma_data *dma_data; - int wlen, channels, wpf, sync_mode = OMAP_DMA_SYNC_ELEMENT; + int wlen, channels, wpf; int pkt_size = 0; unsigned int format, div, framesize, master; @@ -272,15 +272,12 @@ static int omap_mcbsp_dai_hw_params(struct snd_pcm_substream *substream, return -EINVAL; pkt_size = period_words / divider; - sync_mode = OMAP_DMA_SYNC_PACKET; } else if (channels > 1) { /* Use packet mode for non mono streams */ pkt_size = channels; - sync_mode = OMAP_DMA_SYNC_PACKET; } } - dma_data->sync_mode = sync_mode; dma_data->packet_size = pkt_size; snd_soc_dai_set_dma_data(cpu_dai, substream, dma_data); diff --git a/sound/soc/omap/omap-mcpdm.c b/sound/soc/omap/omap-mcpdm.c index f7babb3..baf92da 100644 --- a/sound/soc/omap/omap-mcpdm.c +++ b/sound/soc/omap/omap-mcpdm.c @@ -73,14 +73,12 @@ static struct omap_pcm_dma_data omap_mcpdm_dai_dma_params[] = { .name = "Audio playback", .dma_req = OMAP44XX_DMA_MCPDM_DL, .data_type = OMAP_DMA_DATA_TYPE_S32, - .sync_mode = OMAP_DMA_SYNC_PACKET, .port_addr = OMAP44XX_MCPDM_L3_BASE + MCPDM_REG_DN_DATA, }, { .name = "Audio capture", .dma_req = OMAP44XX_DMA_MCPDM_UP, .data_type = OMAP_DMA_DATA_TYPE_S32, - .sync_mode = OMAP_DMA_SYNC_PACKET, .port_addr = OMAP44XX_MCPDM_L3_BASE + MCPDM_REG_UP_DATA, }, }; diff --git a/sound/soc/omap/omap-pcm.h b/sound/soc/omap/omap-pcm.h index b92248c..1bf47e4 100644 --- a/sound/soc/omap/omap-pcm.h +++ b/sound/soc/omap/omap-pcm.h @@ -33,7 +33,6 @@ struct omap_pcm_dma_data { unsigned long port_addr; /* transmit/receive register */ void (*set_threshold)(struct snd_pcm_substream *substream); int data_type; /* data type 8,16,32 */ - int sync_mode; /* DMA sync mode */ int packet_size; /* packet size only in PACKET mode */ };