Input: tegra-kbc - use devm_platform_ioremap_resource
authorMartin Kaiser <martin@kaiser.cx>
Sun, 9 Jul 2023 13:41:08 +0000 (15:41 +0200)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Mon, 10 Jul 2023 19:00:03 +0000 (12:00 -0700)
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>
Acked-by: Thierry Reding <treding@nvidia.com>
Link: https://lore.kernel.org/r/20230709134109.182418-1-martin@kaiser.cx
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
drivers/input/keyboard/tegra-kbc.c

index d5a6c7d8eb25d0f57f40096dabc707fb01105c50..c9a823ea45d02965275f44318a7e8c5af3790887 100644 (file)
@@ -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);