From patchwork Fri May 4 20:49:32 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: 10381659 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 F3F4560159 for ; Fri, 4 May 2018 20:50:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E04CE294C6 for ; Fri, 4 May 2018 20:50:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D412F2957B; Fri, 4 May 2018 20:50:41 +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=-5.2 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 58AFC294C6 for ; Fri, 4 May 2018 20:50:40 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 416916E957; Fri, 4 May 2018 20:49:49 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from osg.samsung.com (osg.samsung.com [64.30.133.232]) by gabe.freedesktop.org (Postfix) with ESMTP id 5FB2D6E95A for ; Fri, 4 May 2018 20:49:47 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by osg.samsung.com (Postfix) with ESMTP id 99BE720139; Fri, 4 May 2018 13:49:46 -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 ykvsACJAjZrw; Fri, 4 May 2018 13:49:36 -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 9DD782010D; Fri, 4 May 2018 13:49:36 -0700 (PDT) Received: from mchehab by smtp.s-opensource.com with local (Exim 4.90_1) (envelope-from ) id 1fEhe2-0001Km-7S; Fri, 04 May 2018 16:49:34 -0400 From: Mauro Carvalho Chehab To: Subject: [PATCH] media: include/video/omapfb_dss.h: use IS_ENABLED() Date: Fri, 4 May 2018 16:49:32 -0400 Message-Id: <8d55f45b6aa36f5c758d191825f14cd31723b371.1525466956.git.mchehab+samsung@kernel.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <201805050150.CmagcMOg%fengguang.wu@intel.com> References: <201805050150.CmagcMOg%fengguang.wu@intel.com> X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-fbdev@vger.kernel.org, Bartlomiej Zolnierkiewicz , Randy Dunlap , dri-devel@lists.freedesktop.org, Mauro Carvalho Chehab , tomi.valkeinen@ti.com, Mauro Carvalho Chehab , linux-omap@vger.kernel.org, Linux Media Mailing List MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Just checking for ifdefs cause build issues as reported by kernel test: config: openrisc-allmodconfig (attached as .config) compiler: or1k-linux-gcc (GCC) 6.0.0 20160327 (experimental) All errors (new ones prefixed by >>): drivers/video/fbdev/omap2/omapfb/omapfb-main.c: In function 'omapfb_init_connections': >> drivers/video/fbdev/omap2/omapfb/omapfb-main.c:2396:8: error: implicit declaration of function 'omapdss_find_mgr_from_display' [-Werror=implicit-function-declaration] mgr = omapdss_find_mgr_from_display(def_dssdev); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/video/fbdev/omap2/omapfb/omapfb-main.c:2396:6: warning: assignment makes pointer from integer without a cast [-Wint-conversion] mgr = omapdss_find_mgr_from_display(def_dssdev); ^ drivers/video/fbdev/omap2/omapfb/omapfb-main.c: In function 'omapfb_find_default_display': >> drivers/video/fbdev/omap2/omapfb/omapfb-main.c:2430:13: error: implicit declaration of function 'omapdss_get_default_display_name' [-Werror=implicit-function-declaration] def_name = omapdss_get_default_display_name(); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/video/fbdev/omap2/omapfb/omapfb-main.c:2430:11: warning: assignment makes pointer from integer without a cast [-Wint-conversion] def_name = omapdss_get_default_display_name(); ^ So, use IS_ENABLED() instead. Cc: Bartlomiej Zolnierkiewicz Cc: Randy Dunlap Cc: tomi.valkeinen@ti.com Cc: linux-omap@vger.kernel.org Cc: linux-fbdev@vger.kernel.org Fixes: 771f7be87ff9 ("media: omapfb: omapfb_dss.h: add stubs to build with COMPILE_TEST && DRM_OMAP") Signed-off-by: Mauro Carvalho Chehab Tested-by: Randy Dunlap Acked-by: Randy Dunlap --- include/video/omapfb_dss.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/video/omapfb_dss.h b/include/video/omapfb_dss.h index e9775144ff3b..12755d8d9b4f 100644 --- a/include/video/omapfb_dss.h +++ b/include/video/omapfb_dss.h @@ -778,7 +778,7 @@ struct omap_dss_driver { typedef void (*omap_dispc_isr_t) (void *arg, u32 mask); -#ifdef CONFIG_FB_OMAP2 +#if IS_ENABLED(CONFIG_FB_OMAP2) enum omapdss_version omapdss_get_version(void); bool omapdss_is_initialized(void);