mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Michal Simek <michal.simek@amd.com>
To: Yangtao Li <frank.li@vivo.com>,
	Appana Durga Kedareswara rao 
	<appana.durga.kedareswara.rao@amd.com>,
	Arnd Bergmann <arnd@arndb.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/3] misc: xilinx_tmr_manager: Use devm_platform_get_and_ioremap_resource()
Date: Fri, 7 Jul 2023 08:21:07 +0200	[thread overview]
Message-ID: <64347d8a-4427-6c0e-3164-e879a028e4b0@amd.com> (raw)
In-Reply-To: <20230707024224.78907-3-frank.li@vivo.com>



On 7/7/23 04:42, Yangtao Li wrote:
> 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: Yangtao Li <frank.li@vivo.com>
> ---
>   drivers/misc/xilinx_tmr_manager.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/misc/xilinx_tmr_manager.c b/drivers/misc/xilinx_tmr_manager.c
> index 0ef55e06d3a0..2e7a5f37a01f 100644
> --- a/drivers/misc/xilinx_tmr_manager.c
> +++ b/drivers/misc/xilinx_tmr_manager.c
> @@ -170,8 +170,7 @@ static int xtmr_manager_probe(struct platform_device *pdev)
>   	if (!xtmr_manager)
>   		return -ENOMEM;
>   
> -	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	xtmr_manager->regs =  devm_ioremap_resource(&pdev->dev, res);
> +	xtmr_manager->regs = devm_platform_get_and_ioremap_resource(pdev, 0, &res);
>   	if (IS_ERR(xtmr_manager->regs))
>   		return PTR_ERR(xtmr_manager->regs);
>   

Reviewed-by: Michal Simek <michal.simek@amd.com>

Thanks,
M

      reply	other threads:[~2023-07-07  6:21 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-07  2:42 [PATCH 1/3] misc: atmel-ssc: " Yangtao Li
2023-07-07  2:42 ` [PATCH 2/3] misc/xilinx_sdfec: Convert to devm_platform_ioremap_resource() Yangtao Li
2023-07-07  6:21   ` Michal Simek
2023-07-07  2:42 ` [PATCH 3/3] misc: xilinx_tmr_manager: Use devm_platform_get_and_ioremap_resource() Yangtao Li
2023-07-07  6:21   ` Michal Simek [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=64347d8a-4427-6c0e-3164-e879a028e4b0@amd.com \
    --to=michal.simek@amd.com \
    --cc=appana.durga.kedareswara.rao@amd.com \
    --cc=arnd@arndb.de \
    --cc=frank.li@vivo.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®