Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-13.0 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1CABDC433DF for ; Mon, 3 Aug 2020 03:46:05 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id F233C206E2 for ; Mon, 3 Aug 2020 03:46:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726795AbgHCDqE (ORCPT ); Sun, 2 Aug 2020 23:46:04 -0400 Received: from szxga07-in.huawei.com ([45.249.212.35]:58560 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725840AbgHCDqD (ORCPT ); Sun, 2 Aug 2020 23:46:03 -0400 Received: from DGGEMS405-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 89B10F024055EBB9AACB; Mon, 3 Aug 2020 11:45:59 +0800 (CST) Received: from localhost.localdomain.localdomain (10.175.113.25) by DGGEMS405-HUB.china.huawei.com (10.3.19.205) with Microsoft SMTP Server id 14.3.487.0; Mon, 3 Aug 2020 11:45:52 +0800 From: Jing Xiangfeng To: , , , CC: , , Subject: [PATCH] drm/nouveau/acr: fix a coding style in nvkm_acr_lsfw_load_bl_inst_data_sig() Date: Mon, 3 Aug 2020 11:48:27 +0800 Message-ID: <20200803034827.100685-1-jingxiangfeng@huawei.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.113.25] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch performs the following changes: 1. remove a redundant parentheses around the nvkm_acr_lsfw_add() calls 2. do assignment before this if condition, it is more readable Signed-off-by: Jing Xiangfeng --- drivers/gpu/drm/nouveau/nvkm/subdev/acr/lsfw.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/lsfw.c b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/lsfw.c index 07d1830126ab..5f6006418472 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/lsfw.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/lsfw.c @@ -191,7 +191,8 @@ nvkm_acr_lsfw_load_bl_inst_data_sig(struct nvkm_subdev *subdev, u32 *bldata; int ret; - if (IS_ERR((lsfw = nvkm_acr_lsfw_add(func, acr, falcon, id)))) + lsfw = nvkm_acr_lsfw_add(func, acr, falcon, id); + if (IS_ERR(lsfw)) return PTR_ERR(lsfw); ret = nvkm_firmware_load_name(subdev, path, "bl", ver, &bl); -- 2.17.1