hc
2023-12-09 b22da3d8526a935aa31e086e63f60ff3246cb61c
kernel/drivers/video/fbdev/mmp/hw/mmp_spi.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0-or-later
12 /*
23 * linux/drivers/video/mmp/hw/mmp_spi.c
34 * using the spi in LCD controler for commands send
....@@ -6,20 +7,6 @@
67 * Authors: Guoqing Li <ligq@marvell.com>
78 * Lisa Du <cldu@marvell.com>
89 * Zhou Zhu <zzhu3@marvell.com>
9
- *
10
- * This program is free software; you can redistribute it and/or modify it
11
- * under the terms of the GNU General Public License as published by the
12
- * Free Software Foundation; either version 2 of the License, or (at your
13
- * option) any later version.
14
- *
15
- * This program is distributed in the hope that it will be useful, but WITHOUT
16
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
17
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
18
- * more details.
19
- *
20
- * You should have received a copy of the GNU General Public License along with
21
- * this program. If not, see <http://www.gnu.org/licenses/>.
22
- *
2310 */
2411 #include <linux/errno.h>
2512 #include <linux/delay.h>
....@@ -44,7 +31,7 @@
4431 {
4532 int timeout = 100000, isr, ret = 0;
4633 u32 tmp;
47
- void *reg_base =
34
+ void __iomem *reg_base = (void __iomem *)
4835 *(void **)spi_master_get_devdata(spi->master);
4936
5037 /* clear ISR */
....@@ -93,7 +80,7 @@
9380
9481 static int lcd_spi_setup(struct spi_device *spi)
9582 {
96
- void *reg_base =
83
+ void __iomem *reg_base = (void __iomem *)
9784 *(void **)spi_master_get_devdata(spi->master);
9885 u32 tmp;
9986
....@@ -159,7 +146,7 @@
159146 return -ENOMEM;
160147 }
161148 p_regbase = spi_master_get_devdata(master);
162
- *p_regbase = ctrl->reg_base;
149
+ *p_regbase = (void __force *)ctrl->reg_base;
163150
164151 /* set bus num to 5 to avoid conflict with other spi hosts */
165152 master->bus_num = 5;