From patchwork Tue Jan 19 18:33:43 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Shuah Khan X-Patchwork-Id: 8064601 Return-Path: X-Original-To: patchwork-linux-media@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 07954BEEE5 for ; Tue, 19 Jan 2016 18:33:56 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 34D5620576 for ; Tue, 19 Jan 2016 18:33:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E100420574 for ; Tue, 19 Jan 2016 18:33:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932783AbcASSdt (ORCPT ); Tue, 19 Jan 2016 13:33:49 -0500 Received: from mailout.easymail.ca ([64.68.201.169]:54777 "EHLO mailout.easymail.ca" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932371AbcASSds (ORCPT ); Tue, 19 Jan 2016 13:33:48 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 91153E8B2; Tue, 19 Jan 2016 13:33:47 -0500 (EST) X-Quarantine-ID: X-Virus-Scanned: Debian amavisd-new at mailout.easymail.ca X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" X-Spam-Score: -3.629 X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (easymail-mailout.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id gh1CN9fGuoee; Tue, 19 Jan 2016 13:33:47 -0500 (EST) Received: from mail.gonehiking.org (c-73-181-52-62.hsd1.co.comcast.net [73.181.52.62]) by mailout.easymail.ca (Postfix) with ESMTPA id 1ABE6E7F0; Tue, 19 Jan 2016 13:33:47 -0500 (EST) Received: from lorien.internal (lorien-wl.internal [192.168.1.40]) by mail.gonehiking.org (Postfix) with ESMTP id 6C5BA9F372; Tue, 19 Jan 2016 11:33:46 -0700 (MST) From: Shuah Khan To: mchehab@osg.samsung.com, hans.verkuil@cisco.com, chehabrafael@gmail.com, javier@osg.samsung.com Cc: Shuah Khan , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/2] media: au0828 fix enable/disable source compile warns Date: Tue, 19 Jan 2016 11:33:43 -0700 Message-Id: <191653dd281869ad5e5aded297be86d29eaba345.1453223886.git.shuahkh@osg.samsung.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: References: In-Reply-To: References: MIME-Version: 1.0 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Fix the following compile warns for MEDIA_CONTROLLER disabled case. CC [M] drivers/media/usb/au0828/au0828-core.o drivers/media/usb/au0828/au0828-core.c:398:12: warning: ‘au0828_enable_source’ defined but not used [-Wunused-function] static int au0828_enable_source(struct media_entity *entity, ^ drivers/media/usb/au0828/au0828-core.c:497:13: warning: ‘au0828_disable_source’ defined but not used [-Wunused-function] static void au0828_disable_source(struct media_entity *entity) ^ Signed-off-by: Shuah Khan --- drivers/media/usb/au0828/au0828-core.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/media/usb/au0828/au0828-core.c b/drivers/media/usb/au0828/au0828-core.c index de357a2..7dda0dd 100644 --- a/drivers/media/usb/au0828/au0828-core.c +++ b/drivers/media/usb/au0828/au0828-core.c @@ -395,10 +395,10 @@ void au0828_create_media_graph_notify(struct media_entity *new, #endif } +#ifdef CONFIG_MEDIA_CONTROLLER static int au0828_enable_source(struct media_entity *entity, struct media_pipeline *pipe) { -#ifdef CONFIG_MEDIA_CONTROLLER struct media_entity *source; struct media_entity *sink; struct media_link *link, *found_link = NULL; @@ -490,13 +490,10 @@ end: pr_debug("au0828_enable_source() end %s %d %d\n", entity->name, entity->function, ret); return ret; -#endif - return 0; } static void au0828_disable_source(struct media_entity *entity) { -#ifdef CONFIG_MEDIA_CONTROLLER struct media_entity *sink; int ret = 0; struct media_device *mdev = entity->graph_obj.mdev; @@ -536,8 +533,8 @@ static void au0828_disable_source(struct media_entity *entity) end: mutex_unlock(&mdev->graph_mutex); -#endif } +#endif static int au0828_media_device_register(struct au0828_dev *dev, struct usb_device *udev)