From patchwork Tue Sep 22 17:19:30 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shuah Khan X-Patchwork-Id: 7250291 Return-Path: X-Original-To: patchwork-alsa-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 565E59F40A for ; Wed, 23 Sep 2015 14:41:33 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 67F4120AD1 for ; Wed, 23 Sep 2015 14:41:32 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id D6ADB20AC9 for ; Wed, 23 Sep 2015 14:41:30 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 73E0426546A; Wed, 23 Sep 2015 16:41:29 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_LOW, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (localhost [IPv6:::1]) by alsa0.perex.cz (Postfix) with ESMTP id CC194265465; Wed, 23 Sep 2015 16:33:54 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id CF5DB265083; Tue, 22 Sep 2015 19:20:25 +0200 (CEST) Received: from resqmta-po-09v.sys.comcast.net (resqmta-po-09v.sys.comcast.net [96.114.154.168]) by alsa0.perex.cz (Postfix) with ESMTP id DA97E265083 for ; Tue, 22 Sep 2015 19:19:53 +0200 (CEST) Received: from resomta-po-01v.sys.comcast.net ([96.114.154.225]) by resqmta-po-09v.sys.comcast.net with comcast id LHKo1r0054s37d401HKtkN; Tue, 22 Sep 2015 17:19:53 +0000 Received: from mail.gonehiking.org ([73.181.52.62]) by resomta-po-01v.sys.comcast.net with comcast id LHKm1r00G1LXgTt01HKsMi; Tue, 22 Sep 2015 17:19:53 +0000 Received: from lorien.internal (lorien-wl.internal [192.168.1.40]) by mail.gonehiking.org (Postfix) with ESMTP id 40ED3A1633; Tue, 22 Sep 2015 11:19:52 -0600 (MDT) From: Shuah Khan To: mchehab@osg.samsung.com, hans.verkuil@cisco.com, laurent.pinchart@ideasonboard.com, sakari.ailus@linux.intel.com, tiwai@suse.de, pawel@osciak.com, m.szyprowski@samsung.com, kyungmin.park@samsung.com, perex@perex.cz, stefanr@s5r6.in-berlin.de, crope@iki.fi, dan.carpenter@oracle.com, tskd08@gmail.com, ruchandani.tina@gmail.com, arnd@arndb.de, chehabrafael@gmail.com, prabhakar.csengg@gmail.com, Julia.Lawall@lip6.fr, elfring@users.sourceforge.net, ricardo.ribalda@gmail.com, chris.j.arges@canonical.com, pierre-louis.bossart@linux.intel.com, gtmkramer@xs4all.nl, clemens@ladisch.de, misterpib@gmail.com, takamichiho@gmail.com, pmatilai@laiskiainen.org, damien@zamaudio.com, daniel@zonque.org, vladcatoi@gmail.com, normalperson@yhbt.net, joe@oampo.co.uk, bugzilla.frnkcg@spamgourmet.com, jussi@sonarnerd.net Date: Tue, 22 Sep 2015 11:19:30 -0600 Message-Id: <754f57fb0f42cc11d00ee3bbbc3df6c01d909463.1442937669.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=1442942393; bh=wwYN3oCez5t03mpAndYFyHT7I4Wp9wNsPtr6p/TBIHA=; h=Received:Received:Received:From:To:Subject:Date:Message-Id; b=tWASU3TD3ctqgra9edcELYDBwajaaDWv6xWfY6DXNIh7XxMD0gLm+AqGusjoPurqz KoTwO3Of0kJzfrKeBaFKuQHLuEP3pTUR4XXO6WDtDwBOK2e0L0sHRAfgXsXTEHh+xk EnjGzOcun9D+GKS83epEUhT63XMQ5vHF7f16P7O65EA96LNXXEkTW1+QffRz8I2jEk m+KUvcdNfKIZTQSGIAJas3ka2MpeR4vYq94wRzTHFhjQE/Kn9n2tFl1B9gaHPvncDo mflcDTdHNnzPRZQ0eOLQlHzDxPeyD8BcRNCYol3yzHbN80G8UPPjgUAd9wfk/YYGvc 7nBCyCZKXUMYQ== X-Mailman-Approved-At: Wed, 23 Sep 2015 16:33:44 +0200 Cc: alsa-devel@alsa-project.org, Shuah Khan , linux-media@vger.kernel.org Subject: [alsa-devel] [PATCH v3 11/21] media: au0828 Use au8522_media_pads enum for pad defines X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP Change au0828-core to use au8522_media_pads enum 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/usb/au0828/au0828-core.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/drivers/media/usb/au0828/au0828-core.c b/drivers/media/usb/au0828/au0828-core.c index 0378a2c..276598b 100644 --- a/drivers/media/usb/au0828/au0828-core.c +++ b/drivers/media/usb/au0828/au0828-core.c @@ -20,6 +20,7 @@ */ #include "au0828.h" +#include "au8522.h" #include #include @@ -263,11 +264,13 @@ static void au0828_create_media_graph(struct au0828_dev *dev) media_entity_create_link(tuner, 0, decoder, 0, MEDIA_LNK_FL_ENABLED); if (dev->vdev.entity.links) - media_entity_create_link(decoder, 1, &dev->vdev.entity, 0, - MEDIA_LNK_FL_ENABLED); + media_entity_create_link(decoder, AU8522_PAD_VID_OUT, + &dev->vdev.entity, 0, + MEDIA_LNK_FL_ENABLED); if (dev->vbi_dev.entity.links) - media_entity_create_link(decoder, 2, &dev->vbi_dev.entity, 0, - MEDIA_LNK_FL_ENABLED); + media_entity_create_link(decoder, AU8522_PAD_VBI_OUT, + &dev->vbi_dev.entity, 0, + MEDIA_LNK_FL_ENABLED); #endif }