* [PATCH] Input: tegra-kbc - use devm_platform_ioremap_resource
@ 2023-07-09 13:41 Martin Kaiser
2023-07-10 13:11 ` Thierry Reding
2023-07-10 19:08 ` Dmitry Torokhov
0 siblings, 2 replies; 3+ messages in thread
From: Martin Kaiser @ 2023-07-09 13:41 UTC (permalink / raw)
To: Laxman Dewangan, Dmitry Torokhov, Thierry Reding, Jonathan Hunter
Cc: Martin Kaiser, linux-input, linux-tegra, linux-kernel
devm_platform_get_and_ioremap_resource maps a resource and returns its
physical address. If we don't need the physical address, we should call
devm_platform_ioremap_resource instead.
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
---
drivers/input/keyboard/tegra-kbc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/input/keyboard/tegra-kbc.c b/drivers/input/keyboard/tegra-kbc.c
index d5a6c7d8eb25..c9a823ea45d0 100644
--- a/drivers/input/keyboard/tegra-kbc.c
+++ b/drivers/input/keyboard/tegra-kbc.c
@@ -640,7 +640,7 @@ static int tegra_kbc_probe(struct platform_device *pdev)
timer_setup(&kbc->timer, tegra_kbc_keypress_timer, 0);
- kbc->mmio = devm_platform_get_and_ioremap_resource(pdev, 0, NULL);
+ kbc->mmio = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(kbc->mmio))
return PTR_ERR(kbc->mmio);
--
2.30.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] Input: tegra-kbc - use devm_platform_ioremap_resource
2023-07-09 13:41 [PATCH] Input: tegra-kbc - use devm_platform_ioremap_resource Martin Kaiser
@ 2023-07-10 13:11 ` Thierry Reding
2023-07-10 19:08 ` Dmitry Torokhov
1 sibling, 0 replies; 3+ messages in thread
From: Thierry Reding @ 2023-07-10 13:11 UTC (permalink / raw)
To: Martin Kaiser
Cc: Laxman Dewangan, Dmitry Torokhov, Jonathan Hunter, linux-input,
linux-tegra, linux-kernel
[-- Attachment #1: Type: text/plain, Size: 1241 bytes --]
On Sun, Jul 09, 2023 at 03:41:08PM +0200, Martin Kaiser wrote:
> devm_platform_get_and_ioremap_resource maps a resource and returns its
> physical address. If we don't need the physical address, we should call
> devm_platform_ioremap_resource instead.
>
> Signed-off-by: Martin Kaiser <martin@kaiser.cx>
> ---
> drivers/input/keyboard/tegra-kbc.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Different variations of these have been going around for a while now. I
don't really see much use in these tiny conversions.
But the patch also isn't wrong, so while I'm at it:
Acked-by: Thierry Reding <treding@nvidia.com>
>
> diff --git a/drivers/input/keyboard/tegra-kbc.c b/drivers/input/keyboard/tegra-kbc.c
> index d5a6c7d8eb25..c9a823ea45d0 100644
> --- a/drivers/input/keyboard/tegra-kbc.c
> +++ b/drivers/input/keyboard/tegra-kbc.c
> @@ -640,7 +640,7 @@ static int tegra_kbc_probe(struct platform_device *pdev)
>
> timer_setup(&kbc->timer, tegra_kbc_keypress_timer, 0);
>
> - kbc->mmio = devm_platform_get_and_ioremap_resource(pdev, 0, NULL);
> + kbc->mmio = devm_platform_ioremap_resource(pdev, 0);
> if (IS_ERR(kbc->mmio))
> return PTR_ERR(kbc->mmio);
>
> --
> 2.30.2
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Input: tegra-kbc - use devm_platform_ioremap_resource
2023-07-09 13:41 [PATCH] Input: tegra-kbc - use devm_platform_ioremap_resource Martin Kaiser
2023-07-10 13:11 ` Thierry Reding
@ 2023-07-10 19:08 ` Dmitry Torokhov
1 sibling, 0 replies; 3+ messages in thread
From: Dmitry Torokhov @ 2023-07-10 19:08 UTC (permalink / raw)
To: Martin Kaiser
Cc: Laxman Dewangan, Thierry Reding, Jonathan Hunter, linux-input,
linux-tegra, linux-kernel
On Sun, Jul 09, 2023 at 03:41:08PM +0200, Martin Kaiser wrote:
> devm_platform_get_and_ioremap_resource maps a resource and returns its
> physical address. If we don't need the physical address, we should call
> devm_platform_ioremap_resource instead.
>
> Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Applied, thank you.
--
Dmitry
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-07-10 19:09 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-09 13:41 [PATCH] Input: tegra-kbc - use devm_platform_ioremap_resource Martin Kaiser
2023-07-10 13:11 ` Thierry Reding
2023-07-10 19:08 ` Dmitry Torokhov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).