diff options
Diffstat (limited to 'drivers/watchdog/lantiq_wdt.c')
| -rw-r--r-- | drivers/watchdog/lantiq_wdt.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/watchdog/lantiq_wdt.c b/drivers/watchdog/lantiq_wdt.c index 83da84d6074b..a273b97ebcb4 100644 --- a/drivers/watchdog/lantiq_wdt.c +++ b/drivers/watchdog/lantiq_wdt.c @@ -1,7 +1,5 @@ +// SPDX-License-Identifier: GPL-2.0-only /* - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 as published - * by the Free Software Foundation. * * Copyright (C) 2010 John Crispin <john@phrozen.org> * Copyright (C) 2017 Hauke Mehrtens <hauke@hauke-m.de> @@ -11,7 +9,8 @@ #include <linux/module.h> #include <linux/bitops.h> #include <linux/watchdog.h> -#include <linux/of_platform.h> +#include <linux/of.h> +#include <linux/platform_device.h> #include <linux/uaccess.h> #include <linux/clk.h> #include <linux/io.h> @@ -203,7 +202,6 @@ static int ltq_wdt_probe(struct platform_device *pdev) struct device *dev = &pdev->dev; struct ltq_wdt_priv *priv; struct watchdog_device *wdt; - struct resource *res; struct clk *clk; const struct ltq_wdt_hw *ltq_wdt_hw; int ret; @@ -213,8 +211,7 @@ static int ltq_wdt_probe(struct platform_device *pdev) if (!priv) return -ENOMEM; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - priv->membase = devm_ioremap_resource(dev, res); + priv->membase = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(priv->membase)) return PTR_ERR(priv->membase); |
