From patchwork Tue Aug 1 12:28:34 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: wangzhu X-Patchwork-Id: 13336640 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C68FDC001E0 for ; Tue, 1 Aug 2023 12:29:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232392AbjHAM3L (ORCPT ); Tue, 1 Aug 2023 08:29:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38024 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231737AbjHAM3K (ORCPT ); Tue, 1 Aug 2023 08:29:10 -0400 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 023DE10C7 for ; Tue, 1 Aug 2023 05:29:08 -0700 (PDT) Received: from dggpeml500025.china.huawei.com (unknown [172.30.72.57]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4RFZB23DB2zVjpT; Tue, 1 Aug 2023 20:27:22 +0800 (CST) Received: from ubuntu1804.huawei.com (10.67.174.202) by dggpeml500025.china.huawei.com (7.185.36.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.27; Tue, 1 Aug 2023 20:29:05 +0800 From: Zhu Wang To: , , , , , , , CC: Subject: [PATCH -next] usb: typec: tcpci_mt6370: remove redundant dev_err_probe() Date: Tue, 1 Aug 2023 20:28:34 +0800 Message-ID: <20230801122834.89168-1-wangzhu9@huawei.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-Originating-IP: [10.67.174.202] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To dggpeml500025.china.huawei.com (7.185.36.35) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org When platform_get_irq() is called, the error message has been printed, so it need not to call dev_err_probe() to present error messages. Signed-off-by: Zhu Wang Reviewed-by: AngeloGioacchino Del Regno Reviewed-by: Guenter Roeck Acked-by: Heikki Krogerus --- drivers/usb/typec/tcpm/tcpci_mt6370.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/typec/tcpm/tcpci_mt6370.c b/drivers/usb/typec/tcpm/tcpci_mt6370.c index 2a079464b398..9cda1005ef01 100644 --- a/drivers/usb/typec/tcpm/tcpci_mt6370.c +++ b/drivers/usb/typec/tcpm/tcpci_mt6370.c @@ -147,7 +147,7 @@ static int mt6370_tcpc_probe(struct platform_device *pdev) irq = platform_get_irq(pdev, 0); if (irq < 0) - return dev_err_probe(dev, irq, "Failed to get irq\n"); + return irq; /* Assign TCPCI feature and ops */ priv->tcpci_data.auto_discharge_disconnect = 1;