From patchwork Thu May 4 16:55:36 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: SF Markus Elfring X-Patchwork-Id: 9712305 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 9BFC360235 for ; Thu, 4 May 2017 16:55:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8CC5727CAF for ; Thu, 4 May 2017 16:55:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7FACB2860E; Thu, 4 May 2017 16:55: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=-4.2 required=2.0 tests=BAYES_00, 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 0A21427CAF for ; Thu, 4 May 2017 16:55:50 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 868E96E57C; Thu, 4 May 2017 16:55:48 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mout.web.de (mout.web.de [212.227.17.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3A4DF6E579 for ; Thu, 4 May 2017 16:55:46 +0000 (UTC) Received: from [192.168.1.2] ([92.228.166.245]) by smtp.web.de (mrweb101 [213.165.67.124]) with ESMTPSA (Nemesis) id 0MVchv-1dZ8H01Sjn-00Yyb0; Thu, 04 May 2017 18:55:37 +0200 Subject: [PATCH 4/9] drm/i915: Delete unnecessary braces in three functions From: SF Markus Elfring To: dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, Chris Wilson , Daniel Vetter , David Airlie , Jani Nikula References: <39c8a155-cf89-1aa5-9ca6-4e9ccf3aa602@users.sourceforge.net> Message-ID: Date: Thu, 4 May 2017 18:55:36 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.0.1 MIME-Version: 1.0 In-Reply-To: <39c8a155-cf89-1aa5-9ca6-4e9ccf3aa602@users.sourceforge.net> Content-Language: en-US X-Provags-ID: V03:K0:c8/9C3MRm+WEKykLw4kcHYmGnRhhQxGC7oSI4RP1VL3OivghS4N GpeUlMEcJ9sgVS+GbE107v2Mve/mDVBoJivaEFM7S9dokMitNavwJk0yxx7y0esXfmnVec5 NRvmFcqASwjyF01xEjFWlj9FtqTu8FndAuByUl5f7T6rwOXpz0pzrf1gngCJZuiTxKWFcfm 0En+4LSY44uOh/x46nFoQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:JuTLvdZWkQw=:u4BYYuHTPhREa+SzSE7sjd PeQfO/o4JTmaA0kEuuMNJxpczkk/FP4WnAPyivp8VWtGLU1gXksukYdQXKbs6hvCDQpgt/SOq AvdNR/Sd3nnC2+wmMQ/iLt0OZdKvIv1mK+3k4/f0/tG9IqRPrKI9/LOP6CXAWcgcBOciVch/w 4+If2RQWQi5s+nsijwYYC76j1YhwvuwsX1dVZJMGALL1YCtal9Bb2Am34HEHQEbAdAfm14Vj+ hkH9Q+qU3/Q3eS9OHuKs7eS+7AJyrtRdQBaYl7HybAYbqplMIByFzbmpLzeWEC91iALE7rVjr iL1wf5T6u8geMfInCBPXIAbnmFsgDpuRL48Ml+AWpa9UIF3dxwVufU2W6cVhnMiXAAYnH2u1L GU97BFAneFeWfNnbefWsqms0VkuogiHIu+L8SYYIHL/K3UTIqMBhgRf5XLqwWYNKTvefFugZ3 p+9GqjjA11lCbTbs51ggjIJD/Do9Tsb9u2XvZ+uRopFhMtgcElLUGU5CUUifF1s7h01wiWxCD O7zcfOKU0iiObYxhqRqoXi/hRvd0FbQHKN3Z8Yz7R5E8WyJ05vHiohLP+vNb2Dtc1XFffLcpx gb5/APxm+uwf/9t02A8jWf6nl2+Bj0rtCInLyooGxhDAvc2PGI9uaCBNViEcIuwbnuUnxQU+L A+kI4qvOmjHNyMe06DLggkoRcmwr7NjKp0VQ3SjfnwH6bKYDJV9EZq6oi2ahquNCJIpC0VrHi XLVG+IAZjozk2cf+TR0DBA4s7VdtGBAGfd7AdpLt/M862pmWtYlDj0IWiChfQ2mkAhXlI8PNP tW0/7oYovZSMWE9hN9/VT0S6WJcyg== Cc: kernel-janitors@vger.kernel.org, LKML X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Markus Elfring Date: Thu, 4 May 2017 13:40:53 +0200 Do not use curly brackets at some source code places where a single statement should be sufficient. Signed-off-by: Markus Elfring --- drivers/gpu/drm/i915/i915_debugfs.c | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c index 296108464f2b..bf9a2e8d8c16 100644 --- a/drivers/gpu/drm/i915/i915_debugfs.c +++ b/drivers/gpu/drm/i915/i915_debugfs.c @@ -565,13 +565,13 @@ static int i915_gem_pageflip_info(struct seq_file *m, void *data) u32 addr; pending = atomic_read(&work->pending); - if (pending) { + if (pending) seq_printf(m, "Flip ioctl preparing on pipe %c (plane %c)\n", pipe, plane); - } else { + else seq_printf(m, "Flip pending (waiting for vsync) on pipe %c (plane %c)\n", pipe, plane); - } + if (work->flip_queued_req) { struct intel_engine_cs *engine = work->flip_queued_req->engine; @@ -3130,13 +3130,11 @@ static void intel_plane_info(struct seq_file *m, struct intel_crtc *intel_crtc) } state = plane->state; - - if (state->fb) { + if (state->fb) drm_get_format_name(state->fb->format->format, &format_name); - } else { + else sprintf(format_name.str, "N/A"); - } seq_printf(m, "\t--Plane id %d: type=%s, crtc_pos=%4dx%4d, crtc_size=%4dx%4d, src_pos=%d.%04ux%d.%04u, src_size=%d.%04ux%d.%04u, format=%s, rotation=%s\n", plane->base.id, @@ -4636,13 +4634,12 @@ static int i915_sseu_status(struct seq_file *m, void *unused) intel_runtime_pm_get(dev_priv); - if (IS_CHERRYVIEW(dev_priv)) { + if (IS_CHERRYVIEW(dev_priv)) cherryview_sseu_device_status(dev_priv, &sseu); - } else if (IS_BROADWELL(dev_priv)) { + else if (IS_BROADWELL(dev_priv)) broadwell_sseu_device_status(dev_priv, &sseu); - } else if (INTEL_GEN(dev_priv) >= 9) { + else if (INTEL_GEN(dev_priv) >= 9) gen9_sseu_device_status(dev_priv, &sseu); - } intel_runtime_pm_put(dev_priv);