hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/drivers/pinctrl/pinctrl-digicolor.c
....@@ -1,14 +1,10 @@
1
+// SPDX-License-Identifier: GPL-2.0-or-later
12 /*
23 * Driver for Conexant Digicolor General Purpose Pin Mapping
34 *
45 * Author: Baruch Siach <baruch@tkos.co.il>
56 *
67 * Copyright (C) 2015 Paradox Innovation Ltd.
7
- *
8
- * This program is free software; you can redistribute it and/or modify
9
- * it under the terms of the GNU General Public License as published by
10
- * the Free Software Foundation; either version 2 of the License, or
11
- * (at your option) any later version.
128 *
139 * TODO:
1410 * - GPIO interrupt support
....@@ -20,7 +16,6 @@
2016 #include <linux/of.h>
2117 #include <linux/of_device.h>
2218 #include <linux/io.h>
23
-#include <linux/gpio.h>
2419 #include <linux/gpio/driver.h>
2520 #include <linux/spinlock.h>
2621 #include <linux/pinctrl/machine.h>
....@@ -275,7 +270,6 @@
275270 static int dc_pinctrl_probe(struct platform_device *pdev)
276271 {
277272 struct dc_pinmap *pmap;
278
- struct resource *r;
279273 struct pinctrl_pin_desc *pins;
280274 struct pinctrl_desc *pctl_desc;
281275 char *pin_names;
....@@ -286,8 +280,7 @@
286280 if (!pmap)
287281 return -ENOMEM;
288282
289
- r = platform_get_resource(pdev, IORESOURCE_MEM, 0);
290
- pmap->regs = devm_ioremap_resource(&pdev->dev, r);
283
+ pmap->regs = devm_platform_ioremap_resource(pdev, 0);
291284 if (IS_ERR(pmap->regs))
292285 return PTR_ERR(pmap->regs);
293286