hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/drivers/char/xillybus/xillybus_of.c
....@@ -1,13 +1,10 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * linux/drivers/misc/xillybus_of.c
34 *
45 * Copyright 2011 Xillybus Ltd, http://xillybus.com
56 *
67 * Driver for the Xillybus FPGA/host framework using Open Firmware.
7
- *
8
- * This program is free software; you can redistribute it and/or modify
9
- * it under the smems of the GNU General Public License as published by
10
- * the Free Software Foundation; version 2 of the License.
118 */
129
1310 #include <linux/module.h>
....@@ -119,7 +116,6 @@
119116 struct xilly_endpoint *endpoint;
120117 int rc;
121118 int irq;
122
- struct resource *res;
123119 struct xilly_endpoint_hardware *ephw = &of_hw;
124120
125121 if (of_property_read_bool(dev->of_node, "dma-coherent"))
....@@ -132,9 +128,7 @@
132128
133129 dev_set_drvdata(dev, endpoint);
134130
135
- res = platform_get_resource(op, IORESOURCE_MEM, 0);
136
- endpoint->registers = devm_ioremap_resource(dev, res);
137
-
131
+ endpoint->registers = devm_platform_ioremap_resource(op, 0);
138132 if (IS_ERR(endpoint->registers))
139133 return PTR_ERR(endpoint->registers);
140134