Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp5641575ybv; Tue, 11 Feb 2020 20:36:24 -0800 (PST) X-Google-Smtp-Source: APXvYqzJF3oOGwxMoy869PI57I+fvUcnDbI+fXWYzYgmSIs2DToII19flJDWsNcePOeMD+Pr/oD5 X-Received: by 2002:a9d:5786:: with SMTP id q6mr7539436oth.164.1581482184540; Tue, 11 Feb 2020 20:36:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581482184; cv=none; d=google.com; s=arc-20160816; b=OjKmdlV1ylAClYOiwUVtvK2zSGeLtb4jkgJM1INb2bIua+QOIy9KYKT6IguVQZX+KF qxWSKWfJpv5TvIsl9UMvOm2uImnZB45y527sIRquKn319212g3vxXjMnyFy3i5VuuiVY HHAKqftV4Fko0NGliHlpMUE5NLMrHEhNAt52oIyRZXCiAcDgHLhd77uTN12eT4dPcY35 YRHhqOiHhw54k/uA/iZlXSUkEQ8vpN0Uo35wYFG/6Cwwky1tWb7bGmdFfDbaOItpvTji nLat1Y8lZxb8HWsGP/iVWVb6SB4ri5BVJkgbRhMBzcrvbrOSsviRP83JrtLutAcP3df5 +zng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from; bh=go90j01wpjVRyBBWCGDewXW5411kBNBEoi+DaOOcrm8=; b=P9H5nbjTXtMveXPsMIYgAuqoqYopMY1cOYaB5uctC4uoiL638aW/fvEUO8qhpLGwTZ 1Zr0ORsjevs7ywwO8XQRDsRtHtMjnfuUfNPfLSIML/XLrWaYshSTq/fRzMVdb10SkRB1 DWLtrYOikwfXilIN4Vsi+7iTJjCbrIGF7zRBcUDFyG/xphvdBZfU7A8VYokj0ZiLv4c6 AznOTNteMyCcV7F6K5hMaQC27VYfKnAYO4vwxzHb9hQCay2tRhmLKeEtEVTLy/WvbwGP Nv6PStKOluu14kQgGTbFGQyDa6p3YvzVoXAqDT9jHYEXzYMJNP2kbcNVvasmg1+Xg3SX wrSg== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j9si2780699oiw.133.2020.02.11.20.36.12; Tue, 11 Feb 2020 20:36:24 -0800 (PST) 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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728100AbgBLEfq (ORCPT + 99 others); Tue, 11 Feb 2020 23:35:46 -0500 Received: from inva021.nxp.com ([92.121.34.21]:37988 "EHLO inva021.nxp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727918AbgBLEfp (ORCPT ); Tue, 11 Feb 2020 23:35:45 -0500 Received: from inva021.nxp.com (localhost [127.0.0.1]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 2AE5F2256C7; Wed, 12 Feb 2020 05:35:43 +0100 (CET) Received: from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com [165.114.16.14]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 1027E2256CC; Wed, 12 Feb 2020 05:35:36 +0100 (CET) Received: from localhost.localdomain (shlinux2.ap.freescale.net [10.192.224.44]) by invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id 6787C402B7; Wed, 12 Feb 2020 12:35:27 +0800 (SGT) From: Shengjiu Wang To: timur@kernel.org, nicoleotsuka@gmail.com, Xiubo.Lee@gmail.com, festevam@gmail.com, broonie@kernel.org, alsa-devel@alsa-project.org, lgirdwood@gmail.com, perex@perex.cz, tiwai@suse.com, robh+dt@kernel.org, mark.rutland@arm.com, devicetree@vger.kernel.org Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/3] ASoC: fsl_asrc: Move common definition to fsl_asrc_common Date: Wed, 12 Feb 2020 12:30:01 +0800 Message-Id: <916c5542c7248ee3dc9ebe5324b80beb2af9d1fa.1581475981.git.shengjiu.wang@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: References: In-Reply-To: References: X-Virus-Scanned: ClamAV using ClamSMTP Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org There is a new ASRC included in i.MX serial platform, there are some common definition can be shared with each other. So move the common definition to a separate header file. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_asrc.h | 11 +---------- sound/soc/fsl/fsl_asrc_common.h | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+), 10 deletions(-) create mode 100644 sound/soc/fsl/fsl_asrc_common.h diff --git a/sound/soc/fsl/fsl_asrc.h b/sound/soc/fsl/fsl_asrc.h index 8a821132d9d0..e8abb27ffeda 100644 --- a/sound/soc/fsl/fsl_asrc.h +++ b/sound/soc/fsl/fsl_asrc.h @@ -10,8 +10,7 @@ #ifndef _FSL_ASRC_H #define _FSL_ASRC_H -#define IN 0 -#define OUT 1 +#include "fsl_asrc_common.h" #define ASRC_DMA_BUFFER_NUM 2 #define ASRC_INPUTFIFO_THRESHOLD 32 @@ -283,14 +282,6 @@ #define ASRMCR1i_OW16_MASK (1 << ASRMCR1i_OW16_SHIFT) #define ASRMCR1i_OW16(v) ((v) << ASRMCR1i_OW16_SHIFT) - -enum asrc_pair_index { - ASRC_INVALID_PAIR = -1, - ASRC_PAIR_A = 0, - ASRC_PAIR_B = 1, - ASRC_PAIR_C = 2, -}; - #define ASRC_PAIR_MAX_NUM (ASRC_PAIR_C + 1) enum asrc_inclk { diff --git a/sound/soc/fsl/fsl_asrc_common.h b/sound/soc/fsl/fsl_asrc_common.h new file mode 100644 index 000000000000..8acc55778ff2 --- /dev/null +++ b/sound/soc/fsl/fsl_asrc_common.h @@ -0,0 +1,21 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* + * Copyright 2019 NXP + * + */ + +#ifndef _FSL_ASRC_COMMON_H +#define _FSL_ASRC_COMMON_H + +/* directions */ +#define IN 0 +#define OUT 1 + +enum asrc_pair_index { + ASRC_INVALID_PAIR = -1, + ASRC_PAIR_A = 0, + ASRC_PAIR_B = 1, + ASRC_PAIR_C = 2, +}; + +#endif /* _FSL_ASRC_COMMON_H */ -- 2.21.0