From patchwork Fri May 4 14:12:37 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mauro Carvalho Chehab X-Patchwork-Id: 10380691 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id C025F60541 for ; Fri, 4 May 2018 14:12:52 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A337B290B8 for ; Fri, 4 May 2018 14:12:52 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 97F502913D; Fri, 4 May 2018 14:12:52 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5BE7C2910F for ; Fri, 4 May 2018 14:12:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751339AbeEDOMt (ORCPT ); Fri, 4 May 2018 10:12:49 -0400 Received: from osg.samsung.com ([64.30.133.232]:34445 "EHLO osg.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751262AbeEDOMs (ORCPT ); Fri, 4 May 2018 10:12:48 -0400 Received: from localhost (localhost [127.0.0.1]) by osg.samsung.com (Postfix) with ESMTP id 38BEB1E8C1; Fri, 4 May 2018 07:12:48 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at dev.s-opensource.com Received: from osg.samsung.com ([127.0.0.1]) by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id MsdTY44Nk7Vp; Fri, 4 May 2018 07:12:42 -0700 (PDT) Received: from smtp.s-opensource.com (177.17.129.114.dynamic.adsl.gvt.net.br [177.17.129.114]) by osg.samsung.com (Postfix) with ESMTPSA id 3F1B51E8B9; Fri, 4 May 2018 07:12:42 -0700 (PDT) Received: from mchehab by smtp.s-opensource.com with local (Exim 4.90_1) (envelope-from ) id 1fEbRw-00099I-0E; Fri, 04 May 2018 10:12:40 -0400 From: Mauro Carvalho Chehab To: Andy Shevchenko Cc: Mauro Carvalho Chehab , Linux Media Mailing List , Mauro Carvalho Chehab , Mattia Dongili , platform-driver-x86@vger.kernel.org, Mauro Carvalho Chehab Subject: [PATCH 2/7 v2] media: meye: allow building it with COMPILE_TEST on non-x86 Date: Fri, 4 May 2018 10:12:37 -0400 Message-Id: <6317031914d6fa11ad57950f9090bb9041997f00.1525443130.git.mchehab+samsung@kernel.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: References: Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Mauro Carvalho Chehab This driver depends on sony-laptop driver, but this is available only for x86. So, add a stub function, in order to allow building it on non-x86 too. Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Mauro Carvalho Chehab --- drivers/media/pci/meye/Kconfig | 3 ++- include/linux/sony-laptop.h | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/media/pci/meye/Kconfig b/drivers/media/pci/meye/Kconfig index b4bf848be5a0..2e60334ffef5 100644 --- a/drivers/media/pci/meye/Kconfig +++ b/drivers/media/pci/meye/Kconfig @@ -1,6 +1,7 @@ config VIDEO_MEYE tristate "Sony Vaio Picturebook Motion Eye Video For Linux" - depends on PCI && SONY_LAPTOP && VIDEO_V4L2 + depends on PCI && VIDEO_V4L2 + depends on SONY_LAPTOP || COMPILE_TEST ---help--- This is the video4linux driver for the Motion Eye camera found in the Vaio Picturebook laptops. Please read the material in diff --git a/include/linux/sony-laptop.h b/include/linux/sony-laptop.h index 1a4b77317fa1..374d0fdb0743 100644 --- a/include/linux/sony-laptop.h +++ b/include/linux/sony-laptop.h @@ -28,7 +28,11 @@ #define SONY_PIC_COMMAND_GETCAMERAROMVERSION 18 /* obsolete */ #define SONY_PIC_COMMAND_GETCAMERAREVISION 19 /* obsolete */ +#if IS_ENABLED(CONFIG_SONY_LAPTOP) int sony_pic_camera_command(int command, u8 value); +#else +static inline int sony_pic_camera_command(int command, u8 value) { return 0; }; +#endif #endif /* __KERNEL__ */