From patchwork Wed May 11 15:59:23 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Javier Martinez Canillas X-Patchwork-Id: 9072311 Return-Path: X-Original-To: patchwork-linux-fbdev@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 67546BF29F for ; Wed, 11 May 2016 15:59:42 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2F9DD2014A for ; Wed, 11 May 2016 15:59:41 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id BBC1A200D0 for ; Wed, 11 May 2016 15:59:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751338AbcEKP7j (ORCPT ); Wed, 11 May 2016 11:59:39 -0400 Received: from lists.s-osg.org ([54.187.51.154]:47033 "EHLO lists.s-osg.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751308AbcEKP7i (ORCPT ); Wed, 11 May 2016 11:59:38 -0400 Received: from minerva.sisa.samsung.com (unknown [181.124.126.244]) by lists.s-osg.org (Postfix) with ESMTPSA id 38DA4E2749; Wed, 11 May 2016 08:59:52 -0700 (PDT) From: Javier Martinez Canillas To: linux-kernel@vger.kernel.org Cc: Javier Martinez Canillas , linux-fbdev@vger.kernel.org, Florian Tobias Schandinat , Tomi Valkeinen , Jean-Christophe Plagniol-Villard Subject: [PATCH] fbdev: Use IS_ENABLED() instead of checking for built-in or module Date: Wed, 11 May 2016 11:59:23 -0400 Message-Id: <1462982363-25389-1-git-send-email-javier@osg.samsung.com> X-Mailer: git-send-email 2.5.5 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Spam-Status: No, score=-8.3 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either built-in or as a module, use that macro instead of open coding the same. Signed-off-by: Javier Martinez Canillas --- drivers/video/fbdev/via/accel.c | 2 +- drivers/video/fbdev/via/via-core.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/video/fbdev/via/accel.c b/drivers/video/fbdev/via/accel.c index 4b67b8e6030a..eb3615c69987 100644 --- a/drivers/video/fbdev/via/accel.c +++ b/drivers/video/fbdev/via/accel.c @@ -358,7 +358,7 @@ int viafb_setup_engine(struct fb_info *info) viapar->shared->vq_vram_addr = viapar->fbmem_free; viapar->fbmem_used += VQ_SIZE; -#if defined(CONFIG_VIDEO_VIA_CAMERA) || defined(CONFIG_VIDEO_VIA_CAMERA_MODULE) +#if IS_ENABLED(CONFIG_VIDEO_VIA_CAMERA) /* * Set aside a chunk of framebuffer memory for the camera * driver. Someday this driver probably needs a proper allocator diff --git a/drivers/video/fbdev/via/via-core.c b/drivers/video/fbdev/via/via-core.c index 6e274825fb31..1d28e16888e9 100644 --- a/drivers/video/fbdev/via/via-core.c +++ b/drivers/video/fbdev/via/via-core.c @@ -116,7 +116,7 @@ EXPORT_SYMBOL_GPL(viafb_irq_disable); * most viafb systems will not need to have this extra code for a while. * As soon as another user comes long, the ifdef can be removed. */ -#if defined(CONFIG_VIDEO_VIA_CAMERA) || defined(CONFIG_VIDEO_VIA_CAMERA_MODULE) +#if IS_ENABLED(CONFIG_VIDEO_VIA_CAMERA) /* * Access to the DMA engine. This currently provides what the camera * driver needs (i.e. outgoing only) but is easily expandable if need @@ -542,7 +542,7 @@ static struct viafb_subdev_info { { .name = "viafb-i2c", }, -#if defined(CONFIG_VIDEO_VIA_CAMERA) || defined(CONFIG_VIDEO_VIA_CAMERA_MODULE) +#if IS_ENABLED(CONFIG_VIDEO_VIA_CAMERA) { .name = "viafb-camera", },