hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/arch/arm/mach-sa1100/hackkit.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * linux/arch/arm/mach-sa1100/hackkit.c
34 *
....@@ -5,11 +6,6 @@
56 *
67 * This file contains all HackKit tweaks. Based on original work from
78 * Nicolas Pitre's assabet fixes
8
- *
9
- * This program is free software; you can redistribute it and/or modify
10
- * it under the terms of the GNU General Public License version 2 as
11
- * published by the Free Software Foundation.
12
- *
139 */
1410 #include <linux/init.h>
1511 #include <linux/kernel.h>
....@@ -26,11 +22,11 @@
2622 #include <linux/gpio.h>
2723 #include <linux/leds.h>
2824 #include <linux/platform_device.h>
25
+#include <linux/pgtable.h>
2926
3027 #include <asm/mach-types.h>
3128 #include <asm/setup.h>
3229 #include <asm/page.h>
33
-#include <asm/pgtable.h>
3430
3531 #include <asm/mach/arch.h>
3632 #include <asm/mach/flash.h>
....@@ -49,8 +45,6 @@
4945 /* init funcs */
5046 static void __init hackkit_map_io(void);
5147
52
-static u_int hackkit_get_mctrl(struct uart_port *port);
53
-static void hackkit_set_mctrl(struct uart_port *port, u_int mctrl);
5448 static void hackkit_uart_pm(struct uart_port *port, u_int state, u_int oldstate);
5549
5650 /**********************************************************************
....@@ -71,8 +65,6 @@
7165 };
7266
7367 static struct sa1100_port_fns hackkit_port_fns __initdata = {
74
- .set_mctrl = hackkit_set_mctrl,
75
- .get_mctrl = hackkit_get_mctrl,
7668 .pm = hackkit_uart_pm,
7769 };
7870
....@@ -103,50 +95,6 @@
10395 static void hackkit_uart_pm(struct uart_port *port, u_int state, u_int oldstate)
10496 {
10597 /* TODO: switch on/off uart in powersave mode */
106
-}
107
-
108
-/*
109
- * Note! this can be called from IRQ context.
110
- * FIXME: No modem ctrl lines yet.
111
- */
112
-static void hackkit_set_mctrl(struct uart_port *port, u_int mctrl)
113
-{
114
-#if 0
115
- if (port->mapbase == _Ser1UTCR0) {
116
- u_int set = 0, clear = 0;
117
-
118
- if (mctrl & TIOCM_RTS)
119
- set |= PT_CTRL2_RS1_RTS;
120
- else
121
- clear |= PT_CTRL2_RS1_RTS;
122
-
123
- if (mctrl & TIOCM_DTR)
124
- set |= PT_CTRL2_RS1_DTR;
125
- else
126
- clear |= PT_CTRL2_RS1_DTR;
127
-
128
- PTCTRL2_clear(clear);
129
- PTCTRL2_set(set);
130
- }
131
-#endif
132
-}
133
-
134
-static u_int hackkit_get_mctrl(struct uart_port *port)
135
-{
136
- u_int ret = 0;
137
-#if 0
138
- u_int irqsr = PT_IRQSR;
139
-
140
- /* need 2 reads to read current value */
141
- irqsr = PT_IRQSR;
142
-
143
- /* TODO: check IRQ source register for modem/com
144
- status lines and set them correctly. */
145
-#endif
146
-
147
- ret = TIOCM_CD | TIOCM_CTS | TIOCM_DSR;
148
-
149
- return ret;
15098 }
15199
152100 static struct mtd_partition hackkit_partitions[] = {