Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp2410996rwl; Sun, 26 Mar 2023 22:56:50 -0700 (PDT) X-Google-Smtp-Source: AKy350bSsZubOYcfgdOctuv+NqZhejndxF9NAchMTKytdD8ry2GoF9d8qoCQ55+CPe9i4XcB3lPR X-Received: by 2002:a17:902:e80c:b0:19e:82aa:dc8a with SMTP id u12-20020a170902e80c00b0019e82aadc8amr13515437plg.22.1679896610097; Sun, 26 Mar 2023 22:56:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679896610; cv=none; d=google.com; s=arc-20160816; b=plz0FzQVDaWknyWTxvg3w03z+lHAlaSPreMwnD/utuuSabDNTgbWAZWJdirr+dRpbl JgGATTpd9C0DYB2YB/l7uKjztk6M6uv17+GWFg7IQ5JzSTIuV/PqCgbCCA8fMagtCd5/ 1FgNgr/EhwqMwhHbjfO+cjFn/rvR9/Q63WDK44HgujF1fYMdnSU4MMOM2m4XfzQ9yV5/ wFl0UFerUHZ+TFjYhTzaa4yFD6e9b10BMLKlav0vY6gT/PqR/L9vnBZuQevVThNOjGAb lWVKBgrP5j05TwKB2RmljO/56KYmFn6jLAZD+EbSU+rThKB34kB8RRbknFE0CIwdl1An Fr4w== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=xa1U/jOQQNuz1FiLBGOKV1RyR4wYHn44BJe6GwHKR0g=; b=iU36n7G644ZnEuXc2/IchtlfMppxGUnU8rRhkqfrs25p/lgK+BCYx331SuKwXNcax/ skOEA243/LNLENPzB8L0WchBjPMEdx3TLceoG4s9gFAoy0KdxdM3cHuP3NHWxe2cCK/J OR4oYgX0CgXAAtxYtsLU15Fz11EuyKyUL6WR7L4ZtdN4h+wni7UzDmOUTwdEPQ6rXhAx +mjuEZc/GU3tfGfskn9pVqFtLnWD9UnC3fBTnoFgqPN/Lq4x5dD/gQdOTKMrMuWhJpVZ nRr1DgtAtIP7ycU7chCTdqGIswZyR7C0hYC6YTDDLOwIreQBerZM+gfYUQyTji8MXiM5 9FZg== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id b10-20020a170903228a00b001a19cbd4fb9si28542396plh.244.2023.03.26.22.56.39; Sun, 26 Mar 2023 22:56:50 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232335AbjC0Fy3 (ORCPT + 99 others); Mon, 27 Mar 2023 01:54:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52302 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232267AbjC0FyM (ORCPT ); Mon, 27 Mar 2023 01:54:12 -0400 Received: from out30-131.freemail.mail.aliyun.com (out30-131.freemail.mail.aliyun.com [115.124.30.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0D4DB524C; Sun, 26 Mar 2023 22:53:53 -0700 (PDT) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R161e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018046051;MF=yang.lee@linux.alibaba.com;NM=1;PH=DS;RN=4;SR=0;TI=SMTPD_---0Veh3ZHc_1679896430; Received: from localhost(mailfrom:yang.lee@linux.alibaba.com fp:SMTPD_---0Veh3ZHc_1679896430) by smtp.aliyun-inc.com; Mon, 27 Mar 2023 13:53:51 +0800 From: Yang Li To: broonie@kernel.org Cc: linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org, Yang Li Subject: [PATCH -next 3/3] spi: pic32: Use devm_platform_get_and_ioremap_resource() Date: Mon, 27 Mar 2023 13:53:46 +0800 Message-Id: <20230327055346.76625-3-yang.lee@linux.alibaba.com> X-Mailer: git-send-email 2.20.1.7.g153144c In-Reply-To: <20230327055346.76625-1-yang.lee@linux.alibaba.com> References: <20230327055346.76625-1-yang.lee@linux.alibaba.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-8.0 required=5.0 tests=ENV_AND_HDR_SPF_MATCH, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, UNPARSEABLE_RELAY,USER_IN_DEF_SPF_WL 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 According to commit 890cc39a8799 ("drivers: provide devm_platform_get_and_ioremap_resource()"), convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: Yang Li --- drivers/spi/spi-pic32.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/spi/spi-pic32.c b/drivers/spi/spi-pic32.c index 8a02073a354d..f2af5e653f3d 100644 --- a/drivers/spi/spi-pic32.c +++ b/drivers/spi/spi-pic32.c @@ -710,8 +710,7 @@ static int pic32_spi_hw_probe(struct platform_device *pdev, struct resource *mem; int ret; - mem = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pic32s->regs = devm_ioremap_resource(&pdev->dev, mem); + pic32s->regs = devm_platform_get_and_ioremap_resource(pdev, 0, &mem); if (IS_ERR(pic32s->regs)) return PTR_ERR(pic32s->regs); -- 2.20.1.7.g153144c