Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp323508pxb; Tue, 31 Aug 2021 23:01:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzEOTv3xMjP8q31KJBXFxnAiT36+pu8j//aeeVgsgMC4ktQN9MHdFqy0D+5wDPjkKInLsjk X-Received: by 2002:a17:906:84d0:: with SMTP id f16mr34474167ejy.6.1630476068301; Tue, 31 Aug 2021 23:01:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1630476068; cv=none; d=google.com; s=arc-20160816; b=pgTKTEOfCmPooiFvbfzhXl4UOVBzXTiVT3t2nkJmO/e3u784M4w7dAR6IdNtQk88MI 6iZ8PB9CuIxa1AypvmyzuT6m4mNaYerNTmF2Nq8bM56Yu1Ks0E/DiG31nDNv/eNaN5g3 GDfMzVb8J+lkuJ9QacMz0GHpYGXoYiSVXx1BFkVA+tKbEw2LvSCp4kdyKDi4pRO6/mnH m/0IeQ+WiY4YlzYFAasAOaJjHEjL+7zS4SYSNKPDzu7xSm+jX0onGOzsi2lNyIzYDTvx 2B7NBptMskZzu27uFCwNBTyxI1cOtVGJJ3/HJAkRgg+tYcTtqloHDZsqLhAjmRS4v5CV 7RIQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=3EM8/zHxqknUn04pp7PjDaxI8wuH98gep+xoIlO4Yfg=; b=0SN+w3YvOP74DXjwlHjskdm8GbYN1UowpP/WmoBmNhmMeseOEBWT3dLz5ZGisgMrB0 HKjw1Gj2qvHTclC+iIPQ4BU6wQCX3RexnWj+K6I0baaqpkegBOfKtkSSHiI/lKoGhAx+ 0HX6z+Zfftaq8X15H4UrVfxcJGH+4kc39GcI9KNacrwXwTA9LrjfczWwpYyyppj8+2dK IDuNnxFx8tsMr7HPt2L//nIHW6HV0SUDqisck/Y+iVvY47zEV65EusSr6NRtK1ni5PIm VULKzdZvyIdzwWBgUbcjo+1eWuqz6MsoEINUPo9gl5dHGafhTKiRRg/RNe3x4DIDcmsB NnTw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a2si19644816edx.80.2021.08.31.23.00.32; Tue, 31 Aug 2021 23:01:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242493AbhIAF6W (ORCPT + 99 others); Wed, 1 Sep 2021 01:58:22 -0400 Received: from mx20.baidu.com ([111.202.115.85]:54508 "EHLO baidu.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S242473AbhIAF6U (ORCPT ); Wed, 1 Sep 2021 01:58:20 -0400 Received: from BC-Mail-Ex16.internal.baidu.com (unknown [172.31.51.56]) by Forcepoint Email with ESMTPS id CBC6A6061240D7193529; Wed, 1 Sep 2021 13:57:22 +0800 (CST) Received: from BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) by BC-Mail-Ex16.internal.baidu.com (172.31.51.56) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2242.12; Wed, 1 Sep 2021 13:57:22 +0800 Received: from LAPTOP-UKSR4ENP.internal.baidu.com (172.31.63.8) by BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2308.14; Wed, 1 Sep 2021 13:57:22 +0800 From: Cai Huoqing To: CC: Hyun Kwon , Laurent Pinchart , Mauro Carvalho Chehab , Michal Simek , , , Subject: [PATCH] media: xilinx: Make use of the helper function devm_platform_ioremap_resource() Date: Wed, 1 Sep 2021 13:57:15 +0800 Message-ID: <20210901055716.8129-1-caihuoqing@baidu.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [172.31.63.8] X-ClientProxiedBy: BJHW-Mail-Ex11.internal.baidu.com (10.127.64.34) To BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Use the devm_platform_ioremap_resource() helper instead of calling platform_get_resource() and devm_ioremap_resource() separately Signed-off-by: Cai Huoqing --- drivers/media/platform/xilinx/xilinx-vip.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/media/platform/xilinx/xilinx-vip.c b/drivers/media/platform/xilinx/xilinx-vip.c index 425a32dd5d19..a0073122798f 100644 --- a/drivers/media/platform/xilinx/xilinx-vip.c +++ b/drivers/media/platform/xilinx/xilinx-vip.c @@ -205,10 +205,8 @@ EXPORT_SYMBOL_GPL(xvip_clr_and_set); int xvip_init_resources(struct xvip_device *xvip) { struct platform_device *pdev = to_platform_device(xvip->dev); - struct resource *res; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - xvip->iomem = devm_ioremap_resource(xvip->dev, res); + xvip->iomem = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(xvip->iomem)) return PTR_ERR(xvip->iomem); -- 2.25.1