From patchwork Thu Mar 10 14:50:22 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shuah Khan X-Patchwork-Id: 8557621 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 A7FC5C0553 for ; Thu, 10 Mar 2016 14:50:34 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id A15102034B for ; Thu, 10 Mar 2016 14:50:33 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B42032037C for ; Thu, 10 Mar 2016 14:50:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752239AbcCJOu3 (ORCPT ); Thu, 10 Mar 2016 09:50:29 -0500 Received: from mailout.easymail.ca ([64.68.201.169]:48400 "EHLO mailout.easymail.ca" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752002AbcCJOu2 (ORCPT ); Thu, 10 Mar 2016 09:50:28 -0500 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 58714EC97; Thu, 10 Mar 2016 09:50:27 -0500 (EST) X-Virus-Scanned: Debian amavisd-new at mailout.easymail.ca X-Spam-Score: -3.692 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 N9ckQpNpPshn; Thu, 10 Mar 2016 09:50:24 -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 786DBECA6; Thu, 10 Mar 2016 09:50:24 -0500 (EST) Received: from lorien.internal (lorien-wl.internal [192.168.1.40]) by mail.gonehiking.org (Postfix) with ESMTP id 08B4C9F14A; Thu, 10 Mar 2016 07:50:23 -0700 (MST) From: Shuah Khan To: mchehab@osg.samsung.com Cc: Shuah Khan , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] media: fix !CONFIG_MEDIA_CONTROLLER compile error for v4l_change_media_source() Date: Thu, 10 Mar 2016 07:50:22 -0700 Message-Id: <1457621422-3187-1-git-send-email-shuahkh@osg.samsung.com> X-Mailer: git-send-email 2.5.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 This error is a result of not defining v4l_change_media_source() stub in include/media/v4l2-mc.h for !CONFIG_MEDIA_CONTROLLER case. Fix the following compile error: url: https://github.com/0day-ci/linux/commits/Shuah-Khan/media-add-change_source-handler-support/20160310-131140 base: git://linuxtv.org/media_tree.git master config: x86_64-rhel (attached as .config) reproduce: # save the attached .config to linux build tree make ARCH=x86_64 All errors (new ones prefixed by >>): drivers/media/usb/au0828/au0828-video.c: In function 'vidioc_s_input': >> drivers/media/usb/au0828/au0828-video.c:1474:2: error: implicit declaration of function 'v4l_change_media_source' [-Werror=implicit-function-declaration] return v4l_change_media_source(vfd); ^ cc1: some warnings being treated as errors Signed-off-by: Shuah Khan --- This patch applies on top of: https://lkml.org/lkml/2016/3/10/7 include/media/v4l2-mc.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/media/v4l2-mc.h b/include/media/v4l2-mc.h index 884b969..50b9348 100644 --- a/include/media/v4l2-mc.h +++ b/include/media/v4l2-mc.h @@ -237,6 +237,11 @@ static inline int v4l_enable_media_source(struct video_device *vdev) return 0; } +static inline int v4l_change_media_source(struct video_device *vdev) +{ + return 0; +} + static inline void v4l_disable_media_source(struct video_device *vdev) { }