From patchwork Thu Oct 15 12:29:38 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luis de Bethencourt X-Patchwork-Id: 7405801 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 97425BEEA4 for ; Thu, 15 Oct 2015 12:29:52 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id AA39920850 for ; Thu, 15 Oct 2015 12:29:51 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 51C4D20662 for ; Thu, 15 Oct 2015 12:29:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751478AbbJOM3t (ORCPT ); Thu, 15 Oct 2015 08:29:49 -0400 Received: from lists.s-osg.org ([54.187.51.154]:57716 "EHLO lists.s-osg.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751414AbbJOM3s (ORCPT ); Thu, 15 Oct 2015 08:29:48 -0400 Received: from localhost.localdomain (171.Red-88-22-57.staticIP.rima-tde.net [88.22.57.171]) by lists.s-osg.org (Postfix) with ESMTPSA id 94D39462A0; Thu, 15 Oct 2015 05:29:43 -0700 (PDT) From: Luis de Bethencourt To: linux-kernel@vger.kernel.org Cc: tomi.valkeinen@ti.com, plagnioj@jcrosoft.com, laurent.pinchart@ideasonboard.com, linux-omap@vger.kernel.org, linux-fbdev@vger.kernel.org, Luis de Bethencourt Subject: [PATCH] OMAPDSS: DISPC: Remove boolean comparisons Date: Thu, 15 Oct 2015 13:29:38 +0100 Message-Id: <1444912178-15989-1-git-send-email-luisbg@osg.samsung.com> X-Mailer: git-send-email 2.5.1 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_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 Boolean tests do not need explicit comparison to true or false. Signed-off-by: Luis de Bethencourt Acked-by: Laurent Pinchart --- drivers/video/fbdev/omap2/dss/dispc-compat.c | 6 +++--- drivers/video/fbdev/omap2/dss/dispc.c | 6 +++--- drivers/video/fbdev/omap2/dss/manager.c | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/video/fbdev/omap2/dss/dispc-compat.c b/drivers/video/fbdev/omap2/dss/dispc-compat.c index 633c461..0918b3b 100644 --- a/drivers/video/fbdev/omap2/dss/dispc-compat.c +++ b/drivers/video/fbdev/omap2/dss/dispc-compat.c @@ -476,7 +476,7 @@ static void dispc_mgr_disable_lcd_out(enum omap_channel channel) int r; u32 irq; - if (dispc_mgr_is_enabled(channel) == false) + if (!dispc_mgr_is_enabled(channel)) return; /* @@ -524,7 +524,7 @@ static void dispc_mgr_enable_digit_out(void) int r; u32 irq_mask; - if (dispc_mgr_is_enabled(OMAP_DSS_CHANNEL_DIGIT) == true) + if (dispc_mgr_is_enabled(OMAP_DSS_CHANNEL_DIGIT)) return; /* @@ -562,7 +562,7 @@ static void dispc_mgr_disable_digit_out(void) u32 irq_mask; int num_irqs; - if (dispc_mgr_is_enabled(OMAP_DSS_CHANNEL_DIGIT) == false) + if (!dispc_mgr_is_enabled(OMAP_DSS_CHANNEL_DIGIT)) return; /* diff --git a/drivers/video/fbdev/omap2/dss/dispc.c b/drivers/video/fbdev/omap2/dss/dispc.c index be716c9..43b0367 100644 --- a/drivers/video/fbdev/omap2/dss/dispc.c +++ b/drivers/video/fbdev/omap2/dss/dispc.c @@ -571,7 +571,7 @@ EXPORT_SYMBOL(dispc_mgr_go_busy); void dispc_mgr_go(enum omap_channel channel) { - WARN_ON(dispc_mgr_is_enabled(channel) == false); + WARN_ON(!dispc_mgr_is_enabled(channel)); WARN_ON(dispc_mgr_go_busy(channel)); DSSDBG("GO %s\n", mgr_desc[channel].name); @@ -3220,7 +3220,7 @@ void dispc_mgr_set_timings(enum omap_channel channel, DSSDBG("hsync %luHz, vsync %luHz\n", ht, vt); } else { - if (t.interlace == true) + if (t.interlace) t.y_res /= 2; } @@ -3237,7 +3237,7 @@ static void dispc_mgr_set_lcd_divisor(enum omap_channel channel, u16 lck_div, dispc_write_reg(DISPC_DIVISORo(channel), FLD_VAL(lck_div, 23, 16) | FLD_VAL(pck_div, 7, 0)); - if (dss_has_feature(FEAT_CORE_CLK_DIV) == false && + if (!dss_has_feature(FEAT_CORE_CLK_DIV) && channel == OMAP_DSS_CHANNEL_LCD) dispc.core_clk_rate = dispc_fclk_rate() / lck_div; } diff --git a/drivers/video/fbdev/omap2/dss/manager.c b/drivers/video/fbdev/omap2/dss/manager.c index 1aac9b4..08a67f4 100644 --- a/drivers/video/fbdev/omap2/dss/manager.c +++ b/drivers/video/fbdev/omap2/dss/manager.c @@ -210,7 +210,7 @@ static int dss_mgr_check_lcd_config(struct omap_overlay_manager *mgr, return -EINVAL; /* fifohandcheck should be used only with stallmode */ - if (stallmode == false && fifohandcheck == true) + if (!stallmode && fifohandcheck) return -EINVAL; /*