From patchwork Wed Jul 22 07:51:12 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?Q2h1bmZlbmcgWXVuICjkupHmmKXls7Ap?= X-Patchwork-Id: 11677651 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 9BB2113A4 for ; Wed, 22 Jul 2020 07:53:04 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 79FD7207DD for ; Wed, 22 Jul 2020 07:53:04 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=mediatek.com header.i=@mediatek.com header.b="dPOjE8IF" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728283AbgGVHxD (ORCPT ); Wed, 22 Jul 2020 03:53:03 -0400 Received: from Mailgw01.mediatek.com ([1.203.163.78]:23115 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1726821AbgGVHws (ORCPT ); Wed, 22 Jul 2020 03:52:48 -0400 X-UUID: bd70cc3ec72941578030385d60c997ba-20200722 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=cfYm60Altq9Wqji4CsoqqXRvsmV3rfZV2KW7eN4V7sM=; b=dPOjE8IFfuE30mdLcjqGG+DjwiaOmJciHFltBQiqd3tRO4zzkOrYVYu1fFbJD+iTYeKRFoZ0BO6Nm6cXvz9oqIyAEDrCoKRSgD9yl2wqXsgWfTJCq9eyMBwZtv0LZ+AZaXZssC11sc7uIWhj1leU+Uj9Eb33/K1RGbVXfT3nUIw=; X-UUID: bd70cc3ec72941578030385d60c997ba-20200722 Received: from mtkcas32.mediatek.inc [(172.27.4.253)] by mailgw01.mediatek.com (envelope-from ) (mailgw01.mediatek.com ESMTP with TLS) with ESMTP id 305168531; Wed, 22 Jul 2020 15:52:40 +0800 Received: from mtkcas08.mediatek.inc (172.21.101.126) by MTKMBS31DR.mediatek.inc (172.27.6.102) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Wed, 22 Jul 2020 15:52:38 +0800 Received: from localhost.localdomain (10.17.3.153) by mtkcas08.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Wed, 22 Jul 2020 15:52:37 +0800 From: Chunfeng Yun To: Felipe Balbi , Greg Kroah-Hartman CC: Matthias Brugger , Chunfeng Yun , , , , , Patrice Chotard Subject: [PATCH 4/7] usb: dwc3: convert to devm_platform_ioremap_resource_byname Date: Wed, 22 Jul 2020 15:51:12 +0800 Message-ID: <1595404275-8449-4-git-send-email-chunfeng.yun@mediatek.com> X-Mailer: git-send-email 1.8.1.1.dirty In-Reply-To: <1595404275-8449-1-git-send-email-chunfeng.yun@mediatek.com> References: <1595404275-8449-1-git-send-email-chunfeng.yun@mediatek.com> MIME-Version: 1.0 X-TM-SNTS-SMTP: 476947B2B4033799B8766523F97A3126D70D8C4018667E0F265131D97B0086FE2000:8 X-MTK: N Sender: linux-usb-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org Use devm_platform_ioremap_resource_byname() to simplify code Cc: Patrice Chotard Signed-off-by: Chunfeng Yun Reviewed-by: Patrice Chotard --- drivers/usb/dwc3/dwc3-st.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/dwc3/dwc3-st.c b/drivers/usb/dwc3/dwc3-st.c index c682420..e733be8 100644 --- a/drivers/usb/dwc3/dwc3-st.c +++ b/drivers/usb/dwc3/dwc3-st.c @@ -206,8 +206,8 @@ static int st_dwc3_probe(struct platform_device *pdev) if (!dwc3_data) return -ENOMEM; - res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "reg-glue"); - dwc3_data->glue_base = devm_ioremap_resource(dev, res); + dwc3_data->glue_base = + devm_platform_ioremap_resource_byname(pdev, "reg-glue"); if (IS_ERR(dwc3_data->glue_base)) return PTR_ERR(dwc3_data->glue_base);