From patchwork Wed Jul 22 22:42:05 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shuah Khan X-Patchwork-Id: 6847641 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id AEE89C05AC for ; Wed, 22 Jul 2015 22:43:21 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id C8B90200F2 for ; Wed, 22 Jul 2015 22:43:20 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 736822047B for ; Wed, 22 Jul 2015 22:43:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752921AbbGVWm4 (ORCPT ); Wed, 22 Jul 2015 18:42:56 -0400 Received: from resqmta-po-11v.sys.comcast.net ([96.114.154.170]:57667 "EHLO resqmta-po-11v.sys.comcast.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752439AbbGVWmk (ORCPT ); Wed, 22 Jul 2015 18:42:40 -0400 Received: from resomta-po-18v.sys.comcast.net ([96.114.154.242]) by resqmta-po-11v.sys.comcast.net with comcast id vaig1q0035E3ZMc01aigaV; Wed, 22 Jul 2015 22:42:40 +0000 Received: from mail.gonehiking.org ([73.181.52.62]) by resomta-po-18v.sys.comcast.net with comcast id vaid1q00T1LXgTt01aieMq; Wed, 22 Jul 2015 22:42:39 +0000 Received: from lorien.internal (lorien-wl.internal [192.168.1.40]) by mail.gonehiking.org (Postfix) with ESMTP id 67218120445; Wed, 22 Jul 2015 16:42:37 -0600 (MDT) From: Shuah Khan To: mchehab@osg.samsung.com, hans.verkuil@cisco.com, laurent.pinchart@ideasonboard.com, tiwai@suse.de, sakari.ailus@linux.intel.com, perex@perex.cz, crope@iki.fi, arnd@arndb.de, stefanr@s5r6.in-berlin.de, ruchandani.tina@gmail.com, chehabrafael@gmail.com, dan.carpenter@oracle.com, prabhakar.csengg@gmail.com, chris.j.arges@canonical.com, agoode@google.com, pierre-louis.bossart@linux.intel.com, gtmkramer@xs4all.nl, clemens@ladisch.de, daniel@zonque.org, vladcatoi@gmail.com, misterpib@gmail.com, damien@zamaudio.com, pmatilai@laiskiainen.org, takamichiho@gmail.com, normalperson@yhbt.net, bugzilla.frnkcg@spamgourmet.com, joe@oampo.co.uk, calcprogrammer1@gmail.com, jussi@sonarnerd.net, kyungmin.park@samsung.com, s.nawrocki@samsung.com, kgene@kernel.org, hyun.kwon@xilinx.com, michal.simek@xilinx.com, soren.brinkmann@xilinx.com, pawel@osciak.com, m.szyprowski@samsung.com, gregkh@linuxfoundation.org, skd08@gmail.com, nsekhar@ti.com, boris.brezillon@free-electrons.com, Julia.Lawall@lip6.fr, elfring@users.sourceforge.net, p.zabel@pengutronix.de, ricardo.ribalda@gmail.com Cc: Shuah Khan , linux-media@vger.kernel.org, alsa-devel@alsa-project.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devel@driverdev.osuosl.org Subject: [PATCH v2 04/19] media: au8522 change to create MC pad for ALSA Audio Out Date: Wed, 22 Jul 2015 16:42:05 -0600 Message-Id: <7d2f03591bcd3e9bfd5ebad865b0055a61c8027e.1437599281.git.shuahkh@osg.samsung.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: References: In-Reply-To: References: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20140121; t=1437604960; bh=eghX9/GT7sjPSg0aHfl1K/mMwGBZAv5HMdqoHcpyp6I=; h=Received:Received:Received:From:To:Subject:Date:Message-Id; b=r2W7x3QXSElxyIdykIn4PoHusQNVihYCgMlmfG11TIW+O/7vlCLMk9ffOd+9Tm0kp b3TVP4IlFaIp9QDi78/lwfDWgaaL+7yP7OIMrstVV4XzINbcUUbOriRPQdKLyUWdXd 0ZFk2/5iIIBcjVp7VAT6/pkaYE3lwP432bic4BNZC1iUfnzU1iugWS7RcZipoLZw2y sLsA+7POCObTIoKAbJ+ymtUXWMWKHVQ/3KGOB3+jwojSnVD1tRHK1U10hLfR1HUfcb C+Rwry+C1c2yDvOyFUQZ45fAhdt42Ijodfv5ZKR18BM+74vDRHQPij3JuFlF3MKfvz CO/rYXgipw01Q== Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Spam-Status: No, score=-8.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add new pad for ALSA Audio Out to au8522_media_pads. Move the au8522_media_pads enum to au8522.h from au8522_priv.h. This will allow au0828-core to use these defines instead of hard-coding the pad values when it creates media graph linking decode pads to other entities. Signed-off-by: Shuah Khan --- drivers/media/dvb-frontends/au8522.h | 8 ++++++++ drivers/media/dvb-frontends/au8522_decoder.c | 1 + drivers/media/dvb-frontends/au8522_priv.h | 8 -------- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/drivers/media/dvb-frontends/au8522.h b/drivers/media/dvb-frontends/au8522.h index dde6158..d7a997f 100644 --- a/drivers/media/dvb-frontends/au8522.h +++ b/drivers/media/dvb-frontends/au8522.h @@ -90,4 +90,12 @@ enum au8522_audio_input { AU8522_AUDIO_SIF, }; +enum au8522_media_pads { + AU8522_PAD_INPUT, + AU8522_PAD_VID_OUT, + AU8522_PAD_VBI_OUT, + AU8522_PAD_AUDIO_OUT, + + AU8522_NUM_PADS +}; #endif /* __AU8522_H__ */ diff --git a/drivers/media/dvb-frontends/au8522_decoder.c b/drivers/media/dvb-frontends/au8522_decoder.c index 24990db..01d8fe7 100644 --- a/drivers/media/dvb-frontends/au8522_decoder.c +++ b/drivers/media/dvb-frontends/au8522_decoder.c @@ -775,6 +775,7 @@ static int au8522_probe(struct i2c_client *client, state->pads[AU8522_PAD_INPUT].flags = MEDIA_PAD_FL_SINK; state->pads[AU8522_PAD_VID_OUT].flags = MEDIA_PAD_FL_SOURCE; state->pads[AU8522_PAD_VBI_OUT].flags = MEDIA_PAD_FL_SOURCE; + state->pads[AU8522_PAD_AUDIO_OUT].flags = MEDIA_PAD_FL_SINK; sd->entity.type = MEDIA_ENT_T_V4L2_SUBDEV_DECODER; ret = media_entity_init(&sd->entity, ARRAY_SIZE(state->pads), diff --git a/drivers/media/dvb-frontends/au8522_priv.h b/drivers/media/dvb-frontends/au8522_priv.h index d6209d9..4c2a6ed 100644 --- a/drivers/media/dvb-frontends/au8522_priv.h +++ b/drivers/media/dvb-frontends/au8522_priv.h @@ -39,14 +39,6 @@ #define AU8522_DIGITAL_MODE 1 #define AU8522_SUSPEND_MODE 2 -enum au8522_media_pads { - AU8522_PAD_INPUT, - AU8522_PAD_VID_OUT, - AU8522_PAD_VBI_OUT, - - AU8522_NUM_PADS -}; - struct au8522_state { struct i2c_client *c; struct i2c_adapter *i2c;