Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp7334029rwl; Thu, 23 Mar 2023 02:57:13 -0700 (PDT) X-Google-Smtp-Source: AK7set/fIk8n4DQfHy84a2meL5fNjefgtaShw2vs2wQA7mLL+I1Jq+Ffe9OECfzdgGNjNKGBG41g X-Received: by 2002:a17:907:7647:b0:932:2874:cc5 with SMTP id kj7-20020a170907764700b0093228740cc5mr10824328ejc.16.1679565433623; Thu, 23 Mar 2023 02:57:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679565433; cv=none; d=google.com; s=arc-20160816; b=preO6CpKxVm7YBM8V/vRJv5tI53dgqKML5Zqn18MEP+YA3Ii8Fuq4LWMtj4wu6G51u Z0vZnPQ2a06LcWkmBqwgVJplZ7DeRc5Avd+icq5yHwunBY36jhrevzQNli/KGEiswlxv iyQze3oeX8QMNiTreZdzFrLf38EAb5SxxIYvoiD/vFqjfs6RaqRLsQvMtEv8EHC3WroT QtQMvSovjM6kfiaAVkKn9xoCgqTU8CtG/xV4Meoe9GDp4OHj4wUit5fA5RLeG/x/Kdad fOFRpHOPw/rb0o9ldM8nMQbetzKTbMhPBRoa/ZMeJdIdmN9Vv1Yzc5laBpHUul7luvCE ebxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=JrST9pOiJP1qTWCJ2RMKtkOzPVlYQfC2rv92iPuFLcs=; b=o+B1AhGJx19+jvuXBP6vMlSmX33bFA8AyDtj5d82PSWrH9+wpLSaazO7B3H02bpWqU r0SjNYHSSstmRqZjkRsZQHw4lOf0+i6gCSXBkSB6lP1SNbseNW0TgslpspNNL+DJFM14 x1XHHmSVy6tSqZb42U9gti18eWuK0W/oZEriTLCYOLRV4unTwmUH0EBbWE8yQaUxH1VE vYOF+uSxoDCPuEK37MCsv3/3fiLtpFgaAzrY1Dxfyk9+mzmHgqqY7G1LFRg5Iv5tDj5z gFDbj8DYvt/gF8BKAhR/wg7VYojye8uQra+d1R1bSJn2HXsb3LYFoW/z0Qbc0LOlq42f juUA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id re12-20020a170907a2cc00b00938b5232a1dsi8502490ejc.854.2023.03.23.02.56.49; Thu, 23 Mar 2023 02:57:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229996AbjCWJ4D (ORCPT + 99 others); Thu, 23 Mar 2023 05:56:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50258 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229976AbjCWJzb (ORCPT ); Thu, 23 Mar 2023 05:55:31 -0400 Received: from hust.edu.cn (unknown [202.114.0.240]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A429614215; Thu, 23 Mar 2023 02:54:06 -0700 (PDT) Received: from localhost.localdomain ([172.16.0.254]) (user=mx_xiang@hust.edu.cn mech=LOGIN bits=0) by mx1.hust.edu.cn with ESMTP id 32N9rDdw000357-32N9rDdx000357 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Thu, 23 Mar 2023 17:53:17 +0800 From: Mingxuan Xiang To: Thinh Nguyen , Greg Kroah-Hartman Cc: hust-os-kernel-patches@googlegroups.com, Dongliang Mu , Mingxuan Xiang , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2] usb: dwc3: host: remove dead code in dwc3_host_get_irq() Date: Thu, 23 Mar 2023 17:53:10 +0800 Message-Id: <20230323095311.1266655-1-mx_xiang@hust.edu.cn> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-FEAS-AUTH-USER: mx_xiang@hust.edu.cn X-Spam-Status: No, score=-0.0 required=5.0 tests=SPF_HELO_PASS,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org platform_get_irq() no longer returns 0, so there is no need to check whether the return value is 0. Signed-off-by: Mingxuan Xiang --- v1->v2: remove redundant goto drivers/usb/dwc3/host.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/drivers/usb/dwc3/host.c b/drivers/usb/dwc3/host.c index f6f13e7f1ba1..ca1e8294e835 100644 --- a/drivers/usb/dwc3/host.c +++ b/drivers/usb/dwc3/host.c @@ -54,12 +54,8 @@ static int dwc3_host_get_irq(struct dwc3 *dwc) irq = platform_get_irq(dwc3_pdev, 0); if (irq > 0) { dwc3_host_fill_xhci_irq_res(dwc, irq, NULL); - goto out; } - if (!irq) - irq = -EINVAL; - out: return irq; } -- 2.39.2