hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/drivers/gpio/gpio-timberdale.c
....@@ -1,20 +1,8 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Timberdale FPGA GPIO driver
34 * Author: Mocean Laboratories
45 * Copyright (c) 2009 Intel Corporation
5
- *
6
- * This program is free software; you can redistribute it and/or modify
7
- * it under the terms of the GNU General Public License version 2 as
8
- * published by the Free Software Foundation.
9
- *
10
- * This program is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
- * GNU General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU General Public License
16
- * along with this program; if not, write to the Free Software
17
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
186 */
197
208 /* Supports:
....@@ -229,7 +217,6 @@
229217 struct device *dev = &pdev->dev;
230218 struct gpio_chip *gc;
231219 struct timbgpio *tgpio;
232
- struct resource *iomem;
233220 struct timbgpio_platform_data *pdata = dev_get_platdata(&pdev->dev);
234221 int irq = platform_get_irq(pdev, 0);
235222
....@@ -246,8 +233,7 @@
246233
247234 spin_lock_init(&tgpio->lock);
248235
249
- iomem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
250
- tgpio->membase = devm_ioremap_resource(dev, iomem);
236
+ tgpio->membase = devm_platform_ioremap_resource(pdev, 0);
251237 if (IS_ERR(tgpio->membase))
252238 return PTR_ERR(tgpio->membase);
253239