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: 10381655 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 D86D76038F for ; Fri, 4 May 2018 20:49:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C653A29578 for ; Fri, 4 May 2018 20:49:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BAED329579; Fri, 4 May 2018 20:49:51 +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 C6CDA29577 for ; Fri, 4 May 2018 20:49:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751668AbeEDUts (ORCPT ); Fri, 4 May 2018 16:49:48 -0400 Received: from osg.samsung.com ([64.30.133.232]:64169 "EHLO osg.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751630AbeEDUtr (ORCPT ); Fri, 4 May 2018 16:49:47 -0400 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 Cc: Mauro Carvalho Chehab , Linux Media Mailing List , Mauro Carvalho Chehab , Bartlomiej Zolnierkiewicz , dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, Randy Dunlap , tomi.valkeinen@ti.com, linux-omap@vger.kernel.org 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> To: unlisted-recipients:; (no To-header on input) Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org 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);