Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp784541ybe; Thu, 5 Sep 2019 06:02:12 -0700 (PDT) X-Google-Smtp-Source: APXvYqxynZASOuJHv4/06mkfeXy68K65X3m6p3RdI3P8oJbHbAdg+2PN80dJ+OltqgrMvG4fOuCK X-Received: by 2002:a65:68cd:: with SMTP id k13mr3009832pgt.411.1567688531743; Thu, 05 Sep 2019 06:02:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567688531; cv=none; d=google.com; s=arc-20160816; b=MxL7wXD52Wcn0yYaNL+hPw4J1bfNfXu4rBVp2UiHTK6/I2BZteJJsQ49cuBK4bTCYj bBRcSne4eXCeKN7z++X9sb91CDxzfKzNdaqGZhaZpnPrce3t1aId2Jfu8vKLOD9AEOCQ nhOxVs1oH2930nCaVu5j3YgdFSe5YQZbwS5bbL19TVl8ePk9Pu+0NLiqaQ96U6kil9QZ /MJaAwMG42ctCHM7avH5dVyITDRpPRIulsfaj/JiQGrOP+uRimhYTLvT8uWSH4kKz8SH wLiODTmfI70gP58wcEyhnpDBzGfQKLJnI8O6vcYV8um32jWxo7k6VgNFKL3Eq540FLrm 0efw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:message-id:in-reply-to:date:references:subject:cc:to :from; bh=Sp5ppc2VRfnpuidPN3hw77+gJXlyEFL2tMhgHmZA7ls=; b=IhdT2QN1tvs0PDhkt+mR4uIt+b967KAYEzVZhW0Ss2U445BIR1crhEMTTLH8vNT130 8sUfxyLcqV9LJ+LNpdiKqOC0EOaPB93rw34DxU39iwRfTi+iEaozacH84liD5pjZ2aIN h7B+yxkVN4G1He+XvvKJUBTVLt2vYM01vGAxZ1Wdk/dRz13ltKSAksor5PAe6DpyWyZu cFUNWAYxxSBHJoo26w9Qb7Qfb30RRgkPogmatvnkZapbJ5oqkRUxa35+U/GyW8jhL6CJ OJy0ssbi8aEGDVkkloZviaFPIwDscljq6f3zDd1PQQJA7CBHO4FV7GO3atW5HSmure10 F0ng== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j25si2081640pfi.264.2019.09.05.06.01.48; Thu, 05 Sep 2019 06:02:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388202AbfIELG5 convert rfc822-to-8bit (ORCPT + 99 others); Thu, 5 Sep 2019 07:06:57 -0400 Received: from unicorn.mansr.com ([81.2.72.234]:59326 "EHLO unicorn.mansr.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1733182AbfIELG4 (ORCPT ); Thu, 5 Sep 2019 07:06:56 -0400 Received: by unicorn.mansr.com (Postfix, from userid 51770) id B3B4B17FE3; Thu, 5 Sep 2019 12:06:54 +0100 (BST) From: =?iso-8859-1?Q?M=E5ns_Rullg=E5rd?= To: YueHaibing Cc: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , Subject: Re: [PATCH -next 12/15] thermal: tango: use devm_platform_ioremap_resource() to simplify code References: <20190904122939.23780-1-yuehaibing@huawei.com> <20190904122939.23780-13-yuehaibing@huawei.com> Date: Thu, 05 Sep 2019 12:06:54 +0100 In-Reply-To: <20190904122939.23780-13-yuehaibing@huawei.com> (yuehaibing@huawei.com's message of "Wed, 4 Sep 2019 20:29:36 +0800") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org YueHaibing writes: > Use devm_platform_ioremap_resource() to simplify the code a bit. > This is detected by coccinelle. > > Reported-by: Hulk Robot > Signed-off-by: YueHaibing Acked-by: Mans Rullgard > --- > drivers/thermal/tango_thermal.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/drivers/thermal/tango_thermal.c b/drivers/thermal/tango_thermal.c > index 304b461..f44441b 100644 > --- a/drivers/thermal/tango_thermal.c > +++ b/drivers/thermal/tango_thermal.c > @@ -73,7 +73,6 @@ static void tango_thermal_init(struct tango_thermal_priv *priv) > > static int tango_thermal_probe(struct platform_device *pdev) > { > - struct resource *res; > struct tango_thermal_priv *priv; > struct thermal_zone_device *tzdev; > > @@ -81,8 +80,7 @@ static int tango_thermal_probe(struct platform_device *pdev) > if (!priv) > return -ENOMEM; > > - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); > - priv->base = devm_ioremap_resource(&pdev->dev, res); > + priv->base = devm_platform_ioremap_resource(pdev, 0); > if (IS_ERR(priv->base)) > return PTR_ERR(priv->base); > > -- > 2.7.4 > -- M?ns Rullg?rd