From patchwork Wed Sep 26 10:23:48 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinivas Kandagatla X-Patchwork-Id: 147561 Delivered-To: patch@linaro.org Received: by 2002:a2e:8595:0:0:0:0:0 with SMTP id b21-v6csp532626lji; Wed, 26 Sep 2018 03:26:08 -0700 (PDT) X-Google-Smtp-Source: ACcGV62BKrjr9hqnwfZMumE1TPwLIDmL7GjaAGMns2IDVAUzb2vVX0oYgeZFR/+kuuvs0kgokTqX X-Received: by 2002:a63:7a50:: with SMTP id j16-v6mr5133033pgn.112.1537957568276; Wed, 26 Sep 2018 03:26:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537957568; cv=none; d=google.com; s=arc-20160816; b=pd0N5T5ZpDt9sG9OVv0p03V1fnTCumMeSF0jojEkE9YfZilNgsvNXTIXUt0xWlIAbG gKvLq2k/fdeWZ3ZAKMRquYn3kNHPH2ikCqMh1ivNLBLpT4rSpClIQo8HxSwN5i9cDB4y QberqEEnX0/bJ14nRRcX+SOTj+GEz6odWbuFCg5yOqacfAw9sFbAZKsJtsdJC0TBTJmZ AdNJjwet7SCvHF18qHvIcxpIAikfHSKd5UCvkQHP9d9zcmtzIoPJ2wDpPq31akLd0WcV 5pDWdknXi2npP8NgLGLvcGG8VtV+ZwAqcnQx3qXfgnSM8aVtvE6dPnNtUiHEVRADdx9F cVMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=mFjadR6BsgPuHP9WgDqWOULIM9tP8Tkl7i3Z5EXFShQ=; b=Uk4jXKTLCUF9Fx2qtjydHqHXGBxYxprP3eG+etgRxa1w+o7nJ/bW7jwOz5rue0k/ud BFbzKc5Qo+mLk4F1JHcUUCAUYfBiZtb66XyP/YAZt5ej8cL37xRIp1IZgBOE/0QOdHtP ho8UTgnayMmCEgvpAAP/p/cWf0Y4uF40/xFBakrelQKwL1x0UjHbd/FSuPSULp59gkR9 UEUtRXmbLu8EjIZ4rS56QPlwk9vwEepvirRpQHNIFj1XGiiBNTU20KN9qCpFgh1QWvU1 iJpnpCilpriEF29nBgGW6WPj1Exshv/4X4u42uCroq3gQDUnE8pFYS1xJ80JG94Ab54D /lqQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=e43z3rL+; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i64-v6si4676298pfb.314.2018.09.26.03.26.08; Wed, 26 Sep 2018 03:26:08 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=e43z3rL+; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727872AbeIZQiU (ORCPT + 32 others); Wed, 26 Sep 2018 12:38:20 -0400 Received: from mail-wm1-f51.google.com ([209.85.128.51]:50670 "EHLO mail-wm1-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726802AbeIZQiS (ORCPT ); Wed, 26 Sep 2018 12:38:18 -0400 Received: by mail-wm1-f51.google.com with SMTP id s12-v6so1694585wmc.0 for ; Wed, 26 Sep 2018 03:26:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=mFjadR6BsgPuHP9WgDqWOULIM9tP8Tkl7i3Z5EXFShQ=; b=e43z3rL+N5vhsGt0DCWQU4wbwdPS3YiL15rftgl0WqdWQ6JhQ5M2yXnkEQjVWJAo6k Bqbl6LZFST3bp6Fpyqilvo3qgkEq750tnHG+YlRhOWhQ9j38U3bgkiAPA6vdfNYjGuSy m5eDVL2999XW8PtmVJ4N4VTOsQ2HoHRwOqUaE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=mFjadR6BsgPuHP9WgDqWOULIM9tP8Tkl7i3Z5EXFShQ=; b=OiOiLSzEl23MkEsNxmmZkje3FByaEOkLNsuRvAaRD8q8upz5z4zVyUdqj88C+HemcS yVkYoU5ZSpcKo5K8vG5TXtHyB++J6S7Q9oaGhhMiNIUDwfGs10x9zGDEspgVbw4GBr0R 5VNyPpIt95AmhCReExgO0XgiyWualfJfyb9rr5TMGeDX57farWKV72Tc9McvgyARXTrX nwCwfeyYwRi4r7BL+4wU38L00LWDfK1pJosvnt2e4UbRt/OuXHku7EWkZ19NQyO9S0xh qnUoupxVZYYv4CHbWn1zWBoc2IRGjhOOKaVxuziik5HsGaxXHNRJDZMM2ihzH9dycvNx h7kw== X-Gm-Message-State: ABuFfoi0Qo81vpMt2O0H7O0pDOPId2yc/vNrypd0EyJhE1esO3jIcAvE iHSbVbY8dQJuej2iRjJPSbSmiTQOOw4= X-Received: by 2002:a1c:89cd:: with SMTP id l196-v6mr3757018wmd.7.1537957560789; Wed, 26 Sep 2018 03:26:00 -0700 (PDT) Received: from localhost.localdomain (cpc90716-aztw32-2-0-cust92.18-1.cable.virginm.net. [86.26.100.93]) by smtp.gmail.com with ESMTPSA id b12sm4442648wrx.11.2018.09.26.03.25.59 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 26 Sep 2018 03:26:00 -0700 (PDT) From: Srinivas Kandagatla To: broonie@kernel.org, alsa-devel@alsa-project.org, robh+dt@kernel.org Cc: linux-kernel@vger.kernel.org, vkoul@kernel.org, bgoswami@codeaurora.org, rohitkr@codeaurora.org, lgirdwood@gmail.com, tiwai@suse.com, devicetree@vger.kernel.org, mark.rutland@arm.com, Srinivas Kandagatla Subject: [PATCH v2 4/5] ASoC: qdsp6: q6asm: add support to MP3 format Date: Wed, 26 Sep 2018 11:23:48 +0100 Message-Id: <20180926102349.23481-5-srinivas.kandagatla@linaro.org> X-Mailer: git-send-email 2.19.0 In-Reply-To: <20180926102349.23481-1-srinivas.kandagatla@linaro.org> References: <20180926102349.23481-1-srinivas.kandagatla@linaro.org> MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Signed-off-by: Srinivas Kandagatla --- sound/soc/qcom/qdsp6/q6asm.c | 5 +++++ 1 file changed, 5 insertions(+) -- 2.19.0 diff --git a/sound/soc/qcom/qdsp6/q6asm.c b/sound/soc/qcom/qdsp6/q6asm.c index 2b2c7233bb5f..e98aee1baadd 100644 --- a/sound/soc/qcom/qdsp6/q6asm.c +++ b/sound/soc/qcom/qdsp6/q6asm.c @@ -13,6 +13,7 @@ #include #include #include +#include #include #include #include @@ -37,6 +38,7 @@ #define ASM_PARAM_ID_ENCDEC_ENC_CFG_BLK_V2 0x00010DA3 #define ASM_SESSION_CMD_RUN_V2 0x00010DAA #define ASM_MEDIA_FMT_MULTI_CHANNEL_PCM_V2 0x00010DA5 +#define ASM_MEDIA_FMT_MP3 0x00010BE9 #define ASM_DATA_CMD_WRITE_V2 0x00010DAB #define ASM_DATA_CMD_READ_V2 0x00010DAC #define ASM_SESSION_CMD_SUSPEND 0x00010DEC @@ -869,6 +871,9 @@ int q6asm_open_write(struct audio_client *ac, uint32_t format, open->postprocopo_id = ASM_NULL_POPP_TOPOLOGY; switch (format) { + case SND_AUDIOCODEC_MP3: + open->dec_fmt_id = ASM_MEDIA_FMT_MP3; + break; case FORMAT_LINEAR_PCM: open->dec_fmt_id = ASM_MEDIA_FMT_MULTI_CHANNEL_PCM_V2; break;