From patchwork Tue May 11 09:13:44 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Leizhen \(ThunderTown\)" X-Patchwork-Id: 434183 Delivered-To: patch@linaro.org Received: by 2002:a02:c901:0:0:0:0:0 with SMTP id t1csp3638242jao; Tue, 11 May 2021 02:14:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxLxfIDnxF+JiB/BCQ1LiPZNxEzqVkInpFq4d5sdZ94sen3O++OSnt/1Dy1T9jZ5b9wYk1u X-Received: by 2002:a17:90a:c687:: with SMTP id n7mr4175864pjt.104.1620724468868; Tue, 11 May 2021 02:14:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620724468; cv=none; d=google.com; s=arc-20160816; b=HEPbwvcu8ORmfY1CtSSttMbxkeDw/SH7585en+TnFSeLF3X41qhAAizgTamjXdON6r CMI7xnNad37OGU/9rl9jYqo+PZ4sZ/Y2h+diiBOMoyURgR/1kVB+MKrqpcCGhU2UT637 43Me606gNZkldpz1PVqqAu2QPELThWb5lYMeX1ReGin2KkvtxAnSdDvrTxK+sOXyj94/ bNJEbpbbRhbml2uUALxot310JMe1GNS2pvwxw9QHLXMTN0HIOowgC92l6ggTjdYa7GA1 hTnJUDwGcESz3GkKxIziWMRcjxZdaGeWrwXBbFcfvDXuVkbd5vAAN5F/5jfXBlgRQAcE Odgw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:to:from:delivered-to; bh=1ywiGQlvVZKsgNBnpirF5uTmM8QDGIxljRdiLOlZvjs=; b=fP2r2d10NeC1QcoFed91Oj1Bp9k2kn7Znv9FTTIHO47A2OG2ofIXNtV7ahBe0UMqNb WUC2W11c6htRsVhT1JZiAgI8EIMC2fPxoJacKHUV7N3Yn07p//xeWvBwPpE4xt/7eI0X 2N/AezL+O/TzdhmT8NsQ0JG6PEqF56jhrwN3Z18psd/au1/wUNCA3lVYu5bZ+sBmihFJ JCsWMnZPdnfxBfcJg2JkRg2KKZJy42YJUBSRuDBKGChR8ydDSxsyyIq5vBSqpLErjRqR oQq2XbWrhOgj5t70lDo19f9ZeLyBi38t9l1tjdZ5vP/ux4LJ48dAuN5Y7cTyuJ9D9qQF 7gfQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [131.252.210.177]) by mx.google.com with ESMTPS id a18si22939850pls.121.2021.05.11.02.14.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 May 2021 02:14:28 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) client-ip=131.252.210.177; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 9149E6E9FE; Tue, 11 May 2021 09:14:26 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from szxga05-in.huawei.com (szxga05-in.huawei.com [45.249.212.191]) by gabe.freedesktop.org (Postfix) with ESMTPS id 84BE36E9FE for ; Tue, 11 May 2021 09:14:25 +0000 (UTC) Received: from DGGEMS412-HUB.china.huawei.com (unknown [172.30.72.59]) by szxga05-in.huawei.com (SkyGuard) with ESMTP id 4FfXGF1p8CzPwmh; Tue, 11 May 2021 17:11:01 +0800 (CST) Received: from thunder-town.china.huawei.com (10.174.177.72) by DGGEMS412-HUB.china.huawei.com (10.3.19.212) with Microsoft SMTP Server id 14.3.498.0; Tue, 11 May 2021 17:14:13 +0800 From: Zhen Lei To: Linus Walleij , David Airlie , Daniel Vetter , dri-devel Subject: [PATCH 1/1] drm/mcde: Remove redundant error printing in mcde_dsi_probe() Date: Tue, 11 May 2021 17:13:44 +0800 Message-ID: <20210511091344.4508-1-thunder.leizhen@huawei.com> X-Mailer: git-send-email 2.26.0.windows.1 MIME-Version: 1.0 X-Originating-IP: [10.174.177.72] X-CFilter-Loop: Reflected X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Zhen Lei Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" When devm_ioremap_resource() fails, a clear enough error message will be printed by its subfunction __devm_ioremap_resource(). The error information contains the device name, failure cause, and possibly resource information. Therefore, remove the error printing here to simplify code and reduce the binary size. Reported-by: Hulk Robot Signed-off-by: Zhen Lei --- drivers/gpu/drm/mcde/mcde_dsi.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) -- 2.26.0.106.g9fadedd diff --git a/drivers/gpu/drm/mcde/mcde_dsi.c b/drivers/gpu/drm/mcde/mcde_dsi.c index b3fd3501c412799..5aade1d13961ab7 100644 --- a/drivers/gpu/drm/mcde/mcde_dsi.c +++ b/drivers/gpu/drm/mcde/mcde_dsi.c @@ -1196,10 +1196,8 @@ static int mcde_dsi_probe(struct platform_device *pdev) res = platform_get_resource(pdev, IORESOURCE_MEM, 0); d->regs = devm_ioremap_resource(dev, res); - if (IS_ERR(d->regs)) { - dev_err(dev, "no DSI regs\n"); + if (IS_ERR(d->regs)) return PTR_ERR(d->regs); - } dsi_id = readl(d->regs + DSI_ID_REG); dev_info(dev, "HW revision 0x%08x\n", dsi_id);