diff options
399 files changed, 13804 insertions, 8828 deletions
diff --git a/Documentation/DocBook/deviceiobook.tmpl b/Documentation/DocBook/deviceiobook.tmpl index 9ee6f3cbb414..60d6e0b81bd9 100644 --- a/Documentation/DocBook/deviceiobook.tmpl +++ b/Documentation/DocBook/deviceiobook.tmpl | |||
@@ -316,7 +316,7 @@ CPU B: spin_unlock_irqrestore(&dev_lock, flags) | |||
316 | 316 | ||
317 | <chapter id="pubfunctions"> | 317 | <chapter id="pubfunctions"> |
318 | <title>Public Functions Provided</title> | 318 | <title>Public Functions Provided</title> |
319 | !Iinclude/asm-x86/io_32.h | 319 | !Iarch/x86/include/asm/io_32.h |
320 | !Elib/iomap.c | 320 | !Elib/iomap.c |
321 | </chapter> | 321 | </chapter> |
322 | 322 | ||
diff --git a/Documentation/DocBook/kernel-api.tmpl b/Documentation/DocBook/kernel-api.tmpl index 9d0058e788e5..5818ff75786a 100644 --- a/Documentation/DocBook/kernel-api.tmpl +++ b/Documentation/DocBook/kernel-api.tmpl | |||
@@ -45,8 +45,8 @@ | |||
45 | </sect1> | 45 | </sect1> |
46 | 46 | ||
47 | <sect1><title>Atomic and pointer manipulation</title> | 47 | <sect1><title>Atomic and pointer manipulation</title> |
48 | !Iinclude/asm-x86/atomic_32.h | 48 | !Iarch/x86/include/asm/atomic_32.h |
49 | !Iinclude/asm-x86/unaligned.h | 49 | !Iarch/x86/include/asm/unaligned.h |
50 | </sect1> | 50 | </sect1> |
51 | 51 | ||
52 | <sect1><title>Delaying, scheduling, and timer routines</title> | 52 | <sect1><title>Delaying, scheduling, and timer routines</title> |
@@ -119,7 +119,7 @@ X!Ilib/string.c | |||
119 | !Elib/string.c | 119 | !Elib/string.c |
120 | </sect1> | 120 | </sect1> |
121 | <sect1><title>Bit Operations</title> | 121 | <sect1><title>Bit Operations</title> |
122 | !Iinclude/asm-x86/bitops.h | 122 | !Iarch/x86/include/asm/bitops.h |
123 | </sect1> | 123 | </sect1> |
124 | </chapter> | 124 | </chapter> |
125 | 125 | ||
@@ -155,7 +155,7 @@ X!Ilib/string.c | |||
155 | !Emm/slab.c | 155 | !Emm/slab.c |
156 | </sect1> | 156 | </sect1> |
157 | <sect1><title>User Space Memory Access</title> | 157 | <sect1><title>User Space Memory Access</title> |
158 | !Iinclude/asm-x86/uaccess_32.h | 158 | !Iarch/x86/include/asm/uaccess_32.h |
159 | !Earch/x86/lib/usercopy_32.c | 159 | !Earch/x86/lib/usercopy_32.c |
160 | </sect1> | 160 | </sect1> |
161 | <sect1><title>More Memory Management Functions</title> | 161 | <sect1><title>More Memory Management Functions</title> |
@@ -265,7 +265,7 @@ X!Earch/x86/kernel/mca_32.c | |||
265 | --> | 265 | --> |
266 | </sect2> | 266 | </sect2> |
267 | <sect2><title>MCA Bus DMA</title> | 267 | <sect2><title>MCA Bus DMA</title> |
268 | !Iinclude/asm-x86/mca_dma.h | 268 | !Iarch/x86/include/asm/mca_dma.h |
269 | </sect2> | 269 | </sect2> |
270 | </sect1> | 270 | </sect1> |
271 | </chapter> | 271 | </chapter> |
diff --git a/Documentation/DocBook/kernel-hacking.tmpl b/Documentation/DocBook/kernel-hacking.tmpl index ae15d55350ec..a50d6cd58573 100644 --- a/Documentation/DocBook/kernel-hacking.tmpl +++ b/Documentation/DocBook/kernel-hacking.tmpl | |||
@@ -1239,7 +1239,7 @@ static struct block_device_operations opt_fops = { | |||
1239 | </para> | 1239 | </para> |
1240 | 1240 | ||
1241 | <para> | 1241 | <para> |
1242 | <filename>include/asm-x86/delay_32.h:</filename> | 1242 | <filename>arch/x86/include/asm/delay.h:</filename> |
1243 | </para> | 1243 | </para> |
1244 | <programlisting> | 1244 | <programlisting> |
1245 | #define ndelay(n) (__builtin_constant_p(n) ? \ | 1245 | #define ndelay(n) (__builtin_constant_p(n) ? \ |
@@ -1265,7 +1265,7 @@ static struct block_device_operations opt_fops = { | |||
1265 | </programlisting> | 1265 | </programlisting> |
1266 | 1266 | ||
1267 | <para> | 1267 | <para> |
1268 | <filename>include/asm-x86/uaccess_32.h:</filename> | 1268 | <filename>arch/x86/include/asm/uaccess_32.h:</filename> |
1269 | </para> | 1269 | </para> |
1270 | 1270 | ||
1271 | <programlisting> | 1271 | <programlisting> |
diff --git a/Documentation/DocBook/mcabook.tmpl b/Documentation/DocBook/mcabook.tmpl index 529a53dc1389..499eddc2d079 100644 --- a/Documentation/DocBook/mcabook.tmpl +++ b/Documentation/DocBook/mcabook.tmpl | |||
@@ -101,7 +101,7 @@ | |||
101 | 101 | ||
102 | <chapter id="dmafunctions"> | 102 | <chapter id="dmafunctions"> |
103 | <title>DMA Functions Provided</title> | 103 | <title>DMA Functions Provided</title> |
104 | !Iinclude/asm-x86/mca_dma.h | 104 | !Iarch/x86/include/asm/mca_dma.h |
105 | </chapter> | 105 | </chapter> |
106 | 106 | ||
107 | </book> | 107 | </book> |
diff --git a/Documentation/hwmon/lm90 b/Documentation/hwmon/lm90 index e0d5206d1de3..0e8411710238 100644 --- a/Documentation/hwmon/lm90 +++ b/Documentation/hwmon/lm90 | |||
@@ -8,7 +8,7 @@ Supported chips: | |||
8 | Datasheet: Publicly available at the National Semiconductor website | 8 | Datasheet: Publicly available at the National Semiconductor website |
9 | http://www.national.com/pf/LM/LM90.html | 9 | http://www.national.com/pf/LM/LM90.html |
10 | * National Semiconductor LM89 | 10 | * National Semiconductor LM89 |
11 | Prefix: 'lm99' | 11 | Prefix: 'lm89' (no auto-detection) |
12 | Addresses scanned: I2C 0x4c and 0x4d | 12 | Addresses scanned: I2C 0x4c and 0x4d |
13 | Datasheet: Publicly available at the National Semiconductor website | 13 | Datasheet: Publicly available at the National Semiconductor website |
14 | http://www.national.com/mpf/LM/LM89.html | 14 | http://www.national.com/mpf/LM/LM89.html |
diff --git a/Documentation/input/elantech.txt b/Documentation/input/elantech.txt new file mode 100644 index 000000000000..a10c3b6ba7c4 --- /dev/null +++ b/Documentation/input/elantech.txt | |||
@@ -0,0 +1,405 @@ | |||
1 | Elantech Touchpad Driver | ||
2 | ======================== | ||
3 | |||
4 | Copyright (C) 2007-2008 Arjan Opmeer <arjan@opmeer.net> | ||
5 | |||
6 | Extra information for hardware version 1 found and | ||
7 | provided by Steve Havelka | ||
8 | |||
9 | Version 2 (EeePC) hardware support based on patches | ||
10 | received from Woody at Xandros and forwarded to me | ||
11 | by user StewieGriffin at the eeeuser.com forum | ||
12 | |||
13 | |||
14 | Contents | ||
15 | ~~~~~~~~ | ||
16 | |||
17 | 1. Introduction | ||
18 | 2. Extra knobs | ||
19 | 3. Hardware version 1 | ||
20 | 3.1 Registers | ||
21 | 3.2 Native relative mode 4 byte packet format | ||
22 | 3.3 Native absolute mode 4 byte packet format | ||
23 | 4. Hardware version 2 | ||
24 | 4.1 Registers | ||
25 | 4.2 Native absolute mode 6 byte packet format | ||
26 | 4.2.1 One finger touch | ||
27 | 4.2.2 Two finger touch | ||
28 | |||
29 | |||
30 | |||
31 | 1. Introduction | ||
32 | ~~~~~~~~~~~~ | ||
33 | |||
34 | Currently the Linux Elantech touchpad driver is aware of two different | ||
35 | hardware versions unimaginatively called version 1 and version 2. Version 1 | ||
36 | is found in "older" laptops and uses 4 bytes per packet. Version 2 seems to | ||
37 | be introduced with the EeePC and uses 6 bytes per packet. | ||
38 | |||
39 | The driver tries to support both hardware versions and should be compatible | ||
40 | with the Xorg Synaptics touchpad driver and its graphical configuration | ||
41 | utilities. | ||
42 | |||
43 | Additionally the operation of the touchpad can be altered by adjusting the | ||
44 | contents of some of its internal registers. These registers are represented | ||
45 | by the driver as sysfs entries under /sys/bus/serio/drivers/psmouse/serio? | ||
46 | that can be read from and written to. | ||
47 | |||
48 | Currently only the registers for hardware version 1 are somewhat understood. | ||
49 | Hardware version 2 seems to use some of the same registers but it is not | ||
50 | known whether the bits in the registers represent the same thing or might | ||
51 | have changed their meaning. | ||
52 | |||
53 | On top of that, some register settings have effect only when the touchpad is | ||
54 | in relative mode and not in absolute mode. As the Linux Elantech touchpad | ||
55 | driver always puts the hardware into absolute mode not all information | ||
56 | mentioned below can be used immediately. But because there is no freely | ||
57 | available Elantech documentation the information is provided here anyway for | ||
58 | completeness sake. | ||
59 | |||
60 | |||
61 | ///////////////////////////////////////////////////////////////////////////// | ||
62 | |||
63 | |||
64 | 2. Extra knobs | ||
65 | ~~~~~~~~~~~ | ||
66 | |||
67 | Currently the Linux Elantech touchpad driver provides two extra knobs under | ||
68 | /sys/bus/serio/drivers/psmouse/serio? for the user. | ||
69 | |||
70 | * debug | ||
71 | |||
72 | Turn different levels of debugging ON or OFF. | ||
73 | |||
74 | By echoing "0" to this file all debugging will be turned OFF. | ||
75 | |||
76 | Currently a value of "1" will turn on some basic debugging and a value of | ||
77 | "2" will turn on packet debugging. For hardware version 1 the default is | ||
78 | OFF. For version 2 the default is "1". | ||
79 | |||
80 | Turning packet debugging on will make the driver dump every packet | ||
81 | received to the syslog before processing it. Be warned that this can | ||
82 | generate quite a lot of data! | ||
83 | |||
84 | * paritycheck | ||
85 | |||
86 | Turns parity checking ON or OFF. | ||
87 | |||
88 | By echoing "0" to this file parity checking will be turned OFF. Any | ||
89 | non-zero value will turn it ON. For hardware version 1 the default is ON. | ||
90 | For version 2 the default it is OFF. | ||
91 | |||
92 | Hardware version 1 provides basic data integrity verification by | ||
93 | calculating a parity bit for the last 3 bytes of each packet. The driver | ||
94 | can check these bits and reject any packet that appears corrupted. Using | ||
95 | this knob you can bypass that check. | ||
96 | |||
97 | It is not known yet whether hardware version 2 provides the same parity | ||
98 | bits. Hence checking is disabled by default. Currently even turning it on | ||
99 | will do nothing. | ||
100 | |||
101 | |||
102 | ///////////////////////////////////////////////////////////////////////////// | ||
103 | |||
104 | |||
105 | 3. Hardware version 1 | ||
106 | ================== | ||
107 | |||
108 | 3.1 Registers | ||
109 | ~~~~~~~~~ | ||
110 | |||
111 | By echoing a hexadecimal value to a register it contents can be altered. | ||
112 | |||
113 | For example: | ||
114 | |||
115 | echo -n 0x16 > reg_10 | ||
116 | |||
117 | * reg_10 | ||
118 | |||
119 | bit 7 6 5 4 3 2 1 0 | ||
120 | B C T D L A S E | ||
121 | |||
122 | E: 1 = enable smart edges unconditionally | ||
123 | S: 1 = enable smart edges only when dragging | ||
124 | A: 1 = absolute mode (needs 4 byte packets, see reg_11) | ||
125 | L: 1 = enable drag lock (see reg_22) | ||
126 | D: 1 = disable dynamic resolution | ||
127 | T: 1 = disable tapping | ||
128 | C: 1 = enable corner tap | ||
129 | B: 1 = swap left and right button | ||
130 | |||
131 | * reg_11 | ||
132 | |||
133 | bit 7 6 5 4 3 2 1 0 | ||
134 | 1 0 0 H V 1 F P | ||
135 | |||
136 | P: 1 = enable parity checking for relative mode | ||
137 | F: 1 = enable native 4 byte packet mode | ||
138 | V: 1 = enable vertical scroll area | ||
139 | H: 1 = enable horizontal scroll area | ||
140 | |||
141 | * reg_20 | ||
142 | |||
143 | single finger width? | ||
144 | |||
145 | * reg_21 | ||
146 | |||
147 | scroll area width (small: 0x40 ... wide: 0xff) | ||
148 | |||
149 | * reg_22 | ||
150 | |||
151 | drag lock time out (short: 0x14 ... long: 0xfe; | ||
152 | 0xff = tap again to release) | ||
153 | |||
154 | * reg_23 | ||
155 | |||
156 | tap make timeout? | ||
157 | |||
158 | * reg_24 | ||
159 | |||
160 | tap release timeout? | ||
161 | |||
162 | * reg_25 | ||
163 | |||
164 | smart edge cursor speed (0x02 = slow, 0x03 = medium, 0x04 = fast) | ||
165 | |||
166 | * reg_26 | ||
167 | |||
168 | smart edge activation area width? | ||
169 | |||
170 | |||
171 | 3.2 Native relative mode 4 byte packet format | ||
172 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
173 | |||
174 | byte 0: | ||
175 | bit 7 6 5 4 3 2 1 0 | ||
176 | c c p2 p1 1 M R L | ||
177 | |||
178 | L, R, M = 1 when Left, Right, Middle mouse button pressed | ||
179 | some models have M as byte 3 odd parity bit | ||
180 | when parity checking is enabled (reg_11, P = 1): | ||
181 | p1..p2 = byte 1 and 2 odd parity bit | ||
182 | c = 1 when corner tap detected | ||
183 | |||
184 | byte 1: | ||
185 | bit 7 6 5 4 3 2 1 0 | ||
186 | dx7 dx6 dx5 dx4 dx3 dx2 dx1 dx0 | ||
187 | |||
188 | dx7..dx0 = x movement; positive = right, negative = left | ||
189 | byte 1 = 0xf0 when corner tap detected | ||
190 | |||
191 | byte 2: | ||
192 | bit 7 6 5 4 3 2 1 0 | ||
193 | dy7 dy6 dy5 dy4 dy3 dy2 dy1 dy0 | ||
194 | |||
195 | dy7..dy0 = y movement; positive = up, negative = down | ||
196 | |||
197 | byte 3: | ||
198 | parity checking enabled (reg_11, P = 1): | ||
199 | |||
200 | bit 7 6 5 4 3 2 1 0 | ||
201 | w h n1 n0 ds3 ds2 ds1 ds0 | ||
202 | |||
203 | normally: | ||
204 | ds3..ds0 = scroll wheel amount and direction | ||
205 | positive = down or left | ||
206 | negative = up or right | ||
207 | when corner tap detected: | ||
208 | ds0 = 1 when top right corner tapped | ||
209 | ds1 = 1 when bottom right corner tapped | ||
210 | ds2 = 1 when bottom left corner tapped | ||
211 | ds3 = 1 when top left corner tapped | ||
212 | n1..n0 = number of fingers on touchpad | ||
213 | only models with firmware 2.x report this, models with | ||
214 | firmware 1.x seem to map one, two and three finger taps | ||
215 | directly to L, M and R mouse buttons | ||
216 | h = 1 when horizontal scroll action | ||
217 | w = 1 when wide finger touch? | ||
218 | |||
219 | otherwise (reg_11, P = 0): | ||
220 | |||
221 | bit 7 6 5 4 3 2 1 0 | ||
222 | ds7 ds6 ds5 ds4 ds3 ds2 ds1 ds0 | ||
223 | |||
224 | ds7..ds0 = vertical scroll amount and direction | ||
225 | negative = up | ||
226 | positive = down | ||
227 | |||
228 | |||
229 | 3.3 Native absolute mode 4 byte packet format | ||
230 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
231 | |||
232 | byte 0: | ||
233 | firmware version 1.x: | ||
234 | |||
235 | bit 7 6 5 4 3 2 1 0 | ||
236 | D U p1 p2 1 p3 R L | ||
237 | |||
238 | L, R = 1 when Left, Right mouse button pressed | ||
239 | p1..p3 = byte 1..3 odd parity bit | ||
240 | D, U = 1 when rocker switch pressed Up, Down | ||
241 | |||
242 | firmware version 2.x: | ||
243 | |||
244 | bit 7 6 5 4 3 2 1 0 | ||
245 | n1 n0 p2 p1 1 p3 R L | ||
246 | |||
247 | L, R = 1 when Left, Right mouse button pressed | ||
248 | p1..p3 = byte 1..3 odd parity bit | ||
249 | n1..n0 = number of fingers on touchpad | ||
250 | |||
251 | byte 1: | ||
252 | firmware version 1.x: | ||
253 | |||
254 | bit 7 6 5 4 3 2 1 0 | ||
255 | f 0 th tw x9 x8 y9 y8 | ||
256 | |||
257 | tw = 1 when two finger touch | ||
258 | th = 1 when three finger touch | ||
259 | f = 1 when finger touch | ||
260 | |||
261 | firmware version 2.x: | ||
262 | |||
263 | bit 7 6 5 4 3 2 1 0 | ||
264 | . . . . x9 x8 y9 y8 | ||
265 | |||
266 | byte 2: | ||
267 | bit 7 6 5 4 3 2 1 0 | ||
268 | x7 x6 x5 x4 x3 x2 x1 x0 | ||
269 | |||
270 | x9..x0 = absolute x value (horizontal) | ||
271 | |||
272 | byte 3: | ||
273 | bit 7 6 5 4 3 2 1 0 | ||
274 | y7 y6 y5 y4 y3 y2 y1 y0 | ||
275 | |||
276 | y9..y0 = absolute y value (vertical) | ||
277 | |||
278 | |||
279 | ///////////////////////////////////////////////////////////////////////////// | ||
280 | |||
281 | |||
282 | 4. Hardware version 2 | ||
283 | ================== | ||
284 | |||
285 | |||
286 | 4.1 Registers | ||
287 | ~~~~~~~~~ | ||
288 | |||
289 | By echoing a hexadecimal value to a register it contents can be altered. | ||
290 | |||
291 | For example: | ||
292 | |||
293 | echo -n 0x56 > reg_10 | ||
294 | |||
295 | * reg_10 | ||
296 | |||
297 | bit 7 6 5 4 3 2 1 0 | ||
298 | 0 1 0 1 0 1 D 0 | ||
299 | |||
300 | D: 1 = enable drag and drop | ||
301 | |||
302 | * reg_11 | ||
303 | |||
304 | bit 7 6 5 4 3 2 1 0 | ||
305 | 1 0 0 0 S 0 1 0 | ||
306 | |||
307 | S: 1 = enable vertical scroll | ||
308 | |||
309 | * reg_21 | ||
310 | |||
311 | unknown (0x00) | ||
312 | |||
313 | * reg_22 | ||
314 | |||
315 | drag and drop release time out (short: 0x70 ... long 0x7e; | ||
316 | 0x7f = never i.e. tap again to release) | ||
317 | |||
318 | |||
319 | 4.2 Native absolute mode 6 byte packet format | ||
320 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
321 | |||
322 | 4.2.1 One finger touch | ||
323 | ~~~~~~~~~~~~~~~~ | ||
324 | |||
325 | byte 0: | ||
326 | |||
327 | bit 7 6 5 4 3 2 1 0 | ||
328 | n1 n0 . . . . R L | ||
329 | |||
330 | L, R = 1 when Left, Right mouse button pressed | ||
331 | n1..n0 = numbers of fingers on touchpad | ||
332 | |||
333 | byte 1: | ||
334 | |||
335 | bit 7 6 5 4 3 2 1 0 | ||
336 | x15 x14 x13 x12 x11 x10 x9 x8 | ||
337 | |||
338 | byte 2: | ||
339 | |||
340 | bit 7 6 5 4 3 2 1 0 | ||
341 | x7 x6 x5 x4 x4 x2 x1 x0 | ||
342 | |||
343 | x15..x0 = absolute x value (horizontal) | ||
344 | |||
345 | byte 3: | ||
346 | |||
347 | bit 7 6 5 4 3 2 1 0 | ||
348 | . . . . . . . . | ||
349 | |||
350 | byte 4: | ||
351 | |||
352 | bit 7 6 5 4 3 2 1 0 | ||
353 | y15 y14 y13 y12 y11 y10 y8 y8 | ||
354 | |||
355 | byte 5: | ||
356 | |||
357 | bit 7 6 5 4 3 2 1 0 | ||
358 | y7 y6 y5 y4 y3 y2 y1 y0 | ||
359 | |||
360 | y15..y0 = absolute y value (vertical) | ||
361 | |||
362 | |||
363 | 4.2.2 Two finger touch | ||
364 | ~~~~~~~~~~~~~~~~ | ||
365 | |||
366 | byte 0: | ||
367 | |||
368 | bit 7 6 5 4 3 2 1 0 | ||
369 | n1 n0 ay8 ax8 . . R L | ||
370 | |||
371 | L, R = 1 when Left, Right mouse button pressed | ||
372 | n1..n0 = numbers of fingers on touchpad | ||
373 | |||
374 | byte 1: | ||
375 | |||
376 | bit 7 6 5 4 3 2 1 0 | ||
377 | ax7 ax6 ax5 ax4 ax3 ax2 ax1 ax0 | ||
378 | |||
379 | ax8..ax0 = first finger absolute x value | ||
380 | |||
381 | byte 2: | ||
382 | |||
383 | bit 7 6 5 4 3 2 1 0 | ||
384 | ay7 ay6 ay5 ay4 ay3 ay2 ay1 ay0 | ||
385 | |||
386 | ay8..ay0 = first finger absolute y value | ||
387 | |||
388 | byte 3: | ||
389 | |||
390 | bit 7 6 5 4 3 2 1 0 | ||
391 | . . by8 bx8 . . . . | ||
392 | |||
393 | byte 4: | ||
394 | |||
395 | bit 7 6 5 4 3 2 1 0 | ||
396 | bx7 bx6 bx5 bx4 bx3 bx2 bx1 bx0 | ||
397 | |||
398 | bx8..bx0 = second finger absolute x value | ||
399 | |||
400 | byte 5: | ||
401 | |||
402 | bit 7 6 5 4 3 2 1 0 | ||
403 | by7 by8 by5 by4 by3 by2 by1 by0 | ||
404 | |||
405 | by8..by0 = second finger absolute y value | ||
diff --git a/Documentation/scheduler/sched-design-CFS.txt b/Documentation/scheduler/sched-design-CFS.txt index 9d8eb553884c..eb471c7a905e 100644 --- a/Documentation/scheduler/sched-design-CFS.txt +++ b/Documentation/scheduler/sched-design-CFS.txt | |||
@@ -92,7 +92,7 @@ other HZ detail. Thus the CFS scheduler has no notion of "timeslices" in the | |||
92 | way the previous scheduler had, and has no heuristics whatsoever. There is | 92 | way the previous scheduler had, and has no heuristics whatsoever. There is |
93 | only one central tunable (you have to switch on CONFIG_SCHED_DEBUG): | 93 | only one central tunable (you have to switch on CONFIG_SCHED_DEBUG): |
94 | 94 | ||
95 | /proc/sys/kernel/sched_granularity_ns | 95 | /proc/sys/kernel/sched_min_granularity_ns |
96 | 96 | ||
97 | which can be used to tune the scheduler from "desktop" (i.e., low latencies) to | 97 | which can be used to tune the scheduler from "desktop" (i.e., low latencies) to |
98 | "server" (i.e., good batching) workloads. It defaults to a setting suitable | 98 | "server" (i.e., good batching) workloads. It defaults to a setting suitable |
diff --git a/MAINTAINERS b/MAINTAINERS index 277451a52695..16202c8ac68f 100644 --- a/MAINTAINERS +++ b/MAINTAINERS | |||
@@ -378,8 +378,9 @@ T: git://git.kernel.org/pub/scm/linux/kernel/git/joro/linux-2.6-iommu.git | |||
378 | S: Supported | 378 | S: Supported |
379 | 379 | ||
380 | AMD MICROCODE UPDATE SUPPORT | 380 | AMD MICROCODE UPDATE SUPPORT |
381 | P: Peter Oruba | 381 | P: Andreas Herrmann |
382 | M: peter.oruba@amd.com | 382 | M: andeas.herrmann3@amd.com |
383 | L: amd64-microcode@amd64.org | ||
383 | S: Supported | 384 | S: Supported |
384 | 385 | ||
385 | AMS (Apple Motion Sensor) DRIVER | 386 | AMS (Apple Motion Sensor) DRIVER |
@@ -1,8 +1,8 @@ | |||
1 | VERSION = 2 | 1 | VERSION = 2 |
2 | PATCHLEVEL = 6 | 2 | PATCHLEVEL = 6 |
3 | SUBLEVEL = 27 | 3 | SUBLEVEL = 28 |
4 | EXTRAVERSION = | 4 | EXTRAVERSION = -rc2 |
5 | NAME = Rotary Wombat | 5 | NAME = Killer Bat of Doom |
6 | 6 | ||
7 | # *DOCUMENTATION* | 7 | # *DOCUMENTATION* |
8 | # To see a list of typical targets execute "make help" | 8 | # To see a list of typical targets execute "make help" |
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index f504c801792f..5021db2217ed 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig | |||
@@ -540,16 +540,15 @@ config ARCH_OMAP | |||
540 | help | 540 | help |
541 | Support for TI's OMAP platform (OMAP1 and OMAP2). | 541 | Support for TI's OMAP platform (OMAP1 and OMAP2). |
542 | 542 | ||
543 | config ARCH_MSM7X00A | 543 | config ARCH_MSM |
544 | bool "Qualcomm MSM7X00A" | 544 | bool "Qualcomm MSM" |
545 | select GENERIC_TIME | 545 | select GENERIC_TIME |
546 | select GENERIC_CLOCKEVENTS | 546 | select GENERIC_CLOCKEVENTS |
547 | help | 547 | help |
548 | Support for Qualcomm MSM7X00A based systems. This runs on the ARM11 | 548 | Support for Qualcomm MSM7K based systems. This runs on the ARM11 |
549 | apps processor of the MSM7X00A and depends on a shared memory | 549 | apps processor of the MSM7K and depends on a shared memory |
550 | interface to the ARM9 modem processor which runs the baseband stack | 550 | interface to the ARM9 modem processor which runs the baseband stack |
551 | and controls some vital subsystems (clock and power control, etc). | 551 | and controls some vital subsystems (clock and power control, etc). |
552 | <http://www.cdmatech.com/products/msm7200_chipset_solution.jsp> | ||
553 | 552 | ||
554 | endchoice | 553 | endchoice |
555 | 554 | ||
diff --git a/arch/arm/Makefile b/arch/arm/Makefile index 7d5121260fda..bd6e28115ebb 100644 --- a/arch/arm/Makefile +++ b/arch/arm/Makefile | |||
@@ -141,7 +141,7 @@ endif | |||
141 | machine-$(CONFIG_ARCH_MX3) := mx3 | 141 | machine-$(CONFIG_ARCH_MX3) := mx3 |
142 | machine-$(CONFIG_ARCH_ORION5X) := orion5x | 142 | machine-$(CONFIG_ARCH_ORION5X) := orion5x |
143 | plat-$(CONFIG_PLAT_ORION) := orion | 143 | plat-$(CONFIG_PLAT_ORION) := orion |
144 | machine-$(CONFIG_ARCH_MSM7X00A) := msm | 144 | machine-$(CONFIG_ARCH_MSM) := msm |
145 | machine-$(CONFIG_ARCH_LOKI) := loki | 145 | machine-$(CONFIG_ARCH_LOKI) := loki |
146 | machine-$(CONFIG_ARCH_MV78XX0) := mv78xx0 | 146 | machine-$(CONFIG_ARCH_MV78XX0) := mv78xx0 |
147 | 147 | ||
diff --git a/arch/arm/configs/corgi_defconfig b/arch/arm/configs/corgi_defconfig index 9b8748a8d9dd..f3af0b593eb0 100644 --- a/arch/arm/configs/corgi_defconfig +++ b/arch/arm/configs/corgi_defconfig | |||
@@ -1,71 +1,111 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.15-rc2 | 3 | # Linux kernel version: 2.6.27 |
4 | # Mon Nov 28 10:30:09 2005 | 4 | # Mon Oct 20 10:12:23 2008 |
5 | # | 5 | # |
6 | CONFIG_ARM=y | 6 | CONFIG_ARM=y |
7 | CONFIG_SYS_SUPPORTS_APM_EMULATION=y | ||
8 | CONFIG_GENERIC_GPIO=y | ||
9 | CONFIG_GENERIC_TIME=y | ||
10 | CONFIG_GENERIC_CLOCKEVENTS=y | ||
7 | CONFIG_MMU=y | 11 | CONFIG_MMU=y |
8 | CONFIG_UID16=y | 12 | # CONFIG_NO_IOPORT is not set |
13 | CONFIG_GENERIC_HARDIRQS=y | ||
14 | CONFIG_STACKTRACE_SUPPORT=y | ||
15 | CONFIG_HAVE_LATENCYTOP_SUPPORT=y | ||
16 | CONFIG_LOCKDEP_SUPPORT=y | ||
17 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | ||
18 | CONFIG_HARDIRQS_SW_RESEND=y | ||
19 | CONFIG_GENERIC_IRQ_PROBE=y | ||
9 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | 20 | CONFIG_RWSEM_GENERIC_SPINLOCK=y |
21 | # CONFIG_ARCH_HAS_ILOG2_U32 is not set | ||
22 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set | ||
23 | CONFIG_GENERIC_HWEIGHT=y | ||
10 | CONFIG_GENERIC_CALIBRATE_DELAY=y | 24 | CONFIG_GENERIC_CALIBRATE_DELAY=y |
25 | CONFIG_ARCH_MTD_XIP=y | ||
26 | CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y | ||
27 | CONFIG_VECTORS_BASE=0xffff0000 | ||
28 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | ||
11 | 29 | ||
12 | # | 30 | # |
13 | # Code maturity level options | 31 | # General setup |
14 | # | 32 | # |
15 | CONFIG_EXPERIMENTAL=y | 33 | CONFIG_EXPERIMENTAL=y |
16 | CONFIG_CLEAN_COMPILE=y | ||
17 | CONFIG_BROKEN_ON_SMP=y | 34 | CONFIG_BROKEN_ON_SMP=y |
18 | CONFIG_LOCK_KERNEL=y | 35 | CONFIG_LOCK_KERNEL=y |
19 | CONFIG_INIT_ENV_ARG_LIMIT=32 | 36 | CONFIG_INIT_ENV_ARG_LIMIT=32 |
20 | |||
21 | # | ||
22 | # General setup | ||
23 | # | ||
24 | CONFIG_LOCALVERSION="" | 37 | CONFIG_LOCALVERSION="" |
25 | CONFIG_LOCALVERSION_AUTO=y | 38 | CONFIG_LOCALVERSION_AUTO=y |
26 | CONFIG_SWAP=y | 39 | CONFIG_SWAP=y |
27 | CONFIG_SYSVIPC=y | 40 | CONFIG_SYSVIPC=y |
41 | CONFIG_SYSVIPC_SYSCTL=y | ||
28 | # CONFIG_POSIX_MQUEUE is not set | 42 | # CONFIG_POSIX_MQUEUE is not set |
29 | CONFIG_BSD_PROCESS_ACCT=y | 43 | CONFIG_BSD_PROCESS_ACCT=y |
30 | # CONFIG_BSD_PROCESS_ACCT_V3 is not set | 44 | # CONFIG_BSD_PROCESS_ACCT_V3 is not set |
31 | CONFIG_SYSCTL=y | 45 | # CONFIG_TASKSTATS is not set |
32 | # CONFIG_AUDIT is not set | 46 | # CONFIG_AUDIT is not set |
33 | CONFIG_HOTPLUG=y | ||
34 | CONFIG_KOBJECT_UEVENT=y | ||
35 | # CONFIG_IKCONFIG is not set | 47 | # CONFIG_IKCONFIG is not set |
36 | CONFIG_INITRAMFS_SOURCE="" | 48 | CONFIG_LOG_BUF_SHIFT=14 |
49 | # CONFIG_CGROUPS is not set | ||
50 | # CONFIG_GROUP_SCHED is not set | ||
51 | CONFIG_SYSFS_DEPRECATED=y | ||
52 | CONFIG_SYSFS_DEPRECATED_V2=y | ||
53 | # CONFIG_RELAY is not set | ||
54 | # CONFIG_NAMESPACES is not set | ||
55 | # CONFIG_BLK_DEV_INITRD is not set | ||
56 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | ||
57 | CONFIG_SYSCTL=y | ||
37 | CONFIG_EMBEDDED=y | 58 | CONFIG_EMBEDDED=y |
59 | CONFIG_UID16=y | ||
60 | CONFIG_SYSCTL_SYSCALL=y | ||
38 | CONFIG_KALLSYMS=y | 61 | CONFIG_KALLSYMS=y |
39 | # CONFIG_KALLSYMS_ALL is not set | 62 | # CONFIG_KALLSYMS_ALL is not set |
40 | # CONFIG_KALLSYMS_EXTRA_PASS is not set | 63 | # CONFIG_KALLSYMS_EXTRA_PASS is not set |
64 | CONFIG_HOTPLUG=y | ||
41 | CONFIG_PRINTK=y | 65 | CONFIG_PRINTK=y |
42 | CONFIG_BUG=y | 66 | CONFIG_BUG=y |
67 | CONFIG_ELF_CORE=y | ||
68 | CONFIG_COMPAT_BRK=y | ||
43 | CONFIG_BASE_FULL=y | 69 | CONFIG_BASE_FULL=y |
44 | CONFIG_FUTEX=y | 70 | CONFIG_FUTEX=y |
71 | CONFIG_ANON_INODES=y | ||
45 | CONFIG_EPOLL=y | 72 | CONFIG_EPOLL=y |
46 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | 73 | CONFIG_SIGNALFD=y |
74 | CONFIG_TIMERFD=y | ||
75 | CONFIG_EVENTFD=y | ||
47 | CONFIG_SHMEM=y | 76 | CONFIG_SHMEM=y |
48 | CONFIG_CC_ALIGN_FUNCTIONS=0 | 77 | CONFIG_AIO=y |
49 | CONFIG_CC_ALIGN_LABELS=0 | 78 | CONFIG_VM_EVENT_COUNTERS=y |
50 | CONFIG_CC_ALIGN_LOOPS=0 | 79 | CONFIG_SLUB_DEBUG=y |
51 | CONFIG_CC_ALIGN_JUMPS=0 | 80 | # CONFIG_SLAB is not set |
81 | CONFIG_SLUB=y | ||
82 | # CONFIG_SLOB is not set | ||
83 | CONFIG_PROFILING=y | ||
84 | # CONFIG_MARKERS is not set | ||
85 | CONFIG_OPROFILE=m | ||
86 | CONFIG_HAVE_OPROFILE=y | ||
87 | # CONFIG_KPROBES is not set | ||
88 | CONFIG_HAVE_KPROBES=y | ||
89 | CONFIG_HAVE_KRETPROBES=y | ||
90 | CONFIG_HAVE_CLK=y | ||
91 | CONFIG_HAVE_GENERIC_DMA_COHERENT=y | ||
92 | CONFIG_SLABINFO=y | ||
93 | CONFIG_RT_MUTEXES=y | ||
52 | # CONFIG_TINY_SHMEM is not set | 94 | # CONFIG_TINY_SHMEM is not set |
53 | CONFIG_BASE_SMALL=0 | 95 | CONFIG_BASE_SMALL=0 |
54 | |||
55 | # | ||
56 | # Loadable module support | ||
57 | # | ||
58 | CONFIG_MODULES=y | 96 | CONFIG_MODULES=y |
97 | # CONFIG_MODULE_FORCE_LOAD is not set | ||
59 | CONFIG_MODULE_UNLOAD=y | 98 | CONFIG_MODULE_UNLOAD=y |
60 | CONFIG_MODULE_FORCE_UNLOAD=y | 99 | CONFIG_MODULE_FORCE_UNLOAD=y |
61 | CONFIG_OBSOLETE_MODPARM=y | ||
62 | # CONFIG_MODVERSIONS is not set | 100 | # CONFIG_MODVERSIONS is not set |
63 | # CONFIG_MODULE_SRCVERSION_ALL is not set | 101 | # CONFIG_MODULE_SRCVERSION_ALL is not set |
64 | CONFIG_KMOD=y | 102 | CONFIG_KMOD=y |
65 | 103 | CONFIG_BLOCK=y | |
66 | # | 104 | # CONFIG_LBD is not set |
67 | # Block layer | 105 | # CONFIG_BLK_DEV_IO_TRACE is not set |
68 | # | 106 | # CONFIG_LSF is not set |
107 | # CONFIG_BLK_DEV_BSG is not set | ||
108 | # CONFIG_BLK_DEV_INTEGRITY is not set | ||
69 | 109 | ||
70 | # | 110 | # |
71 | # IO Schedulers | 111 | # IO Schedulers |
@@ -79,50 +119,97 @@ CONFIG_DEFAULT_AS=y | |||
79 | # CONFIG_DEFAULT_CFQ is not set | 119 | # CONFIG_DEFAULT_CFQ is not set |
80 | # CONFIG_DEFAULT_NOOP is not set | 120 | # CONFIG_DEFAULT_NOOP is not set |
81 | CONFIG_DEFAULT_IOSCHED="anticipatory" | 121 | CONFIG_DEFAULT_IOSCHED="anticipatory" |
122 | CONFIG_CLASSIC_RCU=y | ||
82 | 123 | ||
83 | # | 124 | # |
84 | # System Type | 125 | # System Type |
85 | # | 126 | # |
127 | # CONFIG_ARCH_AAEC2000 is not set | ||
128 | # CONFIG_ARCH_INTEGRATOR is not set | ||
129 | # CONFIG_ARCH_REALVIEW is not set | ||
130 | # CONFIG_ARCH_VERSATILE is not set | ||
131 | # CONFIG_ARCH_AT91 is not set | ||
86 | # CONFIG_ARCH_CLPS7500 is not set | 132 | # CONFIG_ARCH_CLPS7500 is not set |
87 | # CONFIG_ARCH_CLPS711X is not set | 133 | # CONFIG_ARCH_CLPS711X is not set |
88 | # CONFIG_ARCH_CO285 is not set | ||
89 | # CONFIG_ARCH_EBSA110 is not set | 134 | # CONFIG_ARCH_EBSA110 is not set |
135 | # CONFIG_ARCH_EP93XX is not set | ||
90 | # CONFIG_ARCH_FOOTBRIDGE is not set | 136 | # CONFIG_ARCH_FOOTBRIDGE is not set |
91 | # CONFIG_ARCH_INTEGRATOR is not set | 137 | # CONFIG_ARCH_NETX is not set |
92 | # CONFIG_ARCH_IOP3XX is not set | 138 | # CONFIG_ARCH_H720X is not set |
93 | # CONFIG_ARCH_IXP4XX is not set | 139 | # CONFIG_ARCH_IMX is not set |
140 | # CONFIG_ARCH_IOP13XX is not set | ||
141 | # CONFIG_ARCH_IOP32X is not set | ||
142 | # CONFIG_ARCH_IOP33X is not set | ||
143 | # CONFIG_ARCH_IXP23XX is not set | ||
94 | # CONFIG_ARCH_IXP2000 is not set | 144 | # CONFIG_ARCH_IXP2000 is not set |
145 | # CONFIG_ARCH_IXP4XX is not set | ||
95 | # CONFIG_ARCH_L7200 is not set | 146 | # CONFIG_ARCH_L7200 is not set |
147 | # CONFIG_ARCH_KIRKWOOD is not set | ||
148 | # CONFIG_ARCH_KS8695 is not set | ||
149 | # CONFIG_ARCH_NS9XXX is not set | ||
150 | # CONFIG_ARCH_LOKI is not set | ||
151 | # CONFIG_ARCH_MV78XX0 is not set | ||
152 | # CONFIG_ARCH_MXC is not set | ||
153 | # CONFIG_ARCH_ORION5X is not set | ||
154 | # CONFIG_ARCH_PNX4008 is not set | ||
96 | CONFIG_ARCH_PXA=y | 155 | CONFIG_ARCH_PXA=y |
97 | # CONFIG_ARCH_RPC is not set | 156 | # CONFIG_ARCH_RPC is not set |
98 | # CONFIG_ARCH_SA1100 is not set | 157 | # CONFIG_ARCH_SA1100 is not set |
99 | # CONFIG_ARCH_S3C2410 is not set | 158 | # CONFIG_ARCH_S3C2410 is not set |
100 | # CONFIG_ARCH_SHARK is not set | 159 | # CONFIG_ARCH_SHARK is not set |
101 | # CONFIG_ARCH_LH7A40X is not set | 160 | # CONFIG_ARCH_LH7A40X is not set |
161 | # CONFIG_ARCH_DAVINCI is not set | ||
102 | # CONFIG_ARCH_OMAP is not set | 162 | # CONFIG_ARCH_OMAP is not set |
103 | # CONFIG_ARCH_VERSATILE is not set | 163 | # CONFIG_ARCH_MSM7X00A is not set |
104 | # CONFIG_ARCH_REALVIEW is not set | ||
105 | # CONFIG_ARCH_IMX is not set | ||
106 | # CONFIG_ARCH_H720X is not set | ||
107 | # CONFIG_ARCH_AAEC2000 is not set | ||
108 | 164 | ||
109 | # | 165 | # |
110 | # Intel PXA2xx Implementations | 166 | # Intel PXA2xx/PXA3xx Implementations |
111 | # | 167 | # |
168 | # CONFIG_ARCH_GUMSTIX is not set | ||
112 | # CONFIG_ARCH_LUBBOCK is not set | 169 | # CONFIG_ARCH_LUBBOCK is not set |
170 | # CONFIG_MACH_LOGICPD_PXA270 is not set | ||
113 | # CONFIG_MACH_MAINSTONE is not set | 171 | # CONFIG_MACH_MAINSTONE is not set |
172 | # CONFIG_MACH_MP900C is not set | ||
114 | # CONFIG_ARCH_PXA_IDP is not set | 173 | # CONFIG_ARCH_PXA_IDP is not set |
115 | CONFIG_PXA_SHARPSL=y | 174 | CONFIG_PXA_SHARPSL=y |
116 | CONFIG_PXA_SHARPSL_25x=y | ||
117 | # CONFIG_PXA_SHARPSL_27x is not set | ||
118 | CONFIG_MACH_POODLE=y | 175 | CONFIG_MACH_POODLE=y |
119 | CONFIG_MACH_CORGI=y | 176 | CONFIG_MACH_CORGI=y |
120 | CONFIG_MACH_SHEPHERD=y | 177 | CONFIG_MACH_SHEPHERD=y |
121 | CONFIG_MACH_HUSKY=y | 178 | CONFIG_MACH_HUSKY=y |
179 | # CONFIG_MACH_AKITA is not set | ||
180 | # CONFIG_MACH_SPITZ is not set | ||
181 | # CONFIG_MACH_BORZOI is not set | ||
122 | CONFIG_MACH_TOSA=y | 182 | CONFIG_MACH_TOSA=y |
183 | # CONFIG_ARCH_VIPER is not set | ||
184 | # CONFIG_ARCH_PXA_ESERIES is not set | ||
185 | # CONFIG_TRIZEPS_PXA is not set | ||
186 | # CONFIG_MACH_EM_X270 is not set | ||
187 | # CONFIG_MACH_COLIBRI is not set | ||
188 | # CONFIG_MACH_ZYLONITE is not set | ||
189 | # CONFIG_MACH_LITTLETON is not set | ||
190 | # CONFIG_MACH_TAVOREVB is not set | ||
191 | # CONFIG_MACH_SAAR is not set | ||
192 | # CONFIG_MACH_ARMCORE is not set | ||
193 | # CONFIG_MACH_CM_X300 is not set | ||
194 | # CONFIG_MACH_MAGICIAN is not set | ||
195 | # CONFIG_MACH_MIOA701 is not set | ||
196 | # CONFIG_MACH_PCM027 is not set | ||
197 | # CONFIG_ARCH_PXA_PALM is not set | ||
198 | # CONFIG_PXA_EZX is not set | ||
123 | CONFIG_PXA25x=y | 199 | CONFIG_PXA25x=y |
124 | CONFIG_PXA_SHARP_C7xx=y | 200 | CONFIG_PXA_SHARP_C7xx=y |
125 | CONFIG_PXA_SSP=y | 201 | CONFIG_PXA_SSP=y |
202 | # CONFIG_PXA_PWM is not set | ||
203 | # CONFIG_TOSA_BT is not set | ||
204 | CONFIG_PXA_HAVE_BOARD_IRQS=y | ||
205 | |||
206 | # | ||
207 | # Boot options | ||
208 | # | ||
209 | |||
210 | # | ||
211 | # Power management | ||
212 | # | ||
126 | 213 | ||
127 | # | 214 | # |
128 | # Processor Type | 215 | # Processor Type |
@@ -131,25 +218,30 @@ CONFIG_CPU_32=y | |||
131 | CONFIG_CPU_XSCALE=y | 218 | CONFIG_CPU_XSCALE=y |
132 | CONFIG_CPU_32v5=y | 219 | CONFIG_CPU_32v5=y |
133 | CONFIG_CPU_ABRT_EV5T=y | 220 | CONFIG_CPU_ABRT_EV5T=y |
221 | CONFIG_CPU_PABRT_NOIFAR=y | ||
134 | CONFIG_CPU_CACHE_VIVT=y | 222 | CONFIG_CPU_CACHE_VIVT=y |
135 | CONFIG_CPU_TLB_V4WBI=y | 223 | CONFIG_CPU_TLB_V4WBI=y |
224 | CONFIG_CPU_CP15=y | ||
225 | CONFIG_CPU_CP15_MMU=y | ||
136 | 226 | ||
137 | # | 227 | # |
138 | # Processor Features | 228 | # Processor Features |
139 | # | 229 | # |
140 | CONFIG_ARM_THUMB=y | 230 | CONFIG_ARM_THUMB=y |
231 | # CONFIG_CPU_DCACHE_DISABLE is not set | ||
232 | # CONFIG_OUTER_CACHE is not set | ||
233 | # CONFIG_IWMMXT is not set | ||
141 | CONFIG_XSCALE_PMU=y | 234 | CONFIG_XSCALE_PMU=y |
235 | CONFIG_SHARP_LOCOMO=y | ||
142 | CONFIG_SHARP_PARAM=y | 236 | CONFIG_SHARP_PARAM=y |
237 | CONFIG_SHARPSL_PM=y | ||
143 | CONFIG_SHARP_SCOOP=y | 238 | CONFIG_SHARP_SCOOP=y |
144 | 239 | ||
145 | # | 240 | # |
146 | # Bus support | 241 | # Bus support |
147 | # | 242 | # |
148 | CONFIG_ISA_DMA_API=y | 243 | # CONFIG_PCI_SYSCALL is not set |
149 | 244 | # CONFIG_ARCH_SUPPORTS_MSI is not set | |
150 | # | ||
151 | # PCCARD (PCMCIA/CardBus) support | ||
152 | # | ||
153 | CONFIG_PCCARD=y | 245 | CONFIG_PCCARD=y |
154 | # CONFIG_PCMCIA_DEBUG is not set | 246 | # CONFIG_PCMCIA_DEBUG is not set |
155 | CONFIG_PCMCIA=y | 247 | CONFIG_PCMCIA=y |
@@ -164,16 +256,32 @@ CONFIG_PCMCIA_PXA2XX=y | |||
164 | # | 256 | # |
165 | # Kernel Features | 257 | # Kernel Features |
166 | # | 258 | # |
259 | CONFIG_TICK_ONESHOT=y | ||
260 | # CONFIG_NO_HZ is not set | ||
261 | # CONFIG_HIGH_RES_TIMERS is not set | ||
262 | CONFIG_GENERIC_CLOCKEVENTS_BUILD=y | ||
263 | CONFIG_VMSPLIT_3G=y | ||
264 | # CONFIG_VMSPLIT_2G is not set | ||
265 | # CONFIG_VMSPLIT_1G is not set | ||
266 | CONFIG_PAGE_OFFSET=0xC0000000 | ||
167 | CONFIG_PREEMPT=y | 267 | CONFIG_PREEMPT=y |
168 | # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set | 268 | CONFIG_HZ=100 |
269 | # CONFIG_AEABI is not set | ||
270 | CONFIG_ARCH_FLATMEM_HAS_HOLES=y | ||
271 | # CONFIG_ARCH_SPARSEMEM_DEFAULT is not set | ||
272 | # CONFIG_ARCH_SELECT_MEMORY_MODEL is not set | ||
169 | CONFIG_SELECT_MEMORY_MODEL=y | 273 | CONFIG_SELECT_MEMORY_MODEL=y |
170 | CONFIG_FLATMEM_MANUAL=y | 274 | CONFIG_FLATMEM_MANUAL=y |
171 | # CONFIG_DISCONTIGMEM_MANUAL is not set | 275 | # CONFIG_DISCONTIGMEM_MANUAL is not set |
172 | # CONFIG_SPARSEMEM_MANUAL is not set | 276 | # CONFIG_SPARSEMEM_MANUAL is not set |
173 | CONFIG_FLATMEM=y | 277 | CONFIG_FLATMEM=y |
174 | CONFIG_FLAT_NODE_MEM_MAP=y | 278 | CONFIG_FLAT_NODE_MEM_MAP=y |
175 | # CONFIG_SPARSEMEM_STATIC is not set | 279 | CONFIG_PAGEFLAGS_EXTENDED=y |
176 | CONFIG_SPLIT_PTLOCK_CPUS=4096 | 280 | CONFIG_SPLIT_PTLOCK_CPUS=4096 |
281 | # CONFIG_RESOURCES_64BIT is not set | ||
282 | # CONFIG_PHYS_ADDR_T_64BIT is not set | ||
283 | CONFIG_ZONE_DMA_FLAG=0 | ||
284 | CONFIG_VIRT_TO_BUS=y | ||
177 | CONFIG_ALIGNMENT_TRAP=y | 285 | CONFIG_ALIGNMENT_TRAP=y |
178 | 286 | ||
179 | # | 287 | # |
@@ -183,6 +291,13 @@ CONFIG_ZBOOT_ROM_TEXT=0x0 | |||
183 | CONFIG_ZBOOT_ROM_BSS=0x0 | 291 | CONFIG_ZBOOT_ROM_BSS=0x0 |
184 | CONFIG_CMDLINE="console=ttyS0,115200n8 console=tty1 noinitrd root=/dev/mtdblock2 rootfstype=jffs2 debug" | 292 | CONFIG_CMDLINE="console=ttyS0,115200n8 console=tty1 noinitrd root=/dev/mtdblock2 rootfstype=jffs2 debug" |
185 | # CONFIG_XIP_KERNEL is not set | 293 | # CONFIG_XIP_KERNEL is not set |
294 | # CONFIG_KEXEC is not set | ||
295 | |||
296 | # | ||
297 | # CPU Power Management | ||
298 | # | ||
299 | # CONFIG_CPU_FREQ is not set | ||
300 | # CONFIG_CPU_IDLE is not set | ||
186 | 301 | ||
187 | # | 302 | # |
188 | # Floating point emulation | 303 | # Floating point emulation |
@@ -199,6 +314,7 @@ CONFIG_FPE_NWFPE=y | |||
199 | # Userspace binary formats | 314 | # Userspace binary formats |
200 | # | 315 | # |
201 | CONFIG_BINFMT_ELF=y | 316 | CONFIG_BINFMT_ELF=y |
317 | CONFIG_HAVE_AOUT=y | ||
202 | CONFIG_BINFMT_AOUT=m | 318 | CONFIG_BINFMT_AOUT=m |
203 | CONFIG_BINFMT_MISC=m | 319 | CONFIG_BINFMT_MISC=m |
204 | # CONFIG_ARTHUR is not set | 320 | # CONFIG_ARTHUR is not set |
@@ -207,12 +323,12 @@ CONFIG_BINFMT_MISC=m | |||
207 | # Power management options | 323 | # Power management options |
208 | # | 324 | # |
209 | CONFIG_PM=y | 325 | CONFIG_PM=y |
210 | # CONFIG_PM_LEGACY is not set | 326 | # CONFIG_PM_DEBUG is not set |
211 | CONFIG_APM=y | 327 | CONFIG_PM_SLEEP=y |
212 | 328 | CONFIG_SUSPEND=y | |
213 | # | 329 | CONFIG_SUSPEND_FREEZER=y |
214 | # Networking | 330 | CONFIG_APM_EMULATION=y |
215 | # | 331 | CONFIG_ARCH_SUSPEND_POSSIBLE=y |
216 | CONFIG_NET=y | 332 | CONFIG_NET=y |
217 | 333 | ||
218 | # | 334 | # |
@@ -223,6 +339,10 @@ CONFIG_PACKET_MMAP=y | |||
223 | CONFIG_UNIX=y | 339 | CONFIG_UNIX=y |
224 | CONFIG_XFRM=y | 340 | CONFIG_XFRM=y |
225 | CONFIG_XFRM_USER=m | 341 | CONFIG_XFRM_USER=m |
342 | # CONFIG_XFRM_SUB_POLICY is not set | ||
343 | # CONFIG_XFRM_MIGRATE is not set | ||
344 | # CONFIG_XFRM_STATISTICS is not set | ||
345 | CONFIG_XFRM_IPCOMP=m | ||
226 | # CONFIG_NET_KEY is not set | 346 | # CONFIG_NET_KEY is not set |
227 | CONFIG_INET=y | 347 | CONFIG_INET=y |
228 | # CONFIG_IP_MULTICAST is not set | 348 | # CONFIG_IP_MULTICAST is not set |
@@ -236,140 +356,131 @@ CONFIG_SYN_COOKIES=y | |||
236 | # CONFIG_INET_AH is not set | 356 | # CONFIG_INET_AH is not set |
237 | # CONFIG_INET_ESP is not set | 357 | # CONFIG_INET_ESP is not set |
238 | # CONFIG_INET_IPCOMP is not set | 358 | # CONFIG_INET_IPCOMP is not set |
239 | # CONFIG_INET_TUNNEL is not set | 359 | # CONFIG_INET_XFRM_TUNNEL is not set |
360 | CONFIG_INET_TUNNEL=m | ||
361 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | ||
362 | CONFIG_INET_XFRM_MODE_TUNNEL=y | ||
363 | CONFIG_INET_XFRM_MODE_BEET=y | ||
364 | # CONFIG_INET_LRO is not set | ||
240 | CONFIG_INET_DIAG=y | 365 | CONFIG_INET_DIAG=y |
241 | CONFIG_INET_TCP_DIAG=y | 366 | CONFIG_INET_TCP_DIAG=y |
242 | # CONFIG_TCP_CONG_ADVANCED is not set | 367 | # CONFIG_TCP_CONG_ADVANCED is not set |
243 | CONFIG_TCP_CONG_BIC=y | 368 | CONFIG_TCP_CONG_CUBIC=y |
244 | 369 | CONFIG_DEFAULT_TCP_CONG="cubic" | |
245 | # | 370 | # CONFIG_TCP_MD5SIG is not set |
246 | # IP: Virtual Server Configuration | ||
247 | # | ||
248 | # CONFIG_IP_VS is not set | ||
249 | CONFIG_IPV6=m | 371 | CONFIG_IPV6=m |
250 | # CONFIG_IPV6_PRIVACY is not set | 372 | # CONFIG_IPV6_PRIVACY is not set |
373 | # CONFIG_IPV6_ROUTER_PREF is not set | ||
374 | # CONFIG_IPV6_OPTIMISTIC_DAD is not set | ||
251 | CONFIG_INET6_AH=m | 375 | CONFIG_INET6_AH=m |
252 | CONFIG_INET6_ESP=m | 376 | CONFIG_INET6_ESP=m |
253 | CONFIG_INET6_IPCOMP=m | 377 | CONFIG_INET6_IPCOMP=m |
378 | # CONFIG_IPV6_MIP6 is not set | ||
379 | CONFIG_INET6_XFRM_TUNNEL=m | ||
254 | CONFIG_INET6_TUNNEL=m | 380 | CONFIG_INET6_TUNNEL=m |
381 | CONFIG_INET6_XFRM_MODE_TRANSPORT=m | ||
382 | CONFIG_INET6_XFRM_MODE_TUNNEL=m | ||
383 | CONFIG_INET6_XFRM_MODE_BEET=m | ||
384 | # CONFIG_INET6_XFRM_MODE_ROUTEOPTIMIZATION is not set | ||
385 | CONFIG_IPV6_SIT=m | ||
386 | CONFIG_IPV6_NDISC_NODETYPE=y | ||
255 | CONFIG_IPV6_TUNNEL=m | 387 | CONFIG_IPV6_TUNNEL=m |
388 | # CONFIG_IPV6_MULTIPLE_TABLES is not set | ||
389 | # CONFIG_IPV6_MROUTE is not set | ||
390 | # CONFIG_NETWORK_SECMARK is not set | ||
256 | CONFIG_NETFILTER=y | 391 | CONFIG_NETFILTER=y |
257 | # CONFIG_NETFILTER_DEBUG is not set | 392 | # CONFIG_NETFILTER_DEBUG is not set |
393 | CONFIG_NETFILTER_ADVANCED=y | ||
258 | 394 | ||
259 | # | 395 | # |
260 | # Core Netfilter Configuration | 396 | # Core Netfilter Configuration |
261 | # | 397 | # |
262 | # CONFIG_NETFILTER_NETLINK is not set | 398 | # CONFIG_NETFILTER_NETLINK_QUEUE is not set |
399 | # CONFIG_NETFILTER_NETLINK_LOG is not set | ||
400 | # CONFIG_NF_CONNTRACK is not set | ||
401 | CONFIG_NETFILTER_XTABLES=m | ||
402 | # CONFIG_NETFILTER_XT_TARGET_CLASSIFY is not set | ||
403 | # CONFIG_NETFILTER_XT_TARGET_DSCP is not set | ||
404 | # CONFIG_NETFILTER_XT_TARGET_MARK is not set | ||
405 | # CONFIG_NETFILTER_XT_TARGET_NFLOG is not set | ||
406 | # CONFIG_NETFILTER_XT_TARGET_NFQUEUE is not set | ||
407 | # CONFIG_NETFILTER_XT_TARGET_RATEEST is not set | ||
408 | # CONFIG_NETFILTER_XT_TARGET_TRACE is not set | ||
409 | # CONFIG_NETFILTER_XT_TARGET_TCPMSS is not set | ||
410 | # CONFIG_NETFILTER_XT_TARGET_TCPOPTSTRIP is not set | ||
411 | # CONFIG_NETFILTER_XT_MATCH_COMMENT is not set | ||
412 | # CONFIG_NETFILTER_XT_MATCH_DCCP is not set | ||
413 | # CONFIG_NETFILTER_XT_MATCH_DSCP is not set | ||
414 | # CONFIG_NETFILTER_XT_MATCH_ESP is not set | ||
415 | # CONFIG_NETFILTER_XT_MATCH_HASHLIMIT is not set | ||
416 | # CONFIG_NETFILTER_XT_MATCH_IPRANGE is not set | ||
417 | # CONFIG_NETFILTER_XT_MATCH_LENGTH is not set | ||
418 | # CONFIG_NETFILTER_XT_MATCH_LIMIT is not set | ||
419 | # CONFIG_NETFILTER_XT_MATCH_MAC is not set | ||
420 | # CONFIG_NETFILTER_XT_MATCH_MARK is not set | ||
421 | # CONFIG_NETFILTER_XT_MATCH_MULTIPORT is not set | ||
422 | # CONFIG_NETFILTER_XT_MATCH_OWNER is not set | ||
423 | # CONFIG_NETFILTER_XT_MATCH_POLICY is not set | ||
424 | # CONFIG_NETFILTER_XT_MATCH_PKTTYPE is not set | ||
425 | # CONFIG_NETFILTER_XT_MATCH_QUOTA is not set | ||
426 | # CONFIG_NETFILTER_XT_MATCH_RATEEST is not set | ||
427 | # CONFIG_NETFILTER_XT_MATCH_REALM is not set | ||
428 | # CONFIG_NETFILTER_XT_MATCH_RECENT is not set | ||
429 | # CONFIG_NETFILTER_XT_MATCH_SCTP is not set | ||
430 | # CONFIG_NETFILTER_XT_MATCH_STATISTIC is not set | ||
431 | # CONFIG_NETFILTER_XT_MATCH_STRING is not set | ||
432 | # CONFIG_NETFILTER_XT_MATCH_TCPMSS is not set | ||
433 | # CONFIG_NETFILTER_XT_MATCH_TIME is not set | ||
434 | # CONFIG_NETFILTER_XT_MATCH_U32 is not set | ||
435 | # CONFIG_IP_VS is not set | ||
263 | 436 | ||
264 | # | 437 | # |
265 | # IP: Netfilter Configuration | 438 | # IP: Netfilter Configuration |
266 | # | 439 | # |
267 | CONFIG_IP_NF_CONNTRACK=m | 440 | # CONFIG_NF_DEFRAG_IPV4 is not set |
268 | # CONFIG_IP_NF_CT_ACCT is not set | ||
269 | # CONFIG_IP_NF_CONNTRACK_MARK is not set | ||
270 | # CONFIG_IP_NF_CONNTRACK_EVENTS is not set | ||
271 | CONFIG_IP_NF_CT_PROTO_SCTP=m | ||
272 | CONFIG_IP_NF_FTP=m | ||
273 | CONFIG_IP_NF_IRC=m | ||
274 | # CONFIG_IP_NF_NETBIOS_NS is not set | ||
275 | CONFIG_IP_NF_TFTP=m | ||
276 | CONFIG_IP_NF_AMANDA=m | ||
277 | # CONFIG_IP_NF_PPTP is not set | ||
278 | CONFIG_IP_NF_QUEUE=m | 441 | CONFIG_IP_NF_QUEUE=m |
279 | CONFIG_IP_NF_IPTABLES=m | 442 | CONFIG_IP_NF_IPTABLES=m |
280 | CONFIG_IP_NF_MATCH_LIMIT=m | 443 | CONFIG_IP_NF_MATCH_ADDRTYPE=m |
281 | CONFIG_IP_NF_MATCH_IPRANGE=m | 444 | # CONFIG_IP_NF_MATCH_AH is not set |
282 | CONFIG_IP_NF_MATCH_MAC=m | ||
283 | CONFIG_IP_NF_MATCH_PKTTYPE=m | ||
284 | CONFIG_IP_NF_MATCH_MARK=m | ||
285 | CONFIG_IP_NF_MATCH_MULTIPORT=m | ||
286 | CONFIG_IP_NF_MATCH_TOS=m | ||
287 | CONFIG_IP_NF_MATCH_RECENT=m | ||
288 | CONFIG_IP_NF_MATCH_ECN=m | 445 | CONFIG_IP_NF_MATCH_ECN=m |
289 | CONFIG_IP_NF_MATCH_DSCP=m | ||
290 | CONFIG_IP_NF_MATCH_AH_ESP=m | ||
291 | CONFIG_IP_NF_MATCH_LENGTH=m | ||
292 | CONFIG_IP_NF_MATCH_TTL=m | 446 | CONFIG_IP_NF_MATCH_TTL=m |
293 | CONFIG_IP_NF_MATCH_TCPMSS=m | ||
294 | CONFIG_IP_NF_MATCH_HELPER=m | ||
295 | CONFIG_IP_NF_MATCH_STATE=m | ||
296 | CONFIG_IP_NF_MATCH_CONNTRACK=m | ||
297 | CONFIG_IP_NF_MATCH_OWNER=m | ||
298 | CONFIG_IP_NF_MATCH_ADDRTYPE=m | ||
299 | CONFIG_IP_NF_MATCH_REALM=m | ||
300 | CONFIG_IP_NF_MATCH_SCTP=m | ||
301 | # CONFIG_IP_NF_MATCH_DCCP is not set | ||
302 | CONFIG_IP_NF_MATCH_COMMENT=m | ||
303 | CONFIG_IP_NF_MATCH_HASHLIMIT=m | ||
304 | # CONFIG_IP_NF_MATCH_STRING is not set | ||
305 | CONFIG_IP_NF_FILTER=m | 447 | CONFIG_IP_NF_FILTER=m |
306 | # CONFIG_IP_NF_TARGET_REJECT is not set | 448 | # CONFIG_IP_NF_TARGET_REJECT is not set |
307 | CONFIG_IP_NF_TARGET_LOG=m | 449 | CONFIG_IP_NF_TARGET_LOG=m |
308 | CONFIG_IP_NF_TARGET_ULOG=m | 450 | CONFIG_IP_NF_TARGET_ULOG=m |
309 | CONFIG_IP_NF_TARGET_TCPMSS=m | ||
310 | # CONFIG_IP_NF_TARGET_NFQUEUE is not set | ||
311 | CONFIG_IP_NF_NAT=m | ||
312 | CONFIG_IP_NF_NAT_NEEDED=y | ||
313 | # CONFIG_IP_NF_TARGET_MASQUERADE is not set | ||
314 | # CONFIG_IP_NF_TARGET_REDIRECT is not set | ||
315 | # CONFIG_IP_NF_TARGET_NETMAP is not set | ||
316 | # CONFIG_IP_NF_TARGET_SAME is not set | ||
317 | # CONFIG_IP_NF_NAT_SNMP_BASIC is not set | ||
318 | CONFIG_IP_NF_NAT_IRC=m | ||
319 | CONFIG_IP_NF_NAT_FTP=m | ||
320 | CONFIG_IP_NF_NAT_TFTP=m | ||
321 | CONFIG_IP_NF_NAT_AMANDA=m | ||
322 | CONFIG_IP_NF_MANGLE=m | 451 | CONFIG_IP_NF_MANGLE=m |
323 | # CONFIG_IP_NF_TARGET_TOS is not set | ||
324 | # CONFIG_IP_NF_TARGET_ECN is not set | 452 | # CONFIG_IP_NF_TARGET_ECN is not set |
325 | # CONFIG_IP_NF_TARGET_DSCP is not set | ||
326 | # CONFIG_IP_NF_TARGET_MARK is not set | ||
327 | # CONFIG_IP_NF_TARGET_CLASSIFY is not set | ||
328 | # CONFIG_IP_NF_TARGET_TTL is not set | 453 | # CONFIG_IP_NF_TARGET_TTL is not set |
329 | CONFIG_IP_NF_RAW=m | 454 | CONFIG_IP_NF_RAW=m |
330 | # CONFIG_IP_NF_TARGET_NOTRACK is not set | ||
331 | CONFIG_IP_NF_ARPTABLES=m | 455 | CONFIG_IP_NF_ARPTABLES=m |
332 | CONFIG_IP_NF_ARPFILTER=m | 456 | CONFIG_IP_NF_ARPFILTER=m |
333 | CONFIG_IP_NF_ARP_MANGLE=m | 457 | CONFIG_IP_NF_ARP_MANGLE=m |
334 | 458 | ||
335 | # | 459 | # |
336 | # IPv6: Netfilter Configuration (EXPERIMENTAL) | 460 | # IPv6: Netfilter Configuration |
337 | # | 461 | # |
338 | CONFIG_IP6_NF_QUEUE=m | 462 | CONFIG_IP6_NF_QUEUE=m |
339 | CONFIG_IP6_NF_IPTABLES=m | 463 | CONFIG_IP6_NF_IPTABLES=m |
340 | CONFIG_IP6_NF_MATCH_LIMIT=m | 464 | # CONFIG_IP6_NF_MATCH_AH is not set |
341 | CONFIG_IP6_NF_MATCH_MAC=m | 465 | CONFIG_IP6_NF_MATCH_EUI64=m |
342 | CONFIG_IP6_NF_MATCH_RT=m | ||
343 | CONFIG_IP6_NF_MATCH_OPTS=m | ||
344 | CONFIG_IP6_NF_MATCH_FRAG=m | 466 | CONFIG_IP6_NF_MATCH_FRAG=m |
467 | CONFIG_IP6_NF_MATCH_OPTS=m | ||
345 | CONFIG_IP6_NF_MATCH_HL=m | 468 | CONFIG_IP6_NF_MATCH_HL=m |
346 | CONFIG_IP6_NF_MATCH_MULTIPORT=m | ||
347 | CONFIG_IP6_NF_MATCH_OWNER=m | ||
348 | CONFIG_IP6_NF_MATCH_MARK=m | ||
349 | CONFIG_IP6_NF_MATCH_IPV6HEADER=m | 469 | CONFIG_IP6_NF_MATCH_IPV6HEADER=m |
350 | CONFIG_IP6_NF_MATCH_AHESP=m | 470 | # CONFIG_IP6_NF_MATCH_MH is not set |
351 | CONFIG_IP6_NF_MATCH_LENGTH=m | 471 | CONFIG_IP6_NF_MATCH_RT=m |
352 | CONFIG_IP6_NF_MATCH_EUI64=m | ||
353 | CONFIG_IP6_NF_FILTER=m | ||
354 | # CONFIG_IP6_NF_TARGET_LOG is not set | 472 | # CONFIG_IP6_NF_TARGET_LOG is not set |
473 | CONFIG_IP6_NF_FILTER=m | ||
355 | # CONFIG_IP6_NF_TARGET_REJECT is not set | 474 | # CONFIG_IP6_NF_TARGET_REJECT is not set |
356 | # CONFIG_IP6_NF_TARGET_NFQUEUE is not set | ||
357 | CONFIG_IP6_NF_MANGLE=m | 475 | CONFIG_IP6_NF_MANGLE=m |
358 | # CONFIG_IP6_NF_TARGET_MARK is not set | ||
359 | # CONFIG_IP6_NF_TARGET_HL is not set | 476 | # CONFIG_IP6_NF_TARGET_HL is not set |
360 | CONFIG_IP6_NF_RAW=m | 477 | CONFIG_IP6_NF_RAW=m |
361 | |||
362 | # | ||
363 | # DCCP Configuration (EXPERIMENTAL) | ||
364 | # | ||
365 | # CONFIG_IP_DCCP is not set | 478 | # CONFIG_IP_DCCP is not set |
366 | |||
367 | # | ||
368 | # SCTP Configuration (EXPERIMENTAL) | ||
369 | # | ||
370 | # CONFIG_IP_SCTP is not set | 479 | # CONFIG_IP_SCTP is not set |
480 | # CONFIG_TIPC is not set | ||
371 | # CONFIG_ATM is not set | 481 | # CONFIG_ATM is not set |
372 | # CONFIG_BRIDGE is not set | 482 | # CONFIG_BRIDGE is not set |
483 | # CONFIG_NET_DSA is not set | ||
373 | # CONFIG_VLAN_8021Q is not set | 484 | # CONFIG_VLAN_8021Q is not set |
374 | # CONFIG_DECNET is not set | 485 | # CONFIG_DECNET is not set |
375 | # CONFIG_LLC2 is not set | 486 | # CONFIG_LLC2 is not set |
@@ -377,21 +488,16 @@ CONFIG_IP6_NF_RAW=m | |||
377 | # CONFIG_ATALK is not set | 488 | # CONFIG_ATALK is not set |
378 | # CONFIG_X25 is not set | 489 | # CONFIG_X25 is not set |
379 | # CONFIG_LAPB is not set | 490 | # CONFIG_LAPB is not set |
380 | # CONFIG_NET_DIVERT is not set | ||
381 | # CONFIG_ECONET is not set | 491 | # CONFIG_ECONET is not set |
382 | # CONFIG_WAN_ROUTER is not set | 492 | # CONFIG_WAN_ROUTER is not set |
383 | |||
384 | # | ||
385 | # QoS and/or fair queueing | ||
386 | # | ||
387 | # CONFIG_NET_SCHED is not set | 493 | # CONFIG_NET_SCHED is not set |
388 | CONFIG_NET_CLS_ROUTE=y | ||
389 | 494 | ||
390 | # | 495 | # |
391 | # Network testing | 496 | # Network testing |
392 | # | 497 | # |
393 | # CONFIG_NET_PKTGEN is not set | 498 | # CONFIG_NET_PKTGEN is not set |
394 | # CONFIG_HAMRADIO is not set | 499 | # CONFIG_HAMRADIO is not set |
500 | # CONFIG_CAN is not set | ||
395 | CONFIG_IRDA=m | 501 | CONFIG_IRDA=m |
396 | 502 | ||
397 | # | 503 | # |
@@ -421,27 +527,17 @@ CONFIG_IRCOMM=m | |||
421 | # | 527 | # |
422 | # Dongle support | 528 | # Dongle support |
423 | # | 529 | # |
424 | 530 | # CONFIG_KINGSUN_DONGLE is not set | |
425 | # | 531 | # CONFIG_KSDAZZLE_DONGLE is not set |
426 | # Old SIR device drivers | 532 | # CONFIG_KS959_DONGLE is not set |
427 | # | ||
428 | # CONFIG_IRPORT_SIR is not set | ||
429 | |||
430 | # | ||
431 | # Old Serial dongle support | ||
432 | # | ||
433 | 533 | ||
434 | # | 534 | # |
435 | # FIR device drivers | 535 | # FIR device drivers |
436 | # | 536 | # |
437 | # CONFIG_USB_IRDA is not set | 537 | # CONFIG_USB_IRDA is not set |
438 | # CONFIG_SIGMATEL_FIR is not set | 538 | # CONFIG_SIGMATEL_FIR is not set |
439 | # CONFIG_NSC_FIR is not set | ||
440 | # CONFIG_WINBOND_FIR is not set | ||
441 | # CONFIG_SMC_IRCC_FIR is not set | ||
442 | # CONFIG_ALI_FIR is not set | ||
443 | # CONFIG_VIA_FIR is not set | ||
444 | CONFIG_PXA_FICP=m | 539 | CONFIG_PXA_FICP=m |
540 | # CONFIG_MCS_FIR is not set | ||
445 | CONFIG_BT=m | 541 | CONFIG_BT=m |
446 | CONFIG_BT_L2CAP=m | 542 | CONFIG_BT_L2CAP=m |
447 | CONFIG_BT_SCO=m | 543 | CONFIG_BT_SCO=m |
@@ -457,9 +553,12 @@ CONFIG_BT_HIDP=m | |||
457 | # | 553 | # |
458 | CONFIG_BT_HCIUSB=m | 554 | CONFIG_BT_HCIUSB=m |
459 | # CONFIG_BT_HCIUSB_SCO is not set | 555 | # CONFIG_BT_HCIUSB_SCO is not set |
556 | # CONFIG_BT_HCIBTUSB is not set | ||
557 | # CONFIG_BT_HCIBTSDIO is not set | ||
460 | CONFIG_BT_HCIUART=m | 558 | CONFIG_BT_HCIUART=m |
461 | CONFIG_BT_HCIUART_H4=y | 559 | CONFIG_BT_HCIUART_H4=y |
462 | CONFIG_BT_HCIUART_BCSP=y | 560 | CONFIG_BT_HCIUART_BCSP=y |
561 | # CONFIG_BT_HCIUART_LL is not set | ||
463 | CONFIG_BT_HCIBCM203X=m | 562 | CONFIG_BT_HCIBCM203X=m |
464 | CONFIG_BT_HCIBPA10X=m | 563 | CONFIG_BT_HCIBPA10X=m |
465 | CONFIG_BT_HCIBFUSB=m | 564 | CONFIG_BT_HCIBFUSB=m |
@@ -468,11 +567,20 @@ CONFIG_BT_HCIBT3C=m | |||
468 | CONFIG_BT_HCIBLUECARD=m | 567 | CONFIG_BT_HCIBLUECARD=m |
469 | CONFIG_BT_HCIBTUART=m | 568 | CONFIG_BT_HCIBTUART=m |
470 | CONFIG_BT_HCIVHCI=m | 569 | CONFIG_BT_HCIVHCI=m |
570 | # CONFIG_AF_RXRPC is not set | ||
571 | # CONFIG_PHONET is not set | ||
572 | CONFIG_WIRELESS=y | ||
573 | # CONFIG_CFG80211 is not set | ||
574 | # CONFIG_WIRELESS_OLD_REGULATORY is not set | ||
575 | # CONFIG_WIRELESS_EXT is not set | ||
576 | # CONFIG_MAC80211 is not set | ||
471 | CONFIG_IEEE80211=m | 577 | CONFIG_IEEE80211=m |
472 | # CONFIG_IEEE80211_DEBUG is not set | 578 | # CONFIG_IEEE80211_DEBUG is not set |
473 | CONFIG_IEEE80211_CRYPT_WEP=m | 579 | CONFIG_IEEE80211_CRYPT_WEP=m |
474 | # CONFIG_IEEE80211_CRYPT_CCMP is not set | 580 | # CONFIG_IEEE80211_CRYPT_CCMP is not set |
475 | # CONFIG_IEEE80211_CRYPT_TKIP is not set | 581 | # CONFIG_IEEE80211_CRYPT_TKIP is not set |
582 | # CONFIG_RFKILL is not set | ||
583 | # CONFIG_NET_9P is not set | ||
476 | 584 | ||
477 | # | 585 | # |
478 | # Device Drivers | 586 | # Device Drivers |
@@ -481,19 +589,16 @@ CONFIG_IEEE80211_CRYPT_WEP=m | |||
481 | # | 589 | # |
482 | # Generic Driver Options | 590 | # Generic Driver Options |
483 | # | 591 | # |
592 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | ||
484 | CONFIG_STANDALONE=y | 593 | CONFIG_STANDALONE=y |
485 | CONFIG_PREVENT_FIRMWARE_BUILD=y | 594 | CONFIG_PREVENT_FIRMWARE_BUILD=y |
486 | CONFIG_FW_LOADER=y | 595 | CONFIG_FW_LOADER=y |
596 | CONFIG_FIRMWARE_IN_KERNEL=y | ||
597 | CONFIG_EXTRA_FIRMWARE="" | ||
487 | # CONFIG_DEBUG_DRIVER is not set | 598 | # CONFIG_DEBUG_DRIVER is not set |
488 | 599 | # CONFIG_DEBUG_DEVRES is not set | |
489 | # | 600 | # CONFIG_SYS_HYPERVISOR is not set |
490 | # Connector - unified userspace <-> kernelspace linker | ||
491 | # | ||
492 | # CONFIG_CONNECTOR is not set | 601 | # CONFIG_CONNECTOR is not set |
493 | |||
494 | # | ||
495 | # Memory Technology Devices (MTD) | ||
496 | # | ||
497 | CONFIG_MTD=y | 602 | CONFIG_MTD=y |
498 | # CONFIG_MTD_DEBUG is not set | 603 | # CONFIG_MTD_DEBUG is not set |
499 | # CONFIG_MTD_CONCAT is not set | 604 | # CONFIG_MTD_CONCAT is not set |
@@ -501,16 +606,20 @@ CONFIG_MTD_PARTITIONS=y | |||
501 | # CONFIG_MTD_REDBOOT_PARTS is not set | 606 | # CONFIG_MTD_REDBOOT_PARTS is not set |
502 | CONFIG_MTD_CMDLINE_PARTS=y | 607 | CONFIG_MTD_CMDLINE_PARTS=y |
503 | # CONFIG_MTD_AFS_PARTS is not set | 608 | # CONFIG_MTD_AFS_PARTS is not set |
609 | # CONFIG_MTD_AR7_PARTS is not set | ||
504 | 610 | ||
505 | # | 611 | # |
506 | # User Modules And Translation Layers | 612 | # User Modules And Translation Layers |
507 | # | 613 | # |
508 | CONFIG_MTD_CHAR=y | 614 | CONFIG_MTD_CHAR=y |
615 | CONFIG_MTD_BLKDEVS=y | ||
509 | CONFIG_MTD_BLOCK=y | 616 | CONFIG_MTD_BLOCK=y |
510 | # CONFIG_FTL is not set | 617 | # CONFIG_FTL is not set |
511 | # CONFIG_NFTL is not set | 618 | # CONFIG_NFTL is not set |
512 | # CONFIG_INFTL is not set | 619 | # CONFIG_INFTL is not set |
513 | # CONFIG_RFD_FTL is not set | 620 | # CONFIG_RFD_FTL is not set |
621 | # CONFIG_SSFDC is not set | ||
622 | # CONFIG_MTD_OOPS is not set | ||
514 | 623 | ||
515 | # | 624 | # |
516 | # RAM/ROM/Flash chip drivers | 625 | # RAM/ROM/Flash chip drivers |
@@ -535,16 +644,18 @@ CONFIG_MTD_ROM=y | |||
535 | # Mapping drivers for chip access | 644 | # Mapping drivers for chip access |
536 | # | 645 | # |
537 | CONFIG_MTD_COMPLEX_MAPPINGS=y | 646 | CONFIG_MTD_COMPLEX_MAPPINGS=y |
647 | # CONFIG_MTD_PHYSMAP is not set | ||
538 | CONFIG_MTD_SHARP_SL=y | 648 | CONFIG_MTD_SHARP_SL=y |
539 | # CONFIG_MTD_PLATRAM is not set | 649 | # CONFIG_MTD_PLATRAM is not set |
540 | 650 | ||
541 | # | 651 | # |
542 | # Self-contained MTD device drivers | 652 | # Self-contained MTD device drivers |
543 | # | 653 | # |
654 | # CONFIG_MTD_DATAFLASH is not set | ||
655 | # CONFIG_MTD_M25P80 is not set | ||
544 | # CONFIG_MTD_SLRAM is not set | 656 | # CONFIG_MTD_SLRAM is not set |
545 | # CONFIG_MTD_PHRAM is not set | 657 | # CONFIG_MTD_PHRAM is not set |
546 | # CONFIG_MTD_MTDRAM is not set | 658 | # CONFIG_MTD_MTDRAM is not set |
547 | # CONFIG_MTD_BLKMTD is not set | ||
548 | # CONFIG_MTD_BLOCK2MTD is not set | 659 | # CONFIG_MTD_BLOCK2MTD is not set |
549 | 660 | ||
550 | # | 661 | # |
@@ -553,78 +664,66 @@ CONFIG_MTD_SHARP_SL=y | |||
553 | # CONFIG_MTD_DOC2000 is not set | 664 | # CONFIG_MTD_DOC2000 is not set |
554 | # CONFIG_MTD_DOC2001 is not set | 665 | # CONFIG_MTD_DOC2001 is not set |
555 | # CONFIG_MTD_DOC2001PLUS is not set | 666 | # CONFIG_MTD_DOC2001PLUS is not set |
556 | |||
557 | # | ||
558 | # NAND Flash Device Drivers | ||
559 | # | ||
560 | CONFIG_MTD_NAND=y | 667 | CONFIG_MTD_NAND=y |
561 | CONFIG_MTD_NAND_VERIFY_WRITE=y | 668 | CONFIG_MTD_NAND_VERIFY_WRITE=y |
669 | # CONFIG_MTD_NAND_ECC_SMC is not set | ||
670 | # CONFIG_MTD_NAND_MUSEUM_IDS is not set | ||
562 | # CONFIG_MTD_NAND_H1900 is not set | 671 | # CONFIG_MTD_NAND_H1900 is not set |
563 | CONFIG_MTD_NAND_IDS=y | 672 | CONFIG_MTD_NAND_IDS=y |
564 | # CONFIG_MTD_NAND_DISKONCHIP is not set | 673 | # CONFIG_MTD_NAND_DISKONCHIP is not set |
565 | CONFIG_MTD_NAND_SHARPSL=y | 674 | CONFIG_MTD_NAND_SHARPSL=y |
566 | # CONFIG_MTD_NAND_NANDSIM is not set | 675 | # CONFIG_MTD_NAND_NANDSIM is not set |
567 | 676 | # CONFIG_MTD_NAND_PLATFORM is not set | |
568 | # | 677 | # CONFIG_MTD_ALAUDA is not set |
569 | # OneNAND Flash Device Drivers | ||
570 | # | ||
571 | # CONFIG_MTD_ONENAND is not set | 678 | # CONFIG_MTD_ONENAND is not set |
572 | 679 | ||
573 | # | 680 | # |
574 | # Parallel port support | 681 | # UBI - Unsorted block images |
575 | # | 682 | # |
683 | # CONFIG_MTD_UBI is not set | ||
576 | # CONFIG_PARPORT is not set | 684 | # CONFIG_PARPORT is not set |
577 | 685 | CONFIG_BLK_DEV=y | |
578 | # | ||
579 | # Plug and Play support | ||
580 | # | ||
581 | |||
582 | # | ||
583 | # Block devices | ||
584 | # | ||
585 | # CONFIG_BLK_DEV_COW_COMMON is not set | 686 | # CONFIG_BLK_DEV_COW_COMMON is not set |
586 | CONFIG_BLK_DEV_LOOP=y | 687 | CONFIG_BLK_DEV_LOOP=y |
587 | # CONFIG_BLK_DEV_CRYPTOLOOP is not set | 688 | # CONFIG_BLK_DEV_CRYPTOLOOP is not set |
588 | # CONFIG_BLK_DEV_NBD is not set | 689 | # CONFIG_BLK_DEV_NBD is not set |
589 | # CONFIG_BLK_DEV_UB is not set | 690 | # CONFIG_BLK_DEV_UB is not set |
590 | # CONFIG_BLK_DEV_RAM is not set | 691 | # CONFIG_BLK_DEV_RAM is not set |
591 | CONFIG_BLK_DEV_RAM_COUNT=16 | ||
592 | # CONFIG_CDROM_PKTCDVD is not set | 692 | # CONFIG_CDROM_PKTCDVD is not set |
593 | # CONFIG_ATA_OVER_ETH is not set | 693 | # CONFIG_ATA_OVER_ETH is not set |
594 | 694 | CONFIG_MISC_DEVICES=y | |
595 | # | 695 | # CONFIG_EEPROM_93CX6 is not set |
596 | # ATA/ATAPI/MFM/RLL support | 696 | # CONFIG_ENCLOSURE_SERVICES is not set |
597 | # | 697 | CONFIG_HAVE_IDE=y |
598 | CONFIG_IDE=y | 698 | CONFIG_IDE=y |
599 | CONFIG_BLK_DEV_IDE=y | ||
600 | 699 | ||
601 | # | 700 | # |
602 | # Please see Documentation/ide.txt for help/info on IDE drives | 701 | # Please see Documentation/ide/ide.txt for help/info on IDE drives |
603 | # | 702 | # |
604 | # CONFIG_BLK_DEV_IDE_SATA is not set | 703 | # CONFIG_BLK_DEV_IDE_SATA is not set |
605 | CONFIG_BLK_DEV_IDEDISK=y | 704 | CONFIG_BLK_DEV_IDEDISK=y |
606 | # CONFIG_IDEDISK_MULTI_MODE is not set | ||
607 | CONFIG_BLK_DEV_IDECS=y | 705 | CONFIG_BLK_DEV_IDECS=y |
608 | # CONFIG_BLK_DEV_IDECD is not set | 706 | # CONFIG_BLK_DEV_IDECD is not set |
609 | # CONFIG_BLK_DEV_IDETAPE is not set | 707 | # CONFIG_BLK_DEV_IDETAPE is not set |
610 | # CONFIG_BLK_DEV_IDEFLOPPY is not set | 708 | # CONFIG_BLK_DEV_IDEFLOPPY is not set |
611 | # CONFIG_BLK_DEV_IDESCSI is not set | 709 | # CONFIG_BLK_DEV_IDESCSI is not set |
612 | # CONFIG_IDE_TASK_IOCTL is not set | 710 | # CONFIG_IDE_TASK_IOCTL is not set |
711 | CONFIG_IDE_PROC_FS=y | ||
613 | 712 | ||
614 | # | 713 | # |
615 | # IDE chipset support/bugfixes | 714 | # IDE chipset support/bugfixes |
616 | # | 715 | # |
617 | CONFIG_IDE_GENERIC=y | 716 | # CONFIG_BLK_DEV_PLATFORM is not set |
618 | # CONFIG_IDE_ARM is not set | ||
619 | # CONFIG_BLK_DEV_IDEDMA is not set | 717 | # CONFIG_BLK_DEV_IDEDMA is not set |
620 | # CONFIG_IDEDMA_AUTO is not set | ||
621 | # CONFIG_BLK_DEV_HD is not set | ||
622 | 718 | ||
623 | # | 719 | # |
624 | # SCSI device support | 720 | # SCSI device support |
625 | # | 721 | # |
626 | # CONFIG_RAID_ATTRS is not set | 722 | # CONFIG_RAID_ATTRS is not set |
627 | CONFIG_SCSI=m | 723 | CONFIG_SCSI=m |
724 | CONFIG_SCSI_DMA=y | ||
725 | # CONFIG_SCSI_TGT is not set | ||
726 | # CONFIG_SCSI_NETLINK is not set | ||
628 | CONFIG_SCSI_PROC_FS=y | 727 | CONFIG_SCSI_PROC_FS=y |
629 | 728 | ||
630 | # | 729 | # |
@@ -644,121 +743,76 @@ CONFIG_CHR_DEV_SG=m | |||
644 | CONFIG_SCSI_MULTI_LUN=y | 743 | CONFIG_SCSI_MULTI_LUN=y |
645 | # CONFIG_SCSI_CONSTANTS is not set | 744 | # CONFIG_SCSI_CONSTANTS is not set |
646 | # CONFIG_SCSI_LOGGING is not set | 745 | # CONFIG_SCSI_LOGGING is not set |
746 | # CONFIG_SCSI_SCAN_ASYNC is not set | ||
747 | CONFIG_SCSI_WAIT_SCAN=m | ||
647 | 748 | ||
648 | # | 749 | # |
649 | # SCSI Transport Attributes | 750 | # SCSI Transports |
650 | # | 751 | # |
651 | # CONFIG_SCSI_SPI_ATTRS is not set | 752 | # CONFIG_SCSI_SPI_ATTRS is not set |
652 | # CONFIG_SCSI_FC_ATTRS is not set | 753 | # CONFIG_SCSI_FC_ATTRS is not set |
653 | # CONFIG_SCSI_ISCSI_ATTRS is not set | 754 | # CONFIG_SCSI_ISCSI_ATTRS is not set |
654 | # CONFIG_SCSI_SAS_ATTRS is not set | 755 | # CONFIG_SCSI_SAS_LIBSAS is not set |
655 | 756 | # CONFIG_SCSI_SRP_ATTRS is not set | |
656 | # | 757 | CONFIG_SCSI_LOWLEVEL=y |
657 | # SCSI low-level drivers | ||
658 | # | ||
659 | # CONFIG_ISCSI_TCP is not set | 758 | # CONFIG_ISCSI_TCP is not set |
660 | # CONFIG_SCSI_SATA is not set | ||
661 | # CONFIG_SCSI_DEBUG is not set | 759 | # CONFIG_SCSI_DEBUG is not set |
662 | 760 | # CONFIG_SCSI_LOWLEVEL_PCMCIA is not set | |
663 | # | 761 | # CONFIG_SCSI_DH is not set |
664 | # PCMCIA SCSI adapter support | 762 | # CONFIG_ATA is not set |
665 | # | ||
666 | # CONFIG_PCMCIA_AHA152X is not set | ||
667 | # CONFIG_PCMCIA_FDOMAIN is not set | ||
668 | # CONFIG_PCMCIA_NINJA_SCSI is not set | ||
669 | # CONFIG_PCMCIA_QLOGIC is not set | ||
670 | # CONFIG_PCMCIA_SYM53C500 is not set | ||
671 | |||
672 | # | ||
673 | # Multi-device support (RAID and LVM) | ||
674 | # | ||
675 | # CONFIG_MD is not set | 763 | # CONFIG_MD is not set |
676 | |||
677 | # | ||
678 | # Fusion MPT device support | ||
679 | # | ||
680 | # CONFIG_FUSION is not set | ||
681 | |||
682 | # | ||
683 | # IEEE 1394 (FireWire) support | ||
684 | # | ||
685 | |||
686 | # | ||
687 | # I2O device support | ||
688 | # | ||
689 | |||
690 | # | ||
691 | # Network device support | ||
692 | # | ||
693 | CONFIG_NETDEVICES=y | 764 | CONFIG_NETDEVICES=y |
694 | # CONFIG_DUMMY is not set | 765 | # CONFIG_DUMMY is not set |
695 | # CONFIG_BONDING is not set | 766 | # CONFIG_BONDING is not set |
767 | # CONFIG_MACVLAN is not set | ||
696 | # CONFIG_EQUALIZER is not set | 768 | # CONFIG_EQUALIZER is not set |
697 | # CONFIG_TUN is not set | 769 | # CONFIG_TUN is not set |
698 | 770 | # CONFIG_VETH is not set | |
699 | # | ||
700 | # PHY device support | ||
701 | # | ||
702 | # CONFIG_PHYLIB is not set | 771 | # CONFIG_PHYLIB is not set |
703 | |||
704 | # | ||
705 | # Ethernet (10 or 100Mbit) | ||
706 | # | ||
707 | CONFIG_NET_ETHERNET=y | 772 | CONFIG_NET_ETHERNET=y |
708 | CONFIG_MII=m | 773 | CONFIG_MII=m |
774 | # CONFIG_AX88796 is not set | ||
709 | # CONFIG_SMC91X is not set | 775 | # CONFIG_SMC91X is not set |
710 | # CONFIG_DM9000 is not set | 776 | # CONFIG_DM9000 is not set |
777 | # CONFIG_ENC28J60 is not set | ||
778 | # CONFIG_SMC911X is not set | ||
779 | # CONFIG_IBM_NEW_EMAC_ZMII is not set | ||
780 | # CONFIG_IBM_NEW_EMAC_RGMII is not set | ||
781 | # CONFIG_IBM_NEW_EMAC_TAH is not set | ||
782 | # CONFIG_IBM_NEW_EMAC_EMAC4 is not set | ||
783 | # CONFIG_IBM_NEW_EMAC_NO_FLOW_CTRL is not set | ||
784 | # CONFIG_IBM_NEW_EMAC_MAL_CLR_ICINTSTAT is not set | ||
785 | # CONFIG_IBM_NEW_EMAC_MAL_COMMON_ERR is not set | ||
786 | # CONFIG_B44 is not set | ||
787 | CONFIG_NETDEV_1000=y | ||
788 | CONFIG_NETDEV_10000=y | ||
711 | 789 | ||
712 | # | 790 | # |
713 | # Ethernet (1000 Mbit) | 791 | # Wireless LAN |
714 | # | ||
715 | |||
716 | # | ||
717 | # Ethernet (10000 Mbit) | ||
718 | # | ||
719 | |||
720 | # | ||
721 | # Token Ring devices | ||
722 | # | ||
723 | |||
724 | # | ||
725 | # Wireless LAN (non-hamradio) | ||
726 | # | ||
727 | CONFIG_NET_RADIO=y | ||
728 | |||
729 | # | ||
730 | # Obsolete Wireless cards support (pre-802.11) | ||
731 | # | ||
732 | # CONFIG_STRIP is not set | ||
733 | # CONFIG_PCMCIA_WAVELAN is not set | ||
734 | # CONFIG_PCMCIA_NETWAVE is not set | ||
735 | |||
736 | # | ||
737 | # Wireless 802.11 Frequency Hopping cards support | ||
738 | # | 792 | # |
739 | # CONFIG_PCMCIA_RAYCS is not set | 793 | # CONFIG_WLAN_PRE80211 is not set |
794 | # CONFIG_WLAN_80211 is not set | ||
795 | # CONFIG_IWLWIFI_LEDS is not set | ||
740 | 796 | ||
741 | # | 797 | # |
742 | # Wireless 802.11b ISA/PCI cards support | 798 | # USB Network Adapters |
743 | # | ||
744 | CONFIG_HERMES=m | ||
745 | # CONFIG_ATMEL is not set | ||
746 | |||
747 | # | ||
748 | # Wireless 802.11b Pcmcia/Cardbus cards support | ||
749 | # | ||
750 | CONFIG_PCMCIA_HERMES=m | ||
751 | CONFIG_PCMCIA_SPECTRUM=m | ||
752 | # CONFIG_AIRO_CS is not set | ||
753 | # CONFIG_PCMCIA_WL3501 is not set | ||
754 | CONFIG_HOSTAP=m | ||
755 | CONFIG_HOSTAP_FIRMWARE=y | ||
756 | CONFIG_HOSTAP_CS=m | ||
757 | CONFIG_NET_WIRELESS=y | ||
758 | |||
759 | # | ||
760 | # PCMCIA network device support | ||
761 | # | 799 | # |
800 | CONFIG_USB_CATC=m | ||
801 | CONFIG_USB_KAWETH=m | ||
802 | CONFIG_USB_PEGASUS=m | ||
803 | CONFIG_USB_RTL8150=m | ||
804 | CONFIG_USB_USBNET=m | ||
805 | CONFIG_USB_NET_AX8817X=m | ||
806 | CONFIG_USB_NET_CDCETHER=m | ||
807 | # CONFIG_USB_NET_DM9601 is not set | ||
808 | # CONFIG_USB_NET_SMSC95XX is not set | ||
809 | # CONFIG_USB_NET_GL620A is not set | ||
810 | CONFIG_USB_NET_NET1080=m | ||
811 | # CONFIG_USB_NET_PLUSB is not set | ||
812 | # CONFIG_USB_NET_MCS7830 is not set | ||
813 | # CONFIG_USB_NET_RNDIS_HOST is not set | ||
814 | # CONFIG_USB_NET_CDC_SUBSET is not set | ||
815 | CONFIG_USB_NET_ZAURUS=m | ||
762 | CONFIG_NET_PCMCIA=y | 816 | CONFIG_NET_PCMCIA=y |
763 | # CONFIG_PCMCIA_3C589 is not set | 817 | # CONFIG_PCMCIA_3C589 is not set |
764 | # CONFIG_PCMCIA_3C574 is not set | 818 | # CONFIG_PCMCIA_3C574 is not set |
@@ -768,10 +822,6 @@ CONFIG_PCMCIA_PCNET=m | |||
768 | # CONFIG_PCMCIA_SMC91C92 is not set | 822 | # CONFIG_PCMCIA_SMC91C92 is not set |
769 | # CONFIG_PCMCIA_XIRC2PS is not set | 823 | # CONFIG_PCMCIA_XIRC2PS is not set |
770 | # CONFIG_PCMCIA_AXNET is not set | 824 | # CONFIG_PCMCIA_AXNET is not set |
771 | |||
772 | # | ||
773 | # Wan interfaces | ||
774 | # | ||
775 | # CONFIG_WAN is not set | 825 | # CONFIG_WAN is not set |
776 | CONFIG_PPP=m | 826 | CONFIG_PPP=m |
777 | # CONFIG_PPP_MULTILINK is not set | 827 | # CONFIG_PPP_MULTILINK is not set |
@@ -782,30 +832,29 @@ CONFIG_PPP_ASYNC=m | |||
782 | CONFIG_PPP_BSDCOMP=m | 832 | CONFIG_PPP_BSDCOMP=m |
783 | # CONFIG_PPP_MPPE is not set | 833 | # CONFIG_PPP_MPPE is not set |
784 | # CONFIG_PPPOE is not set | 834 | # CONFIG_PPPOE is not set |
835 | # CONFIG_PPPOL2TP is not set | ||
785 | # CONFIG_SLIP is not set | 836 | # CONFIG_SLIP is not set |
786 | # CONFIG_SHAPER is not set | 837 | CONFIG_SLHC=m |
787 | # CONFIG_NETCONSOLE is not set | 838 | # CONFIG_NETCONSOLE is not set |
788 | # CONFIG_NETPOLL is not set | 839 | # CONFIG_NETPOLL is not set |
789 | # CONFIG_NET_POLL_CONTROLLER is not set | 840 | # CONFIG_NET_POLL_CONTROLLER is not set |
790 | |||
791 | # | ||
792 | # ISDN subsystem | ||
793 | # | ||
794 | # CONFIG_ISDN is not set | 841 | # CONFIG_ISDN is not set |
795 | 842 | ||
796 | # | 843 | # |
797 | # Input device support | 844 | # Input device support |
798 | # | 845 | # |
799 | CONFIG_INPUT=y | 846 | CONFIG_INPUT=y |
847 | CONFIG_INPUT_FF_MEMLESS=m | ||
848 | # CONFIG_INPUT_POLLDEV is not set | ||
800 | 849 | ||
801 | # | 850 | # |
802 | # Userland interfaces | 851 | # Userland interfaces |
803 | # | 852 | # |
804 | # CONFIG_INPUT_MOUSEDEV is not set | 853 | # CONFIG_INPUT_MOUSEDEV is not set |
805 | # CONFIG_INPUT_JOYDEV is not set | 854 | # CONFIG_INPUT_JOYDEV is not set |
806 | # CONFIG_INPUT_TSDEV is not set | ||
807 | CONFIG_INPUT_EVDEV=y | 855 | CONFIG_INPUT_EVDEV=y |
808 | # CONFIG_INPUT_EVBUG is not set | 856 | # CONFIG_INPUT_EVBUG is not set |
857 | # CONFIG_INPUT_APMPOWER is not set | ||
809 | 858 | ||
810 | # | 859 | # |
811 | # Input Device Drivers | 860 | # Input Device Drivers |
@@ -814,19 +863,39 @@ CONFIG_INPUT_KEYBOARD=y | |||
814 | # CONFIG_KEYBOARD_ATKBD is not set | 863 | # CONFIG_KEYBOARD_ATKBD is not set |
815 | # CONFIG_KEYBOARD_SUNKBD is not set | 864 | # CONFIG_KEYBOARD_SUNKBD is not set |
816 | # CONFIG_KEYBOARD_LKKBD is not set | 865 | # CONFIG_KEYBOARD_LKKBD is not set |
866 | # CONFIG_KEYBOARD_LOCOMO is not set | ||
817 | # CONFIG_KEYBOARD_XTKBD is not set | 867 | # CONFIG_KEYBOARD_XTKBD is not set |
818 | # CONFIG_KEYBOARD_NEWTON is not set | 868 | # CONFIG_KEYBOARD_NEWTON is not set |
869 | # CONFIG_KEYBOARD_STOWAWAY is not set | ||
819 | CONFIG_KEYBOARD_CORGI=y | 870 | CONFIG_KEYBOARD_CORGI=y |
820 | CONFIG_KEYBOARD_SPITZ=y | 871 | CONFIG_KEYBOARD_SPITZ=y |
872 | CONFIG_KEYBOARD_TOSA=y | ||
873 | # CONFIG_KEYBOARD_TOSA_USE_EXT_KEYCODES is not set | ||
874 | # CONFIG_KEYBOARD_GPIO is not set | ||
821 | # CONFIG_INPUT_MOUSE is not set | 875 | # CONFIG_INPUT_MOUSE is not set |
822 | # CONFIG_INPUT_JOYSTICK is not set | 876 | # CONFIG_INPUT_JOYSTICK is not set |
877 | # CONFIG_INPUT_TABLET is not set | ||
823 | CONFIG_INPUT_TOUCHSCREEN=y | 878 | CONFIG_INPUT_TOUCHSCREEN=y |
824 | CONFIG_TOUCHSCREEN_CORGI=y | 879 | CONFIG_TOUCHSCREEN_ADS7846=y |
880 | # CONFIG_TOUCHSCREEN_CORGI is not set | ||
881 | # CONFIG_TOUCHSCREEN_FUJITSU is not set | ||
825 | # CONFIG_TOUCHSCREEN_GUNZE is not set | 882 | # CONFIG_TOUCHSCREEN_GUNZE is not set |
826 | # CONFIG_TOUCHSCREEN_ELO is not set | 883 | # CONFIG_TOUCHSCREEN_ELO is not set |
827 | # CONFIG_TOUCHSCREEN_MTOUCH is not set | 884 | # CONFIG_TOUCHSCREEN_MTOUCH is not set |
885 | # CONFIG_TOUCHSCREEN_INEXIO is not set | ||
828 | # CONFIG_TOUCHSCREEN_MK712 is not set | 886 | # CONFIG_TOUCHSCREEN_MK712 is not set |
887 | # CONFIG_TOUCHSCREEN_PENMOUNT is not set | ||
888 | # CONFIG_TOUCHSCREEN_TOUCHRIGHT is not set | ||
889 | # CONFIG_TOUCHSCREEN_TOUCHWIN is not set | ||
890 | # CONFIG_TOUCHSCREEN_USB_COMPOSITE is not set | ||
891 | # CONFIG_TOUCHSCREEN_TOUCHIT213 is not set | ||
829 | CONFIG_INPUT_MISC=y | 892 | CONFIG_INPUT_MISC=y |
893 | # CONFIG_INPUT_ATI_REMOTE is not set | ||
894 | # CONFIG_INPUT_ATI_REMOTE2 is not set | ||
895 | # CONFIG_INPUT_KEYSPAN_REMOTE is not set | ||
896 | # CONFIG_INPUT_POWERMATE is not set | ||
897 | # CONFIG_INPUT_YEALINK is not set | ||
898 | # CONFIG_INPUT_CM109 is not set | ||
830 | CONFIG_INPUT_UINPUT=m | 899 | CONFIG_INPUT_UINPUT=m |
831 | 900 | ||
832 | # | 901 | # |
@@ -839,8 +908,11 @@ CONFIG_INPUT_UINPUT=m | |||
839 | # Character devices | 908 | # Character devices |
840 | # | 909 | # |
841 | CONFIG_VT=y | 910 | CONFIG_VT=y |
911 | CONFIG_CONSOLE_TRANSLATIONS=y | ||
842 | CONFIG_VT_CONSOLE=y | 912 | CONFIG_VT_CONSOLE=y |
843 | CONFIG_HW_CONSOLE=y | 913 | CONFIG_HW_CONSOLE=y |
914 | # CONFIG_VT_HW_CONSOLE_BINDING is not set | ||
915 | CONFIG_DEVKMEM=y | ||
844 | # CONFIG_SERIAL_NONSTANDARD is not set | 916 | # CONFIG_SERIAL_NONSTANDARD is not set |
845 | 917 | ||
846 | # | 918 | # |
@@ -849,6 +921,7 @@ CONFIG_HW_CONSOLE=y | |||
849 | CONFIG_SERIAL_8250=m | 921 | CONFIG_SERIAL_8250=m |
850 | CONFIG_SERIAL_8250_CS=m | 922 | CONFIG_SERIAL_8250_CS=m |
851 | CONFIG_SERIAL_8250_NR_UARTS=4 | 923 | CONFIG_SERIAL_8250_NR_UARTS=4 |
924 | CONFIG_SERIAL_8250_RUNTIME_UARTS=4 | ||
852 | # CONFIG_SERIAL_8250_EXTENDED is not set | 925 | # CONFIG_SERIAL_8250_EXTENDED is not set |
853 | 926 | ||
854 | # | 927 | # |
@@ -860,97 +933,130 @@ CONFIG_SERIAL_CORE=y | |||
860 | CONFIG_SERIAL_CORE_CONSOLE=y | 933 | CONFIG_SERIAL_CORE_CONSOLE=y |
861 | CONFIG_UNIX98_PTYS=y | 934 | CONFIG_UNIX98_PTYS=y |
862 | # CONFIG_LEGACY_PTYS is not set | 935 | # CONFIG_LEGACY_PTYS is not set |
863 | |||
864 | # | ||
865 | # IPMI | ||
866 | # | ||
867 | # CONFIG_IPMI_HANDLER is not set | 936 | # CONFIG_IPMI_HANDLER is not set |
868 | 937 | CONFIG_HW_RANDOM=m | |
869 | # | ||
870 | # Watchdog Cards | ||
871 | # | ||
872 | # CONFIG_WATCHDOG is not set | ||
873 | # CONFIG_NVRAM is not set | 938 | # CONFIG_NVRAM is not set |
874 | # CONFIG_RTC is not set | ||
875 | # CONFIG_DTLK is not set | ||
876 | # CONFIG_R3964 is not set | 939 | # CONFIG_R3964 is not set |
877 | 940 | ||
878 | # | 941 | # |
879 | # Ftape, the floppy tape device driver | ||
880 | # | ||
881 | |||
882 | # | ||
883 | # PCMCIA character devices | 942 | # PCMCIA character devices |
884 | # | 943 | # |
885 | # CONFIG_SYNCLINK_CS is not set | 944 | # CONFIG_SYNCLINK_CS is not set |
886 | # CONFIG_CARDMAN_4000 is not set | 945 | # CONFIG_CARDMAN_4000 is not set |
887 | # CONFIG_CARDMAN_4040 is not set | 946 | # CONFIG_CARDMAN_4040 is not set |
947 | # CONFIG_IPWIRELESS is not set | ||
888 | # CONFIG_RAW_DRIVER is not set | 948 | # CONFIG_RAW_DRIVER is not set |
889 | |||
890 | # | ||
891 | # TPM devices | ||
892 | # | ||
893 | # CONFIG_TCG_TPM is not set | 949 | # CONFIG_TCG_TPM is not set |
894 | # CONFIG_TELCLOCK is not set | ||
895 | |||
896 | # | ||
897 | # I2C support | ||
898 | # | ||
899 | CONFIG_I2C=y | 950 | CONFIG_I2C=y |
951 | CONFIG_I2C_BOARDINFO=y | ||
900 | # CONFIG_I2C_CHARDEV is not set | 952 | # CONFIG_I2C_CHARDEV is not set |
953 | CONFIG_I2C_HELPER_AUTO=y | ||
901 | 954 | ||
902 | # | 955 | # |
903 | # I2C Algorithms | 956 | # I2C Hardware Bus support |
904 | # | 957 | # |
905 | CONFIG_I2C_ALGOBIT=y | ||
906 | # CONFIG_I2C_ALGOPCF is not set | ||
907 | # CONFIG_I2C_ALGOPCA is not set | ||
908 | 958 | ||
909 | # | 959 | # |
910 | # I2C Hardware Bus support | 960 | # I2C system bus drivers (mostly embedded / system-on-chip) |
911 | # | 961 | # |
962 | # CONFIG_I2C_GPIO is not set | ||
963 | # CONFIG_I2C_OCORES is not set | ||
912 | CONFIG_I2C_PXA=y | 964 | CONFIG_I2C_PXA=y |
913 | # CONFIG_I2C_PXA_SLAVE is not set | 965 | # CONFIG_I2C_PXA_SLAVE is not set |
966 | # CONFIG_I2C_SIMTEC is not set | ||
967 | |||
968 | # | ||
969 | # External I2C/SMBus adapter drivers | ||
970 | # | ||
914 | # CONFIG_I2C_PARPORT_LIGHT is not set | 971 | # CONFIG_I2C_PARPORT_LIGHT is not set |
972 | # CONFIG_I2C_TAOS_EVM is not set | ||
973 | # CONFIG_I2C_TINY_USB is not set | ||
974 | |||
975 | # | ||
976 | # Other I2C/SMBus bus drivers | ||
977 | # | ||
978 | # CONFIG_I2C_PCA_PLATFORM is not set | ||
915 | # CONFIG_I2C_STUB is not set | 979 | # CONFIG_I2C_STUB is not set |
916 | # CONFIG_I2C_PCA_ISA is not set | ||
917 | 980 | ||
918 | # | 981 | # |
919 | # Miscellaneous I2C Chip support | 982 | # Miscellaneous I2C Chip support |
920 | # | 983 | # |
921 | # CONFIG_SENSORS_DS1337 is not set | 984 | # CONFIG_DS1682 is not set |
922 | # CONFIG_SENSORS_DS1374 is not set | 985 | # CONFIG_AT24 is not set |
923 | # CONFIG_SENSORS_EEPROM is not set | 986 | # CONFIG_SENSORS_EEPROM is not set |
924 | # CONFIG_SENSORS_PCF8574 is not set | 987 | # CONFIG_SENSORS_PCF8574 is not set |
988 | # CONFIG_PCF8575 is not set | ||
925 | # CONFIG_SENSORS_PCA9539 is not set | 989 | # CONFIG_SENSORS_PCA9539 is not set |
926 | # CONFIG_SENSORS_PCF8591 is not set | 990 | # CONFIG_SENSORS_PCF8591 is not set |
927 | # CONFIG_SENSORS_RTC8564 is not set | 991 | # CONFIG_TPS65010 is not set |
928 | # CONFIG_SENSORS_MAX6875 is not set | 992 | # CONFIG_SENSORS_MAX6875 is not set |
929 | # CONFIG_RTC_X1205_I2C is not set | 993 | # CONFIG_SENSORS_TSL2550 is not set |
930 | # CONFIG_I2C_DEBUG_CORE is not set | 994 | # CONFIG_I2C_DEBUG_CORE is not set |
931 | # CONFIG_I2C_DEBUG_ALGO is not set | 995 | # CONFIG_I2C_DEBUG_ALGO is not set |
932 | # CONFIG_I2C_DEBUG_BUS is not set | 996 | # CONFIG_I2C_DEBUG_BUS is not set |
933 | # CONFIG_I2C_DEBUG_CHIP is not set | 997 | # CONFIG_I2C_DEBUG_CHIP is not set |
998 | CONFIG_SPI=y | ||
999 | # CONFIG_SPI_DEBUG is not set | ||
1000 | CONFIG_SPI_MASTER=y | ||
934 | 1001 | ||
935 | # | 1002 | # |
936 | # Hardware Monitoring support | 1003 | # SPI Master Controller Drivers |
937 | # | 1004 | # |
1005 | # CONFIG_SPI_BITBANG is not set | ||
1006 | CONFIG_SPI_PXA2XX=y | ||
1007 | |||
1008 | # | ||
1009 | # SPI Protocol Masters | ||
1010 | # | ||
1011 | # CONFIG_SPI_AT25 is not set | ||
1012 | # CONFIG_SPI_SPIDEV is not set | ||
1013 | # CONFIG_SPI_TLE62X0 is not set | ||
1014 | CONFIG_ARCH_REQUIRE_GPIOLIB=y | ||
1015 | CONFIG_GPIOLIB=y | ||
1016 | # CONFIG_DEBUG_GPIO is not set | ||
1017 | # CONFIG_GPIO_SYSFS is not set | ||
1018 | |||
1019 | # | ||
1020 | # I2C GPIO expanders: | ||
1021 | # | ||
1022 | # CONFIG_GPIO_MAX732X is not set | ||
1023 | # CONFIG_GPIO_PCA953X is not set | ||
1024 | # CONFIG_GPIO_PCF857X is not set | ||
1025 | |||
1026 | # | ||
1027 | # PCI GPIO expanders: | ||
1028 | # | ||
1029 | |||
1030 | # | ||
1031 | # SPI GPIO expanders: | ||
1032 | # | ||
1033 | # CONFIG_GPIO_MAX7301 is not set | ||
1034 | # CONFIG_GPIO_MCP23S08 is not set | ||
1035 | # CONFIG_W1 is not set | ||
1036 | # CONFIG_POWER_SUPPLY is not set | ||
938 | CONFIG_HWMON=y | 1037 | CONFIG_HWMON=y |
939 | # CONFIG_HWMON_VID is not set | 1038 | # CONFIG_HWMON_VID is not set |
1039 | # CONFIG_SENSORS_AD7414 is not set | ||
1040 | # CONFIG_SENSORS_AD7418 is not set | ||
1041 | # CONFIG_SENSORS_ADCXX is not set | ||
940 | # CONFIG_SENSORS_ADM1021 is not set | 1042 | # CONFIG_SENSORS_ADM1021 is not set |
941 | # CONFIG_SENSORS_ADM1025 is not set | 1043 | # CONFIG_SENSORS_ADM1025 is not set |
942 | # CONFIG_SENSORS_ADM1026 is not set | 1044 | # CONFIG_SENSORS_ADM1026 is not set |
1045 | # CONFIG_SENSORS_ADM1029 is not set | ||
943 | # CONFIG_SENSORS_ADM1031 is not set | 1046 | # CONFIG_SENSORS_ADM1031 is not set |
944 | # CONFIG_SENSORS_ADM9240 is not set | 1047 | # CONFIG_SENSORS_ADM9240 is not set |
945 | # CONFIG_SENSORS_ASB100 is not set | 1048 | # CONFIG_SENSORS_ADT7470 is not set |
1049 | # CONFIG_SENSORS_ADT7473 is not set | ||
946 | # CONFIG_SENSORS_ATXP1 is not set | 1050 | # CONFIG_SENSORS_ATXP1 is not set |
947 | # CONFIG_SENSORS_DS1621 is not set | 1051 | # CONFIG_SENSORS_DS1621 is not set |
948 | # CONFIG_SENSORS_FSCHER is not set | 1052 | # CONFIG_SENSORS_F71805F is not set |
949 | # CONFIG_SENSORS_FSCPOS is not set | 1053 | # CONFIG_SENSORS_F71882FG is not set |
1054 | # CONFIG_SENSORS_F75375S is not set | ||
950 | # CONFIG_SENSORS_GL518SM is not set | 1055 | # CONFIG_SENSORS_GL518SM is not set |
951 | # CONFIG_SENSORS_GL520SM is not set | 1056 | # CONFIG_SENSORS_GL520SM is not set |
952 | # CONFIG_SENSORS_IT87 is not set | 1057 | # CONFIG_SENSORS_IT87 is not set |
953 | # CONFIG_SENSORS_LM63 is not set | 1058 | # CONFIG_SENSORS_LM63 is not set |
1059 | # CONFIG_SENSORS_LM70 is not set | ||
954 | # CONFIG_SENSORS_LM75 is not set | 1060 | # CONFIG_SENSORS_LM75 is not set |
955 | # CONFIG_SENSORS_LM77 is not set | 1061 | # CONFIG_SENSORS_LM77 is not set |
956 | # CONFIG_SENSORS_LM78 is not set | 1062 | # CONFIG_SENSORS_LM78 is not set |
@@ -960,70 +1066,193 @@ CONFIG_HWMON=y | |||
960 | # CONFIG_SENSORS_LM87 is not set | 1066 | # CONFIG_SENSORS_LM87 is not set |
961 | # CONFIG_SENSORS_LM90 is not set | 1067 | # CONFIG_SENSORS_LM90 is not set |
962 | # CONFIG_SENSORS_LM92 is not set | 1068 | # CONFIG_SENSORS_LM92 is not set |
1069 | # CONFIG_SENSORS_LM93 is not set | ||
1070 | CONFIG_SENSORS_MAX1111=y | ||
963 | # CONFIG_SENSORS_MAX1619 is not set | 1071 | # CONFIG_SENSORS_MAX1619 is not set |
1072 | # CONFIG_SENSORS_MAX6650 is not set | ||
964 | # CONFIG_SENSORS_PC87360 is not set | 1073 | # CONFIG_SENSORS_PC87360 is not set |
1074 | # CONFIG_SENSORS_PC87427 is not set | ||
1075 | # CONFIG_SENSORS_DME1737 is not set | ||
965 | # CONFIG_SENSORS_SMSC47M1 is not set | 1076 | # CONFIG_SENSORS_SMSC47M1 is not set |
1077 | # CONFIG_SENSORS_SMSC47M192 is not set | ||
966 | # CONFIG_SENSORS_SMSC47B397 is not set | 1078 | # CONFIG_SENSORS_SMSC47B397 is not set |
1079 | # CONFIG_SENSORS_ADS7828 is not set | ||
1080 | # CONFIG_SENSORS_THMC50 is not set | ||
1081 | # CONFIG_SENSORS_VT1211 is not set | ||
967 | # CONFIG_SENSORS_W83781D is not set | 1082 | # CONFIG_SENSORS_W83781D is not set |
1083 | # CONFIG_SENSORS_W83791D is not set | ||
968 | # CONFIG_SENSORS_W83792D is not set | 1084 | # CONFIG_SENSORS_W83792D is not set |
1085 | # CONFIG_SENSORS_W83793 is not set | ||
969 | # CONFIG_SENSORS_W83L785TS is not set | 1086 | # CONFIG_SENSORS_W83L785TS is not set |
1087 | # CONFIG_SENSORS_W83L786NG is not set | ||
970 | # CONFIG_SENSORS_W83627HF is not set | 1088 | # CONFIG_SENSORS_W83627HF is not set |
971 | # CONFIG_SENSORS_W83627EHF is not set | 1089 | # CONFIG_SENSORS_W83627EHF is not set |
972 | # CONFIG_HWMON_DEBUG_CHIP is not set | 1090 | # CONFIG_HWMON_DEBUG_CHIP is not set |
1091 | # CONFIG_THERMAL is not set | ||
1092 | # CONFIG_THERMAL_HWMON is not set | ||
1093 | # CONFIG_WATCHDOG is not set | ||
973 | 1094 | ||
974 | # | 1095 | # |
975 | # Misc devices | 1096 | # Sonics Silicon Backplane |
976 | # | 1097 | # |
1098 | CONFIG_SSB_POSSIBLE=y | ||
1099 | # CONFIG_SSB is not set | ||
977 | 1100 | ||
978 | # | 1101 | # |
979 | # Multimedia Capabilities Port drivers | 1102 | # Multifunction device drivers |
980 | # | 1103 | # |
1104 | # CONFIG_MFD_CORE is not set | ||
1105 | # CONFIG_MFD_SM501 is not set | ||
1106 | # CONFIG_MFD_ASIC3 is not set | ||
1107 | # CONFIG_HTC_EGPIO is not set | ||
1108 | # CONFIG_HTC_PASIC3 is not set | ||
1109 | # CONFIG_UCB1400_CORE is not set | ||
1110 | # CONFIG_MFD_TMIO is not set | ||
1111 | # CONFIG_MFD_T7L66XB is not set | ||
1112 | # CONFIG_MFD_TC6387XB is not set | ||
1113 | # CONFIG_MFD_TC6393XB is not set | ||
1114 | # CONFIG_MFD_WM8400 is not set | ||
1115 | # CONFIG_MFD_WM8350_I2C is not set | ||
981 | 1116 | ||
982 | # | 1117 | # |
983 | # Multimedia devices | 1118 | # Multimedia devices |
984 | # | 1119 | # |
985 | CONFIG_VIDEO_DEV=m | ||
986 | |||
987 | # | ||
988 | # Video For Linux | ||
989 | # | ||
990 | 1120 | ||
991 | # | 1121 | # |
992 | # Video Adapters | 1122 | # Multimedia core support |
993 | # | 1123 | # |
1124 | CONFIG_VIDEO_DEV=m | ||
1125 | CONFIG_VIDEO_V4L2_COMMON=m | ||
1126 | CONFIG_VIDEO_ALLOW_V4L1=y | ||
1127 | CONFIG_VIDEO_V4L1_COMPAT=y | ||
1128 | # CONFIG_DVB_CORE is not set | ||
1129 | CONFIG_VIDEO_MEDIA=m | ||
1130 | |||
1131 | # | ||
1132 | # Multimedia drivers | ||
1133 | # | ||
1134 | # CONFIG_MEDIA_ATTACH is not set | ||
1135 | CONFIG_MEDIA_TUNER=m | ||
1136 | # CONFIG_MEDIA_TUNER_CUSTOMIZE is not set | ||
1137 | CONFIG_MEDIA_TUNER_SIMPLE=m | ||
1138 | CONFIG_MEDIA_TUNER_TDA8290=m | ||
1139 | CONFIG_MEDIA_TUNER_TDA9887=m | ||
1140 | CONFIG_MEDIA_TUNER_TEA5761=m | ||
1141 | CONFIG_MEDIA_TUNER_TEA5767=m | ||
1142 | CONFIG_MEDIA_TUNER_MT20XX=m | ||
1143 | CONFIG_MEDIA_TUNER_XC2028=m | ||
1144 | CONFIG_MEDIA_TUNER_XC5000=m | ||
1145 | CONFIG_VIDEO_V4L2=m | ||
1146 | CONFIG_VIDEO_V4L1=m | ||
1147 | CONFIG_VIDEO_CAPTURE_DRIVERS=y | ||
1148 | # CONFIG_VIDEO_ADV_DEBUG is not set | ||
1149 | # CONFIG_VIDEO_FIXED_MINOR_RANGES is not set | ||
1150 | CONFIG_VIDEO_HELPER_CHIPS_AUTO=y | ||
1151 | # CONFIG_VIDEO_VIVI is not set | ||
994 | # CONFIG_VIDEO_CPIA is not set | 1152 | # CONFIG_VIDEO_CPIA is not set |
1153 | # CONFIG_VIDEO_CPIA2 is not set | ||
995 | # CONFIG_VIDEO_SAA5246A is not set | 1154 | # CONFIG_VIDEO_SAA5246A is not set |
996 | # CONFIG_VIDEO_SAA5249 is not set | 1155 | # CONFIG_VIDEO_SAA5249 is not set |
997 | # CONFIG_TUNER_3036 is not set | 1156 | # CONFIG_SOC_CAMERA is not set |
1157 | CONFIG_V4L_USB_DRIVERS=y | ||
1158 | # CONFIG_USB_VIDEO_CLASS is not set | ||
1159 | CONFIG_USB_GSPCA=m | ||
1160 | # CONFIG_USB_M5602 is not set | ||
1161 | # CONFIG_USB_GSPCA_CONEX is not set | ||
1162 | # CONFIG_USB_GSPCA_ETOMS is not set | ||
1163 | # CONFIG_USB_GSPCA_FINEPIX is not set | ||
1164 | # CONFIG_USB_GSPCA_MARS is not set | ||
1165 | # CONFIG_USB_GSPCA_OV519 is not set | ||
1166 | # CONFIG_USB_GSPCA_PAC207 is not set | ||
1167 | # CONFIG_USB_GSPCA_PAC7311 is not set | ||
1168 | # CONFIG_USB_GSPCA_SONIXB is not set | ||
1169 | # CONFIG_USB_GSPCA_SONIXJ is not set | ||
1170 | # CONFIG_USB_GSPCA_SPCA500 is not set | ||
1171 | # CONFIG_USB_GSPCA_SPCA501 is not set | ||
1172 | # CONFIG_USB_GSPCA_SPCA505 is not set | ||
1173 | # CONFIG_USB_GSPCA_SPCA506 is not set | ||
1174 | # CONFIG_USB_GSPCA_SPCA508 is not set | ||
1175 | # CONFIG_USB_GSPCA_SPCA561 is not set | ||
1176 | # CONFIG_USB_GSPCA_STK014 is not set | ||
1177 | # CONFIG_USB_GSPCA_SUNPLUS is not set | ||
1178 | # CONFIG_USB_GSPCA_T613 is not set | ||
1179 | # CONFIG_USB_GSPCA_TV8532 is not set | ||
1180 | # CONFIG_USB_GSPCA_VC032X is not set | ||
1181 | # CONFIG_USB_GSPCA_ZC3XX is not set | ||
1182 | # CONFIG_VIDEO_PVRUSB2 is not set | ||
998 | # CONFIG_VIDEO_EM28XX is not set | 1183 | # CONFIG_VIDEO_EM28XX is not set |
1184 | # CONFIG_VIDEO_USBVISION is not set | ||
1185 | CONFIG_VIDEO_USBVIDEO=m | ||
1186 | CONFIG_USB_VICAM=m | ||
1187 | CONFIG_USB_IBMCAM=m | ||
1188 | CONFIG_USB_KONICAWC=m | ||
1189 | # CONFIG_USB_QUICKCAM_MESSENGER is not set | ||
1190 | # CONFIG_USB_ET61X251 is not set | ||
999 | # CONFIG_VIDEO_OVCAMCHIP is not set | 1191 | # CONFIG_VIDEO_OVCAMCHIP is not set |
1000 | # CONFIG_VIDEO_AUDIO_DECODER is not set | 1192 | CONFIG_USB_OV511=m |
1001 | # CONFIG_VIDEO_DECODER is not set | 1193 | CONFIG_USB_SE401=m |
1002 | 1194 | CONFIG_USB_SN9C102=m | |
1003 | # | 1195 | CONFIG_USB_STV680=m |
1004 | # Radio Adapters | 1196 | # CONFIG_USB_ZC0301 is not set |
1005 | # | 1197 | # CONFIG_USB_PWC is not set |
1006 | # CONFIG_RADIO_MAESTRO is not set | 1198 | # CONFIG_USB_ZR364XX is not set |
1007 | 1199 | # CONFIG_USB_STKWEBCAM is not set | |
1008 | # | 1200 | # CONFIG_USB_S2255 is not set |
1009 | # Digital Video Broadcasting Devices | 1201 | CONFIG_RADIO_ADAPTERS=y |
1010 | # | 1202 | CONFIG_USB_DSBR=m |
1011 | # CONFIG_DVB is not set | 1203 | # CONFIG_USB_SI470X is not set |
1204 | # CONFIG_USB_MR800 is not set | ||
1205 | # CONFIG_DAB is not set | ||
1012 | 1206 | ||
1013 | # | 1207 | # |
1014 | # Graphics support | 1208 | # Graphics support |
1015 | # | 1209 | # |
1210 | # CONFIG_VGASTATE is not set | ||
1211 | # CONFIG_VIDEO_OUTPUT_CONTROL is not set | ||
1016 | CONFIG_FB=y | 1212 | CONFIG_FB=y |
1213 | # CONFIG_FIRMWARE_EDID is not set | ||
1214 | # CONFIG_FB_DDC is not set | ||
1215 | # CONFIG_FB_BOOT_VESA_SUPPORT is not set | ||
1017 | CONFIG_FB_CFB_FILLRECT=y | 1216 | CONFIG_FB_CFB_FILLRECT=y |
1018 | CONFIG_FB_CFB_COPYAREA=y | 1217 | CONFIG_FB_CFB_COPYAREA=y |
1019 | CONFIG_FB_CFB_IMAGEBLIT=y | 1218 | CONFIG_FB_CFB_IMAGEBLIT=y |
1219 | # CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set | ||
1220 | # CONFIG_FB_SYS_FILLRECT is not set | ||
1221 | # CONFIG_FB_SYS_COPYAREA is not set | ||
1222 | # CONFIG_FB_SYS_IMAGEBLIT is not set | ||
1223 | # CONFIG_FB_FOREIGN_ENDIAN is not set | ||
1224 | # CONFIG_FB_SYS_FOPS is not set | ||
1225 | # CONFIG_FB_SVGALIB is not set | ||
1020 | # CONFIG_FB_MACMODES is not set | 1226 | # CONFIG_FB_MACMODES is not set |
1227 | # CONFIG_FB_BACKLIGHT is not set | ||
1021 | # CONFIG_FB_MODE_HELPERS is not set | 1228 | # CONFIG_FB_MODE_HELPERS is not set |
1022 | # CONFIG_FB_TILEBLITTING is not set | 1229 | # CONFIG_FB_TILEBLITTING is not set |
1230 | |||
1231 | # | ||
1232 | # Frame buffer hardware drivers | ||
1233 | # | ||
1023 | # CONFIG_FB_S1D13XXX is not set | 1234 | # CONFIG_FB_S1D13XXX is not set |
1024 | # CONFIG_FB_PXA is not set | 1235 | # CONFIG_FB_PXA is not set |
1236 | # CONFIG_FB_MBX is not set | ||
1025 | CONFIG_FB_W100=y | 1237 | CONFIG_FB_W100=y |
1026 | # CONFIG_FB_VIRTUAL is not set | 1238 | # CONFIG_FB_VIRTUAL is not set |
1239 | # CONFIG_FB_METRONOME is not set | ||
1240 | CONFIG_BACKLIGHT_LCD_SUPPORT=y | ||
1241 | CONFIG_LCD_CLASS_DEVICE=y | ||
1242 | CONFIG_LCD_CORGI=y | ||
1243 | # CONFIG_LCD_LTV350QV is not set | ||
1244 | # CONFIG_LCD_ILI9320 is not set | ||
1245 | # CONFIG_LCD_TDO24M is not set | ||
1246 | # CONFIG_LCD_VGG2432A4 is not set | ||
1247 | # CONFIG_LCD_PLATFORM is not set | ||
1248 | CONFIG_BACKLIGHT_CLASS_DEVICE=y | ||
1249 | # CONFIG_BACKLIGHT_CORGI is not set | ||
1250 | CONFIG_BACKLIGHT_LOCOMO=y | ||
1251 | |||
1252 | # | ||
1253 | # Display device support | ||
1254 | # | ||
1255 | # CONFIG_DISPLAY_SUPPORT is not set | ||
1027 | 1256 | ||
1028 | # | 1257 | # |
1029 | # Console display driver support | 1258 | # Console display driver support |
@@ -1031,6 +1260,7 @@ CONFIG_FB_W100=y | |||
1031 | # CONFIG_VGA_CONSOLE is not set | 1260 | # CONFIG_VGA_CONSOLE is not set |
1032 | CONFIG_DUMMY_CONSOLE=y | 1261 | CONFIG_DUMMY_CONSOLE=y |
1033 | CONFIG_FRAMEBUFFER_CONSOLE=y | 1262 | CONFIG_FRAMEBUFFER_CONSOLE=y |
1263 | # CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY is not set | ||
1034 | # CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set | 1264 | # CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set |
1035 | CONFIG_FONTS=y | 1265 | CONFIG_FONTS=y |
1036 | CONFIG_FONT_8x8=y | 1266 | CONFIG_FONT_8x8=y |
@@ -1043,93 +1273,95 @@ CONFIG_FONT_8x16=y | |||
1043 | # CONFIG_FONT_SUN8x16 is not set | 1273 | # CONFIG_FONT_SUN8x16 is not set |
1044 | # CONFIG_FONT_SUN12x22 is not set | 1274 | # CONFIG_FONT_SUN12x22 is not set |
1045 | # CONFIG_FONT_10x18 is not set | 1275 | # CONFIG_FONT_10x18 is not set |
1046 | |||
1047 | # | ||
1048 | # Logo configuration | ||
1049 | # | ||
1050 | # CONFIG_LOGO is not set | 1276 | # CONFIG_LOGO is not set |
1051 | CONFIG_BACKLIGHT_LCD_SUPPORT=y | ||
1052 | CONFIG_BACKLIGHT_CLASS_DEVICE=y | ||
1053 | CONFIG_BACKLIGHT_DEVICE=y | ||
1054 | # CONFIG_LCD_CLASS_DEVICE is not set | ||
1055 | CONFIG_BACKLIGHT_CORGI=y | ||
1056 | |||
1057 | # | ||
1058 | # Sound | ||
1059 | # | ||
1060 | CONFIG_SOUND=y | 1277 | CONFIG_SOUND=y |
1278 | CONFIG_SOUND_OSS_CORE=y | ||
1279 | # CONFIG_SND is not set | ||
1280 | CONFIG_SOUND_PRIME=y | ||
1281 | CONFIG_HID_SUPPORT=y | ||
1282 | CONFIG_HID=y | ||
1283 | # CONFIG_HID_DEBUG is not set | ||
1284 | # CONFIG_HIDRAW is not set | ||
1061 | 1285 | ||
1062 | # | 1286 | # |
1063 | # Advanced Linux Sound Architecture | 1287 | # USB Input Devices |
1064 | # | 1288 | # |
1065 | # CONFIG_SND is not set | 1289 | CONFIG_USB_HID=m |
1290 | # CONFIG_HID_PID is not set | ||
1291 | # CONFIG_USB_HIDDEV is not set | ||
1066 | 1292 | ||
1067 | # | 1293 | # |
1068 | # Open Sound System | 1294 | # USB HID Boot Protocol drivers |
1069 | # | 1295 | # |
1070 | CONFIG_SOUND_PRIME=y | 1296 | CONFIG_USB_KBD=m |
1071 | # CONFIG_SOUND_MSNDCLAS is not set | 1297 | CONFIG_USB_MOUSE=m |
1072 | # CONFIG_SOUND_MSNDPIN is not set | 1298 | |
1073 | CONFIG_SOUND_OSS=y | ||
1074 | # CONFIG_SOUND_TRACEINIT is not set | ||
1075 | # CONFIG_SOUND_DMAP is not set | ||
1076 | # CONFIG_SOUND_AD1816 is not set | ||
1077 | # CONFIG_SOUND_SGALAXY is not set | ||
1078 | # CONFIG_SOUND_ADLIB is not set | ||
1079 | # CONFIG_SOUND_ACI_MIXER is not set | ||
1080 | # CONFIG_SOUND_CS4232 is not set | ||
1081 | # CONFIG_SOUND_SSCAPE is not set | ||
1082 | # CONFIG_SOUND_GUS is not set | ||
1083 | # CONFIG_SOUND_VMIDI is not set | ||
1084 | # CONFIG_SOUND_TRIX is not set | ||
1085 | # CONFIG_SOUND_MSS is not set | ||
1086 | # CONFIG_SOUND_MPU401 is not set | ||
1087 | # CONFIG_SOUND_NM256 is not set | ||
1088 | # CONFIG_SOUND_MAD16 is not set | ||
1089 | # CONFIG_SOUND_PAS is not set | ||
1090 | # CONFIG_SOUND_PSS is not set | ||
1091 | # CONFIG_SOUND_SB is not set | ||
1092 | # CONFIG_SOUND_AWE32_SYNTH is not set | ||
1093 | # CONFIG_SOUND_WAVEFRONT is not set | ||
1094 | # CONFIG_SOUND_MAUI is not set | ||
1095 | # CONFIG_SOUND_YM3812 is not set | ||
1096 | # CONFIG_SOUND_OPL3SA1 is not set | ||
1097 | # CONFIG_SOUND_OPL3SA2 is not set | ||
1098 | # CONFIG_SOUND_UART6850 is not set | ||
1099 | # CONFIG_SOUND_AEDSP16 is not set | ||
1100 | # CONFIG_SOUND_TVMIXER is not set | ||
1101 | # CONFIG_SOUND_AD1980 is not set | ||
1102 | |||
1103 | # | ||
1104 | # USB support | ||
1105 | # | 1299 | # |
1300 | # Special HID drivers | ||
1301 | # | ||
1302 | CONFIG_HID_COMPAT=y | ||
1303 | CONFIG_HID_A4TECH=m | ||
1304 | CONFIG_HID_APPLE=m | ||
1305 | CONFIG_HID_BELKIN=m | ||
1306 | CONFIG_HID_BRIGHT=m | ||
1307 | CONFIG_HID_CHERRY=m | ||
1308 | CONFIG_HID_CHICONY=m | ||
1309 | CONFIG_HID_CYPRESS=m | ||
1310 | CONFIG_HID_DELL=m | ||
1311 | CONFIG_HID_EZKEY=m | ||
1312 | CONFIG_HID_GYRATION=m | ||
1313 | CONFIG_HID_LOGITECH=m | ||
1314 | # CONFIG_LOGITECH_FF is not set | ||
1315 | # CONFIG_LOGIRUMBLEPAD2_FF is not set | ||
1316 | CONFIG_HID_MICROSOFT=m | ||
1317 | CONFIG_HID_MONTEREY=m | ||
1318 | CONFIG_HID_PANTHERLORD=m | ||
1319 | # CONFIG_PANTHERLORD_FF is not set | ||
1320 | CONFIG_HID_PETALYNX=m | ||
1321 | CONFIG_HID_SAMSUNG=m | ||
1322 | CONFIG_HID_SONY=m | ||
1323 | CONFIG_HID_SUNPLUS=m | ||
1324 | CONFIG_THRUSTMASTER_FF=m | ||
1325 | CONFIG_ZEROPLUS_FF=m | ||
1326 | CONFIG_USB_SUPPORT=y | ||
1106 | CONFIG_USB_ARCH_HAS_HCD=y | 1327 | CONFIG_USB_ARCH_HAS_HCD=y |
1107 | # CONFIG_USB_ARCH_HAS_OHCI is not set | 1328 | # CONFIG_USB_ARCH_HAS_OHCI is not set |
1329 | # CONFIG_USB_ARCH_HAS_EHCI is not set | ||
1108 | CONFIG_USB=m | 1330 | CONFIG_USB=m |
1109 | # CONFIG_USB_DEBUG is not set | 1331 | # CONFIG_USB_DEBUG is not set |
1332 | # CONFIG_USB_ANNOUNCE_NEW_DEVICES is not set | ||
1110 | 1333 | ||
1111 | # | 1334 | # |
1112 | # Miscellaneous USB options | 1335 | # Miscellaneous USB options |
1113 | # | 1336 | # |
1114 | CONFIG_USB_DEVICEFS=y | 1337 | CONFIG_USB_DEVICEFS=y |
1115 | # CONFIG_USB_BANDWIDTH is not set | 1338 | CONFIG_USB_DEVICE_CLASS=y |
1116 | # CONFIG_USB_DYNAMIC_MINORS is not set | 1339 | # CONFIG_USB_DYNAMIC_MINORS is not set |
1117 | # CONFIG_USB_SUSPEND is not set | 1340 | # CONFIG_USB_SUSPEND is not set |
1118 | # CONFIG_USB_OTG is not set | 1341 | # CONFIG_USB_OTG is not set |
1342 | # CONFIG_USB_OTG_WHITELIST is not set | ||
1343 | # CONFIG_USB_OTG_BLACKLIST_HUB is not set | ||
1344 | CONFIG_USB_MON=y | ||
1119 | 1345 | ||
1120 | # | 1346 | # |
1121 | # USB Host Controller Drivers | 1347 | # USB Host Controller Drivers |
1122 | # | 1348 | # |
1349 | # CONFIG_USB_C67X00_HCD is not set | ||
1123 | # CONFIG_USB_ISP116X_HCD is not set | 1350 | # CONFIG_USB_ISP116X_HCD is not set |
1351 | # CONFIG_USB_ISP1760_HCD is not set | ||
1124 | CONFIG_USB_SL811_HCD=m | 1352 | CONFIG_USB_SL811_HCD=m |
1125 | CONFIG_USB_SL811_CS=m | 1353 | CONFIG_USB_SL811_CS=m |
1354 | # CONFIG_USB_R8A66597_HCD is not set | ||
1355 | # CONFIG_USB_MUSB_HDRC is not set | ||
1356 | # CONFIG_USB_GADGET_MUSB_HDRC is not set | ||
1126 | 1357 | ||
1127 | # | 1358 | # |
1128 | # USB Device Class drivers | 1359 | # USB Device Class drivers |
1129 | # | 1360 | # |
1130 | # CONFIG_OBSOLETE_OSS_USB_DRIVER is not set | ||
1131 | CONFIG_USB_ACM=m | 1361 | CONFIG_USB_ACM=m |
1132 | CONFIG_USB_PRINTER=m | 1362 | CONFIG_USB_PRINTER=m |
1363 | # CONFIG_USB_WDM is not set | ||
1364 | # CONFIG_USB_TMC is not set | ||
1133 | 1365 | ||
1134 | # | 1366 | # |
1135 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' | 1367 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' |
@@ -1148,33 +1380,11 @@ CONFIG_USB_STORAGE=m | |||
1148 | # CONFIG_USB_STORAGE_SDDR09 is not set | 1380 | # CONFIG_USB_STORAGE_SDDR09 is not set |
1149 | # CONFIG_USB_STORAGE_SDDR55 is not set | 1381 | # CONFIG_USB_STORAGE_SDDR55 is not set |
1150 | # CONFIG_USB_STORAGE_JUMPSHOT is not set | 1382 | # CONFIG_USB_STORAGE_JUMPSHOT is not set |
1151 | 1383 | # CONFIG_USB_STORAGE_ALAUDA is not set | |
1152 | # | 1384 | # CONFIG_USB_STORAGE_ONETOUCH is not set |
1153 | # USB Input Devices | 1385 | # CONFIG_USB_STORAGE_KARMA is not set |
1154 | # | 1386 | # CONFIG_USB_STORAGE_CYPRESS_ATACB is not set |
1155 | CONFIG_USB_HID=m | 1387 | # CONFIG_USB_LIBUSUAL is not set |
1156 | CONFIG_USB_HIDINPUT=y | ||
1157 | # CONFIG_HID_FF is not set | ||
1158 | # CONFIG_USB_HIDDEV is not set | ||
1159 | |||
1160 | # | ||
1161 | # USB HID Boot Protocol drivers | ||
1162 | # | ||
1163 | CONFIG_USB_KBD=m | ||
1164 | CONFIG_USB_MOUSE=m | ||
1165 | CONFIG_USB_AIPTEK=m | ||
1166 | CONFIG_USB_WACOM=m | ||
1167 | # CONFIG_USB_ACECAD is not set | ||
1168 | CONFIG_USB_KBTAB=m | ||
1169 | CONFIG_USB_POWERMATE=m | ||
1170 | CONFIG_USB_MTOUCH=m | ||
1171 | # CONFIG_USB_ITMTOUCH is not set | ||
1172 | CONFIG_USB_EGALAX=m | ||
1173 | # CONFIG_USB_YEALINK is not set | ||
1174 | CONFIG_USB_XPAD=m | ||
1175 | CONFIG_USB_ATI_REMOTE=m | ||
1176 | # CONFIG_USB_KEYSPAN_REMOTE is not set | ||
1177 | # CONFIG_USB_APPLETOUCH is not set | ||
1178 | 1388 | ||
1179 | # | 1389 | # |
1180 | # USB Imaging devices | 1390 | # USB Imaging devices |
@@ -1183,56 +1393,22 @@ CONFIG_USB_MDC800=m | |||
1183 | CONFIG_USB_MICROTEK=m | 1393 | CONFIG_USB_MICROTEK=m |
1184 | 1394 | ||
1185 | # | 1395 | # |
1186 | # USB Multimedia devices | ||
1187 | # | ||
1188 | CONFIG_USB_DABUSB=m | ||
1189 | CONFIG_USB_VICAM=m | ||
1190 | CONFIG_USB_DSBR=m | ||
1191 | CONFIG_USB_IBMCAM=m | ||
1192 | CONFIG_USB_KONICAWC=m | ||
1193 | CONFIG_USB_OV511=m | ||
1194 | CONFIG_USB_SE401=m | ||
1195 | CONFIG_USB_SN9C102=m | ||
1196 | CONFIG_USB_STV680=m | ||
1197 | # CONFIG_USB_PWC is not set | ||
1198 | |||
1199 | # | ||
1200 | # USB Network Adapters | ||
1201 | # | ||
1202 | CONFIG_USB_CATC=m | ||
1203 | CONFIG_USB_KAWETH=m | ||
1204 | CONFIG_USB_PEGASUS=m | ||
1205 | CONFIG_USB_RTL8150=m | ||
1206 | CONFIG_USB_USBNET=m | ||
1207 | CONFIG_USB_NET_AX8817X=m | ||
1208 | CONFIG_USB_NET_CDCETHER=m | ||
1209 | # CONFIG_USB_NET_GL620A is not set | ||
1210 | CONFIG_USB_NET_NET1080=m | ||
1211 | # CONFIG_USB_NET_PLUSB is not set | ||
1212 | # CONFIG_USB_NET_RNDIS_HOST is not set | ||
1213 | # CONFIG_USB_NET_CDC_SUBSET is not set | ||
1214 | CONFIG_USB_NET_ZAURUS=m | ||
1215 | # CONFIG_USB_ZD1201 is not set | ||
1216 | CONFIG_USB_MON=y | ||
1217 | |||
1218 | # | ||
1219 | # USB port drivers | 1396 | # USB port drivers |
1220 | # | 1397 | # |
1221 | |||
1222 | # | ||
1223 | # USB Serial Converter support | ||
1224 | # | ||
1225 | CONFIG_USB_SERIAL=m | 1398 | CONFIG_USB_SERIAL=m |
1399 | CONFIG_USB_EZUSB=y | ||
1226 | CONFIG_USB_SERIAL_GENERIC=y | 1400 | CONFIG_USB_SERIAL_GENERIC=y |
1227 | # CONFIG_USB_SERIAL_AIRPRIME is not set | 1401 | # CONFIG_USB_SERIAL_AIRCABLE is not set |
1228 | # CONFIG_USB_SERIAL_ANYDATA is not set | 1402 | # CONFIG_USB_SERIAL_ARK3116 is not set |
1229 | CONFIG_USB_SERIAL_BELKIN=m | 1403 | CONFIG_USB_SERIAL_BELKIN=m |
1404 | # CONFIG_USB_SERIAL_CH341 is not set | ||
1230 | # CONFIG_USB_SERIAL_WHITEHEAT is not set | 1405 | # CONFIG_USB_SERIAL_WHITEHEAT is not set |
1231 | CONFIG_USB_SERIAL_DIGI_ACCELEPORT=m | 1406 | CONFIG_USB_SERIAL_DIGI_ACCELEPORT=m |
1232 | # CONFIG_USB_SERIAL_CP2101 is not set | 1407 | # CONFIG_USB_SERIAL_CP2101 is not set |
1233 | CONFIG_USB_SERIAL_CYPRESS_M8=m | 1408 | CONFIG_USB_SERIAL_CYPRESS_M8=m |
1234 | CONFIG_USB_SERIAL_EMPEG=m | 1409 | CONFIG_USB_SERIAL_EMPEG=m |
1235 | CONFIG_USB_SERIAL_FTDI_SIO=m | 1410 | CONFIG_USB_SERIAL_FTDI_SIO=m |
1411 | # CONFIG_USB_SERIAL_FUNSOFT is not set | ||
1236 | CONFIG_USB_SERIAL_VISOR=m | 1412 | CONFIG_USB_SERIAL_VISOR=m |
1237 | CONFIG_USB_SERIAL_IPAQ=m | 1413 | CONFIG_USB_SERIAL_IPAQ=m |
1238 | CONFIG_USB_SERIAL_IR=m | 1414 | CONFIG_USB_SERIAL_IR=m |
@@ -1240,6 +1416,7 @@ CONFIG_USB_SERIAL_EDGEPORT=m | |||
1240 | CONFIG_USB_SERIAL_EDGEPORT_TI=m | 1416 | CONFIG_USB_SERIAL_EDGEPORT_TI=m |
1241 | CONFIG_USB_SERIAL_GARMIN=m | 1417 | CONFIG_USB_SERIAL_GARMIN=m |
1242 | CONFIG_USB_SERIAL_IPW=m | 1418 | CONFIG_USB_SERIAL_IPW=m |
1419 | # CONFIG_USB_SERIAL_IUU is not set | ||
1243 | CONFIG_USB_SERIAL_KEYSPAN_PDA=m | 1420 | CONFIG_USB_SERIAL_KEYSPAN_PDA=m |
1244 | CONFIG_USB_SERIAL_KEYSPAN=m | 1421 | CONFIG_USB_SERIAL_KEYSPAN=m |
1245 | # CONFIG_USB_SERIAL_KEYSPAN_MPR is not set | 1422 | # CONFIG_USB_SERIAL_KEYSPAN_MPR is not set |
@@ -1257,50 +1434,68 @@ CONFIG_USB_SERIAL_KEYSPAN=m | |||
1257 | CONFIG_USB_SERIAL_KLSI=m | 1434 | CONFIG_USB_SERIAL_KLSI=m |
1258 | CONFIG_USB_SERIAL_KOBIL_SCT=m | 1435 | CONFIG_USB_SERIAL_KOBIL_SCT=m |
1259 | CONFIG_USB_SERIAL_MCT_U232=m | 1436 | CONFIG_USB_SERIAL_MCT_U232=m |
1437 | # CONFIG_USB_SERIAL_MOS7720 is not set | ||
1438 | # CONFIG_USB_SERIAL_MOS7840 is not set | ||
1439 | # CONFIG_USB_SERIAL_MOTOROLA is not set | ||
1440 | # CONFIG_USB_SERIAL_NAVMAN is not set | ||
1260 | CONFIG_USB_SERIAL_PL2303=m | 1441 | CONFIG_USB_SERIAL_PL2303=m |
1442 | # CONFIG_USB_SERIAL_OTI6858 is not set | ||
1443 | # CONFIG_USB_SERIAL_SPCP8X5 is not set | ||
1261 | # CONFIG_USB_SERIAL_HP4X is not set | 1444 | # CONFIG_USB_SERIAL_HP4X is not set |
1262 | CONFIG_USB_SERIAL_SAFE=m | 1445 | CONFIG_USB_SERIAL_SAFE=m |
1263 | # CONFIG_USB_SERIAL_SAFE_PADDED is not set | 1446 | # CONFIG_USB_SERIAL_SAFE_PADDED is not set |
1447 | # CONFIG_USB_SERIAL_SIERRAWIRELESS is not set | ||
1264 | CONFIG_USB_SERIAL_TI=m | 1448 | CONFIG_USB_SERIAL_TI=m |
1265 | CONFIG_USB_SERIAL_CYBERJACK=m | 1449 | CONFIG_USB_SERIAL_CYBERJACK=m |
1266 | CONFIG_USB_SERIAL_XIRCOM=m | 1450 | CONFIG_USB_SERIAL_XIRCOM=m |
1451 | # CONFIG_USB_SERIAL_OPTION is not set | ||
1267 | CONFIG_USB_SERIAL_OMNINET=m | 1452 | CONFIG_USB_SERIAL_OMNINET=m |
1268 | CONFIG_USB_EZUSB=y | 1453 | # CONFIG_USB_SERIAL_DEBUG is not set |
1269 | 1454 | ||
1270 | # | 1455 | # |
1271 | # USB Miscellaneous drivers | 1456 | # USB Miscellaneous drivers |
1272 | # | 1457 | # |
1273 | CONFIG_USB_EMI62=m | 1458 | CONFIG_USB_EMI62=m |
1274 | CONFIG_USB_EMI26=m | 1459 | CONFIG_USB_EMI26=m |
1275 | CONFIG_USB_AUERSWALD=m | 1460 | # CONFIG_USB_ADUTUX is not set |
1461 | # CONFIG_USB_SEVSEG is not set | ||
1276 | CONFIG_USB_RIO500=m | 1462 | CONFIG_USB_RIO500=m |
1277 | CONFIG_USB_LEGOTOWER=m | 1463 | CONFIG_USB_LEGOTOWER=m |
1278 | CONFIG_USB_LCD=m | 1464 | CONFIG_USB_LCD=m |
1465 | # CONFIG_USB_BERRY_CHARGE is not set | ||
1279 | CONFIG_USB_LED=m | 1466 | CONFIG_USB_LED=m |
1467 | # CONFIG_USB_CYPRESS_CY7C63 is not set | ||
1280 | CONFIG_USB_CYTHERM=m | 1468 | CONFIG_USB_CYTHERM=m |
1281 | CONFIG_USB_PHIDGETKIT=m | 1469 | # CONFIG_USB_PHIDGET is not set |
1282 | CONFIG_USB_PHIDGETSERVO=m | ||
1283 | CONFIG_USB_IDMOUSE=m | 1470 | CONFIG_USB_IDMOUSE=m |
1471 | # CONFIG_USB_FTDI_ELAN is not set | ||
1472 | # CONFIG_USB_APPLEDISPLAY is not set | ||
1284 | # CONFIG_USB_LD is not set | 1473 | # CONFIG_USB_LD is not set |
1474 | # CONFIG_USB_TRANCEVIBRATOR is not set | ||
1475 | # CONFIG_USB_IOWARRIOR is not set | ||
1285 | # CONFIG_USB_TEST is not set | 1476 | # CONFIG_USB_TEST is not set |
1286 | 1477 | # CONFIG_USB_ISIGHTFW is not set | |
1287 | # | 1478 | # CONFIG_USB_VST is not set |
1288 | # USB DSL modem support | ||
1289 | # | ||
1290 | |||
1291 | # | ||
1292 | # USB Gadget Support | ||
1293 | # | ||
1294 | CONFIG_USB_GADGET=y | 1479 | CONFIG_USB_GADGET=y |
1480 | # CONFIG_USB_GADGET_DEBUG is not set | ||
1295 | # CONFIG_USB_GADGET_DEBUG_FILES is not set | 1481 | # CONFIG_USB_GADGET_DEBUG_FILES is not set |
1482 | CONFIG_USB_GADGET_VBUS_DRAW=2 | ||
1296 | CONFIG_USB_GADGET_SELECTED=y | 1483 | CONFIG_USB_GADGET_SELECTED=y |
1297 | # CONFIG_USB_GADGET_NET2280 is not set | 1484 | # CONFIG_USB_GADGET_AT91 is not set |
1298 | CONFIG_USB_GADGET_PXA2XX=y | 1485 | # CONFIG_USB_GADGET_ATMEL_USBA is not set |
1299 | CONFIG_USB_PXA2XX=y | 1486 | # CONFIG_USB_GADGET_FSL_USB2 is not set |
1300 | # CONFIG_USB_PXA2XX_SMALL is not set | ||
1301 | # CONFIG_USB_GADGET_GOKU is not set | ||
1302 | # CONFIG_USB_GADGET_LH7A40X is not set | 1487 | # CONFIG_USB_GADGET_LH7A40X is not set |
1303 | # CONFIG_USB_GADGET_OMAP is not set | 1488 | # CONFIG_USB_GADGET_OMAP is not set |
1489 | CONFIG_USB_GADGET_PXA25X=y | ||
1490 | CONFIG_USB_PXA25X=y | ||
1491 | # CONFIG_USB_PXA25X_SMALL is not set | ||
1492 | # CONFIG_USB_GADGET_PXA27X is not set | ||
1493 | # CONFIG_USB_GADGET_S3C2410 is not set | ||
1494 | # CONFIG_USB_GADGET_M66592 is not set | ||
1495 | # CONFIG_USB_GADGET_AMD5536UDC is not set | ||
1496 | # CONFIG_USB_GADGET_FSL_QE is not set | ||
1497 | # CONFIG_USB_GADGET_NET2280 is not set | ||
1498 | # CONFIG_USB_GADGET_GOKU is not set | ||
1304 | # CONFIG_USB_GADGET_DUMMY_HCD is not set | 1499 | # CONFIG_USB_GADGET_DUMMY_HCD is not set |
1305 | # CONFIG_USB_GADGET_DUALSPEED is not set | 1500 | # CONFIG_USB_GADGET_DUALSPEED is not set |
1306 | CONFIG_USB_ZERO=m | 1501 | CONFIG_USB_ZERO=m |
@@ -1310,15 +1505,42 @@ CONFIG_USB_GADGETFS=m | |||
1310 | CONFIG_USB_FILE_STORAGE=m | 1505 | CONFIG_USB_FILE_STORAGE=m |
1311 | # CONFIG_USB_FILE_STORAGE_TEST is not set | 1506 | # CONFIG_USB_FILE_STORAGE_TEST is not set |
1312 | CONFIG_USB_G_SERIAL=m | 1507 | CONFIG_USB_G_SERIAL=m |
1508 | # CONFIG_USB_MIDI_GADGET is not set | ||
1509 | # CONFIG_USB_G_PRINTER is not set | ||
1510 | # CONFIG_USB_CDC_COMPOSITE is not set | ||
1511 | CONFIG_MMC=y | ||
1512 | # CONFIG_MMC_DEBUG is not set | ||
1513 | # CONFIG_MMC_UNSAFE_RESUME is not set | ||
1313 | 1514 | ||
1314 | # | 1515 | # |
1315 | # MMC/SD Card support | 1516 | # MMC/SD/SDIO Card Drivers |
1316 | # | 1517 | # |
1317 | CONFIG_MMC=y | ||
1318 | # CONFIG_MMC_DEBUG is not set | ||
1319 | CONFIG_MMC_BLOCK=y | 1518 | CONFIG_MMC_BLOCK=y |
1519 | CONFIG_MMC_BLOCK_BOUNCE=y | ||
1520 | # CONFIG_SDIO_UART is not set | ||
1521 | # CONFIG_MMC_TEST is not set | ||
1522 | |||
1523 | # | ||
1524 | # MMC/SD/SDIO Host Controller Drivers | ||
1525 | # | ||
1320 | CONFIG_MMC_PXA=y | 1526 | CONFIG_MMC_PXA=y |
1321 | # CONFIG_MMC_WBSD is not set | 1527 | # CONFIG_MMC_SDHCI is not set |
1528 | # CONFIG_MMC_SPI is not set | ||
1529 | # CONFIG_MEMSTICK is not set | ||
1530 | # CONFIG_ACCESSIBILITY is not set | ||
1531 | # CONFIG_NEW_LEDS is not set | ||
1532 | CONFIG_RTC_LIB=y | ||
1533 | # CONFIG_RTC_CLASS is not set | ||
1534 | # CONFIG_DMADEVICES is not set | ||
1535 | |||
1536 | # | ||
1537 | # Voltage and Current regulators | ||
1538 | # | ||
1539 | # CONFIG_REGULATOR is not set | ||
1540 | # CONFIG_REGULATOR_FIXED_VOLTAGE is not set | ||
1541 | # CONFIG_REGULATOR_VIRTUAL_CONSUMER is not set | ||
1542 | # CONFIG_REGULATOR_BQ24022 is not set | ||
1543 | # CONFIG_UIO is not set | ||
1322 | 1544 | ||
1323 | # | 1545 | # |
1324 | # File systems | 1546 | # File systems |
@@ -1327,16 +1549,17 @@ CONFIG_EXT2_FS=y | |||
1327 | # CONFIG_EXT2_FS_XATTR is not set | 1549 | # CONFIG_EXT2_FS_XATTR is not set |
1328 | # CONFIG_EXT2_FS_XIP is not set | 1550 | # CONFIG_EXT2_FS_XIP is not set |
1329 | # CONFIG_EXT3_FS is not set | 1551 | # CONFIG_EXT3_FS is not set |
1330 | # CONFIG_JBD is not set | 1552 | # CONFIG_EXT4_FS is not set |
1331 | # CONFIG_REISERFS_FS is not set | 1553 | # CONFIG_REISERFS_FS is not set |
1332 | # CONFIG_JFS_FS is not set | 1554 | # CONFIG_JFS_FS is not set |
1333 | # CONFIG_FS_POSIX_ACL is not set | 1555 | # CONFIG_FS_POSIX_ACL is not set |
1556 | CONFIG_FILE_LOCKING=y | ||
1334 | # CONFIG_XFS_FS is not set | 1557 | # CONFIG_XFS_FS is not set |
1335 | # CONFIG_MINIX_FS is not set | 1558 | # CONFIG_OCFS2_FS is not set |
1336 | # CONFIG_ROMFS_FS is not set | 1559 | CONFIG_DNOTIFY=y |
1337 | CONFIG_INOTIFY=y | 1560 | CONFIG_INOTIFY=y |
1561 | CONFIG_INOTIFY_USER=y | ||
1338 | # CONFIG_QUOTA is not set | 1562 | # CONFIG_QUOTA is not set |
1339 | CONFIG_DNOTIFY=y | ||
1340 | # CONFIG_AUTOFS_FS is not set | 1563 | # CONFIG_AUTOFS_FS is not set |
1341 | # CONFIG_AUTOFS4_FS is not set | 1564 | # CONFIG_AUTOFS4_FS is not set |
1342 | # CONFIG_FUSE_FS is not set | 1565 | # CONFIG_FUSE_FS is not set |
@@ -1361,11 +1584,13 @@ CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" | |||
1361 | # Pseudo filesystems | 1584 | # Pseudo filesystems |
1362 | # | 1585 | # |
1363 | CONFIG_PROC_FS=y | 1586 | CONFIG_PROC_FS=y |
1587 | CONFIG_PROC_SYSCTL=y | ||
1588 | CONFIG_PROC_PAGE_MONITOR=y | ||
1364 | CONFIG_SYSFS=y | 1589 | CONFIG_SYSFS=y |
1365 | CONFIG_TMPFS=y | 1590 | CONFIG_TMPFS=y |
1591 | # CONFIG_TMPFS_POSIX_ACL is not set | ||
1366 | # CONFIG_HUGETLB_PAGE is not set | 1592 | # CONFIG_HUGETLB_PAGE is not set |
1367 | CONFIG_RAMFS=y | 1593 | # CONFIG_CONFIGFS_FS is not set |
1368 | # CONFIG_RELAYFS_FS is not set | ||
1369 | 1594 | ||
1370 | # | 1595 | # |
1371 | # Miscellaneous filesystems | 1596 | # Miscellaneous filesystems |
@@ -1377,39 +1602,42 @@ CONFIG_RAMFS=y | |||
1377 | # CONFIG_BEFS_FS is not set | 1602 | # CONFIG_BEFS_FS is not set |
1378 | # CONFIG_BFS_FS is not set | 1603 | # CONFIG_BFS_FS is not set |
1379 | # CONFIG_EFS_FS is not set | 1604 | # CONFIG_EFS_FS is not set |
1380 | # CONFIG_JFFS_FS is not set | ||
1381 | CONFIG_JFFS2_FS=y | 1605 | CONFIG_JFFS2_FS=y |
1382 | CONFIG_JFFS2_FS_DEBUG=0 | 1606 | CONFIG_JFFS2_FS_DEBUG=0 |
1383 | CONFIG_JFFS2_FS_WRITEBUFFER=y | 1607 | CONFIG_JFFS2_FS_WRITEBUFFER=y |
1608 | # CONFIG_JFFS2_FS_WBUF_VERIFY is not set | ||
1384 | CONFIG_JFFS2_SUMMARY=y | 1609 | CONFIG_JFFS2_SUMMARY=y |
1610 | # CONFIG_JFFS2_FS_XATTR is not set | ||
1385 | CONFIG_JFFS2_COMPRESSION_OPTIONS=y | 1611 | CONFIG_JFFS2_COMPRESSION_OPTIONS=y |
1386 | CONFIG_JFFS2_ZLIB=y | 1612 | CONFIG_JFFS2_ZLIB=y |
1613 | # CONFIG_JFFS2_LZO is not set | ||
1387 | CONFIG_JFFS2_RTIME=y | 1614 | CONFIG_JFFS2_RTIME=y |
1388 | CONFIG_JFFS2_RUBIN=y | 1615 | CONFIG_JFFS2_RUBIN=y |
1389 | # CONFIG_JFFS2_CMODE_NONE is not set | 1616 | # CONFIG_JFFS2_CMODE_NONE is not set |
1390 | CONFIG_JFFS2_CMODE_PRIORITY=y | 1617 | CONFIG_JFFS2_CMODE_PRIORITY=y |
1391 | # CONFIG_JFFS2_CMODE_SIZE is not set | 1618 | # CONFIG_JFFS2_CMODE_SIZE is not set |
1619 | # CONFIG_JFFS2_CMODE_FAVOURLZO is not set | ||
1392 | CONFIG_CRAMFS=m | 1620 | CONFIG_CRAMFS=m |
1393 | # CONFIG_VXFS_FS is not set | 1621 | # CONFIG_VXFS_FS is not set |
1622 | # CONFIG_MINIX_FS is not set | ||
1623 | # CONFIG_OMFS_FS is not set | ||
1394 | # CONFIG_HPFS_FS is not set | 1624 | # CONFIG_HPFS_FS is not set |
1395 | # CONFIG_QNX4FS_FS is not set | 1625 | # CONFIG_QNX4FS_FS is not set |
1626 | # CONFIG_ROMFS_FS is not set | ||
1396 | # CONFIG_SYSV_FS is not set | 1627 | # CONFIG_SYSV_FS is not set |
1397 | # CONFIG_UFS_FS is not set | 1628 | # CONFIG_UFS_FS is not set |
1398 | 1629 | CONFIG_NETWORK_FILESYSTEMS=y | |
1399 | # | ||
1400 | # Network File Systems | ||
1401 | # | ||
1402 | CONFIG_NFS_FS=m | 1630 | CONFIG_NFS_FS=m |
1403 | CONFIG_NFS_V3=y | 1631 | CONFIG_NFS_V3=y |
1404 | # CONFIG_NFS_V3_ACL is not set | 1632 | # CONFIG_NFS_V3_ACL is not set |
1405 | CONFIG_NFS_V4=y | 1633 | CONFIG_NFS_V4=y |
1406 | # CONFIG_NFS_DIRECTIO is not set | ||
1407 | # CONFIG_NFSD is not set | 1634 | # CONFIG_NFSD is not set |
1408 | CONFIG_LOCKD=m | 1635 | CONFIG_LOCKD=m |
1409 | CONFIG_LOCKD_V4=y | 1636 | CONFIG_LOCKD_V4=y |
1410 | CONFIG_NFS_COMMON=y | 1637 | CONFIG_NFS_COMMON=y |
1411 | CONFIG_SUNRPC=m | 1638 | CONFIG_SUNRPC=m |
1412 | CONFIG_SUNRPC_GSS=m | 1639 | CONFIG_SUNRPC_GSS=m |
1640 | # CONFIG_SUNRPC_REGISTER_V4 is not set | ||
1413 | CONFIG_RPCSEC_GSS_KRB5=m | 1641 | CONFIG_RPCSEC_GSS_KRB5=m |
1414 | # CONFIG_RPCSEC_GSS_SPKM3 is not set | 1642 | # CONFIG_RPCSEC_GSS_SPKM3 is not set |
1415 | CONFIG_SMB_FS=m | 1643 | CONFIG_SMB_FS=m |
@@ -1419,7 +1647,6 @@ CONFIG_SMB_NLS_REMOTE="cp437" | |||
1419 | # CONFIG_NCP_FS is not set | 1647 | # CONFIG_NCP_FS is not set |
1420 | # CONFIG_CODA_FS is not set | 1648 | # CONFIG_CODA_FS is not set |
1421 | # CONFIG_AFS_FS is not set | 1649 | # CONFIG_AFS_FS is not set |
1422 | # CONFIG_9P_FS is not set | ||
1423 | 1650 | ||
1424 | # | 1651 | # |
1425 | # Partition Types | 1652 | # Partition Types |
@@ -1439,11 +1666,9 @@ CONFIG_MSDOS_PARTITION=y | |||
1439 | # CONFIG_SGI_PARTITION is not set | 1666 | # CONFIG_SGI_PARTITION is not set |
1440 | # CONFIG_ULTRIX_PARTITION is not set | 1667 | # CONFIG_ULTRIX_PARTITION is not set |
1441 | # CONFIG_SUN_PARTITION is not set | 1668 | # CONFIG_SUN_PARTITION is not set |
1669 | # CONFIG_KARMA_PARTITION is not set | ||
1442 | # CONFIG_EFI_PARTITION is not set | 1670 | # CONFIG_EFI_PARTITION is not set |
1443 | 1671 | # CONFIG_SYSV68_PARTITION is not set | |
1444 | # | ||
1445 | # Native Language Support | ||
1446 | # | ||
1447 | CONFIG_NLS=y | 1672 | CONFIG_NLS=y |
1448 | CONFIG_NLS_DEFAULT="cp437" | 1673 | CONFIG_NLS_DEFAULT="cp437" |
1449 | CONFIG_NLS_CODEPAGE_437=y | 1674 | CONFIG_NLS_CODEPAGE_437=y |
@@ -1484,35 +1709,71 @@ CONFIG_NLS_ISO8859_1=y | |||
1484 | # CONFIG_NLS_KOI8_R is not set | 1709 | # CONFIG_NLS_KOI8_R is not set |
1485 | # CONFIG_NLS_KOI8_U is not set | 1710 | # CONFIG_NLS_KOI8_U is not set |
1486 | CONFIG_NLS_UTF8=y | 1711 | CONFIG_NLS_UTF8=y |
1487 | 1712 | # CONFIG_DLM is not set | |
1488 | # | ||
1489 | # Profiling support | ||
1490 | # | ||
1491 | CONFIG_PROFILING=y | ||
1492 | CONFIG_OPROFILE=m | ||
1493 | 1713 | ||
1494 | # | 1714 | # |
1495 | # Kernel hacking | 1715 | # Kernel hacking |
1496 | # | 1716 | # |
1497 | # CONFIG_PRINTK_TIME is not set | 1717 | # CONFIG_PRINTK_TIME is not set |
1498 | CONFIG_DEBUG_KERNEL=y | 1718 | CONFIG_ENABLE_WARN_DEPRECATED=y |
1719 | CONFIG_ENABLE_MUST_CHECK=y | ||
1720 | CONFIG_FRAME_WARN=1024 | ||
1499 | CONFIG_MAGIC_SYSRQ=y | 1721 | CONFIG_MAGIC_SYSRQ=y |
1500 | CONFIG_LOG_BUF_SHIFT=14 | 1722 | # CONFIG_UNUSED_SYMBOLS is not set |
1723 | # CONFIG_DEBUG_FS is not set | ||
1724 | # CONFIG_HEADERS_CHECK is not set | ||
1725 | CONFIG_DEBUG_KERNEL=y | ||
1726 | # CONFIG_DEBUG_SHIRQ is not set | ||
1501 | CONFIG_DETECT_SOFTLOCKUP=y | 1727 | CONFIG_DETECT_SOFTLOCKUP=y |
1728 | # CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set | ||
1729 | CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC_VALUE=0 | ||
1730 | CONFIG_SCHED_DEBUG=y | ||
1502 | # CONFIG_SCHEDSTATS is not set | 1731 | # CONFIG_SCHEDSTATS is not set |
1503 | # CONFIG_DEBUG_SLAB is not set | 1732 | # CONFIG_TIMER_STATS is not set |
1733 | # CONFIG_DEBUG_OBJECTS is not set | ||
1734 | # CONFIG_SLUB_DEBUG_ON is not set | ||
1735 | # CONFIG_SLUB_STATS is not set | ||
1504 | # CONFIG_DEBUG_PREEMPT is not set | 1736 | # CONFIG_DEBUG_PREEMPT is not set |
1737 | # CONFIG_DEBUG_RT_MUTEXES is not set | ||
1738 | # CONFIG_RT_MUTEX_TESTER is not set | ||
1505 | # CONFIG_DEBUG_SPINLOCK is not set | 1739 | # CONFIG_DEBUG_SPINLOCK is not set |
1740 | # CONFIG_DEBUG_MUTEXES is not set | ||
1741 | # CONFIG_DEBUG_LOCK_ALLOC is not set | ||
1742 | # CONFIG_PROVE_LOCKING is not set | ||
1743 | # CONFIG_LOCK_STAT is not set | ||
1506 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set | 1744 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set |
1745 | # CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set | ||
1507 | # CONFIG_DEBUG_KOBJECT is not set | 1746 | # CONFIG_DEBUG_KOBJECT is not set |
1508 | CONFIG_DEBUG_BUGVERBOSE=y | 1747 | CONFIG_DEBUG_BUGVERBOSE=y |
1509 | # CONFIG_DEBUG_INFO is not set | 1748 | # CONFIG_DEBUG_INFO is not set |
1510 | # CONFIG_DEBUG_FS is not set | ||
1511 | # CONFIG_DEBUG_VM is not set | 1749 | # CONFIG_DEBUG_VM is not set |
1750 | # CONFIG_DEBUG_WRITECOUNT is not set | ||
1751 | # CONFIG_DEBUG_MEMORY_INIT is not set | ||
1752 | # CONFIG_DEBUG_LIST is not set | ||
1753 | # CONFIG_DEBUG_SG is not set | ||
1512 | CONFIG_FRAME_POINTER=y | 1754 | CONFIG_FRAME_POINTER=y |
1755 | # CONFIG_BOOT_PRINTK_DELAY is not set | ||
1513 | # CONFIG_RCU_TORTURE_TEST is not set | 1756 | # CONFIG_RCU_TORTURE_TEST is not set |
1757 | # CONFIG_RCU_CPU_STALL_DETECTOR is not set | ||
1758 | # CONFIG_BACKTRACE_SELF_TEST is not set | ||
1759 | # CONFIG_DEBUG_BLOCK_EXT_DEVT is not set | ||
1760 | # CONFIG_FAULT_INJECTION is not set | ||
1761 | # CONFIG_LATENCYTOP is not set | ||
1762 | # CONFIG_SYSCTL_SYSCALL_CHECK is not set | ||
1763 | CONFIG_HAVE_FTRACE=y | ||
1764 | CONFIG_HAVE_DYNAMIC_FTRACE=y | ||
1765 | # CONFIG_FTRACE is not set | ||
1766 | # CONFIG_IRQSOFF_TRACER is not set | ||
1767 | # CONFIG_PREEMPT_TRACER is not set | ||
1768 | # CONFIG_SCHED_TRACER is not set | ||
1769 | # CONFIG_CONTEXT_SWITCH_TRACER is not set | ||
1770 | # CONFIG_DYNAMIC_PRINTK_DEBUG is not set | ||
1771 | # CONFIG_SAMPLES is not set | ||
1772 | CONFIG_HAVE_ARCH_KGDB=y | ||
1773 | # CONFIG_KGDB is not set | ||
1514 | # CONFIG_DEBUG_USER is not set | 1774 | # CONFIG_DEBUG_USER is not set |
1515 | CONFIG_DEBUG_ERRORS=y | 1775 | CONFIG_DEBUG_ERRORS=y |
1776 | # CONFIG_DEBUG_STACK_USAGE is not set | ||
1516 | CONFIG_DEBUG_LL=y | 1777 | CONFIG_DEBUG_LL=y |
1517 | # CONFIG_DEBUG_ICEDCC is not set | 1778 | # CONFIG_DEBUG_ICEDCC is not set |
1518 | 1779 | ||
@@ -1521,46 +1782,113 @@ CONFIG_DEBUG_LL=y | |||
1521 | # | 1782 | # |
1522 | # CONFIG_KEYS is not set | 1783 | # CONFIG_KEYS is not set |
1523 | # CONFIG_SECURITY is not set | 1784 | # CONFIG_SECURITY is not set |
1785 | # CONFIG_SECURITYFS is not set | ||
1786 | # CONFIG_SECURITY_FILE_CAPABILITIES is not set | ||
1787 | CONFIG_CRYPTO=y | ||
1524 | 1788 | ||
1525 | # | 1789 | # |
1526 | # Cryptographic options | 1790 | # Crypto core or helper |
1527 | # | 1791 | # |
1528 | CONFIG_CRYPTO=y | 1792 | # CONFIG_CRYPTO_FIPS is not set |
1529 | CONFIG_CRYPTO_HMAC=y | 1793 | CONFIG_CRYPTO_ALGAPI=y |
1794 | CONFIG_CRYPTO_AEAD=y | ||
1795 | CONFIG_CRYPTO_BLKCIPHER=y | ||
1796 | CONFIG_CRYPTO_HASH=y | ||
1797 | CONFIG_CRYPTO_RNG=y | ||
1798 | CONFIG_CRYPTO_MANAGER=y | ||
1799 | # CONFIG_CRYPTO_GF128MUL is not set | ||
1530 | CONFIG_CRYPTO_NULL=m | 1800 | CONFIG_CRYPTO_NULL=m |
1801 | # CONFIG_CRYPTO_CRYPTD is not set | ||
1802 | CONFIG_CRYPTO_AUTHENC=m | ||
1803 | CONFIG_CRYPTO_TEST=m | ||
1804 | |||
1805 | # | ||
1806 | # Authenticated Encryption with Associated Data | ||
1807 | # | ||
1808 | # CONFIG_CRYPTO_CCM is not set | ||
1809 | # CONFIG_CRYPTO_GCM is not set | ||
1810 | # CONFIG_CRYPTO_SEQIV is not set | ||
1811 | |||
1812 | # | ||
1813 | # Block modes | ||
1814 | # | ||
1815 | CONFIG_CRYPTO_CBC=m | ||
1816 | # CONFIG_CRYPTO_CTR is not set | ||
1817 | # CONFIG_CRYPTO_CTS is not set | ||
1818 | CONFIG_CRYPTO_ECB=m | ||
1819 | # CONFIG_CRYPTO_LRW is not set | ||
1820 | # CONFIG_CRYPTO_PCBC is not set | ||
1821 | # CONFIG_CRYPTO_XTS is not set | ||
1822 | |||
1823 | # | ||
1824 | # Hash modes | ||
1825 | # | ||
1826 | CONFIG_CRYPTO_HMAC=y | ||
1827 | # CONFIG_CRYPTO_XCBC is not set | ||
1828 | |||
1829 | # | ||
1830 | # Digest | ||
1831 | # | ||
1832 | CONFIG_CRYPTO_CRC32C=m | ||
1531 | CONFIG_CRYPTO_MD4=m | 1833 | CONFIG_CRYPTO_MD4=m |
1532 | CONFIG_CRYPTO_MD5=m | 1834 | CONFIG_CRYPTO_MD5=m |
1835 | CONFIG_CRYPTO_MICHAEL_MIC=m | ||
1836 | # CONFIG_CRYPTO_RMD128 is not set | ||
1837 | # CONFIG_CRYPTO_RMD160 is not set | ||
1838 | # CONFIG_CRYPTO_RMD256 is not set | ||
1839 | # CONFIG_CRYPTO_RMD320 is not set | ||
1533 | CONFIG_CRYPTO_SHA1=m | 1840 | CONFIG_CRYPTO_SHA1=m |
1534 | CONFIG_CRYPTO_SHA256=m | 1841 | CONFIG_CRYPTO_SHA256=m |
1535 | CONFIG_CRYPTO_SHA512=m | 1842 | CONFIG_CRYPTO_SHA512=m |
1536 | CONFIG_CRYPTO_WP512=m | ||
1537 | # CONFIG_CRYPTO_TGR192 is not set | 1843 | # CONFIG_CRYPTO_TGR192 is not set |
1538 | CONFIG_CRYPTO_DES=m | 1844 | CONFIG_CRYPTO_WP512=m |
1539 | CONFIG_CRYPTO_BLOWFISH=m | 1845 | |
1540 | CONFIG_CRYPTO_TWOFISH=m | 1846 | # |
1541 | CONFIG_CRYPTO_SERPENT=m | 1847 | # Ciphers |
1848 | # | ||
1542 | CONFIG_CRYPTO_AES=m | 1849 | CONFIG_CRYPTO_AES=m |
1850 | CONFIG_CRYPTO_ANUBIS=m | ||
1851 | CONFIG_CRYPTO_ARC4=m | ||
1852 | CONFIG_CRYPTO_BLOWFISH=m | ||
1853 | # CONFIG_CRYPTO_CAMELLIA is not set | ||
1543 | CONFIG_CRYPTO_CAST5=m | 1854 | CONFIG_CRYPTO_CAST5=m |
1544 | CONFIG_CRYPTO_CAST6=m | 1855 | CONFIG_CRYPTO_CAST6=m |
1545 | CONFIG_CRYPTO_TEA=m | 1856 | CONFIG_CRYPTO_DES=m |
1546 | CONFIG_CRYPTO_ARC4=m | 1857 | # CONFIG_CRYPTO_FCRYPT is not set |
1547 | CONFIG_CRYPTO_KHAZAD=m | 1858 | CONFIG_CRYPTO_KHAZAD=m |
1548 | CONFIG_CRYPTO_ANUBIS=m | 1859 | # CONFIG_CRYPTO_SALSA20 is not set |
1860 | # CONFIG_CRYPTO_SEED is not set | ||
1861 | CONFIG_CRYPTO_SERPENT=m | ||
1862 | CONFIG_CRYPTO_TEA=m | ||
1863 | CONFIG_CRYPTO_TWOFISH=m | ||
1864 | CONFIG_CRYPTO_TWOFISH_COMMON=m | ||
1865 | |||
1866 | # | ||
1867 | # Compression | ||
1868 | # | ||
1549 | CONFIG_CRYPTO_DEFLATE=m | 1869 | CONFIG_CRYPTO_DEFLATE=m |
1550 | CONFIG_CRYPTO_MICHAEL_MIC=m | 1870 | # CONFIG_CRYPTO_LZO is not set |
1551 | CONFIG_CRYPTO_CRC32C=m | ||
1552 | CONFIG_CRYPTO_TEST=m | ||
1553 | 1871 | ||
1554 | # | 1872 | # |
1555 | # Hardware crypto devices | 1873 | # Random Number Generation |
1556 | # | 1874 | # |
1875 | # CONFIG_CRYPTO_ANSI_CPRNG is not set | ||
1876 | CONFIG_CRYPTO_HW=y | ||
1557 | 1877 | ||
1558 | # | 1878 | # |
1559 | # Library routines | 1879 | # Library routines |
1560 | # | 1880 | # |
1881 | CONFIG_BITREVERSE=y | ||
1561 | CONFIG_CRC_CCITT=y | 1882 | CONFIG_CRC_CCITT=y |
1562 | # CONFIG_CRC16 is not set | 1883 | # CONFIG_CRC16 is not set |
1884 | # CONFIG_CRC_T10DIF is not set | ||
1885 | # CONFIG_CRC_ITU_T is not set | ||
1563 | CONFIG_CRC32=y | 1886 | CONFIG_CRC32=y |
1887 | # CONFIG_CRC7 is not set | ||
1564 | CONFIG_LIBCRC32C=m | 1888 | CONFIG_LIBCRC32C=m |
1565 | CONFIG_ZLIB_INFLATE=y | 1889 | CONFIG_ZLIB_INFLATE=y |
1566 | CONFIG_ZLIB_DEFLATE=y | 1890 | CONFIG_ZLIB_DEFLATE=y |
1891 | CONFIG_PLIST=y | ||
1892 | CONFIG_HAS_IOMEM=y | ||
1893 | CONFIG_HAS_IOPORT=y | ||
1894 | CONFIG_HAS_DMA=y | ||
diff --git a/arch/arm/configs/msm_defconfig b/arch/arm/configs/msm_defconfig index ae4c5e62086a..3b4ecf2a90dd 100644 --- a/arch/arm/configs/msm_defconfig +++ b/arch/arm/configs/msm_defconfig | |||
@@ -133,7 +133,7 @@ CONFIG_DEFAULT_IOSCHED="anticipatory" | |||
133 | # CONFIG_ARCH_LH7A40X is not set | 133 | # CONFIG_ARCH_LH7A40X is not set |
134 | # CONFIG_ARCH_DAVINCI is not set | 134 | # CONFIG_ARCH_DAVINCI is not set |
135 | # CONFIG_ARCH_OMAP is not set | 135 | # CONFIG_ARCH_OMAP is not set |
136 | CONFIG_ARCH_MSM7X00A=y | 136 | CONFIG_ARCH_MSM=y |
137 | 137 | ||
138 | # | 138 | # |
139 | # Boot options | 139 | # Boot options |
diff --git a/arch/arm/configs/spitz_defconfig b/arch/arm/configs/spitz_defconfig index 7d59fb1f1cea..4df5b4db2aa0 100644 --- a/arch/arm/configs/spitz_defconfig +++ b/arch/arm/configs/spitz_defconfig | |||
@@ -1,71 +1,111 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.15-rc2 | 3 | # Linux kernel version: 2.6.27 |
4 | # Mon Nov 28 10:26:52 2005 | 4 | # Mon Oct 20 10:25:37 2008 |
5 | # | 5 | # |
6 | CONFIG_ARM=y | 6 | CONFIG_ARM=y |
7 | CONFIG_SYS_SUPPORTS_APM_EMULATION=y | ||
8 | CONFIG_GENERIC_GPIO=y | ||
9 | CONFIG_GENERIC_TIME=y | ||
10 | CONFIG_GENERIC_CLOCKEVENTS=y | ||
7 | CONFIG_MMU=y | 11 | CONFIG_MMU=y |
8 | CONFIG_UID16=y | 12 | # CONFIG_NO_IOPORT is not set |
13 | CONFIG_GENERIC_HARDIRQS=y | ||
14 | CONFIG_STACKTRACE_SUPPORT=y | ||
15 | CONFIG_HAVE_LATENCYTOP_SUPPORT=y | ||
16 | CONFIG_LOCKDEP_SUPPORT=y | ||
17 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | ||
18 | CONFIG_HARDIRQS_SW_RESEND=y | ||
19 | CONFIG_GENERIC_IRQ_PROBE=y | ||
9 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | 20 | CONFIG_RWSEM_GENERIC_SPINLOCK=y |
21 | # CONFIG_ARCH_HAS_ILOG2_U32 is not set | ||
22 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set | ||
23 | CONFIG_GENERIC_HWEIGHT=y | ||
10 | CONFIG_GENERIC_CALIBRATE_DELAY=y | 24 | CONFIG_GENERIC_CALIBRATE_DELAY=y |
25 | CONFIG_ARCH_MTD_XIP=y | ||
26 | CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y | ||
27 | CONFIG_VECTORS_BASE=0xffff0000 | ||
28 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | ||
11 | 29 | ||
12 | # | 30 | # |
13 | # Code maturity level options | 31 | # General setup |
14 | # | 32 | # |
15 | CONFIG_EXPERIMENTAL=y | 33 | CONFIG_EXPERIMENTAL=y |
16 | CONFIG_CLEAN_COMPILE=y | ||
17 | CONFIG_BROKEN_ON_SMP=y | 34 | CONFIG_BROKEN_ON_SMP=y |
18 | CONFIG_LOCK_KERNEL=y | 35 | CONFIG_LOCK_KERNEL=y |
19 | CONFIG_INIT_ENV_ARG_LIMIT=32 | 36 | CONFIG_INIT_ENV_ARG_LIMIT=32 |
20 | |||
21 | # | ||
22 | # General setup | ||
23 | # | ||
24 | CONFIG_LOCALVERSION="" | 37 | CONFIG_LOCALVERSION="" |
25 | CONFIG_LOCALVERSION_AUTO=y | 38 | CONFIG_LOCALVERSION_AUTO=y |
26 | CONFIG_SWAP=y | 39 | CONFIG_SWAP=y |
27 | CONFIG_SYSVIPC=y | 40 | CONFIG_SYSVIPC=y |
41 | CONFIG_SYSVIPC_SYSCTL=y | ||
28 | # CONFIG_POSIX_MQUEUE is not set | 42 | # CONFIG_POSIX_MQUEUE is not set |
29 | CONFIG_BSD_PROCESS_ACCT=y | 43 | CONFIG_BSD_PROCESS_ACCT=y |
30 | # CONFIG_BSD_PROCESS_ACCT_V3 is not set | 44 | # CONFIG_BSD_PROCESS_ACCT_V3 is not set |
31 | CONFIG_SYSCTL=y | 45 | # CONFIG_TASKSTATS is not set |
32 | # CONFIG_AUDIT is not set | 46 | # CONFIG_AUDIT is not set |
33 | CONFIG_HOTPLUG=y | ||
34 | CONFIG_KOBJECT_UEVENT=y | ||
35 | # CONFIG_IKCONFIG is not set | 47 | # CONFIG_IKCONFIG is not set |
36 | CONFIG_INITRAMFS_SOURCE="" | 48 | CONFIG_LOG_BUF_SHIFT=14 |
49 | # CONFIG_CGROUPS is not set | ||
50 | # CONFIG_GROUP_SCHED is not set | ||
51 | CONFIG_SYSFS_DEPRECATED=y | ||
52 | CONFIG_SYSFS_DEPRECATED_V2=y | ||
53 | # CONFIG_RELAY is not set | ||
54 | # CONFIG_NAMESPACES is not set | ||
55 | # CONFIG_BLK_DEV_INITRD is not set | ||
56 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | ||
57 | CONFIG_SYSCTL=y | ||
37 | CONFIG_EMBEDDED=y | 58 | CONFIG_EMBEDDED=y |
59 | CONFIG_UID16=y | ||
60 | CONFIG_SYSCTL_SYSCALL=y | ||
38 | CONFIG_KALLSYMS=y | 61 | CONFIG_KALLSYMS=y |
39 | # CONFIG_KALLSYMS_ALL is not set | 62 | # CONFIG_KALLSYMS_ALL is not set |
40 | # CONFIG_KALLSYMS_EXTRA_PASS is not set | 63 | # CONFIG_KALLSYMS_EXTRA_PASS is not set |
64 | CONFIG_HOTPLUG=y | ||
41 | CONFIG_PRINTK=y | 65 | CONFIG_PRINTK=y |
42 | CONFIG_BUG=y | 66 | CONFIG_BUG=y |
67 | CONFIG_ELF_CORE=y | ||
68 | CONFIG_COMPAT_BRK=y | ||
43 | CONFIG_BASE_FULL=y | 69 | CONFIG_BASE_FULL=y |
44 | CONFIG_FUTEX=y | 70 | CONFIG_FUTEX=y |
71 | CONFIG_ANON_INODES=y | ||
45 | CONFIG_EPOLL=y | 72 | CONFIG_EPOLL=y |
46 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | 73 | CONFIG_SIGNALFD=y |
74 | CONFIG_TIMERFD=y | ||
75 | CONFIG_EVENTFD=y | ||
47 | CONFIG_SHMEM=y | 76 | CONFIG_SHMEM=y |
48 | CONFIG_CC_ALIGN_FUNCTIONS=0 | 77 | CONFIG_AIO=y |
49 | CONFIG_CC_ALIGN_LABELS=0 | 78 | CONFIG_VM_EVENT_COUNTERS=y |
50 | CONFIG_CC_ALIGN_LOOPS=0 | 79 | CONFIG_SLUB_DEBUG=y |
51 | CONFIG_CC_ALIGN_JUMPS=0 | 80 | # CONFIG_SLAB is not set |
81 | CONFIG_SLUB=y | ||
82 | # CONFIG_SLOB is not set | ||
83 | CONFIG_PROFILING=y | ||
84 | # CONFIG_MARKERS is not set | ||
85 | CONFIG_OPROFILE=m | ||
86 | CONFIG_HAVE_OPROFILE=y | ||
87 | # CONFIG_KPROBES is not set | ||
88 | CONFIG_HAVE_KPROBES=y | ||
89 | CONFIG_HAVE_KRETPROBES=y | ||
90 | CONFIG_HAVE_CLK=y | ||
91 | CONFIG_HAVE_GENERIC_DMA_COHERENT=y | ||
92 | CONFIG_SLABINFO=y | ||
93 | CONFIG_RT_MUTEXES=y | ||
52 | # CONFIG_TINY_SHMEM is not set | 94 | # CONFIG_TINY_SHMEM is not set |
53 | CONFIG_BASE_SMALL=0 | 95 | CONFIG_BASE_SMALL=0 |
54 | |||
55 | # | ||
56 | # Loadable module support | ||
57 | # | ||
58 | CONFIG_MODULES=y | 96 | CONFIG_MODULES=y |
97 | # CONFIG_MODULE_FORCE_LOAD is not set | ||
59 | CONFIG_MODULE_UNLOAD=y | 98 | CONFIG_MODULE_UNLOAD=y |
60 | CONFIG_MODULE_FORCE_UNLOAD=y | 99 | CONFIG_MODULE_FORCE_UNLOAD=y |
61 | CONFIG_OBSOLETE_MODPARM=y | ||
62 | # CONFIG_MODVERSIONS is not set | 100 | # CONFIG_MODVERSIONS is not set |
63 | # CONFIG_MODULE_SRCVERSION_ALL is not set | 101 | # CONFIG_MODULE_SRCVERSION_ALL is not set |
64 | CONFIG_KMOD=y | 102 | CONFIG_KMOD=y |
65 | 103 | CONFIG_BLOCK=y | |
66 | # | 104 | # CONFIG_LBD is not set |
67 | # Block layer | 105 | # CONFIG_BLK_DEV_IO_TRACE is not set |
68 | # | 106 | # CONFIG_LSF is not set |
107 | # CONFIG_BLK_DEV_BSG is not set | ||
108 | # CONFIG_BLK_DEV_INTEGRITY is not set | ||
69 | 109 | ||
70 | # | 110 | # |
71 | # IO Schedulers | 111 | # IO Schedulers |
@@ -79,49 +119,95 @@ CONFIG_DEFAULT_AS=y | |||
79 | # CONFIG_DEFAULT_CFQ is not set | 119 | # CONFIG_DEFAULT_CFQ is not set |
80 | # CONFIG_DEFAULT_NOOP is not set | 120 | # CONFIG_DEFAULT_NOOP is not set |
81 | CONFIG_DEFAULT_IOSCHED="anticipatory" | 121 | CONFIG_DEFAULT_IOSCHED="anticipatory" |
122 | CONFIG_CLASSIC_RCU=y | ||
82 | 123 | ||
83 | # | 124 | # |
84 | # System Type | 125 | # System Type |
85 | # | 126 | # |
127 | # CONFIG_ARCH_AAEC2000 is not set | ||
128 | # CONFIG_ARCH_INTEGRATOR is not set | ||
129 | # CONFIG_ARCH_REALVIEW is not set | ||
130 | # CONFIG_ARCH_VERSATILE is not set | ||
131 | # CONFIG_ARCH_AT91 is not set | ||
86 | # CONFIG_ARCH_CLPS7500 is not set | 132 | # CONFIG_ARCH_CLPS7500 is not set |
87 | # CONFIG_ARCH_CLPS711X is not set | 133 | # CONFIG_ARCH_CLPS711X is not set |
88 | # CONFIG_ARCH_CO285 is not set | ||
89 | # CONFIG_ARCH_EBSA110 is not set | 134 | # CONFIG_ARCH_EBSA110 is not set |
135 | # CONFIG_ARCH_EP93XX is not set | ||
90 | # CONFIG_ARCH_FOOTBRIDGE is not set | 136 | # CONFIG_ARCH_FOOTBRIDGE is not set |
91 | # CONFIG_ARCH_INTEGRATOR is not set | 137 | # CONFIG_ARCH_NETX is not set |
92 | # CONFIG_ARCH_IOP3XX is not set | 138 | # CONFIG_ARCH_H720X is not set |
93 | # CONFIG_ARCH_IXP4XX is not set | 139 | # CONFIG_ARCH_IMX is not set |
140 | # CONFIG_ARCH_IOP13XX is not set | ||
141 | # CONFIG_ARCH_IOP32X is not set | ||
142 | # CONFIG_ARCH_IOP33X is not set | ||
143 | # CONFIG_ARCH_IXP23XX is not set | ||
94 | # CONFIG_ARCH_IXP2000 is not set | 144 | # CONFIG_ARCH_IXP2000 is not set |
145 | # CONFIG_ARCH_IXP4XX is not set | ||
95 | # CONFIG_ARCH_L7200 is not set | 146 | # CONFIG_ARCH_L7200 is not set |
147 | # CONFIG_ARCH_KIRKWOOD is not set | ||
148 | # CONFIG_ARCH_KS8695 is not set | ||
149 | # CONFIG_ARCH_NS9XXX is not set | ||
150 | # CONFIG_ARCH_LOKI is not set | ||
151 | # CONFIG_ARCH_MV78XX0 is not set | ||
152 | # CONFIG_ARCH_MXC is not set | ||
153 | # CONFIG_ARCH_ORION5X is not set | ||
154 | # CONFIG_ARCH_PNX4008 is not set | ||
96 | CONFIG_ARCH_PXA=y | 155 | CONFIG_ARCH_PXA=y |
97 | # CONFIG_ARCH_RPC is not set | 156 | # CONFIG_ARCH_RPC is not set |
98 | # CONFIG_ARCH_SA1100 is not set | 157 | # CONFIG_ARCH_SA1100 is not set |
99 | # CONFIG_ARCH_S3C2410 is not set | 158 | # CONFIG_ARCH_S3C2410 is not set |
100 | # CONFIG_ARCH_SHARK is not set | 159 | # CONFIG_ARCH_SHARK is not set |
101 | # CONFIG_ARCH_LH7A40X is not set | 160 | # CONFIG_ARCH_LH7A40X is not set |
161 | # CONFIG_ARCH_DAVINCI is not set | ||
102 | # CONFIG_ARCH_OMAP is not set | 162 | # CONFIG_ARCH_OMAP is not set |
103 | # CONFIG_ARCH_VERSATILE is not set | 163 | # CONFIG_ARCH_MSM7X00A is not set |
104 | # CONFIG_ARCH_REALVIEW is not set | ||
105 | # CONFIG_ARCH_IMX is not set | ||
106 | # CONFIG_ARCH_H720X is not set | ||
107 | # CONFIG_ARCH_AAEC2000 is not set | ||
108 | 164 | ||
109 | # | 165 | # |
110 | # Intel PXA2xx Implementations | 166 | # Intel PXA2xx/PXA3xx Implementations |
111 | # | 167 | # |
168 | # CONFIG_ARCH_GUMSTIX is not set | ||
112 | # CONFIG_ARCH_LUBBOCK is not set | 169 | # CONFIG_ARCH_LUBBOCK is not set |
170 | # CONFIG_MACH_LOGICPD_PXA270 is not set | ||
113 | # CONFIG_MACH_MAINSTONE is not set | 171 | # CONFIG_MACH_MAINSTONE is not set |
172 | # CONFIG_MACH_MP900C is not set | ||
114 | # CONFIG_ARCH_PXA_IDP is not set | 173 | # CONFIG_ARCH_PXA_IDP is not set |
115 | CONFIG_PXA_SHARPSL=y | 174 | CONFIG_PXA_SHARPSL=y |
116 | # CONFIG_PXA_SHARPSL_25x is not set | 175 | # CONFIG_MACH_POODLE is not set |
117 | CONFIG_PXA_SHARPSL_27x=y | 176 | # CONFIG_MACH_CORGI is not set |
177 | # CONFIG_MACH_SHEPHERD is not set | ||
178 | # CONFIG_MACH_HUSKY is not set | ||
118 | CONFIG_MACH_AKITA=y | 179 | CONFIG_MACH_AKITA=y |
119 | CONFIG_MACH_SPITZ=y | 180 | CONFIG_MACH_SPITZ=y |
120 | CONFIG_MACH_BORZOI=y | 181 | CONFIG_MACH_BORZOI=y |
182 | # CONFIG_MACH_TOSA is not set | ||
183 | # CONFIG_ARCH_VIPER is not set | ||
184 | # CONFIG_ARCH_PXA_ESERIES is not set | ||
185 | # CONFIG_TRIZEPS_PXA is not set | ||
186 | # CONFIG_MACH_EM_X270 is not set | ||
187 | # CONFIG_MACH_COLIBRI is not set | ||
188 | # CONFIG_MACH_ZYLONITE is not set | ||
189 | # CONFIG_MACH_LITTLETON is not set | ||
190 | # CONFIG_MACH_TAVOREVB is not set | ||
191 | # CONFIG_MACH_SAAR is not set | ||
192 | # CONFIG_MACH_ARMCORE is not set | ||
193 | # CONFIG_MACH_CM_X300 is not set | ||
194 | # CONFIG_MACH_MAGICIAN is not set | ||
195 | # CONFIG_MACH_MIOA701 is not set | ||
196 | # CONFIG_MACH_PCM027 is not set | ||
197 | # CONFIG_ARCH_PXA_PALM is not set | ||
198 | # CONFIG_PXA_EZX is not set | ||
121 | CONFIG_PXA27x=y | 199 | CONFIG_PXA27x=y |
122 | CONFIG_IWMMXT=y | ||
123 | CONFIG_PXA_SHARP_Cxx00=y | 200 | CONFIG_PXA_SHARP_Cxx00=y |
124 | CONFIG_PXA_SSP=y | 201 | CONFIG_PXA_SSP=y |
202 | # CONFIG_PXA_PWM is not set | ||
203 | |||
204 | # | ||
205 | # Boot options | ||
206 | # | ||
207 | |||
208 | # | ||
209 | # Power management | ||
210 | # | ||
125 | 211 | ||
126 | # | 212 | # |
127 | # Processor Type | 213 | # Processor Type |
@@ -130,25 +216,29 @@ CONFIG_CPU_32=y | |||
130 | CONFIG_CPU_XSCALE=y | 216 | CONFIG_CPU_XSCALE=y |
131 | CONFIG_CPU_32v5=y | 217 | CONFIG_CPU_32v5=y |
132 | CONFIG_CPU_ABRT_EV5T=y | 218 | CONFIG_CPU_ABRT_EV5T=y |
219 | CONFIG_CPU_PABRT_NOIFAR=y | ||
133 | CONFIG_CPU_CACHE_VIVT=y | 220 | CONFIG_CPU_CACHE_VIVT=y |
134 | CONFIG_CPU_TLB_V4WBI=y | 221 | CONFIG_CPU_TLB_V4WBI=y |
222 | CONFIG_CPU_CP15=y | ||
223 | CONFIG_CPU_CP15_MMU=y | ||
135 | 224 | ||
136 | # | 225 | # |
137 | # Processor Features | 226 | # Processor Features |
138 | # | 227 | # |
139 | CONFIG_ARM_THUMB=y | 228 | CONFIG_ARM_THUMB=y |
229 | # CONFIG_CPU_DCACHE_DISABLE is not set | ||
230 | # CONFIG_OUTER_CACHE is not set | ||
231 | CONFIG_IWMMXT=y | ||
140 | CONFIG_XSCALE_PMU=y | 232 | CONFIG_XSCALE_PMU=y |
141 | CONFIG_SHARP_PARAM=y | 233 | CONFIG_SHARP_PARAM=y |
234 | CONFIG_SHARPSL_PM=y | ||
142 | CONFIG_SHARP_SCOOP=y | 235 | CONFIG_SHARP_SCOOP=y |
143 | 236 | ||
144 | # | 237 | # |
145 | # Bus support | 238 | # Bus support |
146 | # | 239 | # |
147 | CONFIG_ISA_DMA_API=y | 240 | # CONFIG_PCI_SYSCALL is not set |
148 | 241 | # CONFIG_ARCH_SUPPORTS_MSI is not set | |
149 | # | ||
150 | # PCCARD (PCMCIA/CardBus) support | ||
151 | # | ||
152 | CONFIG_PCCARD=y | 242 | CONFIG_PCCARD=y |
153 | # CONFIG_PCMCIA_DEBUG is not set | 243 | # CONFIG_PCMCIA_DEBUG is not set |
154 | CONFIG_PCMCIA=y | 244 | CONFIG_PCMCIA=y |
@@ -163,16 +253,32 @@ CONFIG_PCMCIA_PXA2XX=y | |||
163 | # | 253 | # |
164 | # Kernel Features | 254 | # Kernel Features |
165 | # | 255 | # |
256 | CONFIG_TICK_ONESHOT=y | ||
257 | # CONFIG_NO_HZ is not set | ||
258 | # CONFIG_HIGH_RES_TIMERS is not set | ||
259 | CONFIG_GENERIC_CLOCKEVENTS_BUILD=y | ||
260 | CONFIG_VMSPLIT_3G=y | ||
261 | # CONFIG_VMSPLIT_2G is not set | ||
262 | # CONFIG_VMSPLIT_1G is not set | ||
263 | CONFIG_PAGE_OFFSET=0xC0000000 | ||
166 | CONFIG_PREEMPT=y | 264 | CONFIG_PREEMPT=y |
167 | # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set | 265 | CONFIG_HZ=100 |
266 | # CONFIG_AEABI is not set | ||
267 | CONFIG_ARCH_FLATMEM_HAS_HOLES=y | ||
268 | # CONFIG_ARCH_SPARSEMEM_DEFAULT is not set | ||
269 | # CONFIG_ARCH_SELECT_MEMORY_MODEL is not set | ||
168 | CONFIG_SELECT_MEMORY_MODEL=y | 270 | CONFIG_SELECT_MEMORY_MODEL=y |
169 | CONFIG_FLATMEM_MANUAL=y | 271 | CONFIG_FLATMEM_MANUAL=y |
170 | # CONFIG_DISCONTIGMEM_MANUAL is not set | 272 | # CONFIG_DISCONTIGMEM_MANUAL is not set |
171 | # CONFIG_SPARSEMEM_MANUAL is not set | 273 | # CONFIG_SPARSEMEM_MANUAL is not set |
172 | CONFIG_FLATMEM=y | 274 | CONFIG_FLATMEM=y |
173 | CONFIG_FLAT_NODE_MEM_MAP=y | 275 | CONFIG_FLAT_NODE_MEM_MAP=y |
174 | # CONFIG_SPARSEMEM_STATIC is not set | 276 | CONFIG_PAGEFLAGS_EXTENDED=y |
175 | CONFIG_SPLIT_PTLOCK_CPUS=4096 | 277 | CONFIG_SPLIT_PTLOCK_CPUS=4096 |
278 | # CONFIG_RESOURCES_64BIT is not set | ||
279 | # CONFIG_PHYS_ADDR_T_64BIT is not set | ||
280 | CONFIG_ZONE_DMA_FLAG=0 | ||
281 | CONFIG_VIRT_TO_BUS=y | ||
176 | CONFIG_ALIGNMENT_TRAP=y | 282 | CONFIG_ALIGNMENT_TRAP=y |
177 | 283 | ||
178 | # | 284 | # |
@@ -182,6 +288,13 @@ CONFIG_ZBOOT_ROM_TEXT=0x0 | |||
182 | CONFIG_ZBOOT_ROM_BSS=0x0 | 288 | CONFIG_ZBOOT_ROM_BSS=0x0 |
183 | CONFIG_CMDLINE="console=ttyS0,115200n8 console=tty1 noinitrd root=/dev/mtdblock2 rootfstype=jffs2 debug" | 289 | CONFIG_CMDLINE="console=ttyS0,115200n8 console=tty1 noinitrd root=/dev/mtdblock2 rootfstype=jffs2 debug" |
184 | # CONFIG_XIP_KERNEL is not set | 290 | # CONFIG_XIP_KERNEL is not set |
291 | # CONFIG_KEXEC is not set | ||
292 | |||
293 | # | ||
294 | # CPU Power Management | ||
295 | # | ||
296 | # CONFIG_CPU_FREQ is not set | ||
297 | # CONFIG_CPU_IDLE is not set | ||
185 | 298 | ||
186 | # | 299 | # |
187 | # Floating point emulation | 300 | # Floating point emulation |
@@ -198,6 +311,7 @@ CONFIG_FPE_NWFPE=y | |||
198 | # Userspace binary formats | 311 | # Userspace binary formats |
199 | # | 312 | # |
200 | CONFIG_BINFMT_ELF=y | 313 | CONFIG_BINFMT_ELF=y |
314 | CONFIG_HAVE_AOUT=y | ||
201 | CONFIG_BINFMT_AOUT=m | 315 | CONFIG_BINFMT_AOUT=m |
202 | CONFIG_BINFMT_MISC=m | 316 | CONFIG_BINFMT_MISC=m |
203 | # CONFIG_ARTHUR is not set | 317 | # CONFIG_ARTHUR is not set |
@@ -206,12 +320,12 @@ CONFIG_BINFMT_MISC=m | |||
206 | # Power management options | 320 | # Power management options |
207 | # | 321 | # |
208 | CONFIG_PM=y | 322 | CONFIG_PM=y |
209 | # CONFIG_PM_LEGACY is not set | 323 | # CONFIG_PM_DEBUG is not set |
210 | CONFIG_APM=y | 324 | CONFIG_PM_SLEEP=y |
211 | 325 | CONFIG_SUSPEND=y | |
212 | # | 326 | CONFIG_SUSPEND_FREEZER=y |
213 | # Networking | 327 | CONFIG_APM_EMULATION=y |
214 | # | 328 | CONFIG_ARCH_SUSPEND_POSSIBLE=y |
215 | CONFIG_NET=y | 329 | CONFIG_NET=y |
216 | 330 | ||
217 | # | 331 | # |
@@ -222,6 +336,10 @@ CONFIG_PACKET_MMAP=y | |||
222 | CONFIG_UNIX=y | 336 | CONFIG_UNIX=y |
223 | CONFIG_XFRM=y | 337 | CONFIG_XFRM=y |
224 | # CONFIG_XFRM_USER is not set | 338 | # CONFIG_XFRM_USER is not set |
339 | # CONFIG_XFRM_SUB_POLICY is not set | ||
340 | # CONFIG_XFRM_MIGRATE is not set | ||
341 | # CONFIG_XFRM_STATISTICS is not set | ||
342 | CONFIG_XFRM_IPCOMP=m | ||
225 | # CONFIG_NET_KEY is not set | 343 | # CONFIG_NET_KEY is not set |
226 | CONFIG_INET=y | 344 | CONFIG_INET=y |
227 | # CONFIG_IP_MULTICAST is not set | 345 | # CONFIG_IP_MULTICAST is not set |
@@ -235,140 +353,131 @@ CONFIG_SYN_COOKIES=y | |||
235 | # CONFIG_INET_AH is not set | 353 | # CONFIG_INET_AH is not set |
236 | # CONFIG_INET_ESP is not set | 354 | # CONFIG_INET_ESP is not set |
237 | # CONFIG_INET_IPCOMP is not set | 355 | # CONFIG_INET_IPCOMP is not set |
238 | # CONFIG_INET_TUNNEL is not set | 356 | # CONFIG_INET_XFRM_TUNNEL is not set |
357 | CONFIG_INET_TUNNEL=m | ||
358 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | ||
359 | CONFIG_INET_XFRM_MODE_TUNNEL=y | ||
360 | CONFIG_INET_XFRM_MODE_BEET=y | ||
361 | # CONFIG_INET_LRO is not set | ||
239 | CONFIG_INET_DIAG=y | 362 | CONFIG_INET_DIAG=y |
240 | CONFIG_INET_TCP_DIAG=y | 363 | CONFIG_INET_TCP_DIAG=y |
241 | # CONFIG_TCP_CONG_ADVANCED is not set | 364 | # CONFIG_TCP_CONG_ADVANCED is not set |
242 | CONFIG_TCP_CONG_BIC=y | 365 | CONFIG_TCP_CONG_CUBIC=y |
243 | 366 | CONFIG_DEFAULT_TCP_CONG="cubic" | |
244 | # | 367 | # CONFIG_TCP_MD5SIG is not set |
245 | # IP: Virtual Server Configuration | ||
246 | # | ||
247 | # CONFIG_IP_VS is not set | ||
248 | CONFIG_IPV6=m | 368 | CONFIG_IPV6=m |
249 | # CONFIG_IPV6_PRIVACY is not set | 369 | # CONFIG_IPV6_PRIVACY is not set |
370 | # CONFIG_IPV6_ROUTER_PREF is not set | ||
371 | # CONFIG_IPV6_OPTIMISTIC_DAD is not set | ||
250 | CONFIG_INET6_AH=m | 372 | CONFIG_INET6_AH=m |
251 | CONFIG_INET6_ESP=m | 373 | CONFIG_INET6_ESP=m |
252 | CONFIG_INET6_IPCOMP=m | 374 | CONFIG_INET6_IPCOMP=m |
375 | # CONFIG_IPV6_MIP6 is not set | ||
376 | CONFIG_INET6_XFRM_TUNNEL=m | ||
253 | CONFIG_INET6_TUNNEL=m | 377 | CONFIG_INET6_TUNNEL=m |
378 | CONFIG_INET6_XFRM_MODE_TRANSPORT=m | ||
379 | CONFIG_INET6_XFRM_MODE_TUNNEL=m | ||
380 | CONFIG_INET6_XFRM_MODE_BEET=m | ||
381 | # CONFIG_INET6_XFRM_MODE_ROUTEOPTIMIZATION is not set | ||
382 | CONFIG_IPV6_SIT=m | ||
383 | CONFIG_IPV6_NDISC_NODETYPE=y | ||
254 | CONFIG_IPV6_TUNNEL=m | 384 | CONFIG_IPV6_TUNNEL=m |
385 | # CONFIG_IPV6_MULTIPLE_TABLES is not set | ||
386 | # CONFIG_IPV6_MROUTE is not set | ||
387 | # CONFIG_NETWORK_SECMARK is not set | ||
255 | CONFIG_NETFILTER=y | 388 | CONFIG_NETFILTER=y |
256 | # CONFIG_NETFILTER_DEBUG is not set | 389 | # CONFIG_NETFILTER_DEBUG is not set |
390 | CONFIG_NETFILTER_ADVANCED=y | ||
257 | 391 | ||
258 | # | 392 | # |
259 | # Core Netfilter Configuration | 393 | # Core Netfilter Configuration |
260 | # | 394 | # |
261 | # CONFIG_NETFILTER_NETLINK is not set | 395 | # CONFIG_NETFILTER_NETLINK_QUEUE is not set |
396 | # CONFIG_NETFILTER_NETLINK_LOG is not set | ||
397 | # CONFIG_NF_CONNTRACK is not set | ||
398 | CONFIG_NETFILTER_XTABLES=m | ||
399 | # CONFIG_NETFILTER_XT_TARGET_CLASSIFY is not set | ||
400 | # CONFIG_NETFILTER_XT_TARGET_DSCP is not set | ||
401 | # CONFIG_NETFILTER_XT_TARGET_MARK is not set | ||
402 | # CONFIG_NETFILTER_XT_TARGET_NFLOG is not set | ||
403 | # CONFIG_NETFILTER_XT_TARGET_NFQUEUE is not set | ||
404 | # CONFIG_NETFILTER_XT_TARGET_RATEEST is not set | ||
405 | # CONFIG_NETFILTER_XT_TARGET_TRACE is not set | ||
406 | # CONFIG_NETFILTER_XT_TARGET_TCPMSS is not set | ||
407 | # CONFIG_NETFILTER_XT_TARGET_TCPOPTSTRIP is not set | ||
408 | # CONFIG_NETFILTER_XT_MATCH_COMMENT is not set | ||
409 | # CONFIG_NETFILTER_XT_MATCH_DCCP is not set | ||
410 | # CONFIG_NETFILTER_XT_MATCH_DSCP is not set | ||
411 | # CONFIG_NETFILTER_XT_MATCH_ESP is not set | ||
412 | # CONFIG_NETFILTER_XT_MATCH_HASHLIMIT is not set | ||
413 | # CONFIG_NETFILTER_XT_MATCH_IPRANGE is not set | ||
414 | # CONFIG_NETFILTER_XT_MATCH_LENGTH is not set | ||
415 | # CONFIG_NETFILTER_XT_MATCH_LIMIT is not set | ||
416 | # CONFIG_NETFILTER_XT_MATCH_MAC is not set | ||
417 | # CONFIG_NETFILTER_XT_MATCH_MARK is not set | ||
418 | # CONFIG_NETFILTER_XT_MATCH_MULTIPORT is not set | ||
419 | # CONFIG_NETFILTER_XT_MATCH_OWNER is not set | ||
420 | # CONFIG_NETFILTER_XT_MATCH_POLICY is not set | ||
421 | # CONFIG_NETFILTER_XT_MATCH_PKTTYPE is not set | ||
422 | # CONFIG_NETFILTER_XT_MATCH_QUOTA is not set | ||
423 | # CONFIG_NETFILTER_XT_MATCH_RATEEST is not set | ||
424 | # CONFIG_NETFILTER_XT_MATCH_REALM is not set | ||
425 | # CONFIG_NETFILTER_XT_MATCH_RECENT is not set | ||
426 | # CONFIG_NETFILTER_XT_MATCH_SCTP is not set | ||
427 | # CONFIG_NETFILTER_XT_MATCH_STATISTIC is not set | ||
428 | # CONFIG_NETFILTER_XT_MATCH_STRING is not set | ||
429 | # CONFIG_NETFILTER_XT_MATCH_TCPMSS is not set | ||
430 | # CONFIG_NETFILTER_XT_MATCH_TIME is not set | ||
431 | # CONFIG_NETFILTER_XT_MATCH_U32 is not set | ||
432 | # CONFIG_IP_VS is not set | ||
262 | 433 | ||
263 | # | 434 | # |
264 | # IP: Netfilter Configuration | 435 | # IP: Netfilter Configuration |
265 | # | 436 | # |
266 | CONFIG_IP_NF_CONNTRACK=m | 437 | # CONFIG_NF_DEFRAG_IPV4 is not set |
267 | # CONFIG_IP_NF_CT_ACCT is not set | ||
268 | # CONFIG_IP_NF_CONNTRACK_MARK is not set | ||
269 | # CONFIG_IP_NF_CONNTRACK_EVENTS is not set | ||
270 | CONFIG_IP_NF_CT_PROTO_SCTP=m | ||
271 | CONFIG_IP_NF_FTP=m | ||
272 | CONFIG_IP_NF_IRC=m | ||
273 | # CONFIG_IP_NF_NETBIOS_NS is not set | ||
274 | CONFIG_IP_NF_TFTP=m | ||
275 | CONFIG_IP_NF_AMANDA=m | ||
276 | # CONFIG_IP_NF_PPTP is not set | ||
277 | CONFIG_IP_NF_QUEUE=m | 438 | CONFIG_IP_NF_QUEUE=m |
278 | CONFIG_IP_NF_IPTABLES=m | 439 | CONFIG_IP_NF_IPTABLES=m |
279 | CONFIG_IP_NF_MATCH_LIMIT=m | 440 | CONFIG_IP_NF_MATCH_ADDRTYPE=m |
280 | CONFIG_IP_NF_MATCH_IPRANGE=m | 441 | # CONFIG_IP_NF_MATCH_AH is not set |
281 | CONFIG_IP_NF_MATCH_MAC=m | ||
282 | CONFIG_IP_NF_MATCH_PKTTYPE=m | ||
283 | CONFIG_IP_NF_MATCH_MARK=m | ||
284 | CONFIG_IP_NF_MATCH_MULTIPORT=m | ||
285 | CONFIG_IP_NF_MATCH_TOS=m | ||
286 | CONFIG_IP_NF_MATCH_RECENT=m | ||
287 | CONFIG_IP_NF_MATCH_ECN=m | 442 | CONFIG_IP_NF_MATCH_ECN=m |
288 | CONFIG_IP_NF_MATCH_DSCP=m | ||
289 | CONFIG_IP_NF_MATCH_AH_ESP=m | ||
290 | CONFIG_IP_NF_MATCH_LENGTH=m | ||
291 | CONFIG_IP_NF_MATCH_TTL=m | 443 | CONFIG_IP_NF_MATCH_TTL=m |
292 | CONFIG_IP_NF_MATCH_TCPMSS=m | ||
293 | CONFIG_IP_NF_MATCH_HELPER=m | ||
294 | CONFIG_IP_NF_MATCH_STATE=m | ||
295 | CONFIG_IP_NF_MATCH_CONNTRACK=m | ||
296 | CONFIG_IP_NF_MATCH_OWNER=m | ||
297 | CONFIG_IP_NF_MATCH_ADDRTYPE=m | ||
298 | CONFIG_IP_NF_MATCH_REALM=m | ||
299 | CONFIG_IP_NF_MATCH_SCTP=m | ||
300 | # CONFIG_IP_NF_MATCH_DCCP is not set | ||
301 | CONFIG_IP_NF_MATCH_COMMENT=m | ||
302 | CONFIG_IP_NF_MATCH_HASHLIMIT=m | ||
303 | # CONFIG_IP_NF_MATCH_STRING is not set | ||
304 | CONFIG_IP_NF_FILTER=m | 444 | CONFIG_IP_NF_FILTER=m |
305 | # CONFIG_IP_NF_TARGET_REJECT is not set | 445 | # CONFIG_IP_NF_TARGET_REJECT is not set |
306 | CONFIG_IP_NF_TARGET_LOG=m | 446 | CONFIG_IP_NF_TARGET_LOG=m |
307 | CONFIG_IP_NF_TARGET_ULOG=m | 447 | CONFIG_IP_NF_TARGET_ULOG=m |
308 | CONFIG_IP_NF_TARGET_TCPMSS=m | ||
309 | # CONFIG_IP_NF_TARGET_NFQUEUE is not set | ||
310 | CONFIG_IP_NF_NAT=m | ||
311 | CONFIG_IP_NF_NAT_NEEDED=y | ||
312 | # CONFIG_IP_NF_TARGET_MASQUERADE is not set | ||
313 | # CONFIG_IP_NF_TARGET_REDIRECT is not set | ||
314 | # CONFIG_IP_NF_TARGET_NETMAP is not set | ||
315 | # CONFIG_IP_NF_TARGET_SAME is not set | ||
316 | # CONFIG_IP_NF_NAT_SNMP_BASIC is not set | ||
317 | CONFIG_IP_NF_NAT_IRC=m | ||
318 | CONFIG_IP_NF_NAT_FTP=m | ||
319 | CONFIG_IP_NF_NAT_TFTP=m | ||
320 | CONFIG_IP_NF_NAT_AMANDA=m | ||
321 | CONFIG_IP_NF_MANGLE=m | 448 | CONFIG_IP_NF_MANGLE=m |
322 | # CONFIG_IP_NF_TARGET_TOS is not set | ||
323 | # CONFIG_IP_NF_TARGET_ECN is not set | 449 | # CONFIG_IP_NF_TARGET_ECN is not set |
324 | # CONFIG_IP_NF_TARGET_DSCP is not set | ||
325 | # CONFIG_IP_NF_TARGET_MARK is not set | ||
326 | # CONFIG_IP_NF_TARGET_CLASSIFY is not set | ||
327 | # CONFIG_IP_NF_TARGET_TTL is not set | 450 | # CONFIG_IP_NF_TARGET_TTL is not set |
328 | CONFIG_IP_NF_RAW=m | 451 | CONFIG_IP_NF_RAW=m |
329 | # CONFIG_IP_NF_TARGET_NOTRACK is not set | ||
330 | CONFIG_IP_NF_ARPTABLES=m | 452 | CONFIG_IP_NF_ARPTABLES=m |
331 | CONFIG_IP_NF_ARPFILTER=m | 453 | CONFIG_IP_NF_ARPFILTER=m |
332 | CONFIG_IP_NF_ARP_MANGLE=m | 454 | CONFIG_IP_NF_ARP_MANGLE=m |
333 | 455 | ||
334 | # | 456 | # |
335 | # IPv6: Netfilter Configuration (EXPERIMENTAL) | 457 | # IPv6: Netfilter Configuration |
336 | # | 458 | # |
337 | CONFIG_IP6_NF_QUEUE=m | 459 | CONFIG_IP6_NF_QUEUE=m |
338 | CONFIG_IP6_NF_IPTABLES=m | 460 | CONFIG_IP6_NF_IPTABLES=m |
339 | CONFIG_IP6_NF_MATCH_LIMIT=m | 461 | # CONFIG_IP6_NF_MATCH_AH is not set |
340 | CONFIG_IP6_NF_MATCH_MAC=m | 462 | CONFIG_IP6_NF_MATCH_EUI64=m |
341 | CONFIG_IP6_NF_MATCH_RT=m | ||
342 | CONFIG_IP6_NF_MATCH_OPTS=m | ||
343 | CONFIG_IP6_NF_MATCH_FRAG=m | 463 | CONFIG_IP6_NF_MATCH_FRAG=m |
464 | CONFIG_IP6_NF_MATCH_OPTS=m | ||
344 | CONFIG_IP6_NF_MATCH_HL=m | 465 | CONFIG_IP6_NF_MATCH_HL=m |
345 | CONFIG_IP6_NF_MATCH_MULTIPORT=m | ||
346 | CONFIG_IP6_NF_MATCH_OWNER=m | ||
347 | CONFIG_IP6_NF_MATCH_MARK=m | ||
348 | CONFIG_IP6_NF_MATCH_IPV6HEADER=m | 466 | CONFIG_IP6_NF_MATCH_IPV6HEADER=m |
349 | CONFIG_IP6_NF_MATCH_AHESP=m | 467 | # CONFIG_IP6_NF_MATCH_MH is not set |
350 | CONFIG_IP6_NF_MATCH_LENGTH=m | 468 | CONFIG_IP6_NF_MATCH_RT=m |
351 | CONFIG_IP6_NF_MATCH_EUI64=m | ||
352 | CONFIG_IP6_NF_FILTER=m | ||
353 | # CONFIG_IP6_NF_TARGET_LOG is not set | 469 | # CONFIG_IP6_NF_TARGET_LOG is not set |
470 | CONFIG_IP6_NF_FILTER=m | ||
354 | # CONFIG_IP6_NF_TARGET_REJECT is not set | 471 | # CONFIG_IP6_NF_TARGET_REJECT is not set |
355 | # CONFIG_IP6_NF_TARGET_NFQUEUE is not set | ||
356 | CONFIG_IP6_NF_MANGLE=m | 472 | CONFIG_IP6_NF_MANGLE=m |
357 | # CONFIG_IP6_NF_TARGET_MARK is not set | ||
358 | # CONFIG_IP6_NF_TARGET_HL is not set | 473 | # CONFIG_IP6_NF_TARGET_HL is not set |
359 | CONFIG_IP6_NF_RAW=m | 474 | CONFIG_IP6_NF_RAW=m |
360 | |||
361 | # | ||
362 | # DCCP Configuration (EXPERIMENTAL) | ||
363 | # | ||
364 | # CONFIG_IP_DCCP is not set | 475 | # CONFIG_IP_DCCP is not set |
365 | |||
366 | # | ||
367 | # SCTP Configuration (EXPERIMENTAL) | ||
368 | # | ||
369 | # CONFIG_IP_SCTP is not set | 476 | # CONFIG_IP_SCTP is not set |
477 | # CONFIG_TIPC is not set | ||
370 | # CONFIG_ATM is not set | 478 | # CONFIG_ATM is not set |
371 | # CONFIG_BRIDGE is not set | 479 | # CONFIG_BRIDGE is not set |
480 | # CONFIG_NET_DSA is not set | ||
372 | # CONFIG_VLAN_8021Q is not set | 481 | # CONFIG_VLAN_8021Q is not set |
373 | # CONFIG_DECNET is not set | 482 | # CONFIG_DECNET is not set |
374 | # CONFIG_LLC2 is not set | 483 | # CONFIG_LLC2 is not set |
@@ -376,21 +485,16 @@ CONFIG_IP6_NF_RAW=m | |||
376 | # CONFIG_ATALK is not set | 485 | # CONFIG_ATALK is not set |
377 | # CONFIG_X25 is not set | 486 | # CONFIG_X25 is not set |
378 | # CONFIG_LAPB is not set | 487 | # CONFIG_LAPB is not set |
379 | # CONFIG_NET_DIVERT is not set | ||
380 | # CONFIG_ECONET is not set | 488 | # CONFIG_ECONET is not set |
381 | # CONFIG_WAN_ROUTER is not set | 489 | # CONFIG_WAN_ROUTER is not set |
382 | |||
383 | # | ||
384 | # QoS and/or fair queueing | ||
385 | # | ||
386 | # CONFIG_NET_SCHED is not set | 490 | # CONFIG_NET_SCHED is not set |
387 | CONFIG_NET_CLS_ROUTE=y | ||
388 | 491 | ||
389 | # | 492 | # |
390 | # Network testing | 493 | # Network testing |
391 | # | 494 | # |
392 | # CONFIG_NET_PKTGEN is not set | 495 | # CONFIG_NET_PKTGEN is not set |
393 | # CONFIG_HAMRADIO is not set | 496 | # CONFIG_HAMRADIO is not set |
497 | # CONFIG_CAN is not set | ||
394 | CONFIG_IRDA=m | 498 | CONFIG_IRDA=m |
395 | 499 | ||
396 | # | 500 | # |
@@ -420,27 +524,17 @@ CONFIG_IRCOMM=m | |||
420 | # | 524 | # |
421 | # Dongle support | 525 | # Dongle support |
422 | # | 526 | # |
423 | 527 | # CONFIG_KINGSUN_DONGLE is not set | |
424 | # | 528 | # CONFIG_KSDAZZLE_DONGLE is not set |
425 | # Old SIR device drivers | 529 | # CONFIG_KS959_DONGLE is not set |
426 | # | ||
427 | # CONFIG_IRPORT_SIR is not set | ||
428 | |||
429 | # | ||
430 | # Old Serial dongle support | ||
431 | # | ||
432 | 530 | ||
433 | # | 531 | # |
434 | # FIR device drivers | 532 | # FIR device drivers |
435 | # | 533 | # |
436 | # CONFIG_USB_IRDA is not set | 534 | # CONFIG_USB_IRDA is not set |
437 | # CONFIG_SIGMATEL_FIR is not set | 535 | # CONFIG_SIGMATEL_FIR is not set |
438 | # CONFIG_NSC_FIR is not set | ||
439 | # CONFIG_WINBOND_FIR is not set | ||
440 | # CONFIG_SMC_IRCC_FIR is not set | ||
441 | # CONFIG_ALI_FIR is not set | ||
442 | # CONFIG_VIA_FIR is not set | ||
443 | CONFIG_PXA_FICP=m | 536 | CONFIG_PXA_FICP=m |
537 | # CONFIG_MCS_FIR is not set | ||
444 | CONFIG_BT=m | 538 | CONFIG_BT=m |
445 | CONFIG_BT_L2CAP=m | 539 | CONFIG_BT_L2CAP=m |
446 | CONFIG_BT_SCO=m | 540 | CONFIG_BT_SCO=m |
@@ -456,9 +550,12 @@ CONFIG_BT_HIDP=m | |||
456 | # | 550 | # |
457 | CONFIG_BT_HCIUSB=m | 551 | CONFIG_BT_HCIUSB=m |
458 | # CONFIG_BT_HCIUSB_SCO is not set | 552 | # CONFIG_BT_HCIUSB_SCO is not set |
553 | # CONFIG_BT_HCIBTUSB is not set | ||
554 | # CONFIG_BT_HCIBTSDIO is not set | ||
459 | CONFIG_BT_HCIUART=m | 555 | CONFIG_BT_HCIUART=m |
460 | CONFIG_BT_HCIUART_H4=y | 556 | CONFIG_BT_HCIUART_H4=y |
461 | CONFIG_BT_HCIUART_BCSP=y | 557 | CONFIG_BT_HCIUART_BCSP=y |
558 | # CONFIG_BT_HCIUART_LL is not set | ||
462 | CONFIG_BT_HCIBCM203X=m | 559 | CONFIG_BT_HCIBCM203X=m |
463 | CONFIG_BT_HCIBPA10X=m | 560 | CONFIG_BT_HCIBPA10X=m |
464 | CONFIG_BT_HCIBFUSB=m | 561 | CONFIG_BT_HCIBFUSB=m |
@@ -467,11 +564,20 @@ CONFIG_BT_HCIBT3C=m | |||
467 | CONFIG_BT_HCIBLUECARD=m | 564 | CONFIG_BT_HCIBLUECARD=m |
468 | CONFIG_BT_HCIBTUART=m | 565 | CONFIG_BT_HCIBTUART=m |
469 | CONFIG_BT_HCIVHCI=m | 566 | CONFIG_BT_HCIVHCI=m |
567 | # CONFIG_AF_RXRPC is not set | ||
568 | # CONFIG_PHONET is not set | ||
569 | CONFIG_WIRELESS=y | ||
570 | # CONFIG_CFG80211 is not set | ||
571 | # CONFIG_WIRELESS_OLD_REGULATORY is not set | ||
572 | # CONFIG_WIRELESS_EXT is not set | ||
573 | # CONFIG_MAC80211 is not set | ||
470 | CONFIG_IEEE80211=m | 574 | CONFIG_IEEE80211=m |
471 | # CONFIG_IEEE80211_DEBUG is not set | 575 | # CONFIG_IEEE80211_DEBUG is not set |
472 | CONFIG_IEEE80211_CRYPT_WEP=m | 576 | CONFIG_IEEE80211_CRYPT_WEP=m |
473 | # CONFIG_IEEE80211_CRYPT_CCMP is not set | 577 | # CONFIG_IEEE80211_CRYPT_CCMP is not set |
474 | # CONFIG_IEEE80211_CRYPT_TKIP is not set | 578 | # CONFIG_IEEE80211_CRYPT_TKIP is not set |
579 | # CONFIG_RFKILL is not set | ||
580 | # CONFIG_NET_9P is not set | ||
475 | 581 | ||
476 | # | 582 | # |
477 | # Device Drivers | 583 | # Device Drivers |
@@ -480,19 +586,16 @@ CONFIG_IEEE80211_CRYPT_WEP=m | |||
480 | # | 586 | # |
481 | # Generic Driver Options | 587 | # Generic Driver Options |
482 | # | 588 | # |
589 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | ||
483 | CONFIG_STANDALONE=y | 590 | CONFIG_STANDALONE=y |
484 | CONFIG_PREVENT_FIRMWARE_BUILD=y | 591 | CONFIG_PREVENT_FIRMWARE_BUILD=y |
485 | CONFIG_FW_LOADER=y | 592 | CONFIG_FW_LOADER=y |
593 | CONFIG_FIRMWARE_IN_KERNEL=y | ||
594 | CONFIG_EXTRA_FIRMWARE="" | ||
486 | # CONFIG_DEBUG_DRIVER is not set | 595 | # CONFIG_DEBUG_DRIVER is not set |
487 | 596 | # CONFIG_DEBUG_DEVRES is not set | |
488 | # | 597 | # CONFIG_SYS_HYPERVISOR is not set |
489 | # Connector - unified userspace <-> kernelspace linker | ||
490 | # | ||
491 | # CONFIG_CONNECTOR is not set | 598 | # CONFIG_CONNECTOR is not set |
492 | |||
493 | # | ||
494 | # Memory Technology Devices (MTD) | ||
495 | # | ||
496 | CONFIG_MTD=y | 599 | CONFIG_MTD=y |
497 | # CONFIG_MTD_DEBUG is not set | 600 | # CONFIG_MTD_DEBUG is not set |
498 | # CONFIG_MTD_CONCAT is not set | 601 | # CONFIG_MTD_CONCAT is not set |
@@ -500,16 +603,20 @@ CONFIG_MTD_PARTITIONS=y | |||
500 | # CONFIG_MTD_REDBOOT_PARTS is not set | 603 | # CONFIG_MTD_REDBOOT_PARTS is not set |
501 | CONFIG_MTD_CMDLINE_PARTS=y | 604 | CONFIG_MTD_CMDLINE_PARTS=y |
502 | # CONFIG_MTD_AFS_PARTS is not set | 605 | # CONFIG_MTD_AFS_PARTS is not set |
606 | # CONFIG_MTD_AR7_PARTS is not set | ||
503 | 607 | ||
504 | # | 608 | # |
505 | # User Modules And Translation Layers | 609 | # User Modules And Translation Layers |
506 | # | 610 | # |
507 | CONFIG_MTD_CHAR=y | 611 | CONFIG_MTD_CHAR=y |
612 | CONFIG_MTD_BLKDEVS=y | ||
508 | CONFIG_MTD_BLOCK=y | 613 | CONFIG_MTD_BLOCK=y |
509 | # CONFIG_FTL is not set | 614 | # CONFIG_FTL is not set |
510 | # CONFIG_NFTL is not set | 615 | # CONFIG_NFTL is not set |
511 | # CONFIG_INFTL is not set | 616 | # CONFIG_INFTL is not set |
512 | # CONFIG_RFD_FTL is not set | 617 | # CONFIG_RFD_FTL is not set |
618 | # CONFIG_SSFDC is not set | ||
619 | # CONFIG_MTD_OOPS is not set | ||
513 | 620 | ||
514 | # | 621 | # |
515 | # RAM/ROM/Flash chip drivers | 622 | # RAM/ROM/Flash chip drivers |
@@ -534,16 +641,18 @@ CONFIG_MTD_ROM=y | |||
534 | # Mapping drivers for chip access | 641 | # Mapping drivers for chip access |
535 | # | 642 | # |
536 | CONFIG_MTD_COMPLEX_MAPPINGS=y | 643 | CONFIG_MTD_COMPLEX_MAPPINGS=y |
644 | # CONFIG_MTD_PHYSMAP is not set | ||
537 | CONFIG_MTD_SHARP_SL=y | 645 | CONFIG_MTD_SHARP_SL=y |
538 | # CONFIG_MTD_PLATRAM is not set | 646 | # CONFIG_MTD_PLATRAM is not set |
539 | 647 | ||
540 | # | 648 | # |
541 | # Self-contained MTD device drivers | 649 | # Self-contained MTD device drivers |
542 | # | 650 | # |
651 | # CONFIG_MTD_DATAFLASH is not set | ||
652 | # CONFIG_MTD_M25P80 is not set | ||
543 | # CONFIG_MTD_SLRAM is not set | 653 | # CONFIG_MTD_SLRAM is not set |
544 | # CONFIG_MTD_PHRAM is not set | 654 | # CONFIG_MTD_PHRAM is not set |
545 | # CONFIG_MTD_MTDRAM is not set | 655 | # CONFIG_MTD_MTDRAM is not set |
546 | # CONFIG_MTD_BLKMTD is not set | ||
547 | # CONFIG_MTD_BLOCK2MTD is not set | 656 | # CONFIG_MTD_BLOCK2MTD is not set |
548 | 657 | ||
549 | # | 658 | # |
@@ -552,78 +661,66 @@ CONFIG_MTD_SHARP_SL=y | |||
552 | # CONFIG_MTD_DOC2000 is not set | 661 | # CONFIG_MTD_DOC2000 is not set |
553 | # CONFIG_MTD_DOC2001 is not set | 662 | # CONFIG_MTD_DOC2001 is not set |
554 | # CONFIG_MTD_DOC2001PLUS is not set | 663 | # CONFIG_MTD_DOC2001PLUS is not set |
555 | |||
556 | # | ||
557 | # NAND Flash Device Drivers | ||
558 | # | ||
559 | CONFIG_MTD_NAND=y | 664 | CONFIG_MTD_NAND=y |
560 | CONFIG_MTD_NAND_VERIFY_WRITE=y | 665 | CONFIG_MTD_NAND_VERIFY_WRITE=y |
666 | # CONFIG_MTD_NAND_ECC_SMC is not set | ||
667 | # CONFIG_MTD_NAND_MUSEUM_IDS is not set | ||
561 | # CONFIG_MTD_NAND_H1900 is not set | 668 | # CONFIG_MTD_NAND_H1900 is not set |
562 | CONFIG_MTD_NAND_IDS=y | 669 | CONFIG_MTD_NAND_IDS=y |
563 | # CONFIG_MTD_NAND_DISKONCHIP is not set | 670 | # CONFIG_MTD_NAND_DISKONCHIP is not set |
564 | CONFIG_MTD_NAND_SHARPSL=y | 671 | CONFIG_MTD_NAND_SHARPSL=y |
565 | # CONFIG_MTD_NAND_NANDSIM is not set | 672 | # CONFIG_MTD_NAND_NANDSIM is not set |
566 | 673 | # CONFIG_MTD_NAND_PLATFORM is not set | |
567 | # | 674 | # CONFIG_MTD_ALAUDA is not set |
568 | # OneNAND Flash Device Drivers | ||
569 | # | ||
570 | # CONFIG_MTD_ONENAND is not set | 675 | # CONFIG_MTD_ONENAND is not set |
571 | 676 | ||
572 | # | 677 | # |
573 | # Parallel port support | 678 | # UBI - Unsorted block images |
574 | # | 679 | # |
680 | # CONFIG_MTD_UBI is not set | ||
575 | # CONFIG_PARPORT is not set | 681 | # CONFIG_PARPORT is not set |
576 | 682 | CONFIG_BLK_DEV=y | |
577 | # | ||
578 | # Plug and Play support | ||
579 | # | ||
580 | |||
581 | # | ||
582 | # Block devices | ||
583 | # | ||
584 | # CONFIG_BLK_DEV_COW_COMMON is not set | 683 | # CONFIG_BLK_DEV_COW_COMMON is not set |
585 | CONFIG_BLK_DEV_LOOP=y | 684 | CONFIG_BLK_DEV_LOOP=y |
586 | # CONFIG_BLK_DEV_CRYPTOLOOP is not set | 685 | # CONFIG_BLK_DEV_CRYPTOLOOP is not set |
587 | # CONFIG_BLK_DEV_NBD is not set | 686 | # CONFIG_BLK_DEV_NBD is not set |
588 | # CONFIG_BLK_DEV_UB is not set | 687 | # CONFIG_BLK_DEV_UB is not set |
589 | # CONFIG_BLK_DEV_RAM is not set | 688 | # CONFIG_BLK_DEV_RAM is not set |
590 | CONFIG_BLK_DEV_RAM_COUNT=16 | ||
591 | # CONFIG_CDROM_PKTCDVD is not set | 689 | # CONFIG_CDROM_PKTCDVD is not set |
592 | # CONFIG_ATA_OVER_ETH is not set | 690 | # CONFIG_ATA_OVER_ETH is not set |
593 | 691 | CONFIG_MISC_DEVICES=y | |
594 | # | 692 | # CONFIG_EEPROM_93CX6 is not set |
595 | # ATA/ATAPI/MFM/RLL support | 693 | # CONFIG_ENCLOSURE_SERVICES is not set |
596 | # | 694 | CONFIG_HAVE_IDE=y |
597 | CONFIG_IDE=y | 695 | CONFIG_IDE=y |
598 | CONFIG_BLK_DEV_IDE=y | ||
599 | 696 | ||
600 | # | 697 | # |
601 | # Please see Documentation/ide.txt for help/info on IDE drives | 698 | # Please see Documentation/ide/ide.txt for help/info on IDE drives |
602 | # | 699 | # |
603 | # CONFIG_BLK_DEV_IDE_SATA is not set | 700 | # CONFIG_BLK_DEV_IDE_SATA is not set |
604 | CONFIG_BLK_DEV_IDEDISK=y | 701 | CONFIG_BLK_DEV_IDEDISK=y |
605 | # CONFIG_IDEDISK_MULTI_MODE is not set | ||
606 | CONFIG_BLK_DEV_IDECS=y | 702 | CONFIG_BLK_DEV_IDECS=y |
607 | # CONFIG_BLK_DEV_IDECD is not set | 703 | # CONFIG_BLK_DEV_IDECD is not set |
608 | # CONFIG_BLK_DEV_IDETAPE is not set | 704 | # CONFIG_BLK_DEV_IDETAPE is not set |
609 | # CONFIG_BLK_DEV_IDEFLOPPY is not set | 705 | # CONFIG_BLK_DEV_IDEFLOPPY is not set |
610 | # CONFIG_BLK_DEV_IDESCSI is not set | 706 | # CONFIG_BLK_DEV_IDESCSI is not set |
611 | # CONFIG_IDE_TASK_IOCTL is not set | 707 | # CONFIG_IDE_TASK_IOCTL is not set |
708 | CONFIG_IDE_PROC_FS=y | ||
612 | 709 | ||
613 | # | 710 | # |
614 | # IDE chipset support/bugfixes | 711 | # IDE chipset support/bugfixes |
615 | # | 712 | # |
616 | CONFIG_IDE_GENERIC=y | 713 | # CONFIG_BLK_DEV_PLATFORM is not set |
617 | # CONFIG_IDE_ARM is not set | ||
618 | # CONFIG_BLK_DEV_IDEDMA is not set | 714 | # CONFIG_BLK_DEV_IDEDMA is not set |
619 | # CONFIG_IDEDMA_AUTO is not set | ||
620 | # CONFIG_BLK_DEV_HD is not set | ||
621 | 715 | ||
622 | # | 716 | # |
623 | # SCSI device support | 717 | # SCSI device support |
624 | # | 718 | # |
625 | # CONFIG_RAID_ATTRS is not set | 719 | # CONFIG_RAID_ATTRS is not set |
626 | CONFIG_SCSI=m | 720 | CONFIG_SCSI=m |
721 | CONFIG_SCSI_DMA=y | ||
722 | # CONFIG_SCSI_TGT is not set | ||
723 | # CONFIG_SCSI_NETLINK is not set | ||
627 | CONFIG_SCSI_PROC_FS=y | 724 | CONFIG_SCSI_PROC_FS=y |
628 | 725 | ||
629 | # | 726 | # |
@@ -643,121 +740,76 @@ CONFIG_CHR_DEV_SG=m | |||
643 | CONFIG_SCSI_MULTI_LUN=y | 740 | CONFIG_SCSI_MULTI_LUN=y |
644 | # CONFIG_SCSI_CONSTANTS is not set | 741 | # CONFIG_SCSI_CONSTANTS is not set |
645 | # CONFIG_SCSI_LOGGING is not set | 742 | # CONFIG_SCSI_LOGGING is not set |
743 | # CONFIG_SCSI_SCAN_ASYNC is not set | ||
744 | CONFIG_SCSI_WAIT_SCAN=m | ||
646 | 745 | ||
647 | # | 746 | # |
648 | # SCSI Transport Attributes | 747 | # SCSI Transports |
649 | # | 748 | # |
650 | # CONFIG_SCSI_SPI_ATTRS is not set | 749 | # CONFIG_SCSI_SPI_ATTRS is not set |
651 | # CONFIG_SCSI_FC_ATTRS is not set | 750 | # CONFIG_SCSI_FC_ATTRS is not set |
652 | # CONFIG_SCSI_ISCSI_ATTRS is not set | 751 | # CONFIG_SCSI_ISCSI_ATTRS is not set |
653 | # CONFIG_SCSI_SAS_ATTRS is not set | 752 | # CONFIG_SCSI_SAS_LIBSAS is not set |
654 | 753 | # CONFIG_SCSI_SRP_ATTRS is not set | |
655 | # | 754 | CONFIG_SCSI_LOWLEVEL=y |
656 | # SCSI low-level drivers | ||
657 | # | ||
658 | # CONFIG_ISCSI_TCP is not set | 755 | # CONFIG_ISCSI_TCP is not set |
659 | # CONFIG_SCSI_SATA is not set | ||
660 | # CONFIG_SCSI_DEBUG is not set | 756 | # CONFIG_SCSI_DEBUG is not set |
661 | 757 | # CONFIG_SCSI_LOWLEVEL_PCMCIA is not set | |
662 | # | 758 | # CONFIG_SCSI_DH is not set |
663 | # PCMCIA SCSI adapter support | 759 | # CONFIG_ATA is not set |
664 | # | ||
665 | # CONFIG_PCMCIA_AHA152X is not set | ||
666 | # CONFIG_PCMCIA_FDOMAIN is not set | ||
667 | # CONFIG_PCMCIA_NINJA_SCSI is not set | ||
668 | # CONFIG_PCMCIA_QLOGIC is not set | ||
669 | # CONFIG_PCMCIA_SYM53C500 is not set | ||
670 | |||
671 | # | ||
672 | # Multi-device support (RAID and LVM) | ||
673 | # | ||
674 | # CONFIG_MD is not set | 760 | # CONFIG_MD is not set |
675 | |||
676 | # | ||
677 | # Fusion MPT device support | ||
678 | # | ||
679 | # CONFIG_FUSION is not set | ||
680 | |||
681 | # | ||
682 | # IEEE 1394 (FireWire) support | ||
683 | # | ||
684 | |||
685 | # | ||
686 | # I2O device support | ||
687 | # | ||
688 | |||
689 | # | ||
690 | # Network device support | ||
691 | # | ||
692 | CONFIG_NETDEVICES=y | 761 | CONFIG_NETDEVICES=y |
693 | # CONFIG_DUMMY is not set | 762 | # CONFIG_DUMMY is not set |
694 | # CONFIG_BONDING is not set | 763 | # CONFIG_BONDING is not set |
764 | # CONFIG_MACVLAN is not set | ||
695 | # CONFIG_EQUALIZER is not set | 765 | # CONFIG_EQUALIZER is not set |
696 | # CONFIG_TUN is not set | 766 | # CONFIG_TUN is not set |
697 | 767 | # CONFIG_VETH is not set | |
698 | # | ||
699 | # PHY device support | ||
700 | # | ||
701 | # CONFIG_PHYLIB is not set | 768 | # CONFIG_PHYLIB is not set |
702 | |||
703 | # | ||
704 | # Ethernet (10 or 100Mbit) | ||
705 | # | ||
706 | CONFIG_NET_ETHERNET=y | 769 | CONFIG_NET_ETHERNET=y |
707 | CONFIG_MII=m | 770 | CONFIG_MII=m |
771 | # CONFIG_AX88796 is not set | ||
708 | # CONFIG_SMC91X is not set | 772 | # CONFIG_SMC91X is not set |
709 | # CONFIG_DM9000 is not set | 773 | # CONFIG_DM9000 is not set |
774 | # CONFIG_ENC28J60 is not set | ||
775 | # CONFIG_SMC911X is not set | ||
776 | # CONFIG_IBM_NEW_EMAC_ZMII is not set | ||
777 | # CONFIG_IBM_NEW_EMAC_RGMII is not set | ||
778 | # CONFIG_IBM_NEW_EMAC_TAH is not set | ||
779 | # CONFIG_IBM_NEW_EMAC_EMAC4 is not set | ||
780 | # CONFIG_IBM_NEW_EMAC_NO_FLOW_CTRL is not set | ||
781 | # CONFIG_IBM_NEW_EMAC_MAL_CLR_ICINTSTAT is not set | ||
782 | # CONFIG_IBM_NEW_EMAC_MAL_COMMON_ERR is not set | ||
783 | # CONFIG_B44 is not set | ||
784 | CONFIG_NETDEV_1000=y | ||
785 | CONFIG_NETDEV_10000=y | ||
710 | 786 | ||
711 | # | 787 | # |
712 | # Ethernet (1000 Mbit) | 788 | # Wireless LAN |
713 | # | ||
714 | |||
715 | # | ||
716 | # Ethernet (10000 Mbit) | ||
717 | # | ||
718 | |||
719 | # | ||
720 | # Token Ring devices | ||
721 | # | 789 | # |
790 | # CONFIG_WLAN_PRE80211 is not set | ||
791 | # CONFIG_WLAN_80211 is not set | ||
792 | # CONFIG_IWLWIFI_LEDS is not set | ||
722 | 793 | ||
723 | # | 794 | # |
724 | # Wireless LAN (non-hamradio) | 795 | # USB Network Adapters |
725 | # | ||
726 | CONFIG_NET_RADIO=y | ||
727 | |||
728 | # | ||
729 | # Obsolete Wireless cards support (pre-802.11) | ||
730 | # | ||
731 | # CONFIG_STRIP is not set | ||
732 | # CONFIG_PCMCIA_WAVELAN is not set | ||
733 | # CONFIG_PCMCIA_NETWAVE is not set | ||
734 | |||
735 | # | ||
736 | # Wireless 802.11 Frequency Hopping cards support | ||
737 | # | ||
738 | # CONFIG_PCMCIA_RAYCS is not set | ||
739 | |||
740 | # | ||
741 | # Wireless 802.11b ISA/PCI cards support | ||
742 | # | ||
743 | CONFIG_HERMES=m | ||
744 | # CONFIG_ATMEL is not set | ||
745 | |||
746 | # | ||
747 | # Wireless 802.11b Pcmcia/Cardbus cards support | ||
748 | # | ||
749 | CONFIG_PCMCIA_HERMES=m | ||
750 | CONFIG_PCMCIA_SPECTRUM=m | ||
751 | # CONFIG_AIRO_CS is not set | ||
752 | # CONFIG_PCMCIA_WL3501 is not set | ||
753 | CONFIG_HOSTAP=m | ||
754 | CONFIG_HOSTAP_FIRMWARE=y | ||
755 | CONFIG_HOSTAP_CS=m | ||
756 | CONFIG_NET_WIRELESS=y | ||
757 | |||
758 | # | ||
759 | # PCMCIA network device support | ||
760 | # | 796 | # |
797 | CONFIG_USB_CATC=m | ||
798 | CONFIG_USB_KAWETH=m | ||
799 | CONFIG_USB_PEGASUS=m | ||
800 | CONFIG_USB_RTL8150=m | ||
801 | CONFIG_USB_USBNET=m | ||
802 | CONFIG_USB_NET_AX8817X=m | ||
803 | CONFIG_USB_NET_CDCETHER=m | ||
804 | # CONFIG_USB_NET_DM9601 is not set | ||
805 | # CONFIG_USB_NET_SMSC95XX is not set | ||
806 | # CONFIG_USB_NET_GL620A is not set | ||
807 | CONFIG_USB_NET_NET1080=m | ||
808 | # CONFIG_USB_NET_PLUSB is not set | ||
809 | # CONFIG_USB_NET_MCS7830 is not set | ||
810 | # CONFIG_USB_NET_RNDIS_HOST is not set | ||
811 | # CONFIG_USB_NET_CDC_SUBSET is not set | ||
812 | CONFIG_USB_NET_ZAURUS=m | ||
761 | CONFIG_NET_PCMCIA=y | 813 | CONFIG_NET_PCMCIA=y |
762 | # CONFIG_PCMCIA_3C589 is not set | 814 | # CONFIG_PCMCIA_3C589 is not set |
763 | # CONFIG_PCMCIA_3C574 is not set | 815 | # CONFIG_PCMCIA_3C574 is not set |
@@ -767,10 +819,6 @@ CONFIG_PCMCIA_PCNET=m | |||
767 | # CONFIG_PCMCIA_SMC91C92 is not set | 819 | # CONFIG_PCMCIA_SMC91C92 is not set |
768 | # CONFIG_PCMCIA_XIRC2PS is not set | 820 | # CONFIG_PCMCIA_XIRC2PS is not set |
769 | # CONFIG_PCMCIA_AXNET is not set | 821 | # CONFIG_PCMCIA_AXNET is not set |
770 | |||
771 | # | ||
772 | # Wan interfaces | ||
773 | # | ||
774 | # CONFIG_WAN is not set | 822 | # CONFIG_WAN is not set |
775 | CONFIG_PPP=m | 823 | CONFIG_PPP=m |
776 | # CONFIG_PPP_MULTILINK is not set | 824 | # CONFIG_PPP_MULTILINK is not set |
@@ -781,31 +829,29 @@ CONFIG_PPP_ASYNC=m | |||
781 | CONFIG_PPP_BSDCOMP=m | 829 | CONFIG_PPP_BSDCOMP=m |
782 | # CONFIG_PPP_MPPE is not set | 830 | # CONFIG_PPP_MPPE is not set |
783 | # CONFIG_PPPOE is not set | 831 | # CONFIG_PPPOE is not set |
832 | # CONFIG_PPPOL2TP is not set | ||
784 | # CONFIG_SLIP is not set | 833 | # CONFIG_SLIP is not set |
785 | # CONFIG_SHAPER is not set | 834 | CONFIG_SLHC=m |
786 | # CONFIG_NETCONSOLE is not set | 835 | # CONFIG_NETCONSOLE is not set |
787 | # CONFIG_NETPOLL is not set | 836 | # CONFIG_NETPOLL is not set |
788 | # CONFIG_NET_POLL_CONTROLLER is not set | 837 | # CONFIG_NET_POLL_CONTROLLER is not set |
789 | |||
790 | # | ||
791 | # ISDN subsystem | ||
792 | # | ||
793 | # CONFIG_ISDN is not set | 838 | # CONFIG_ISDN is not set |
794 | 839 | ||
795 | # | 840 | # |
796 | # Input device support | 841 | # Input device support |
797 | # | 842 | # |
798 | CONFIG_INPUT=y | 843 | CONFIG_INPUT=y |
844 | CONFIG_INPUT_FF_MEMLESS=m | ||
845 | # CONFIG_INPUT_POLLDEV is not set | ||
799 | 846 | ||
800 | # | 847 | # |
801 | # Userland interfaces | 848 | # Userland interfaces |
802 | # | 849 | # |
803 | # CONFIG_INPUT_MOUSEDEV is not set | 850 | # CONFIG_INPUT_MOUSEDEV is not set |
804 | # CONFIG_INPUT_JOYDEV is not set | 851 | # CONFIG_INPUT_JOYDEV is not set |
805 | # CONFIG_INPUT_TSDEV is not set | ||
806 | CONFIG_INPUT_EVDEV=y | 852 | CONFIG_INPUT_EVDEV=y |
807 | # CONFIG_INPUT_EVBUG is not set | 853 | # CONFIG_INPUT_EVBUG is not set |
808 | # CONFIG_INPUT_POWER is not set | 854 | # CONFIG_INPUT_APMPOWER is not set |
809 | 855 | ||
810 | # | 856 | # |
811 | # Input Device Drivers | 857 | # Input Device Drivers |
@@ -816,17 +862,35 @@ CONFIG_INPUT_KEYBOARD=y | |||
816 | # CONFIG_KEYBOARD_LKKBD is not set | 862 | # CONFIG_KEYBOARD_LKKBD is not set |
817 | # CONFIG_KEYBOARD_XTKBD is not set | 863 | # CONFIG_KEYBOARD_XTKBD is not set |
818 | # CONFIG_KEYBOARD_NEWTON is not set | 864 | # CONFIG_KEYBOARD_NEWTON is not set |
865 | # CONFIG_KEYBOARD_STOWAWAY is not set | ||
819 | # CONFIG_KEYBOARD_CORGI is not set | 866 | # CONFIG_KEYBOARD_CORGI is not set |
820 | CONFIG_KEYBOARD_SPITZ=y | 867 | CONFIG_KEYBOARD_SPITZ=y |
868 | # CONFIG_KEYBOARD_PXA27x is not set | ||
869 | # CONFIG_KEYBOARD_GPIO is not set | ||
821 | # CONFIG_INPUT_MOUSE is not set | 870 | # CONFIG_INPUT_MOUSE is not set |
822 | # CONFIG_INPUT_JOYSTICK is not set | 871 | # CONFIG_INPUT_JOYSTICK is not set |
872 | # CONFIG_INPUT_TABLET is not set | ||
823 | CONFIG_INPUT_TOUCHSCREEN=y | 873 | CONFIG_INPUT_TOUCHSCREEN=y |
824 | CONFIG_TOUCHSCREEN_CORGI=y | 874 | CONFIG_TOUCHSCREEN_ADS7846=y |
875 | # CONFIG_TOUCHSCREEN_CORGI is not set | ||
876 | # CONFIG_TOUCHSCREEN_FUJITSU is not set | ||
825 | # CONFIG_TOUCHSCREEN_GUNZE is not set | 877 | # CONFIG_TOUCHSCREEN_GUNZE is not set |
826 | # CONFIG_TOUCHSCREEN_ELO is not set | 878 | # CONFIG_TOUCHSCREEN_ELO is not set |
827 | # CONFIG_TOUCHSCREEN_MTOUCH is not set | 879 | # CONFIG_TOUCHSCREEN_MTOUCH is not set |
880 | # CONFIG_TOUCHSCREEN_INEXIO is not set | ||
828 | # CONFIG_TOUCHSCREEN_MK712 is not set | 881 | # CONFIG_TOUCHSCREEN_MK712 is not set |
882 | # CONFIG_TOUCHSCREEN_PENMOUNT is not set | ||
883 | # CONFIG_TOUCHSCREEN_TOUCHRIGHT is not set | ||
884 | # CONFIG_TOUCHSCREEN_TOUCHWIN is not set | ||
885 | # CONFIG_TOUCHSCREEN_USB_COMPOSITE is not set | ||
886 | # CONFIG_TOUCHSCREEN_TOUCHIT213 is not set | ||
829 | CONFIG_INPUT_MISC=y | 887 | CONFIG_INPUT_MISC=y |
888 | # CONFIG_INPUT_ATI_REMOTE is not set | ||
889 | # CONFIG_INPUT_ATI_REMOTE2 is not set | ||
890 | # CONFIG_INPUT_KEYSPAN_REMOTE is not set | ||
891 | # CONFIG_INPUT_POWERMATE is not set | ||
892 | # CONFIG_INPUT_YEALINK is not set | ||
893 | # CONFIG_INPUT_CM109 is not set | ||
830 | CONFIG_INPUT_UINPUT=m | 894 | CONFIG_INPUT_UINPUT=m |
831 | 895 | ||
832 | # | 896 | # |
@@ -839,8 +903,11 @@ CONFIG_INPUT_UINPUT=m | |||
839 | # Character devices | 903 | # Character devices |
840 | # | 904 | # |
841 | CONFIG_VT=y | 905 | CONFIG_VT=y |
906 | CONFIG_CONSOLE_TRANSLATIONS=y | ||
842 | CONFIG_VT_CONSOLE=y | 907 | CONFIG_VT_CONSOLE=y |
843 | CONFIG_HW_CONSOLE=y | 908 | CONFIG_HW_CONSOLE=y |
909 | # CONFIG_VT_HW_CONSOLE_BINDING is not set | ||
910 | CONFIG_DEVKMEM=y | ||
844 | # CONFIG_SERIAL_NONSTANDARD is not set | 911 | # CONFIG_SERIAL_NONSTANDARD is not set |
845 | 912 | ||
846 | # | 913 | # |
@@ -849,6 +916,7 @@ CONFIG_HW_CONSOLE=y | |||
849 | CONFIG_SERIAL_8250=m | 916 | CONFIG_SERIAL_8250=m |
850 | CONFIG_SERIAL_8250_CS=m | 917 | CONFIG_SERIAL_8250_CS=m |
851 | CONFIG_SERIAL_8250_NR_UARTS=4 | 918 | CONFIG_SERIAL_8250_NR_UARTS=4 |
919 | CONFIG_SERIAL_8250_RUNTIME_UARTS=4 | ||
852 | # CONFIG_SERIAL_8250_EXTENDED is not set | 920 | # CONFIG_SERIAL_8250_EXTENDED is not set |
853 | 921 | ||
854 | # | 922 | # |
@@ -860,101 +928,253 @@ CONFIG_SERIAL_CORE=y | |||
860 | CONFIG_SERIAL_CORE_CONSOLE=y | 928 | CONFIG_SERIAL_CORE_CONSOLE=y |
861 | CONFIG_UNIX98_PTYS=y | 929 | CONFIG_UNIX98_PTYS=y |
862 | # CONFIG_LEGACY_PTYS is not set | 930 | # CONFIG_LEGACY_PTYS is not set |
863 | |||
864 | # | ||
865 | # IPMI | ||
866 | # | ||
867 | # CONFIG_IPMI_HANDLER is not set | 931 | # CONFIG_IPMI_HANDLER is not set |
868 | 932 | CONFIG_HW_RANDOM=m | |
869 | # | ||
870 | # Watchdog Cards | ||
871 | # | ||
872 | # CONFIG_WATCHDOG is not set | ||
873 | # CONFIG_NVRAM is not set | 933 | # CONFIG_NVRAM is not set |
874 | # CONFIG_RTC is not set | ||
875 | # CONFIG_DTLK is not set | ||
876 | # CONFIG_R3964 is not set | 934 | # CONFIG_R3964 is not set |
877 | 935 | ||
878 | # | 936 | # |
879 | # Ftape, the floppy tape device driver | ||
880 | # | ||
881 | |||
882 | # | ||
883 | # PCMCIA character devices | 937 | # PCMCIA character devices |
884 | # | 938 | # |
885 | # CONFIG_SYNCLINK_CS is not set | 939 | # CONFIG_SYNCLINK_CS is not set |
886 | # CONFIG_CARDMAN_4000 is not set | 940 | # CONFIG_CARDMAN_4000 is not set |
887 | # CONFIG_CARDMAN_4040 is not set | 941 | # CONFIG_CARDMAN_4040 is not set |
942 | # CONFIG_IPWIRELESS is not set | ||
888 | # CONFIG_RAW_DRIVER is not set | 943 | # CONFIG_RAW_DRIVER is not set |
889 | |||
890 | # | ||
891 | # TPM devices | ||
892 | # | ||
893 | # CONFIG_TCG_TPM is not set | 944 | # CONFIG_TCG_TPM is not set |
894 | # CONFIG_TELCLOCK is not set | ||
895 | |||
896 | # | ||
897 | # I2C support | ||
898 | # | ||
899 | CONFIG_I2C=y | 945 | CONFIG_I2C=y |
946 | CONFIG_I2C_BOARDINFO=y | ||
900 | # CONFIG_I2C_CHARDEV is not set | 947 | # CONFIG_I2C_CHARDEV is not set |
948 | CONFIG_I2C_HELPER_AUTO=y | ||
901 | 949 | ||
902 | # | 950 | # |
903 | # I2C Algorithms | 951 | # I2C Hardware Bus support |
904 | # | 952 | # |
905 | # CONFIG_I2C_ALGOBIT is not set | ||
906 | # CONFIG_I2C_ALGOPCF is not set | ||
907 | # CONFIG_I2C_ALGOPCA is not set | ||
908 | 953 | ||
909 | # | 954 | # |
910 | # I2C Hardware Bus support | 955 | # I2C system bus drivers (mostly embedded / system-on-chip) |
911 | # | 956 | # |
957 | # CONFIG_I2C_GPIO is not set | ||
958 | # CONFIG_I2C_OCORES is not set | ||
912 | CONFIG_I2C_PXA=y | 959 | CONFIG_I2C_PXA=y |
913 | # CONFIG_I2C_PXA_SLAVE is not set | 960 | # CONFIG_I2C_PXA_SLAVE is not set |
961 | # CONFIG_I2C_SIMTEC is not set | ||
962 | |||
963 | # | ||
964 | # External I2C/SMBus adapter drivers | ||
965 | # | ||
914 | # CONFIG_I2C_PARPORT_LIGHT is not set | 966 | # CONFIG_I2C_PARPORT_LIGHT is not set |
967 | # CONFIG_I2C_TAOS_EVM is not set | ||
968 | # CONFIG_I2C_TINY_USB is not set | ||
969 | |||
970 | # | ||
971 | # Other I2C/SMBus bus drivers | ||
972 | # | ||
973 | # CONFIG_I2C_PCA_PLATFORM is not set | ||
915 | # CONFIG_I2C_STUB is not set | 974 | # CONFIG_I2C_STUB is not set |
916 | # CONFIG_I2C_PCA_ISA is not set | ||
917 | 975 | ||
918 | # | 976 | # |
919 | # Hardware Monitoring support | 977 | # Miscellaneous I2C Chip support |
978 | # | ||
979 | # CONFIG_DS1682 is not set | ||
980 | # CONFIG_AT24 is not set | ||
981 | # CONFIG_SENSORS_EEPROM is not set | ||
982 | # CONFIG_SENSORS_PCF8574 is not set | ||
983 | # CONFIG_PCF8575 is not set | ||
984 | # CONFIG_SENSORS_PCA9539 is not set | ||
985 | # CONFIG_SENSORS_PCF8591 is not set | ||
986 | # CONFIG_TPS65010 is not set | ||
987 | # CONFIG_SENSORS_MAX6875 is not set | ||
988 | # CONFIG_SENSORS_TSL2550 is not set | ||
989 | # CONFIG_I2C_DEBUG_CORE is not set | ||
990 | # CONFIG_I2C_DEBUG_ALGO is not set | ||
991 | # CONFIG_I2C_DEBUG_BUS is not set | ||
992 | # CONFIG_I2C_DEBUG_CHIP is not set | ||
993 | CONFIG_SPI=y | ||
994 | # CONFIG_SPI_DEBUG is not set | ||
995 | CONFIG_SPI_MASTER=y | ||
996 | |||
997 | # | ||
998 | # SPI Master Controller Drivers | ||
999 | # | ||
1000 | # CONFIG_SPI_BITBANG is not set | ||
1001 | CONFIG_SPI_PXA2XX=y | ||
1002 | |||
1003 | # | ||
1004 | # SPI Protocol Masters | ||
1005 | # | ||
1006 | # CONFIG_SPI_AT25 is not set | ||
1007 | # CONFIG_SPI_SPIDEV is not set | ||
1008 | # CONFIG_SPI_TLE62X0 is not set | ||
1009 | CONFIG_ARCH_REQUIRE_GPIOLIB=y | ||
1010 | CONFIG_GPIOLIB=y | ||
1011 | # CONFIG_DEBUG_GPIO is not set | ||
1012 | # CONFIG_GPIO_SYSFS is not set | ||
1013 | |||
1014 | # | ||
1015 | # I2C GPIO expanders: | ||
1016 | # | ||
1017 | # CONFIG_GPIO_MAX732X is not set | ||
1018 | # CONFIG_GPIO_PCA953X is not set | ||
1019 | # CONFIG_GPIO_PCF857X is not set | ||
1020 | |||
1021 | # | ||
1022 | # PCI GPIO expanders: | ||
1023 | # | ||
1024 | |||
1025 | # | ||
1026 | # SPI GPIO expanders: | ||
920 | # | 1027 | # |
1028 | # CONFIG_GPIO_MAX7301 is not set | ||
1029 | # CONFIG_GPIO_MCP23S08 is not set | ||
1030 | # CONFIG_W1 is not set | ||
1031 | # CONFIG_POWER_SUPPLY is not set | ||
921 | CONFIG_HWMON=y | 1032 | CONFIG_HWMON=y |
922 | # CONFIG_HWMON_VID is not set | 1033 | # CONFIG_HWMON_VID is not set |
1034 | # CONFIG_SENSORS_AD7414 is not set | ||
1035 | # CONFIG_SENSORS_AD7418 is not set | ||
1036 | # CONFIG_SENSORS_ADCXX is not set | ||
1037 | # CONFIG_SENSORS_ADM1021 is not set | ||
1038 | # CONFIG_SENSORS_ADM1025 is not set | ||
1039 | # CONFIG_SENSORS_ADM1026 is not set | ||
1040 | # CONFIG_SENSORS_ADM1029 is not set | ||
1041 | # CONFIG_SENSORS_ADM1031 is not set | ||
1042 | # CONFIG_SENSORS_ADM9240 is not set | ||
1043 | # CONFIG_SENSORS_ADT7470 is not set | ||
1044 | # CONFIG_SENSORS_ADT7473 is not set | ||
1045 | # CONFIG_SENSORS_ATXP1 is not set | ||
1046 | # CONFIG_SENSORS_DS1621 is not set | ||
1047 | # CONFIG_SENSORS_F71805F is not set | ||
1048 | # CONFIG_SENSORS_F71882FG is not set | ||
1049 | # CONFIG_SENSORS_F75375S is not set | ||
1050 | # CONFIG_SENSORS_GL518SM is not set | ||
1051 | # CONFIG_SENSORS_GL520SM is not set | ||
1052 | # CONFIG_SENSORS_IT87 is not set | ||
1053 | # CONFIG_SENSORS_LM63 is not set | ||
1054 | # CONFIG_SENSORS_LM70 is not set | ||
1055 | # CONFIG_SENSORS_LM75 is not set | ||
1056 | # CONFIG_SENSORS_LM77 is not set | ||
1057 | # CONFIG_SENSORS_LM78 is not set | ||
1058 | # CONFIG_SENSORS_LM80 is not set | ||
1059 | # CONFIG_SENSORS_LM83 is not set | ||
1060 | # CONFIG_SENSORS_LM85 is not set | ||
1061 | # CONFIG_SENSORS_LM87 is not set | ||
1062 | # CONFIG_SENSORS_LM90 is not set | ||
1063 | # CONFIG_SENSORS_LM92 is not set | ||
1064 | # CONFIG_SENSORS_LM93 is not set | ||
1065 | CONFIG_SENSORS_MAX1111=y | ||
1066 | # CONFIG_SENSORS_MAX1619 is not set | ||
1067 | # CONFIG_SENSORS_MAX6650 is not set | ||
1068 | # CONFIG_SENSORS_PC87360 is not set | ||
1069 | # CONFIG_SENSORS_PC87427 is not set | ||
1070 | # CONFIG_SENSORS_DME1737 is not set | ||
1071 | # CONFIG_SENSORS_SMSC47M1 is not set | ||
1072 | # CONFIG_SENSORS_SMSC47M192 is not set | ||
1073 | # CONFIG_SENSORS_SMSC47B397 is not set | ||
1074 | # CONFIG_SENSORS_ADS7828 is not set | ||
1075 | # CONFIG_SENSORS_THMC50 is not set | ||
1076 | # CONFIG_SENSORS_VT1211 is not set | ||
1077 | # CONFIG_SENSORS_W83781D is not set | ||
1078 | # CONFIG_SENSORS_W83791D is not set | ||
1079 | # CONFIG_SENSORS_W83792D is not set | ||
1080 | # CONFIG_SENSORS_W83793 is not set | ||
1081 | # CONFIG_SENSORS_W83L785TS is not set | ||
1082 | # CONFIG_SENSORS_W83L786NG is not set | ||
1083 | # CONFIG_SENSORS_W83627HF is not set | ||
1084 | # CONFIG_SENSORS_W83627EHF is not set | ||
923 | # CONFIG_HWMON_DEBUG_CHIP is not set | 1085 | # CONFIG_HWMON_DEBUG_CHIP is not set |
1086 | # CONFIG_THERMAL is not set | ||
1087 | # CONFIG_THERMAL_HWMON is not set | ||
1088 | # CONFIG_WATCHDOG is not set | ||
924 | 1089 | ||
925 | # | 1090 | # |
926 | # Misc devices | 1091 | # Sonics Silicon Backplane |
927 | # | 1092 | # |
1093 | CONFIG_SSB_POSSIBLE=y | ||
1094 | # CONFIG_SSB is not set | ||
928 | 1095 | ||
929 | # | 1096 | # |
930 | # Multimedia Capabilities Port drivers | 1097 | # Multifunction device drivers |
931 | # | 1098 | # |
1099 | # CONFIG_MFD_CORE is not set | ||
1100 | # CONFIG_MFD_SM501 is not set | ||
1101 | # CONFIG_MFD_ASIC3 is not set | ||
1102 | # CONFIG_HTC_EGPIO is not set | ||
1103 | # CONFIG_HTC_PASIC3 is not set | ||
1104 | # CONFIG_UCB1400_CORE is not set | ||
1105 | # CONFIG_MFD_TMIO is not set | ||
1106 | # CONFIG_MFD_T7L66XB is not set | ||
1107 | # CONFIG_MFD_TC6387XB is not set | ||
1108 | # CONFIG_MFD_TC6393XB is not set | ||
1109 | # CONFIG_MFD_WM8400 is not set | ||
1110 | # CONFIG_MFD_WM8350_I2C is not set | ||
932 | 1111 | ||
933 | # | 1112 | # |
934 | # Multimedia devices | 1113 | # Multimedia devices |
935 | # | 1114 | # |
1115 | |||
1116 | # | ||
1117 | # Multimedia core support | ||
1118 | # | ||
936 | # CONFIG_VIDEO_DEV is not set | 1119 | # CONFIG_VIDEO_DEV is not set |
1120 | # CONFIG_DVB_CORE is not set | ||
1121 | # CONFIG_VIDEO_MEDIA is not set | ||
937 | 1122 | ||
938 | # | 1123 | # |
939 | # Digital Video Broadcasting Devices | 1124 | # Multimedia drivers |
940 | # | 1125 | # |
941 | # CONFIG_DVB is not set | 1126 | # CONFIG_DAB is not set |
942 | 1127 | ||
943 | # | 1128 | # |
944 | # Graphics support | 1129 | # Graphics support |
945 | # | 1130 | # |
1131 | # CONFIG_VGASTATE is not set | ||
1132 | # CONFIG_VIDEO_OUTPUT_CONTROL is not set | ||
946 | CONFIG_FB=y | 1133 | CONFIG_FB=y |
1134 | # CONFIG_FIRMWARE_EDID is not set | ||
1135 | # CONFIG_FB_DDC is not set | ||
1136 | # CONFIG_FB_BOOT_VESA_SUPPORT is not set | ||
947 | CONFIG_FB_CFB_FILLRECT=y | 1137 | CONFIG_FB_CFB_FILLRECT=y |
948 | CONFIG_FB_CFB_COPYAREA=y | 1138 | CONFIG_FB_CFB_COPYAREA=y |
949 | CONFIG_FB_CFB_IMAGEBLIT=y | 1139 | CONFIG_FB_CFB_IMAGEBLIT=y |
1140 | # CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set | ||
1141 | # CONFIG_FB_SYS_FILLRECT is not set | ||
1142 | # CONFIG_FB_SYS_COPYAREA is not set | ||
1143 | # CONFIG_FB_SYS_IMAGEBLIT is not set | ||
1144 | # CONFIG_FB_FOREIGN_ENDIAN is not set | ||
1145 | # CONFIG_FB_SYS_FOPS is not set | ||
1146 | # CONFIG_FB_SVGALIB is not set | ||
950 | # CONFIG_FB_MACMODES is not set | 1147 | # CONFIG_FB_MACMODES is not set |
1148 | # CONFIG_FB_BACKLIGHT is not set | ||
951 | # CONFIG_FB_MODE_HELPERS is not set | 1149 | # CONFIG_FB_MODE_HELPERS is not set |
952 | # CONFIG_FB_TILEBLITTING is not set | 1150 | # CONFIG_FB_TILEBLITTING is not set |
1151 | |||
1152 | # | ||
1153 | # Frame buffer hardware drivers | ||
1154 | # | ||
953 | # CONFIG_FB_S1D13XXX is not set | 1155 | # CONFIG_FB_S1D13XXX is not set |
954 | CONFIG_FB_PXA=y | 1156 | CONFIG_FB_PXA=y |
1157 | # CONFIG_FB_PXA_SMARTPANEL is not set | ||
955 | # CONFIG_FB_PXA_PARAMETERS is not set | 1158 | # CONFIG_FB_PXA_PARAMETERS is not set |
1159 | # CONFIG_FB_MBX is not set | ||
956 | # CONFIG_FB_W100 is not set | 1160 | # CONFIG_FB_W100 is not set |
957 | # CONFIG_FB_VIRTUAL is not set | 1161 | # CONFIG_FB_VIRTUAL is not set |
1162 | # CONFIG_FB_METRONOME is not set | ||
1163 | CONFIG_BACKLIGHT_LCD_SUPPORT=y | ||
1164 | CONFIG_LCD_CLASS_DEVICE=y | ||
1165 | CONFIG_LCD_CORGI=y | ||
1166 | # CONFIG_LCD_LTV350QV is not set | ||
1167 | # CONFIG_LCD_ILI9320 is not set | ||
1168 | # CONFIG_LCD_TDO24M is not set | ||
1169 | # CONFIG_LCD_VGG2432A4 is not set | ||
1170 | # CONFIG_LCD_PLATFORM is not set | ||
1171 | CONFIG_BACKLIGHT_CLASS_DEVICE=y | ||
1172 | # CONFIG_BACKLIGHT_CORGI is not set | ||
1173 | |||
1174 | # | ||
1175 | # Display device support | ||
1176 | # | ||
1177 | # CONFIG_DISPLAY_SUPPORT is not set | ||
958 | 1178 | ||
959 | # | 1179 | # |
960 | # Console display driver support | 1180 | # Console display driver support |
@@ -962,6 +1182,7 @@ CONFIG_FB_PXA=y | |||
962 | # CONFIG_VGA_CONSOLE is not set | 1182 | # CONFIG_VGA_CONSOLE is not set |
963 | CONFIG_DUMMY_CONSOLE=y | 1183 | CONFIG_DUMMY_CONSOLE=y |
964 | CONFIG_FRAMEBUFFER_CONSOLE=y | 1184 | CONFIG_FRAMEBUFFER_CONSOLE=y |
1185 | # CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY is not set | ||
965 | CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=y | 1186 | CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=y |
966 | CONFIG_FONTS=y | 1187 | CONFIG_FONTS=y |
967 | CONFIG_FONT_8x8=y | 1188 | CONFIG_FONT_8x8=y |
@@ -974,55 +1195,96 @@ CONFIG_FONT_8x16=y | |||
974 | # CONFIG_FONT_SUN8x16 is not set | 1195 | # CONFIG_FONT_SUN8x16 is not set |
975 | # CONFIG_FONT_SUN12x22 is not set | 1196 | # CONFIG_FONT_SUN12x22 is not set |
976 | # CONFIG_FONT_10x18 is not set | 1197 | # CONFIG_FONT_10x18 is not set |
1198 | # CONFIG_LOGO is not set | ||
1199 | # CONFIG_SOUND is not set | ||
1200 | CONFIG_HID_SUPPORT=y | ||
1201 | CONFIG_HID=y | ||
1202 | # CONFIG_HID_DEBUG is not set | ||
1203 | # CONFIG_HIDRAW is not set | ||
977 | 1204 | ||
978 | # | 1205 | # |
979 | # Logo configuration | 1206 | # USB Input Devices |
980 | # | 1207 | # |
981 | # CONFIG_LOGO is not set | 1208 | CONFIG_USB_HID=m |
982 | CONFIG_BACKLIGHT_LCD_SUPPORT=y | 1209 | # CONFIG_HID_PID is not set |
983 | CONFIG_BACKLIGHT_CLASS_DEVICE=y | 1210 | # CONFIG_USB_HIDDEV is not set |
984 | CONFIG_BACKLIGHT_DEVICE=y | ||
985 | CONFIG_LCD_CLASS_DEVICE=y | ||
986 | CONFIG_LCD_DEVICE=y | ||
987 | CONFIG_BACKLIGHT_CORGI=y | ||
988 | 1211 | ||
989 | # | 1212 | # |
990 | # Sound | 1213 | # USB HID Boot Protocol drivers |
991 | # | 1214 | # |
992 | # CONFIG_SOUND is not set | 1215 | CONFIG_USB_KBD=m |
1216 | CONFIG_USB_MOUSE=m | ||
993 | 1217 | ||
994 | # | 1218 | # |
995 | # USB support | 1219 | # Special HID drivers |
996 | # | 1220 | # |
1221 | CONFIG_HID_COMPAT=y | ||
1222 | CONFIG_HID_A4TECH=m | ||
1223 | CONFIG_HID_APPLE=m | ||
1224 | CONFIG_HID_BELKIN=m | ||
1225 | CONFIG_HID_BRIGHT=m | ||
1226 | CONFIG_HID_CHERRY=m | ||
1227 | CONFIG_HID_CHICONY=m | ||
1228 | CONFIG_HID_CYPRESS=m | ||
1229 | CONFIG_HID_DELL=m | ||
1230 | CONFIG_HID_EZKEY=m | ||
1231 | CONFIG_HID_GYRATION=m | ||
1232 | CONFIG_HID_LOGITECH=m | ||
1233 | # CONFIG_LOGITECH_FF is not set | ||
1234 | # CONFIG_LOGIRUMBLEPAD2_FF is not set | ||
1235 | CONFIG_HID_MICROSOFT=m | ||
1236 | CONFIG_HID_MONTEREY=m | ||
1237 | CONFIG_HID_PANTHERLORD=m | ||
1238 | # CONFIG_PANTHERLORD_FF is not set | ||
1239 | CONFIG_HID_PETALYNX=m | ||
1240 | CONFIG_HID_SAMSUNG=m | ||
1241 | CONFIG_HID_SONY=m | ||
1242 | CONFIG_HID_SUNPLUS=m | ||
1243 | CONFIG_THRUSTMASTER_FF=m | ||
1244 | CONFIG_ZEROPLUS_FF=m | ||
1245 | CONFIG_USB_SUPPORT=y | ||
997 | CONFIG_USB_ARCH_HAS_HCD=y | 1246 | CONFIG_USB_ARCH_HAS_HCD=y |
998 | CONFIG_USB_ARCH_HAS_OHCI=y | 1247 | CONFIG_USB_ARCH_HAS_OHCI=y |
1248 | # CONFIG_USB_ARCH_HAS_EHCI is not set | ||
999 | CONFIG_USB=m | 1249 | CONFIG_USB=m |
1000 | # CONFIG_USB_DEBUG is not set | 1250 | # CONFIG_USB_DEBUG is not set |
1251 | # CONFIG_USB_ANNOUNCE_NEW_DEVICES is not set | ||
1001 | 1252 | ||
1002 | # | 1253 | # |
1003 | # Miscellaneous USB options | 1254 | # Miscellaneous USB options |
1004 | # | 1255 | # |
1005 | CONFIG_USB_DEVICEFS=y | 1256 | CONFIG_USB_DEVICEFS=y |
1006 | # CONFIG_USB_BANDWIDTH is not set | 1257 | CONFIG_USB_DEVICE_CLASS=y |
1007 | # CONFIG_USB_DYNAMIC_MINORS is not set | 1258 | # CONFIG_USB_DYNAMIC_MINORS is not set |
1008 | # CONFIG_USB_SUSPEND is not set | 1259 | # CONFIG_USB_SUSPEND is not set |
1009 | # CONFIG_USB_OTG is not set | 1260 | # CONFIG_USB_OTG is not set |
1261 | # CONFIG_USB_OTG_WHITELIST is not set | ||
1262 | # CONFIG_USB_OTG_BLACKLIST_HUB is not set | ||
1263 | CONFIG_USB_MON=y | ||
1010 | 1264 | ||
1011 | # | 1265 | # |
1012 | # USB Host Controller Drivers | 1266 | # USB Host Controller Drivers |
1013 | # | 1267 | # |
1268 | # CONFIG_USB_C67X00_HCD is not set | ||
1014 | # CONFIG_USB_ISP116X_HCD is not set | 1269 | # CONFIG_USB_ISP116X_HCD is not set |
1270 | # CONFIG_USB_ISP1760_HCD is not set | ||
1015 | CONFIG_USB_OHCI_HCD=m | 1271 | CONFIG_USB_OHCI_HCD=m |
1016 | # CONFIG_USB_OHCI_BIG_ENDIAN is not set | 1272 | # CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set |
1273 | # CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set | ||
1017 | CONFIG_USB_OHCI_LITTLE_ENDIAN=y | 1274 | CONFIG_USB_OHCI_LITTLE_ENDIAN=y |
1018 | CONFIG_USB_SL811_HCD=m | 1275 | CONFIG_USB_SL811_HCD=m |
1019 | CONFIG_USB_SL811_CS=m | 1276 | CONFIG_USB_SL811_CS=m |
1277 | # CONFIG_USB_R8A66597_HCD is not set | ||
1278 | # CONFIG_USB_MUSB_HDRC is not set | ||
1279 | # CONFIG_USB_GADGET_MUSB_HDRC is not set | ||
1020 | 1280 | ||
1021 | # | 1281 | # |
1022 | # USB Device Class drivers | 1282 | # USB Device Class drivers |
1023 | # | 1283 | # |
1024 | CONFIG_USB_ACM=m | 1284 | CONFIG_USB_ACM=m |
1025 | CONFIG_USB_PRINTER=m | 1285 | CONFIG_USB_PRINTER=m |
1286 | # CONFIG_USB_WDM is not set | ||
1287 | # CONFIG_USB_TMC is not set | ||
1026 | 1288 | ||
1027 | # | 1289 | # |
1028 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' | 1290 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' |
@@ -1041,33 +1303,11 @@ CONFIG_USB_STORAGE=m | |||
1041 | # CONFIG_USB_STORAGE_SDDR09 is not set | 1303 | # CONFIG_USB_STORAGE_SDDR09 is not set |
1042 | # CONFIG_USB_STORAGE_SDDR55 is not set | 1304 | # CONFIG_USB_STORAGE_SDDR55 is not set |
1043 | # CONFIG_USB_STORAGE_JUMPSHOT is not set | 1305 | # CONFIG_USB_STORAGE_JUMPSHOT is not set |
1044 | 1306 | # CONFIG_USB_STORAGE_ALAUDA is not set | |
1045 | # | 1307 | # CONFIG_USB_STORAGE_ONETOUCH is not set |
1046 | # USB Input Devices | 1308 | # CONFIG_USB_STORAGE_KARMA is not set |
1047 | # | 1309 | # CONFIG_USB_STORAGE_CYPRESS_ATACB is not set |
1048 | CONFIG_USB_HID=m | 1310 | # CONFIG_USB_LIBUSUAL is not set |
1049 | CONFIG_USB_HIDINPUT=y | ||
1050 | # CONFIG_HID_FF is not set | ||
1051 | # CONFIG_USB_HIDDEV is not set | ||
1052 | |||
1053 | # | ||
1054 | # USB HID Boot Protocol drivers | ||
1055 | # | ||
1056 | CONFIG_USB_KBD=m | ||
1057 | CONFIG_USB_MOUSE=m | ||
1058 | CONFIG_USB_AIPTEK=m | ||
1059 | CONFIG_USB_WACOM=m | ||
1060 | # CONFIG_USB_ACECAD is not set | ||
1061 | CONFIG_USB_KBTAB=m | ||
1062 | CONFIG_USB_POWERMATE=m | ||
1063 | CONFIG_USB_MTOUCH=m | ||
1064 | # CONFIG_USB_ITMTOUCH is not set | ||
1065 | CONFIG_USB_EGALAX=m | ||
1066 | # CONFIG_USB_YEALINK is not set | ||
1067 | CONFIG_USB_XPAD=m | ||
1068 | CONFIG_USB_ATI_REMOTE=m | ||
1069 | # CONFIG_USB_KEYSPAN_REMOTE is not set | ||
1070 | # CONFIG_USB_APPLETOUCH is not set | ||
1071 | 1311 | ||
1072 | # | 1312 | # |
1073 | # USB Imaging devices | 1313 | # USB Imaging devices |
@@ -1076,51 +1316,22 @@ CONFIG_USB_MDC800=m | |||
1076 | CONFIG_USB_MICROTEK=m | 1316 | CONFIG_USB_MICROTEK=m |
1077 | 1317 | ||
1078 | # | 1318 | # |
1079 | # USB Multimedia devices | ||
1080 | # | ||
1081 | CONFIG_USB_DABUSB=m | ||
1082 | |||
1083 | # | ||
1084 | # Video4Linux support is needed for USB Multimedia device support | ||
1085 | # | ||
1086 | |||
1087 | # | ||
1088 | # USB Network Adapters | ||
1089 | # | ||
1090 | CONFIG_USB_CATC=m | ||
1091 | CONFIG_USB_KAWETH=m | ||
1092 | CONFIG_USB_PEGASUS=m | ||
1093 | CONFIG_USB_RTL8150=m | ||
1094 | CONFIG_USB_USBNET=m | ||
1095 | CONFIG_USB_NET_AX8817X=m | ||
1096 | CONFIG_USB_NET_CDCETHER=m | ||
1097 | # CONFIG_USB_NET_GL620A is not set | ||
1098 | CONFIG_USB_NET_NET1080=m | ||
1099 | # CONFIG_USB_NET_PLUSB is not set | ||
1100 | # CONFIG_USB_NET_RNDIS_HOST is not set | ||
1101 | # CONFIG_USB_NET_CDC_SUBSET is not set | ||
1102 | CONFIG_USB_NET_ZAURUS=m | ||
1103 | # CONFIG_USB_ZD1201 is not set | ||
1104 | CONFIG_USB_MON=y | ||
1105 | |||
1106 | # | ||
1107 | # USB port drivers | 1319 | # USB port drivers |
1108 | # | 1320 | # |
1109 | |||
1110 | # | ||
1111 | # USB Serial Converter support | ||
1112 | # | ||
1113 | CONFIG_USB_SERIAL=m | 1321 | CONFIG_USB_SERIAL=m |
1322 | CONFIG_USB_EZUSB=y | ||
1114 | CONFIG_USB_SERIAL_GENERIC=y | 1323 | CONFIG_USB_SERIAL_GENERIC=y |
1115 | # CONFIG_USB_SERIAL_AIRPRIME is not set | 1324 | # CONFIG_USB_SERIAL_AIRCABLE is not set |
1116 | # CONFIG_USB_SERIAL_ANYDATA is not set | 1325 | # CONFIG_USB_SERIAL_ARK3116 is not set |
1117 | CONFIG_USB_SERIAL_BELKIN=m | 1326 | CONFIG_USB_SERIAL_BELKIN=m |
1327 | # CONFIG_USB_SERIAL_CH341 is not set | ||
1118 | # CONFIG_USB_SERIAL_WHITEHEAT is not set | 1328 | # CONFIG_USB_SERIAL_WHITEHEAT is not set |
1119 | CONFIG_USB_SERIAL_DIGI_ACCELEPORT=m | 1329 | CONFIG_USB_SERIAL_DIGI_ACCELEPORT=m |
1120 | # CONFIG_USB_SERIAL_CP2101 is not set | 1330 | # CONFIG_USB_SERIAL_CP2101 is not set |
1121 | CONFIG_USB_SERIAL_CYPRESS_M8=m | 1331 | CONFIG_USB_SERIAL_CYPRESS_M8=m |
1122 | CONFIG_USB_SERIAL_EMPEG=m | 1332 | CONFIG_USB_SERIAL_EMPEG=m |
1123 | CONFIG_USB_SERIAL_FTDI_SIO=m | 1333 | CONFIG_USB_SERIAL_FTDI_SIO=m |
1334 | # CONFIG_USB_SERIAL_FUNSOFT is not set | ||
1124 | CONFIG_USB_SERIAL_VISOR=m | 1335 | CONFIG_USB_SERIAL_VISOR=m |
1125 | CONFIG_USB_SERIAL_IPAQ=m | 1336 | CONFIG_USB_SERIAL_IPAQ=m |
1126 | CONFIG_USB_SERIAL_IR=m | 1337 | CONFIG_USB_SERIAL_IR=m |
@@ -1128,6 +1339,7 @@ CONFIG_USB_SERIAL_EDGEPORT=m | |||
1128 | CONFIG_USB_SERIAL_EDGEPORT_TI=m | 1339 | CONFIG_USB_SERIAL_EDGEPORT_TI=m |
1129 | CONFIG_USB_SERIAL_GARMIN=m | 1340 | CONFIG_USB_SERIAL_GARMIN=m |
1130 | CONFIG_USB_SERIAL_IPW=m | 1341 | CONFIG_USB_SERIAL_IPW=m |
1342 | # CONFIG_USB_SERIAL_IUU is not set | ||
1131 | CONFIG_USB_SERIAL_KEYSPAN_PDA=m | 1343 | CONFIG_USB_SERIAL_KEYSPAN_PDA=m |
1132 | CONFIG_USB_SERIAL_KEYSPAN=m | 1344 | CONFIG_USB_SERIAL_KEYSPAN=m |
1133 | # CONFIG_USB_SERIAL_KEYSPAN_MPR is not set | 1345 | # CONFIG_USB_SERIAL_KEYSPAN_MPR is not set |
@@ -1145,49 +1357,66 @@ CONFIG_USB_SERIAL_KEYSPAN=m | |||
1145 | CONFIG_USB_SERIAL_KLSI=m | 1357 | CONFIG_USB_SERIAL_KLSI=m |
1146 | CONFIG_USB_SERIAL_KOBIL_SCT=m | 1358 | CONFIG_USB_SERIAL_KOBIL_SCT=m |
1147 | CONFIG_USB_SERIAL_MCT_U232=m | 1359 | CONFIG_USB_SERIAL_MCT_U232=m |
1360 | # CONFIG_USB_SERIAL_MOS7720 is not set | ||
1361 | # CONFIG_USB_SERIAL_MOS7840 is not set | ||
1362 | # CONFIG_USB_SERIAL_MOTOROLA is not set | ||
1363 | # CONFIG_USB_SERIAL_NAVMAN is not set | ||
1148 | CONFIG_USB_SERIAL_PL2303=m | 1364 | CONFIG_USB_SERIAL_PL2303=m |
1365 | # CONFIG_USB_SERIAL_OTI6858 is not set | ||
1366 | # CONFIG_USB_SERIAL_SPCP8X5 is not set | ||
1149 | # CONFIG_USB_SERIAL_HP4X is not set | 1367 | # CONFIG_USB_SERIAL_HP4X is not set |
1150 | CONFIG_USB_SERIAL_SAFE=m | 1368 | CONFIG_USB_SERIAL_SAFE=m |
1151 | # CONFIG_USB_SERIAL_SAFE_PADDED is not set | 1369 | # CONFIG_USB_SERIAL_SAFE_PADDED is not set |
1370 | # CONFIG_USB_SERIAL_SIERRAWIRELESS is not set | ||
1152 | CONFIG_USB_SERIAL_TI=m | 1371 | CONFIG_USB_SERIAL_TI=m |
1153 | CONFIG_USB_SERIAL_CYBERJACK=m | 1372 | CONFIG_USB_SERIAL_CYBERJACK=m |
1154 | CONFIG_USB_SERIAL_XIRCOM=m | 1373 | CONFIG_USB_SERIAL_XIRCOM=m |
1155 | # CONFIG_USB_SERIAL_OPTION is not set | 1374 | # CONFIG_USB_SERIAL_OPTION is not set |
1156 | CONFIG_USB_SERIAL_OMNINET=m | 1375 | CONFIG_USB_SERIAL_OMNINET=m |
1157 | CONFIG_USB_EZUSB=y | 1376 | # CONFIG_USB_SERIAL_DEBUG is not set |
1158 | 1377 | ||
1159 | # | 1378 | # |
1160 | # USB Miscellaneous drivers | 1379 | # USB Miscellaneous drivers |
1161 | # | 1380 | # |
1162 | CONFIG_USB_EMI62=m | 1381 | CONFIG_USB_EMI62=m |
1163 | CONFIG_USB_EMI26=m | 1382 | CONFIG_USB_EMI26=m |
1164 | CONFIG_USB_AUERSWALD=m | 1383 | # CONFIG_USB_ADUTUX is not set |
1384 | # CONFIG_USB_SEVSEG is not set | ||
1165 | CONFIG_USB_RIO500=m | 1385 | CONFIG_USB_RIO500=m |
1166 | CONFIG_USB_LEGOTOWER=m | 1386 | CONFIG_USB_LEGOTOWER=m |
1167 | CONFIG_USB_LCD=m | 1387 | CONFIG_USB_LCD=m |
1388 | # CONFIG_USB_BERRY_CHARGE is not set | ||
1168 | CONFIG_USB_LED=m | 1389 | CONFIG_USB_LED=m |
1390 | # CONFIG_USB_CYPRESS_CY7C63 is not set | ||
1169 | CONFIG_USB_CYTHERM=m | 1391 | CONFIG_USB_CYTHERM=m |
1170 | CONFIG_USB_PHIDGETKIT=m | 1392 | # CONFIG_USB_PHIDGET is not set |
1171 | CONFIG_USB_PHIDGETSERVO=m | ||
1172 | CONFIG_USB_IDMOUSE=m | 1393 | CONFIG_USB_IDMOUSE=m |
1394 | # CONFIG_USB_FTDI_ELAN is not set | ||
1395 | # CONFIG_USB_APPLEDISPLAY is not set | ||
1173 | # CONFIG_USB_LD is not set | 1396 | # CONFIG_USB_LD is not set |
1397 | # CONFIG_USB_TRANCEVIBRATOR is not set | ||
1398 | # CONFIG_USB_IOWARRIOR is not set | ||
1174 | # CONFIG_USB_TEST is not set | 1399 | # CONFIG_USB_TEST is not set |
1175 | 1400 | # CONFIG_USB_ISIGHTFW is not set | |
1176 | # | 1401 | # CONFIG_USB_VST is not set |
1177 | # USB DSL modem support | ||
1178 | # | ||
1179 | |||
1180 | # | ||
1181 | # USB Gadget Support | ||
1182 | # | ||
1183 | CONFIG_USB_GADGET=m | 1402 | CONFIG_USB_GADGET=m |
1403 | # CONFIG_USB_GADGET_DEBUG is not set | ||
1184 | # CONFIG_USB_GADGET_DEBUG_FILES is not set | 1404 | # CONFIG_USB_GADGET_DEBUG_FILES is not set |
1405 | CONFIG_USB_GADGET_VBUS_DRAW=2 | ||
1185 | CONFIG_USB_GADGET_SELECTED=y | 1406 | CONFIG_USB_GADGET_SELECTED=y |
1186 | # CONFIG_USB_GADGET_NET2280 is not set | 1407 | # CONFIG_USB_GADGET_AT91 is not set |
1187 | # CONFIG_USB_GADGET_PXA2XX is not set | 1408 | # CONFIG_USB_GADGET_ATMEL_USBA is not set |
1188 | # CONFIG_USB_GADGET_GOKU is not set | 1409 | # CONFIG_USB_GADGET_FSL_USB2 is not set |
1189 | # CONFIG_USB_GADGET_LH7A40X is not set | 1410 | # CONFIG_USB_GADGET_LH7A40X is not set |
1190 | # CONFIG_USB_GADGET_OMAP is not set | 1411 | # CONFIG_USB_GADGET_OMAP is not set |
1412 | # CONFIG_USB_GADGET_PXA25X is not set | ||
1413 | # CONFIG_USB_GADGET_PXA27X is not set | ||
1414 | # CONFIG_USB_GADGET_S3C2410 is not set | ||
1415 | # CONFIG_USB_GADGET_M66592 is not set | ||
1416 | # CONFIG_USB_GADGET_AMD5536UDC is not set | ||
1417 | # CONFIG_USB_GADGET_FSL_QE is not set | ||
1418 | # CONFIG_USB_GADGET_NET2280 is not set | ||
1419 | # CONFIG_USB_GADGET_GOKU is not set | ||
1191 | CONFIG_USB_GADGET_DUMMY_HCD=y | 1420 | CONFIG_USB_GADGET_DUMMY_HCD=y |
1192 | CONFIG_USB_DUMMY_HCD=m | 1421 | CONFIG_USB_DUMMY_HCD=m |
1193 | CONFIG_USB_GADGET_DUALSPEED=y | 1422 | CONFIG_USB_GADGET_DUALSPEED=y |
@@ -1198,15 +1427,42 @@ CONFIG_USB_GADGETFS=m | |||
1198 | CONFIG_USB_FILE_STORAGE=m | 1427 | CONFIG_USB_FILE_STORAGE=m |
1199 | # CONFIG_USB_FILE_STORAGE_TEST is not set | 1428 | # CONFIG_USB_FILE_STORAGE_TEST is not set |
1200 | CONFIG_USB_G_SERIAL=m | 1429 | CONFIG_USB_G_SERIAL=m |
1430 | # CONFIG_USB_MIDI_GADGET is not set | ||
1431 | # CONFIG_USB_G_PRINTER is not set | ||
1432 | # CONFIG_USB_CDC_COMPOSITE is not set | ||
1433 | CONFIG_MMC=y | ||
1434 | # CONFIG_MMC_DEBUG is not set | ||
1435 | # CONFIG_MMC_UNSAFE_RESUME is not set | ||
1201 | 1436 | ||
1202 | # | 1437 | # |
1203 | # MMC/SD Card support | 1438 | # MMC/SD/SDIO Card Drivers |
1204 | # | 1439 | # |
1205 | CONFIG_MMC=y | ||
1206 | # CONFIG_MMC_DEBUG is not set | ||
1207 | CONFIG_MMC_BLOCK=y | 1440 | CONFIG_MMC_BLOCK=y |
1441 | CONFIG_MMC_BLOCK_BOUNCE=y | ||
1442 | # CONFIG_SDIO_UART is not set | ||
1443 | # CONFIG_MMC_TEST is not set | ||
1444 | |||
1445 | # | ||
1446 | # MMC/SD/SDIO Host Controller Drivers | ||
1447 | # | ||
1208 | CONFIG_MMC_PXA=y | 1448 | CONFIG_MMC_PXA=y |
1209 | # CONFIG_MMC_WBSD is not set | 1449 | # CONFIG_MMC_SDHCI is not set |
1450 | # CONFIG_MMC_SPI is not set | ||
1451 | # CONFIG_MEMSTICK is not set | ||
1452 | # CONFIG_ACCESSIBILITY is not set | ||
1453 | # CONFIG_NEW_LEDS is not set | ||
1454 | CONFIG_RTC_LIB=y | ||
1455 | # CONFIG_RTC_CLASS is not set | ||
1456 | # CONFIG_DMADEVICES is not set | ||
1457 | |||
1458 | # | ||
1459 | # Voltage and Current regulators | ||
1460 | # | ||
1461 | # CONFIG_REGULATOR is not set | ||
1462 | # CONFIG_REGULATOR_FIXED_VOLTAGE is not set | ||
1463 | # CONFIG_REGULATOR_VIRTUAL_CONSUMER is not set | ||
1464 | # CONFIG_REGULATOR_BQ24022 is not set | ||
1465 | # CONFIG_UIO is not set | ||
1210 | 1466 | ||
1211 | # | 1467 | # |
1212 | # File systems | 1468 | # File systems |
@@ -1218,18 +1474,19 @@ CONFIG_EXT2_FS_SECURITY=y | |||
1218 | # CONFIG_EXT2_FS_XIP is not set | 1474 | # CONFIG_EXT2_FS_XIP is not set |
1219 | CONFIG_EXT3_FS=y | 1475 | CONFIG_EXT3_FS=y |
1220 | # CONFIG_EXT3_FS_XATTR is not set | 1476 | # CONFIG_EXT3_FS_XATTR is not set |
1477 | # CONFIG_EXT4_FS is not set | ||
1221 | CONFIG_JBD=y | 1478 | CONFIG_JBD=y |
1222 | # CONFIG_JBD_DEBUG is not set | ||
1223 | CONFIG_FS_MBCACHE=y | 1479 | CONFIG_FS_MBCACHE=y |
1224 | # CONFIG_REISERFS_FS is not set | 1480 | # CONFIG_REISERFS_FS is not set |
1225 | # CONFIG_JFS_FS is not set | 1481 | # CONFIG_JFS_FS is not set |
1226 | CONFIG_FS_POSIX_ACL=y | 1482 | CONFIG_FS_POSIX_ACL=y |
1483 | CONFIG_FILE_LOCKING=y | ||
1227 | # CONFIG_XFS_FS is not set | 1484 | # CONFIG_XFS_FS is not set |
1228 | # CONFIG_MINIX_FS is not set | 1485 | # CONFIG_OCFS2_FS is not set |
1229 | # CONFIG_ROMFS_FS is not set | 1486 | CONFIG_DNOTIFY=y |
1230 | CONFIG_INOTIFY=y | 1487 | CONFIG_INOTIFY=y |
1488 | CONFIG_INOTIFY_USER=y | ||
1231 | # CONFIG_QUOTA is not set | 1489 | # CONFIG_QUOTA is not set |
1232 | CONFIG_DNOTIFY=y | ||
1233 | # CONFIG_AUTOFS_FS is not set | 1490 | # CONFIG_AUTOFS_FS is not set |
1234 | # CONFIG_AUTOFS4_FS is not set | 1491 | # CONFIG_AUTOFS4_FS is not set |
1235 | # CONFIG_FUSE_FS is not set | 1492 | # CONFIG_FUSE_FS is not set |
@@ -1254,11 +1511,13 @@ CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" | |||
1254 | # Pseudo filesystems | 1511 | # Pseudo filesystems |
1255 | # | 1512 | # |
1256 | CONFIG_PROC_FS=y | 1513 | CONFIG_PROC_FS=y |
1514 | CONFIG_PROC_SYSCTL=y | ||
1515 | CONFIG_PROC_PAGE_MONITOR=y | ||
1257 | CONFIG_SYSFS=y | 1516 | CONFIG_SYSFS=y |
1258 | CONFIG_TMPFS=y | 1517 | CONFIG_TMPFS=y |
1518 | # CONFIG_TMPFS_POSIX_ACL is not set | ||
1259 | # CONFIG_HUGETLB_PAGE is not set | 1519 | # CONFIG_HUGETLB_PAGE is not set |
1260 | CONFIG_RAMFS=y | 1520 | # CONFIG_CONFIGFS_FS is not set |
1261 | # CONFIG_RELAYFS_FS is not set | ||
1262 | 1521 | ||
1263 | # | 1522 | # |
1264 | # Miscellaneous filesystems | 1523 | # Miscellaneous filesystems |
@@ -1270,39 +1529,42 @@ CONFIG_RAMFS=y | |||
1270 | # CONFIG_BEFS_FS is not set | 1529 | # CONFIG_BEFS_FS is not set |
1271 | # CONFIG_BFS_FS is not set | 1530 | # CONFIG_BFS_FS is not set |
1272 | # CONFIG_EFS_FS is not set | 1531 | # CONFIG_EFS_FS is not set |
1273 | # CONFIG_JFFS_FS is not set | ||
1274 | CONFIG_JFFS2_FS=y | 1532 | CONFIG_JFFS2_FS=y |
1275 | CONFIG_JFFS2_FS_DEBUG=0 | 1533 | CONFIG_JFFS2_FS_DEBUG=0 |
1276 | CONFIG_JFFS2_FS_WRITEBUFFER=y | 1534 | CONFIG_JFFS2_FS_WRITEBUFFER=y |
1535 | # CONFIG_JFFS2_FS_WBUF_VERIFY is not set | ||
1277 | CONFIG_JFFS2_SUMMARY=y | 1536 | CONFIG_JFFS2_SUMMARY=y |
1537 | # CONFIG_JFFS2_FS_XATTR is not set | ||
1278 | CONFIG_JFFS2_COMPRESSION_OPTIONS=y | 1538 | CONFIG_JFFS2_COMPRESSION_OPTIONS=y |
1279 | CONFIG_JFFS2_ZLIB=y | 1539 | CONFIG_JFFS2_ZLIB=y |
1540 | # CONFIG_JFFS2_LZO is not set | ||
1280 | CONFIG_JFFS2_RTIME=y | 1541 | CONFIG_JFFS2_RTIME=y |
1281 | CONFIG_JFFS2_RUBIN=y | 1542 | CONFIG_JFFS2_RUBIN=y |
1282 | # CONFIG_JFFS2_CMODE_NONE is not set | 1543 | # CONFIG_JFFS2_CMODE_NONE is not set |
1283 | CONFIG_JFFS2_CMODE_PRIORITY=y | 1544 | CONFIG_JFFS2_CMODE_PRIORITY=y |
1284 | # CONFIG_JFFS2_CMODE_SIZE is not set | 1545 | # CONFIG_JFFS2_CMODE_SIZE is not set |
1546 | # CONFIG_JFFS2_CMODE_FAVOURLZO is not set | ||
1285 | CONFIG_CRAMFS=m | 1547 | CONFIG_CRAMFS=m |
1286 | # CONFIG_VXFS_FS is not set | 1548 | # CONFIG_VXFS_FS is not set |
1549 | # CONFIG_MINIX_FS is not set | ||
1550 | # CONFIG_OMFS_FS is not set | ||
1287 | # CONFIG_HPFS_FS is not set | 1551 | # CONFIG_HPFS_FS is not set |
1288 | # CONFIG_QNX4FS_FS is not set | 1552 | # CONFIG_QNX4FS_FS is not set |
1553 | # CONFIG_ROMFS_FS is not set | ||
1289 | # CONFIG_SYSV_FS is not set | 1554 | # CONFIG_SYSV_FS is not set |
1290 | # CONFIG_UFS_FS is not set | 1555 | # CONFIG_UFS_FS is not set |
1291 | 1556 | CONFIG_NETWORK_FILESYSTEMS=y | |
1292 | # | ||
1293 | # Network File Systems | ||
1294 | # | ||
1295 | CONFIG_NFS_FS=m | 1557 | CONFIG_NFS_FS=m |
1296 | CONFIG_NFS_V3=y | 1558 | CONFIG_NFS_V3=y |
1297 | # CONFIG_NFS_V3_ACL is not set | 1559 | # CONFIG_NFS_V3_ACL is not set |
1298 | CONFIG_NFS_V4=y | 1560 | CONFIG_NFS_V4=y |
1299 | # CONFIG_NFS_DIRECTIO is not set | ||
1300 | # CONFIG_NFSD is not set | 1561 | # CONFIG_NFSD is not set |
1301 | CONFIG_LOCKD=m | 1562 | CONFIG_LOCKD=m |
1302 | CONFIG_LOCKD_V4=y | 1563 | CONFIG_LOCKD_V4=y |
1303 | CONFIG_NFS_COMMON=y | 1564 | CONFIG_NFS_COMMON=y |
1304 | CONFIG_SUNRPC=m | 1565 | CONFIG_SUNRPC=m |
1305 | CONFIG_SUNRPC_GSS=m | 1566 | CONFIG_SUNRPC_GSS=m |
1567 | # CONFIG_SUNRPC_REGISTER_V4 is not set | ||
1306 | CONFIG_RPCSEC_GSS_KRB5=m | 1568 | CONFIG_RPCSEC_GSS_KRB5=m |
1307 | # CONFIG_RPCSEC_GSS_SPKM3 is not set | 1569 | # CONFIG_RPCSEC_GSS_SPKM3 is not set |
1308 | CONFIG_SMB_FS=m | 1570 | CONFIG_SMB_FS=m |
@@ -1312,7 +1574,6 @@ CONFIG_SMB_NLS_REMOTE="cp437" | |||
1312 | # CONFIG_NCP_FS is not set | 1574 | # CONFIG_NCP_FS is not set |
1313 | # CONFIG_CODA_FS is not set | 1575 | # CONFIG_CODA_FS is not set |
1314 | # CONFIG_AFS_FS is not set | 1576 | # CONFIG_AFS_FS is not set |
1315 | # CONFIG_9P_FS is not set | ||
1316 | 1577 | ||
1317 | # | 1578 | # |
1318 | # Partition Types | 1579 | # Partition Types |
@@ -1332,11 +1593,9 @@ CONFIG_MSDOS_PARTITION=y | |||
1332 | # CONFIG_SGI_PARTITION is not set | 1593 | # CONFIG_SGI_PARTITION is not set |
1333 | # CONFIG_ULTRIX_PARTITION is not set | 1594 | # CONFIG_ULTRIX_PARTITION is not set |
1334 | # CONFIG_SUN_PARTITION is not set | 1595 | # CONFIG_SUN_PARTITION is not set |
1596 | # CONFIG_KARMA_PARTITION is not set | ||
1335 | # CONFIG_EFI_PARTITION is not set | 1597 | # CONFIG_EFI_PARTITION is not set |
1336 | 1598 | # CONFIG_SYSV68_PARTITION is not set | |
1337 | # | ||
1338 | # Native Language Support | ||
1339 | # | ||
1340 | CONFIG_NLS=y | 1599 | CONFIG_NLS=y |
1341 | CONFIG_NLS_DEFAULT="cp437" | 1600 | CONFIG_NLS_DEFAULT="cp437" |
1342 | CONFIG_NLS_CODEPAGE_437=y | 1601 | CONFIG_NLS_CODEPAGE_437=y |
@@ -1377,35 +1636,71 @@ CONFIG_NLS_ISO8859_1=y | |||
1377 | # CONFIG_NLS_KOI8_R is not set | 1636 | # CONFIG_NLS_KOI8_R is not set |
1378 | # CONFIG_NLS_KOI8_U is not set | 1637 | # CONFIG_NLS_KOI8_U is not set |
1379 | CONFIG_NLS_UTF8=y | 1638 | CONFIG_NLS_UTF8=y |
1380 | 1639 | # CONFIG_DLM is not set | |
1381 | # | ||
1382 | # Profiling support | ||
1383 | # | ||
1384 | CONFIG_PROFILING=y | ||
1385 | CONFIG_OPROFILE=m | ||
1386 | 1640 | ||
1387 | # | 1641 | # |
1388 | # Kernel hacking | 1642 | # Kernel hacking |
1389 | # | 1643 | # |
1390 | # CONFIG_PRINTK_TIME is not set | 1644 | # CONFIG_PRINTK_TIME is not set |
1391 | CONFIG_DEBUG_KERNEL=y | 1645 | CONFIG_ENABLE_WARN_DEPRECATED=y |
1646 | CONFIG_ENABLE_MUST_CHECK=y | ||
1647 | CONFIG_FRAME_WARN=1024 | ||
1392 | CONFIG_MAGIC_SYSRQ=y | 1648 | CONFIG_MAGIC_SYSRQ=y |
1393 | CONFIG_LOG_BUF_SHIFT=14 | 1649 | # CONFIG_UNUSED_SYMBOLS is not set |
1650 | # CONFIG_DEBUG_FS is not set | ||
1651 | # CONFIG_HEADERS_CHECK is not set | ||
1652 | CONFIG_DEBUG_KERNEL=y | ||
1653 | # CONFIG_DEBUG_SHIRQ is not set | ||
1394 | CONFIG_DETECT_SOFTLOCKUP=y | 1654 | CONFIG_DETECT_SOFTLOCKUP=y |
1655 | # CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set | ||
1656 | CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC_VALUE=0 | ||
1657 | CONFIG_SCHED_DEBUG=y | ||
1395 | # CONFIG_SCHEDSTATS is not set | 1658 | # CONFIG_SCHEDSTATS is not set |
1396 | # CONFIG_DEBUG_SLAB is not set | 1659 | # CONFIG_TIMER_STATS is not set |
1660 | # CONFIG_DEBUG_OBJECTS is not set | ||
1661 | # CONFIG_SLUB_DEBUG_ON is not set | ||
1662 | # CONFIG_SLUB_STATS is not set | ||
1397 | # CONFIG_DEBUG_PREEMPT is not set | 1663 | # CONFIG_DEBUG_PREEMPT is not set |
1664 | # CONFIG_DEBUG_RT_MUTEXES is not set | ||
1665 | # CONFIG_RT_MUTEX_TESTER is not set | ||
1398 | # CONFIG_DEBUG_SPINLOCK is not set | 1666 | # CONFIG_DEBUG_SPINLOCK is not set |
1667 | # CONFIG_DEBUG_MUTEXES is not set | ||
1668 | # CONFIG_DEBUG_LOCK_ALLOC is not set | ||
1669 | # CONFIG_PROVE_LOCKING is not set | ||
1670 | # CONFIG_LOCK_STAT is not set | ||
1399 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set | 1671 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set |
1672 | # CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set | ||
1400 | # CONFIG_DEBUG_KOBJECT is not set | 1673 | # CONFIG_DEBUG_KOBJECT is not set |
1401 | CONFIG_DEBUG_BUGVERBOSE=y | 1674 | CONFIG_DEBUG_BUGVERBOSE=y |
1402 | # CONFIG_DEBUG_INFO is not set | 1675 | # CONFIG_DEBUG_INFO is not set |
1403 | # CONFIG_DEBUG_FS is not set | ||
1404 | # CONFIG_DEBUG_VM is not set | 1676 | # CONFIG_DEBUG_VM is not set |
1677 | # CONFIG_DEBUG_WRITECOUNT is not set | ||
1678 | # CONFIG_DEBUG_MEMORY_INIT is not set | ||
1679 | # CONFIG_DEBUG_LIST is not set | ||
1680 | # CONFIG_DEBUG_SG is not set | ||
1405 | CONFIG_FRAME_POINTER=y | 1681 | CONFIG_FRAME_POINTER=y |
1682 | # CONFIG_BOOT_PRINTK_DELAY is not set | ||
1406 | # CONFIG_RCU_TORTURE_TEST is not set | 1683 | # CONFIG_RCU_TORTURE_TEST is not set |
1684 | # CONFIG_RCU_CPU_STALL_DETECTOR is not set | ||
1685 | # CONFIG_BACKTRACE_SELF_TEST is not set | ||
1686 | # CONFIG_DEBUG_BLOCK_EXT_DEVT is not set | ||
1687 | # CONFIG_FAULT_INJECTION is not set | ||
1688 | # CONFIG_LATENCYTOP is not set | ||
1689 | # CONFIG_SYSCTL_SYSCALL_CHECK is not set | ||
1690 | CONFIG_HAVE_FTRACE=y | ||
1691 | CONFIG_HAVE_DYNAMIC_FTRACE=y | ||
1692 | # CONFIG_FTRACE is not set | ||
1693 | # CONFIG_IRQSOFF_TRACER is not set | ||
1694 | # CONFIG_PREEMPT_TRACER is not set | ||
1695 | # CONFIG_SCHED_TRACER is not set | ||
1696 | # CONFIG_CONTEXT_SWITCH_TRACER is not set | ||
1697 | # CONFIG_DYNAMIC_PRINTK_DEBUG is not set | ||
1698 | # CONFIG_SAMPLES is not set | ||
1699 | CONFIG_HAVE_ARCH_KGDB=y | ||
1700 | # CONFIG_KGDB is not set | ||
1407 | # CONFIG_DEBUG_USER is not set | 1701 | # CONFIG_DEBUG_USER is not set |
1408 | CONFIG_DEBUG_ERRORS=y | 1702 | CONFIG_DEBUG_ERRORS=y |
1703 | # CONFIG_DEBUG_STACK_USAGE is not set | ||
1409 | CONFIG_DEBUG_LL=y | 1704 | CONFIG_DEBUG_LL=y |
1410 | # CONFIG_DEBUG_ICEDCC is not set | 1705 | # CONFIG_DEBUG_ICEDCC is not set |
1411 | 1706 | ||
@@ -1414,46 +1709,113 @@ CONFIG_DEBUG_LL=y | |||
1414 | # | 1709 | # |
1415 | # CONFIG_KEYS is not set | 1710 | # CONFIG_KEYS is not set |
1416 | # CONFIG_SECURITY is not set | 1711 | # CONFIG_SECURITY is not set |
1712 | # CONFIG_SECURITYFS is not set | ||
1713 | # CONFIG_SECURITY_FILE_CAPABILITIES is not set | ||
1714 | CONFIG_CRYPTO=y | ||
1417 | 1715 | ||
1418 | # | 1716 | # |
1419 | # Cryptographic options | 1717 | # Crypto core or helper |
1420 | # | 1718 | # |
1421 | CONFIG_CRYPTO=y | 1719 | # CONFIG_CRYPTO_FIPS is not set |
1422 | CONFIG_CRYPTO_HMAC=y | 1720 | CONFIG_CRYPTO_ALGAPI=y |
1721 | CONFIG_CRYPTO_AEAD=y | ||
1722 | CONFIG_CRYPTO_BLKCIPHER=y | ||
1723 | CONFIG_CRYPTO_HASH=y | ||
1724 | CONFIG_CRYPTO_RNG=y | ||
1725 | CONFIG_CRYPTO_MANAGER=y | ||
1726 | # CONFIG_CRYPTO_GF128MUL is not set | ||
1423 | CONFIG_CRYPTO_NULL=m | 1727 | CONFIG_CRYPTO_NULL=m |
1728 | # CONFIG_CRYPTO_CRYPTD is not set | ||
1729 | CONFIG_CRYPTO_AUTHENC=m | ||
1730 | CONFIG_CRYPTO_TEST=m | ||
1731 | |||
1732 | # | ||
1733 | # Authenticated Encryption with Associated Data | ||
1734 | # | ||
1735 | # CONFIG_CRYPTO_CCM is not set | ||
1736 | # CONFIG_CRYPTO_GCM is not set | ||
1737 | # CONFIG_CRYPTO_SEQIV is not set | ||
1738 | |||
1739 | # | ||
1740 | # Block modes | ||
1741 | # | ||
1742 | CONFIG_CRYPTO_CBC=m | ||
1743 | # CONFIG_CRYPTO_CTR is not set | ||
1744 | # CONFIG_CRYPTO_CTS is not set | ||
1745 | CONFIG_CRYPTO_ECB=m | ||
1746 | # CONFIG_CRYPTO_LRW is not set | ||
1747 | # CONFIG_CRYPTO_PCBC is not set | ||
1748 | # CONFIG_CRYPTO_XTS is not set | ||
1749 | |||
1750 | # | ||
1751 | # Hash modes | ||
1752 | # | ||
1753 | CONFIG_CRYPTO_HMAC=y | ||
1754 | # CONFIG_CRYPTO_XCBC is not set | ||
1755 | |||
1756 | # | ||
1757 | # Digest | ||
1758 | # | ||
1759 | CONFIG_CRYPTO_CRC32C=m | ||
1424 | CONFIG_CRYPTO_MD4=m | 1760 | CONFIG_CRYPTO_MD4=m |
1425 | CONFIG_CRYPTO_MD5=m | 1761 | CONFIG_CRYPTO_MD5=m |
1762 | CONFIG_CRYPTO_MICHAEL_MIC=m | ||
1763 | # CONFIG_CRYPTO_RMD128 is not set | ||
1764 | # CONFIG_CRYPTO_RMD160 is not set | ||
1765 | # CONFIG_CRYPTO_RMD256 is not set | ||
1766 | # CONFIG_CRYPTO_RMD320 is not set | ||
1426 | CONFIG_CRYPTO_SHA1=m | 1767 | CONFIG_CRYPTO_SHA1=m |
1427 | CONFIG_CRYPTO_SHA256=m | 1768 | CONFIG_CRYPTO_SHA256=m |
1428 | CONFIG_CRYPTO_SHA512=m | 1769 | CONFIG_CRYPTO_SHA512=m |
1429 | CONFIG_CRYPTO_WP512=m | ||
1430 | # CONFIG_CRYPTO_TGR192 is not set | 1770 | # CONFIG_CRYPTO_TGR192 is not set |
1431 | CONFIG_CRYPTO_DES=m | 1771 | CONFIG_CRYPTO_WP512=m |
1432 | CONFIG_CRYPTO_BLOWFISH=m | 1772 | |
1433 | CONFIG_CRYPTO_TWOFISH=m | 1773 | # |
1434 | CONFIG_CRYPTO_SERPENT=m | 1774 | # Ciphers |
1775 | # | ||
1435 | CONFIG_CRYPTO_AES=m | 1776 | CONFIG_CRYPTO_AES=m |
1777 | CONFIG_CRYPTO_ANUBIS=m | ||
1778 | CONFIG_CRYPTO_ARC4=m | ||
1779 | CONFIG_CRYPTO_BLOWFISH=m | ||
1780 | # CONFIG_CRYPTO_CAMELLIA is not set | ||
1436 | CONFIG_CRYPTO_CAST5=m | 1781 | CONFIG_CRYPTO_CAST5=m |
1437 | CONFIG_CRYPTO_CAST6=m | 1782 | CONFIG_CRYPTO_CAST6=m |
1438 | CONFIG_CRYPTO_TEA=m | 1783 | CONFIG_CRYPTO_DES=m |
1439 | CONFIG_CRYPTO_ARC4=m | 1784 | # CONFIG_CRYPTO_FCRYPT is not set |
1440 | CONFIG_CRYPTO_KHAZAD=m | 1785 | CONFIG_CRYPTO_KHAZAD=m |
1441 | CONFIG_CRYPTO_ANUBIS=m | 1786 | # CONFIG_CRYPTO_SALSA20 is not set |
1787 | # CONFIG_CRYPTO_SEED is not set | ||
1788 | CONFIG_CRYPTO_SERPENT=m | ||
1789 | CONFIG_CRYPTO_TEA=m | ||
1790 | CONFIG_CRYPTO_TWOFISH=m | ||
1791 | CONFIG_CRYPTO_TWOFISH_COMMON=m | ||
1792 | |||
1793 | # | ||
1794 | # Compression | ||
1795 | # | ||
1442 | CONFIG_CRYPTO_DEFLATE=m | 1796 | CONFIG_CRYPTO_DEFLATE=m |
1443 | CONFIG_CRYPTO_MICHAEL_MIC=m | 1797 | # CONFIG_CRYPTO_LZO is not set |
1444 | CONFIG_CRYPTO_CRC32C=m | ||
1445 | CONFIG_CRYPTO_TEST=m | ||
1446 | 1798 | ||
1447 | # | 1799 | # |
1448 | # Hardware crypto devices | 1800 | # Random Number Generation |
1449 | # | 1801 | # |
1802 | # CONFIG_CRYPTO_ANSI_CPRNG is not set | ||
1803 | CONFIG_CRYPTO_HW=y | ||
1450 | 1804 | ||
1451 | # | 1805 | # |
1452 | # Library routines | 1806 | # Library routines |
1453 | # | 1807 | # |
1808 | CONFIG_BITREVERSE=y | ||
1454 | CONFIG_CRC_CCITT=y | 1809 | CONFIG_CRC_CCITT=y |
1455 | # CONFIG_CRC16 is not set | 1810 | # CONFIG_CRC16 is not set |
1811 | # CONFIG_CRC_T10DIF is not set | ||
1812 | # CONFIG_CRC_ITU_T is not set | ||
1456 | CONFIG_CRC32=y | 1813 | CONFIG_CRC32=y |
1814 | # CONFIG_CRC7 is not set | ||
1457 | CONFIG_LIBCRC32C=m | 1815 | CONFIG_LIBCRC32C=m |
1458 | CONFIG_ZLIB_INFLATE=y | 1816 | CONFIG_ZLIB_INFLATE=y |
1459 | CONFIG_ZLIB_DEFLATE=y | 1817 | CONFIG_ZLIB_DEFLATE=y |
1818 | CONFIG_PLIST=y | ||
1819 | CONFIG_HAS_IOMEM=y | ||
1820 | CONFIG_HAS_IOPORT=y | ||
1821 | CONFIG_HAS_DMA=y | ||
diff --git a/arch/arm/include/asm/div64.h b/arch/arm/include/asm/div64.h index 5001390be958..d3f0a9eee9f6 100644 --- a/arch/arm/include/asm/div64.h +++ b/arch/arm/include/asm/div64.h | |||
@@ -165,7 +165,7 @@ | |||
165 | __res = __m; \ | 165 | __res = __m; \ |
166 | asm ( "umlal %Q0, %R0, %Q1, %Q2\n\t" \ | 166 | asm ( "umlal %Q0, %R0, %Q1, %Q2\n\t" \ |
167 | "mov %Q0, #0" \ | 167 | "mov %Q0, #0" \ |
168 | : "+r" (__res) \ | 168 | : "+&r" (__res) \ |
169 | : "r" (__m), "r" (__n) \ | 169 | : "r" (__m), "r" (__n) \ |
170 | : "cc" ); \ | 170 | : "cc" ); \ |
171 | } else { \ | 171 | } else { \ |
@@ -182,7 +182,7 @@ | |||
182 | "umlal %R0, %Q0, %Q1, %R2\n\t" \ | 182 | "umlal %R0, %Q0, %Q1, %R2\n\t" \ |
183 | "mov %R0, #0\n\t" \ | 183 | "mov %R0, #0\n\t" \ |
184 | "umlal %Q0, %R0, %R1, %R2" \ | 184 | "umlal %Q0, %R0, %R1, %R2" \ |
185 | : "+r" (__res) \ | 185 | : "+&r" (__res) \ |
186 | : "r" (__m), "r" (__n) \ | 186 | : "r" (__m), "r" (__n) \ |
187 | : "cc" ); \ | 187 | : "cc" ); \ |
188 | } else { \ | 188 | } else { \ |
@@ -192,7 +192,7 @@ | |||
192 | "adds %Q0, %1, %Q0\n\t" \ | 192 | "adds %Q0, %1, %Q0\n\t" \ |
193 | "adc %R0, %R0, #0\n\t" \ | 193 | "adc %R0, %R0, #0\n\t" \ |
194 | "umlal %Q0, %R0, %R2, %R3" \ | 194 | "umlal %Q0, %R0, %R2, %R3" \ |
195 | : "+r" (__res), "+r" (__z) \ | 195 | : "+&r" (__res), "+&r" (__z) \ |
196 | : "r" (__m), "r" (__n) \ | 196 | : "r" (__m), "r" (__n) \ |
197 | : "cc" ); \ | 197 | : "cc" ); \ |
198 | } \ | 198 | } \ |
diff --git a/arch/arm/mach-at91/gpio.c b/arch/arm/mach-at91/gpio.c index 7e5ebb5bdd17..9b0447c3d59b 100644 --- a/arch/arm/mach-at91/gpio.c +++ b/arch/arm/mach-at91/gpio.c | |||
@@ -404,6 +404,7 @@ static void gpio_irq_handler(unsigned irq, struct irq_desc *desc) | |||
404 | } | 404 | } |
405 | 405 | ||
406 | pin = bank->chipbase; | 406 | pin = bank->chipbase; |
407 | gpio = &irq_desc[pin]; | ||
407 | 408 | ||
408 | while (isr) { | 409 | while (isr) { |
409 | if (isr & 1) { | 410 | if (isr & 1) { |
diff --git a/arch/arm/mach-kirkwood/Makefile b/arch/arm/mach-kirkwood/Makefile index e14bf40bfb07..b96c55dad343 100644 --- a/arch/arm/mach-kirkwood/Makefile +++ b/arch/arm/mach-kirkwood/Makefile | |||
@@ -2,4 +2,4 @@ obj-y += common.o addr-map.o irq.o pcie.o | |||
2 | 2 | ||
3 | obj-$(CONFIG_MACH_DB88F6281_BP) += db88f6281-bp-setup.o | 3 | obj-$(CONFIG_MACH_DB88F6281_BP) += db88f6281-bp-setup.o |
4 | obj-$(CONFIG_MACH_RD88F6192_NAS) += rd88f6192-nas-setup.o | 4 | obj-$(CONFIG_MACH_RD88F6192_NAS) += rd88f6192-nas-setup.o |
5 | obj-$(CONFIG_MACH_RD88F6192_NAS) += rd88f6281-setup.o | 5 | obj-$(CONFIG_MACH_RD88F6281) += rd88f6281-setup.o |
diff --git a/arch/arm/mach-msm/Kconfig b/arch/arm/mach-msm/Kconfig index 3553babbbf05..d140abca690a 100644 --- a/arch/arm/mach-msm/Kconfig +++ b/arch/arm/mach-msm/Kconfig | |||
@@ -1,18 +1,13 @@ | |||
1 | if ARCH_MSM7X00A | 1 | if ARCH_MSM |
2 | 2 | ||
3 | comment "MSM7X00A Board Type" | 3 | comment "MSM Board Type" |
4 | depends on ARCH_MSM7X00A | 4 | depends on ARCH_MSM |
5 | 5 | ||
6 | config MACH_HALIBUT | 6 | config MACH_HALIBUT |
7 | depends on ARCH_MSM7X00A | 7 | depends on ARCH_MSM |
8 | default y | 8 | default y |
9 | bool "Halibut Board (QCT SURF7200A)" | 9 | bool "Halibut Board (QCT SURF7201A)" |
10 | help | 10 | help |
11 | Support for the Qualcomm SURF7200A eval board. | 11 | Support for the Qualcomm SURF7201A eval board. |
12 | |||
13 | config MSM7X00A_IDLE | ||
14 | depends on ARCH_MSM7X00A | ||
15 | default y | ||
16 | bool "Idle Support for MSM7X00A" | ||
17 | 12 | ||
18 | endif | 13 | endif |
diff --git a/arch/arm/mach-msm/Makefile b/arch/arm/mach-msm/Makefile index d12f23655850..1aa47001aa3b 100644 --- a/arch/arm/mach-msm/Makefile +++ b/arch/arm/mach-msm/Makefile | |||
@@ -1,7 +1,8 @@ | |||
1 | obj-y += io.o idle.o irq.o timer.o dma.o | 1 | obj-y += io.o idle.o irq.o timer.o dma.o |
2 | 2 | obj-y += devices.o | |
3 | # Common code for board init | 3 | obj-y += proc_comm.o |
4 | obj-y += common.o | 4 | obj-y += vreg.o |
5 | obj-y += clock.o clock-7x01a.o | ||
5 | 6 | ||
6 | obj-$(CONFIG_MACH_HALIBUT) += board-halibut.o | 7 | obj-$(CONFIG_MACH_HALIBUT) += board-halibut.o |
7 | 8 | ||
diff --git a/arch/arm/mach-msm/board-halibut.c b/arch/arm/mach-msm/board-halibut.c index a24259133e07..c2a96e3965a6 100644 --- a/arch/arm/mach-msm/board-halibut.c +++ b/arch/arm/mach-msm/board-halibut.c | |||
@@ -33,6 +33,8 @@ | |||
33 | #include <linux/mtd/nand.h> | 33 | #include <linux/mtd/nand.h> |
34 | #include <linux/mtd/partitions.h> | 34 | #include <linux/mtd/partitions.h> |
35 | 35 | ||
36 | #include "devices.h" | ||
37 | |||
36 | static struct resource smc91x_resources[] = { | 38 | static struct resource smc91x_resources[] = { |
37 | [0] = { | 39 | [0] = { |
38 | .start = 0x9C004300, | 40 | .start = 0x9C004300, |
@@ -53,31 +55,12 @@ static struct platform_device smc91x_device = { | |||
53 | .resource = smc91x_resources, | 55 | .resource = smc91x_resources, |
54 | }; | 56 | }; |
55 | 57 | ||
56 | static void mddi0_panel_power(int on) | ||
57 | { | ||
58 | } | ||
59 | |||
60 | static struct msm_mddi_platform_data msm_mddi0_pdata = { | ||
61 | .panel_power = mddi0_panel_power, | ||
62 | .has_vsync_irq = 0, | ||
63 | }; | ||
64 | |||
65 | static struct platform_device msm_mddi0_device = { | ||
66 | .name = "msm_mddi", | ||
67 | .id = 0, | ||
68 | .dev = { | ||
69 | .platform_data = &msm_mddi0_pdata | ||
70 | }, | ||
71 | }; | ||
72 | |||
73 | static struct platform_device msm_serial0_device = { | ||
74 | .name = "msm_serial", | ||
75 | .id = 0, | ||
76 | }; | ||
77 | |||
78 | static struct platform_device *devices[] __initdata = { | 58 | static struct platform_device *devices[] __initdata = { |
79 | &msm_serial0_device, | 59 | &msm_device_uart3, |
80 | &msm_mddi0_device, | 60 | &msm_device_smd, |
61 | &msm_device_nand, | ||
62 | &msm_device_hsusb, | ||
63 | &msm_device_i2c, | ||
81 | &smc91x_device, | 64 | &smc91x_device, |
82 | }; | 65 | }; |
83 | 66 | ||
@@ -91,20 +74,15 @@ static void __init halibut_init_irq(void) | |||
91 | static void __init halibut_init(void) | 74 | static void __init halibut_init(void) |
92 | { | 75 | { |
93 | platform_add_devices(devices, ARRAY_SIZE(devices)); | 76 | platform_add_devices(devices, ARRAY_SIZE(devices)); |
94 | msm_add_devices(); | ||
95 | } | 77 | } |
96 | 78 | ||
97 | static void __init halibut_map_io(void) | 79 | static void __init halibut_map_io(void) |
98 | { | 80 | { |
99 | msm_map_common_io(); | 81 | msm_map_common_io(); |
82 | msm_clock_init(); | ||
100 | } | 83 | } |
101 | 84 | ||
102 | MACHINE_START(HALIBUT, "Halibut Board (QCT SURF7200A)") | 85 | MACHINE_START(HALIBUT, "Halibut Board (QCT SURF7200A)") |
103 | |||
104 | /* UART for LL DEBUG */ | ||
105 | .phys_io = MSM_UART1_PHYS, | ||
106 | .io_pg_offst = ((MSM_UART1_BASE) >> 18) & 0xfffc, | ||
107 | |||
108 | .boot_params = 0x10000100, | 86 | .boot_params = 0x10000100, |
109 | .map_io = halibut_map_io, | 87 | .map_io = halibut_map_io, |
110 | .init_irq = halibut_init_irq, | 88 | .init_irq = halibut_init_irq, |
diff --git a/arch/arm/mach-msm/clock-7x01a.c b/arch/arm/mach-msm/clock-7x01a.c new file mode 100644 index 000000000000..62230a3428ee --- /dev/null +++ b/arch/arm/mach-msm/clock-7x01a.c | |||
@@ -0,0 +1,126 @@ | |||
1 | /* arch/arm/mach-msm/clock-7x01a.c | ||
2 | * | ||
3 | * Clock tables for MSM7X01A | ||
4 | * | ||
5 | * Copyright (C) 2007 Google, Inc. | ||
6 | * Copyright (c) 2007 QUALCOMM Incorporated | ||
7 | * | ||
8 | * This software is licensed under the terms of the GNU General Public | ||
9 | * License version 2, as published by the Free Software Foundation, and | ||
10 | * may be copied, distributed, and modified under those terms. | ||
11 | * | ||
12 | * This program is distributed in the hope that it will be useful, | ||
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
15 | * GNU General Public License for more details. | ||
16 | * | ||
17 | */ | ||
18 | |||
19 | #include <linux/kernel.h> | ||
20 | #include <linux/platform_device.h> | ||
21 | |||
22 | #include "clock.h" | ||
23 | #include "devices.h" | ||
24 | |||
25 | /* clock IDs used by the modem processor */ | ||
26 | |||
27 | #define ACPU_CLK 0 /* Applications processor clock */ | ||
28 | #define ADM_CLK 1 /* Applications data mover clock */ | ||
29 | #define ADSP_CLK 2 /* ADSP clock */ | ||
30 | #define EBI1_CLK 3 /* External bus interface 1 clock */ | ||
31 | #define EBI2_CLK 4 /* External bus interface 2 clock */ | ||
32 | #define ECODEC_CLK 5 /* External CODEC clock */ | ||
33 | #define EMDH_CLK 6 /* External MDDI host clock */ | ||
34 | #define GP_CLK 7 /* General purpose clock */ | ||
35 | #define GRP_CLK 8 /* Graphics clock */ | ||
36 | #define I2C_CLK 9 /* I2C clock */ | ||
37 | #define ICODEC_RX_CLK 10 /* Internal CODEX RX clock */ | ||
38 | #define ICODEC_TX_CLK 11 /* Internal CODEX TX clock */ | ||
39 | #define IMEM_CLK 12 /* Internal graphics memory clock */ | ||
40 | #define MDC_CLK 13 /* MDDI client clock */ | ||
41 | #define MDP_CLK 14 /* Mobile display processor clock */ | ||
42 | #define PBUS_CLK 15 /* Peripheral bus clock */ | ||
43 | #define PCM_CLK 16 /* PCM clock */ | ||
44 | #define PMDH_CLK 17 /* Primary MDDI host clock */ | ||
45 | #define SDAC_CLK 18 /* Stereo DAC clock */ | ||
46 | #define SDC1_CLK 19 /* Secure Digital Card clocks */ | ||
47 | #define SDC1_PCLK 20 | ||
48 | #define SDC2_CLK 21 | ||
49 | #define SDC2_PCLK 22 | ||
50 | #define SDC3_CLK 23 | ||
51 | #define SDC3_PCLK 24 | ||
52 | #define SDC4_CLK 25 | ||
53 | #define SDC4_PCLK 26 | ||
54 | #define TSIF_CLK 27 /* Transport Stream Interface clocks */ | ||
55 | #define TSIF_REF_CLK 28 | ||
56 | #define TV_DAC_CLK 29 /* TV clocks */ | ||
57 | #define TV_ENC_CLK 30 | ||
58 | #define UART1_CLK 31 /* UART clocks */ | ||
59 | #define UART2_CLK 32 | ||
60 | #define UART3_CLK 33 | ||
61 | #define UART1DM_CLK 34 | ||
62 | #define UART2DM_CLK 35 | ||
63 | #define USB_HS_CLK 36 /* High speed USB core clock */ | ||
64 | #define USB_HS_PCLK 37 /* High speed USB pbus clock */ | ||
65 | #define USB_OTG_CLK 38 /* Full speed USB clock */ | ||
66 | #define VDC_CLK 39 /* Video controller clock */ | ||
67 | #define VFE_CLK 40 /* Camera / Video Front End clock */ | ||
68 | #define VFE_MDC_CLK 41 /* VFE MDDI client clock */ | ||
69 | |||
70 | #define NR_CLKS 42 | ||
71 | |||
72 | #define CLOCK(clk_name, clk_id, clk_dev, clk_flags) { \ | ||
73 | .name = clk_name, \ | ||
74 | .id = clk_id, \ | ||
75 | .flags = clk_flags, \ | ||
76 | .dev = clk_dev, \ | ||
77 | } | ||
78 | |||
79 | #define OFF CLKFLAG_AUTO_OFF | ||
80 | #define MINMAX CLKFLAG_USE_MIN_MAX_TO_SET | ||
81 | |||
82 | struct clk msm_clocks[] = { | ||
83 | CLOCK("adm_clk", ADM_CLK, NULL, 0), | ||
84 | CLOCK("adsp_clk", ADSP_CLK, NULL, 0), | ||
85 | CLOCK("ebi1_clk", EBI1_CLK, NULL, 0), | ||
86 | CLOCK("ebi2_clk", EBI2_CLK, NULL, 0), | ||
87 | CLOCK("ecodec_clk", ECODEC_CLK, NULL, 0), | ||
88 | CLOCK("emdh_clk", EMDH_CLK, NULL, OFF), | ||
89 | CLOCK("gp_clk", GP_CLK, NULL, 0), | ||
90 | CLOCK("grp_clk", GRP_CLK, NULL, OFF), | ||
91 | CLOCK("i2c_clk", I2C_CLK, &msm_device_i2c.dev, 0), | ||
92 | CLOCK("icodec_rx_clk", ICODEC_RX_CLK, NULL, 0), | ||
93 | CLOCK("icodec_tx_clk", ICODEC_TX_CLK, NULL, 0), | ||
94 | CLOCK("imem_clk", IMEM_CLK, NULL, OFF), | ||
95 | CLOCK("mdc_clk", MDC_CLK, NULL, 0), | ||
96 | CLOCK("mdp_clk", MDP_CLK, NULL, OFF), | ||
97 | CLOCK("pbus_clk", PBUS_CLK, NULL, 0), | ||
98 | CLOCK("pcm_clk", PCM_CLK, NULL, 0), | ||
99 | CLOCK("pmdh_clk", PMDH_CLK, NULL, OFF | MINMAX), | ||
100 | CLOCK("sdac_clk", SDAC_CLK, NULL, OFF), | ||
101 | CLOCK("sdc_clk", SDC1_CLK, &msm_device_sdc1.dev, OFF), | ||
102 | CLOCK("sdc_pclk", SDC1_PCLK, &msm_device_sdc1.dev, OFF), | ||
103 | CLOCK("sdc_clk", SDC2_CLK, &msm_device_sdc2.dev, OFF), | ||
104 | CLOCK("sdc_pclk", SDC2_PCLK, &msm_device_sdc2.dev, OFF), | ||
105 | CLOCK("sdc_clk", SDC3_CLK, &msm_device_sdc3.dev, OFF), | ||
106 | CLOCK("sdc_pclk", SDC3_PCLK, &msm_device_sdc3.dev, OFF), | ||
107 | CLOCK("sdc_clk", SDC4_CLK, &msm_device_sdc4.dev, OFF), | ||
108 | CLOCK("sdc_pclk", SDC4_PCLK, &msm_device_sdc4.dev, OFF), | ||
109 | CLOCK("tsif_clk", TSIF_CLK, NULL, 0), | ||
110 | CLOCK("tsif_ref_clk", TSIF_REF_CLK, NULL, 0), | ||
111 | CLOCK("tv_dac_clk", TV_DAC_CLK, NULL, 0), | ||
112 | CLOCK("tv_enc_clk", TV_ENC_CLK, NULL, 0), | ||
113 | CLOCK("uart_clk", UART1_CLK, &msm_device_uart1.dev, OFF), | ||
114 | CLOCK("uart_clk", UART2_CLK, &msm_device_uart2.dev, 0), | ||
115 | CLOCK("uart_clk", UART3_CLK, &msm_device_uart3.dev, OFF), | ||
116 | CLOCK("uart1dm_clk", UART1DM_CLK, NULL, OFF), | ||
117 | CLOCK("uart2dm_clk", UART2DM_CLK, NULL, 0), | ||
118 | CLOCK("usb_hs_clk", USB_HS_CLK, &msm_device_hsusb.dev, OFF), | ||
119 | CLOCK("usb_hs_pclk", USB_HS_PCLK, &msm_device_hsusb.dev, OFF), | ||
120 | CLOCK("usb_otg_clk", USB_OTG_CLK, NULL, 0), | ||
121 | CLOCK("vdc_clk", VDC_CLK, NULL, OFF | MINMAX), | ||
122 | CLOCK("vfe_clk", VFE_CLK, NULL, OFF), | ||
123 | CLOCK("vfe_mdc_clk", VFE_MDC_CLK, NULL, OFF), | ||
124 | }; | ||
125 | |||
126 | unsigned msm_num_clocks = ARRAY_SIZE(msm_clocks); | ||
diff --git a/arch/arm/mach-msm/clock.c b/arch/arm/mach-msm/clock.c new file mode 100644 index 000000000000..3b1ce36f1032 --- /dev/null +++ b/arch/arm/mach-msm/clock.c | |||
@@ -0,0 +1,218 @@ | |||
1 | /* arch/arm/mach-msm/clock.c | ||
2 | * | ||
3 | * Copyright (C) 2007 Google, Inc. | ||
4 | * Copyright (c) 2007 QUALCOMM Incorporated | ||
5 | * | ||
6 | * This software is licensed under the terms of the GNU General Public | ||
7 | * License version 2, as published by the Free Software Foundation, and | ||
8 | * may be copied, distributed, and modified under those terms. | ||
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 | */ | ||
16 | |||
17 | #include <linux/version.h> | ||
18 | #include <linux/kernel.h> | ||
19 | #include <linux/init.h> | ||
20 | #include <linux/module.h> | ||
21 | #include <linux/list.h> | ||
22 | #include <linux/err.h> | ||
23 | #include <linux/clk.h> | ||
24 | #include <linux/spinlock.h> | ||
25 | |||
26 | #include "clock.h" | ||
27 | #include "proc_comm.h" | ||
28 | |||
29 | static DEFINE_MUTEX(clocks_mutex); | ||
30 | static DEFINE_SPINLOCK(clocks_lock); | ||
31 | static LIST_HEAD(clocks); | ||
32 | |||
33 | /* | ||
34 | * glue for the proc_comm interface | ||
35 | */ | ||
36 | static inline int pc_clk_enable(unsigned id) | ||
37 | { | ||
38 | return msm_proc_comm(PCOM_CLKCTL_RPC_ENABLE, &id, NULL); | ||
39 | } | ||
40 | |||
41 | static inline void pc_clk_disable(unsigned id) | ||
42 | { | ||
43 | msm_proc_comm(PCOM_CLKCTL_RPC_DISABLE, &id, NULL); | ||
44 | } | ||
45 | |||
46 | static inline int pc_clk_set_rate(unsigned id, unsigned rate) | ||
47 | { | ||
48 | return msm_proc_comm(PCOM_CLKCTL_RPC_SET_RATE, &id, &rate); | ||
49 | } | ||
50 | |||
51 | static inline int pc_clk_set_min_rate(unsigned id, unsigned rate) | ||
52 | { | ||
53 | return msm_proc_comm(PCOM_CLKCTL_RPC_MIN_RATE, &id, &rate); | ||
54 | } | ||
55 | |||
56 | static inline int pc_clk_set_max_rate(unsigned id, unsigned rate) | ||
57 | { | ||
58 | return msm_proc_comm(PCOM_CLKCTL_RPC_MAX_RATE, &id, &rate); | ||
59 | } | ||
60 | |||
61 | static inline int pc_clk_set_flags(unsigned id, unsigned flags) | ||
62 | { | ||
63 | return msm_proc_comm(PCOM_CLKCTL_RPC_SET_FLAGS, &id, &flags); | ||
64 | } | ||
65 | |||
66 | static inline unsigned pc_clk_get_rate(unsigned id) | ||
67 | { | ||
68 | if (msm_proc_comm(PCOM_CLKCTL_RPC_RATE, &id, NULL)) | ||
69 | return 0; | ||
70 | else | ||
71 | return id; | ||
72 | } | ||
73 | |||
74 | static inline unsigned pc_clk_is_enabled(unsigned id) | ||
75 | { | ||
76 | if (msm_proc_comm(PCOM_CLKCTL_RPC_ENABLED, &id, NULL)) | ||
77 | return 0; | ||
78 | else | ||
79 | return id; | ||
80 | } | ||
81 | |||
82 | static inline int pc_pll_request(unsigned id, unsigned on) | ||
83 | { | ||
84 | on = !!on; | ||
85 | return msm_proc_comm(PCOM_CLKCTL_RPC_PLL_REQUEST, &id, &on); | ||
86 | } | ||
87 | |||
88 | /* | ||
89 | * Standard clock functions defined in include/linux/clk.h | ||
90 | */ | ||
91 | struct clk *clk_get(struct device *dev, const char *id) | ||
92 | { | ||
93 | struct clk *clk; | ||
94 | |||
95 | mutex_lock(&clocks_mutex); | ||
96 | |||
97 | list_for_each_entry(clk, &clocks, list) | ||
98 | if (!strcmp(id, clk->name) && clk->dev == dev) | ||
99 | goto found_it; | ||
100 | |||
101 | list_for_each_entry(clk, &clocks, list) | ||
102 | if (!strcmp(id, clk->name) && clk->dev == NULL) | ||
103 | goto found_it; | ||
104 | |||
105 | clk = ERR_PTR(-ENOENT); | ||
106 | found_it: | ||
107 | mutex_unlock(&clocks_mutex); | ||
108 | return clk; | ||
109 | } | ||
110 | EXPORT_SYMBOL(clk_get); | ||
111 | |||
112 | void clk_put(struct clk *clk) | ||
113 | { | ||
114 | } | ||
115 | EXPORT_SYMBOL(clk_put); | ||
116 | |||
117 | int clk_enable(struct clk *clk) | ||
118 | { | ||
119 | unsigned long flags; | ||
120 | spin_lock_irqsave(&clocks_lock, flags); | ||
121 | clk->count++; | ||
122 | if (clk->count == 1) | ||
123 | pc_clk_enable(clk->id); | ||
124 | spin_unlock_irqrestore(&clocks_lock, flags); | ||
125 | return 0; | ||
126 | } | ||
127 | EXPORT_SYMBOL(clk_enable); | ||
128 | |||
129 | void clk_disable(struct clk *clk) | ||
130 | { | ||
131 | unsigned long flags; | ||
132 | spin_lock_irqsave(&clocks_lock, flags); | ||
133 | BUG_ON(clk->count == 0); | ||
134 | clk->count--; | ||
135 | if (clk->count == 0) | ||
136 | pc_clk_disable(clk->id); | ||
137 | spin_unlock_irqrestore(&clocks_lock, flags); | ||
138 | } | ||
139 | EXPORT_SYMBOL(clk_disable); | ||
140 | |||
141 | unsigned long clk_get_rate(struct clk *clk) | ||
142 | { | ||
143 | return pc_clk_get_rate(clk->id); | ||
144 | } | ||
145 | EXPORT_SYMBOL(clk_get_rate); | ||
146 | |||
147 | int clk_set_rate(struct clk *clk, unsigned long rate) | ||
148 | { | ||
149 | int ret; | ||
150 | if (clk->flags & CLKFLAG_USE_MIN_MAX_TO_SET) { | ||
151 | ret = pc_clk_set_max_rate(clk->id, rate); | ||
152 | if (ret) | ||
153 | return ret; | ||
154 | return pc_clk_set_min_rate(clk->id, rate); | ||
155 | } | ||
156 | return pc_clk_set_rate(clk->id, rate); | ||
157 | } | ||
158 | EXPORT_SYMBOL(clk_set_rate); | ||
159 | |||
160 | int clk_set_parent(struct clk *clk, struct clk *parent) | ||
161 | { | ||
162 | return -ENOSYS; | ||
163 | } | ||
164 | EXPORT_SYMBOL(clk_set_parent); | ||
165 | |||
166 | struct clk *clk_get_parent(struct clk *clk) | ||
167 | { | ||
168 | return ERR_PTR(-ENOSYS); | ||
169 | } | ||
170 | EXPORT_SYMBOL(clk_get_parent); | ||
171 | |||
172 | int clk_set_flags(struct clk *clk, unsigned long flags) | ||
173 | { | ||
174 | if (clk == NULL || IS_ERR(clk)) | ||
175 | return -EINVAL; | ||
176 | return pc_clk_set_flags(clk->id, flags); | ||
177 | } | ||
178 | EXPORT_SYMBOL(clk_set_flags); | ||
179 | |||
180 | |||
181 | void __init msm_clock_init(void) | ||
182 | { | ||
183 | unsigned n; | ||
184 | |||
185 | spin_lock_init(&clocks_lock); | ||
186 | mutex_lock(&clocks_mutex); | ||
187 | for (n = 0; n < msm_num_clocks; n++) | ||
188 | list_add_tail(&msm_clocks[n].list, &clocks); | ||
189 | mutex_unlock(&clocks_mutex); | ||
190 | } | ||
191 | |||
192 | /* The bootloader and/or AMSS may have left various clocks enabled. | ||
193 | * Disable any clocks that belong to us (CLKFLAG_AUTO_OFF) but have | ||
194 | * not been explicitly enabled by a clk_enable() call. | ||
195 | */ | ||
196 | static int __init clock_late_init(void) | ||
197 | { | ||
198 | unsigned long flags; | ||
199 | struct clk *clk; | ||
200 | unsigned count = 0; | ||
201 | |||
202 | mutex_lock(&clocks_mutex); | ||
203 | list_for_each_entry(clk, &clocks, list) { | ||
204 | if (clk->flags & CLKFLAG_AUTO_OFF) { | ||
205 | spin_lock_irqsave(&clocks_lock, flags); | ||
206 | if (!clk->count) { | ||
207 | count++; | ||
208 | pc_clk_disable(clk->id); | ||
209 | } | ||
210 | spin_unlock_irqrestore(&clocks_lock, flags); | ||
211 | } | ||
212 | } | ||
213 | mutex_unlock(&clocks_mutex); | ||
214 | pr_info("clock_late_init() disabled %d unused clocks\n", count); | ||
215 | return 0; | ||
216 | } | ||
217 | |||
218 | late_initcall(clock_late_init); | ||
diff --git a/arch/arm/mach-msm/clock.h b/arch/arm/mach-msm/clock.h new file mode 100644 index 000000000000..f875e1544e5f --- /dev/null +++ b/arch/arm/mach-msm/clock.h | |||
@@ -0,0 +1,48 @@ | |||
1 | /* arch/arm/mach-msm/clock.h | ||
2 | * | ||
3 | * Copyright (C) 2007 Google, Inc. | ||
4 | * Copyright (c) 2007 QUALCOMM Incorporated | ||
5 | * | ||
6 | * This software is licensed under the terms of the GNU General Public | ||
7 | * License version 2, as published by the Free Software Foundation, and | ||
8 | * may be copied, distributed, and modified under those terms. | ||
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 | */ | ||
16 | |||
17 | #ifndef __ARCH_ARM_MACH_MSM_CLOCK_H | ||
18 | #define __ARCH_ARM_MACH_MSM_CLOCK_H | ||
19 | |||
20 | #include <linux/list.h> | ||
21 | |||
22 | #define CLKFLAG_INVERT 0x00000001 | ||
23 | #define CLKFLAG_NOINVERT 0x00000002 | ||
24 | #define CLKFLAG_NONEST 0x00000004 | ||
25 | #define CLKFLAG_NORESET 0x00000008 | ||
26 | |||
27 | #define CLK_FIRST_AVAILABLE_FLAG 0x00000100 | ||
28 | #define CLKFLAG_USE_MIN_MAX_TO_SET 0x00000200 | ||
29 | #define CLKFLAG_AUTO_OFF 0x00000400 | ||
30 | |||
31 | struct clk { | ||
32 | uint32_t id; | ||
33 | uint32_t count; | ||
34 | uint32_t flags; | ||
35 | const char *name; | ||
36 | struct list_head list; | ||
37 | struct device *dev; | ||
38 | }; | ||
39 | |||
40 | #define A11S_CLK_CNTL_ADDR (MSM_CSR_BASE + 0x100) | ||
41 | #define A11S_CLK_SEL_ADDR (MSM_CSR_BASE + 0x104) | ||
42 | #define A11S_VDD_SVS_PLEVEL_ADDR (MSM_CSR_BASE + 0x124) | ||
43 | |||
44 | extern struct clk msm_clocks[]; | ||
45 | extern unsigned msm_num_clocks; | ||
46 | |||
47 | #endif | ||
48 | |||
diff --git a/arch/arm/mach-msm/common.c b/arch/arm/mach-msm/common.c deleted file mode 100644 index 604f8ade9587..000000000000 --- a/arch/arm/mach-msm/common.c +++ /dev/null | |||
@@ -1,116 +0,0 @@ | |||
1 | /* linux/arch/arm/mach-msm/common.c | ||
2 | * | ||
3 | * Common setup code for MSM7K Boards | ||
4 | * | ||
5 | * Copyright (C) 2007 Google, Inc. | ||
6 | * Author: Brian Swetland <swetland@google.com> | ||
7 | * | ||
8 | * This software is licensed under the terms of the GNU General Public | ||
9 | * License version 2, as published by the Free Software Foundation, and | ||
10 | * may be copied, distributed, and modified under those terms. | ||
11 | * | ||
12 | * This program is distributed in the hope that it will be useful, | ||
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
15 | * GNU General Public License for more details. | ||
16 | * | ||
17 | */ | ||
18 | |||
19 | #include <linux/kernel.h> | ||
20 | #include <linux/init.h> | ||
21 | #include <linux/platform_device.h> | ||
22 | #include <linux/io.h> | ||
23 | |||
24 | #include <asm/mach/flash.h> | ||
25 | |||
26 | #include <asm/setup.h> | ||
27 | |||
28 | #include <linux/mtd/nand.h> | ||
29 | #include <linux/mtd/partitions.h> | ||
30 | |||
31 | #include <mach/msm_iomap.h> | ||
32 | |||
33 | #include <mach/board.h> | ||
34 | |||
35 | struct flash_platform_data msm_nand_data = { | ||
36 | .parts = 0, | ||
37 | .nr_parts = 0, | ||
38 | }; | ||
39 | |||
40 | static struct resource msm_nand_resources[] = { | ||
41 | [0] = { | ||
42 | .start = 7, | ||
43 | .end = 7, | ||
44 | .flags = IORESOURCE_DMA, | ||
45 | }, | ||
46 | }; | ||
47 | |||
48 | static struct platform_device msm_nand_device = { | ||
49 | .name = "msm_nand", | ||
50 | .id = -1, | ||
51 | .num_resources = ARRAY_SIZE(msm_nand_resources), | ||
52 | .resource = msm_nand_resources, | ||
53 | .dev = { | ||
54 | .platform_data = &msm_nand_data, | ||
55 | }, | ||
56 | }; | ||
57 | |||
58 | static struct platform_device msm_smd_device = { | ||
59 | .name = "msm_smd", | ||
60 | .id = -1, | ||
61 | }; | ||
62 | |||
63 | static struct resource msm_i2c_resources[] = { | ||
64 | { | ||
65 | .start = MSM_I2C_BASE, | ||
66 | .end = MSM_I2C_BASE + MSM_I2C_SIZE - 1, | ||
67 | .flags = IORESOURCE_MEM, | ||
68 | }, | ||
69 | { | ||
70 | .start = INT_PWB_I2C, | ||
71 | .end = INT_PWB_I2C, | ||
72 | .flags = IORESOURCE_IRQ, | ||
73 | }, | ||
74 | }; | ||
75 | |||
76 | static struct platform_device msm_i2c_device = { | ||
77 | .name = "msm_i2c", | ||
78 | .id = 0, | ||
79 | .num_resources = ARRAY_SIZE(msm_i2c_resources), | ||
80 | .resource = msm_i2c_resources, | ||
81 | }; | ||
82 | |||
83 | static struct resource usb_resources[] = { | ||
84 | { | ||
85 | .start = MSM_HSUSB_PHYS, | ||
86 | .end = MSM_HSUSB_PHYS + MSM_HSUSB_SIZE, | ||
87 | .flags = IORESOURCE_MEM, | ||
88 | }, | ||
89 | { | ||
90 | .start = INT_USB_HS, | ||
91 | .end = INT_USB_HS, | ||
92 | .flags = IORESOURCE_IRQ, | ||
93 | }, | ||
94 | }; | ||
95 | |||
96 | static struct platform_device msm_hsusb_device = { | ||
97 | .name = "msm_hsusb", | ||
98 | .id = -1, | ||
99 | .num_resources = ARRAY_SIZE(usb_resources), | ||
100 | .resource = usb_resources, | ||
101 | .dev = { | ||
102 | .coherent_dma_mask = 0xffffffff, | ||
103 | }, | ||
104 | }; | ||
105 | |||
106 | static struct platform_device *devices[] __initdata = { | ||
107 | &msm_nand_device, | ||
108 | &msm_smd_device, | ||
109 | &msm_i2c_device, | ||
110 | &msm_hsusb_device, | ||
111 | }; | ||
112 | |||
113 | void __init msm_add_devices(void) | ||
114 | { | ||
115 | platform_add_devices(devices, ARRAY_SIZE(devices)); | ||
116 | } | ||
diff --git a/arch/arm/mach-msm/devices.c b/arch/arm/mach-msm/devices.c new file mode 100644 index 000000000000..f2a74b92a97f --- /dev/null +++ b/arch/arm/mach-msm/devices.c | |||
@@ -0,0 +1,267 @@ | |||
1 | /* linux/arch/arm/mach-msm/devices.c | ||
2 | * | ||
3 | * Copyright (C) 2008 Google, Inc. | ||
4 | * | ||
5 | * This software is licensed under the terms of the GNU General Public | ||
6 | * License version 2, as published by the Free Software Foundation, and | ||
7 | * may be copied, distributed, and modified under those terms. | ||
8 | * | ||
9 | * This program is distributed in the hope that it will be useful, | ||
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | * GNU General Public License for more details. | ||
13 | * | ||
14 | */ | ||
15 | |||
16 | #include <linux/kernel.h> | ||
17 | #include <linux/platform_device.h> | ||
18 | |||
19 | #include <mach/msm_iomap.h> | ||
20 | #include "devices.h" | ||
21 | |||
22 | #include <asm/mach/flash.h> | ||
23 | #include <linux/mtd/nand.h> | ||
24 | #include <linux/mtd/partitions.h> | ||
25 | |||
26 | static struct resource resources_uart1[] = { | ||
27 | { | ||
28 | .start = INT_UART1, | ||
29 | .end = INT_UART1, | ||
30 | .flags = IORESOURCE_IRQ, | ||
31 | }, | ||
32 | { | ||
33 | .start = MSM_UART1_PHYS, | ||
34 | .end = MSM_UART1_PHYS + MSM_UART1_SIZE - 1, | ||
35 | .flags = IORESOURCE_MEM, | ||
36 | }, | ||
37 | }; | ||
38 | |||
39 | static struct resource resources_uart2[] = { | ||
40 | { | ||
41 | .start = INT_UART2, | ||
42 | .end = INT_UART2, | ||
43 | .flags = IORESOURCE_IRQ, | ||
44 | }, | ||
45 | { | ||
46 | .start = MSM_UART2_PHYS, | ||
47 | .end = MSM_UART2_PHYS + MSM_UART2_SIZE - 1, | ||
48 | .flags = IORESOURCE_MEM, | ||
49 | }, | ||
50 | }; | ||
51 | |||
52 | static struct resource resources_uart3[] = { | ||
53 | { | ||
54 | .start = INT_UART3, | ||
55 | .end = INT_UART3, | ||
56 | .flags = IORESOURCE_IRQ, | ||
57 | }, | ||
58 | { | ||
59 | .start = MSM_UART3_PHYS, | ||
60 | .end = MSM_UART3_PHYS + MSM_UART3_SIZE - 1, | ||
61 | .flags = IORESOURCE_MEM, | ||
62 | }, | ||
63 | }; | ||
64 | |||
65 | struct platform_device msm_device_uart1 = { | ||
66 | .name = "msm_serial", | ||
67 | .id = 0, | ||
68 | .num_resources = ARRAY_SIZE(resources_uart1), | ||
69 | .resource = resources_uart1, | ||
70 | }; | ||
71 | |||
72 | struct platform_device msm_device_uart2 = { | ||
73 | .name = "msm_serial", | ||
74 | .id = 1, | ||
75 | .num_resources = ARRAY_SIZE(resources_uart2), | ||
76 | .resource = resources_uart2, | ||
77 | }; | ||
78 | |||
79 | struct platform_device msm_device_uart3 = { | ||
80 | .name = "msm_serial", | ||
81 | .id = 2, | ||
82 | .num_resources = ARRAY_SIZE(resources_uart3), | ||
83 | .resource = resources_uart3, | ||
84 | }; | ||
85 | |||
86 | static struct resource resources_i2c[] = { | ||
87 | { | ||
88 | .start = MSM_I2C_PHYS, | ||
89 | .end = MSM_I2C_PHYS + MSM_I2C_SIZE - 1, | ||
90 | .flags = IORESOURCE_MEM, | ||
91 | }, | ||
92 | { | ||
93 | .start = INT_PWB_I2C, | ||
94 | .end = INT_PWB_I2C, | ||
95 | .flags = IORESOURCE_IRQ, | ||
96 | }, | ||
97 | }; | ||
98 | |||
99 | struct platform_device msm_device_i2c = { | ||
100 | .name = "msm_i2c", | ||
101 | .id = 0, | ||
102 | .num_resources = ARRAY_SIZE(resources_i2c), | ||
103 | .resource = resources_i2c, | ||
104 | }; | ||
105 | |||
106 | static struct resource resources_hsusb[] = { | ||
107 | { | ||
108 | .start = MSM_HSUSB_PHYS, | ||
109 | .end = MSM_HSUSB_PHYS + MSM_HSUSB_SIZE, | ||
110 | .flags = IORESOURCE_MEM, | ||
111 | }, | ||
112 | { | ||
113 | .start = INT_USB_HS, | ||
114 | .end = INT_USB_HS, | ||
115 | .flags = IORESOURCE_IRQ, | ||
116 | }, | ||
117 | }; | ||
118 | |||
119 | struct platform_device msm_device_hsusb = { | ||
120 | .name = "msm_hsusb", | ||
121 | .id = -1, | ||
122 | .num_resources = ARRAY_SIZE(resources_hsusb), | ||
123 | .resource = resources_hsusb, | ||
124 | .dev = { | ||
125 | .coherent_dma_mask = 0xffffffff, | ||
126 | }, | ||
127 | }; | ||
128 | |||
129 | struct flash_platform_data msm_nand_data = { | ||
130 | .parts = NULL, | ||
131 | .nr_parts = 0, | ||
132 | }; | ||
133 | |||
134 | static struct resource resources_nand[] = { | ||
135 | [0] = { | ||
136 | .start = 7, | ||
137 | .end = 7, | ||
138 | .flags = IORESOURCE_DMA, | ||
139 | }, | ||
140 | }; | ||
141 | |||
142 | struct platform_device msm_device_nand = { | ||
143 | .name = "msm_nand", | ||
144 | .id = -1, | ||
145 | .num_resources = ARRAY_SIZE(resources_nand), | ||
146 | .resource = resources_nand, | ||
147 | .dev = { | ||
148 | .platform_data = &msm_nand_data, | ||
149 | }, | ||
150 | }; | ||
151 | |||
152 | struct platform_device msm_device_smd = { | ||
153 | .name = "msm_smd", | ||
154 | .id = -1, | ||
155 | }; | ||
156 | |||
157 | static struct resource resources_sdc1[] = { | ||
158 | { | ||
159 | .start = MSM_SDC1_PHYS, | ||
160 | .end = MSM_SDC1_PHYS + MSM_SDC1_SIZE - 1, | ||
161 | .flags = IORESOURCE_MEM, | ||
162 | }, | ||
163 | { | ||
164 | .start = INT_SDC1_0, | ||
165 | .end = INT_SDC1_1, | ||
166 | .flags = IORESOURCE_IRQ, | ||
167 | }, | ||
168 | { | ||
169 | .start = 8, | ||
170 | .end = 8, | ||
171 | .flags = IORESOURCE_DMA, | ||
172 | }, | ||
173 | }; | ||
174 | |||
175 | static struct resource resources_sdc2[] = { | ||
176 | { | ||
177 | .start = MSM_SDC2_PHYS, | ||
178 | .end = MSM_SDC2_PHYS + MSM_SDC2_SIZE - 1, | ||
179 | .flags = IORESOURCE_MEM, | ||
180 | }, | ||
181 | { | ||
182 | .start = INT_SDC2_0, | ||
183 | .end = INT_SDC2_1, | ||
184 | .flags = IORESOURCE_IRQ, | ||
185 | }, | ||
186 | { | ||
187 | .start = 8, | ||
188 | .end = 8, | ||
189 | .flags = IORESOURCE_DMA, | ||
190 | }, | ||
191 | }; | ||
192 | |||
193 | static struct resource resources_sdc3[] = { | ||
194 | { | ||
195 | .start = MSM_SDC3_PHYS, | ||
196 | .end = MSM_SDC3_PHYS + MSM_SDC3_SIZE - 1, | ||
197 | .flags = IORESOURCE_MEM, | ||
198 | }, | ||
199 | { | ||
200 | .start = INT_SDC3_0, | ||
201 | .end = INT_SDC3_1, | ||
202 | .flags = IORESOURCE_IRQ, | ||
203 | }, | ||
204 | { | ||
205 | .start = 8, | ||
206 | .end = 8, | ||
207 | .flags = IORESOURCE_DMA, | ||
208 | }, | ||
209 | }; | ||
210 | |||
211 | static struct resource resources_sdc4[] = { | ||
212 | { | ||
213 | .start = MSM_SDC4_PHYS, | ||
214 | .end = MSM_SDC4_PHYS + MSM_SDC4_SIZE - 1, | ||
215 | .flags = IORESOURCE_MEM, | ||
216 | }, | ||
217 | { | ||
218 | .start = INT_SDC4_0, | ||
219 | .end = INT_SDC4_1, | ||
220 | .flags = IORESOURCE_IRQ, | ||
221 | }, | ||
222 | { | ||
223 | .start = 8, | ||
224 | .end = 8, | ||
225 | .flags = IORESOURCE_DMA, | ||
226 | }, | ||
227 | }; | ||
228 | |||
229 | struct platform_device msm_device_sdc1 = { | ||
230 | .name = "msm_sdcc", | ||
231 | .id = 1, | ||
232 | .num_resources = ARRAY_SIZE(resources_sdc1), | ||
233 | .resource = resources_sdc1, | ||
234 | .dev = { | ||
235 | .coherent_dma_mask = 0xffffffff, | ||
236 | }, | ||
237 | }; | ||
238 | |||
239 | struct platform_device msm_device_sdc2 = { | ||
240 | .name = "msm_sdcc", | ||
241 | .id = 2, | ||
242 | .num_resources = ARRAY_SIZE(resources_sdc2), | ||
243 | .resource = resources_sdc2, | ||
244 | .dev = { | ||
245 | .coherent_dma_mask = 0xffffffff, | ||
246 | }, | ||
247 | }; | ||
248 | |||
249 | struct platform_device msm_device_sdc3 = { | ||
250 | .name = "msm_sdcc", | ||
251 | .id = 3, | ||
252 | .num_resources = ARRAY_SIZE(resources_sdc3), | ||
253 | .resource = resources_sdc3, | ||
254 | .dev = { | ||
255 | .coherent_dma_mask = 0xffffffff, | ||
256 | }, | ||
257 | }; | ||
258 | |||
259 | struct platform_device msm_device_sdc4 = { | ||
260 | .name = "msm_sdcc", | ||
261 | .id = 4, | ||
262 | .num_resources = ARRAY_SIZE(resources_sdc4), | ||
263 | .resource = resources_sdc4, | ||
264 | .dev = { | ||
265 | .coherent_dma_mask = 0xffffffff, | ||
266 | }, | ||
267 | }; | ||
diff --git a/arch/arm/mach-msm/devices.h b/arch/arm/mach-msm/devices.h new file mode 100644 index 000000000000..0744c4a27d6a --- /dev/null +++ b/arch/arm/mach-msm/devices.h | |||
@@ -0,0 +1,36 @@ | |||
1 | /* linux/arch/arm/mach-msm/devices.h | ||
2 | * | ||
3 | * Copyright (C) 2008 Google, Inc. | ||
4 | * | ||
5 | * This software is licensed under the terms of the GNU General Public | ||
6 | * License version 2, as published by the Free Software Foundation, and | ||
7 | * may be copied, distributed, and modified under those terms. | ||
8 | * | ||
9 | * This program is distributed in the hope that it will be useful, | ||
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | * GNU General Public License for more details. | ||
13 | * | ||
14 | */ | ||
15 | |||
16 | #ifndef __ARCH_ARM_MACH_MSM_DEVICES_H | ||
17 | #define __ARCH_ARM_MACH_MSM_DEVICES_H | ||
18 | |||
19 | extern struct platform_device msm_device_uart1; | ||
20 | extern struct platform_device msm_device_uart2; | ||
21 | extern struct platform_device msm_device_uart3; | ||
22 | |||
23 | extern struct platform_device msm_device_sdc1; | ||
24 | extern struct platform_device msm_device_sdc2; | ||
25 | extern struct platform_device msm_device_sdc3; | ||
26 | extern struct platform_device msm_device_sdc4; | ||
27 | |||
28 | extern struct platform_device msm_device_hsusb; | ||
29 | |||
30 | extern struct platform_device msm_device_i2c; | ||
31 | |||
32 | extern struct platform_device msm_device_smd; | ||
33 | |||
34 | extern struct platform_device msm_device_nand; | ||
35 | |||
36 | #endif | ||
diff --git a/arch/arm/mach-msm/dma.c b/arch/arm/mach-msm/dma.c index 0c8f252637e1..f5420f9585c5 100644 --- a/arch/arm/mach-msm/dma.c +++ b/arch/arm/mach-msm/dma.c | |||
@@ -26,7 +26,7 @@ enum { | |||
26 | }; | 26 | }; |
27 | 27 | ||
28 | static DEFINE_SPINLOCK(msm_dmov_lock); | 28 | static DEFINE_SPINLOCK(msm_dmov_lock); |
29 | static struct msm_dmov_cmd active_command; | 29 | static unsigned int channel_active; |
30 | static struct list_head ready_commands[MSM_DMOV_CHANNEL_COUNT]; | 30 | static struct list_head ready_commands[MSM_DMOV_CHANNEL_COUNT]; |
31 | static struct list_head active_commands[MSM_DMOV_CHANNEL_COUNT]; | 31 | static struct list_head active_commands[MSM_DMOV_CHANNEL_COUNT]; |
32 | unsigned int msm_dmov_print_mask = MSM_DMOV_PRINT_ERRORS; | 32 | unsigned int msm_dmov_print_mask = MSM_DMOV_PRINT_ERRORS; |
@@ -43,6 +43,11 @@ unsigned int msm_dmov_print_mask = MSM_DMOV_PRINT_ERRORS; | |||
43 | #define PRINT_FLOW(format, args...) \ | 43 | #define PRINT_FLOW(format, args...) \ |
44 | MSM_DMOV_DPRINTF(MSM_DMOV_PRINT_FLOW, format, args); | 44 | MSM_DMOV_DPRINTF(MSM_DMOV_PRINT_FLOW, format, args); |
45 | 45 | ||
46 | void msm_dmov_stop_cmd(unsigned id, struct msm_dmov_cmd *cmd, int graceful) | ||
47 | { | ||
48 | writel((graceful << 31), DMOV_FLUSH0(id)); | ||
49 | } | ||
50 | |||
46 | void msm_dmov_enqueue_cmd(unsigned id, struct msm_dmov_cmd *cmd) | 51 | void msm_dmov_enqueue_cmd(unsigned id, struct msm_dmov_cmd *cmd) |
47 | { | 52 | { |
48 | unsigned long irq_flags; | 53 | unsigned long irq_flags; |
@@ -60,6 +65,9 @@ void msm_dmov_enqueue_cmd(unsigned id, struct msm_dmov_cmd *cmd) | |||
60 | #endif | 65 | #endif |
61 | PRINT_IO("msm_dmov_enqueue_cmd(%d), start command, status %x\n", id, status); | 66 | PRINT_IO("msm_dmov_enqueue_cmd(%d), start command, status %x\n", id, status); |
62 | list_add_tail(&cmd->list, &active_commands[id]); | 67 | list_add_tail(&cmd->list, &active_commands[id]); |
68 | if (!channel_active) | ||
69 | enable_irq(INT_ADM_AARM); | ||
70 | channel_active |= 1U << id; | ||
63 | writel(cmd->cmdptr, DMOV_CMD_PTR(id)); | 71 | writel(cmd->cmdptr, DMOV_CMD_PTR(id)); |
64 | } else { | 72 | } else { |
65 | if (list_empty(&active_commands[id])) | 73 | if (list_empty(&active_commands[id])) |
@@ -76,21 +84,19 @@ struct msm_dmov_exec_cmdptr_cmd { | |||
76 | struct completion complete; | 84 | struct completion complete; |
77 | unsigned id; | 85 | unsigned id; |
78 | unsigned int result; | 86 | unsigned int result; |
79 | unsigned int flush[6]; | 87 | struct msm_dmov_errdata err; |
80 | }; | 88 | }; |
81 | 89 | ||
82 | static void dmov_exec_cmdptr_complete_func(struct msm_dmov_cmd *_cmd, unsigned int result) | 90 | static void |
91 | dmov_exec_cmdptr_complete_func(struct msm_dmov_cmd *_cmd, | ||
92 | unsigned int result, | ||
93 | struct msm_dmov_errdata *err) | ||
83 | { | 94 | { |
84 | struct msm_dmov_exec_cmdptr_cmd *cmd = container_of(_cmd, struct msm_dmov_exec_cmdptr_cmd, dmov_cmd); | 95 | struct msm_dmov_exec_cmdptr_cmd *cmd = container_of(_cmd, struct msm_dmov_exec_cmdptr_cmd, dmov_cmd); |
85 | cmd->result = result; | 96 | cmd->result = result; |
86 | if (result != 0x80000002) { | 97 | if (result != 0x80000002 && err) |
87 | cmd->flush[0] = readl(DMOV_FLUSH0(cmd->id)); | 98 | memcpy(&cmd->err, err, sizeof(struct msm_dmov_errdata)); |
88 | cmd->flush[1] = readl(DMOV_FLUSH1(cmd->id)); | 99 | |
89 | cmd->flush[2] = readl(DMOV_FLUSH2(cmd->id)); | ||
90 | cmd->flush[3] = readl(DMOV_FLUSH3(cmd->id)); | ||
91 | cmd->flush[4] = readl(DMOV_FLUSH4(cmd->id)); | ||
92 | cmd->flush[5] = readl(DMOV_FLUSH5(cmd->id)); | ||
93 | } | ||
94 | complete(&cmd->complete); | 100 | complete(&cmd->complete); |
95 | } | 101 | } |
96 | 102 | ||
@@ -111,7 +117,7 @@ int msm_dmov_exec_cmd(unsigned id, unsigned int cmdptr) | |||
111 | if (cmd.result != 0x80000002) { | 117 | if (cmd.result != 0x80000002) { |
112 | PRINT_ERROR("dmov_exec_cmdptr(%d): ERROR, result: %x\n", id, cmd.result); | 118 | PRINT_ERROR("dmov_exec_cmdptr(%d): ERROR, result: %x\n", id, cmd.result); |
113 | PRINT_ERROR("dmov_exec_cmdptr(%d): flush: %x %x %x %x\n", | 119 | PRINT_ERROR("dmov_exec_cmdptr(%d): flush: %x %x %x %x\n", |
114 | id, cmd.flush[0], cmd.flush[1], cmd.flush[2], cmd.flush[3]); | 120 | id, cmd.err.flush[0], cmd.err.flush[1], cmd.err.flush[2], cmd.err.flush[3]); |
115 | return -EIO; | 121 | return -EIO; |
116 | } | 122 | } |
117 | PRINT_FLOW("dmov_exec_cmdptr(%d, %x) done\n", id, cmdptr); | 123 | PRINT_FLOW("dmov_exec_cmdptr(%d, %x) done\n", id, cmdptr); |
@@ -159,25 +165,40 @@ static irqreturn_t msm_datamover_irq_handler(int irq, void *dev_id) | |||
159 | "for %p, result %x\n", id, cmd, ch_result); | 165 | "for %p, result %x\n", id, cmd, ch_result); |
160 | if (cmd) { | 166 | if (cmd) { |
161 | list_del(&cmd->list); | 167 | list_del(&cmd->list); |
162 | cmd->complete_func(cmd, ch_result); | 168 | cmd->complete_func(cmd, ch_result, NULL); |
163 | } | 169 | } |
164 | } | 170 | } |
165 | if (ch_result & DMOV_RSLT_FLUSH) { | 171 | if (ch_result & DMOV_RSLT_FLUSH) { |
166 | unsigned int flush0 = readl(DMOV_FLUSH0(id)); | 172 | struct msm_dmov_errdata errdata; |
173 | |||
174 | errdata.flush[0] = readl(DMOV_FLUSH0(id)); | ||
175 | errdata.flush[1] = readl(DMOV_FLUSH1(id)); | ||
176 | errdata.flush[2] = readl(DMOV_FLUSH2(id)); | ||
177 | errdata.flush[3] = readl(DMOV_FLUSH3(id)); | ||
178 | errdata.flush[4] = readl(DMOV_FLUSH4(id)); | ||
179 | errdata.flush[5] = readl(DMOV_FLUSH5(id)); | ||
167 | PRINT_FLOW("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); | 180 | PRINT_FLOW("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); |
168 | PRINT_FLOW("msm_datamover_irq_handler id %d, flush, result %x, flush0 %x\n", id, ch_result, flush0); | 181 | PRINT_FLOW("msm_datamover_irq_handler id %d, flush, result %x, flush0 %x\n", id, ch_result, errdata.flush[0]); |
169 | if (cmd) { | 182 | if (cmd) { |
170 | list_del(&cmd->list); | 183 | list_del(&cmd->list); |
171 | cmd->complete_func(cmd, ch_result); | 184 | cmd->complete_func(cmd, ch_result, &errdata); |
172 | } | 185 | } |
173 | } | 186 | } |
174 | if (ch_result & DMOV_RSLT_ERROR) { | 187 | if (ch_result & DMOV_RSLT_ERROR) { |
175 | unsigned int flush0 = readl(DMOV_FLUSH0(id)); | 188 | struct msm_dmov_errdata errdata; |
189 | |||
190 | errdata.flush[0] = readl(DMOV_FLUSH0(id)); | ||
191 | errdata.flush[1] = readl(DMOV_FLUSH1(id)); | ||
192 | errdata.flush[2] = readl(DMOV_FLUSH2(id)); | ||
193 | errdata.flush[3] = readl(DMOV_FLUSH3(id)); | ||
194 | errdata.flush[4] = readl(DMOV_FLUSH4(id)); | ||
195 | errdata.flush[5] = readl(DMOV_FLUSH5(id)); | ||
196 | |||
176 | PRINT_ERROR("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); | 197 | PRINT_ERROR("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); |
177 | PRINT_ERROR("msm_datamover_irq_handler id %d, error, result %x, flush0 %x\n", id, ch_result, flush0); | 198 | PRINT_ERROR("msm_datamover_irq_handler id %d, error, result %x, flush0 %x\n", id, ch_result, errdata.flush[0]); |
178 | if (cmd) { | 199 | if (cmd) { |
179 | list_del(&cmd->list); | 200 | list_del(&cmd->list); |
180 | cmd->complete_func(cmd, ch_result); | 201 | cmd->complete_func(cmd, ch_result, &errdata); |
181 | } | 202 | } |
182 | /* this does not seem to work, once we get an error */ | 203 | /* this does not seem to work, once we get an error */ |
183 | /* the datamover will no longer accept commands */ | 204 | /* the datamover will no longer accept commands */ |
@@ -193,8 +214,14 @@ static irqreturn_t msm_datamover_irq_handler(int irq, void *dev_id) | |||
193 | writel(cmd->cmdptr, DMOV_CMD_PTR(id)); | 214 | writel(cmd->cmdptr, DMOV_CMD_PTR(id)); |
194 | } | 215 | } |
195 | } while (ch_status & DMOV_STATUS_RSLT_VALID); | 216 | } while (ch_status & DMOV_STATUS_RSLT_VALID); |
217 | if (list_empty(&active_commands[id]) && list_empty(&ready_commands[id])) | ||
218 | channel_active &= ~(1U << id); | ||
196 | PRINT_FLOW("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); | 219 | PRINT_FLOW("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); |
197 | } | 220 | } |
221 | |||
222 | if (!channel_active) | ||
223 | disable_irq(INT_ADM_AARM); | ||
224 | |||
198 | spin_unlock_irqrestore(&msm_dmov_lock, irq_flags); | 225 | spin_unlock_irqrestore(&msm_dmov_lock, irq_flags); |
199 | return IRQ_HANDLED; | 226 | return IRQ_HANDLED; |
200 | } | 227 | } |
@@ -202,12 +229,17 @@ static irqreturn_t msm_datamover_irq_handler(int irq, void *dev_id) | |||
202 | static int __init msm_init_datamover(void) | 229 | static int __init msm_init_datamover(void) |
203 | { | 230 | { |
204 | int i; | 231 | int i; |
232 | int ret; | ||
205 | for (i = 0; i < MSM_DMOV_CHANNEL_COUNT; i++) { | 233 | for (i = 0; i < MSM_DMOV_CHANNEL_COUNT; i++) { |
206 | INIT_LIST_HEAD(&ready_commands[i]); | 234 | INIT_LIST_HEAD(&ready_commands[i]); |
207 | INIT_LIST_HEAD(&active_commands[i]); | 235 | INIT_LIST_HEAD(&active_commands[i]); |
208 | writel(DMOV_CONFIG_IRQ_EN | DMOV_CONFIG_FORCE_TOP_PTR_RSLT | DMOV_CONFIG_FORCE_FLUSH_RSLT, DMOV_CONFIG(i)); | 236 | writel(DMOV_CONFIG_IRQ_EN | DMOV_CONFIG_FORCE_TOP_PTR_RSLT | DMOV_CONFIG_FORCE_FLUSH_RSLT, DMOV_CONFIG(i)); |
209 | } | 237 | } |
210 | return request_irq(INT_ADM_AARM, msm_datamover_irq_handler, 0, "msmdatamover", NULL); | 238 | ret = request_irq(INT_ADM_AARM, msm_datamover_irq_handler, 0, "msmdatamover", NULL); |
239 | if (ret) | ||
240 | return ret; | ||
241 | disable_irq(INT_ADM_AARM); | ||
242 | return 0; | ||
211 | } | 243 | } |
212 | 244 | ||
213 | arch_initcall(msm_init_datamover); | 245 | arch_initcall(msm_init_datamover); |
diff --git a/arch/arm/mach-msm/include/mach/board.h b/arch/arm/mach-msm/include/mach/board.h index a7639493c095..264d62e519f3 100644 --- a/arch/arm/mach-msm/include/mach/board.h +++ b/arch/arm/mach-msm/include/mach/board.h | |||
@@ -33,5 +33,6 @@ void __init msm_add_devices(void); | |||
33 | void __init msm_map_common_io(void); | 33 | void __init msm_map_common_io(void); |
34 | void __init msm_init_irq(void); | 34 | void __init msm_init_irq(void); |
35 | void __init msm_init_gpio(void); | 35 | void __init msm_init_gpio(void); |
36 | void __init msm_clock_init(void); | ||
36 | 37 | ||
37 | #endif | 38 | #endif |
diff --git a/arch/arm/mach-msm/include/mach/debug-macro.S b/arch/arm/mach-msm/include/mach/debug-macro.S index 528eef4b605c..1db3c97dbc49 100644 --- a/arch/arm/mach-msm/include/mach/debug-macro.S +++ b/arch/arm/mach-msm/include/mach/debug-macro.S | |||
@@ -22,18 +22,22 @@ | |||
22 | mrc p15, 0, \rx, c1, c0 | 22 | mrc p15, 0, \rx, c1, c0 |
23 | tst \rx, #1 | 23 | tst \rx, #1 |
24 | ldreq \rx, =MSM_UART1_PHYS | 24 | ldreq \rx, =MSM_UART1_PHYS |
25 | ldrne \rx, =MSM_UART1_BASE | 25 | movne \rx, #0 |
26 | .endm | 26 | .endm |
27 | 27 | ||
28 | .macro senduart,rd,rx | 28 | .macro senduart,rd,rx |
29 | str \rd, [\rx, #0x0C] | 29 | teq \rx, #0 |
30 | strne \rd, [\rx, #0x0C] | ||
30 | .endm | 31 | .endm |
31 | 32 | ||
32 | .macro waituart,rd,rx | 33 | .macro waituart,rd,rx |
33 | @ wait for TX_READY | 34 | @ wait for TX_READY |
35 | teq \rx, #0 | ||
36 | bne 2f | ||
34 | 1: ldr \rd, [\rx, #0x08] | 37 | 1: ldr \rd, [\rx, #0x08] |
35 | tst \rd, #0x04 | 38 | tst \rd, #0x04 |
36 | beq 1b | 39 | beq 1b |
40 | 2: | ||
37 | .endm | 41 | .endm |
38 | 42 | ||
39 | .macro busyuart,rd,rx | 43 | .macro busyuart,rd,rx |
diff --git a/arch/arm/mach-msm/include/mach/dma.h b/arch/arm/mach-msm/include/mach/dma.h index ad1c87f86d10..5ab5bdffab07 100644 --- a/arch/arm/mach-msm/include/mach/dma.h +++ b/arch/arm/mach-msm/include/mach/dma.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* arch/arm/mach-msm/include/mach/dma.h | 1 | /* linux/include/asm-arm/arch-msm/dma.h |
2 | * | 2 | * |
3 | * Copyright (C) 2007 Google, Inc. | 3 | * Copyright (C) 2007 Google, Inc. |
4 | * | 4 | * |
@@ -18,17 +18,21 @@ | |||
18 | #include <linux/list.h> | 18 | #include <linux/list.h> |
19 | #include <mach/msm_iomap.h> | 19 | #include <mach/msm_iomap.h> |
20 | 20 | ||
21 | struct msm_dmov_errdata { | ||
22 | uint32_t flush[6]; | ||
23 | }; | ||
24 | |||
21 | struct msm_dmov_cmd { | 25 | struct msm_dmov_cmd { |
22 | struct list_head list; | 26 | struct list_head list; |
23 | unsigned int cmdptr; | 27 | unsigned int cmdptr; |
24 | void (*complete_func)(struct msm_dmov_cmd *cmd, unsigned int result); | 28 | void (*complete_func)(struct msm_dmov_cmd *cmd, |
25 | /* void (*user_result_func)(struct msm_dmov_cmd *cmd); */ | 29 | unsigned int result, |
30 | struct msm_dmov_errdata *err); | ||
26 | }; | 31 | }; |
27 | 32 | ||
28 | void msm_dmov_enqueue_cmd(unsigned id, struct msm_dmov_cmd *cmd); | 33 | void msm_dmov_enqueue_cmd(unsigned id, struct msm_dmov_cmd *cmd); |
29 | void msm_dmov_stop_cmd(unsigned id, struct msm_dmov_cmd *cmd); | 34 | void msm_dmov_stop_cmd(unsigned id, struct msm_dmov_cmd *cmd, int graceful); |
30 | int msm_dmov_exec_cmd(unsigned id, unsigned int cmdptr); | 35 | int msm_dmov_exec_cmd(unsigned id, unsigned int cmdptr); |
31 | /* int msm_dmov_exec_cmd_etc(unsigned id, unsigned int cmdptr, int timeout, int interruptible); */ | ||
32 | 36 | ||
33 | 37 | ||
34 | 38 | ||
@@ -122,6 +126,16 @@ typedef struct { | |||
122 | unsigned _reserved; | 126 | unsigned _reserved; |
123 | } dmov_sg; | 127 | } dmov_sg; |
124 | 128 | ||
129 | /* Box mode */ | ||
130 | typedef struct { | ||
131 | uint32_t cmd; | ||
132 | uint32_t src_row_addr; | ||
133 | uint32_t dst_row_addr; | ||
134 | uint32_t src_dst_len; | ||
135 | uint32_t num_rows; | ||
136 | uint32_t row_offset; | ||
137 | } dmov_box; | ||
138 | |||
125 | /* bits for the cmd field of the above structures */ | 139 | /* bits for the cmd field of the above structures */ |
126 | 140 | ||
127 | #define CMD_LC (1 << 31) /* last command */ | 141 | #define CMD_LC (1 << 31) /* last command */ |
diff --git a/arch/arm/mach-msm/include/mach/msm_iomap.h b/arch/arm/mach-msm/include/mach/msm_iomap.h index e221f58ceea3..2f7b4c8620d9 100644 --- a/arch/arm/mach-msm/include/mach/msm_iomap.h +++ b/arch/arm/mach-msm/include/mach/msm_iomap.h | |||
@@ -37,11 +37,17 @@ | |||
37 | * | 37 | * |
38 | */ | 38 | */ |
39 | 39 | ||
40 | #define MSM_VIC_BASE 0xE0000000 | 40 | #ifdef __ASSEMBLY__ |
41 | #define IOMEM(x) x | ||
42 | #else | ||
43 | #define IOMEM(x) ((void __force __iomem *)(x)) | ||
44 | #endif | ||
45 | |||
46 | #define MSM_VIC_BASE IOMEM(0xE0000000) | ||
41 | #define MSM_VIC_PHYS 0xC0000000 | 47 | #define MSM_VIC_PHYS 0xC0000000 |
42 | #define MSM_VIC_SIZE SZ_4K | 48 | #define MSM_VIC_SIZE SZ_4K |
43 | 49 | ||
44 | #define MSM_CSR_BASE 0xE0001000 | 50 | #define MSM_CSR_BASE IOMEM(0xE0001000) |
45 | #define MSM_CSR_PHYS 0xC0100000 | 51 | #define MSM_CSR_PHYS 0xC0100000 |
46 | #define MSM_CSR_SIZE SZ_4K | 52 | #define MSM_CSR_SIZE SZ_4K |
47 | 53 | ||
@@ -49,56 +55,67 @@ | |||
49 | #define MSM_GPT_BASE MSM_CSR_BASE | 55 | #define MSM_GPT_BASE MSM_CSR_BASE |
50 | #define MSM_GPT_SIZE SZ_4K | 56 | #define MSM_GPT_SIZE SZ_4K |
51 | 57 | ||
52 | #define MSM_DMOV_BASE 0xE0002000 | 58 | #define MSM_DMOV_BASE IOMEM(0xE0002000) |
53 | #define MSM_DMOV_PHYS 0xA9700000 | 59 | #define MSM_DMOV_PHYS 0xA9700000 |
54 | #define MSM_DMOV_SIZE SZ_4K | 60 | #define MSM_DMOV_SIZE SZ_4K |
55 | 61 | ||
56 | #define MSM_UART1_BASE 0xE0003000 | 62 | #define MSM_GPIO1_BASE IOMEM(0xE0003000) |
63 | #define MSM_GPIO1_PHYS 0xA9200000 | ||
64 | #define MSM_GPIO1_SIZE SZ_4K | ||
65 | |||
66 | #define MSM_GPIO2_BASE IOMEM(0xE0004000) | ||
67 | #define MSM_GPIO2_PHYS 0xA9300000 | ||
68 | #define MSM_GPIO2_SIZE SZ_4K | ||
69 | |||
70 | #define MSM_CLK_CTL_BASE IOMEM(0xE0005000) | ||
71 | #define MSM_CLK_CTL_PHYS 0xA8600000 | ||
72 | #define MSM_CLK_CTL_SIZE SZ_4K | ||
73 | |||
74 | #define MSM_SHARED_RAM_BASE IOMEM(0xE0100000) | ||
75 | #define MSM_SHARED_RAM_PHYS 0x01F00000 | ||
76 | #define MSM_SHARED_RAM_SIZE SZ_1M | ||
77 | |||
57 | #define MSM_UART1_PHYS 0xA9A00000 | 78 | #define MSM_UART1_PHYS 0xA9A00000 |
58 | #define MSM_UART1_SIZE SZ_4K | 79 | #define MSM_UART1_SIZE SZ_4K |
59 | 80 | ||
60 | #define MSM_UART2_BASE 0xE0004000 | ||
61 | #define MSM_UART2_PHYS 0xA9B00000 | 81 | #define MSM_UART2_PHYS 0xA9B00000 |
62 | #define MSM_UART2_SIZE SZ_4K | 82 | #define MSM_UART2_SIZE SZ_4K |
63 | 83 | ||
64 | #define MSM_UART3_BASE 0xE0005000 | ||
65 | #define MSM_UART3_PHYS 0xA9C00000 | 84 | #define MSM_UART3_PHYS 0xA9C00000 |
66 | #define MSM_UART3_SIZE SZ_4K | 85 | #define MSM_UART3_SIZE SZ_4K |
67 | 86 | ||
68 | #define MSM_I2C_BASE 0xE0006000 | 87 | #define MSM_SDC1_PHYS 0xA0400000 |
69 | #define MSM_I2C_PHYS 0xA9900000 | 88 | #define MSM_SDC1_SIZE SZ_4K |
70 | #define MSM_I2C_SIZE SZ_4K | ||
71 | 89 | ||
72 | #define MSM_GPIO1_BASE 0xE0007000 | 90 | #define MSM_SDC2_PHYS 0xA0500000 |
73 | #define MSM_GPIO1_PHYS 0xA9200000 | 91 | #define MSM_SDC2_SIZE SZ_4K |
74 | #define MSM_GPIO1_SIZE SZ_4K | ||
75 | 92 | ||
76 | #define MSM_GPIO2_BASE 0xE0008000 | 93 | #define MSM_SDC3_PHYS 0xA0600000 |
77 | #define MSM_GPIO2_PHYS 0xA9300000 | 94 | #define MSM_SDC3_SIZE SZ_4K |
78 | #define MSM_GPIO2_SIZE SZ_4K | 95 | |
96 | #define MSM_SDC4_PHYS 0xA0700000 | ||
97 | #define MSM_SDC4_SIZE SZ_4K | ||
98 | |||
99 | #define MSM_I2C_PHYS 0xA9900000 | ||
100 | #define MSM_I2C_SIZE SZ_4K | ||
79 | 101 | ||
80 | #define MSM_HSUSB_BASE 0xE0009000 | ||
81 | #define MSM_HSUSB_PHYS 0xA0800000 | 102 | #define MSM_HSUSB_PHYS 0xA0800000 |
82 | #define MSM_HSUSB_SIZE SZ_4K | 103 | #define MSM_HSUSB_SIZE SZ_4K |
83 | 104 | ||
84 | #define MSM_CLK_CTL_BASE 0xE000A000 | ||
85 | #define MSM_CLK_CTL_PHYS 0xA8600000 | ||
86 | #define MSM_CLK_CTL_SIZE SZ_4K | ||
87 | |||
88 | #define MSM_PMDH_BASE 0xE000B000 | ||
89 | #define MSM_PMDH_PHYS 0xAA600000 | 105 | #define MSM_PMDH_PHYS 0xAA600000 |
90 | #define MSM_PMDH_SIZE SZ_4K | 106 | #define MSM_PMDH_SIZE SZ_4K |
91 | 107 | ||
92 | #define MSM_EMDH_BASE 0xE000C000 | ||
93 | #define MSM_EMDH_PHYS 0xAA700000 | 108 | #define MSM_EMDH_PHYS 0xAA700000 |
94 | #define MSM_EMDH_SIZE SZ_4K | 109 | #define MSM_EMDH_SIZE SZ_4K |
95 | 110 | ||
96 | #define MSM_MDP_BASE 0xE0010000 | ||
97 | #define MSM_MDP_PHYS 0xAA200000 | 111 | #define MSM_MDP_PHYS 0xAA200000 |
98 | #define MSM_MDP_SIZE 0x000F0000 | 112 | #define MSM_MDP_SIZE 0x000F0000 |
99 | 113 | ||
100 | #define MSM_SHARED_RAM_BASE 0xE0100000 | 114 | #define MSM_MDC_PHYS 0xAA500000 |
101 | #define MSM_SHARED_RAM_PHYS 0x01F00000 | 115 | #define MSM_MDC_SIZE SZ_1M |
102 | #define MSM_SHARED_RAM_SIZE SZ_1M | 116 | |
117 | #define MSM_AD5_PHYS 0xAC000000 | ||
118 | #define MSM_AD5_SIZE (SZ_1M*13) | ||
119 | |||
103 | 120 | ||
104 | #endif | 121 | #endif |
diff --git a/arch/arm/mach-msm/include/mach/vreg.h b/arch/arm/mach-msm/include/mach/vreg.h new file mode 100644 index 000000000000..9f9e25cb718e --- /dev/null +++ b/arch/arm/mach-msm/include/mach/vreg.h | |||
@@ -0,0 +1,29 @@ | |||
1 | /* linux/include/asm-arm/arch-msm/vreg.h | ||
2 | * | ||
3 | * Copyright (C) 2008 Google, Inc. | ||
4 | * Author: Brian Swetland <swetland@google.com> | ||
5 | * | ||
6 | * This software is licensed under the terms of the GNU General Public | ||
7 | * License version 2, as published by the Free Software Foundation, and | ||
8 | * may be copied, distributed, and modified under those terms. | ||
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 | */ | ||
16 | |||
17 | #ifndef __ARCH_ARM_MACH_MSM_VREG_H | ||
18 | #define __ARCH_ARM_MACH_MSM_VREG_H | ||
19 | |||
20 | struct vreg; | ||
21 | |||
22 | struct vreg *vreg_get(struct device *dev, const char *id); | ||
23 | void vreg_put(struct vreg *vreg); | ||
24 | |||
25 | int vreg_enable(struct vreg *vreg); | ||
26 | void vreg_disable(struct vreg *vreg); | ||
27 | int vreg_set_level(struct vreg *vreg, unsigned mv); | ||
28 | |||
29 | #endif | ||
diff --git a/arch/arm/mach-msm/io.c b/arch/arm/mach-msm/io.c index 7999e4ba8e20..6e7692ff6f2c 100644 --- a/arch/arm/mach-msm/io.c +++ b/arch/arm/mach-msm/io.c | |||
@@ -28,7 +28,7 @@ | |||
28 | #include <mach/board.h> | 28 | #include <mach/board.h> |
29 | 29 | ||
30 | #define MSM_DEVICE(name) { \ | 30 | #define MSM_DEVICE(name) { \ |
31 | .virtual = MSM_##name##_BASE, \ | 31 | .virtual = (unsigned long) MSM_##name##_BASE, \ |
32 | .pfn = __phys_to_pfn(MSM_##name##_PHYS), \ | 32 | .pfn = __phys_to_pfn(MSM_##name##_PHYS), \ |
33 | .length = MSM_##name##_SIZE, \ | 33 | .length = MSM_##name##_SIZE, \ |
34 | .type = MT_DEVICE_NONSHARED, \ | 34 | .type = MT_DEVICE_NONSHARED, \ |
@@ -39,19 +39,11 @@ static struct map_desc msm_io_desc[] __initdata = { | |||
39 | MSM_DEVICE(CSR), | 39 | MSM_DEVICE(CSR), |
40 | MSM_DEVICE(GPT), | 40 | MSM_DEVICE(GPT), |
41 | MSM_DEVICE(DMOV), | 41 | MSM_DEVICE(DMOV), |
42 | MSM_DEVICE(UART1), | ||
43 | MSM_DEVICE(UART2), | ||
44 | MSM_DEVICE(UART3), | ||
45 | MSM_DEVICE(I2C), | ||
46 | MSM_DEVICE(GPIO1), | 42 | MSM_DEVICE(GPIO1), |
47 | MSM_DEVICE(GPIO2), | 43 | MSM_DEVICE(GPIO2), |
48 | MSM_DEVICE(HSUSB), | ||
49 | MSM_DEVICE(CLK_CTL), | 44 | MSM_DEVICE(CLK_CTL), |
50 | MSM_DEVICE(PMDH), | ||
51 | MSM_DEVICE(EMDH), | ||
52 | MSM_DEVICE(MDP), | ||
53 | { | 45 | { |
54 | .virtual = MSM_SHARED_RAM_BASE, | 46 | .virtual = (unsigned long) MSM_SHARED_RAM_BASE, |
55 | .pfn = __phys_to_pfn(MSM_SHARED_RAM_PHYS), | 47 | .pfn = __phys_to_pfn(MSM_SHARED_RAM_PHYS), |
56 | .length = MSM_SHARED_RAM_SIZE, | 48 | .length = MSM_SHARED_RAM_SIZE, |
57 | .type = MT_DEVICE, | 49 | .type = MT_DEVICE, |
diff --git a/arch/arm/mach-msm/irq.c b/arch/arm/mach-msm/irq.c index 04b8d182ff8a..69ca0dd79bdf 100644 --- a/arch/arm/mach-msm/irq.c +++ b/arch/arm/mach-msm/irq.c | |||
@@ -66,20 +66,20 @@ | |||
66 | 66 | ||
67 | static void msm_irq_ack(unsigned int irq) | 67 | static void msm_irq_ack(unsigned int irq) |
68 | { | 68 | { |
69 | unsigned reg = VIC_INT_CLEAR0 + ((irq & 32) ? 4 : 0); | 69 | void __iomem *reg = VIC_INT_CLEAR0 + ((irq & 32) ? 4 : 0); |
70 | irq = 1 << (irq & 31); | 70 | irq = 1 << (irq & 31); |
71 | writel(irq, reg); | 71 | writel(irq, reg); |
72 | } | 72 | } |
73 | 73 | ||
74 | static void msm_irq_mask(unsigned int irq) | 74 | static void msm_irq_mask(unsigned int irq) |
75 | { | 75 | { |
76 | unsigned reg = VIC_INT_ENCLEAR0 + ((irq & 32) ? 4 : 0); | 76 | void __iomem *reg = VIC_INT_ENCLEAR0 + ((irq & 32) ? 4 : 0); |
77 | writel(1 << (irq & 31), reg); | 77 | writel(1 << (irq & 31), reg); |
78 | } | 78 | } |
79 | 79 | ||
80 | static void msm_irq_unmask(unsigned int irq) | 80 | static void msm_irq_unmask(unsigned int irq) |
81 | { | 81 | { |
82 | unsigned reg = VIC_INT_ENSET0 + ((irq & 32) ? 4 : 0); | 82 | void __iomem *reg = VIC_INT_ENSET0 + ((irq & 32) ? 4 : 0); |
83 | writel(1 << (irq & 31), reg); | 83 | writel(1 << (irq & 31), reg); |
84 | } | 84 | } |
85 | 85 | ||
@@ -90,8 +90,8 @@ static int msm_irq_set_wake(unsigned int irq, unsigned int on) | |||
90 | 90 | ||
91 | static int msm_irq_set_type(unsigned int irq, unsigned int flow_type) | 91 | static int msm_irq_set_type(unsigned int irq, unsigned int flow_type) |
92 | { | 92 | { |
93 | unsigned treg = VIC_INT_TYPE0 + ((irq & 32) ? 4 : 0); | 93 | void __iomem *treg = VIC_INT_TYPE0 + ((irq & 32) ? 4 : 0); |
94 | unsigned preg = VIC_INT_POLARITY0 + ((irq & 32) ? 4 : 0); | 94 | void __iomem *preg = VIC_INT_POLARITY0 + ((irq & 32) ? 4 : 0); |
95 | int b = 1 << (irq & 31); | 95 | int b = 1 << (irq & 31); |
96 | 96 | ||
97 | if (flow_type & (IRQF_TRIGGER_FALLING | IRQF_TRIGGER_LOW)) | 97 | if (flow_type & (IRQF_TRIGGER_FALLING | IRQF_TRIGGER_LOW)) |
diff --git a/arch/arm/mach-msm/proc_comm.c b/arch/arm/mach-msm/proc_comm.c new file mode 100644 index 000000000000..915ee704ed3c --- /dev/null +++ b/arch/arm/mach-msm/proc_comm.c | |||
@@ -0,0 +1,110 @@ | |||
1 | /* arch/arm/mach-msm/proc_comm.c | ||
2 | * | ||
3 | * Copyright (C) 2007-2008 Google, Inc. | ||
4 | * Author: Brian Swetland <swetland@google.com> | ||
5 | * | ||
6 | * This software is licensed under the terms of the GNU General Public | ||
7 | * License version 2, as published by the Free Software Foundation, and | ||
8 | * may be copied, distributed, and modified under those terms. | ||
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 | */ | ||
16 | |||
17 | #include <linux/delay.h> | ||
18 | #include <linux/errno.h> | ||
19 | #include <linux/io.h> | ||
20 | #include <linux/spinlock.h> | ||
21 | #include <mach/msm_iomap.h> | ||
22 | #include <mach/system.h> | ||
23 | |||
24 | #include "proc_comm.h" | ||
25 | |||
26 | #define MSM_A2M_INT(n) (MSM_CSR_BASE + 0x400 + (n) * 4) | ||
27 | |||
28 | static inline void notify_other_proc_comm(void) | ||
29 | { | ||
30 | writel(1, MSM_A2M_INT(6)); | ||
31 | } | ||
32 | |||
33 | #define APP_COMMAND 0x00 | ||
34 | #define APP_STATUS 0x04 | ||
35 | #define APP_DATA1 0x08 | ||
36 | #define APP_DATA2 0x0C | ||
37 | |||
38 | #define MDM_COMMAND 0x10 | ||
39 | #define MDM_STATUS 0x14 | ||
40 | #define MDM_DATA1 0x18 | ||
41 | #define MDM_DATA2 0x1C | ||
42 | |||
43 | static DEFINE_SPINLOCK(proc_comm_lock); | ||
44 | |||
45 | /* The higher level SMD support will install this to | ||
46 | * provide a way to check for and handle modem restart. | ||
47 | */ | ||
48 | int (*msm_check_for_modem_crash)(void); | ||
49 | |||
50 | /* Poll for a state change, checking for possible | ||
51 | * modem crashes along the way (so we don't wait | ||
52 | * forever while the ARM9 is blowing up). | ||
53 | * | ||
54 | * Return an error in the event of a modem crash and | ||
55 | * restart so the msm_proc_comm() routine can restart | ||
56 | * the operation from the beginning. | ||
57 | */ | ||
58 | static int proc_comm_wait_for(void __iomem *addr, unsigned value) | ||
59 | { | ||
60 | for (;;) { | ||
61 | if (readl(addr) == value) | ||
62 | return 0; | ||
63 | |||
64 | if (msm_check_for_modem_crash) | ||
65 | if (msm_check_for_modem_crash()) | ||
66 | return -EAGAIN; | ||
67 | } | ||
68 | } | ||
69 | |||
70 | int msm_proc_comm(unsigned cmd, unsigned *data1, unsigned *data2) | ||
71 | { | ||
72 | void __iomem *base = MSM_SHARED_RAM_BASE; | ||
73 | unsigned long flags; | ||
74 | int ret; | ||
75 | |||
76 | spin_lock_irqsave(&proc_comm_lock, flags); | ||
77 | |||
78 | for (;;) { | ||
79 | if (proc_comm_wait_for(base + MDM_STATUS, PCOM_READY)) | ||
80 | continue; | ||
81 | |||
82 | writel(cmd, base + APP_COMMAND); | ||
83 | writel(data1 ? *data1 : 0, base + APP_DATA1); | ||
84 | writel(data2 ? *data2 : 0, base + APP_DATA2); | ||
85 | |||
86 | notify_other_proc_comm(); | ||
87 | |||
88 | if (proc_comm_wait_for(base + APP_COMMAND, PCOM_CMD_DONE)) | ||
89 | continue; | ||
90 | |||
91 | if (readl(base + APP_STATUS) != PCOM_CMD_FAIL) { | ||
92 | if (data1) | ||
93 | *data1 = readl(base + APP_DATA1); | ||
94 | if (data2) | ||
95 | *data2 = readl(base + APP_DATA2); | ||
96 | ret = 0; | ||
97 | } else { | ||
98 | ret = -EIO; | ||
99 | } | ||
100 | break; | ||
101 | } | ||
102 | |||
103 | writel(PCOM_CMD_IDLE, base + APP_COMMAND); | ||
104 | |||
105 | spin_unlock_irqrestore(&proc_comm_lock, flags); | ||
106 | |||
107 | return ret; | ||
108 | } | ||
109 | |||
110 | |||
diff --git a/arch/arm/mach-msm/proc_comm.h b/arch/arm/mach-msm/proc_comm.h new file mode 100644 index 000000000000..834760f25692 --- /dev/null +++ b/arch/arm/mach-msm/proc_comm.h | |||
@@ -0,0 +1,165 @@ | |||
1 | /* arch/arm/mach-msm/proc_comm.h | ||
2 | * | ||
3 | * Copyright (c) 2007 QUALCOMM Incorporated | ||
4 | * | ||
5 | * This software is licensed under the terms of the GNU General Public | ||
6 | * License version 2, as published by the Free Software Foundation, and | ||
7 | * may be copied, distributed, and modified under those terms. | ||
8 | * | ||
9 | * This program is distributed in the hope that it will be useful, | ||
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | * GNU General Public License for more details. | ||
13 | * | ||
14 | */ | ||
15 | |||
16 | #ifndef _ARCH_ARM_MACH_MSM_PROC_COMM_H_ | ||
17 | #define _ARCH_ARM_MACH_MSM_PROC_COMM_H_ | ||
18 | |||
19 | enum { | ||
20 | PCOM_CMD_IDLE = 0x0, | ||
21 | PCOM_CMD_DONE, | ||
22 | PCOM_RESET_APPS, | ||
23 | PCOM_RESET_CHIP, | ||
24 | PCOM_CONFIG_NAND_MPU, | ||
25 | PCOM_CONFIG_USB_CLKS, | ||
26 | PCOM_GET_POWER_ON_STATUS, | ||
27 | PCOM_GET_WAKE_UP_STATUS, | ||
28 | PCOM_GET_BATT_LEVEL, | ||
29 | PCOM_CHG_IS_CHARGING, | ||
30 | PCOM_POWER_DOWN, | ||
31 | PCOM_USB_PIN_CONFIG, | ||
32 | PCOM_USB_PIN_SEL, | ||
33 | PCOM_SET_RTC_ALARM, | ||
34 | PCOM_NV_READ, | ||
35 | PCOM_NV_WRITE, | ||
36 | PCOM_GET_UUID_HIGH, | ||
37 | PCOM_GET_UUID_LOW, | ||
38 | PCOM_GET_HW_ENTROPY, | ||
39 | PCOM_RPC_GPIO_TLMM_CONFIG_REMOTE, | ||
40 | PCOM_CLKCTL_RPC_ENABLE, | ||
41 | PCOM_CLKCTL_RPC_DISABLE, | ||
42 | PCOM_CLKCTL_RPC_RESET, | ||
43 | PCOM_CLKCTL_RPC_SET_FLAGS, | ||
44 | PCOM_CLKCTL_RPC_SET_RATE, | ||
45 | PCOM_CLKCTL_RPC_MIN_RATE, | ||
46 | PCOM_CLKCTL_RPC_MAX_RATE, | ||
47 | PCOM_CLKCTL_RPC_RATE, | ||
48 | PCOM_CLKCTL_RPC_PLL_REQUEST, | ||
49 | PCOM_CLKCTL_RPC_ENABLED, | ||
50 | PCOM_VREG_SWITCH, | ||
51 | PCOM_VREG_SET_LEVEL, | ||
52 | PCOM_GPIO_TLMM_CONFIG_GROUP, | ||
53 | PCOM_GPIO_TLMM_UNCONFIG_GROUP, | ||
54 | PCOM_NV_WRITE_BYTES_4_7, | ||
55 | PCOM_CONFIG_DISP, | ||
56 | PCOM_GET_FTM_BOOT_COUNT, | ||
57 | PCOM_RPC_GPIO_TLMM_CONFIG_EX, | ||
58 | PCOM_PM_MPP_CONFIG, | ||
59 | PCOM_GPIO_IN, | ||
60 | PCOM_GPIO_OUT, | ||
61 | PCOM_RESET_MODEM, | ||
62 | PCOM_RESET_CHIP_IMM, | ||
63 | PCOM_PM_VID_EN, | ||
64 | PCOM_VREG_PULLDOWN, | ||
65 | PCOM_NUM_CMDS, | ||
66 | }; | ||
67 | |||
68 | enum { | ||
69 | PCOM_INVALID_STATUS = 0x0, | ||
70 | PCOM_READY, | ||
71 | PCOM_CMD_RUNNING, | ||
72 | PCOM_CMD_SUCCESS, | ||
73 | PCOM_CMD_FAIL, | ||
74 | }; | ||
75 | |||
76 | /* List of VREGs that support the Pull Down Resistor setting. */ | ||
77 | enum { | ||
78 | PM_VREG_PDOWN_MSMA_ID, | ||
79 | PM_VREG_PDOWN_MSMP_ID, | ||
80 | PM_VREG_PDOWN_MSME1_ID, /* Not supported in Panoramix */ | ||
81 | PM_VREG_PDOWN_MSMC1_ID, /* Not supported in PM6620 */ | ||
82 | PM_VREG_PDOWN_MSMC2_ID, /* Supported in PM7500 only */ | ||
83 | PM_VREG_PDOWN_GP3_ID, /* Supported in PM7500 only */ | ||
84 | PM_VREG_PDOWN_MSME2_ID, /* Supported in PM7500 and Panoramix only */ | ||
85 | PM_VREG_PDOWN_GP4_ID, /* Supported in PM7500 only */ | ||
86 | PM_VREG_PDOWN_GP1_ID, /* Supported in PM7500 only */ | ||
87 | PM_VREG_PDOWN_TCXO_ID, | ||
88 | PM_VREG_PDOWN_PA_ID, | ||
89 | PM_VREG_PDOWN_RFTX_ID, | ||
90 | PM_VREG_PDOWN_RFRX1_ID, | ||
91 | PM_VREG_PDOWN_RFRX2_ID, | ||
92 | PM_VREG_PDOWN_SYNT_ID, | ||
93 | PM_VREG_PDOWN_WLAN_ID, | ||
94 | PM_VREG_PDOWN_USB_ID, | ||
95 | PM_VREG_PDOWN_MMC_ID, | ||
96 | PM_VREG_PDOWN_RUIM_ID, | ||
97 | PM_VREG_PDOWN_MSMC0_ID, /* Supported in PM6610 only */ | ||
98 | PM_VREG_PDOWN_GP2_ID, /* Supported in PM7500 only */ | ||
99 | PM_VREG_PDOWN_GP5_ID, /* Supported in PM7500 only */ | ||
100 | PM_VREG_PDOWN_GP6_ID, /* Supported in PM7500 only */ | ||
101 | PM_VREG_PDOWN_RF_ID, | ||
102 | PM_VREG_PDOWN_RF_VCO_ID, | ||
103 | PM_VREG_PDOWN_MPLL_ID, | ||
104 | PM_VREG_PDOWN_S2_ID, | ||
105 | PM_VREG_PDOWN_S3_ID, | ||
106 | PM_VREG_PDOWN_RFUBM_ID, | ||
107 | |||
108 | /* new for HAN */ | ||
109 | PM_VREG_PDOWN_RF1_ID, | ||
110 | PM_VREG_PDOWN_RF2_ID, | ||
111 | PM_VREG_PDOWN_RFA_ID, | ||
112 | PM_VREG_PDOWN_CDC2_ID, | ||
113 | PM_VREG_PDOWN_RFTX2_ID, | ||
114 | PM_VREG_PDOWN_USIM_ID, | ||
115 | PM_VREG_PDOWN_USB2P6_ID, | ||
116 | PM_VREG_PDOWN_USB3P3_ID, | ||
117 | PM_VREG_PDOWN_INVALID_ID, | ||
118 | |||
119 | /* backward compatible enums only */ | ||
120 | PM_VREG_PDOWN_CAM_ID = PM_VREG_PDOWN_GP1_ID, | ||
121 | PM_VREG_PDOWN_MDDI_ID = PM_VREG_PDOWN_GP2_ID, | ||
122 | PM_VREG_PDOWN_RUIM2_ID = PM_VREG_PDOWN_GP3_ID, | ||
123 | PM_VREG_PDOWN_AUX_ID = PM_VREG_PDOWN_GP4_ID, | ||
124 | PM_VREG_PDOWN_AUX2_ID = PM_VREG_PDOWN_GP5_ID, | ||
125 | PM_VREG_PDOWN_BT_ID = PM_VREG_PDOWN_GP6_ID, | ||
126 | |||
127 | PM_VREG_PDOWN_MSME_ID = PM_VREG_PDOWN_MSME1_ID, | ||
128 | PM_VREG_PDOWN_MSMC_ID = PM_VREG_PDOWN_MSMC1_ID, | ||
129 | PM_VREG_PDOWN_RFA1_ID = PM_VREG_PDOWN_RFRX2_ID, | ||
130 | PM_VREG_PDOWN_RFA2_ID = PM_VREG_PDOWN_RFTX2_ID, | ||
131 | PM_VREG_PDOWN_XO_ID = PM_VREG_PDOWN_TCXO_ID | ||
132 | }; | ||
133 | |||
134 | /* gpio info for PCOM_RPC_GPIO_TLMM_CONFIG_EX */ | ||
135 | |||
136 | #define GPIO_ENABLE 0 | ||
137 | #define GPIO_DISABLE 1 | ||
138 | |||
139 | #define GPIO_INPUT 0 | ||
140 | #define GPIO_OUTPUT 1 | ||
141 | |||
142 | #define GPIO_NO_PULL 0 | ||
143 | #define GPIO_PULL_DOWN 1 | ||
144 | #define GPIO_KEEPER 2 | ||
145 | #define GPIO_PULL_UP 3 | ||
146 | |||
147 | #define GPIO_2MA 0 | ||
148 | #define GPIO_4MA 1 | ||
149 | #define GPIO_6MA 2 | ||
150 | #define GPIO_8MA 3 | ||
151 | #define GPIO_10MA 4 | ||
152 | #define GPIO_12MA 5 | ||
153 | #define GPIO_14MA 6 | ||
154 | #define GPIO_16MA 7 | ||
155 | |||
156 | #define PCOM_GPIO_CFG(gpio, func, dir, pull, drvstr) \ | ||
157 | ((((gpio) & 0x3FF) << 4) | \ | ||
158 | ((func) & 0xf) | \ | ||
159 | (((dir) & 0x1) << 14) | \ | ||
160 | (((pull) & 0x3) << 15) | \ | ||
161 | (((drvstr) & 0xF) << 17)) | ||
162 | |||
163 | int msm_proc_comm(unsigned cmd, unsigned *data1, unsigned *data2); | ||
164 | |||
165 | #endif | ||
diff --git a/arch/arm/mach-msm/timer.c b/arch/arm/mach-msm/timer.c index 2bffe9b7e9fe..345a14cb73c3 100644 --- a/arch/arm/mach-msm/timer.c +++ b/arch/arm/mach-msm/timer.c | |||
@@ -45,7 +45,7 @@ struct msm_clock { | |||
45 | struct clock_event_device clockevent; | 45 | struct clock_event_device clockevent; |
46 | struct clocksource clocksource; | 46 | struct clocksource clocksource; |
47 | struct irqaction irq; | 47 | struct irqaction irq; |
48 | uint32_t regbase; | 48 | void __iomem *regbase; |
49 | uint32_t freq; | 49 | uint32_t freq; |
50 | uint32_t shift; | 50 | uint32_t shift; |
51 | }; | 51 | }; |
diff --git a/arch/arm/mach-msm/vreg.c b/arch/arm/mach-msm/vreg.c new file mode 100644 index 000000000000..fcb0b9f25684 --- /dev/null +++ b/arch/arm/mach-msm/vreg.c | |||
@@ -0,0 +1,143 @@ | |||
1 | /* arch/arm/mach-msm/vreg.c | ||
2 | * | ||
3 | * Copyright (C) 2008 Google, Inc. | ||
4 | * Author: Brian Swetland <swetland@google.com> | ||
5 | * | ||
6 | * This software is licensed under the terms of the GNU General Public | ||
7 | * License version 2, as published by the Free Software Foundation, and | ||
8 | * may be copied, distributed, and modified under those terms. | ||
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 | */ | ||
16 | |||
17 | #include <linux/kernel.h> | ||
18 | #include <linux/device.h> | ||
19 | #include <linux/init.h> | ||
20 | #include <linux/debugfs.h> | ||
21 | #include <mach/vreg.h> | ||
22 | |||
23 | #include "proc_comm.h" | ||
24 | |||
25 | struct vreg { | ||
26 | const char *name; | ||
27 | unsigned id; | ||
28 | }; | ||
29 | |||
30 | #define VREG(_name, _id) { .name = _name, .id = _id, } | ||
31 | |||
32 | static struct vreg vregs[] = { | ||
33 | VREG("msma", 0), | ||
34 | VREG("msmp", 1), | ||
35 | VREG("msme1", 2), | ||
36 | VREG("msmc1", 3), | ||
37 | VREG("msmc2", 4), | ||
38 | VREG("gp3", 5), | ||
39 | VREG("msme2", 6), | ||
40 | VREG("gp4", 7), | ||
41 | VREG("gp1", 8), | ||
42 | VREG("tcxo", 9), | ||
43 | VREG("pa", 10), | ||
44 | VREG("rftx", 11), | ||
45 | VREG("rfrx1", 12), | ||
46 | VREG("rfrx2", 13), | ||
47 | VREG("synt", 14), | ||
48 | VREG("wlan", 15), | ||
49 | VREG("usb", 16), | ||
50 | VREG("boost", 17), | ||
51 | VREG("mmc", 18), | ||
52 | VREG("ruim", 19), | ||
53 | VREG("msmc0", 20), | ||
54 | VREG("gp2", 21), | ||
55 | VREG("gp5", 22), | ||
56 | VREG("gp6", 23), | ||
57 | VREG("rf", 24), | ||
58 | VREG("rf_vco", 26), | ||
59 | VREG("mpll", 27), | ||
60 | VREG("s2", 28), | ||
61 | VREG("s3", 29), | ||
62 | VREG("rfubm", 30), | ||
63 | VREG("ncp", 31), | ||
64 | }; | ||
65 | |||
66 | struct vreg *vreg_get(struct device *dev, const char *id) | ||
67 | { | ||
68 | int n; | ||
69 | for (n = 0; n < ARRAY_SIZE(vregs); n++) { | ||
70 | if (!strcmp(vregs[n].name, id)) | ||
71 | return vregs + n; | ||
72 | } | ||
73 | return 0; | ||
74 | } | ||
75 | |||
76 | void vreg_put(struct vreg *vreg) | ||
77 | { | ||
78 | } | ||
79 | |||
80 | int vreg_enable(struct vreg *vreg) | ||
81 | { | ||
82 | unsigned id = vreg->id; | ||
83 | unsigned enable = 1; | ||
84 | return msm_proc_comm(PCOM_VREG_SWITCH, &id, &enable); | ||
85 | } | ||
86 | |||
87 | void vreg_disable(struct vreg *vreg) | ||
88 | { | ||
89 | unsigned id = vreg->id; | ||
90 | unsigned enable = 0; | ||
91 | msm_proc_comm(PCOM_VREG_SWITCH, &id, &enable); | ||
92 | } | ||
93 | |||
94 | int vreg_set_level(struct vreg *vreg, unsigned mv) | ||
95 | { | ||
96 | unsigned id = vreg->id; | ||
97 | return msm_proc_comm(PCOM_VREG_SET_LEVEL, &id, &mv); | ||
98 | } | ||
99 | |||
100 | #if defined(CONFIG_DEBUG_FS) | ||
101 | |||
102 | static int vreg_debug_set(void *data, u64 val) | ||
103 | { | ||
104 | struct vreg *vreg = data; | ||
105 | switch (val) { | ||
106 | case 0: | ||
107 | vreg_disable(vreg); | ||
108 | break; | ||
109 | case 1: | ||
110 | vreg_enable(vreg); | ||
111 | break; | ||
112 | default: | ||
113 | vreg_set_level(vreg, val); | ||
114 | break; | ||
115 | } | ||
116 | return 0; | ||
117 | } | ||
118 | |||
119 | static int vreg_debug_get(void *data, u64 *val) | ||
120 | { | ||
121 | return -ENOSYS; | ||
122 | } | ||
123 | |||
124 | DEFINE_SIMPLE_ATTRIBUTE(vreg_fops, vreg_debug_get, vreg_debug_set, "%llu\n"); | ||
125 | |||
126 | static int __init vreg_debug_init(void) | ||
127 | { | ||
128 | struct dentry *dent; | ||
129 | int n; | ||
130 | |||
131 | dent = debugfs_create_dir("vreg", 0); | ||
132 | if (IS_ERR(dent)) | ||
133 | return 0; | ||
134 | |||
135 | for (n = 0; n < ARRAY_SIZE(vregs); n++) | ||
136 | (void) debugfs_create_file(vregs[n].name, 0644, | ||
137 | dent, vregs + n, &vreg_fops); | ||
138 | |||
139 | return 0; | ||
140 | } | ||
141 | |||
142 | device_initcall(vreg_debug_init); | ||
143 | #endif | ||
diff --git a/arch/arm/mach-pxa/Kconfig b/arch/arm/mach-pxa/Kconfig index f781873431f3..a062235e83a8 100644 --- a/arch/arm/mach-pxa/Kconfig +++ b/arch/arm/mach-pxa/Kconfig | |||
@@ -71,6 +71,14 @@ config PXA_SHARPSL | |||
71 | SL-C3000 (Spitz), SL-C3100 (Borzoi) or SL-C6000x (Tosa) | 71 | SL-C3000 (Spitz), SL-C3100 (Borzoi) or SL-C6000x (Tosa) |
72 | handheld computer. | 72 | handheld computer. |
73 | 73 | ||
74 | config CORGI_SSP_DEPRECATED | ||
75 | bool | ||
76 | select PXA_SSP | ||
77 | help | ||
78 | This option will include corgi_ssp.c and corgi_lcd.c | ||
79 | that corgi_ts.c and other legacy drivers (corgi_bl.c | ||
80 | and sharpsl_pm.c) may depend on. | ||
81 | |||
74 | config MACH_POODLE | 82 | config MACH_POODLE |
75 | bool "Enable Sharp SL-5600 (Poodle) Support" | 83 | bool "Enable Sharp SL-5600 (Poodle) Support" |
76 | depends on PXA_SHARPSL | 84 | depends on PXA_SHARPSL |
diff --git a/arch/arm/mach-pxa/Makefile b/arch/arm/mach-pxa/Makefile index d31c9979cfa3..d64c68b232e3 100644 --- a/arch/arm/mach-pxa/Makefile +++ b/arch/arm/mach-pxa/Makefile | |||
@@ -37,6 +37,7 @@ obj-$(CONFIG_MACH_TRIZEPS4) += trizeps4.o | |||
37 | obj-$(CONFIG_MACH_COLIBRI) += colibri.o | 37 | obj-$(CONFIG_MACH_COLIBRI) += colibri.o |
38 | obj-$(CONFIG_PXA_SHARP_C7xx) += corgi.o sharpsl_pm.o corgi_pm.o | 38 | obj-$(CONFIG_PXA_SHARP_C7xx) += corgi.o sharpsl_pm.o corgi_pm.o |
39 | obj-$(CONFIG_PXA_SHARP_Cxx00) += spitz.o sharpsl_pm.o spitz_pm.o | 39 | obj-$(CONFIG_PXA_SHARP_Cxx00) += spitz.o sharpsl_pm.o spitz_pm.o |
40 | obj-$(CONFIG_CORGI_SSP_DEPRECATED) += corgi_ssp.o corgi_lcd.o | ||
40 | obj-$(CONFIG_MACH_POODLE) += poodle.o | 41 | obj-$(CONFIG_MACH_POODLE) += poodle.o |
41 | obj-$(CONFIG_MACH_PCM027) += pcm027.o | 42 | obj-$(CONFIG_MACH_PCM027) += pcm027.o |
42 | obj-$(CONFIG_MACH_PCM990_BASEBOARD) += pcm990-baseboard.o | 43 | obj-$(CONFIG_MACH_PCM990_BASEBOARD) += pcm990-baseboard.o |
diff --git a/arch/arm/mach-pxa/corgi_lcd.c b/arch/arm/mach-pxa/corgi_lcd.c new file mode 100644 index 000000000000..411607bc1fc2 --- /dev/null +++ b/arch/arm/mach-pxa/corgi_lcd.c | |||
@@ -0,0 +1,289 @@ | |||
1 | /* | ||
2 | * linux/arch/arm/mach-pxa/corgi_lcd.c | ||
3 | * | ||
4 | * Corgi/Spitz LCD Specific Code | ||
5 | * | ||
6 | * Copyright (C) 2005 Richard Purdie | ||
7 | * | ||
8 | * Connectivity: | ||
9 | * Corgi - LCD to ATI Imageon w100 (Wallaby) | ||
10 | * Spitz - LCD to PXA Framebuffer | ||
11 | * | ||
12 | * This program is free software; you can redistribute it and/or modify | ||
13 | * it under the terms of the GNU General Public License version 2 as | ||
14 | * published by the Free Software Foundation. | ||
15 | * | ||
16 | */ | ||
17 | |||
18 | #include <linux/delay.h> | ||
19 | #include <linux/kernel.h> | ||
20 | #include <linux/platform_device.h> | ||
21 | #include <linux/module.h> | ||
22 | #include <linux/string.h> | ||
23 | #include <mach/corgi.h> | ||
24 | #include <mach/hardware.h> | ||
25 | #include <mach/pxa-regs.h> | ||
26 | #include <mach/sharpsl.h> | ||
27 | #include <mach/spitz.h> | ||
28 | #include <asm/hardware/scoop.h> | ||
29 | #include <asm/mach/sharpsl_param.h> | ||
30 | #include "generic.h" | ||
31 | |||
32 | /* Register Addresses */ | ||
33 | #define RESCTL_ADRS 0x00 | ||
34 | #define PHACTRL_ADRS 0x01 | ||
35 | #define DUTYCTRL_ADRS 0x02 | ||
36 | #define POWERREG0_ADRS 0x03 | ||
37 | #define POWERREG1_ADRS 0x04 | ||
38 | #define GPOR3_ADRS 0x05 | ||
39 | #define PICTRL_ADRS 0x06 | ||
40 | #define POLCTRL_ADRS 0x07 | ||
41 | |||
42 | /* Register Bit Definitions */ | ||
43 | #define RESCTL_QVGA 0x01 | ||
44 | #define RESCTL_VGA 0x00 | ||
45 | |||
46 | #define POWER1_VW_ON 0x01 /* VW Supply FET ON */ | ||
47 | #define POWER1_GVSS_ON 0x02 /* GVSS(-8V) Power Supply ON */ | ||
48 | #define POWER1_VDD_ON 0x04 /* VDD(8V),SVSS(-4V) Power Supply ON */ | ||
49 | |||
50 | #define POWER1_VW_OFF 0x00 /* VW Supply FET OFF */ | ||
51 | #define POWER1_GVSS_OFF 0x00 /* GVSS(-8V) Power Supply OFF */ | ||
52 | #define POWER1_VDD_OFF 0x00 /* VDD(8V),SVSS(-4V) Power Supply OFF */ | ||
53 | |||
54 | #define POWER0_COM_DCLK 0x01 /* COM Voltage DC Bias DAC Serial Data Clock */ | ||
55 | #define POWER0_COM_DOUT 0x02 /* COM Voltage DC Bias DAC Serial Data Out */ | ||
56 | #define POWER0_DAC_ON 0x04 /* DAC Power Supply ON */ | ||
57 | #define POWER0_COM_ON 0x08 /* COM Power Supply ON */ | ||
58 | #define POWER0_VCC5_ON 0x10 /* VCC5 Power Supply ON */ | ||
59 | |||
60 | #define POWER0_DAC_OFF 0x00 /* DAC Power Supply OFF */ | ||
61 | #define POWER0_COM_OFF 0x00 /* COM Power Supply OFF */ | ||
62 | #define POWER0_VCC5_OFF 0x00 /* VCC5 Power Supply OFF */ | ||
63 | |||
64 | #define PICTRL_INIT_STATE 0x01 | ||
65 | #define PICTRL_INIOFF 0x02 | ||
66 | #define PICTRL_POWER_DOWN 0x04 | ||
67 | #define PICTRL_COM_SIGNAL_OFF 0x08 | ||
68 | #define PICTRL_DAC_SIGNAL_OFF 0x10 | ||
69 | |||
70 | #define POLCTRL_SYNC_POL_FALL 0x01 | ||
71 | #define POLCTRL_EN_POL_FALL 0x02 | ||
72 | #define POLCTRL_DATA_POL_FALL 0x04 | ||
73 | #define POLCTRL_SYNC_ACT_H 0x08 | ||
74 | #define POLCTRL_EN_ACT_L 0x10 | ||
75 | |||
76 | #define POLCTRL_SYNC_POL_RISE 0x00 | ||
77 | #define POLCTRL_EN_POL_RISE 0x00 | ||
78 | #define POLCTRL_DATA_POL_RISE 0x00 | ||
79 | #define POLCTRL_SYNC_ACT_L 0x00 | ||
80 | #define POLCTRL_EN_ACT_H 0x00 | ||
81 | |||
82 | #define PHACTRL_PHASE_MANUAL 0x01 | ||
83 | #define DEFAULT_PHAD_QVGA (9) | ||
84 | #define DEFAULT_COMADJ (125) | ||
85 | |||
86 | /* | ||
87 | * This is only a psuedo I2C interface. We can't use the standard kernel | ||
88 | * routines as the interface is write only. We just assume the data is acked... | ||
89 | */ | ||
90 | static void lcdtg_ssp_i2c_send(u8 data) | ||
91 | { | ||
92 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, data); | ||
93 | udelay(10); | ||
94 | } | ||
95 | |||
96 | static void lcdtg_i2c_send_bit(u8 data) | ||
97 | { | ||
98 | lcdtg_ssp_i2c_send(data); | ||
99 | lcdtg_ssp_i2c_send(data | POWER0_COM_DCLK); | ||
100 | lcdtg_ssp_i2c_send(data); | ||
101 | } | ||
102 | |||
103 | static void lcdtg_i2c_send_start(u8 base) | ||
104 | { | ||
105 | lcdtg_ssp_i2c_send(base | POWER0_COM_DCLK | POWER0_COM_DOUT); | ||
106 | lcdtg_ssp_i2c_send(base | POWER0_COM_DCLK); | ||
107 | lcdtg_ssp_i2c_send(base); | ||
108 | } | ||
109 | |||
110 | static void lcdtg_i2c_send_stop(u8 base) | ||
111 | { | ||
112 | lcdtg_ssp_i2c_send(base); | ||
113 | lcdtg_ssp_i2c_send(base | POWER0_COM_DCLK); | ||
114 | lcdtg_ssp_i2c_send(base | POWER0_COM_DCLK | POWER0_COM_DOUT); | ||
115 | } | ||
116 | |||
117 | static void lcdtg_i2c_send_byte(u8 base, u8 data) | ||
118 | { | ||
119 | int i; | ||
120 | for (i = 0; i < 8; i++) { | ||
121 | if (data & 0x80) | ||
122 | lcdtg_i2c_send_bit(base | POWER0_COM_DOUT); | ||
123 | else | ||
124 | lcdtg_i2c_send_bit(base); | ||
125 | data <<= 1; | ||
126 | } | ||
127 | } | ||
128 | |||
129 | static void lcdtg_i2c_wait_ack(u8 base) | ||
130 | { | ||
131 | lcdtg_i2c_send_bit(base); | ||
132 | } | ||
133 | |||
134 | static void lcdtg_set_common_voltage(u8 base_data, u8 data) | ||
135 | { | ||
136 | /* Set Common Voltage to M62332FP via I2C */ | ||
137 | lcdtg_i2c_send_start(base_data); | ||
138 | lcdtg_i2c_send_byte(base_data, 0x9c); | ||
139 | lcdtg_i2c_wait_ack(base_data); | ||
140 | lcdtg_i2c_send_byte(base_data, 0x00); | ||
141 | lcdtg_i2c_wait_ack(base_data); | ||
142 | lcdtg_i2c_send_byte(base_data, data); | ||
143 | lcdtg_i2c_wait_ack(base_data); | ||
144 | lcdtg_i2c_send_stop(base_data); | ||
145 | } | ||
146 | |||
147 | /* Set Phase Adjust */ | ||
148 | static void lcdtg_set_phadadj(int mode) | ||
149 | { | ||
150 | int adj; | ||
151 | switch(mode) { | ||
152 | case 480: | ||
153 | case 640: | ||
154 | /* Setting for VGA */ | ||
155 | adj = sharpsl_param.phadadj; | ||
156 | if (adj < 0) { | ||
157 | adj = PHACTRL_PHASE_MANUAL; | ||
158 | } else { | ||
159 | adj = ((adj & 0x0f) << 1) | PHACTRL_PHASE_MANUAL; | ||
160 | } | ||
161 | break; | ||
162 | case 240: | ||
163 | case 320: | ||
164 | default: | ||
165 | /* Setting for QVGA */ | ||
166 | adj = (DEFAULT_PHAD_QVGA << 1) | PHACTRL_PHASE_MANUAL; | ||
167 | break; | ||
168 | } | ||
169 | |||
170 | corgi_ssp_lcdtg_send(PHACTRL_ADRS, adj); | ||
171 | } | ||
172 | |||
173 | static int lcd_inited; | ||
174 | |||
175 | void corgi_lcdtg_hw_init(int mode) | ||
176 | { | ||
177 | if (!lcd_inited) { | ||
178 | int comadj; | ||
179 | |||
180 | /* Initialize Internal Logic & Port */ | ||
181 | corgi_ssp_lcdtg_send(PICTRL_ADRS, PICTRL_POWER_DOWN | PICTRL_INIOFF | PICTRL_INIT_STATE | ||
182 | | PICTRL_COM_SIGNAL_OFF | PICTRL_DAC_SIGNAL_OFF); | ||
183 | |||
184 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_COM_DCLK | POWER0_COM_DOUT | POWER0_DAC_OFF | ||
185 | | POWER0_COM_OFF | POWER0_VCC5_OFF); | ||
186 | |||
187 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_OFF | POWER1_VDD_OFF); | ||
188 | |||
189 | /* VDD(+8V), SVSS(-4V) ON */ | ||
190 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_OFF | POWER1_VDD_ON); | ||
191 | mdelay(3); | ||
192 | |||
193 | /* DAC ON */ | ||
194 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_COM_DCLK | POWER0_COM_DOUT | POWER0_DAC_ON | ||
195 | | POWER0_COM_OFF | POWER0_VCC5_OFF); | ||
196 | |||
197 | /* INIB = H, INI = L */ | ||
198 | /* PICTL[0] = H , PICTL[1] = PICTL[2] = PICTL[4] = L */ | ||
199 | corgi_ssp_lcdtg_send(PICTRL_ADRS, PICTRL_INIT_STATE | PICTRL_COM_SIGNAL_OFF); | ||
200 | |||
201 | /* Set Common Voltage */ | ||
202 | comadj = sharpsl_param.comadj; | ||
203 | if (comadj < 0) | ||
204 | comadj = DEFAULT_COMADJ; | ||
205 | lcdtg_set_common_voltage((POWER0_DAC_ON | POWER0_COM_OFF | POWER0_VCC5_OFF), comadj); | ||
206 | |||
207 | /* VCC5 ON, DAC ON */ | ||
208 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_COM_DCLK | POWER0_COM_DOUT | POWER0_DAC_ON | | ||
209 | POWER0_COM_OFF | POWER0_VCC5_ON); | ||
210 | |||
211 | /* GVSS(-8V) ON, VDD ON */ | ||
212 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_ON | POWER1_VDD_ON); | ||
213 | mdelay(2); | ||
214 | |||
215 | /* COM SIGNAL ON (PICTL[3] = L) */ | ||
216 | corgi_ssp_lcdtg_send(PICTRL_ADRS, PICTRL_INIT_STATE); | ||
217 | |||
218 | /* COM ON, DAC ON, VCC5_ON */ | ||
219 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_COM_DCLK | POWER0_COM_DOUT | POWER0_DAC_ON | ||
220 | | POWER0_COM_ON | POWER0_VCC5_ON); | ||
221 | |||
222 | /* VW ON, GVSS ON, VDD ON */ | ||
223 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_ON | POWER1_GVSS_ON | POWER1_VDD_ON); | ||
224 | |||
225 | /* Signals output enable */ | ||
226 | corgi_ssp_lcdtg_send(PICTRL_ADRS, 0); | ||
227 | |||
228 | /* Set Phase Adjust */ | ||
229 | lcdtg_set_phadadj(mode); | ||
230 | |||
231 | /* Initialize for Input Signals from ATI */ | ||
232 | corgi_ssp_lcdtg_send(POLCTRL_ADRS, POLCTRL_SYNC_POL_RISE | POLCTRL_EN_POL_RISE | ||
233 | | POLCTRL_DATA_POL_RISE | POLCTRL_SYNC_ACT_L | POLCTRL_EN_ACT_H); | ||
234 | udelay(1000); | ||
235 | |||
236 | lcd_inited=1; | ||
237 | } else { | ||
238 | lcdtg_set_phadadj(mode); | ||
239 | } | ||
240 | |||
241 | switch(mode) { | ||
242 | case 480: | ||
243 | case 640: | ||
244 | /* Set Lcd Resolution (VGA) */ | ||
245 | corgi_ssp_lcdtg_send(RESCTL_ADRS, RESCTL_VGA); | ||
246 | break; | ||
247 | case 240: | ||
248 | case 320: | ||
249 | default: | ||
250 | /* Set Lcd Resolution (QVGA) */ | ||
251 | corgi_ssp_lcdtg_send(RESCTL_ADRS, RESCTL_QVGA); | ||
252 | break; | ||
253 | } | ||
254 | } | ||
255 | |||
256 | void corgi_lcdtg_suspend(void) | ||
257 | { | ||
258 | /* 60Hz x 2 frame = 16.7msec x 2 = 33.4 msec */ | ||
259 | mdelay(34); | ||
260 | |||
261 | /* (1)VW OFF */ | ||
262 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_ON | POWER1_VDD_ON); | ||
263 | |||
264 | /* (2)COM OFF */ | ||
265 | corgi_ssp_lcdtg_send(PICTRL_ADRS, PICTRL_COM_SIGNAL_OFF); | ||
266 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_DAC_ON | POWER0_COM_OFF | POWER0_VCC5_ON); | ||
267 | |||
268 | /* (3)Set Common Voltage Bias 0V */ | ||
269 | lcdtg_set_common_voltage(POWER0_DAC_ON | POWER0_COM_OFF | POWER0_VCC5_ON, 0); | ||
270 | |||
271 | /* (4)GVSS OFF */ | ||
272 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_OFF | POWER1_VDD_ON); | ||
273 | |||
274 | /* (5)VCC5 OFF */ | ||
275 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_DAC_ON | POWER0_COM_OFF | POWER0_VCC5_OFF); | ||
276 | |||
277 | /* (6)Set PDWN, INIOFF, DACOFF */ | ||
278 | corgi_ssp_lcdtg_send(PICTRL_ADRS, PICTRL_INIOFF | PICTRL_DAC_SIGNAL_OFF | | ||
279 | PICTRL_POWER_DOWN | PICTRL_COM_SIGNAL_OFF); | ||
280 | |||
281 | /* (7)DAC OFF */ | ||
282 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_DAC_OFF | POWER0_COM_OFF | POWER0_VCC5_OFF); | ||
283 | |||
284 | /* (8)VDD OFF */ | ||
285 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_OFF | POWER1_VDD_OFF); | ||
286 | |||
287 | lcd_inited = 0; | ||
288 | } | ||
289 | |||
diff --git a/arch/arm/mach-pxa/corgi_ssp.c b/arch/arm/mach-pxa/corgi_ssp.c new file mode 100644 index 000000000000..8e2f2215c4ba --- /dev/null +++ b/arch/arm/mach-pxa/corgi_ssp.c | |||
@@ -0,0 +1,276 @@ | |||
1 | /* | ||
2 | * SSP control code for Sharp Corgi devices | ||
3 | * | ||
4 | * Copyright (c) 2004-2005 Richard Purdie | ||
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 | */ | ||
11 | |||
12 | #include <linux/module.h> | ||
13 | #include <linux/init.h> | ||
14 | #include <linux/kernel.h> | ||
15 | #include <linux/sched.h> | ||
16 | #include <linux/slab.h> | ||
17 | #include <linux/delay.h> | ||
18 | #include <linux/platform_device.h> | ||
19 | #include <mach/hardware.h> | ||
20 | #include <asm/mach-types.h> | ||
21 | |||
22 | #include <mach/ssp.h> | ||
23 | #include <mach/pxa-regs.h> | ||
24 | #include <mach/pxa2xx-gpio.h> | ||
25 | #include <mach/regs-ssp.h> | ||
26 | #include "sharpsl.h" | ||
27 | |||
28 | static DEFINE_SPINLOCK(corgi_ssp_lock); | ||
29 | static struct ssp_dev corgi_ssp_dev; | ||
30 | static struct ssp_state corgi_ssp_state; | ||
31 | static struct corgissp_machinfo *ssp_machinfo; | ||
32 | |||
33 | /* | ||
34 | * There are three devices connected to the SSP interface: | ||
35 | * 1. A touchscreen controller (TI ADS7846 compatible) | ||
36 | * 2. An LCD controller (with some Backlight functionality) | ||
37 | * 3. A battery monitoring IC (Maxim MAX1111) | ||
38 | * | ||
39 | * Each device uses a different speed/mode of communication. | ||
40 | * | ||
41 | * The touchscreen is very sensitive and the most frequently used | ||
42 | * so the port is left configured for this. | ||
43 | * | ||
44 | * Devices are selected using Chip Selects on GPIOs. | ||
45 | */ | ||
46 | |||
47 | /* | ||
48 | * ADS7846 Routines | ||
49 | */ | ||
50 | unsigned long corgi_ssp_ads7846_putget(ulong data) | ||
51 | { | ||
52 | unsigned long flag; | ||
53 | u32 ret = 0; | ||
54 | |||
55 | spin_lock_irqsave(&corgi_ssp_lock, flag); | ||
56 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
57 | GPCR(ssp_machinfo->cs_ads7846) = GPIO_bit(ssp_machinfo->cs_ads7846); | ||
58 | |||
59 | ssp_write_word(&corgi_ssp_dev,data); | ||
60 | ssp_read_word(&corgi_ssp_dev, &ret); | ||
61 | |||
62 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
63 | GPSR(ssp_machinfo->cs_ads7846) = GPIO_bit(ssp_machinfo->cs_ads7846); | ||
64 | spin_unlock_irqrestore(&corgi_ssp_lock, flag); | ||
65 | |||
66 | return ret; | ||
67 | } | ||
68 | |||
69 | /* | ||
70 | * NOTE: These functions should always be called in interrupt context | ||
71 | * and use the _lock and _unlock functions. They are very time sensitive. | ||
72 | */ | ||
73 | void corgi_ssp_ads7846_lock(void) | ||
74 | { | ||
75 | spin_lock(&corgi_ssp_lock); | ||
76 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
77 | GPCR(ssp_machinfo->cs_ads7846) = GPIO_bit(ssp_machinfo->cs_ads7846); | ||
78 | } | ||
79 | |||
80 | void corgi_ssp_ads7846_unlock(void) | ||
81 | { | ||
82 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
83 | GPSR(ssp_machinfo->cs_ads7846) = GPIO_bit(ssp_machinfo->cs_ads7846); | ||
84 | spin_unlock(&corgi_ssp_lock); | ||
85 | } | ||
86 | |||
87 | void corgi_ssp_ads7846_put(ulong data) | ||
88 | { | ||
89 | ssp_write_word(&corgi_ssp_dev,data); | ||
90 | } | ||
91 | |||
92 | unsigned long corgi_ssp_ads7846_get(void) | ||
93 | { | ||
94 | u32 ret = 0; | ||
95 | ssp_read_word(&corgi_ssp_dev, &ret); | ||
96 | return ret; | ||
97 | } | ||
98 | |||
99 | EXPORT_SYMBOL(corgi_ssp_ads7846_putget); | ||
100 | EXPORT_SYMBOL(corgi_ssp_ads7846_lock); | ||
101 | EXPORT_SYMBOL(corgi_ssp_ads7846_unlock); | ||
102 | EXPORT_SYMBOL(corgi_ssp_ads7846_put); | ||
103 | EXPORT_SYMBOL(corgi_ssp_ads7846_get); | ||
104 | |||
105 | |||
106 | /* | ||
107 | * LCD/Backlight Routines | ||
108 | */ | ||
109 | unsigned long corgi_ssp_dac_put(ulong data) | ||
110 | { | ||
111 | unsigned long flag, sscr1 = SSCR1_SPH; | ||
112 | u32 tmp; | ||
113 | |||
114 | spin_lock_irqsave(&corgi_ssp_lock, flag); | ||
115 | |||
116 | if (machine_is_spitz() || machine_is_akita() || machine_is_borzoi()) | ||
117 | sscr1 = 0; | ||
118 | |||
119 | ssp_disable(&corgi_ssp_dev); | ||
120 | ssp_config(&corgi_ssp_dev, (SSCR0_Motorola | (SSCR0_DSS & 0x07 )), sscr1, 0, SSCR0_SerClkDiv(ssp_machinfo->clk_lcdcon)); | ||
121 | ssp_enable(&corgi_ssp_dev); | ||
122 | |||
123 | if (ssp_machinfo->cs_lcdcon >= 0) | ||
124 | GPCR(ssp_machinfo->cs_lcdcon) = GPIO_bit(ssp_machinfo->cs_lcdcon); | ||
125 | ssp_write_word(&corgi_ssp_dev,data); | ||
126 | /* Read null data back from device to prevent SSP overflow */ | ||
127 | ssp_read_word(&corgi_ssp_dev, &tmp); | ||
128 | if (ssp_machinfo->cs_lcdcon >= 0) | ||
129 | GPSR(ssp_machinfo->cs_lcdcon) = GPIO_bit(ssp_machinfo->cs_lcdcon); | ||
130 | |||
131 | ssp_disable(&corgi_ssp_dev); | ||
132 | ssp_config(&corgi_ssp_dev, (SSCR0_National | (SSCR0_DSS & 0x0b )), 0, 0, SSCR0_SerClkDiv(ssp_machinfo->clk_ads7846)); | ||
133 | ssp_enable(&corgi_ssp_dev); | ||
134 | |||
135 | spin_unlock_irqrestore(&corgi_ssp_lock, flag); | ||
136 | |||
137 | return 0; | ||
138 | } | ||
139 | |||
140 | void corgi_ssp_lcdtg_send(u8 adrs, u8 data) | ||
141 | { | ||
142 | corgi_ssp_dac_put(((adrs & 0x07) << 5) | (data & 0x1f)); | ||
143 | } | ||
144 | |||
145 | void corgi_ssp_blduty_set(int duty) | ||
146 | { | ||
147 | corgi_ssp_lcdtg_send(0x02,duty); | ||
148 | } | ||
149 | |||
150 | EXPORT_SYMBOL(corgi_ssp_lcdtg_send); | ||
151 | EXPORT_SYMBOL(corgi_ssp_blduty_set); | ||
152 | |||
153 | /* | ||
154 | * Max1111 Routines | ||
155 | */ | ||
156 | int corgi_ssp_max1111_get(ulong data) | ||
157 | { | ||
158 | unsigned long flag; | ||
159 | long voltage = 0, voltage1 = 0, voltage2 = 0; | ||
160 | |||
161 | spin_lock_irqsave(&corgi_ssp_lock, flag); | ||
162 | if (ssp_machinfo->cs_max1111 >= 0) | ||
163 | GPCR(ssp_machinfo->cs_max1111) = GPIO_bit(ssp_machinfo->cs_max1111); | ||
164 | ssp_disable(&corgi_ssp_dev); | ||
165 | ssp_config(&corgi_ssp_dev, (SSCR0_Motorola | (SSCR0_DSS & 0x07 )), 0, 0, SSCR0_SerClkDiv(ssp_machinfo->clk_max1111)); | ||
166 | ssp_enable(&corgi_ssp_dev); | ||
167 | |||
168 | udelay(1); | ||
169 | |||
170 | /* TB1/RB1 */ | ||
171 | ssp_write_word(&corgi_ssp_dev,data); | ||
172 | ssp_read_word(&corgi_ssp_dev, (u32*)&voltage1); /* null read */ | ||
173 | |||
174 | /* TB12/RB2 */ | ||
175 | ssp_write_word(&corgi_ssp_dev,0); | ||
176 | ssp_read_word(&corgi_ssp_dev, (u32*)&voltage1); | ||
177 | |||
178 | /* TB13/RB3*/ | ||
179 | ssp_write_word(&corgi_ssp_dev,0); | ||
180 | ssp_read_word(&corgi_ssp_dev, (u32*)&voltage2); | ||
181 | |||
182 | ssp_disable(&corgi_ssp_dev); | ||
183 | ssp_config(&corgi_ssp_dev, (SSCR0_National | (SSCR0_DSS & 0x0b )), 0, 0, SSCR0_SerClkDiv(ssp_machinfo->clk_ads7846)); | ||
184 | ssp_enable(&corgi_ssp_dev); | ||
185 | if (ssp_machinfo->cs_max1111 >= 0) | ||
186 | GPSR(ssp_machinfo->cs_max1111) = GPIO_bit(ssp_machinfo->cs_max1111); | ||
187 | spin_unlock_irqrestore(&corgi_ssp_lock, flag); | ||
188 | |||
189 | if (voltage1 & 0xc0 || voltage2 & 0x3f) | ||
190 | voltage = -1; | ||
191 | else | ||
192 | voltage = ((voltage1 << 2) & 0xfc) | ((voltage2 >> 6) & 0x03); | ||
193 | |||
194 | return voltage; | ||
195 | } | ||
196 | |||
197 | EXPORT_SYMBOL(corgi_ssp_max1111_get); | ||
198 | |||
199 | /* | ||
200 | * Support Routines | ||
201 | */ | ||
202 | |||
203 | void __init corgi_ssp_set_machinfo(struct corgissp_machinfo *machinfo) | ||
204 | { | ||
205 | ssp_machinfo = machinfo; | ||
206 | } | ||
207 | |||
208 | static int __init corgi_ssp_probe(struct platform_device *dev) | ||
209 | { | ||
210 | int ret; | ||
211 | |||
212 | /* Chip Select - Disable All */ | ||
213 | if (ssp_machinfo->cs_lcdcon >= 0) | ||
214 | pxa_gpio_mode(ssp_machinfo->cs_lcdcon | GPIO_OUT | GPIO_DFLT_HIGH); | ||
215 | if (ssp_machinfo->cs_max1111 >= 0) | ||
216 | pxa_gpio_mode(ssp_machinfo->cs_max1111 | GPIO_OUT | GPIO_DFLT_HIGH); | ||
217 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
218 | pxa_gpio_mode(ssp_machinfo->cs_ads7846 | GPIO_OUT | GPIO_DFLT_HIGH); | ||
219 | |||
220 | ret = ssp_init(&corgi_ssp_dev, ssp_machinfo->port, 0); | ||
221 | |||
222 | if (ret) | ||
223 | printk(KERN_ERR "Unable to register SSP handler!\n"); | ||
224 | else { | ||
225 | ssp_disable(&corgi_ssp_dev); | ||
226 | ssp_config(&corgi_ssp_dev, (SSCR0_National | (SSCR0_DSS & 0x0b )), 0, 0, SSCR0_SerClkDiv(ssp_machinfo->clk_ads7846)); | ||
227 | ssp_enable(&corgi_ssp_dev); | ||
228 | } | ||
229 | |||
230 | return ret; | ||
231 | } | ||
232 | |||
233 | static int corgi_ssp_remove(struct platform_device *dev) | ||
234 | { | ||
235 | ssp_exit(&corgi_ssp_dev); | ||
236 | return 0; | ||
237 | } | ||
238 | |||
239 | static int corgi_ssp_suspend(struct platform_device *dev, pm_message_t state) | ||
240 | { | ||
241 | ssp_flush(&corgi_ssp_dev); | ||
242 | ssp_save_state(&corgi_ssp_dev,&corgi_ssp_state); | ||
243 | |||
244 | return 0; | ||
245 | } | ||
246 | |||
247 | static int corgi_ssp_resume(struct platform_device *dev) | ||
248 | { | ||
249 | if (ssp_machinfo->cs_lcdcon >= 0) | ||
250 | GPSR(ssp_machinfo->cs_lcdcon) = GPIO_bit(ssp_machinfo->cs_lcdcon); /* High - Disable LCD Control/Timing Gen */ | ||
251 | if (ssp_machinfo->cs_max1111 >= 0) | ||
252 | GPSR(ssp_machinfo->cs_max1111) = GPIO_bit(ssp_machinfo->cs_max1111); /* High - Disable MAX1111*/ | ||
253 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
254 | GPSR(ssp_machinfo->cs_ads7846) = GPIO_bit(ssp_machinfo->cs_ads7846); /* High - Disable ADS7846*/ | ||
255 | ssp_restore_state(&corgi_ssp_dev,&corgi_ssp_state); | ||
256 | ssp_enable(&corgi_ssp_dev); | ||
257 | |||
258 | return 0; | ||
259 | } | ||
260 | |||
261 | static struct platform_driver corgissp_driver = { | ||
262 | .probe = corgi_ssp_probe, | ||
263 | .remove = corgi_ssp_remove, | ||
264 | .suspend = corgi_ssp_suspend, | ||
265 | .resume = corgi_ssp_resume, | ||
266 | .driver = { | ||
267 | .name = "corgi-ssp", | ||
268 | }, | ||
269 | }; | ||
270 | |||
271 | int __init corgi_ssp_init(void) | ||
272 | { | ||
273 | return platform_driver_register(&corgissp_driver); | ||
274 | } | ||
275 | |||
276 | arch_initcall(corgi_ssp_init); | ||
diff --git a/arch/arm/mach-pxa/include/mach/corgi.h b/arch/arm/mach-pxa/include/mach/corgi.h index 585970ef08ce..7239281788de 100644 --- a/arch/arm/mach-pxa/include/mach/corgi.h +++ b/arch/arm/mach-pxa/include/mach/corgi.h | |||
@@ -113,6 +113,7 @@ | |||
113 | * Shared data structures | 113 | * Shared data structures |
114 | */ | 114 | */ |
115 | extern struct platform_device corgiscoop_device; | 115 | extern struct platform_device corgiscoop_device; |
116 | extern struct platform_device corgissp_device; | ||
116 | 117 | ||
117 | #endif /* __ASM_ARCH_CORGI_H */ | 118 | #endif /* __ASM_ARCH_CORGI_H */ |
118 | 119 | ||
diff --git a/arch/arm/mach-pxa/include/mach/spitz.h b/arch/arm/mach-pxa/include/mach/spitz.h index e8488dfb7e91..fa1998caa78e 100644 --- a/arch/arm/mach-pxa/include/mach/spitz.h +++ b/arch/arm/mach-pxa/include/mach/spitz.h | |||
@@ -187,4 +187,5 @@ | |||
187 | */ | 187 | */ |
188 | extern struct platform_device spitzscoop_device; | 188 | extern struct platform_device spitzscoop_device; |
189 | extern struct platform_device spitzscoop2_device; | 189 | extern struct platform_device spitzscoop2_device; |
190 | extern struct platform_device spitzssp_device; | ||
190 | extern struct sharpsl_charger_machinfo spitz_pm_machinfo; | 191 | extern struct sharpsl_charger_machinfo spitz_pm_machinfo; |
diff --git a/arch/arm/mach-pxa/include/mach/tosa.h b/arch/arm/mach-pxa/include/mach/tosa.h index 8bce6d8615b9..4df2d38507dc 100644 --- a/arch/arm/mach-pxa/include/mach/tosa.h +++ b/arch/arm/mach-pxa/include/mach/tosa.h | |||
@@ -193,4 +193,7 @@ | |||
193 | #define TOSA_KEY_MAIL KEY_MAIL | 193 | #define TOSA_KEY_MAIL KEY_MAIL |
194 | #endif | 194 | #endif |
195 | 195 | ||
196 | struct spi_device; | ||
197 | extern int tosa_bl_enable(struct spi_device *spi, int enable); | ||
198 | |||
196 | #endif /* _ASM_ARCH_TOSA_H_ */ | 199 | #endif /* _ASM_ARCH_TOSA_H_ */ |
diff --git a/arch/arm/mach-pxa/sharpsl_pm.c b/arch/arm/mach-pxa/sharpsl_pm.c index 15c2f1a8623b..f0845c1b001c 100644 --- a/arch/arm/mach-pxa/sharpsl_pm.c +++ b/arch/arm/mach-pxa/sharpsl_pm.c | |||
@@ -116,20 +116,33 @@ struct battery_thresh spitz_battery_levels_noac[] = { | |||
116 | { 0, 0}, | 116 | { 0, 0}, |
117 | }; | 117 | }; |
118 | 118 | ||
119 | /* MAX1111 Commands */ | ||
120 | #define MAXCTRL_PD0 1u << 0 | ||
121 | #define MAXCTRL_PD1 1u << 1 | ||
122 | #define MAXCTRL_SGL 1u << 2 | ||
123 | #define MAXCTRL_UNI 1u << 3 | ||
124 | #define MAXCTRL_SEL_SH 4 | ||
125 | #define MAXCTRL_STR 1u << 7 | ||
126 | |||
119 | /* | 127 | /* |
120 | * Read MAX1111 ADC | 128 | * Read MAX1111 ADC |
121 | */ | 129 | */ |
122 | extern int max1111_read_channel(int); | ||
123 | |||
124 | int sharpsl_pm_pxa_read_max1111(int channel) | 130 | int sharpsl_pm_pxa_read_max1111(int channel) |
125 | { | 131 | { |
126 | if (machine_is_tosa()) // Ugly, better move this function into another module | 132 | if (machine_is_tosa()) // Ugly, better move this function into another module |
127 | return 0; | 133 | return 0; |
128 | 134 | ||
135 | #ifdef CONFIG_CORGI_SSP_DEPRECATED | ||
136 | return corgi_ssp_max1111_get((channel << MAXCTRL_SEL_SH) | MAXCTRL_PD0 | MAXCTRL_PD1 | ||
137 | | MAXCTRL_SGL | MAXCTRL_UNI | MAXCTRL_STR); | ||
138 | #else | ||
139 | extern int max1111_read_channel(int); | ||
140 | |||
129 | /* max1111 accepts channels from 0-3, however, | 141 | /* max1111 accepts channels from 0-3, however, |
130 | * it is encoded from 0-7 here in the code. | 142 | * it is encoded from 0-7 here in the code. |
131 | */ | 143 | */ |
132 | return max1111_read_channel(channel >> 1); | 144 | return max1111_read_channel(channel >> 1); |
145 | #endif | ||
133 | } | 146 | } |
134 | 147 | ||
135 | void sharpsl_pm_pxa_init(void) | 148 | void sharpsl_pm_pxa_init(void) |
diff --git a/arch/arm/mach-pxa/tosa.c b/arch/arm/mach-pxa/tosa.c index a6c4694359ca..224897a67d15 100644 --- a/arch/arm/mach-pxa/tosa.c +++ b/arch/arm/mach-pxa/tosa.c | |||
@@ -31,6 +31,7 @@ | |||
31 | #include <linux/gpio.h> | 31 | #include <linux/gpio.h> |
32 | #include <linux/pda_power.h> | 32 | #include <linux/pda_power.h> |
33 | #include <linux/rfkill.h> | 33 | #include <linux/rfkill.h> |
34 | #include <linux/spi/spi.h> | ||
34 | 35 | ||
35 | #include <asm/setup.h> | 36 | #include <asm/setup.h> |
36 | #include <asm/mach-types.h> | 37 | #include <asm/mach-types.h> |
@@ -42,6 +43,7 @@ | |||
42 | #include <mach/mmc.h> | 43 | #include <mach/mmc.h> |
43 | #include <mach/udc.h> | 44 | #include <mach/udc.h> |
44 | #include <mach/tosa_bt.h> | 45 | #include <mach/tosa_bt.h> |
46 | #include <mach/pxa2xx_spi.h> | ||
45 | 47 | ||
46 | #include <asm/mach/arch.h> | 48 | #include <asm/mach/arch.h> |
47 | #include <mach/tosa.h> | 49 | #include <mach/tosa.h> |
@@ -612,7 +614,7 @@ static int tosa_tc6393xb_enable(struct platform_device *dev) | |||
612 | rc = gpio_request(TOSA_GPIO_TC6393XB_SUSPEND, "tc6393xb #suspend"); | 614 | rc = gpio_request(TOSA_GPIO_TC6393XB_SUSPEND, "tc6393xb #suspend"); |
613 | if (rc) | 615 | if (rc) |
614 | goto err_req_suspend; | 616 | goto err_req_suspend; |
615 | rc = gpio_request(TOSA_GPIO_TC6393XB_L3V_ON, "l3v"); | 617 | rc = gpio_request(TOSA_GPIO_TC6393XB_L3V_ON, "tc6393xb l3v"); |
616 | if (rc) | 618 | if (rc) |
617 | goto err_req_l3v; | 619 | goto err_req_l3v; |
618 | rc = gpio_direction_output(TOSA_GPIO_TC6393XB_L3V_ON, 0); | 620 | rc = gpio_direction_output(TOSA_GPIO_TC6393XB_L3V_ON, 0); |
@@ -772,6 +774,20 @@ static struct platform_device tosa_bt_device = { | |||
772 | .dev.platform_data = &tosa_bt_data, | 774 | .dev.platform_data = &tosa_bt_data, |
773 | }; | 775 | }; |
774 | 776 | ||
777 | static struct pxa2xx_spi_master pxa_ssp_master_info = { | ||
778 | .num_chipselect = 1, | ||
779 | }; | ||
780 | |||
781 | static struct spi_board_info spi_board_info[] __initdata = { | ||
782 | { | ||
783 | .modalias = "tosa-lcd", | ||
784 | // .platform_data | ||
785 | .max_speed_hz = 28750, | ||
786 | .bus_num = 2, | ||
787 | .chip_select = 0, | ||
788 | .mode = SPI_MODE_0, | ||
789 | }, | ||
790 | }; | ||
775 | 791 | ||
776 | static struct platform_device *devices[] __initdata = { | 792 | static struct platform_device *devices[] __initdata = { |
777 | &tosascoop_device, | 793 | &tosascoop_device, |
@@ -826,6 +842,9 @@ static void __init tosa_init(void) | |||
826 | pxa_set_i2c_info(NULL); | 842 | pxa_set_i2c_info(NULL); |
827 | platform_scoop_config = &tosa_pcmcia_config; | 843 | platform_scoop_config = &tosa_pcmcia_config; |
828 | 844 | ||
845 | pxa2xx_set_spi_info(2, &pxa_ssp_master_info); | ||
846 | spi_register_board_info(spi_board_info, ARRAY_SIZE(spi_board_info)); | ||
847 | |||
829 | clk_add_alias("CLK_CK3P6MI", &tc6393xb_device.dev, "GPIO11_CLK", NULL); | 848 | clk_add_alias("CLK_CK3P6MI", &tc6393xb_device.dev, "GPIO11_CLK", NULL); |
830 | 849 | ||
831 | platform_add_devices(devices, ARRAY_SIZE(devices)); | 850 | platform_add_devices(devices, ARRAY_SIZE(devices)); |
diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig index d1193884d76d..ab5f7a21350b 100644 --- a/arch/arm/mm/Kconfig +++ b/arch/arm/mm/Kconfig | |||
@@ -400,9 +400,9 @@ config CPU_FEROCEON_OLD_ID | |||
400 | # ARMv6 | 400 | # ARMv6 |
401 | config CPU_V6 | 401 | config CPU_V6 |
402 | bool "Support ARM V6 processor" | 402 | bool "Support ARM V6 processor" |
403 | depends on ARCH_INTEGRATOR || MACH_REALVIEW_EB || ARCH_OMAP2 || ARCH_MX3 || ARCH_MSM7X00A || MACH_REALVIEW_PB11MP || MACH_REALVIEW_PB1176 | 403 | depends on ARCH_INTEGRATOR || MACH_REALVIEW_EB || ARCH_OMAP2 || ARCH_MX3 || ARCH_MSM || MACH_REALVIEW_PB11MP || MACH_REALVIEW_PB1176 |
404 | default y if ARCH_MX3 | 404 | default y if ARCH_MX3 |
405 | default y if ARCH_MSM7X00A | 405 | default y if ARCH_MSM |
406 | select CPU_32v6 | 406 | select CPU_32v6 |
407 | select CPU_ABRT_EV6 | 407 | select CPU_ABRT_EV6 |
408 | select CPU_PABRT_NOIFAR | 408 | select CPU_PABRT_NOIFAR |
diff --git a/arch/arm/mm/proc-v7.S b/arch/arm/mm/proc-v7.S index 34e424041927..07f82db70945 100644 --- a/arch/arm/mm/proc-v7.S +++ b/arch/arm/mm/proc-v7.S | |||
@@ -180,8 +180,8 @@ __v7_setup: | |||
180 | mov r10, #0x1f @ domains 0, 1 = manager | 180 | mov r10, #0x1f @ domains 0, 1 = manager |
181 | mcr p15, 0, r10, c3, c0, 0 @ load domain access register | 181 | mcr p15, 0, r10, c3, c0, 0 @ load domain access register |
182 | #endif | 182 | #endif |
183 | ldr r5, =0x40e040e0 | 183 | ldr r5, =0xff0aa1a8 |
184 | ldr r6, =0xff0aa1a8 | 184 | ldr r6, =0x40e040e0 |
185 | mcr p15, 0, r5, c10, c2, 0 @ write PRRR | 185 | mcr p15, 0, r5, c10, c2, 0 @ write PRRR |
186 | mcr p15, 0, r6, c10, c2, 1 @ write NMRR | 186 | mcr p15, 0, r6, c10, c2, 1 @ write NMRR |
187 | adr r5, v7_crval | 187 | adr r5, v7_crval |
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index 5f149b030c0f..653574bc19cf 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig | |||
@@ -238,21 +238,8 @@ config MIPS_SIM | |||
238 | This option enables support for MIPS Technologies MIPSsim software | 238 | This option enables support for MIPS Technologies MIPSsim software |
239 | emulator. | 239 | emulator. |
240 | 240 | ||
241 | config MARKEINS | 241 | config MACH_EMMA |
242 | bool "NEC EMMA2RH Mark-eins" | 242 | bool "NEC EMMA series based machines" |
243 | select CEVT_R4K | ||
244 | select CSRC_R4K | ||
245 | select DMA_NONCOHERENT | ||
246 | select HW_HAS_PCI | ||
247 | select IRQ_CPU | ||
248 | select SWAP_IO_SPACE | ||
249 | select SYS_SUPPORTS_32BIT_KERNEL | ||
250 | select SYS_SUPPORTS_BIG_ENDIAN | ||
251 | select SYS_SUPPORTS_LITTLE_ENDIAN | ||
252 | select SYS_HAS_CPU_R5000 | ||
253 | help | ||
254 | This enables support for the R5432-based NEC Mark-eins | ||
255 | boards with R5500 CPU. | ||
256 | 243 | ||
257 | config MACH_VR41XX | 244 | config MACH_VR41XX |
258 | bool "NEC VR4100 series based machines" | 245 | bool "NEC VR4100 series based machines" |
@@ -261,6 +248,19 @@ config MACH_VR41XX | |||
261 | select SYS_HAS_CPU_VR41XX | 248 | select SYS_HAS_CPU_VR41XX |
262 | select GENERIC_HARDIRQS_NO__DO_IRQ | 249 | select GENERIC_HARDIRQS_NO__DO_IRQ |
263 | 250 | ||
251 | config NXP_STB220 | ||
252 | bool "NXP STB220 board" | ||
253 | select SOC_PNX833X | ||
254 | help | ||
255 | Support for NXP Semiconductors STB220 Development Board. | ||
256 | |||
257 | config NXP_STB225 | ||
258 | bool "NXP 225 board" | ||
259 | select SOC_PNX833X | ||
260 | select SOC_PNX8335 | ||
261 | help | ||
262 | Support for NXP Semiconductors STB225 Development Board. | ||
263 | |||
264 | config PNX8550_JBS | 264 | config PNX8550_JBS |
265 | bool "NXP PNX8550 based JBS board" | 265 | bool "NXP PNX8550 based JBS board" |
266 | select PNX8550 | 266 | select PNX8550 |
@@ -601,6 +601,7 @@ endchoice | |||
601 | 601 | ||
602 | source "arch/mips/alchemy/Kconfig" | 602 | source "arch/mips/alchemy/Kconfig" |
603 | source "arch/mips/basler/excite/Kconfig" | 603 | source "arch/mips/basler/excite/Kconfig" |
604 | source "arch/mips/emma/Kconfig" | ||
604 | source "arch/mips/jazz/Kconfig" | 605 | source "arch/mips/jazz/Kconfig" |
605 | source "arch/mips/lasat/Kconfig" | 606 | source "arch/mips/lasat/Kconfig" |
606 | source "arch/mips/pmc-sierra/Kconfig" | 607 | source "arch/mips/pmc-sierra/Kconfig" |
@@ -849,6 +850,24 @@ config MIPS_RM9122 | |||
849 | bool | 850 | bool |
850 | select SERIAL_RM9000 | 851 | select SERIAL_RM9000 |
851 | 852 | ||
853 | config SOC_PNX833X | ||
854 | bool | ||
855 | select CEVT_R4K | ||
856 | select CSRC_R4K | ||
857 | select IRQ_CPU | ||
858 | select DMA_NONCOHERENT | ||
859 | select SYS_HAS_CPU_MIPS32_R2 | ||
860 | select SYS_SUPPORTS_32BIT_KERNEL | ||
861 | select SYS_SUPPORTS_LITTLE_ENDIAN | ||
862 | select SYS_SUPPORTS_BIG_ENDIAN | ||
863 | select GENERIC_HARDIRQS_NO__DO_IRQ | ||
864 | select GENERIC_GPIO | ||
865 | select CPU_MIPSR2_IRQ_VI | ||
866 | |||
867 | config SOC_PNX8335 | ||
868 | bool | ||
869 | select SOC_PNX833X | ||
870 | |||
852 | config PNX8550 | 871 | config PNX8550 |
853 | bool | 872 | bool |
854 | select SOC_PNX8550 | 873 | select SOC_PNX8550 |
@@ -1092,6 +1111,16 @@ config CPU_R5432 | |||
1092 | select CPU_SUPPORTS_32BIT_KERNEL | 1111 | select CPU_SUPPORTS_32BIT_KERNEL |
1093 | select CPU_SUPPORTS_64BIT_KERNEL | 1112 | select CPU_SUPPORTS_64BIT_KERNEL |
1094 | 1113 | ||
1114 | config CPU_R5500 | ||
1115 | bool "R5500" | ||
1116 | depends on SYS_HAS_CPU_R5500 | ||
1117 | select CPU_HAS_LLSC | ||
1118 | select CPU_SUPPORTS_32BIT_KERNEL | ||
1119 | select CPU_SUPPORTS_64BIT_KERNEL | ||
1120 | help | ||
1121 | NEC VR5500 and VR5500A series processors implement 64-bit MIPS IV | ||
1122 | instruction set. | ||
1123 | |||
1095 | config CPU_R6000 | 1124 | config CPU_R6000 |
1096 | bool "R6000" | 1125 | bool "R6000" |
1097 | depends on EXPERIMENTAL | 1126 | depends on EXPERIMENTAL |
@@ -1202,6 +1231,9 @@ config SYS_HAS_CPU_R5000 | |||
1202 | config SYS_HAS_CPU_R5432 | 1231 | config SYS_HAS_CPU_R5432 |
1203 | bool | 1232 | bool |
1204 | 1233 | ||
1234 | config SYS_HAS_CPU_R5500 | ||
1235 | bool | ||
1236 | |||
1205 | config SYS_HAS_CPU_R6000 | 1237 | config SYS_HAS_CPU_R6000 |
1206 | bool | 1238 | bool |
1207 | 1239 | ||
diff --git a/arch/mips/Makefile b/arch/mips/Makefile index 7f39fd8a91fe..28c55f608913 100644 --- a/arch/mips/Makefile +++ b/arch/mips/Makefile | |||
@@ -131,6 +131,8 @@ cflags-$(CONFIG_CPU_MIPS64_R2) += $(call cc-option,-march=mips64r2,-mips64r2 -U_ | |||
131 | cflags-$(CONFIG_CPU_R5000) += -march=r5000 -Wa,--trap | 131 | cflags-$(CONFIG_CPU_R5000) += -march=r5000 -Wa,--trap |
132 | cflags-$(CONFIG_CPU_R5432) += $(call cc-option,-march=r5400,-march=r5000) \ | 132 | cflags-$(CONFIG_CPU_R5432) += $(call cc-option,-march=r5400,-march=r5000) \ |
133 | -Wa,--trap | 133 | -Wa,--trap |
134 | cflags-$(CONFIG_CPU_R5500) += $(call cc-option,-march=r5500,-march=r5000) \ | ||
135 | -Wa,--trap | ||
134 | cflags-$(CONFIG_CPU_NEVADA) += $(call cc-option,-march=rm5200,-march=r5000) \ | 136 | cflags-$(CONFIG_CPU_NEVADA) += $(call cc-option,-march=rm5200,-march=r5000) \ |
135 | -Wa,--trap | 137 | -Wa,--trap |
136 | cflags-$(CONFIG_CPU_RM7000) += $(call cc-option,-march=rm7000,-march=r5000) \ | 138 | cflags-$(CONFIG_CPU_RM7000) += $(call cc-option,-march=rm7000,-march=r5000) \ |
@@ -381,6 +383,14 @@ load-$(CONFIG_CASIO_E55) += 0xffffffff80004000 | |||
381 | # | 383 | # |
382 | load-$(CONFIG_TANBAC_TB022X) += 0xffffffff80000000 | 384 | load-$(CONFIG_TANBAC_TB022X) += 0xffffffff80000000 |
383 | 385 | ||
386 | # NXP STB225 | ||
387 | core-$(CONFIG_SOC_PNX833X) += arch/mips/nxp/pnx833x/common/ | ||
388 | cflags-$(CONFIG_SOC_PNX833X) += -Iarch/mips/include/asm/mach-pnx833x | ||
389 | libs-$(CONFIG_NXP_STB220) += arch/mips/nxp/pnx833x/stb22x/ | ||
390 | load-$(CONFIG_NXP_STB220) += 0xffffffff80001000 | ||
391 | libs-$(CONFIG_NXP_STB225) += arch/mips/nxp/pnx833x/stb22x/ | ||
392 | load-$(CONFIG_NXP_STB225) += 0xffffffff80001000 | ||
393 | |||
384 | # | 394 | # |
385 | # Common NXP PNX8550 | 395 | # Common NXP PNX8550 |
386 | # | 396 | # |
@@ -399,14 +409,17 @@ load-$(CONFIG_PNX8550_JBS) += 0xffffffff80060000 | |||
399 | libs-$(CONFIG_PNX8550_STB810) += arch/mips/nxp/pnx8550/stb810/ | 409 | libs-$(CONFIG_PNX8550_STB810) += arch/mips/nxp/pnx8550/stb810/ |
400 | load-$(CONFIG_PNX8550_STB810) += 0xffffffff80060000 | 410 | load-$(CONFIG_PNX8550_STB810) += 0xffffffff80060000 |
401 | 411 | ||
402 | # NEC EMMA2RH boards | ||
403 | # | 412 | # |
404 | core-$(CONFIG_EMMA2RH) += arch/mips/emma2rh/common/ | 413 | # Common NEC EMMAXXX |
405 | cflags-$(CONFIG_EMMA2RH) += -I$(srctree)/arch/mips/include/asm/mach-emma2rh | 414 | # |
415 | core-$(CONFIG_SOC_EMMA) += arch/mips/emma/common/ | ||
416 | cflags-$(CONFIG_SOC_EMMA2RH) += -I$(srctree)/arch/mips/include/asm/mach-emma2rh | ||
406 | 417 | ||
418 | # | ||
407 | # NEC EMMA2RH Mark-eins | 419 | # NEC EMMA2RH Mark-eins |
408 | core-$(CONFIG_MARKEINS) += arch/mips/emma2rh/markeins/ | 420 | # |
409 | load-$(CONFIG_MARKEINS) += 0xffffffff88100000 | 421 | core-$(CONFIG_NEC_MARKEINS) += arch/mips/emma/markeins/ |
422 | load-$(CONFIG_NEC_MARKEINS) += 0xffffffff88100000 | ||
410 | 423 | ||
411 | # | 424 | # |
412 | # SGI IP22 (Indy/Indigo2) | 425 | # SGI IP22 (Indy/Indigo2) |
diff --git a/arch/mips/alchemy/common/platform.c b/arch/mips/alchemy/common/platform.c index dc8a67efac28..5c76c6448e04 100644 --- a/arch/mips/alchemy/common/platform.c +++ b/arch/mips/alchemy/common/platform.c | |||
@@ -17,6 +17,8 @@ | |||
17 | #include <linux/init.h> | 17 | #include <linux/init.h> |
18 | 18 | ||
19 | #include <asm/mach-au1x00/au1xxx.h> | 19 | #include <asm/mach-au1x00/au1xxx.h> |
20 | #include <asm/mach-au1x00/au1xxx_dbdma.h> | ||
21 | #include <asm/mach-au1x00/au1100_mmc.h> | ||
20 | 22 | ||
21 | #define PORT(_base, _irq) \ | 23 | #define PORT(_base, _irq) \ |
22 | { \ | 24 | { \ |
@@ -163,24 +165,6 @@ static struct resource au1xxx_usb_gdt_resources[] = { | |||
163 | }, | 165 | }, |
164 | }; | 166 | }; |
165 | 167 | ||
166 | static struct resource au1xxx_mmc_resources[] = { | ||
167 | [0] = { | ||
168 | .start = SD0_PHYS_ADDR, | ||
169 | .end = SD0_PHYS_ADDR + 0x7ffff, | ||
170 | .flags = IORESOURCE_MEM, | ||
171 | }, | ||
172 | [1] = { | ||
173 | .start = SD1_PHYS_ADDR, | ||
174 | .end = SD1_PHYS_ADDR + 0x7ffff, | ||
175 | .flags = IORESOURCE_MEM, | ||
176 | }, | ||
177 | [2] = { | ||
178 | .start = AU1200_SD_INT, | ||
179 | .end = AU1200_SD_INT, | ||
180 | .flags = IORESOURCE_IRQ, | ||
181 | } | ||
182 | }; | ||
183 | |||
184 | static u64 udc_dmamask = DMA_32BIT_MASK; | 168 | static u64 udc_dmamask = DMA_32BIT_MASK; |
185 | 169 | ||
186 | static struct platform_device au1xxx_usb_gdt_device = { | 170 | static struct platform_device au1xxx_usb_gdt_device = { |
@@ -249,16 +233,79 @@ static struct platform_device au1200_lcd_device = { | |||
249 | 233 | ||
250 | static u64 au1xxx_mmc_dmamask = DMA_32BIT_MASK; | 234 | static u64 au1xxx_mmc_dmamask = DMA_32BIT_MASK; |
251 | 235 | ||
252 | static struct platform_device au1xxx_mmc_device = { | 236 | extern struct au1xmmc_platform_data au1xmmc_platdata[2]; |
237 | |||
238 | static struct resource au1200_mmc0_resources[] = { | ||
239 | [0] = { | ||
240 | .start = SD0_PHYS_ADDR, | ||
241 | .end = SD0_PHYS_ADDR + 0x7ffff, | ||
242 | .flags = IORESOURCE_MEM, | ||
243 | }, | ||
244 | [1] = { | ||
245 | .start = AU1200_SD_INT, | ||
246 | .end = AU1200_SD_INT, | ||
247 | .flags = IORESOURCE_IRQ, | ||
248 | }, | ||
249 | [2] = { | ||
250 | .start = DSCR_CMD0_SDMS_TX0, | ||
251 | .end = DSCR_CMD0_SDMS_TX0, | ||
252 | .flags = IORESOURCE_DMA, | ||
253 | }, | ||
254 | [3] = { | ||
255 | .start = DSCR_CMD0_SDMS_RX0, | ||
256 | .end = DSCR_CMD0_SDMS_RX0, | ||
257 | .flags = IORESOURCE_DMA, | ||
258 | } | ||
259 | }; | ||
260 | |||
261 | static struct platform_device au1200_mmc0_device = { | ||
253 | .name = "au1xxx-mmc", | 262 | .name = "au1xxx-mmc", |
254 | .id = 0, | 263 | .id = 0, |
255 | .dev = { | 264 | .dev = { |
256 | .dma_mask = &au1xxx_mmc_dmamask, | 265 | .dma_mask = &au1xxx_mmc_dmamask, |
257 | .coherent_dma_mask = DMA_32BIT_MASK, | 266 | .coherent_dma_mask = DMA_32BIT_MASK, |
267 | .platform_data = &au1xmmc_platdata[0], | ||
258 | }, | 268 | }, |
259 | .num_resources = ARRAY_SIZE(au1xxx_mmc_resources), | 269 | .num_resources = ARRAY_SIZE(au1200_mmc0_resources), |
260 | .resource = au1xxx_mmc_resources, | 270 | .resource = au1200_mmc0_resources, |
261 | }; | 271 | }; |
272 | |||
273 | #ifndef CONFIG_MIPS_DB1200 | ||
274 | static struct resource au1200_mmc1_resources[] = { | ||
275 | [0] = { | ||
276 | .start = SD1_PHYS_ADDR, | ||
277 | .end = SD1_PHYS_ADDR + 0x7ffff, | ||
278 | .flags = IORESOURCE_MEM, | ||
279 | }, | ||
280 | [1] = { | ||
281 | .start = AU1200_SD_INT, | ||
282 | .end = AU1200_SD_INT, | ||
283 | .flags = IORESOURCE_IRQ, | ||
284 | }, | ||
285 | [2] = { | ||
286 | .start = DSCR_CMD0_SDMS_TX1, | ||
287 | .end = DSCR_CMD0_SDMS_TX1, | ||
288 | .flags = IORESOURCE_DMA, | ||
289 | }, | ||
290 | [3] = { | ||
291 | .start = DSCR_CMD0_SDMS_RX1, | ||
292 | .end = DSCR_CMD0_SDMS_RX1, | ||
293 | .flags = IORESOURCE_DMA, | ||
294 | } | ||
295 | }; | ||
296 | |||
297 | static struct platform_device au1200_mmc1_device = { | ||
298 | .name = "au1xxx-mmc", | ||
299 | .id = 1, | ||
300 | .dev = { | ||
301 | .dma_mask = &au1xxx_mmc_dmamask, | ||
302 | .coherent_dma_mask = DMA_32BIT_MASK, | ||
303 | .platform_data = &au1xmmc_platdata[1], | ||
304 | }, | ||
305 | .num_resources = ARRAY_SIZE(au1200_mmc1_resources), | ||
306 | .resource = au1200_mmc1_resources, | ||
307 | }; | ||
308 | #endif /* #ifndef CONFIG_MIPS_DB1200 */ | ||
262 | #endif /* #ifdef CONFIG_SOC_AU1200 */ | 309 | #endif /* #ifdef CONFIG_SOC_AU1200 */ |
263 | 310 | ||
264 | static struct platform_device au1x00_pcmcia_device = { | 311 | static struct platform_device au1x00_pcmcia_device = { |
@@ -296,7 +343,10 @@ static struct platform_device *au1xxx_platform_devices[] __initdata = { | |||
296 | &au1xxx_usb_gdt_device, | 343 | &au1xxx_usb_gdt_device, |
297 | &au1xxx_usb_otg_device, | 344 | &au1xxx_usb_otg_device, |
298 | &au1200_lcd_device, | 345 | &au1200_lcd_device, |
299 | &au1xxx_mmc_device, | 346 | &au1200_mmc0_device, |
347 | #ifndef CONFIG_MIPS_DB1200 | ||
348 | &au1200_mmc1_device, | ||
349 | #endif | ||
300 | #endif | 350 | #endif |
301 | #ifdef SMBUS_PSC_BASE | 351 | #ifdef SMBUS_PSC_BASE |
302 | &pbdb_smbus_device, | 352 | &pbdb_smbus_device, |
diff --git a/arch/mips/alchemy/pb1200/platform.c b/arch/mips/alchemy/pb1200/platform.c index f8fb0aeac571..95303297c534 100644 --- a/arch/mips/alchemy/pb1200/platform.c +++ b/arch/mips/alchemy/pb1200/platform.c | |||
@@ -20,9 +20,90 @@ | |||
20 | 20 | ||
21 | #include <linux/dma-mapping.h> | 21 | #include <linux/dma-mapping.h> |
22 | #include <linux/init.h> | 22 | #include <linux/init.h> |
23 | #include <linux/leds.h> | ||
23 | #include <linux/platform_device.h> | 24 | #include <linux/platform_device.h> |
24 | 25 | ||
25 | #include <asm/mach-au1x00/au1xxx.h> | 26 | #include <asm/mach-au1x00/au1xxx.h> |
27 | #include <asm/mach-au1x00/au1100_mmc.h> | ||
28 | |||
29 | static int mmc_activity; | ||
30 | |||
31 | static void pb1200mmc0_set_power(void *mmc_host, int state) | ||
32 | { | ||
33 | if (state) | ||
34 | bcsr->board |= BCSR_BOARD_SD0PWR; | ||
35 | else | ||
36 | bcsr->board &= ~BCSR_BOARD_SD0PWR; | ||
37 | |||
38 | au_sync_delay(1); | ||
39 | } | ||
40 | |||
41 | static int pb1200mmc0_card_readonly(void *mmc_host) | ||
42 | { | ||
43 | return (bcsr->status & BCSR_STATUS_SD0WP) ? 1 : 0; | ||
44 | } | ||
45 | |||
46 | static int pb1200mmc0_card_inserted(void *mmc_host) | ||
47 | { | ||
48 | return (bcsr->sig_status & BCSR_INT_SD0INSERT) ? 1 : 0; | ||
49 | } | ||
50 | |||
51 | static void pb1200_mmcled_set(struct led_classdev *led, | ||
52 | enum led_brightness brightness) | ||
53 | { | ||
54 | if (brightness != LED_OFF) { | ||
55 | if (++mmc_activity == 1) | ||
56 | bcsr->disk_leds &= ~(1 << 8); | ||
57 | } else { | ||
58 | if (--mmc_activity == 0) | ||
59 | bcsr->disk_leds |= (1 << 8); | ||
60 | } | ||
61 | } | ||
62 | |||
63 | static struct led_classdev pb1200mmc_led = { | ||
64 | .brightness_set = pb1200_mmcled_set, | ||
65 | }; | ||
66 | |||
67 | #ifndef CONFIG_MIPS_DB1200 | ||
68 | static void pb1200mmc1_set_power(void *mmc_host, int state) | ||
69 | { | ||
70 | if (state) | ||
71 | bcsr->board |= BCSR_BOARD_SD1PWR; | ||
72 | else | ||
73 | bcsr->board &= ~BCSR_BOARD_SD1PWR; | ||
74 | |||
75 | au_sync_delay(1); | ||
76 | } | ||
77 | |||
78 | static int pb1200mmc1_card_readonly(void *mmc_host) | ||
79 | { | ||
80 | return (bcsr->status & BCSR_STATUS_SD1WP) ? 1 : 0; | ||
81 | } | ||
82 | |||
83 | static int pb1200mmc1_card_inserted(void *mmc_host) | ||
84 | { | ||
85 | return (bcsr->sig_status & BCSR_INT_SD1INSERT) ? 1 : 0; | ||
86 | } | ||
87 | #endif | ||
88 | |||
89 | const struct au1xmmc_platform_data au1xmmc_platdata[2] = { | ||
90 | [0] = { | ||
91 | .set_power = pb1200mmc0_set_power, | ||
92 | .card_inserted = pb1200mmc0_card_inserted, | ||
93 | .card_readonly = pb1200mmc0_card_readonly, | ||
94 | .cd_setup = NULL, /* use poll-timer in driver */ | ||
95 | .led = &pb1200mmc_led, | ||
96 | }, | ||
97 | #ifndef CONFIG_MIPS_DB1200 | ||
98 | [1] = { | ||
99 | .set_power = pb1200mmc1_set_power, | ||
100 | .card_inserted = pb1200mmc1_card_inserted, | ||
101 | .card_readonly = pb1200mmc1_card_readonly, | ||
102 | .cd_setup = NULL, /* use poll-timer in driver */ | ||
103 | .led = &pb1200mmc_led, | ||
104 | }, | ||
105 | #endif | ||
106 | }; | ||
26 | 107 | ||
27 | static struct resource ide_resources[] = { | 108 | static struct resource ide_resources[] = { |
28 | [0] = { | 109 | [0] = { |
diff --git a/arch/mips/configs/pnx8335-stb225_defconfig b/arch/mips/configs/pnx8335-stb225_defconfig new file mode 100644 index 000000000000..d9536522cff5 --- /dev/null +++ b/arch/mips/configs/pnx8335-stb225_defconfig | |||
@@ -0,0 +1,1149 @@ | |||
1 | # | ||
2 | # Automatically generated make config: don't edit | ||
3 | # Linux kernel version: 2.6.26 | ||
4 | # Sat Jul 26 09:02:59 2008 | ||
5 | # | ||
6 | CONFIG_MIPS=y | ||
7 | |||
8 | # | ||
9 | # Machine selection | ||
10 | # | ||
11 | # CONFIG_MACH_ALCHEMY is not set | ||
12 | # CONFIG_BASLER_EXCITE is not set | ||
13 | # CONFIG_BCM47XX is not set | ||
14 | # CONFIG_MIPS_COBALT is not set | ||
15 | # CONFIG_MACH_DECSTATION is not set | ||
16 | # CONFIG_MACH_JAZZ is not set | ||
17 | # CONFIG_LASAT is not set | ||
18 | # CONFIG_LEMOTE_FULONG is not set | ||
19 | # CONFIG_MIPS_MALTA is not set | ||
20 | # CONFIG_MIPS_SIM is not set | ||
21 | # CONFIG_MARKEINS is not set | ||
22 | # CONFIG_MACH_VR41XX is not set | ||
23 | # CONFIG_NXP_STB220 is not set | ||
24 | CONFIG_NXP_STB225=y | ||
25 | # CONFIG_PNX8550_JBS is not set | ||
26 | # CONFIG_PNX8550_STB810 is not set | ||
27 | # CONFIG_PMC_MSP is not set | ||
28 | # CONFIG_PMC_YOSEMITE is not set | ||
29 | # CONFIG_SGI_IP22 is not set | ||
30 | # CONFIG_SGI_IP27 is not set | ||
31 | # CONFIG_SGI_IP28 is not set | ||
32 | # CONFIG_SGI_IP32 is not set | ||
33 | # CONFIG_SIBYTE_CRHINE is not set | ||
34 | # CONFIG_SIBYTE_CARMEL is not set | ||
35 | # CONFIG_SIBYTE_CRHONE is not set | ||
36 | # CONFIG_SIBYTE_RHONE is not set | ||
37 | # CONFIG_SIBYTE_SWARM is not set | ||
38 | # CONFIG_SIBYTE_LITTLESUR is not set | ||
39 | # CONFIG_SIBYTE_SENTOSA is not set | ||
40 | # CONFIG_SIBYTE_BIGSUR is not set | ||
41 | # CONFIG_SNI_RM is not set | ||
42 | # CONFIG_MACH_TX39XX is not set | ||
43 | # CONFIG_MACH_TX49XX is not set | ||
44 | # CONFIG_WR_PPMC is not set | ||
45 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | ||
46 | # CONFIG_ARCH_HAS_ILOG2_U32 is not set | ||
47 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set | ||
48 | CONFIG_ARCH_SUPPORTS_OPROFILE=y | ||
49 | CONFIG_GENERIC_FIND_NEXT_BIT=y | ||
50 | CONFIG_GENERIC_HWEIGHT=y | ||
51 | CONFIG_GENERIC_CALIBRATE_DELAY=y | ||
52 | CONFIG_GENERIC_CLOCKEVENTS=y | ||
53 | CONFIG_GENERIC_TIME=y | ||
54 | CONFIG_GENERIC_CMOS_UPDATE=y | ||
55 | CONFIG_SCHED_NO_NO_OMIT_FRAME_POINTER=y | ||
56 | CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y | ||
57 | CONFIG_CEVT_R4K=y | ||
58 | CONFIG_CSRC_R4K=y | ||
59 | CONFIG_DMA_NONCOHERENT=y | ||
60 | CONFIG_DMA_NEED_PCI_MAP_STATE=y | ||
61 | # CONFIG_HOTPLUG_CPU is not set | ||
62 | # CONFIG_NO_IOPORT is not set | ||
63 | CONFIG_GENERIC_GPIO=y | ||
64 | # CONFIG_CPU_BIG_ENDIAN is not set | ||
65 | CONFIG_CPU_LITTLE_ENDIAN=y | ||
66 | CONFIG_SYS_SUPPORTS_BIG_ENDIAN=y | ||
67 | CONFIG_SYS_SUPPORTS_LITTLE_ENDIAN=y | ||
68 | CONFIG_IRQ_CPU=y | ||
69 | CONFIG_SOC_PNX833X=y | ||
70 | CONFIG_SOC_PNX8335=y | ||
71 | CONFIG_MIPS_L1_CACHE_SHIFT=5 | ||
72 | |||
73 | # | ||
74 | # CPU selection | ||
75 | # | ||
76 | # CONFIG_CPU_LOONGSON2 is not set | ||
77 | # CONFIG_CPU_MIPS32_R1 is not set | ||
78 | CONFIG_CPU_MIPS32_R2=y | ||
79 | # CONFIG_CPU_MIPS64_R1 is not set | ||
80 | # CONFIG_CPU_MIPS64_R2 is not set | ||
81 | # CONFIG_CPU_R3000 is not set | ||
82 | # CONFIG_CPU_TX39XX is not set | ||
83 | # CONFIG_CPU_VR41XX is not set | ||
84 | # CONFIG_CPU_R4300 is not set | ||
85 | # CONFIG_CPU_R4X00 is not set | ||
86 | # CONFIG_CPU_TX49XX is not set | ||
87 | # CONFIG_CPU_R5000 is not set | ||
88 | # CONFIG_CPU_R5432 is not set | ||
89 | # CONFIG_CPU_R6000 is not set | ||
90 | # CONFIG_CPU_NEVADA is not set | ||
91 | # CONFIG_CPU_R8000 is not set | ||
92 | # CONFIG_CPU_R10000 is not set | ||
93 | # CONFIG_CPU_RM7000 is not set | ||
94 | # CONFIG_CPU_RM9000 is not set | ||
95 | # CONFIG_CPU_SB1 is not set | ||
96 | CONFIG_SYS_HAS_CPU_MIPS32_R2=y | ||
97 | CONFIG_CPU_MIPS32=y | ||
98 | CONFIG_CPU_MIPSR2=y | ||
99 | CONFIG_SYS_SUPPORTS_32BIT_KERNEL=y | ||
100 | CONFIG_CPU_SUPPORTS_32BIT_KERNEL=y | ||
101 | |||
102 | # | ||
103 | # Kernel type | ||
104 | # | ||
105 | CONFIG_32BIT=y | ||
106 | # CONFIG_64BIT is not set | ||
107 | CONFIG_PAGE_SIZE_4KB=y | ||
108 | # CONFIG_PAGE_SIZE_8KB is not set | ||
109 | # CONFIG_PAGE_SIZE_16KB is not set | ||
110 | # CONFIG_PAGE_SIZE_64KB is not set | ||
111 | CONFIG_CPU_HAS_PREFETCH=y | ||
112 | CONFIG_MIPS_MT_DISABLED=y | ||
113 | # CONFIG_MIPS_MT_SMP is not set | ||
114 | # CONFIG_MIPS_MT_SMTC is not set | ||
115 | CONFIG_CPU_HAS_LLSC=y | ||
116 | CONFIG_CPU_MIPSR2_IRQ_VI=y | ||
117 | CONFIG_CPU_HAS_SYNC=y | ||
118 | CONFIG_GENERIC_HARDIRQS=y | ||
119 | CONFIG_GENERIC_IRQ_PROBE=y | ||
120 | CONFIG_CPU_SUPPORTS_HIGHMEM=y | ||
121 | CONFIG_ARCH_FLATMEM_ENABLE=y | ||
122 | CONFIG_ARCH_POPULATES_NODE_MAP=y | ||
123 | CONFIG_SELECT_MEMORY_MODEL=y | ||
124 | CONFIG_FLATMEM_MANUAL=y | ||
125 | # CONFIG_DISCONTIGMEM_MANUAL is not set | ||
126 | # CONFIG_SPARSEMEM_MANUAL is not set | ||
127 | CONFIG_FLATMEM=y | ||
128 | CONFIG_FLAT_NODE_MEM_MAP=y | ||
129 | # CONFIG_SPARSEMEM_STATIC is not set | ||
130 | # CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set | ||
131 | CONFIG_PAGEFLAGS_EXTENDED=y | ||
132 | CONFIG_SPLIT_PTLOCK_CPUS=4 | ||
133 | # CONFIG_RESOURCES_64BIT is not set | ||
134 | CONFIG_ZONE_DMA_FLAG=0 | ||
135 | CONFIG_VIRT_TO_BUS=y | ||
136 | CONFIG_TICK_ONESHOT=y | ||
137 | CONFIG_NO_HZ=y | ||
138 | CONFIG_HIGH_RES_TIMERS=y | ||
139 | CONFIG_GENERIC_CLOCKEVENTS_BUILD=y | ||
140 | # CONFIG_HZ_48 is not set | ||
141 | # CONFIG_HZ_100 is not set | ||
142 | CONFIG_HZ_128=y | ||
143 | # CONFIG_HZ_250 is not set | ||
144 | # CONFIG_HZ_256 is not set | ||
145 | # CONFIG_HZ_1000 is not set | ||
146 | # CONFIG_HZ_1024 is not set | ||
147 | CONFIG_SYS_SUPPORTS_ARBIT_HZ=y | ||
148 | CONFIG_HZ=128 | ||
149 | # CONFIG_PREEMPT_NONE is not set | ||
150 | CONFIG_PREEMPT_VOLUNTARY=y | ||
151 | # CONFIG_PREEMPT is not set | ||
152 | # CONFIG_KEXEC is not set | ||
153 | # CONFIG_SECCOMP is not set | ||
154 | CONFIG_LOCKDEP_SUPPORT=y | ||
155 | CONFIG_STACKTRACE_SUPPORT=y | ||
156 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | ||
157 | |||
158 | # | ||
159 | # General setup | ||
160 | # | ||
161 | CONFIG_EXPERIMENTAL=y | ||
162 | CONFIG_BROKEN_ON_SMP=y | ||
163 | CONFIG_INIT_ENV_ARG_LIMIT=32 | ||
164 | CONFIG_LOCALVERSION="" | ||
165 | # CONFIG_LOCALVERSION_AUTO is not set | ||
166 | # CONFIG_SWAP is not set | ||
167 | CONFIG_SYSVIPC=y | ||
168 | CONFIG_SYSVIPC_SYSCTL=y | ||
169 | # CONFIG_POSIX_MQUEUE is not set | ||
170 | # CONFIG_BSD_PROCESS_ACCT is not set | ||
171 | # CONFIG_TASKSTATS is not set | ||
172 | # CONFIG_AUDIT is not set | ||
173 | # CONFIG_IKCONFIG is not set | ||
174 | CONFIG_LOG_BUF_SHIFT=14 | ||
175 | # CONFIG_CGROUPS is not set | ||
176 | # CONFIG_GROUP_SCHED is not set | ||
177 | CONFIG_SYSFS_DEPRECATED=y | ||
178 | CONFIG_SYSFS_DEPRECATED_V2=y | ||
179 | # CONFIG_RELAY is not set | ||
180 | # CONFIG_NAMESPACES is not set | ||
181 | # CONFIG_BLK_DEV_INITRD is not set | ||
182 | CONFIG_CC_OPTIMIZE_FOR_SIZE=y | ||
183 | CONFIG_SYSCTL=y | ||
184 | CONFIG_EMBEDDED=y | ||
185 | CONFIG_SYSCTL_SYSCALL=y | ||
186 | CONFIG_SYSCTL_SYSCALL_CHECK=y | ||
187 | CONFIG_KALLSYMS=y | ||
188 | # CONFIG_KALLSYMS_EXTRA_PASS is not set | ||
189 | CONFIG_HOTPLUG=y | ||
190 | CONFIG_PRINTK=y | ||
191 | CONFIG_BUG=y | ||
192 | CONFIG_ELF_CORE=y | ||
193 | CONFIG_PCSPKR_PLATFORM=y | ||
194 | CONFIG_COMPAT_BRK=y | ||
195 | CONFIG_BASE_FULL=y | ||
196 | CONFIG_FUTEX=y | ||
197 | CONFIG_ANON_INODES=y | ||
198 | CONFIG_EPOLL=y | ||
199 | CONFIG_SIGNALFD=y | ||
200 | CONFIG_TIMERFD=y | ||
201 | CONFIG_EVENTFD=y | ||
202 | CONFIG_SHMEM=y | ||
203 | CONFIG_VM_EVENT_COUNTERS=y | ||
204 | CONFIG_SLAB=y | ||
205 | # CONFIG_SLUB is not set | ||
206 | # CONFIG_SLOB is not set | ||
207 | # CONFIG_PROFILING is not set | ||
208 | # CONFIG_MARKERS is not set | ||
209 | CONFIG_HAVE_OPROFILE=y | ||
210 | # CONFIG_HAVE_KPROBES is not set | ||
211 | # CONFIG_HAVE_KRETPROBES is not set | ||
212 | # CONFIG_HAVE_DMA_ATTRS is not set | ||
213 | # CONFIG_USE_GENERIC_SMP_HELPERS is not set | ||
214 | CONFIG_PROC_PAGE_MONITOR=y | ||
215 | CONFIG_SLABINFO=y | ||
216 | CONFIG_RT_MUTEXES=y | ||
217 | # CONFIG_TINY_SHMEM is not set | ||
218 | CONFIG_BASE_SMALL=0 | ||
219 | CONFIG_MODULES=y | ||
220 | # CONFIG_MODULE_FORCE_LOAD is not set | ||
221 | CONFIG_MODULE_UNLOAD=y | ||
222 | # CONFIG_MODULE_FORCE_UNLOAD is not set | ||
223 | # CONFIG_MODVERSIONS is not set | ||
224 | # CONFIG_MODULE_SRCVERSION_ALL is not set | ||
225 | CONFIG_KMOD=y | ||
226 | CONFIG_BLOCK=y | ||
227 | # CONFIG_LBD is not set | ||
228 | # CONFIG_BLK_DEV_IO_TRACE is not set | ||
229 | # CONFIG_LSF is not set | ||
230 | # CONFIG_BLK_DEV_BSG is not set | ||
231 | # CONFIG_BLK_DEV_INTEGRITY is not set | ||
232 | |||
233 | # | ||
234 | # IO Schedulers | ||
235 | # | ||
236 | CONFIG_IOSCHED_NOOP=y | ||
237 | # CONFIG_IOSCHED_AS is not set | ||
238 | # CONFIG_IOSCHED_DEADLINE is not set | ||
239 | # CONFIG_IOSCHED_CFQ is not set | ||
240 | # CONFIG_DEFAULT_AS is not set | ||
241 | # CONFIG_DEFAULT_DEADLINE is not set | ||
242 | # CONFIG_DEFAULT_CFQ is not set | ||
243 | CONFIG_DEFAULT_NOOP=y | ||
244 | CONFIG_DEFAULT_IOSCHED="noop" | ||
245 | CONFIG_CLASSIC_RCU=y | ||
246 | |||
247 | # | ||
248 | # Bus options (PCI, PCMCIA, EISA, ISA, TC) | ||
249 | # | ||
250 | # CONFIG_ARCH_SUPPORTS_MSI is not set | ||
251 | CONFIG_MMU=y | ||
252 | # CONFIG_PCCARD is not set | ||
253 | |||
254 | # | ||
255 | # Executable file formats | ||
256 | # | ||
257 | CONFIG_BINFMT_ELF=y | ||
258 | # CONFIG_BINFMT_MISC is not set | ||
259 | CONFIG_TRAD_SIGNALS=y | ||
260 | |||
261 | # | ||
262 | # Power management options | ||
263 | # | ||
264 | CONFIG_ARCH_SUSPEND_POSSIBLE=y | ||
265 | CONFIG_PM=y | ||
266 | # CONFIG_PM_DEBUG is not set | ||
267 | CONFIG_PM_SLEEP=y | ||
268 | CONFIG_SUSPEND=y | ||
269 | CONFIG_SUSPEND_FREEZER=y | ||
270 | |||
271 | # | ||
272 | # Networking | ||
273 | # | ||
274 | CONFIG_NET=y | ||
275 | |||
276 | # | ||
277 | # Networking options | ||
278 | # | ||
279 | CONFIG_PACKET=y | ||
280 | # CONFIG_PACKET_MMAP is not set | ||
281 | CONFIG_UNIX=y | ||
282 | CONFIG_XFRM=y | ||
283 | # CONFIG_XFRM_USER is not set | ||
284 | # CONFIG_XFRM_SUB_POLICY is not set | ||
285 | # CONFIG_XFRM_MIGRATE is not set | ||
286 | # CONFIG_XFRM_STATISTICS is not set | ||
287 | # CONFIG_NET_KEY is not set | ||
288 | CONFIG_INET=y | ||
289 | CONFIG_IP_MULTICAST=y | ||
290 | # CONFIG_IP_ADVANCED_ROUTER is not set | ||
291 | CONFIG_IP_FIB_HASH=y | ||
292 | CONFIG_IP_PNP=y | ||
293 | CONFIG_IP_PNP_DHCP=y | ||
294 | # CONFIG_IP_PNP_BOOTP is not set | ||
295 | # CONFIG_IP_PNP_RARP is not set | ||
296 | # CONFIG_NET_IPIP is not set | ||
297 | # CONFIG_NET_IPGRE is not set | ||
298 | # CONFIG_IP_MROUTE is not set | ||
299 | # CONFIG_ARPD is not set | ||
300 | # CONFIG_SYN_COOKIES is not set | ||
301 | CONFIG_INET_AH=y | ||
302 | # CONFIG_INET_ESP is not set | ||
303 | # CONFIG_INET_IPCOMP is not set | ||
304 | # CONFIG_INET_XFRM_TUNNEL is not set | ||
305 | # CONFIG_INET_TUNNEL is not set | ||
306 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | ||
307 | CONFIG_INET_XFRM_MODE_TUNNEL=y | ||
308 | CONFIG_INET_XFRM_MODE_BEET=y | ||
309 | # CONFIG_INET_LRO is not set | ||
310 | CONFIG_INET_DIAG=y | ||
311 | CONFIG_INET_TCP_DIAG=y | ||
312 | # CONFIG_TCP_CONG_ADVANCED is not set | ||
313 | CONFIG_TCP_CONG_CUBIC=y | ||
314 | CONFIG_DEFAULT_TCP_CONG="cubic" | ||
315 | # CONFIG_TCP_MD5SIG is not set | ||
316 | # CONFIG_IPV6 is not set | ||
317 | # CONFIG_NETWORK_SECMARK is not set | ||
318 | # CONFIG_NETFILTER is not set | ||
319 | # CONFIG_IP_DCCP is not set | ||
320 | # CONFIG_IP_SCTP is not set | ||
321 | # CONFIG_TIPC is not set | ||
322 | # CONFIG_ATM is not set | ||
323 | # CONFIG_BRIDGE is not set | ||
324 | # CONFIG_VLAN_8021Q is not set | ||
325 | # CONFIG_DECNET is not set | ||
326 | # CONFIG_LLC2 is not set | ||
327 | # CONFIG_IPX is not set | ||
328 | # CONFIG_ATALK is not set | ||
329 | # CONFIG_X25 is not set | ||
330 | # CONFIG_LAPB is not set | ||
331 | # CONFIG_ECONET is not set | ||
332 | # CONFIG_WAN_ROUTER is not set | ||
333 | # CONFIG_NET_SCHED is not set | ||
334 | |||
335 | # | ||
336 | # Network testing | ||
337 | # | ||
338 | # CONFIG_NET_PKTGEN is not set | ||
339 | # CONFIG_HAMRADIO is not set | ||
340 | # CONFIG_CAN is not set | ||
341 | # CONFIG_IRDA is not set | ||
342 | # CONFIG_BT is not set | ||
343 | # CONFIG_AF_RXRPC is not set | ||
344 | |||
345 | # | ||
346 | # Wireless | ||
347 | # | ||
348 | # CONFIG_CFG80211 is not set | ||
349 | # CONFIG_WIRELESS_EXT is not set | ||
350 | # CONFIG_MAC80211 is not set | ||
351 | # CONFIG_IEEE80211 is not set | ||
352 | # CONFIG_RFKILL is not set | ||
353 | # CONFIG_NET_9P is not set | ||
354 | |||
355 | # | ||
356 | # Device Drivers | ||
357 | # | ||
358 | |||
359 | # | ||
360 | # Generic Driver Options | ||
361 | # | ||
362 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | ||
363 | CONFIG_STANDALONE=y | ||
364 | CONFIG_PREVENT_FIRMWARE_BUILD=y | ||
365 | CONFIG_FW_LOADER=y | ||
366 | CONFIG_FIRMWARE_IN_KERNEL=y | ||
367 | CONFIG_EXTRA_FIRMWARE="" | ||
368 | # CONFIG_SYS_HYPERVISOR is not set | ||
369 | # CONFIG_CONNECTOR is not set | ||
370 | CONFIG_MTD=y | ||
371 | # CONFIG_MTD_DEBUG is not set | ||
372 | # CONFIG_MTD_CONCAT is not set | ||
373 | CONFIG_MTD_PARTITIONS=y | ||
374 | # CONFIG_MTD_REDBOOT_PARTS is not set | ||
375 | CONFIG_MTD_CMDLINE_PARTS=y | ||
376 | # CONFIG_MTD_AR7_PARTS is not set | ||
377 | |||
378 | # | ||
379 | # User Modules And Translation Layers | ||
380 | # | ||
381 | CONFIG_MTD_CHAR=y | ||
382 | CONFIG_MTD_BLKDEVS=y | ||
383 | CONFIG_MTD_BLOCK=y | ||
384 | # CONFIG_FTL is not set | ||
385 | # CONFIG_NFTL is not set | ||
386 | # CONFIG_INFTL is not set | ||
387 | # CONFIG_RFD_FTL is not set | ||
388 | # CONFIG_SSFDC is not set | ||
389 | # CONFIG_MTD_OOPS is not set | ||
390 | |||
391 | # | ||
392 | # RAM/ROM/Flash chip drivers | ||
393 | # | ||
394 | CONFIG_MTD_CFI=y | ||
395 | # CONFIG_MTD_JEDECPROBE is not set | ||
396 | CONFIG_MTD_GEN_PROBE=y | ||
397 | CONFIG_MTD_CFI_ADV_OPTIONS=y | ||
398 | # CONFIG_MTD_CFI_NOSWAP is not set | ||
399 | # CONFIG_MTD_CFI_BE_BYTE_SWAP is not set | ||
400 | CONFIG_MTD_CFI_LE_BYTE_SWAP=y | ||
401 | CONFIG_MTD_CFI_GEOMETRY=y | ||
402 | CONFIG_MTD_MAP_BANK_WIDTH_1=y | ||
403 | CONFIG_MTD_MAP_BANK_WIDTH_2=y | ||
404 | CONFIG_MTD_MAP_BANK_WIDTH_4=y | ||
405 | # CONFIG_MTD_MAP_BANK_WIDTH_8 is not set | ||
406 | # CONFIG_MTD_MAP_BANK_WIDTH_16 is not set | ||
407 | # CONFIG_MTD_MAP_BANK_WIDTH_32 is not set | ||
408 | CONFIG_MTD_CFI_I1=y | ||
409 | CONFIG_MTD_CFI_I2=y | ||
410 | # CONFIG_MTD_CFI_I4 is not set | ||
411 | # CONFIG_MTD_CFI_I8 is not set | ||
412 | # CONFIG_MTD_OTP is not set | ||
413 | # CONFIG_MTD_CFI_INTELEXT is not set | ||
414 | CONFIG_MTD_CFI_AMDSTD=y | ||
415 | # CONFIG_MTD_CFI_STAA is not set | ||
416 | CONFIG_MTD_CFI_UTIL=y | ||
417 | # CONFIG_MTD_RAM is not set | ||
418 | # CONFIG_MTD_ROM is not set | ||
419 | # CONFIG_MTD_ABSENT is not set | ||
420 | |||
421 | # | ||
422 | # Mapping drivers for chip access | ||
423 | # | ||
424 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set | ||
425 | CONFIG_MTD_PHYSMAP=y | ||
426 | CONFIG_MTD_PHYSMAP_START=0x18000000 | ||
427 | CONFIG_MTD_PHYSMAP_LEN=0x04000000 | ||
428 | CONFIG_MTD_PHYSMAP_BANKWIDTH=2 | ||
429 | # CONFIG_MTD_PLATRAM is not set | ||
430 | |||
431 | # | ||
432 | # Self-contained MTD device drivers | ||
433 | # | ||
434 | # CONFIG_MTD_SLRAM is not set | ||
435 | # CONFIG_MTD_PHRAM is not set | ||
436 | # CONFIG_MTD_MTDRAM is not set | ||
437 | # CONFIG_MTD_BLOCK2MTD is not set | ||
438 | |||
439 | # | ||
440 | # Disk-On-Chip Device Drivers | ||
441 | # | ||
442 | # CONFIG_MTD_DOC2000 is not set | ||
443 | # CONFIG_MTD_DOC2001 is not set | ||
444 | # CONFIG_MTD_DOC2001PLUS is not set | ||
445 | # CONFIG_MTD_NAND is not set | ||
446 | # CONFIG_MTD_ONENAND is not set | ||
447 | |||
448 | # | ||
449 | # UBI - Unsorted block images | ||
450 | # | ||
451 | # CONFIG_MTD_UBI is not set | ||
452 | # CONFIG_PARPORT is not set | ||
453 | CONFIG_BLK_DEV=y | ||
454 | # CONFIG_BLK_DEV_COW_COMMON is not set | ||
455 | CONFIG_BLK_DEV_LOOP=y | ||
456 | # CONFIG_BLK_DEV_CRYPTOLOOP is not set | ||
457 | # CONFIG_BLK_DEV_NBD is not set | ||
458 | # CONFIG_BLK_DEV_RAM is not set | ||
459 | # CONFIG_CDROM_PKTCDVD is not set | ||
460 | # CONFIG_ATA_OVER_ETH is not set | ||
461 | # CONFIG_BLK_DEV_HD is not set | ||
462 | # CONFIG_MISC_DEVICES is not set | ||
463 | CONFIG_HAVE_IDE=y | ||
464 | # CONFIG_IDE is not set | ||
465 | |||
466 | # | ||
467 | # SCSI device support | ||
468 | # | ||
469 | # CONFIG_RAID_ATTRS is not set | ||
470 | CONFIG_SCSI=y | ||
471 | CONFIG_SCSI_DMA=y | ||
472 | # CONFIG_SCSI_TGT is not set | ||
473 | # CONFIG_SCSI_NETLINK is not set | ||
474 | CONFIG_SCSI_PROC_FS=y | ||
475 | |||
476 | # | ||
477 | # SCSI support type (disk, tape, CD-ROM) | ||
478 | # | ||
479 | CONFIG_BLK_DEV_SD=y | ||
480 | # CONFIG_CHR_DEV_ST is not set | ||
481 | # CONFIG_CHR_DEV_OSST is not set | ||
482 | # CONFIG_BLK_DEV_SR is not set | ||
483 | # CONFIG_CHR_DEV_SG is not set | ||
484 | # CONFIG_CHR_DEV_SCH is not set | ||
485 | |||
486 | # | ||
487 | # Some SCSI devices (e.g. CD jukebox) support multiple LUNs | ||
488 | # | ||
489 | # CONFIG_SCSI_MULTI_LUN is not set | ||
490 | # CONFIG_SCSI_CONSTANTS is not set | ||
491 | # CONFIG_SCSI_LOGGING is not set | ||
492 | # CONFIG_SCSI_SCAN_ASYNC is not set | ||
493 | CONFIG_SCSI_WAIT_SCAN=m | ||
494 | |||
495 | # | ||
496 | # SCSI Transports | ||
497 | # | ||
498 | # CONFIG_SCSI_SPI_ATTRS is not set | ||
499 | # CONFIG_SCSI_FC_ATTRS is not set | ||
500 | # CONFIG_SCSI_ISCSI_ATTRS is not set | ||
501 | # CONFIG_SCSI_SAS_LIBSAS is not set | ||
502 | # CONFIG_SCSI_SRP_ATTRS is not set | ||
503 | # CONFIG_SCSI_LOWLEVEL is not set | ||
504 | # CONFIG_SCSI_DH is not set | ||
505 | CONFIG_ATA=y | ||
506 | # CONFIG_ATA_NONSTANDARD is not set | ||
507 | CONFIG_SATA_PMP=y | ||
508 | CONFIG_ATA_SFF=y | ||
509 | # CONFIG_SATA_MV is not set | ||
510 | # CONFIG_PATA_PLATFORM is not set | ||
511 | # CONFIG_MD is not set | ||
512 | CONFIG_NETDEVICES=y | ||
513 | # CONFIG_DUMMY is not set | ||
514 | # CONFIG_BONDING is not set | ||
515 | # CONFIG_MACVLAN is not set | ||
516 | # CONFIG_EQUALIZER is not set | ||
517 | # CONFIG_TUN is not set | ||
518 | # CONFIG_VETH is not set | ||
519 | # CONFIG_PHYLIB is not set | ||
520 | CONFIG_NET_ETHERNET=y | ||
521 | CONFIG_MII=y | ||
522 | # CONFIG_AX88796 is not set | ||
523 | # CONFIG_DM9000 is not set | ||
524 | # CONFIG_IBM_NEW_EMAC_ZMII is not set | ||
525 | # CONFIG_IBM_NEW_EMAC_RGMII is not set | ||
526 | # CONFIG_IBM_NEW_EMAC_TAH is not set | ||
527 | # CONFIG_IBM_NEW_EMAC_EMAC4 is not set | ||
528 | # CONFIG_B44 is not set | ||
529 | # CONFIG_NETDEV_1000 is not set | ||
530 | # CONFIG_NETDEV_10000 is not set | ||
531 | |||
532 | # | ||
533 | # Wireless LAN | ||
534 | # | ||
535 | # CONFIG_WLAN_PRE80211 is not set | ||
536 | # CONFIG_WLAN_80211 is not set | ||
537 | # CONFIG_IWLWIFI_LEDS is not set | ||
538 | # CONFIG_WAN is not set | ||
539 | # CONFIG_PPP is not set | ||
540 | # CONFIG_SLIP is not set | ||
541 | # CONFIG_NETCONSOLE is not set | ||
542 | # CONFIG_NETPOLL is not set | ||
543 | # CONFIG_NET_POLL_CONTROLLER is not set | ||
544 | # CONFIG_ISDN is not set | ||
545 | # CONFIG_PHONE is not set | ||
546 | |||
547 | # | ||
548 | # Input device support | ||
549 | # | ||
550 | CONFIG_INPUT=y | ||
551 | # CONFIG_INPUT_FF_MEMLESS is not set | ||
552 | # CONFIG_INPUT_POLLDEV is not set | ||
553 | |||
554 | # | ||
555 | # Userland interfaces | ||
556 | # | ||
557 | # CONFIG_INPUT_MOUSEDEV is not set | ||
558 | # CONFIG_INPUT_JOYDEV is not set | ||
559 | CONFIG_INPUT_EVDEV=m | ||
560 | CONFIG_INPUT_EVBUG=m | ||
561 | |||
562 | # | ||
563 | # Input Device Drivers | ||
564 | # | ||
565 | # CONFIG_INPUT_KEYBOARD is not set | ||
566 | # CONFIG_INPUT_MOUSE is not set | ||
567 | # CONFIG_INPUT_JOYSTICK is not set | ||
568 | # CONFIG_INPUT_TABLET is not set | ||
569 | # CONFIG_INPUT_TOUCHSCREEN is not set | ||
570 | # CONFIG_INPUT_MISC is not set | ||
571 | |||
572 | # | ||
573 | # Hardware I/O ports | ||
574 | # | ||
575 | CONFIG_SERIO=y | ||
576 | # CONFIG_SERIO_I8042 is not set | ||
577 | CONFIG_SERIO_SERPORT=y | ||
578 | # CONFIG_SERIO_LIBPS2 is not set | ||
579 | # CONFIG_SERIO_RAW is not set | ||
580 | # CONFIG_GAMEPORT is not set | ||
581 | |||
582 | # | ||
583 | # Character devices | ||
584 | # | ||
585 | CONFIG_VT=y | ||
586 | CONFIG_CONSOLE_TRANSLATIONS=y | ||
587 | # CONFIG_VT_CONSOLE is not set | ||
588 | CONFIG_HW_CONSOLE=y | ||
589 | # CONFIG_VT_HW_CONSOLE_BINDING is not set | ||
590 | CONFIG_DEVKMEM=y | ||
591 | # CONFIG_SERIAL_NONSTANDARD is not set | ||
592 | |||
593 | # | ||
594 | # Serial drivers | ||
595 | # | ||
596 | # CONFIG_SERIAL_8250 is not set | ||
597 | |||
598 | # | ||
599 | # Non-8250 serial port support | ||
600 | # | ||
601 | CONFIG_SERIAL_PNX8XXX=y | ||
602 | CONFIG_SERIAL_PNX8XXX_CONSOLE=y | ||
603 | CONFIG_SERIAL_CORE=y | ||
604 | CONFIG_SERIAL_CORE_CONSOLE=y | ||
605 | CONFIG_UNIX98_PTYS=y | ||
606 | # CONFIG_LEGACY_PTYS is not set | ||
607 | # CONFIG_IPMI_HANDLER is not set | ||
608 | CONFIG_HW_RANDOM=y | ||
609 | # CONFIG_R3964 is not set | ||
610 | # CONFIG_RAW_DRIVER is not set | ||
611 | # CONFIG_TCG_TPM is not set | ||
612 | CONFIG_I2C=y | ||
613 | CONFIG_I2C_BOARDINFO=y | ||
614 | CONFIG_I2C_CHARDEV=y | ||
615 | |||
616 | # | ||
617 | # I2C Hardware Bus support | ||
618 | # | ||
619 | |||
620 | # | ||
621 | # I2C system bus drivers (mostly embedded / system-on-chip) | ||
622 | # | ||
623 | # CONFIG_I2C_GPIO is not set | ||
624 | # CONFIG_I2C_OCORES is not set | ||
625 | # CONFIG_I2C_SIMTEC is not set | ||
626 | |||
627 | # | ||
628 | # External I2C/SMBus adapter drivers | ||
629 | # | ||
630 | # CONFIG_I2C_PARPORT_LIGHT is not set | ||
631 | # CONFIG_I2C_TAOS_EVM is not set | ||
632 | |||
633 | # | ||
634 | # Other I2C/SMBus bus drivers | ||
635 | # | ||
636 | # CONFIG_I2C_PCA_PLATFORM is not set | ||
637 | # CONFIG_I2C_STUB is not set | ||
638 | |||
639 | # | ||
640 | # Miscellaneous I2C Chip support | ||
641 | # | ||
642 | # CONFIG_DS1682 is not set | ||
643 | # CONFIG_AT24 is not set | ||
644 | # CONFIG_SENSORS_EEPROM is not set | ||
645 | # CONFIG_SENSORS_PCF8574 is not set | ||
646 | # CONFIG_PCF8575 is not set | ||
647 | # CONFIG_SENSORS_PCA9539 is not set | ||
648 | # CONFIG_SENSORS_PCF8591 is not set | ||
649 | # CONFIG_SENSORS_MAX6875 is not set | ||
650 | # CONFIG_SENSORS_TSL2550 is not set | ||
651 | # CONFIG_I2C_DEBUG_CORE is not set | ||
652 | # CONFIG_I2C_DEBUG_ALGO is not set | ||
653 | # CONFIG_I2C_DEBUG_BUS is not set | ||
654 | # CONFIG_I2C_DEBUG_CHIP is not set | ||
655 | # CONFIG_SPI is not set | ||
656 | # CONFIG_W1 is not set | ||
657 | # CONFIG_POWER_SUPPLY is not set | ||
658 | # CONFIG_HWMON is not set | ||
659 | # CONFIG_THERMAL is not set | ||
660 | # CONFIG_THERMAL_HWMON is not set | ||
661 | # CONFIG_WATCHDOG is not set | ||
662 | |||
663 | # | ||
664 | # Sonics Silicon Backplane | ||
665 | # | ||
666 | CONFIG_SSB_POSSIBLE=y | ||
667 | # CONFIG_SSB is not set | ||
668 | |||
669 | # | ||
670 | # Multifunction device drivers | ||
671 | # | ||
672 | # CONFIG_MFD_CORE is not set | ||
673 | # CONFIG_MFD_SM501 is not set | ||
674 | # CONFIG_HTC_PASIC3 is not set | ||
675 | |||
676 | # | ||
677 | # Multimedia devices | ||
678 | # | ||
679 | |||
680 | # | ||
681 | # Multimedia core support | ||
682 | # | ||
683 | # CONFIG_VIDEO_DEV is not set | ||
684 | CONFIG_DVB_CORE=y | ||
685 | CONFIG_VIDEO_MEDIA=y | ||
686 | |||
687 | # | ||
688 | # Multimedia drivers | ||
689 | # | ||
690 | # CONFIG_MEDIA_ATTACH is not set | ||
691 | CONFIG_MEDIA_TUNER=y | ||
692 | # CONFIG_MEDIA_TUNER_CUSTOMIZE is not set | ||
693 | CONFIG_MEDIA_TUNER_SIMPLE=y | ||
694 | CONFIG_MEDIA_TUNER_TDA8290=y | ||
695 | CONFIG_MEDIA_TUNER_TDA9887=y | ||
696 | CONFIG_MEDIA_TUNER_TEA5761=y | ||
697 | CONFIG_MEDIA_TUNER_TEA5767=y | ||
698 | CONFIG_MEDIA_TUNER_MT20XX=y | ||
699 | CONFIG_MEDIA_TUNER_XC2028=y | ||
700 | CONFIG_MEDIA_TUNER_XC5000=y | ||
701 | CONFIG_DVB_CAPTURE_DRIVERS=y | ||
702 | # CONFIG_TTPCI_EEPROM is not set | ||
703 | # CONFIG_DVB_B2C2_FLEXCOP is not set | ||
704 | |||
705 | # | ||
706 | # Supported DVB Frontends | ||
707 | # | ||
708 | |||
709 | # | ||
710 | # Customise DVB Frontends | ||
711 | # | ||
712 | # CONFIG_DVB_FE_CUSTOMISE is not set | ||
713 | |||
714 | # | ||
715 | # DVB-S (satellite) frontends | ||
716 | # | ||
717 | # CONFIG_DVB_CX24110 is not set | ||
718 | # CONFIG_DVB_CX24123 is not set | ||
719 | # CONFIG_DVB_MT312 is not set | ||
720 | # CONFIG_DVB_S5H1420 is not set | ||
721 | # CONFIG_DVB_STV0299 is not set | ||
722 | # CONFIG_DVB_TDA8083 is not set | ||
723 | # CONFIG_DVB_TDA10086 is not set | ||
724 | # CONFIG_DVB_VES1X93 is not set | ||
725 | # CONFIG_DVB_TUNER_ITD1000 is not set | ||
726 | # CONFIG_DVB_TDA826X is not set | ||
727 | # CONFIG_DVB_TUA6100 is not set | ||
728 | |||
729 | # | ||
730 | # DVB-T (terrestrial) frontends | ||
731 | # | ||
732 | # CONFIG_DVB_SP8870 is not set | ||
733 | # CONFIG_DVB_SP887X is not set | ||
734 | # CONFIG_DVB_CX22700 is not set | ||
735 | # CONFIG_DVB_CX22702 is not set | ||
736 | # CONFIG_DVB_DRX397XD is not set | ||
737 | # CONFIG_DVB_L64781 is not set | ||
738 | CONFIG_DVB_TDA1004X=y | ||
739 | # CONFIG_DVB_NXT6000 is not set | ||
740 | # CONFIG_DVB_MT352 is not set | ||
741 | # CONFIG_DVB_ZL10353 is not set | ||
742 | # CONFIG_DVB_DIB3000MB is not set | ||
743 | # CONFIG_DVB_DIB3000MC is not set | ||
744 | # CONFIG_DVB_DIB7000M is not set | ||
745 | # CONFIG_DVB_DIB7000P is not set | ||
746 | # CONFIG_DVB_TDA10048 is not set | ||
747 | |||
748 | # | ||
749 | # DVB-C (cable) frontends | ||
750 | # | ||
751 | # CONFIG_DVB_VES1820 is not set | ||
752 | # CONFIG_DVB_TDA10021 is not set | ||
753 | # CONFIG_DVB_TDA10023 is not set | ||
754 | # CONFIG_DVB_STV0297 is not set | ||
755 | |||
756 | # | ||
757 | # ATSC (North American/Korean Terrestrial/Cable DTV) frontends | ||
758 | # | ||
759 | # CONFIG_DVB_NXT200X is not set | ||
760 | # CONFIG_DVB_OR51211 is not set | ||
761 | # CONFIG_DVB_OR51132 is not set | ||
762 | # CONFIG_DVB_BCM3510 is not set | ||
763 | # CONFIG_DVB_LGDT330X is not set | ||
764 | # CONFIG_DVB_S5H1409 is not set | ||
765 | # CONFIG_DVB_AU8522 is not set | ||
766 | # CONFIG_DVB_S5H1411 is not set | ||
767 | |||
768 | # | ||
769 | # Digital terrestrial only tuners/PLL | ||
770 | # | ||
771 | # CONFIG_DVB_PLL is not set | ||
772 | # CONFIG_DVB_TUNER_DIB0070 is not set | ||
773 | |||
774 | # | ||
775 | # SEC control devices for DVB-S | ||
776 | # | ||
777 | # CONFIG_DVB_LNBP21 is not set | ||
778 | # CONFIG_DVB_ISL6405 is not set | ||
779 | # CONFIG_DVB_ISL6421 is not set | ||
780 | # CONFIG_DAB is not set | ||
781 | |||
782 | # | ||
783 | # Graphics support | ||
784 | # | ||
785 | # CONFIG_VGASTATE is not set | ||
786 | # CONFIG_VIDEO_OUTPUT_CONTROL is not set | ||
787 | CONFIG_FB=y | ||
788 | # CONFIG_FIRMWARE_EDID is not set | ||
789 | # CONFIG_FB_DDC is not set | ||
790 | # CONFIG_FB_CFB_FILLRECT is not set | ||
791 | # CONFIG_FB_CFB_COPYAREA is not set | ||
792 | # CONFIG_FB_CFB_IMAGEBLIT is not set | ||
793 | # CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set | ||
794 | # CONFIG_FB_SYS_FILLRECT is not set | ||
795 | # CONFIG_FB_SYS_COPYAREA is not set | ||
796 | # CONFIG_FB_SYS_IMAGEBLIT is not set | ||
797 | # CONFIG_FB_FOREIGN_ENDIAN is not set | ||
798 | # CONFIG_FB_SYS_FOPS is not set | ||
799 | # CONFIG_FB_SVGALIB is not set | ||
800 | # CONFIG_FB_MACMODES is not set | ||
801 | # CONFIG_FB_BACKLIGHT is not set | ||
802 | # CONFIG_FB_MODE_HELPERS is not set | ||
803 | # CONFIG_FB_TILEBLITTING is not set | ||
804 | |||
805 | # | ||
806 | # Frame buffer hardware drivers | ||
807 | # | ||
808 | # CONFIG_FB_S1D13XXX is not set | ||
809 | # CONFIG_FB_VIRTUAL is not set | ||
810 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set | ||
811 | |||
812 | # | ||
813 | # Display device support | ||
814 | # | ||
815 | # CONFIG_DISPLAY_SUPPORT is not set | ||
816 | |||
817 | # | ||
818 | # Console display driver support | ||
819 | # | ||
820 | # CONFIG_VGA_CONSOLE is not set | ||
821 | CONFIG_DUMMY_CONSOLE=y | ||
822 | # CONFIG_FRAMEBUFFER_CONSOLE is not set | ||
823 | # CONFIG_LOGO is not set | ||
824 | CONFIG_SOUND=m | ||
825 | CONFIG_SND=m | ||
826 | CONFIG_SND_TIMER=m | ||
827 | CONFIG_SND_PCM=m | ||
828 | CONFIG_SND_SEQUENCER=m | ||
829 | # CONFIG_SND_SEQ_DUMMY is not set | ||
830 | CONFIG_SND_OSSEMUL=y | ||
831 | CONFIG_SND_MIXER_OSS=m | ||
832 | CONFIG_SND_PCM_OSS=m | ||
833 | CONFIG_SND_PCM_OSS_PLUGINS=y | ||
834 | CONFIG_SND_SEQUENCER_OSS=y | ||
835 | # CONFIG_SND_DYNAMIC_MINORS is not set | ||
836 | CONFIG_SND_SUPPORT_OLD_API=y | ||
837 | CONFIG_SND_VERBOSE_PROCFS=y | ||
838 | CONFIG_SND_VERBOSE_PRINTK=y | ||
839 | CONFIG_SND_DEBUG=y | ||
840 | # CONFIG_SND_DEBUG_VERBOSE is not set | ||
841 | # CONFIG_SND_PCM_XRUN_DEBUG is not set | ||
842 | CONFIG_SND_DRIVERS=y | ||
843 | # CONFIG_SND_DUMMY is not set | ||
844 | # CONFIG_SND_VIRMIDI is not set | ||
845 | # CONFIG_SND_MTPAV is not set | ||
846 | # CONFIG_SND_SERIAL_U16550 is not set | ||
847 | # CONFIG_SND_MPU401 is not set | ||
848 | CONFIG_SND_MIPS=y | ||
849 | # CONFIG_SND_SOC is not set | ||
850 | # CONFIG_SOUND_PRIME is not set | ||
851 | CONFIG_HID_SUPPORT=y | ||
852 | CONFIG_HID=y | ||
853 | # CONFIG_HID_DEBUG is not set | ||
854 | # CONFIG_HIDRAW is not set | ||
855 | CONFIG_USB_SUPPORT=y | ||
856 | # CONFIG_USB_ARCH_HAS_HCD is not set | ||
857 | # CONFIG_USB_ARCH_HAS_OHCI is not set | ||
858 | # CONFIG_USB_ARCH_HAS_EHCI is not set | ||
859 | # CONFIG_USB_OTG_WHITELIST is not set | ||
860 | # CONFIG_USB_OTG_BLACKLIST_HUB is not set | ||
861 | |||
862 | # | ||
863 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' | ||
864 | # | ||
865 | # CONFIG_USB_GADGET is not set | ||
866 | # CONFIG_MMC is not set | ||
867 | # CONFIG_MEMSTICK is not set | ||
868 | # CONFIG_NEW_LEDS is not set | ||
869 | # CONFIG_ACCESSIBILITY is not set | ||
870 | CONFIG_RTC_LIB=y | ||
871 | # CONFIG_RTC_CLASS is not set | ||
872 | # CONFIG_DMADEVICES is not set | ||
873 | # CONFIG_UIO is not set | ||
874 | |||
875 | # | ||
876 | # File systems | ||
877 | # | ||
878 | CONFIG_EXT2_FS=m | ||
879 | # CONFIG_EXT2_FS_XATTR is not set | ||
880 | # CONFIG_EXT2_FS_XIP is not set | ||
881 | # CONFIG_EXT3_FS is not set | ||
882 | # CONFIG_EXT4DEV_FS is not set | ||
883 | # CONFIG_REISERFS_FS is not set | ||
884 | # CONFIG_JFS_FS is not set | ||
885 | # CONFIG_FS_POSIX_ACL is not set | ||
886 | # CONFIG_XFS_FS is not set | ||
887 | # CONFIG_OCFS2_FS is not set | ||
888 | # CONFIG_DNOTIFY is not set | ||
889 | CONFIG_INOTIFY=y | ||
890 | CONFIG_INOTIFY_USER=y | ||
891 | # CONFIG_QUOTA is not set | ||
892 | # CONFIG_AUTOFS_FS is not set | ||
893 | # CONFIG_AUTOFS4_FS is not set | ||
894 | # CONFIG_FUSE_FS is not set | ||
895 | |||
896 | # | ||
897 | # CD-ROM/DVD Filesystems | ||
898 | # | ||
899 | # CONFIG_ISO9660_FS is not set | ||
900 | # CONFIG_UDF_FS is not set | ||
901 | |||
902 | # | ||
903 | # DOS/FAT/NT Filesystems | ||
904 | # | ||
905 | CONFIG_FAT_FS=m | ||
906 | CONFIG_MSDOS_FS=m | ||
907 | CONFIG_VFAT_FS=m | ||
908 | CONFIG_FAT_DEFAULT_CODEPAGE=437 | ||
909 | CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" | ||
910 | # CONFIG_NTFS_FS is not set | ||
911 | |||
912 | # | ||
913 | # Pseudo filesystems | ||
914 | # | ||
915 | CONFIG_PROC_FS=y | ||
916 | # CONFIG_PROC_KCORE is not set | ||
917 | CONFIG_PROC_SYSCTL=y | ||
918 | CONFIG_SYSFS=y | ||
919 | CONFIG_TMPFS=y | ||
920 | # CONFIG_TMPFS_POSIX_ACL is not set | ||
921 | # CONFIG_HUGETLB_PAGE is not set | ||
922 | # CONFIG_CONFIGFS_FS is not set | ||
923 | |||
924 | # | ||
925 | # Miscellaneous filesystems | ||
926 | # | ||
927 | # CONFIG_ADFS_FS is not set | ||
928 | # CONFIG_AFFS_FS is not set | ||
929 | # CONFIG_HFS_FS is not set | ||
930 | # CONFIG_HFSPLUS_FS is not set | ||
931 | # CONFIG_BEFS_FS is not set | ||
932 | # CONFIG_BFS_FS is not set | ||
933 | # CONFIG_EFS_FS is not set | ||
934 | CONFIG_JFFS2_FS=y | ||
935 | CONFIG_JFFS2_FS_DEBUG=0 | ||
936 | CONFIG_JFFS2_FS_WRITEBUFFER=y | ||
937 | # CONFIG_JFFS2_FS_WBUF_VERIFY is not set | ||
938 | # CONFIG_JFFS2_SUMMARY is not set | ||
939 | # CONFIG_JFFS2_FS_XATTR is not set | ||
940 | # CONFIG_JFFS2_COMPRESSION_OPTIONS is not set | ||
941 | CONFIG_JFFS2_ZLIB=y | ||
942 | # CONFIG_JFFS2_LZO is not set | ||
943 | CONFIG_JFFS2_RTIME=y | ||
944 | # CONFIG_JFFS2_RUBIN is not set | ||
945 | CONFIG_CRAMFS=y | ||
946 | # CONFIG_VXFS_FS is not set | ||
947 | # CONFIG_MINIX_FS is not set | ||
948 | # CONFIG_HPFS_FS is not set | ||
949 | # CONFIG_QNX4FS_FS is not set | ||
950 | # CONFIG_ROMFS_FS is not set | ||
951 | # CONFIG_SYSV_FS is not set | ||
952 | # CONFIG_UFS_FS is not set | ||
953 | CONFIG_NETWORK_FILESYSTEMS=y | ||
954 | CONFIG_NFS_FS=y | ||
955 | CONFIG_NFS_V3=y | ||
956 | # CONFIG_NFS_V3_ACL is not set | ||
957 | # CONFIG_NFS_V4 is not set | ||
958 | CONFIG_ROOT_NFS=y | ||
959 | CONFIG_NFSD=m | ||
960 | CONFIG_NFSD_V3=y | ||
961 | # CONFIG_NFSD_V3_ACL is not set | ||
962 | # CONFIG_NFSD_V4 is not set | ||
963 | CONFIG_LOCKD=y | ||
964 | CONFIG_LOCKD_V4=y | ||
965 | CONFIG_EXPORTFS=m | ||
966 | CONFIG_NFS_COMMON=y | ||
967 | CONFIG_SUNRPC=y | ||
968 | # CONFIG_RPCSEC_GSS_KRB5 is not set | ||
969 | # CONFIG_RPCSEC_GSS_SPKM3 is not set | ||
970 | # CONFIG_SMB_FS is not set | ||
971 | # CONFIG_CIFS is not set | ||
972 | # CONFIG_NCP_FS is not set | ||
973 | # CONFIG_CODA_FS is not set | ||
974 | # CONFIG_AFS_FS is not set | ||
975 | |||
976 | # | ||
977 | # Partition Types | ||
978 | # | ||
979 | # CONFIG_PARTITION_ADVANCED is not set | ||
980 | CONFIG_MSDOS_PARTITION=y | ||
981 | CONFIG_NLS=y | ||
982 | CONFIG_NLS_DEFAULT="iso8859-1" | ||
983 | CONFIG_NLS_CODEPAGE_437=m | ||
984 | # CONFIG_NLS_CODEPAGE_737 is not set | ||
985 | # CONFIG_NLS_CODEPAGE_775 is not set | ||
986 | CONFIG_NLS_CODEPAGE_850=m | ||
987 | # CONFIG_NLS_CODEPAGE_852 is not set | ||
988 | # CONFIG_NLS_CODEPAGE_855 is not set | ||
989 | # CONFIG_NLS_CODEPAGE_857 is not set | ||
990 | # CONFIG_NLS_CODEPAGE_860 is not set | ||
991 | # CONFIG_NLS_CODEPAGE_861 is not set | ||
992 | # CONFIG_NLS_CODEPAGE_862 is not set | ||
993 | # CONFIG_NLS_CODEPAGE_863 is not set | ||
994 | # CONFIG_NLS_CODEPAGE_864 is not set | ||
995 | # CONFIG_NLS_CODEPAGE_865 is not set | ||
996 | # CONFIG_NLS_CODEPAGE_866 is not set | ||
997 | # CONFIG_NLS_CODEPAGE_869 is not set | ||
998 | # CONFIG_NLS_CODEPAGE_936 is not set | ||
999 | # CONFIG_NLS_CODEPAGE_950 is not set | ||
1000 | CONFIG_NLS_CODEPAGE_932=m | ||
1001 | # CONFIG_NLS_CODEPAGE_949 is not set | ||
1002 | # CONFIG_NLS_CODEPAGE_874 is not set | ||
1003 | # CONFIG_NLS_ISO8859_8 is not set | ||
1004 | # CONFIG_NLS_CODEPAGE_1250 is not set | ||
1005 | # CONFIG_NLS_CODEPAGE_1251 is not set | ||
1006 | CONFIG_NLS_ASCII=m | ||
1007 | CONFIG_NLS_ISO8859_1=m | ||
1008 | # CONFIG_NLS_ISO8859_2 is not set | ||
1009 | # CONFIG_NLS_ISO8859_3 is not set | ||
1010 | # CONFIG_NLS_ISO8859_4 is not set | ||
1011 | # CONFIG_NLS_ISO8859_5 is not set | ||
1012 | # CONFIG_NLS_ISO8859_6 is not set | ||
1013 | # CONFIG_NLS_ISO8859_7 is not set | ||
1014 | # CONFIG_NLS_ISO8859_9 is not set | ||
1015 | # CONFIG_NLS_ISO8859_13 is not set | ||
1016 | # CONFIG_NLS_ISO8859_14 is not set | ||
1017 | CONFIG_NLS_ISO8859_15=m | ||
1018 | # CONFIG_NLS_KOI8_R is not set | ||
1019 | # CONFIG_NLS_KOI8_U is not set | ||
1020 | CONFIG_NLS_UTF8=m | ||
1021 | # CONFIG_DLM is not set | ||
1022 | |||
1023 | # | ||
1024 | # Kernel hacking | ||
1025 | # | ||
1026 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | ||
1027 | # CONFIG_PRINTK_TIME is not set | ||
1028 | CONFIG_ENABLE_WARN_DEPRECATED=y | ||
1029 | CONFIG_ENABLE_MUST_CHECK=y | ||
1030 | CONFIG_FRAME_WARN=1024 | ||
1031 | # CONFIG_MAGIC_SYSRQ is not set | ||
1032 | # CONFIG_UNUSED_SYMBOLS is not set | ||
1033 | # CONFIG_DEBUG_FS is not set | ||
1034 | # CONFIG_HEADERS_CHECK is not set | ||
1035 | # CONFIG_DEBUG_KERNEL is not set | ||
1036 | # CONFIG_SAMPLES is not set | ||
1037 | # CONFIG_KERNEL_TESTS is not set | ||
1038 | CONFIG_CMDLINE="" | ||
1039 | |||
1040 | # | ||
1041 | # Security options | ||
1042 | # | ||
1043 | # CONFIG_KEYS is not set | ||
1044 | # CONFIG_SECURITY is not set | ||
1045 | # CONFIG_SECURITY_FILE_CAPABILITIES is not set | ||
1046 | CONFIG_CRYPTO=y | ||
1047 | |||
1048 | # | ||
1049 | # Crypto core or helper | ||
1050 | # | ||
1051 | CONFIG_CRYPTO_ALGAPI=y | ||
1052 | CONFIG_CRYPTO_HASH=y | ||
1053 | CONFIG_CRYPTO_MANAGER=y | ||
1054 | # CONFIG_CRYPTO_GF128MUL is not set | ||
1055 | # CONFIG_CRYPTO_NULL is not set | ||
1056 | # CONFIG_CRYPTO_CRYPTD is not set | ||
1057 | # CONFIG_CRYPTO_AUTHENC is not set | ||
1058 | # CONFIG_CRYPTO_TEST is not set | ||
1059 | |||
1060 | # | ||
1061 | # Authenticated Encryption with Associated Data | ||
1062 | # | ||
1063 | # CONFIG_CRYPTO_CCM is not set | ||
1064 | # CONFIG_CRYPTO_GCM is not set | ||
1065 | # CONFIG_CRYPTO_SEQIV is not set | ||
1066 | |||
1067 | # | ||
1068 | # Block modes | ||
1069 | # | ||
1070 | # CONFIG_CRYPTO_CBC is not set | ||
1071 | # CONFIG_CRYPTO_CTR is not set | ||
1072 | # CONFIG_CRYPTO_CTS is not set | ||
1073 | # CONFIG_CRYPTO_ECB is not set | ||
1074 | # CONFIG_CRYPTO_LRW is not set | ||
1075 | # CONFIG_CRYPTO_PCBC is not set | ||
1076 | # CONFIG_CRYPTO_XTS is not set | ||
1077 | |||
1078 | # | ||
1079 | # Hash modes | ||
1080 | # | ||
1081 | CONFIG_CRYPTO_HMAC=y | ||
1082 | # CONFIG_CRYPTO_XCBC is not set | ||
1083 | |||
1084 | # | ||
1085 | # Digest | ||
1086 | # | ||
1087 | # CONFIG_CRYPTO_CRC32C is not set | ||
1088 | # CONFIG_CRYPTO_MD4 is not set | ||
1089 | CONFIG_CRYPTO_MD5=y | ||
1090 | # CONFIG_CRYPTO_MICHAEL_MIC is not set | ||
1091 | # CONFIG_CRYPTO_RMD128 is not set | ||
1092 | # CONFIG_CRYPTO_RMD160 is not set | ||
1093 | # CONFIG_CRYPTO_RMD256 is not set | ||
1094 | # CONFIG_CRYPTO_RMD320 is not set | ||
1095 | CONFIG_CRYPTO_SHA1=y | ||
1096 | # CONFIG_CRYPTO_SHA256 is not set | ||
1097 | # CONFIG_CRYPTO_SHA512 is not set | ||
1098 | # CONFIG_CRYPTO_TGR192 is not set | ||
1099 | # CONFIG_CRYPTO_WP512 is not set | ||
1100 | |||
1101 | # | ||
1102 | # Ciphers | ||
1103 | # | ||
1104 | # CONFIG_CRYPTO_AES is not set | ||
1105 | # CONFIG_CRYPTO_ANUBIS is not set | ||
1106 | # CONFIG_CRYPTO_ARC4 is not set | ||
1107 | # CONFIG_CRYPTO_BLOWFISH is not set | ||
1108 | # CONFIG_CRYPTO_CAMELLIA is not set | ||
1109 | # CONFIG_CRYPTO_CAST5 is not set | ||
1110 | # CONFIG_CRYPTO_CAST6 is not set | ||
1111 | # CONFIG_CRYPTO_DES is not set | ||
1112 | # CONFIG_CRYPTO_FCRYPT is not set | ||
1113 | # CONFIG_CRYPTO_KHAZAD is not set | ||
1114 | # CONFIG_CRYPTO_SALSA20 is not set | ||
1115 | # CONFIG_CRYPTO_SEED is not set | ||
1116 | # CONFIG_CRYPTO_SERPENT is not set | ||
1117 | # CONFIG_CRYPTO_TEA is not set | ||
1118 | # CONFIG_CRYPTO_TWOFISH is not set | ||
1119 | |||
1120 | # | ||
1121 | # Compression | ||
1122 | # | ||
1123 | # CONFIG_CRYPTO_DEFLATE is not set | ||
1124 | # CONFIG_CRYPTO_LZO is not set | ||
1125 | |||
1126 | # | ||
1127 | # Random Number Generation | ||
1128 | # | ||
1129 | # CONFIG_CRYPTO_PRNG is not set | ||
1130 | CONFIG_CRYPTO_HW=y | ||
1131 | |||
1132 | # | ||
1133 | # Library routines | ||
1134 | # | ||
1135 | CONFIG_BITREVERSE=y | ||
1136 | # CONFIG_GENERIC_FIND_FIRST_BIT is not set | ||
1137 | # CONFIG_CRC_CCITT is not set | ||
1138 | # CONFIG_CRC16 is not set | ||
1139 | # CONFIG_CRC_T10DIF is not set | ||
1140 | # CONFIG_CRC_ITU_T is not set | ||
1141 | CONFIG_CRC32=y | ||
1142 | # CONFIG_CRC7 is not set | ||
1143 | # CONFIG_LIBCRC32C is not set | ||
1144 | CONFIG_ZLIB_INFLATE=y | ||
1145 | CONFIG_ZLIB_DEFLATE=y | ||
1146 | CONFIG_PLIST=y | ||
1147 | CONFIG_HAS_IOMEM=y | ||
1148 | CONFIG_HAS_IOPORT=y | ||
1149 | CONFIG_HAS_DMA=y | ||
diff --git a/arch/mips/emma/Kconfig b/arch/mips/emma/Kconfig new file mode 100644 index 000000000000..9669c72123c9 --- /dev/null +++ b/arch/mips/emma/Kconfig | |||
@@ -0,0 +1,29 @@ | |||
1 | choice | ||
2 | prompt "Machine type" | ||
3 | depends on MACH_EMMA | ||
4 | default NEC_MARKEINS | ||
5 | |||
6 | config NEC_MARKEINS | ||
7 | bool "NEC EMMA2RH Mark-eins board" | ||
8 | select SOC_EMMA2RH | ||
9 | select HW_HAS_PCI | ||
10 | help | ||
11 | This enables support for the NEC Electronics Mark-eins boards. | ||
12 | |||
13 | endchoice | ||
14 | |||
15 | config SOC_EMMA2RH | ||
16 | bool | ||
17 | select SOC_EMMA | ||
18 | select SYS_HAS_CPU_R5500 | ||
19 | select SYS_SUPPORTS_32BIT_KERNEL | ||
20 | select SYS_SUPPORTS_64BIT_KERNEL | ||
21 | |||
22 | config SOC_EMMA | ||
23 | bool | ||
24 | select CEVT_R4K | ||
25 | select CSRC_R4K | ||
26 | select DMA_NONCOHERENT | ||
27 | select IRQ_CPU | ||
28 | select SWAP_IO_SPACE | ||
29 | select SYS_SUPPORTS_BIG_ENDIAN | ||
diff --git a/arch/mips/emma2rh/common/Makefile b/arch/mips/emma/common/Makefile index 859121b3867d..c392d28c1ef1 100644 --- a/arch/mips/emma2rh/common/Makefile +++ b/arch/mips/emma/common/Makefile | |||
@@ -10,4 +10,4 @@ | |||
10 | # (at your option) any later version. | 10 | # (at your option) any later version. |
11 | # | 11 | # |
12 | 12 | ||
13 | obj-$(CONFIG_MARKEINS) += irq.o irq_emma2rh.o prom.o | 13 | obj-$(CONFIG_NEC_MARKEINS) += prom.o |
diff --git a/arch/mips/emma2rh/common/prom.c b/arch/mips/emma/common/prom.c index e14a2e3d8842..120f53fbdb45 100644 --- a/arch/mips/emma2rh/common/prom.c +++ b/arch/mips/emma/common/prom.c | |||
@@ -29,11 +29,11 @@ | |||
29 | 29 | ||
30 | #include <asm/addrspace.h> | 30 | #include <asm/addrspace.h> |
31 | #include <asm/bootinfo.h> | 31 | #include <asm/bootinfo.h> |
32 | #include <asm/emma2rh/emma2rh.h> | 32 | #include <asm/emma/emma2rh.h> |
33 | 33 | ||
34 | const char *get_system_type(void) | 34 | const char *get_system_type(void) |
35 | { | 35 | { |
36 | #if defined(CONFIG_MARKEINS) | 36 | #ifdef CONFIG_NEC_MARKEINS |
37 | return "NEC EMMA2RH Mark-eins"; | 37 | return "NEC EMMA2RH Mark-eins"; |
38 | #else | 38 | #else |
39 | #error Unknown NEC board | 39 | #error Unknown NEC board |
@@ -60,7 +60,7 @@ void __init prom_init(void) | |||
60 | strcat(arcs_cmdline, " "); | 60 | strcat(arcs_cmdline, " "); |
61 | } | 61 | } |
62 | 62 | ||
63 | #if defined(CONFIG_MARKEINS) | 63 | #ifdef CONFIG_NEC_MARKEINS |
64 | add_memory_region(0, EMMA2RH_RAM_SIZE, BOOT_MEM_RAM); | 64 | add_memory_region(0, EMMA2RH_RAM_SIZE, BOOT_MEM_RAM); |
65 | #else | 65 | #else |
66 | #error Unknown NEC board | 66 | #error Unknown NEC board |
diff --git a/arch/mips/emma2rh/markeins/Makefile b/arch/mips/emma/markeins/Makefile index 14fc268b175c..16e0017ba919 100644 --- a/arch/mips/emma2rh/markeins/Makefile +++ b/arch/mips/emma/markeins/Makefile | |||
@@ -10,4 +10,4 @@ | |||
10 | # (at your option) any later version. | 10 | # (at your option) any later version. |
11 | # | 11 | # |
12 | 12 | ||
13 | obj-$(CONFIG_MARKEINS) += irq.o irq_markeins.o setup.o led.o platform.o | 13 | obj-$(CONFIG_NEC_MARKEINS) += irq.o setup.o led.o platform.o |
diff --git a/arch/mips/emma/markeins/irq.c b/arch/mips/emma/markeins/irq.c new file mode 100644 index 000000000000..c2583ecc93cf --- /dev/null +++ b/arch/mips/emma/markeins/irq.c | |||
@@ -0,0 +1,331 @@ | |||
1 | /* | ||
2 | * arch/mips/emma2rh/markeins/irq.c | ||
3 | * This file defines the irq handler for EMMA2RH. | ||
4 | * | ||
5 | * Copyright (C) NEC Electronics Corporation 2004-2006 | ||
6 | * | ||
7 | * This file is based on the arch/mips/ddb5xxx/ddb5477/irq.c | ||
8 | * | ||
9 | * Copyright 2001 MontaVista Software Inc. | ||
10 | * | ||
11 | * This program is free software; you can redistribute it and/or modify | ||
12 | * it under the terms of the GNU General Public License as published by | ||
13 | * the Free Software Foundation; either version 2 of the License, or | ||
14 | * (at your option) any later version. | ||
15 | * | ||
16 | * This program is distributed in the hope that it will be useful, | ||
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
19 | * GNU General Public License for more details. | ||
20 | * | ||
21 | * You should have received a copy of the GNU General Public License | ||
22 | * along with this program; if not, write to the Free Software | ||
23 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
24 | */ | ||
25 | #include <linux/init.h> | ||
26 | #include <linux/interrupt.h> | ||
27 | #include <linux/irq.h> | ||
28 | #include <linux/types.h> | ||
29 | #include <linux/ptrace.h> | ||
30 | #include <linux/delay.h> | ||
31 | |||
32 | #include <asm/irq_cpu.h> | ||
33 | #include <asm/system.h> | ||
34 | #include <asm/mipsregs.h> | ||
35 | #include <asm/addrspace.h> | ||
36 | #include <asm/bootinfo.h> | ||
37 | |||
38 | #include <asm/emma/emma2rh.h> | ||
39 | |||
40 | static void emma2rh_irq_enable(unsigned int irq) | ||
41 | { | ||
42 | u32 reg_value; | ||
43 | u32 reg_bitmask; | ||
44 | u32 reg_index; | ||
45 | |||
46 | irq -= EMMA2RH_IRQ_BASE; | ||
47 | |||
48 | reg_index = EMMA2RH_BHIF_INT_EN_0 + | ||
49 | (EMMA2RH_BHIF_INT_EN_1 - EMMA2RH_BHIF_INT_EN_0) * (irq / 32); | ||
50 | reg_value = emma2rh_in32(reg_index); | ||
51 | reg_bitmask = 0x1 << (irq % 32); | ||
52 | emma2rh_out32(reg_index, reg_value | reg_bitmask); | ||
53 | } | ||
54 | |||
55 | static void emma2rh_irq_disable(unsigned int irq) | ||
56 | { | ||
57 | u32 reg_value; | ||
58 | u32 reg_bitmask; | ||
59 | u32 reg_index; | ||
60 | |||
61 | irq -= EMMA2RH_IRQ_BASE; | ||
62 | |||
63 | reg_index = EMMA2RH_BHIF_INT_EN_0 + | ||
64 | (EMMA2RH_BHIF_INT_EN_1 - EMMA2RH_BHIF_INT_EN_0) * (irq / 32); | ||
65 | reg_value = emma2rh_in32(reg_index); | ||
66 | reg_bitmask = 0x1 << (irq % 32); | ||
67 | emma2rh_out32(reg_index, reg_value & ~reg_bitmask); | ||
68 | } | ||
69 | |||
70 | struct irq_chip emma2rh_irq_controller = { | ||
71 | .name = "emma2rh_irq", | ||
72 | .ack = emma2rh_irq_disable, | ||
73 | .mask = emma2rh_irq_disable, | ||
74 | .mask_ack = emma2rh_irq_disable, | ||
75 | .unmask = emma2rh_irq_enable, | ||
76 | }; | ||
77 | |||
78 | void emma2rh_irq_init(void) | ||
79 | { | ||
80 | u32 i; | ||
81 | |||
82 | for (i = 0; i < NUM_EMMA2RH_IRQ; i++) | ||
83 | set_irq_chip_and_handler(EMMA2RH_IRQ_BASE + i, | ||
84 | &emma2rh_irq_controller, | ||
85 | handle_level_irq); | ||
86 | } | ||
87 | |||
88 | static void emma2rh_sw_irq_enable(unsigned int irq) | ||
89 | { | ||
90 | u32 reg; | ||
91 | |||
92 | irq -= EMMA2RH_SW_IRQ_BASE; | ||
93 | |||
94 | reg = emma2rh_in32(EMMA2RH_BHIF_SW_INT_EN); | ||
95 | reg |= 1 << irq; | ||
96 | emma2rh_out32(EMMA2RH_BHIF_SW_INT_EN, reg); | ||
97 | } | ||
98 | |||
99 | static void emma2rh_sw_irq_disable(unsigned int irq) | ||
100 | { | ||
101 | u32 reg; | ||
102 | |||
103 | irq -= EMMA2RH_SW_IRQ_BASE; | ||
104 | |||
105 | reg = emma2rh_in32(EMMA2RH_BHIF_SW_INT_EN); | ||
106 | reg &= ~(1 << irq); | ||
107 | emma2rh_out32(EMMA2RH_BHIF_SW_INT_EN, reg); | ||
108 | } | ||
109 | |||
110 | struct irq_chip emma2rh_sw_irq_controller = { | ||
111 | .name = "emma2rh_sw_irq", | ||
112 | .ack = emma2rh_sw_irq_disable, | ||
113 | .mask = emma2rh_sw_irq_disable, | ||
114 | .mask_ack = emma2rh_sw_irq_disable, | ||
115 | .unmask = emma2rh_sw_irq_enable, | ||
116 | }; | ||
117 | |||
118 | void emma2rh_sw_irq_init(void) | ||
119 | { | ||
120 | u32 i; | ||
121 | |||
122 | for (i = 0; i < NUM_EMMA2RH_IRQ_SW; i++) | ||
123 | set_irq_chip_and_handler(EMMA2RH_SW_IRQ_BASE + i, | ||
124 | &emma2rh_sw_irq_controller, | ||
125 | handle_level_irq); | ||
126 | } | ||
127 | |||
128 | static void emma2rh_gpio_irq_enable(unsigned int irq) | ||
129 | { | ||
130 | u32 reg; | ||
131 | |||
132 | irq -= EMMA2RH_GPIO_IRQ_BASE; | ||
133 | |||
134 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_MASK); | ||
135 | reg |= 1 << irq; | ||
136 | emma2rh_out32(EMMA2RH_GPIO_INT_MASK, reg); | ||
137 | } | ||
138 | |||
139 | static void emma2rh_gpio_irq_disable(unsigned int irq) | ||
140 | { | ||
141 | u32 reg; | ||
142 | |||
143 | irq -= EMMA2RH_GPIO_IRQ_BASE; | ||
144 | |||
145 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_MASK); | ||
146 | reg &= ~(1 << irq); | ||
147 | emma2rh_out32(EMMA2RH_GPIO_INT_MASK, reg); | ||
148 | } | ||
149 | |||
150 | static void emma2rh_gpio_irq_ack(unsigned int irq) | ||
151 | { | ||
152 | u32 reg; | ||
153 | |||
154 | irq -= EMMA2RH_GPIO_IRQ_BASE; | ||
155 | emma2rh_out32(EMMA2RH_GPIO_INT_ST, ~(1 << irq)); | ||
156 | |||
157 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_MASK); | ||
158 | reg &= ~(1 << irq); | ||
159 | emma2rh_out32(EMMA2RH_GPIO_INT_MASK, reg); | ||
160 | } | ||
161 | |||
162 | static void emma2rh_gpio_irq_end(unsigned int irq) | ||
163 | { | ||
164 | u32 reg; | ||
165 | |||
166 | if (!(irq_desc[irq].status & (IRQ_DISABLED | IRQ_INPROGRESS))) { | ||
167 | |||
168 | irq -= EMMA2RH_GPIO_IRQ_BASE; | ||
169 | |||
170 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_MASK); | ||
171 | reg |= 1 << irq; | ||
172 | emma2rh_out32(EMMA2RH_GPIO_INT_MASK, reg); | ||
173 | } | ||
174 | } | ||
175 | |||
176 | struct irq_chip emma2rh_gpio_irq_controller = { | ||
177 | .name = "emma2rh_gpio_irq", | ||
178 | .ack = emma2rh_gpio_irq_ack, | ||
179 | .mask = emma2rh_gpio_irq_disable, | ||
180 | .mask_ack = emma2rh_gpio_irq_ack, | ||
181 | .unmask = emma2rh_gpio_irq_enable, | ||
182 | .end = emma2rh_gpio_irq_end, | ||
183 | }; | ||
184 | |||
185 | void emma2rh_gpio_irq_init(void) | ||
186 | { | ||
187 | u32 i; | ||
188 | |||
189 | for (i = 0; i < NUM_EMMA2RH_IRQ_GPIO; i++) | ||
190 | set_irq_chip(EMMA2RH_GPIO_IRQ_BASE + i, | ||
191 | &emma2rh_gpio_irq_controller); | ||
192 | } | ||
193 | |||
194 | static struct irqaction irq_cascade = { | ||
195 | .handler = no_action, | ||
196 | .flags = 0, | ||
197 | .mask = CPU_MASK_NONE, | ||
198 | .name = "cascade", | ||
199 | .dev_id = NULL, | ||
200 | .next = NULL, | ||
201 | }; | ||
202 | |||
203 | /* | ||
204 | * the first level int-handler will jump here if it is a emma2rh irq | ||
205 | */ | ||
206 | void emma2rh_irq_dispatch(void) | ||
207 | { | ||
208 | u32 intStatus; | ||
209 | u32 bitmask; | ||
210 | u32 i; | ||
211 | |||
212 | intStatus = emma2rh_in32(EMMA2RH_BHIF_INT_ST_0) & | ||
213 | emma2rh_in32(EMMA2RH_BHIF_INT_EN_0); | ||
214 | |||
215 | #ifdef EMMA2RH_SW_CASCADE | ||
216 | if (intStatus & | ||
217 | (1 << ((EMMA2RH_SW_CASCADE - EMMA2RH_IRQ_INT0) & (32 - 1)))) { | ||
218 | u32 swIntStatus; | ||
219 | swIntStatus = emma2rh_in32(EMMA2RH_BHIF_SW_INT) | ||
220 | & emma2rh_in32(EMMA2RH_BHIF_SW_INT_EN); | ||
221 | for (i = 0, bitmask = 1; i < 32; i++, bitmask <<= 1) { | ||
222 | if (swIntStatus & bitmask) { | ||
223 | do_IRQ(EMMA2RH_SW_IRQ_BASE + i); | ||
224 | return; | ||
225 | } | ||
226 | } | ||
227 | } | ||
228 | #endif | ||
229 | |||
230 | for (i = 0, bitmask = 1; i < 32; i++, bitmask <<= 1) { | ||
231 | if (intStatus & bitmask) { | ||
232 | do_IRQ(EMMA2RH_IRQ_BASE + i); | ||
233 | return; | ||
234 | } | ||
235 | } | ||
236 | |||
237 | intStatus = emma2rh_in32(EMMA2RH_BHIF_INT_ST_1) & | ||
238 | emma2rh_in32(EMMA2RH_BHIF_INT_EN_1); | ||
239 | |||
240 | #ifdef EMMA2RH_GPIO_CASCADE | ||
241 | if (intStatus & | ||
242 | (1 << ((EMMA2RH_GPIO_CASCADE - EMMA2RH_IRQ_INT0) & (32 - 1)))) { | ||
243 | u32 gpioIntStatus; | ||
244 | gpioIntStatus = emma2rh_in32(EMMA2RH_GPIO_INT_ST) | ||
245 | & emma2rh_in32(EMMA2RH_GPIO_INT_MASK); | ||
246 | for (i = 0, bitmask = 1; i < 32; i++, bitmask <<= 1) { | ||
247 | if (gpioIntStatus & bitmask) { | ||
248 | do_IRQ(EMMA2RH_GPIO_IRQ_BASE + i); | ||
249 | return; | ||
250 | } | ||
251 | } | ||
252 | } | ||
253 | #endif | ||
254 | |||
255 | for (i = 32, bitmask = 1; i < 64; i++, bitmask <<= 1) { | ||
256 | if (intStatus & bitmask) { | ||
257 | do_IRQ(EMMA2RH_IRQ_BASE + i); | ||
258 | return; | ||
259 | } | ||
260 | } | ||
261 | |||
262 | intStatus = emma2rh_in32(EMMA2RH_BHIF_INT_ST_2) & | ||
263 | emma2rh_in32(EMMA2RH_BHIF_INT_EN_2); | ||
264 | |||
265 | for (i = 64, bitmask = 1; i < 96; i++, bitmask <<= 1) { | ||
266 | if (intStatus & bitmask) { | ||
267 | do_IRQ(EMMA2RH_IRQ_BASE + i); | ||
268 | return; | ||
269 | } | ||
270 | } | ||
271 | } | ||
272 | |||
273 | void __init arch_init_irq(void) | ||
274 | { | ||
275 | u32 reg; | ||
276 | |||
277 | /* by default, interrupts are disabled. */ | ||
278 | emma2rh_out32(EMMA2RH_BHIF_INT_EN_0, 0); | ||
279 | emma2rh_out32(EMMA2RH_BHIF_INT_EN_1, 0); | ||
280 | emma2rh_out32(EMMA2RH_BHIF_INT_EN_2, 0); | ||
281 | emma2rh_out32(EMMA2RH_BHIF_INT1_EN_0, 0); | ||
282 | emma2rh_out32(EMMA2RH_BHIF_INT1_EN_1, 0); | ||
283 | emma2rh_out32(EMMA2RH_BHIF_INT1_EN_2, 0); | ||
284 | emma2rh_out32(EMMA2RH_BHIF_SW_INT_EN, 0); | ||
285 | |||
286 | clear_c0_status(0xff00); | ||
287 | set_c0_status(0x0400); | ||
288 | |||
289 | #define GPIO_PCI (0xf<<15) | ||
290 | /* setup GPIO interrupt for PCI interface */ | ||
291 | /* direction input */ | ||
292 | reg = emma2rh_in32(EMMA2RH_GPIO_DIR); | ||
293 | emma2rh_out32(EMMA2RH_GPIO_DIR, reg & ~GPIO_PCI); | ||
294 | /* disable interrupt */ | ||
295 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_MASK); | ||
296 | emma2rh_out32(EMMA2RH_GPIO_INT_MASK, reg & ~GPIO_PCI); | ||
297 | /* level triggerd */ | ||
298 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_MODE); | ||
299 | emma2rh_out32(EMMA2RH_GPIO_INT_MODE, reg | GPIO_PCI); | ||
300 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_CND_A); | ||
301 | emma2rh_out32(EMMA2RH_GPIO_INT_CND_A, reg & (~GPIO_PCI)); | ||
302 | /* interrupt clear */ | ||
303 | emma2rh_out32(EMMA2RH_GPIO_INT_ST, ~GPIO_PCI); | ||
304 | |||
305 | /* init all controllers */ | ||
306 | emma2rh_irq_init(); | ||
307 | emma2rh_sw_irq_init(); | ||
308 | emma2rh_gpio_irq_init(); | ||
309 | mips_cpu_irq_init(); | ||
310 | |||
311 | /* setup cascade interrupts */ | ||
312 | setup_irq(EMMA2RH_IRQ_BASE + EMMA2RH_SW_CASCADE, &irq_cascade); | ||
313 | setup_irq(EMMA2RH_IRQ_BASE + EMMA2RH_GPIO_CASCADE, &irq_cascade); | ||
314 | setup_irq(CPU_IRQ_BASE + CPU_EMMA2RH_CASCADE, &irq_cascade); | ||
315 | } | ||
316 | |||
317 | asmlinkage void plat_irq_dispatch(void) | ||
318 | { | ||
319 | unsigned int pending = read_c0_status() & read_c0_cause() & ST0_IM; | ||
320 | |||
321 | if (pending & STATUSF_IP7) | ||
322 | do_IRQ(CPU_IRQ_BASE + 7); | ||
323 | else if (pending & STATUSF_IP2) | ||
324 | emma2rh_irq_dispatch(); | ||
325 | else if (pending & STATUSF_IP1) | ||
326 | do_IRQ(CPU_IRQ_BASE + 1); | ||
327 | else if (pending & STATUSF_IP0) | ||
328 | do_IRQ(CPU_IRQ_BASE + 0); | ||
329 | else | ||
330 | spurious_interrupt(); | ||
331 | } | ||
diff --git a/arch/mips/emma2rh/markeins/led.c b/arch/mips/emma/markeins/led.c index b65254c1bfe9..377a181b6561 100644 --- a/arch/mips/emma2rh/markeins/led.c +++ b/arch/mips/emma/markeins/led.c | |||
@@ -21,7 +21,7 @@ | |||
21 | #include <linux/kernel.h> | 21 | #include <linux/kernel.h> |
22 | #include <linux/types.h> | 22 | #include <linux/types.h> |
23 | #include <linux/string.h> | 23 | #include <linux/string.h> |
24 | #include <asm/emma2rh/emma2rh.h> | 24 | #include <asm/emma/emma2rh.h> |
25 | 25 | ||
26 | const unsigned long clear = 0x20202020; | 26 | const unsigned long clear = 0x20202020; |
27 | 27 | ||
diff --git a/arch/mips/emma2rh/markeins/platform.c b/arch/mips/emma/markeins/platform.c index fb9cda253ab0..88e87f6b3442 100644 --- a/arch/mips/emma2rh/markeins/platform.c +++ b/arch/mips/emma/markeins/platform.c | |||
@@ -36,7 +36,7 @@ | |||
36 | #include <asm/reboot.h> | 36 | #include <asm/reboot.h> |
37 | #include <asm/traps.h> | 37 | #include <asm/traps.h> |
38 | 38 | ||
39 | #include <asm/emma2rh/emma2rh.h> | 39 | #include <asm/emma/emma2rh.h> |
40 | 40 | ||
41 | 41 | ||
42 | #define I2C_EMMA2RH "emma2rh-iic" /* must be in sync with IIC driver */ | 42 | #define I2C_EMMA2RH "emma2rh-iic" /* must be in sync with IIC driver */ |
diff --git a/arch/mips/emma2rh/markeins/setup.c b/arch/mips/emma/markeins/setup.c index b6a23ad539f8..67f456500084 100644 --- a/arch/mips/emma2rh/markeins/setup.c +++ b/arch/mips/emma/markeins/setup.c | |||
@@ -29,7 +29,7 @@ | |||
29 | #include <asm/time.h> | 29 | #include <asm/time.h> |
30 | #include <asm/reboot.h> | 30 | #include <asm/reboot.h> |
31 | 31 | ||
32 | #include <asm/emma2rh/emma2rh.h> | 32 | #include <asm/emma/emma2rh.h> |
33 | 33 | ||
34 | #define USE_CPU_COUNTER_TIMER /* whether we use cpu counter */ | 34 | #define USE_CPU_COUNTER_TIMER /* whether we use cpu counter */ |
35 | 35 | ||
diff --git a/arch/mips/emma2rh/common/irq.c b/arch/mips/emma2rh/common/irq.c deleted file mode 100644 index 91cbd959ab67..000000000000 --- a/arch/mips/emma2rh/common/irq.c +++ /dev/null | |||
@@ -1,105 +0,0 @@ | |||
1 | /* | ||
2 | * arch/mips/emma2rh/common/irq.c | ||
3 | * This file is common irq dispatcher. | ||
4 | * | ||
5 | * Copyright (C) NEC Electronics Corporation 2005-2006 | ||
6 | * | ||
7 | * This file is based on the arch/mips/ddb5xxx/ddb5477/irq.c | ||
8 | * | ||
9 | * Copyright 2001 MontaVista Software Inc. | ||
10 | * | ||
11 | * This program is free software; you can redistribute it and/or modify | ||
12 | * it under the terms of the GNU General Public License as published by | ||
13 | * the Free Software Foundation; either version 2 of the License, or | ||
14 | * (at your option) any later version. | ||
15 | * | ||
16 | * This program is distributed in the hope that it will be useful, | ||
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
19 | * GNU General Public License for more details. | ||
20 | * | ||
21 | * You should have received a copy of the GNU General Public License | ||
22 | * along with this program; if not, write to the Free Software | ||
23 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
24 | */ | ||
25 | #include <linux/init.h> | ||
26 | #include <linux/interrupt.h> | ||
27 | #include <linux/irq.h> | ||
28 | #include <linux/types.h> | ||
29 | |||
30 | #include <asm/system.h> | ||
31 | #include <asm/mipsregs.h> | ||
32 | #include <asm/addrspace.h> | ||
33 | #include <asm/bootinfo.h> | ||
34 | |||
35 | #include <asm/emma2rh/emma2rh.h> | ||
36 | |||
37 | /* | ||
38 | * the first level int-handler will jump here if it is a emma2rh irq | ||
39 | */ | ||
40 | void emma2rh_irq_dispatch(void) | ||
41 | { | ||
42 | u32 intStatus; | ||
43 | u32 bitmask; | ||
44 | u32 i; | ||
45 | |||
46 | intStatus = emma2rh_in32(EMMA2RH_BHIF_INT_ST_0) | ||
47 | & emma2rh_in32(EMMA2RH_BHIF_INT_EN_0); | ||
48 | |||
49 | #ifdef EMMA2RH_SW_CASCADE | ||
50 | if (intStatus & | ||
51 | (1 << ((EMMA2RH_SW_CASCADE - EMMA2RH_IRQ_INT0) & (32 - 1)))) { | ||
52 | u32 swIntStatus; | ||
53 | swIntStatus = emma2rh_in32(EMMA2RH_BHIF_SW_INT) | ||
54 | & emma2rh_in32(EMMA2RH_BHIF_SW_INT_EN); | ||
55 | for (i = 0, bitmask = 1; i < 32; i++, bitmask <<= 1) { | ||
56 | if (swIntStatus & bitmask) { | ||
57 | do_IRQ(EMMA2RH_SW_IRQ_BASE + i); | ||
58 | return; | ||
59 | } | ||
60 | } | ||
61 | } | ||
62 | #endif | ||
63 | |||
64 | for (i = 0, bitmask = 1; i < 32; i++, bitmask <<= 1) { | ||
65 | if (intStatus & bitmask) { | ||
66 | do_IRQ(EMMA2RH_IRQ_BASE + i); | ||
67 | return; | ||
68 | } | ||
69 | } | ||
70 | |||
71 | intStatus = emma2rh_in32(EMMA2RH_BHIF_INT_ST_1) | ||
72 | & emma2rh_in32(EMMA2RH_BHIF_INT_EN_1); | ||
73 | |||
74 | #ifdef EMMA2RH_GPIO_CASCADE | ||
75 | if (intStatus & | ||
76 | (1 << ((EMMA2RH_GPIO_CASCADE - EMMA2RH_IRQ_INT0) & (32 - 1)))) { | ||
77 | u32 gpioIntStatus; | ||
78 | gpioIntStatus = emma2rh_in32(EMMA2RH_GPIO_INT_ST) | ||
79 | & emma2rh_in32(EMMA2RH_GPIO_INT_MASK); | ||
80 | for (i = 0, bitmask = 1; i < 32; i++, bitmask <<= 1) { | ||
81 | if (gpioIntStatus & bitmask) { | ||
82 | do_IRQ(EMMA2RH_GPIO_IRQ_BASE + i); | ||
83 | return; | ||
84 | } | ||
85 | } | ||
86 | } | ||
87 | #endif | ||
88 | |||
89 | for (i = 32, bitmask = 1; i < 64; i++, bitmask <<= 1) { | ||
90 | if (intStatus & bitmask) { | ||
91 | do_IRQ(EMMA2RH_IRQ_BASE + i); | ||
92 | return; | ||
93 | } | ||
94 | } | ||
95 | |||
96 | intStatus = emma2rh_in32(EMMA2RH_BHIF_INT_ST_2) | ||
97 | & emma2rh_in32(EMMA2RH_BHIF_INT_EN_2); | ||
98 | |||
99 | for (i = 64, bitmask = 1; i < 96; i++, bitmask <<= 1) { | ||
100 | if (intStatus & bitmask) { | ||
101 | do_IRQ(EMMA2RH_IRQ_BASE + i); | ||
102 | return; | ||
103 | } | ||
104 | } | ||
105 | } | ||
diff --git a/arch/mips/emma2rh/common/irq_emma2rh.c b/arch/mips/emma2rh/common/irq_emma2rh.c deleted file mode 100644 index 96df37b77759..000000000000 --- a/arch/mips/emma2rh/common/irq_emma2rh.c +++ /dev/null | |||
@@ -1,106 +0,0 @@ | |||
1 | /* | ||
2 | * arch/mips/emma2rh/common/irq_emma2rh.c | ||
3 | * This file defines the irq handler for EMMA2RH. | ||
4 | * | ||
5 | * Copyright (C) NEC Electronics Corporation 2005-2006 | ||
6 | * | ||
7 | * This file is based on the arch/mips/ddb5xxx/ddb5477/irq_5477.c | ||
8 | * | ||
9 | * Copyright 2001 MontaVista Software Inc. | ||
10 | * | ||
11 | * This program is free software; you can redistribute it and/or modify | ||
12 | * it under the terms of the GNU General Public License as published by | ||
13 | * the Free Software Foundation; either version 2 of the License, or | ||
14 | * (at your option) any later version. | ||
15 | * | ||
16 | * This program is distributed in the hope that it will be useful, | ||
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
19 | * GNU General Public License for more details. | ||
20 | * | ||
21 | * You should have received a copy of the GNU General Public License | ||
22 | * along with this program; if not, write to the Free Software | ||
23 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
24 | */ | ||
25 | |||
26 | /* | ||
27 | * EMMA2RH defines 64 IRQs. | ||
28 | * | ||
29 | * This file exports one function: | ||
30 | * emma2rh_irq_init(u32 irq_base); | ||
31 | */ | ||
32 | |||
33 | #include <linux/interrupt.h> | ||
34 | #include <linux/types.h> | ||
35 | #include <linux/ptrace.h> | ||
36 | |||
37 | #include <asm/debug.h> | ||
38 | |||
39 | #include <asm/emma2rh/emma2rh.h> | ||
40 | |||
41 | /* number of total irqs supported by EMMA2RH */ | ||
42 | #define NUM_EMMA2RH_IRQ 96 | ||
43 | |||
44 | static int emma2rh_irq_base = -1; | ||
45 | |||
46 | void ll_emma2rh_irq_enable(int); | ||
47 | void ll_emma2rh_irq_disable(int); | ||
48 | |||
49 | static void emma2rh_irq_enable(unsigned int irq) | ||
50 | { | ||
51 | ll_emma2rh_irq_enable(irq - emma2rh_irq_base); | ||
52 | } | ||
53 | |||
54 | static void emma2rh_irq_disable(unsigned int irq) | ||
55 | { | ||
56 | ll_emma2rh_irq_disable(irq - emma2rh_irq_base); | ||
57 | } | ||
58 | |||
59 | struct irq_chip emma2rh_irq_controller = { | ||
60 | .name = "emma2rh_irq", | ||
61 | .ack = emma2rh_irq_disable, | ||
62 | .mask = emma2rh_irq_disable, | ||
63 | .mask_ack = emma2rh_irq_disable, | ||
64 | .unmask = emma2rh_irq_enable, | ||
65 | }; | ||
66 | |||
67 | void emma2rh_irq_init(u32 irq_base) | ||
68 | { | ||
69 | u32 i; | ||
70 | |||
71 | for (i = irq_base; i < irq_base + NUM_EMMA2RH_IRQ; i++) | ||
72 | set_irq_chip_and_handler(i, &emma2rh_irq_controller, | ||
73 | handle_level_irq); | ||
74 | |||
75 | emma2rh_irq_base = irq_base; | ||
76 | } | ||
77 | |||
78 | void ll_emma2rh_irq_enable(int emma2rh_irq) | ||
79 | { | ||
80 | u32 reg_value; | ||
81 | u32 reg_bitmask; | ||
82 | u32 reg_index; | ||
83 | |||
84 | reg_index = EMMA2RH_BHIF_INT_EN_0 | ||
85 | + (EMMA2RH_BHIF_INT_EN_1 - EMMA2RH_BHIF_INT_EN_0) | ||
86 | * (emma2rh_irq / 32); | ||
87 | reg_value = emma2rh_in32(reg_index); | ||
88 | reg_bitmask = 0x1 << (emma2rh_irq % 32); | ||
89 | db_assert((reg_value & reg_bitmask) == 0); | ||
90 | emma2rh_out32(reg_index, reg_value | reg_bitmask); | ||
91 | } | ||
92 | |||
93 | void ll_emma2rh_irq_disable(int emma2rh_irq) | ||
94 | { | ||
95 | u32 reg_value; | ||
96 | u32 reg_bitmask; | ||
97 | u32 reg_index; | ||
98 | |||
99 | reg_index = EMMA2RH_BHIF_INT_EN_0 | ||
100 | + (EMMA2RH_BHIF_INT_EN_1 - EMMA2RH_BHIF_INT_EN_0) | ||
101 | * (emma2rh_irq / 32); | ||
102 | reg_value = emma2rh_in32(reg_index); | ||
103 | reg_bitmask = 0x1 << (emma2rh_irq % 32); | ||
104 | db_assert((reg_value & reg_bitmask) != 0); | ||
105 | emma2rh_out32(reg_index, reg_value & ~reg_bitmask); | ||
106 | } | ||
diff --git a/arch/mips/emma2rh/markeins/irq.c b/arch/mips/emma2rh/markeins/irq.c deleted file mode 100644 index 6bcf6a06367a..000000000000 --- a/arch/mips/emma2rh/markeins/irq.c +++ /dev/null | |||
@@ -1,132 +0,0 @@ | |||
1 | /* | ||
2 | * arch/mips/emma2rh/markeins/irq.c | ||
3 | * This file defines the irq handler for EMMA2RH. | ||
4 | * | ||
5 | * Copyright (C) NEC Electronics Corporation 2004-2006 | ||
6 | * | ||
7 | * This file is based on the arch/mips/ddb5xxx/ddb5477/irq.c | ||
8 | * | ||
9 | * Copyright 2001 MontaVista Software Inc. | ||
10 | * | ||
11 | * This program is free software; you can redistribute it and/or modify | ||
12 | * it under the terms of the GNU General Public License as published by | ||
13 | * the Free Software Foundation; either version 2 of the License, or | ||
14 | * (at your option) any later version. | ||
15 | * | ||
16 | * This program is distributed in the hope that it will be useful, | ||
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
19 | * GNU General Public License for more details. | ||
20 | * | ||
21 | * You should have received a copy of the GNU General Public License | ||
22 | * along with this program; if not, write to the Free Software | ||
23 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
24 | */ | ||
25 | #include <linux/init.h> | ||
26 | #include <linux/interrupt.h> | ||
27 | #include <linux/irq.h> | ||
28 | #include <linux/types.h> | ||
29 | #include <linux/ptrace.h> | ||
30 | #include <linux/delay.h> | ||
31 | |||
32 | #include <asm/irq_cpu.h> | ||
33 | #include <asm/system.h> | ||
34 | #include <asm/mipsregs.h> | ||
35 | #include <asm/debug.h> | ||
36 | #include <asm/addrspace.h> | ||
37 | #include <asm/bootinfo.h> | ||
38 | |||
39 | #include <asm/emma2rh/emma2rh.h> | ||
40 | |||
41 | /* | ||
42 | * IRQ mapping | ||
43 | * | ||
44 | * 0-7: 8 CPU interrupts | ||
45 | * 0 - software interrupt 0 | ||
46 | * 1 - software interrupt 1 | ||
47 | * 2 - most Vrc5477 interrupts are routed to this pin | ||
48 | * 3 - (optional) some other interrupts routed to this pin for debugg | ||
49 | * 4 - not used | ||
50 | * 5 - not used | ||
51 | * 6 - not used | ||
52 | * 7 - cpu timer (used by default) | ||
53 | * | ||
54 | */ | ||
55 | |||
56 | extern void emma2rh_sw_irq_init(u32 base); | ||
57 | extern void emma2rh_gpio_irq_init(u32 base); | ||
58 | extern void emma2rh_irq_init(u32 base); | ||
59 | extern void emma2rh_irq_dispatch(void); | ||
60 | |||
61 | static struct irqaction irq_cascade = { | ||
62 | .handler = no_action, | ||
63 | .flags = 0, | ||
64 | .mask = CPU_MASK_NONE, | ||
65 | .name = "cascade", | ||
66 | .dev_id = NULL, | ||
67 | .next = NULL, | ||
68 | }; | ||
69 | |||
70 | void __init arch_init_irq(void) | ||
71 | { | ||
72 | u32 reg; | ||
73 | |||
74 | db_run(printk("markeins_irq_setup invoked.\n")); | ||
75 | |||
76 | /* by default, interrupts are disabled. */ | ||
77 | emma2rh_out32(EMMA2RH_BHIF_INT_EN_0, 0); | ||
78 | emma2rh_out32(EMMA2RH_BHIF_INT_EN_1, 0); | ||
79 | emma2rh_out32(EMMA2RH_BHIF_INT_EN_2, 0); | ||
80 | emma2rh_out32(EMMA2RH_BHIF_INT1_EN_0, 0); | ||
81 | emma2rh_out32(EMMA2RH_BHIF_INT1_EN_1, 0); | ||
82 | emma2rh_out32(EMMA2RH_BHIF_INT1_EN_2, 0); | ||
83 | emma2rh_out32(EMMA2RH_BHIF_SW_INT_EN, 0); | ||
84 | |||
85 | clear_c0_status(0xff00); | ||
86 | set_c0_status(0x0400); | ||
87 | |||
88 | #define GPIO_PCI (0xf<<15) | ||
89 | /* setup GPIO interrupt for PCI interface */ | ||
90 | /* direction input */ | ||
91 | reg = emma2rh_in32(EMMA2RH_GPIO_DIR); | ||
92 | emma2rh_out32(EMMA2RH_GPIO_DIR, reg & ~GPIO_PCI); | ||
93 | /* disable interrupt */ | ||
94 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_MASK); | ||
95 | emma2rh_out32(EMMA2RH_GPIO_INT_MASK, reg & ~GPIO_PCI); | ||
96 | /* level triggerd */ | ||
97 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_MODE); | ||
98 | emma2rh_out32(EMMA2RH_GPIO_INT_MODE, reg | GPIO_PCI); | ||
99 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_CND_A); | ||
100 | emma2rh_out32(EMMA2RH_GPIO_INT_CND_A, reg & (~GPIO_PCI)); | ||
101 | /* interrupt clear */ | ||
102 | emma2rh_out32(EMMA2RH_GPIO_INT_ST, ~GPIO_PCI); | ||
103 | |||
104 | /* init all controllers */ | ||
105 | emma2rh_irq_init(EMMA2RH_IRQ_BASE); | ||
106 | emma2rh_sw_irq_init(EMMA2RH_SW_IRQ_BASE); | ||
107 | emma2rh_gpio_irq_init(EMMA2RH_GPIO_IRQ_BASE); | ||
108 | mips_cpu_irq_init(); | ||
109 | |||
110 | /* setup cascade interrupts */ | ||
111 | setup_irq(EMMA2RH_IRQ_BASE + EMMA2RH_SW_CASCADE, &irq_cascade); | ||
112 | setup_irq(EMMA2RH_IRQ_BASE + EMMA2RH_GPIO_CASCADE, &irq_cascade); | ||
113 | setup_irq(CPU_IRQ_BASE + CPU_EMMA2RH_CASCADE, &irq_cascade); | ||
114 | } | ||
115 | |||
116 | asmlinkage void plat_irq_dispatch(void) | ||
117 | { | ||
118 | unsigned int pending = read_c0_status() & read_c0_cause() & ST0_IM; | ||
119 | |||
120 | if (pending & STATUSF_IP7) | ||
121 | do_IRQ(CPU_IRQ_BASE + 7); | ||
122 | else if (pending & STATUSF_IP2) | ||
123 | emma2rh_irq_dispatch(); | ||
124 | else if (pending & STATUSF_IP1) | ||
125 | do_IRQ(CPU_IRQ_BASE + 1); | ||
126 | else if (pending & STATUSF_IP0) | ||
127 | do_IRQ(CPU_IRQ_BASE + 0); | ||
128 | else | ||
129 | spurious_interrupt(); | ||
130 | } | ||
131 | |||
132 | |||
diff --git a/arch/mips/emma2rh/markeins/irq_markeins.c b/arch/mips/emma2rh/markeins/irq_markeins.c deleted file mode 100644 index fba5c156f472..000000000000 --- a/arch/mips/emma2rh/markeins/irq_markeins.c +++ /dev/null | |||
@@ -1,158 +0,0 @@ | |||
1 | /* | ||
2 | * arch/mips/emma2rh/markeins/irq_markeins.c | ||
3 | * This file defines the irq handler for Mark-eins. | ||
4 | * | ||
5 | * Copyright (C) NEC Electronics Corporation 2004-2006 | ||
6 | * | ||
7 | * This file is based on the arch/mips/ddb5xxx/ddb5477/irq_5477.c | ||
8 | * | ||
9 | * Copyright 2001 MontaVista Software Inc. | ||
10 | * | ||
11 | * This program is free software; you can redistribute it and/or modify | ||
12 | * it under the terms of the GNU General Public License as published by | ||
13 | * the Free Software Foundation; either version 2 of the License, or | ||
14 | * (at your option) any later version. | ||
15 | * | ||
16 | * This program is distributed in the hope that it will be useful, | ||
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
19 | * GNU General Public License for more details. | ||
20 | * | ||
21 | * You should have received a copy of the GNU General Public License | ||
22 | * along with this program; if not, write to the Free Software | ||
23 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
24 | */ | ||
25 | #include <linux/interrupt.h> | ||
26 | #include <linux/irq.h> | ||
27 | #include <linux/types.h> | ||
28 | #include <linux/ptrace.h> | ||
29 | |||
30 | #include <asm/debug.h> | ||
31 | #include <asm/emma2rh/emma2rh.h> | ||
32 | |||
33 | static int emma2rh_sw_irq_base = -1; | ||
34 | static int emma2rh_gpio_irq_base = -1; | ||
35 | |||
36 | void ll_emma2rh_sw_irq_enable(int reg); | ||
37 | void ll_emma2rh_sw_irq_disable(int reg); | ||
38 | void ll_emma2rh_gpio_irq_enable(int reg); | ||
39 | void ll_emma2rh_gpio_irq_disable(int reg); | ||
40 | |||
41 | static void emma2rh_sw_irq_enable(unsigned int irq) | ||
42 | { | ||
43 | ll_emma2rh_sw_irq_enable(irq - emma2rh_sw_irq_base); | ||
44 | } | ||
45 | |||
46 | static void emma2rh_sw_irq_disable(unsigned int irq) | ||
47 | { | ||
48 | ll_emma2rh_sw_irq_disable(irq - emma2rh_sw_irq_base); | ||
49 | } | ||
50 | |||
51 | struct irq_chip emma2rh_sw_irq_controller = { | ||
52 | .name = "emma2rh_sw_irq", | ||
53 | .ack = emma2rh_sw_irq_disable, | ||
54 | .mask = emma2rh_sw_irq_disable, | ||
55 | .mask_ack = emma2rh_sw_irq_disable, | ||
56 | .unmask = emma2rh_sw_irq_enable, | ||
57 | }; | ||
58 | |||
59 | void emma2rh_sw_irq_init(u32 irq_base) | ||
60 | { | ||
61 | u32 i; | ||
62 | |||
63 | for (i = irq_base; i < irq_base + NUM_EMMA2RH_IRQ_SW; i++) | ||
64 | set_irq_chip_and_handler(i, &emma2rh_sw_irq_controller, | ||
65 | handle_level_irq); | ||
66 | |||
67 | emma2rh_sw_irq_base = irq_base; | ||
68 | } | ||
69 | |||
70 | void ll_emma2rh_sw_irq_enable(int irq) | ||
71 | { | ||
72 | u32 reg; | ||
73 | |||
74 | db_assert(irq >= 0); | ||
75 | db_assert(irq < NUM_EMMA2RH_IRQ_SW); | ||
76 | |||
77 | reg = emma2rh_in32(EMMA2RH_BHIF_SW_INT_EN); | ||
78 | reg |= 1 << irq; | ||
79 | emma2rh_out32(EMMA2RH_BHIF_SW_INT_EN, reg); | ||
80 | } | ||
81 | |||
82 | void ll_emma2rh_sw_irq_disable(int irq) | ||
83 | { | ||
84 | u32 reg; | ||
85 | |||
86 | db_assert(irq >= 0); | ||
87 | db_assert(irq < 32); | ||
88 | |||
89 | reg = emma2rh_in32(EMMA2RH_BHIF_SW_INT_EN); | ||
90 | reg &= ~(1 << irq); | ||
91 | emma2rh_out32(EMMA2RH_BHIF_SW_INT_EN, reg); | ||
92 | } | ||
93 | |||
94 | static void emma2rh_gpio_irq_enable(unsigned int irq) | ||
95 | { | ||
96 | ll_emma2rh_gpio_irq_enable(irq - emma2rh_gpio_irq_base); | ||
97 | } | ||
98 | |||
99 | static void emma2rh_gpio_irq_disable(unsigned int irq) | ||
100 | { | ||
101 | ll_emma2rh_gpio_irq_disable(irq - emma2rh_gpio_irq_base); | ||
102 | } | ||
103 | |||
104 | static void emma2rh_gpio_irq_ack(unsigned int irq) | ||
105 | { | ||
106 | irq -= emma2rh_gpio_irq_base; | ||
107 | emma2rh_out32(EMMA2RH_GPIO_INT_ST, ~(1 << irq)); | ||
108 | ll_emma2rh_gpio_irq_disable(irq); | ||
109 | } | ||
110 | |||
111 | static void emma2rh_gpio_irq_end(unsigned int irq) | ||
112 | { | ||
113 | if (!(irq_desc[irq].status & (IRQ_DISABLED | IRQ_INPROGRESS))) | ||
114 | ll_emma2rh_gpio_irq_enable(irq - emma2rh_gpio_irq_base); | ||
115 | } | ||
116 | |||
117 | struct irq_chip emma2rh_gpio_irq_controller = { | ||
118 | .name = "emma2rh_gpio_irq", | ||
119 | .ack = emma2rh_gpio_irq_ack, | ||
120 | .mask = emma2rh_gpio_irq_disable, | ||
121 | .mask_ack = emma2rh_gpio_irq_ack, | ||
122 | .unmask = emma2rh_gpio_irq_enable, | ||
123 | .end = emma2rh_gpio_irq_end, | ||
124 | }; | ||
125 | |||
126 | void emma2rh_gpio_irq_init(u32 irq_base) | ||
127 | { | ||
128 | u32 i; | ||
129 | |||
130 | for (i = irq_base; i < irq_base + NUM_EMMA2RH_IRQ_GPIO; i++) | ||
131 | set_irq_chip(i, &emma2rh_gpio_irq_controller); | ||
132 | |||
133 | emma2rh_gpio_irq_base = irq_base; | ||
134 | } | ||
135 | |||
136 | void ll_emma2rh_gpio_irq_enable(int irq) | ||
137 | { | ||
138 | u32 reg; | ||
139 | |||
140 | db_assert(irq >= 0); | ||
141 | db_assert(irq < NUM_EMMA2RH_IRQ_GPIO); | ||
142 | |||
143 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_MASK); | ||
144 | reg |= 1 << irq; | ||
145 | emma2rh_out32(EMMA2RH_GPIO_INT_MASK, reg); | ||
146 | } | ||
147 | |||
148 | void ll_emma2rh_gpio_irq_disable(int irq) | ||
149 | { | ||
150 | u32 reg; | ||
151 | |||
152 | db_assert(irq >= 0); | ||
153 | db_assert(irq < NUM_EMMA2RH_IRQ_GPIO); | ||
154 | |||
155 | reg = emma2rh_in32(EMMA2RH_GPIO_INT_MASK); | ||
156 | reg &= ~(1 << irq); | ||
157 | emma2rh_out32(EMMA2RH_GPIO_INT_MASK, reg); | ||
158 | } | ||
diff --git a/arch/mips/include/asm/emma2rh/emma2rh.h b/arch/mips/include/asm/emma/emma2rh.h index 6a1af0af51e3..30aea91de626 100644 --- a/arch/mips/include/asm/emma2rh/emma2rh.h +++ b/arch/mips/include/asm/emma/emma2rh.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * include/asm-mips/emma2rh/emma2rh.h | 2 | * arch/mips/include/asm/emma/emma2rh.h |
3 | * This file is EMMA2RH common header. | 3 | * This file is EMMA2RH common header. |
4 | * | 4 | * |
5 | * Copyright (C) NEC Electronics Corporation 2005-2006 | 5 | * Copyright (C) NEC Electronics Corporation 2005-2006 |
@@ -21,8 +21,8 @@ | |||
21 | * along with this program; if not, write to the Free Software | 21 | * along with this program; if not, write to the Free Software |
22 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 22 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
23 | */ | 23 | */ |
24 | #ifndef __ASM_EMMA2RH_EMMA2RH_H | 24 | #ifndef __ASM_EMMA_EMMA2RH_H |
25 | #define __ASM_EMMA2RH_EMMA2RH_H | 25 | #define __ASM_EMMA_EMMA2RH_H |
26 | 26 | ||
27 | #include <irq.h> | 27 | #include <irq.h> |
28 | 28 | ||
@@ -206,7 +206,6 @@ static inline void emma2rh_out32(u32 offset, u32 val) | |||
206 | static inline u32 emma2rh_in32(u32 offset) | 206 | static inline u32 emma2rh_in32(u32 offset) |
207 | { | 207 | { |
208 | u32 val = *(volatile u32 *)(EMMA2RH_BASE | offset); | 208 | u32 val = *(volatile u32 *)(EMMA2RH_BASE | offset); |
209 | emma2rh_sync(); | ||
210 | return val; | 209 | return val; |
211 | } | 210 | } |
212 | 211 | ||
@@ -219,7 +218,6 @@ static inline void emma2rh_out16(u32 offset, u16 val) | |||
219 | static inline u16 emma2rh_in16(u32 offset) | 218 | static inline u16 emma2rh_in16(u32 offset) |
220 | { | 219 | { |
221 | u16 val = *(volatile u16 *)(EMMA2RH_BASE | offset); | 220 | u16 val = *(volatile u16 *)(EMMA2RH_BASE | offset); |
222 | emma2rh_sync(); | ||
223 | return val; | 221 | return val; |
224 | } | 222 | } |
225 | 223 | ||
@@ -232,7 +230,6 @@ static inline void emma2rh_out8(u32 offset, u8 val) | |||
232 | static inline u8 emma2rh_in8(u32 offset) | 230 | static inline u8 emma2rh_in8(u32 offset) |
233 | { | 231 | { |
234 | u8 val = *(volatile u8 *)(EMMA2RH_BASE | offset); | 232 | u8 val = *(volatile u8 *)(EMMA2RH_BASE | offset); |
235 | emma2rh_sync(); | ||
236 | return val; | 233 | return val; |
237 | } | 234 | } |
238 | 235 | ||
@@ -324,10 +321,10 @@ static inline u8 emma2rh_in8(u32 offset) | |||
324 | /* | 321 | /* |
325 | * include the board dependent part | 322 | * include the board dependent part |
326 | */ | 323 | */ |
327 | #if defined(CONFIG_MARKEINS) | 324 | #ifdef CONFIG_NEC_MARKEINS |
328 | #include <asm/emma2rh/markeins.h> | 325 | #include <asm/emma/markeins.h> |
329 | #else | 326 | #else |
330 | #error "Unknown EMMA2RH board!" | 327 | #error "Unknown EMMA2RH board!" |
331 | #endif | 328 | #endif |
332 | 329 | ||
333 | #endif /* __ASM_EMMA2RH_EMMA2RH_H */ | 330 | #endif /* __ASM_EMMA_EMMA2RH_H */ |
diff --git a/arch/mips/include/asm/emma2rh/markeins.h b/arch/mips/include/asm/emma/markeins.h index 973b0628490d..973b0628490d 100644 --- a/arch/mips/include/asm/emma2rh/markeins.h +++ b/arch/mips/include/asm/emma/markeins.h | |||
diff --git a/arch/mips/include/asm/mach-lemote/pci.h b/arch/mips/include/asm/mach-lemote/pci.h new file mode 100644 index 000000000000..ea6aa143b78e --- /dev/null +++ b/arch/mips/include/asm/mach-lemote/pci.h | |||
@@ -0,0 +1,30 @@ | |||
1 | /* | ||
2 | * Copyright (c) 2008 Zhang Le <r0bertz@gentoo.org> | ||
3 | * | ||
4 | * This program is free software; you can redistribute it | ||
5 | * and/or modify it under the terms of the GNU General | ||
6 | * Public License as published by the Free Software | ||
7 | * Foundation; either version 2 of the License, or (at your | ||
8 | * option) any later version. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be | ||
11 | * useful, but WITHOUT ANY WARRANTY; without even the implied | ||
12 | * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR | ||
13 | * PURPOSE. See the GNU General Public License for more | ||
14 | * details. | ||
15 | * | ||
16 | * You should have received a copy of the GNU General Public | ||
17 | * License along with this program; if not, write to the Free | ||
18 | * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA | ||
19 | * 02139, USA. | ||
20 | */ | ||
21 | |||
22 | #ifndef _LEMOTE_PCI_H_ | ||
23 | #define _LEMOTE_PCI_H_ | ||
24 | |||
25 | #define LOONGSON2E_PCI_MEM_START 0x14000000UL | ||
26 | #define LOONGSON2E_PCI_MEM_END 0x1fffffffUL | ||
27 | #define LOONGSON2E_PCI_IO_START 0x00004000UL | ||
28 | #define LOONGSON2E_IO_PORT_BASE 0x1fd00000UL | ||
29 | |||
30 | #endif /* !_LEMOTE_PCI_H_ */ | ||
diff --git a/arch/mips/include/asm/mach-pnx833x/gpio.h b/arch/mips/include/asm/mach-pnx833x/gpio.h new file mode 100644 index 000000000000..8de0eb9c98a3 --- /dev/null +++ b/arch/mips/include/asm/mach-pnx833x/gpio.h | |||
@@ -0,0 +1,172 @@ | |||
1 | /* | ||
2 | * gpio.h: GPIO Support for PNX833X. | ||
3 | * | ||
4 | * Copyright 2008 NXP Semiconductors | ||
5 | * Chris Steel <chris.steel@nxp.com> | ||
6 | * Daniel Laird <daniel.j.laird@nxp.com> | ||
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. | ||
12 | * | ||
13 | * This program is distributed in the hope that it will be useful, | ||
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
16 | * GNU General Public License for more details. | ||
17 | * | ||
18 | * You should have received a copy of the GNU General Public License | ||
19 | * along with this program; if not, write to the Free Software | ||
20 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
21 | */ | ||
22 | #ifndef __ASM_MIPS_MACH_PNX833X_GPIO_H | ||
23 | #define __ASM_MIPS_MACH_PNX833X_GPIO_H | ||
24 | |||
25 | /* BIG FAT WARNING: races danger! | ||
26 | No protections exist here. Current users are only early init code, | ||
27 | when locking is not needed because no cuncurency yet exists there, | ||
28 | and GPIO IRQ dispatcher, which does locking. | ||
29 | However, if many uses will ever happen, proper locking will be needed | ||
30 | - including locking between different uses | ||
31 | */ | ||
32 | |||
33 | #include "pnx833x.h" | ||
34 | |||
35 | #define SET_REG_BIT(reg, bit) do { (reg |= (1 << (bit))); } while (0) | ||
36 | #define CLEAR_REG_BIT(reg, bit) do { (reg &= ~(1 << (bit))); } while (0) | ||
37 | |||
38 | /* Initialize GPIO to a known state */ | ||
39 | static inline void pnx833x_gpio_init(void) | ||
40 | { | ||
41 | PNX833X_PIO_DIR = 0; | ||
42 | PNX833X_PIO_DIR2 = 0; | ||
43 | PNX833X_PIO_SEL = 0; | ||
44 | PNX833X_PIO_SEL2 = 0; | ||
45 | PNX833X_PIO_INT_EDGE = 0; | ||
46 | PNX833X_PIO_INT_HI = 0; | ||
47 | PNX833X_PIO_INT_LO = 0; | ||
48 | |||
49 | /* clear any GPIO interrupt requests */ | ||
50 | PNX833X_PIO_INT_CLEAR = 0xffff; | ||
51 | PNX833X_PIO_INT_CLEAR = 0; | ||
52 | PNX833X_PIO_INT_ENABLE = 0; | ||
53 | } | ||
54 | |||
55 | /* Select GPIO direction for a pin */ | ||
56 | static inline void pnx833x_gpio_select_input(unsigned int pin) | ||
57 | { | ||
58 | if (pin < 32) | ||
59 | CLEAR_REG_BIT(PNX833X_PIO_DIR, pin); | ||
60 | else | ||
61 | CLEAR_REG_BIT(PNX833X_PIO_DIR2, pin & 31); | ||
62 | } | ||
63 | static inline void pnx833x_gpio_select_output(unsigned int pin) | ||
64 | { | ||
65 | if (pin < 32) | ||
66 | SET_REG_BIT(PNX833X_PIO_DIR, pin); | ||
67 | else | ||
68 | SET_REG_BIT(PNX833X_PIO_DIR2, pin & 31); | ||
69 | } | ||
70 | |||
71 | /* Select GPIO or alternate function for a pin */ | ||
72 | static inline void pnx833x_gpio_select_function_io(unsigned int pin) | ||
73 | { | ||
74 | if (pin < 32) | ||
75 | CLEAR_REG_BIT(PNX833X_PIO_SEL, pin); | ||
76 | else | ||
77 | CLEAR_REG_BIT(PNX833X_PIO_SEL2, pin & 31); | ||
78 | } | ||
79 | static inline void pnx833x_gpio_select_function_alt(unsigned int pin) | ||
80 | { | ||
81 | if (pin < 32) | ||
82 | SET_REG_BIT(PNX833X_PIO_SEL, pin); | ||
83 | else | ||
84 | SET_REG_BIT(PNX833X_PIO_SEL2, pin & 31); | ||
85 | } | ||
86 | |||
87 | /* Read GPIO pin */ | ||
88 | static inline int pnx833x_gpio_read(unsigned int pin) | ||
89 | { | ||
90 | if (pin < 32) | ||
91 | return (PNX833X_PIO_IN >> pin) & 1; | ||
92 | else | ||
93 | return (PNX833X_PIO_IN2 >> (pin & 31)) & 1; | ||
94 | } | ||
95 | |||
96 | /* Write GPIO pin */ | ||
97 | static inline void pnx833x_gpio_write(unsigned int val, unsigned int pin) | ||
98 | { | ||
99 | if (pin < 32) { | ||
100 | if (val) | ||
101 | SET_REG_BIT(PNX833X_PIO_OUT, pin); | ||
102 | else | ||
103 | CLEAR_REG_BIT(PNX833X_PIO_OUT, pin); | ||
104 | } else { | ||
105 | if (val) | ||
106 | SET_REG_BIT(PNX833X_PIO_OUT2, pin & 31); | ||
107 | else | ||
108 | CLEAR_REG_BIT(PNX833X_PIO_OUT2, pin & 31); | ||
109 | } | ||
110 | } | ||
111 | |||
112 | /* Configure GPIO interrupt */ | ||
113 | #define GPIO_INT_NONE 0 | ||
114 | #define GPIO_INT_LEVEL_LOW 1 | ||
115 | #define GPIO_INT_LEVEL_HIGH 2 | ||
116 | #define GPIO_INT_EDGE_RISING 3 | ||
117 | #define GPIO_INT_EDGE_FALLING 4 | ||
118 | #define GPIO_INT_EDGE_BOTH 5 | ||
119 | static inline void pnx833x_gpio_setup_irq(int when, unsigned int pin) | ||
120 | { | ||
121 | switch (when) { | ||
122 | case GPIO_INT_LEVEL_LOW: | ||
123 | CLEAR_REG_BIT(PNX833X_PIO_INT_EDGE, pin); | ||
124 | CLEAR_REG_BIT(PNX833X_PIO_INT_HI, pin); | ||
125 | SET_REG_BIT(PNX833X_PIO_INT_LO, pin); | ||
126 | break; | ||
127 | case GPIO_INT_LEVEL_HIGH: | ||
128 | CLEAR_REG_BIT(PNX833X_PIO_INT_EDGE, pin); | ||
129 | SET_REG_BIT(PNX833X_PIO_INT_HI, pin); | ||
130 | CLEAR_REG_BIT(PNX833X_PIO_INT_LO, pin); | ||
131 | break; | ||
132 | case GPIO_INT_EDGE_RISING: | ||
133 | SET_REG_BIT(PNX833X_PIO_INT_EDGE, pin); | ||
134 | SET_REG_BIT(PNX833X_PIO_INT_HI, pin); | ||
135 | CLEAR_REG_BIT(PNX833X_PIO_INT_LO, pin); | ||
136 | break; | ||
137 | case GPIO_INT_EDGE_FALLING: | ||
138 | SET_REG_BIT(PNX833X_PIO_INT_EDGE, pin); | ||
139 | CLEAR_REG_BIT(PNX833X_PIO_INT_HI, pin); | ||
140 | SET_REG_BIT(PNX833X_PIO_INT_LO, pin); | ||
141 | break; | ||
142 | case GPIO_INT_EDGE_BOTH: | ||
143 | SET_REG_BIT(PNX833X_PIO_INT_EDGE, pin); | ||
144 | SET_REG_BIT(PNX833X_PIO_INT_HI, pin); | ||
145 | SET_REG_BIT(PNX833X_PIO_INT_LO, pin); | ||
146 | break; | ||
147 | default: | ||
148 | CLEAR_REG_BIT(PNX833X_PIO_INT_EDGE, pin); | ||
149 | CLEAR_REG_BIT(PNX833X_PIO_INT_HI, pin); | ||
150 | CLEAR_REG_BIT(PNX833X_PIO_INT_LO, pin); | ||
151 | break; | ||
152 | } | ||
153 | } | ||
154 | |||
155 | /* Enable/disable GPIO interrupt */ | ||
156 | static inline void pnx833x_gpio_enable_irq(unsigned int pin) | ||
157 | { | ||
158 | SET_REG_BIT(PNX833X_PIO_INT_ENABLE, pin); | ||
159 | } | ||
160 | static inline void pnx833x_gpio_disable_irq(unsigned int pin) | ||
161 | { | ||
162 | CLEAR_REG_BIT(PNX833X_PIO_INT_ENABLE, pin); | ||
163 | } | ||
164 | |||
165 | /* Clear GPIO interrupt request */ | ||
166 | static inline void pnx833x_gpio_clear_irq(unsigned int pin) | ||
167 | { | ||
168 | SET_REG_BIT(PNX833X_PIO_INT_CLEAR, pin); | ||
169 | CLEAR_REG_BIT(PNX833X_PIO_INT_CLEAR, pin); | ||
170 | } | ||
171 | |||
172 | #endif | ||
diff --git a/arch/mips/include/asm/mach-pnx833x/irq-mapping.h b/arch/mips/include/asm/mach-pnx833x/irq-mapping.h new file mode 100644 index 000000000000..657f089b1724 --- /dev/null +++ b/arch/mips/include/asm/mach-pnx833x/irq-mapping.h | |||
@@ -0,0 +1,126 @@ | |||
1 | |||
2 | /* | ||
3 | * irq.h: IRQ mappings for PNX833X. | ||
4 | * | ||
5 | * Copyright 2008 NXP Semiconductors | ||
6 | * Chris Steel <chris.steel@nxp.com> | ||
7 | * Daniel Laird <daniel.j.laird@nxp.com> | ||
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 as published by | ||
11 | * the Free Software Foundation; either version 2 of the License, or | ||
12 | * (at your option) any later version. | ||
13 | * | ||
14 | * This program is distributed in the hope that it will be useful, | ||
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
17 | * GNU General Public License for more details. | ||
18 | * | ||
19 | * You should have received a copy of the GNU General Public License | ||
20 | * along with this program; if not, write to the Free Software | ||
21 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
22 | */ | ||
23 | |||
24 | #ifndef __ASM_MIPS_MACH_PNX833X_IRQ_MAPPING_H | ||
25 | #define __ASM_MIPS_MACH_PNX833X_IRQ_MAPPING_H | ||
26 | /* | ||
27 | * The "IRQ numbers" are completely virtual. | ||
28 | * | ||
29 | * In PNX8330/1, we have 48 interrupt lines, numbered from 1 to 48. | ||
30 | * Let's use numbers 1..48 for PIC interrupts, number 0 for timer interrupt, | ||
31 | * numbers 49..64 for (virtual) GPIO interrupts. | ||
32 | * | ||
33 | * In PNX8335, we have 57 interrupt lines, numbered from 1 to 57, | ||
34 | * connected to PIC, which uses core hardware interrupt 2, and also | ||
35 | * a timer interrupt through hardware interrupt 5. | ||
36 | * Let's use numbers 1..64 for PIC interrupts, number 0 for timer interrupt, | ||
37 | * numbers 65..80 for (virtual) GPIO interrupts. | ||
38 | * | ||
39 | */ | ||
40 | #include <irq.h> | ||
41 | |||
42 | #define PNX833X_TIMER_IRQ (MIPS_CPU_IRQ_BASE + 7) | ||
43 | |||
44 | /* Interrupts supported by PIC */ | ||
45 | #define PNX833X_PIC_I2C0_INT (PNX833X_PIC_IRQ_BASE + 1) | ||
46 | #define PNX833X_PIC_I2C1_INT (PNX833X_PIC_IRQ_BASE + 2) | ||
47 | #define PNX833X_PIC_UART0_INT (PNX833X_PIC_IRQ_BASE + 3) | ||
48 | #define PNX833X_PIC_UART1_INT (PNX833X_PIC_IRQ_BASE + 4) | ||
49 | #define PNX833X_PIC_TS_IN0_DV_INT (PNX833X_PIC_IRQ_BASE + 5) | ||
50 | #define PNX833X_PIC_TS_IN0_DMA_INT (PNX833X_PIC_IRQ_BASE + 6) | ||
51 | #define PNX833X_PIC_GPIO_INT (PNX833X_PIC_IRQ_BASE + 7) | ||
52 | #define PNX833X_PIC_AUDIO_DEC_INT (PNX833X_PIC_IRQ_BASE + 8) | ||
53 | #define PNX833X_PIC_VIDEO_DEC_INT (PNX833X_PIC_IRQ_BASE + 9) | ||
54 | #define PNX833X_PIC_CONFIG_INT (PNX833X_PIC_IRQ_BASE + 10) | ||
55 | #define PNX833X_PIC_AOI_INT (PNX833X_PIC_IRQ_BASE + 11) | ||
56 | #define PNX833X_PIC_SYNC_INT (PNX833X_PIC_IRQ_BASE + 12) | ||
57 | #define PNX8330_PIC_SPU_INT (PNX833X_PIC_IRQ_BASE + 13) | ||
58 | #define PNX8335_PIC_SATA_INT (PNX833X_PIC_IRQ_BASE + 13) | ||
59 | #define PNX833X_PIC_OSD_INT (PNX833X_PIC_IRQ_BASE + 14) | ||
60 | #define PNX833X_PIC_DISP1_INT (PNX833X_PIC_IRQ_BASE + 15) | ||
61 | #define PNX833X_PIC_DEINTERLACER_INT (PNX833X_PIC_IRQ_BASE + 16) | ||
62 | #define PNX833X_PIC_DISPLAY2_INT (PNX833X_PIC_IRQ_BASE + 17) | ||
63 | #define PNX833X_PIC_VC_INT (PNX833X_PIC_IRQ_BASE + 18) | ||
64 | #define PNX833X_PIC_SC_INT (PNX833X_PIC_IRQ_BASE + 19) | ||
65 | #define PNX833X_PIC_IDE_INT (PNX833X_PIC_IRQ_BASE + 20) | ||
66 | #define PNX833X_PIC_IDE_DMA_INT (PNX833X_PIC_IRQ_BASE + 21) | ||
67 | #define PNX833X_PIC_TS_IN1_DV_INT (PNX833X_PIC_IRQ_BASE + 22) | ||
68 | #define PNX833X_PIC_TS_IN1_DMA_INT (PNX833X_PIC_IRQ_BASE + 23) | ||
69 | #define PNX833X_PIC_SGDX_DMA_INT (PNX833X_PIC_IRQ_BASE + 24) | ||
70 | #define PNX833X_PIC_TS_OUT_INT (PNX833X_PIC_IRQ_BASE + 25) | ||
71 | #define PNX833X_PIC_IR_INT (PNX833X_PIC_IRQ_BASE + 26) | ||
72 | #define PNX833X_PIC_VMSP1_INT (PNX833X_PIC_IRQ_BASE + 27) | ||
73 | #define PNX833X_PIC_VMSP2_INT (PNX833X_PIC_IRQ_BASE + 28) | ||
74 | #define PNX833X_PIC_PIBC_INT (PNX833X_PIC_IRQ_BASE + 29) | ||
75 | #define PNX833X_PIC_TS_IN0_TRD_INT (PNX833X_PIC_IRQ_BASE + 30) | ||
76 | #define PNX833X_PIC_SGDX_TPD_INT (PNX833X_PIC_IRQ_BASE + 31) | ||
77 | #define PNX833X_PIC_USB_INT (PNX833X_PIC_IRQ_BASE + 32) | ||
78 | #define PNX833X_PIC_TS_IN1_TRD_INT (PNX833X_PIC_IRQ_BASE + 33) | ||
79 | #define PNX833X_PIC_CLOCK_INT (PNX833X_PIC_IRQ_BASE + 34) | ||
80 | #define PNX833X_PIC_SGDX_PARSER_INT (PNX833X_PIC_IRQ_BASE + 35) | ||
81 | #define PNX833X_PIC_VMSP_DMA_INT (PNX833X_PIC_IRQ_BASE + 36) | ||
82 | |||
83 | #if defined(CONFIG_SOC_PNX8335) | ||
84 | #define PNX8335_PIC_MIU_INT (PNX833X_PIC_IRQ_BASE + 37) | ||
85 | #define PNX8335_PIC_AVCHIP_IRQ_INT (PNX833X_PIC_IRQ_BASE + 38) | ||
86 | #define PNX8335_PIC_SYNC_HD_INT (PNX833X_PIC_IRQ_BASE + 39) | ||
87 | #define PNX8335_PIC_DISP_HD_INT (PNX833X_PIC_IRQ_BASE + 40) | ||
88 | #define PNX8335_PIC_DISP_SCALER_INT (PNX833X_PIC_IRQ_BASE + 41) | ||
89 | #define PNX8335_PIC_OSD_HD1_INT (PNX833X_PIC_IRQ_BASE + 42) | ||
90 | #define PNX8335_PIC_DTL_WRITER_Y_INT (PNX833X_PIC_IRQ_BASE + 43) | ||
91 | #define PNX8335_PIC_DTL_WRITER_C_INT (PNX833X_PIC_IRQ_BASE + 44) | ||
92 | #define PNX8335_PIC_DTL_EMULATOR_Y_IR_INT (PNX833X_PIC_IRQ_BASE + 45) | ||
93 | #define PNX8335_PIC_DTL_EMULATOR_C_IR_INT (PNX833X_PIC_IRQ_BASE + 46) | ||
94 | #define PNX8335_PIC_DENC_TTX_INT (PNX833X_PIC_IRQ_BASE + 47) | ||
95 | #define PNX8335_PIC_MMI_SIF0_INT (PNX833X_PIC_IRQ_BASE + 48) | ||
96 | #define PNX8335_PIC_MMI_SIF1_INT (PNX833X_PIC_IRQ_BASE + 49) | ||
97 | #define PNX8335_PIC_MMI_CDMMU_INT (PNX833X_PIC_IRQ_BASE + 50) | ||
98 | #define PNX8335_PIC_PIBCS_INT (PNX833X_PIC_IRQ_BASE + 51) | ||
99 | #define PNX8335_PIC_ETHERNET_INT (PNX833X_PIC_IRQ_BASE + 52) | ||
100 | #define PNX8335_PIC_VMSP1_0_INT (PNX833X_PIC_IRQ_BASE + 53) | ||
101 | #define PNX8335_PIC_VMSP1_1_INT (PNX833X_PIC_IRQ_BASE + 54) | ||
102 | #define PNX8335_PIC_VMSP1_DMA_INT (PNX833X_PIC_IRQ_BASE + 55) | ||
103 | #define PNX8335_PIC_TDGR_DE_INT (PNX833X_PIC_IRQ_BASE + 56) | ||
104 | #define PNX8335_PIC_IR1_IRQ_INT (PNX833X_PIC_IRQ_BASE + 57) | ||
105 | #endif | ||
106 | |||
107 | /* GPIO interrupts */ | ||
108 | #define PNX833X_GPIO_0_INT (PNX833X_GPIO_IRQ_BASE + 0) | ||
109 | #define PNX833X_GPIO_1_INT (PNX833X_GPIO_IRQ_BASE + 1) | ||
110 | #define PNX833X_GPIO_2_INT (PNX833X_GPIO_IRQ_BASE + 2) | ||
111 | #define PNX833X_GPIO_3_INT (PNX833X_GPIO_IRQ_BASE + 3) | ||
112 | #define PNX833X_GPIO_4_INT (PNX833X_GPIO_IRQ_BASE + 4) | ||
113 | #define PNX833X_GPIO_5_INT (PNX833X_GPIO_IRQ_BASE + 5) | ||
114 | #define PNX833X_GPIO_6_INT (PNX833X_GPIO_IRQ_BASE + 6) | ||
115 | #define PNX833X_GPIO_7_INT (PNX833X_GPIO_IRQ_BASE + 7) | ||
116 | #define PNX833X_GPIO_8_INT (PNX833X_GPIO_IRQ_BASE + 8) | ||
117 | #define PNX833X_GPIO_9_INT (PNX833X_GPIO_IRQ_BASE + 9) | ||
118 | #define PNX833X_GPIO_10_INT (PNX833X_GPIO_IRQ_BASE + 10) | ||
119 | #define PNX833X_GPIO_11_INT (PNX833X_GPIO_IRQ_BASE + 11) | ||
120 | #define PNX833X_GPIO_12_INT (PNX833X_GPIO_IRQ_BASE + 12) | ||
121 | #define PNX833X_GPIO_13_INT (PNX833X_GPIO_IRQ_BASE + 13) | ||
122 | #define PNX833X_GPIO_14_INT (PNX833X_GPIO_IRQ_BASE + 14) | ||
123 | #define PNX833X_GPIO_15_INT (PNX833X_GPIO_IRQ_BASE + 15) | ||
124 | |||
125 | #endif | ||
126 | |||
diff --git a/arch/mips/include/asm/mach-pnx833x/irq.h b/arch/mips/include/asm/mach-pnx833x/irq.h new file mode 100644 index 000000000000..745114b1d8d5 --- /dev/null +++ b/arch/mips/include/asm/mach-pnx833x/irq.h | |||
@@ -0,0 +1,53 @@ | |||
1 | /* | ||
2 | * irq.h: IRQ mappings for PNX833X. | ||
3 | * | ||
4 | * Copyright 2008 NXP Semiconductors | ||
5 | * Chris Steel <chris.steel@nxp.com> | ||
6 | * Daniel Laird <daniel.j.laird@nxp.com> | ||
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. | ||
12 | * | ||
13 | * This program is distributed in the hope that it will be useful, | ||
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
16 | * GNU General Public License for more details. | ||
17 | * | ||
18 | * You should have received a copy of the GNU General Public License | ||
19 | * along with this program; if not, write to the Free Software | ||
20 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
21 | */ | ||
22 | |||
23 | #ifndef __ASM_MIPS_MACH_PNX833X_IRQ_H | ||
24 | #define __ASM_MIPS_MACH_PNX833X_IRQ_H | ||
25 | /* | ||
26 | * The "IRQ numbers" are completely virtual. | ||
27 | * | ||
28 | * In PNX8330/1, we have 48 interrupt lines, numbered from 1 to 48. | ||
29 | * Let's use numbers 1..48 for PIC interrupts, number 0 for timer interrupt, | ||
30 | * numbers 49..64 for (virtual) GPIO interrupts. | ||
31 | * | ||
32 | * In PNX8335, we have 57 interrupt lines, numbered from 1 to 57, | ||
33 | * connected to PIC, which uses core hardware interrupt 2, and also | ||
34 | * a timer interrupt through hardware interrupt 5. | ||
35 | * Let's use numbers 1..64 for PIC interrupts, number 0 for timer interrupt, | ||
36 | * numbers 65..80 for (virtual) GPIO interrupts. | ||
37 | * | ||
38 | */ | ||
39 | #if defined(CONFIG_SOC_PNX8335) | ||
40 | #define PNX833X_PIC_NUM_IRQ 58 | ||
41 | #else | ||
42 | #define PNX833X_PIC_NUM_IRQ 37 | ||
43 | #endif | ||
44 | |||
45 | #define MIPS_CPU_NUM_IRQ 8 | ||
46 | #define PNX833X_GPIO_NUM_IRQ 16 | ||
47 | |||
48 | #define MIPS_CPU_IRQ_BASE 0 | ||
49 | #define PNX833X_PIC_IRQ_BASE (MIPS_CPU_IRQ_BASE + MIPS_CPU_NUM_IRQ) | ||
50 | #define PNX833X_GPIO_IRQ_BASE (PNX833X_PIC_IRQ_BASE + PNX833X_PIC_NUM_IRQ) | ||
51 | #define NR_IRQS (MIPS_CPU_NUM_IRQ + PNX833X_PIC_NUM_IRQ + PNX833X_GPIO_NUM_IRQ) | ||
52 | |||
53 | #endif | ||
diff --git a/arch/mips/include/asm/mach-pnx833x/pnx833x.h b/arch/mips/include/asm/mach-pnx833x/pnx833x.h new file mode 100644 index 000000000000..100f52870e3c --- /dev/null +++ b/arch/mips/include/asm/mach-pnx833x/pnx833x.h | |||
@@ -0,0 +1,202 @@ | |||
1 | /* | ||
2 | * pnx833x.h: Register mappings for PNX833X. | ||
3 | * | ||
4 | * Copyright 2008 NXP Semiconductors | ||
5 | * Chris Steel <chris.steel@nxp.com> | ||
6 | * Daniel Laird <daniel.j.laird@nxp.com> | ||
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. | ||
12 | * | ||
13 | * This program is distributed in the hope that it will be useful, | ||
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
16 | * GNU General Public License for more details. | ||
17 | * | ||
18 | * You should have received a copy of the GNU General Public License | ||
19 | * along with this program; if not, write to the Free Software | ||
20 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
21 | */ | ||
22 | #ifndef __ASM_MIPS_MACH_PNX833X_PNX833X_H | ||
23 | #define __ASM_MIPS_MACH_PNX833X_PNX833X_H | ||
24 | |||
25 | /* All regs are accessed in KSEG1 */ | ||
26 | #define PNX833X_BASE (0xa0000000ul + 0x17E00000ul) | ||
27 | |||
28 | #define PNX833X_REG(offs) (*((volatile unsigned long *)(PNX833X_BASE + offs))) | ||
29 | |||
30 | /* Registers are named exactly as in PNX833X docs, just with PNX833X_ prefix */ | ||
31 | |||
32 | /* Read access to multibit fields */ | ||
33 | #define PNX833X_BIT(val, reg, field) ((val) & PNX833X_##reg##_##field) | ||
34 | #define PNX833X_REGBIT(reg, field) PNX833X_BIT(PNX833X_##reg, reg, field) | ||
35 | |||
36 | /* Use PNX833X_FIELD to extract a field from val */ | ||
37 | #define PNX_FIELD(cpu, val, reg, field) \ | ||
38 | (((val) & PNX##cpu##_##reg##_##field##_MASK) >> \ | ||
39 | PNX##cpu##_##reg##_##field##_SHIFT) | ||
40 | #define PNX833X_FIELD(val, reg, field) PNX_FIELD(833X, val, reg, field) | ||
41 | #define PNX8330_FIELD(val, reg, field) PNX_FIELD(8330, val, reg, field) | ||
42 | #define PNX8335_FIELD(val, reg, field) PNX_FIELD(8335, val, reg, field) | ||
43 | |||
44 | /* Use PNX833X_REGFIELD to extract a field from a register */ | ||
45 | #define PNX833X_REGFIELD(reg, field) PNX833X_FIELD(PNX833X_##reg, reg, field) | ||
46 | #define PNX8330_REGFIELD(reg, field) PNX8330_FIELD(PNX8330_##reg, reg, field) | ||
47 | #define PNX8335_REGFIELD(reg, field) PNX8335_FIELD(PNX8335_##reg, reg, field) | ||
48 | |||
49 | |||
50 | #define PNX_WRITEFIELD(cpu, val, reg, field) \ | ||
51 | (PNX##cpu##_##reg = (PNX##cpu##_##reg & ~(PNX##cpu##_##reg##_##field##_MASK)) | \ | ||
52 | ((val) << PNX##cpu##_##reg##_##field##_SHIFT)) | ||
53 | #define PNX833X_WRITEFIELD(val, reg, field) \ | ||
54 | PNX_WRITEFIELD(833X, val, reg, field) | ||
55 | #define PNX8330_WRITEFIELD(val, reg, field) \ | ||
56 | PNX_WRITEFIELD(8330, val, reg, field) | ||
57 | #define PNX8335_WRITEFIELD(val, reg, field) \ | ||
58 | PNX_WRITEFIELD(8335, val, reg, field) | ||
59 | |||
60 | |||
61 | /* Macros to detect CPU type */ | ||
62 | |||
63 | #define PNX833X_CONFIG_MODULE_ID PNX833X_REG(0x7FFC) | ||
64 | #define PNX833X_CONFIG_MODULE_ID_MAJREV_MASK 0x0000f000 | ||
65 | #define PNX833X_CONFIG_MODULE_ID_MAJREV_SHIFT 12 | ||
66 | #define PNX8330_CONFIG_MODULE_MAJREV 4 | ||
67 | #define PNX8335_CONFIG_MODULE_MAJREV 5 | ||
68 | #define CPU_IS_PNX8330 (PNX833X_REGFIELD(CONFIG_MODULE_ID, MAJREV) == \ | ||
69 | PNX8330_CONFIG_MODULE_MAJREV) | ||
70 | #define CPU_IS_PNX8335 (PNX833X_REGFIELD(CONFIG_MODULE_ID, MAJREV) == \ | ||
71 | PNX8335_CONFIG_MODULE_MAJREV) | ||
72 | |||
73 | |||
74 | |||
75 | #define PNX833X_RESET_CONTROL PNX833X_REG(0x8004) | ||
76 | #define PNX833X_RESET_CONTROL_2 PNX833X_REG(0x8014) | ||
77 | |||
78 | #define PNX833X_PIC_REG(offs) PNX833X_REG(0x01000 + (offs)) | ||
79 | #define PNX833X_PIC_INT_PRIORITY PNX833X_PIC_REG(0x0) | ||
80 | #define PNX833X_PIC_INT_SRC PNX833X_PIC_REG(0x4) | ||
81 | #define PNX833X_PIC_INT_SRC_INT_SRC_MASK 0x00000FF8ul /* bits 11:3 */ | ||
82 | #define PNX833X_PIC_INT_SRC_INT_SRC_SHIFT 3 | ||
83 | #define PNX833X_PIC_INT_REG(irq) PNX833X_PIC_REG(0x10 + 4*(irq)) | ||
84 | |||
85 | #define PNX833X_CLOCK_CPUCP_CTL PNX833X_REG(0x9228) | ||
86 | #define PNX833X_CLOCK_CPUCP_CTL_EXIT_RESET 0x00000002ul /* bit 1 */ | ||
87 | #define PNX833X_CLOCK_CPUCP_CTL_DIV_CLOCK_MASK 0x00000018ul /* bits 4:3 */ | ||
88 | #define PNX833X_CLOCK_CPUCP_CTL_DIV_CLOCK_SHIFT 3 | ||
89 | |||
90 | #define PNX8335_CLOCK_PLL_CPU_CTL PNX833X_REG(0x9020) | ||
91 | #define PNX8335_CLOCK_PLL_CPU_CTL_FREQ_MASK 0x1f | ||
92 | #define PNX8335_CLOCK_PLL_CPU_CTL_FREQ_SHIFT 0 | ||
93 | |||
94 | #define PNX833X_CONFIG_MUX PNX833X_REG(0x7004) | ||
95 | #define PNX833X_CONFIG_MUX_IDE_MUX 0x00000080 /* bit 7 */ | ||
96 | |||
97 | #define PNX8330_CONFIG_POLYFUSE_7 PNX833X_REG(0x7040) | ||
98 | #define PNX8330_CONFIG_POLYFUSE_7_BOOT_MODE_MASK 0x00180000 | ||
99 | #define PNX8330_CONFIG_POLYFUSE_7_BOOT_MODE_SHIFT 19 | ||
100 | |||
101 | #define PNX833X_PIO_IN PNX833X_REG(0xF000) | ||
102 | #define PNX833X_PIO_OUT PNX833X_REG(0xF004) | ||
103 | #define PNX833X_PIO_DIR PNX833X_REG(0xF008) | ||
104 | #define PNX833X_PIO_SEL PNX833X_REG(0xF014) | ||
105 | #define PNX833X_PIO_INT_EDGE PNX833X_REG(0xF020) | ||
106 | #define PNX833X_PIO_INT_HI PNX833X_REG(0xF024) | ||
107 | #define PNX833X_PIO_INT_LO PNX833X_REG(0xF028) | ||
108 | #define PNX833X_PIO_INT_STATUS PNX833X_REG(0xFFE0) | ||
109 | #define PNX833X_PIO_INT_ENABLE PNX833X_REG(0xFFE4) | ||
110 | #define PNX833X_PIO_INT_CLEAR PNX833X_REG(0xFFE8) | ||
111 | #define PNX833X_PIO_IN2 PNX833X_REG(0xF05C) | ||
112 | #define PNX833X_PIO_OUT2 PNX833X_REG(0xF060) | ||
113 | #define PNX833X_PIO_DIR2 PNX833X_REG(0xF064) | ||
114 | #define PNX833X_PIO_SEL2 PNX833X_REG(0xF068) | ||
115 | |||
116 | #define PNX833X_UART0_PORTS_START (PNX833X_BASE + 0xB000) | ||
117 | #define PNX833X_UART0_PORTS_END (PNX833X_BASE + 0xBFFF) | ||
118 | #define PNX833X_UART1_PORTS_START (PNX833X_BASE + 0xC000) | ||
119 | #define PNX833X_UART1_PORTS_END (PNX833X_BASE + 0xCFFF) | ||
120 | |||
121 | #define PNX833X_USB_PORTS_START (PNX833X_BASE + 0x19000) | ||
122 | #define PNX833X_USB_PORTS_END (PNX833X_BASE + 0x19FFF) | ||
123 | |||
124 | #define PNX833X_CONFIG_USB PNX833X_REG(0x7008) | ||
125 | |||
126 | #define PNX833X_I2C0_PORTS_START (PNX833X_BASE + 0xD000) | ||
127 | #define PNX833X_I2C0_PORTS_END (PNX833X_BASE + 0xDFFF) | ||
128 | #define PNX833X_I2C1_PORTS_START (PNX833X_BASE + 0xE000) | ||
129 | #define PNX833X_I2C1_PORTS_END (PNX833X_BASE + 0xEFFF) | ||
130 | |||
131 | #define PNX833X_IDE_PORTS_START (PNX833X_BASE + 0x1A000) | ||
132 | #define PNX833X_IDE_PORTS_END (PNX833X_BASE + 0x1AFFF) | ||
133 | #define PNX833X_IDE_MODULE_ID PNX833X_REG(0x1AFFC) | ||
134 | |||
135 | #define PNX833X_IDE_MODULE_ID_MODULE_ID_MASK 0xFFFF0000 | ||
136 | #define PNX833X_IDE_MODULE_ID_MODULE_ID_SHIFT 16 | ||
137 | #define PNX833X_IDE_MODULE_ID_VALUE 0xA009 | ||
138 | |||
139 | |||
140 | #define PNX833X_MIU_SEL0 PNX833X_REG(0x2004) | ||
141 | #define PNX833X_MIU_SEL0_TIMING PNX833X_REG(0x2008) | ||
142 | #define PNX833X_MIU_SEL1 PNX833X_REG(0x200C) | ||
143 | #define PNX833X_MIU_SEL1_TIMING PNX833X_REG(0x2010) | ||
144 | #define PNX833X_MIU_SEL2 PNX833X_REG(0x2014) | ||
145 | #define PNX833X_MIU_SEL2_TIMING PNX833X_REG(0x2018) | ||
146 | #define PNX833X_MIU_SEL3 PNX833X_REG(0x201C) | ||
147 | #define PNX833X_MIU_SEL3_TIMING PNX833X_REG(0x2020) | ||
148 | |||
149 | #define PNX833X_MIU_SEL0_SPI_MODE_ENABLE_MASK (1 << 14) | ||
150 | #define PNX833X_MIU_SEL0_SPI_MODE_ENABLE_SHIFT 14 | ||
151 | |||
152 | #define PNX833X_MIU_SEL0_BURST_MODE_ENABLE_MASK (1 << 7) | ||
153 | #define PNX833X_MIU_SEL0_BURST_MODE_ENABLE_SHIFT 7 | ||
154 | |||
155 | #define PNX833X_MIU_SEL0_BURST_PAGE_LEN_MASK (0xF << 9) | ||
156 | #define PNX833X_MIU_SEL0_BURST_PAGE_LEN_SHIFT 9 | ||
157 | |||
158 | #define PNX833X_MIU_CONFIG_SPI PNX833X_REG(0x2000) | ||
159 | |||
160 | #define PNX833X_MIU_CONFIG_SPI_OPCODE_MASK (0xFF << 3) | ||
161 | #define PNX833X_MIU_CONFIG_SPI_OPCODE_SHIFT 3 | ||
162 | |||
163 | #define PNX833X_MIU_CONFIG_SPI_DATA_ENABLE_MASK (1 << 2) | ||
164 | #define PNX833X_MIU_CONFIG_SPI_DATA_ENABLE_SHIFT 2 | ||
165 | |||
166 | #define PNX833X_MIU_CONFIG_SPI_ADDR_ENABLE_MASK (1 << 1) | ||
167 | #define PNX833X_MIU_CONFIG_SPI_ADDR_ENABLE_SHIFT 1 | ||
168 | |||
169 | #define PNX833X_MIU_CONFIG_SPI_SYNC_MASK (1 << 0) | ||
170 | #define PNX833X_MIU_CONFIG_SPI_SYNC_SHIFT 0 | ||
171 | |||
172 | #define PNX833X_WRITE_CONFIG_SPI(opcode, data_enable, addr_enable, sync) \ | ||
173 | (PNX833X_MIU_CONFIG_SPI = \ | ||
174 | ((opcode) << PNX833X_MIU_CONFIG_SPI_OPCODE_SHIFT) | \ | ||
175 | ((data_enable) << PNX833X_MIU_CONFIG_SPI_DATA_ENABLE_SHIFT) | \ | ||
176 | ((addr_enable) << PNX833X_MIU_CONFIG_SPI_ADDR_ENABLE_SHIFT) | \ | ||
177 | ((sync) << PNX833X_MIU_CONFIG_SPI_SYNC_SHIFT)) | ||
178 | |||
179 | #define PNX8335_IP3902_PORTS_START (PNX833X_BASE + 0x2F000) | ||
180 | #define PNX8335_IP3902_PORTS_END (PNX833X_BASE + 0x2FFFF) | ||
181 | #define PNX8335_IP3902_MODULE_ID PNX833X_REG(0x2FFFC) | ||
182 | |||
183 | #define PNX8335_IP3902_MODULE_ID_MODULE_ID_MASK 0xFFFF0000 | ||
184 | #define PNX8335_IP3902_MODULE_ID_MODULE_ID_SHIFT 16 | ||
185 | #define PNX8335_IP3902_MODULE_ID_VALUE 0x3902 | ||
186 | |||
187 | /* I/O location(gets remapped)*/ | ||
188 | #define PNX8335_NAND_BASE 0x18000000 | ||
189 | /* I/O location with CLE high */ | ||
190 | #define PNX8335_NAND_CLE_MASK 0x00100000 | ||
191 | /* I/O location with ALE high */ | ||
192 | #define PNX8335_NAND_ALE_MASK 0x00010000 | ||
193 | |||
194 | #define PNX8335_SATA_PORTS_START (PNX833X_BASE + 0x2E000) | ||
195 | #define PNX8335_SATA_PORTS_END (PNX833X_BASE + 0x2EFFF) | ||
196 | #define PNX8335_SATA_MODULE_ID PNX833X_REG(0x2EFFC) | ||
197 | |||
198 | #define PNX8335_SATA_MODULE_ID_MODULE_ID_MASK 0xFFFF0000 | ||
199 | #define PNX8335_SATA_MODULE_ID_MODULE_ID_SHIFT 16 | ||
200 | #define PNX8335_SATA_MODULE_ID_VALUE 0xA099 | ||
201 | |||
202 | #endif | ||
diff --git a/arch/mips/include/asm/mach-pnx833x/war.h b/arch/mips/include/asm/mach-pnx833x/war.h new file mode 100644 index 000000000000..82cd1e97bc2e --- /dev/null +++ b/arch/mips/include/asm/mach-pnx833x/war.h | |||
@@ -0,0 +1,25 @@ | |||
1 | /* | ||
2 | * This file is subject to the terms and conditions of the GNU General Public | ||
3 | * License. See the file "COPYING" in the main directory of this archive | ||
4 | * for more details. | ||
5 | * | ||
6 | * Copyright (C) 2002, 2004, 2007 by Ralf Baechle <ralf@linux-mips.org> | ||
7 | */ | ||
8 | #ifndef __ASM_MIPS_MACH_PNX833X_WAR_H | ||
9 | #define __ASM_MIPS_MACH_PNX833X_WAR_H | ||
10 | |||
11 | #define R4600_V1_INDEX_ICACHEOP_WAR 0 | ||
12 | #define R4600_V1_HIT_CACHEOP_WAR 0 | ||
13 | #define R4600_V2_HIT_CACHEOP_WAR 0 | ||
14 | #define R5432_CP0_INTERRUPT_WAR 0 | ||
15 | #define BCM1250_M3_WAR 0 | ||
16 | #define SIBYTE_1956_WAR 0 | ||
17 | #define MIPS4K_ICACHE_REFILL_WAR 0 | ||
18 | #define MIPS_CACHE_SYNC_WAR 0 | ||
19 | #define TX49XX_ICACHE_INDEX_INV_WAR 0 | ||
20 | #define RM9000_CDEX_SMP_WAR 0 | ||
21 | #define ICACHE_REFILLS_WORKAROUND_WAR 0 | ||
22 | #define R10000_LLSC_WAR 0 | ||
23 | #define MIPS34K_MISSED_ITLB_WAR 0 | ||
24 | |||
25 | #endif /* __ASM_MIPS_MACH_PNX8550_WAR_H */ | ||
diff --git a/arch/mips/include/asm/mach-tx49xx/mangle-port.h b/arch/mips/include/asm/mach-tx49xx/mangle-port.h new file mode 100644 index 000000000000..5e6912fdd0ed --- /dev/null +++ b/arch/mips/include/asm/mach-tx49xx/mangle-port.h | |||
@@ -0,0 +1,26 @@ | |||
1 | #ifndef __ASM_MACH_TX49XX_MANGLE_PORT_H | ||
2 | #define __ASM_MACH_TX49XX_MANGLE_PORT_H | ||
3 | |||
4 | #define __swizzle_addr_b(port) (port) | ||
5 | #define __swizzle_addr_w(port) (port) | ||
6 | #define __swizzle_addr_l(port) (port) | ||
7 | #define __swizzle_addr_q(port) (port) | ||
8 | |||
9 | #define ioswabb(a, x) (x) | ||
10 | #define __mem_ioswabb(a, x) (x) | ||
11 | #if defined(CONFIG_TOSHIBA_RBTX4939) && \ | ||
12 | (defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE)) && \ | ||
13 | defined(__BIG_ENDIAN) | ||
14 | #define NEEDS_TXX9_IOSWABW | ||
15 | extern u16 (*ioswabw)(volatile u16 *a, u16 x); | ||
16 | extern u16 (*__mem_ioswabw)(volatile u16 *a, u16 x); | ||
17 | #else | ||
18 | #define ioswabw(a, x) le16_to_cpu(x) | ||
19 | #define __mem_ioswabw(a, x) (x) | ||
20 | #endif | ||
21 | #define ioswabl(a, x) le32_to_cpu(x) | ||
22 | #define __mem_ioswabl(a, x) (x) | ||
23 | #define ioswabq(a, x) le64_to_cpu(x) | ||
24 | #define __mem_ioswabq(a, x) (x) | ||
25 | |||
26 | #endif /* __ASM_MACH_TX49XX_MANGLE_PORT_H */ | ||
diff --git a/arch/mips/include/asm/mipsregs.h b/arch/mips/include/asm/mipsregs.h index 979866000da4..9316324d070d 100644 --- a/arch/mips/include/asm/mipsregs.h +++ b/arch/mips/include/asm/mipsregs.h | |||
@@ -192,6 +192,7 @@ | |||
192 | #define PM_16M 0x01ffe000 | 192 | #define PM_16M 0x01ffe000 |
193 | #define PM_64M 0x07ffe000 | 193 | #define PM_64M 0x07ffe000 |
194 | #define PM_256M 0x1fffe000 | 194 | #define PM_256M 0x1fffe000 |
195 | #define PM_1G 0x7fffe000 | ||
195 | 196 | ||
196 | #endif | 197 | #endif |
197 | 198 | ||
diff --git a/arch/mips/include/asm/module.h b/arch/mips/include/asm/module.h index de6d09ebbd80..e2e09b2cd265 100644 --- a/arch/mips/include/asm/module.h +++ b/arch/mips/include/asm/module.h | |||
@@ -98,6 +98,8 @@ search_module_dbetables(unsigned long addr) | |||
98 | #define MODULE_PROC_FAMILY "R5000 " | 98 | #define MODULE_PROC_FAMILY "R5000 " |
99 | #elif defined CONFIG_CPU_R5432 | 99 | #elif defined CONFIG_CPU_R5432 |
100 | #define MODULE_PROC_FAMILY "R5432 " | 100 | #define MODULE_PROC_FAMILY "R5432 " |
101 | #elif defined CONFIG_CPU_R5500 | ||
102 | #define MODULE_PROC_FAMILY "R5500 " | ||
101 | #elif defined CONFIG_CPU_R6000 | 103 | #elif defined CONFIG_CPU_R6000 |
102 | #define MODULE_PROC_FAMILY "R6000 " | 104 | #define MODULE_PROC_FAMILY "R6000 " |
103 | #elif defined CONFIG_CPU_NEVADA | 105 | #elif defined CONFIG_CPU_NEVADA |
diff --git a/arch/mips/include/asm/ptrace.h b/arch/mips/include/asm/ptrace.h index 9c22571b160d..813abd16255d 100644 --- a/arch/mips/include/asm/ptrace.h +++ b/arch/mips/include/asm/ptrace.h | |||
@@ -80,25 +80,25 @@ enum pt_watch_style { | |||
80 | pt_watch_style_mips64 | 80 | pt_watch_style_mips64 |
81 | }; | 81 | }; |
82 | struct mips32_watch_regs { | 82 | struct mips32_watch_regs { |
83 | uint32_t watchlo[8]; | 83 | unsigned int watchlo[8]; |
84 | /* Lower 16 bits of watchhi. */ | 84 | /* Lower 16 bits of watchhi. */ |
85 | uint16_t watchhi[8]; | 85 | unsigned short watchhi[8]; |
86 | /* Valid mask and I R W bits. | 86 | /* Valid mask and I R W bits. |
87 | * bit 0 -- 1 if W bit is usable. | 87 | * bit 0 -- 1 if W bit is usable. |
88 | * bit 1 -- 1 if R bit is usable. | 88 | * bit 1 -- 1 if R bit is usable. |
89 | * bit 2 -- 1 if I bit is usable. | 89 | * bit 2 -- 1 if I bit is usable. |
90 | * bits 3 - 11 -- Valid watchhi mask bits. | 90 | * bits 3 - 11 -- Valid watchhi mask bits. |
91 | */ | 91 | */ |
92 | uint16_t watch_masks[8]; | 92 | unsigned short watch_masks[8]; |
93 | /* The number of valid watch register pairs. */ | 93 | /* The number of valid watch register pairs. */ |
94 | uint32_t num_valid; | 94 | unsigned int num_valid; |
95 | } __attribute__((aligned(8))); | 95 | } __attribute__((aligned(8))); |
96 | 96 | ||
97 | struct mips64_watch_regs { | 97 | struct mips64_watch_regs { |
98 | uint64_t watchlo[8]; | 98 | unsigned long long watchlo[8]; |
99 | uint16_t watchhi[8]; | 99 | unsigned short watchhi[8]; |
100 | uint16_t watch_masks[8]; | 100 | unsigned short watch_masks[8]; |
101 | uint32_t num_valid; | 101 | unsigned int num_valid; |
102 | } __attribute__((aligned(8))); | 102 | } __attribute__((aligned(8))); |
103 | 103 | ||
104 | struct pt_watch_regs { | 104 | struct pt_watch_regs { |
@@ -116,6 +116,7 @@ struct pt_watch_regs { | |||
116 | 116 | ||
117 | #include <linux/compiler.h> | 117 | #include <linux/compiler.h> |
118 | #include <linux/linkage.h> | 118 | #include <linux/linkage.h> |
119 | #include <linux/types.h> | ||
119 | #include <asm/isadep.h> | 120 | #include <asm/isadep.h> |
120 | 121 | ||
121 | struct task_struct; | 122 | struct task_struct; |
diff --git a/arch/mips/include/asm/txx9/generic.h b/arch/mips/include/asm/txx9/generic.h index 4316a3e57678..9cde0090cbf6 100644 --- a/arch/mips/include/asm/txx9/generic.h +++ b/arch/mips/include/asm/txx9/generic.h | |||
@@ -86,4 +86,9 @@ void txx9_iocled_init(unsigned long baseaddr, | |||
86 | int basenum, unsigned int num, int lowactive, | 86 | int basenum, unsigned int num, int lowactive, |
87 | const char *color, char **deftriggers); | 87 | const char *color, char **deftriggers); |
88 | 88 | ||
89 | /* 7SEG LED */ | ||
90 | void txx9_7segled_init(unsigned int num, | ||
91 | void (*putc)(unsigned int pos, unsigned char val)); | ||
92 | int txx9_7segled_putc(unsigned int pos, char c); | ||
93 | |||
89 | #endif /* __ASM_TXX9_GENERIC_H */ | 94 | #endif /* __ASM_TXX9_GENERIC_H */ |
diff --git a/arch/mips/include/asm/txx9/tx4938.h b/arch/mips/include/asm/txx9/tx4938.h index 989e7751135a..0b068154054c 100644 --- a/arch/mips/include/asm/txx9/tx4938.h +++ b/arch/mips/include/asm/txx9/tx4938.h | |||
@@ -292,4 +292,17 @@ void tx4938_setup_pcierr_irq(void); | |||
292 | void tx4938_irq_init(void); | 292 | void tx4938_irq_init(void); |
293 | void tx4938_mtd_init(int ch); | 293 | void tx4938_mtd_init(int ch); |
294 | 294 | ||
295 | struct tx4938ide_platform_info { | ||
296 | /* | ||
297 | * I/O port shift, for platforms with ports that are | ||
298 | * constantly spaced and need larger than the 1-byte | ||
299 | * spacing used by ata_std_ports(). | ||
300 | */ | ||
301 | unsigned int ioport_shift; | ||
302 | unsigned int gbus_clock; /* 0 means no PIO mode tuning. */ | ||
303 | unsigned int ebus_ch; | ||
304 | }; | ||
305 | |||
306 | void tx4938_ata_init(unsigned int irq, unsigned int shift, int tune); | ||
307 | |||
295 | #endif | 308 | #endif |
diff --git a/arch/mips/kernel/Makefile b/arch/mips/kernel/Makefile index d9da7112aaf8..b1372c27f136 100644 --- a/arch/mips/kernel/Makefile +++ b/arch/mips/kernel/Makefile | |||
@@ -33,6 +33,7 @@ obj-$(CONFIG_CPU_R4X00) += r4k_fpu.o r4k_switch.o | |||
33 | obj-$(CONFIG_CPU_R5000) += r4k_fpu.o r4k_switch.o | 33 | obj-$(CONFIG_CPU_R5000) += r4k_fpu.o r4k_switch.o |
34 | obj-$(CONFIG_CPU_R6000) += r6000_fpu.o r4k_switch.o | 34 | obj-$(CONFIG_CPU_R6000) += r6000_fpu.o r4k_switch.o |
35 | obj-$(CONFIG_CPU_R5432) += r4k_fpu.o r4k_switch.o | 35 | obj-$(CONFIG_CPU_R5432) += r4k_fpu.o r4k_switch.o |
36 | obj-$(CONFIG_CPU_R5500) += r4k_fpu.o r4k_switch.o | ||
36 | obj-$(CONFIG_CPU_R8000) += r4k_fpu.o r4k_switch.o | 37 | obj-$(CONFIG_CPU_R8000) += r4k_fpu.o r4k_switch.o |
37 | obj-$(CONFIG_CPU_RM7000) += r4k_fpu.o r4k_switch.o | 38 | obj-$(CONFIG_CPU_RM7000) += r4k_fpu.o r4k_switch.o |
38 | obj-$(CONFIG_CPU_RM9000) += r4k_fpu.o r4k_switch.o | 39 | obj-$(CONFIG_CPU_RM9000) += r4k_fpu.o r4k_switch.o |
diff --git a/arch/mips/kernel/scall32-o32.S b/arch/mips/kernel/scall32-o32.S index 5e75a316f6b1..759f68066b5d 100644 --- a/arch/mips/kernel/scall32-o32.S +++ b/arch/mips/kernel/scall32-o32.S | |||
@@ -180,7 +180,7 @@ bad_stack: | |||
180 | * The system call does not exist in this kernel | 180 | * The system call does not exist in this kernel |
181 | */ | 181 | */ |
182 | illegal_syscall: | 182 | illegal_syscall: |
183 | li v0, -ENOSYS # error | 183 | li v0, ENOSYS # error |
184 | sw v0, PT_R2(sp) | 184 | sw v0, PT_R2(sp) |
185 | li t0, 1 # set error flag | 185 | li t0, 1 # set error flag |
186 | sw t0, PT_R7(sp) | 186 | sw t0, PT_R7(sp) |
@@ -293,7 +293,7 @@ bad_alignment: | |||
293 | jr t2 | 293 | jr t2 |
294 | /* Unreached */ | 294 | /* Unreached */ |
295 | 295 | ||
296 | einval: li v0, -EINVAL | 296 | einval: li v0, -ENOSYS |
297 | jr ra | 297 | jr ra |
298 | END(sys_syscall) | 298 | END(sys_syscall) |
299 | 299 | ||
diff --git a/arch/mips/kernel/scall64-64.S b/arch/mips/kernel/scall64-64.S index 3d58204c9d44..a9e171618994 100644 --- a/arch/mips/kernel/scall64-64.S +++ b/arch/mips/kernel/scall64-64.S | |||
@@ -117,7 +117,7 @@ syscall_trace_entry: | |||
117 | 117 | ||
118 | illegal_syscall: | 118 | illegal_syscall: |
119 | /* This also isn't a 64-bit syscall, throw an error. */ | 119 | /* This also isn't a 64-bit syscall, throw an error. */ |
120 | li v0, -ENOSYS # error | 120 | li v0, ENOSYS # error |
121 | sd v0, PT_R2(sp) | 121 | sd v0, PT_R2(sp) |
122 | li t0, 1 # set error flag | 122 | li t0, 1 # set error flag |
123 | sd t0, PT_R7(sp) | 123 | sd t0, PT_R7(sp) |
diff --git a/arch/mips/kernel/setup.c b/arch/mips/kernel/setup.c index 16f8edfe5cdc..4430a1f8fdf1 100644 --- a/arch/mips/kernel/setup.c +++ b/arch/mips/kernel/setup.c | |||
@@ -601,8 +601,8 @@ static int __init debugfs_mips(void) | |||
601 | struct dentry *d; | 601 | struct dentry *d; |
602 | 602 | ||
603 | d = debugfs_create_dir("mips", NULL); | 603 | d = debugfs_create_dir("mips", NULL); |
604 | if (IS_ERR(d)) | 604 | if (!d) |
605 | return PTR_ERR(d); | 605 | return -ENOMEM; |
606 | mips_debugfs_dir = d; | 606 | mips_debugfs_dir = d; |
607 | return 0; | 607 | return 0; |
608 | } | 608 | } |
diff --git a/arch/mips/kernel/smp.c b/arch/mips/kernel/smp.c index 7b59cfb7e602..b79ea7055ec3 100644 --- a/arch/mips/kernel/smp.c +++ b/arch/mips/kernel/smp.c | |||
@@ -163,8 +163,10 @@ static void stop_this_cpu(void *dummy) | |||
163 | * Remove this CPU: | 163 | * Remove this CPU: |
164 | */ | 164 | */ |
165 | cpu_clear(smp_processor_id(), cpu_online_map); | 165 | cpu_clear(smp_processor_id(), cpu_online_map); |
166 | local_irq_enable(); /* May need to service _machine_restart IPI */ | 166 | for (;;) { |
167 | for (;;); /* Wait if available. */ | 167 | if (cpu_wait) |
168 | (*cpu_wait)(); /* Wait if available. */ | ||
169 | } | ||
168 | } | 170 | } |
169 | 171 | ||
170 | void smp_send_stop(void) | 172 | void smp_send_stop(void) |
diff --git a/arch/mips/kernel/unaligned.c b/arch/mips/kernel/unaligned.c index c327b21bca81..20709669e592 100644 --- a/arch/mips/kernel/unaligned.c +++ b/arch/mips/kernel/unaligned.c | |||
@@ -560,12 +560,12 @@ static int __init debugfs_unaligned(void) | |||
560 | return -ENODEV; | 560 | return -ENODEV; |
561 | d = debugfs_create_u32("unaligned_instructions", S_IRUGO, | 561 | d = debugfs_create_u32("unaligned_instructions", S_IRUGO, |
562 | mips_debugfs_dir, &unaligned_instructions); | 562 | mips_debugfs_dir, &unaligned_instructions); |
563 | if (IS_ERR(d)) | 563 | if (!d) |
564 | return PTR_ERR(d); | 564 | return -ENOMEM; |
565 | d = debugfs_create_u32("unaligned_action", S_IRUGO | S_IWUSR, | 565 | d = debugfs_create_u32("unaligned_action", S_IRUGO | S_IWUSR, |
566 | mips_debugfs_dir, &unaligned_action); | 566 | mips_debugfs_dir, &unaligned_action); |
567 | if (IS_ERR(d)) | 567 | if (!d) |
568 | return PTR_ERR(d); | 568 | return -ENOMEM; |
569 | return 0; | 569 | return 0; |
570 | } | 570 | } |
571 | __initcall(debugfs_unaligned); | 571 | __initcall(debugfs_unaligned); |
diff --git a/arch/mips/lemote/lm2e/pci.c b/arch/mips/lemote/lm2e/pci.c index c1e41f15cc7e..8be03a8e1ad4 100644 --- a/arch/mips/lemote/lm2e/pci.c +++ b/arch/mips/lemote/lm2e/pci.c | |||
@@ -30,19 +30,20 @@ | |||
30 | #include <linux/kernel.h> | 30 | #include <linux/kernel.h> |
31 | #include <linux/init.h> | 31 | #include <linux/init.h> |
32 | #include <asm/mips-boards/bonito64.h> | 32 | #include <asm/mips-boards/bonito64.h> |
33 | #include <asm/mach-lemote/pci.h> | ||
33 | 34 | ||
34 | extern struct pci_ops bonito64_pci_ops; | 35 | extern struct pci_ops bonito64_pci_ops; |
35 | 36 | ||
36 | static struct resource loongson2e_pci_mem_resource = { | 37 | static struct resource loongson2e_pci_mem_resource = { |
37 | .name = "LOONGSON2E PCI MEM", | 38 | .name = "LOONGSON2E PCI MEM", |
38 | .start = 0x14000000UL, | 39 | .start = LOONGSON2E_PCI_MEM_START, |
39 | .end = 0x1fffffffUL, | 40 | .end = LOONGSON2E_PCI_MEM_END, |
40 | .flags = IORESOURCE_MEM, | 41 | .flags = IORESOURCE_MEM, |
41 | }; | 42 | }; |
42 | 43 | ||
43 | static struct resource loongson2e_pci_io_resource = { | 44 | static struct resource loongson2e_pci_io_resource = { |
44 | .name = "LOONGSON2E PCI IO MEM", | 45 | .name = "LOONGSON2E PCI IO MEM", |
45 | .start = 0x00004000UL, | 46 | .start = LOONGSON2E_PCI_IO_START, |
46 | .end = IO_SPACE_LIMIT, | 47 | .end = IO_SPACE_LIMIT, |
47 | .flags = IORESOURCE_IO, | 48 | .flags = IORESOURCE_IO, |
48 | }; | 49 | }; |
@@ -82,6 +83,12 @@ static void __init ict_pcimap(void) | |||
82 | static int __init pcibios_init(void) | 83 | static int __init pcibios_init(void) |
83 | { | 84 | { |
84 | ict_pcimap(); | 85 | ict_pcimap(); |
86 | |||
87 | loongson2e_pci_controller.io_map_base = | ||
88 | (unsigned long) ioremap(LOONGSON2E_IO_PORT_BASE, | ||
89 | loongson2e_pci_io_resource.end - | ||
90 | loongson2e_pci_io_resource.start + 1); | ||
91 | |||
85 | register_pci_controller(&loongson2e_pci_controller); | 92 | register_pci_controller(&loongson2e_pci_controller); |
86 | 93 | ||
87 | return 0; | 94 | return 0; |
diff --git a/arch/mips/lemote/lm2e/setup.c b/arch/mips/lemote/lm2e/setup.c index 2cc6745991ab..ebd6ceaef2fd 100644 --- a/arch/mips/lemote/lm2e/setup.c +++ b/arch/mips/lemote/lm2e/setup.c | |||
@@ -34,6 +34,7 @@ | |||
34 | #include <asm/mc146818-time.h> | 34 | #include <asm/mc146818-time.h> |
35 | #include <asm/time.h> | 35 | #include <asm/time.h> |
36 | #include <asm/wbflush.h> | 36 | #include <asm/wbflush.h> |
37 | #include <asm/mach-lemote/pci.h> | ||
37 | 38 | ||
38 | #ifdef CONFIG_VT | 39 | #ifdef CONFIG_VT |
39 | #include <linux/console.h> | 40 | #include <linux/console.h> |
@@ -42,12 +43,6 @@ | |||
42 | 43 | ||
43 | extern void mips_reboot_setup(void); | 44 | extern void mips_reboot_setup(void); |
44 | 45 | ||
45 | #ifdef CONFIG_64BIT | ||
46 | #define PTR_PAD(p) ((0xffffffff00000000)|((unsigned long long)(p))) | ||
47 | #else | ||
48 | #define PTR_PAD(p) (p) | ||
49 | #endif | ||
50 | |||
51 | unsigned long cpu_clock_freq; | 46 | unsigned long cpu_clock_freq; |
52 | unsigned long bus_clock; | 47 | unsigned long bus_clock; |
53 | unsigned int memsize; | 48 | unsigned int memsize; |
@@ -80,8 +75,8 @@ static void wbflush_loongson2e(void) | |||
80 | 75 | ||
81 | void __init plat_mem_setup(void) | 76 | void __init plat_mem_setup(void) |
82 | { | 77 | { |
83 | set_io_port_base(PTR_PAD(0xbfd00000)); | 78 | set_io_port_base((unsigned long)ioremap(LOONGSON2E_IO_PORT_BASE, |
84 | 79 | IO_SPACE_LIMIT - LOONGSON2E_PCI_IO_START + 1)); | |
85 | mips_reboot_setup(); | 80 | mips_reboot_setup(); |
86 | 81 | ||
87 | __wbflush = wbflush_loongson2e; | 82 | __wbflush = wbflush_loongson2e; |
diff --git a/arch/mips/lib/Makefile b/arch/mips/lib/Makefile index 8810dfb915dd..dbcf6511b74e 100644 --- a/arch/mips/lib/Makefile +++ b/arch/mips/lib/Makefile | |||
@@ -18,6 +18,7 @@ obj-$(CONFIG_CPU_R4300) += dump_tlb.o | |||
18 | obj-$(CONFIG_CPU_R4X00) += dump_tlb.o | 18 | obj-$(CONFIG_CPU_R4X00) += dump_tlb.o |
19 | obj-$(CONFIG_CPU_R5000) += dump_tlb.o | 19 | obj-$(CONFIG_CPU_R5000) += dump_tlb.o |
20 | obj-$(CONFIG_CPU_R5432) += dump_tlb.o | 20 | obj-$(CONFIG_CPU_R5432) += dump_tlb.o |
21 | obj-$(CONFIG_CPU_R5500) += dump_tlb.o | ||
21 | obj-$(CONFIG_CPU_R6000) += | 22 | obj-$(CONFIG_CPU_R6000) += |
22 | obj-$(CONFIG_CPU_R8000) += | 23 | obj-$(CONFIG_CPU_R8000) += |
23 | obj-$(CONFIG_CPU_RM7000) += dump_tlb.o | 24 | obj-$(CONFIG_CPU_RM7000) += dump_tlb.o |
diff --git a/arch/mips/lib/dump_tlb.c b/arch/mips/lib/dump_tlb.c index 465ff0ec85b9..779821cd54ab 100644 --- a/arch/mips/lib/dump_tlb.c +++ b/arch/mips/lib/dump_tlb.c | |||
@@ -25,6 +25,7 @@ static inline const char *msk2str(unsigned int mask) | |||
25 | case PM_16M: return "16Mb"; | 25 | case PM_16M: return "16Mb"; |
26 | case PM_64M: return "64Mb"; | 26 | case PM_64M: return "64Mb"; |
27 | case PM_256M: return "256Mb"; | 27 | case PM_256M: return "256Mb"; |
28 | case PM_1G: return "1Gb"; | ||
28 | #endif | 29 | #endif |
29 | } | 30 | } |
30 | return ""; | 31 | return ""; |
diff --git a/arch/mips/math-emu/cp1emu.c b/arch/mips/math-emu/cp1emu.c index b08fc65c13a6..7ec0b217dfd3 100644 --- a/arch/mips/math-emu/cp1emu.c +++ b/arch/mips/math-emu/cp1emu.c | |||
@@ -1299,12 +1299,12 @@ static int __init debugfs_fpuemu(void) | |||
1299 | if (!mips_debugfs_dir) | 1299 | if (!mips_debugfs_dir) |
1300 | return -ENODEV; | 1300 | return -ENODEV; |
1301 | dir = debugfs_create_dir("fpuemustats", mips_debugfs_dir); | 1301 | dir = debugfs_create_dir("fpuemustats", mips_debugfs_dir); |
1302 | if (IS_ERR(dir)) | 1302 | if (!dir) |
1303 | return PTR_ERR(dir); | 1303 | return -ENOMEM; |
1304 | for (i = 0; i < ARRAY_SIZE(vars); i++) { | 1304 | for (i = 0; i < ARRAY_SIZE(vars); i++) { |
1305 | d = debugfs_create_u32(vars[i].name, S_IRUGO, dir, vars[i].v); | 1305 | d = debugfs_create_u32(vars[i].name, S_IRUGO, dir, vars[i].v); |
1306 | if (IS_ERR(d)) | 1306 | if (!d) |
1307 | return PTR_ERR(d); | 1307 | return -ENOMEM; |
1308 | } | 1308 | } |
1309 | return 0; | 1309 | return 0; |
1310 | } | 1310 | } |
diff --git a/arch/mips/mm/Makefile b/arch/mips/mm/Makefile index 44e8dd8106bf..95ba32b5b720 100644 --- a/arch/mips/mm/Makefile +++ b/arch/mips/mm/Makefile | |||
@@ -19,6 +19,7 @@ obj-$(CONFIG_CPU_R4300) += c-r4k.o cex-gen.o tlb-r4k.o | |||
19 | obj-$(CONFIG_CPU_R4X00) += c-r4k.o cex-gen.o tlb-r4k.o | 19 | obj-$(CONFIG_CPU_R4X00) += c-r4k.o cex-gen.o tlb-r4k.o |
20 | obj-$(CONFIG_CPU_R5000) += c-r4k.o cex-gen.o tlb-r4k.o | 20 | obj-$(CONFIG_CPU_R5000) += c-r4k.o cex-gen.o tlb-r4k.o |
21 | obj-$(CONFIG_CPU_R5432) += c-r4k.o cex-gen.o tlb-r4k.o | 21 | obj-$(CONFIG_CPU_R5432) += c-r4k.o cex-gen.o tlb-r4k.o |
22 | obj-$(CONFIG_CPU_R5500) += c-r4k.o cex-gen.o tlb-r4k.o | ||
22 | obj-$(CONFIG_CPU_R8000) += c-r4k.o cex-gen.o tlb-r8k.o | 23 | obj-$(CONFIG_CPU_R8000) += c-r4k.o cex-gen.o tlb-r8k.o |
23 | obj-$(CONFIG_CPU_RM7000) += c-r4k.o cex-gen.o tlb-r4k.o | 24 | obj-$(CONFIG_CPU_RM7000) += c-r4k.o cex-gen.o tlb-r4k.o |
24 | obj-$(CONFIG_CPU_RM9000) += c-r4k.o cex-gen.o tlb-r4k.o | 25 | obj-$(CONFIG_CPU_RM9000) += c-r4k.o cex-gen.o tlb-r4k.o |
diff --git a/arch/mips/mm/dma-default.c b/arch/mips/mm/dma-default.c index 891312f8e5a6..5b98d0e731c2 100644 --- a/arch/mips/mm/dma-default.c +++ b/arch/mips/mm/dma-default.c | |||
@@ -324,7 +324,6 @@ void dma_sync_sg_for_cpu(struct device *dev, struct scatterlist *sg, int nelems, | |||
324 | if (cpu_is_noncoherent_r10000(dev)) | 324 | if (cpu_is_noncoherent_r10000(dev)) |
325 | __dma_sync((unsigned long)page_address(sg_page(sg)), | 325 | __dma_sync((unsigned long)page_address(sg_page(sg)), |
326 | sg->length, direction); | 326 | sg->length, direction); |
327 | plat_unmap_dma_mem(sg->dma_address); | ||
328 | } | 327 | } |
329 | } | 328 | } |
330 | 329 | ||
@@ -342,7 +341,6 @@ void dma_sync_sg_for_device(struct device *dev, struct scatterlist *sg, int nele | |||
342 | if (!plat_device_is_coherent(dev)) | 341 | if (!plat_device_is_coherent(dev)) |
343 | __dma_sync((unsigned long)page_address(sg_page(sg)), | 342 | __dma_sync((unsigned long)page_address(sg_page(sg)), |
344 | sg->length, direction); | 343 | sg->length, direction); |
345 | plat_unmap_dma_mem(sg->dma_address); | ||
346 | } | 344 | } |
347 | } | 345 | } |
348 | 346 | ||
diff --git a/arch/mips/nxp/pnx833x/common/Makefile b/arch/mips/nxp/pnx833x/common/Makefile new file mode 100644 index 000000000000..4a16f3b503b5 --- /dev/null +++ b/arch/mips/nxp/pnx833x/common/Makefile | |||
@@ -0,0 +1,3 @@ | |||
1 | obj-y := interrupts.o platform.o prom.o setup.o reset.o | ||
2 | |||
3 | EXTRA_CFLAGS += -Werror | ||
diff --git a/arch/mips/nxp/pnx833x/common/interrupts.c b/arch/mips/nxp/pnx833x/common/interrupts.c new file mode 100644 index 000000000000..30533ba200e2 --- /dev/null +++ b/arch/mips/nxp/pnx833x/common/interrupts.c | |||
@@ -0,0 +1,380 @@ | |||
1 | /* | ||
2 | * interrupts.c: Interrupt mappings for PNX833X. | ||
3 | * | ||
4 | * Copyright 2008 NXP Semiconductors | ||
5 | * Chris Steel <chris.steel@nxp.com> | ||
6 | * Daniel Laird <daniel.j.laird@nxp.com> | ||
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. | ||
12 | * | ||
13 | * This program is distributed in the hope that it will be useful, | ||
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
16 | * GNU General Public License for more details. | ||
17 | * | ||
18 | * You should have received a copy of the GNU General Public License | ||
19 | * along with this program; if not, write to the Free Software | ||
20 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
21 | */ | ||
22 | #include <linux/kernel.h> | ||
23 | #include <linux/irq.h> | ||
24 | #include <linux/hardirq.h> | ||
25 | #include <linux/interrupt.h> | ||
26 | #include <asm/mipsregs.h> | ||
27 | #include <asm/irq_cpu.h> | ||
28 | #include <irq.h> | ||
29 | #include <irq-mapping.h> | ||
30 | #include <gpio.h> | ||
31 | |||
32 | static int mips_cpu_timer_irq; | ||
33 | |||
34 | static const unsigned int irq_prio[PNX833X_PIC_NUM_IRQ] = | ||
35 | { | ||
36 | 0, /* unused */ | ||
37 | 4, /* PNX833X_PIC_I2C0_INT 1 */ | ||
38 | 4, /* PNX833X_PIC_I2C1_INT 2 */ | ||
39 | 1, /* PNX833X_PIC_UART0_INT 3 */ | ||
40 | 1, /* PNX833X_PIC_UART1_INT 4 */ | ||
41 | 6, /* PNX833X_PIC_TS_IN0_DV_INT 5 */ | ||
42 | 6, /* PNX833X_PIC_TS_IN0_DMA_INT 6 */ | ||
43 | 7, /* PNX833X_PIC_GPIO_INT 7 */ | ||
44 | 4, /* PNX833X_PIC_AUDIO_DEC_INT 8 */ | ||
45 | 5, /* PNX833X_PIC_VIDEO_DEC_INT 9 */ | ||
46 | 4, /* PNX833X_PIC_CONFIG_INT 10 */ | ||
47 | 4, /* PNX833X_PIC_AOI_INT 11 */ | ||
48 | 9, /* PNX833X_PIC_SYNC_INT 12 */ | ||
49 | 9, /* PNX8335_PIC_SATA_INT 13 */ | ||
50 | 4, /* PNX833X_PIC_OSD_INT 14 */ | ||
51 | 9, /* PNX833X_PIC_DISP1_INT 15 */ | ||
52 | 4, /* PNX833X_PIC_DEINTERLACER_INT 16 */ | ||
53 | 9, /* PNX833X_PIC_DISPLAY2_INT 17 */ | ||
54 | 4, /* PNX833X_PIC_VC_INT 18 */ | ||
55 | 4, /* PNX833X_PIC_SC_INT 19 */ | ||
56 | 9, /* PNX833X_PIC_IDE_INT 20 */ | ||
57 | 9, /* PNX833X_PIC_IDE_DMA_INT 21 */ | ||
58 | 6, /* PNX833X_PIC_TS_IN1_DV_INT 22 */ | ||
59 | 6, /* PNX833X_PIC_TS_IN1_DMA_INT 23 */ | ||
60 | 4, /* PNX833X_PIC_SGDX_DMA_INT 24 */ | ||
61 | 4, /* PNX833X_PIC_TS_OUT_INT 25 */ | ||
62 | 4, /* PNX833X_PIC_IR_INT 26 */ | ||
63 | 3, /* PNX833X_PIC_VMSP1_INT 27 */ | ||
64 | 3, /* PNX833X_PIC_VMSP2_INT 28 */ | ||
65 | 4, /* PNX833X_PIC_PIBC_INT 29 */ | ||
66 | 4, /* PNX833X_PIC_TS_IN0_TRD_INT 30 */ | ||
67 | 4, /* PNX833X_PIC_SGDX_TPD_INT 31 */ | ||
68 | 5, /* PNX833X_PIC_USB_INT 32 */ | ||
69 | 4, /* PNX833X_PIC_TS_IN1_TRD_INT 33 */ | ||
70 | 4, /* PNX833X_PIC_CLOCK_INT 34 */ | ||
71 | 4, /* PNX833X_PIC_SGDX_PARSER_INT 35 */ | ||
72 | 4, /* PNX833X_PIC_VMSP_DMA_INT 36 */ | ||
73 | #if defined(CONFIG_SOC_PNX8335) | ||
74 | 4, /* PNX8335_PIC_MIU_INT 37 */ | ||
75 | 4, /* PNX8335_PIC_AVCHIP_IRQ_INT 38 */ | ||
76 | 9, /* PNX8335_PIC_SYNC_HD_INT 39 */ | ||
77 | 9, /* PNX8335_PIC_DISP_HD_INT 40 */ | ||
78 | 9, /* PNX8335_PIC_DISP_SCALER_INT 41 */ | ||
79 | 4, /* PNX8335_PIC_OSD_HD1_INT 42 */ | ||
80 | 4, /* PNX8335_PIC_DTL_WRITER_Y_INT 43 */ | ||
81 | 4, /* PNX8335_PIC_DTL_WRITER_C_INT 44 */ | ||
82 | 4, /* PNX8335_PIC_DTL_EMULATOR_Y_IR_INT 45 */ | ||
83 | 4, /* PNX8335_PIC_DTL_EMULATOR_C_IR_INT 46 */ | ||
84 | 4, /* PNX8335_PIC_DENC_TTX_INT 47 */ | ||
85 | 4, /* PNX8335_PIC_MMI_SIF0_INT 48 */ | ||
86 | 4, /* PNX8335_PIC_MMI_SIF1_INT 49 */ | ||
87 | 4, /* PNX8335_PIC_MMI_CDMMU_INT 50 */ | ||
88 | 4, /* PNX8335_PIC_PIBCS_INT 51 */ | ||
89 | 12, /* PNX8335_PIC_ETHERNET_INT 52 */ | ||
90 | 3, /* PNX8335_PIC_VMSP1_0_INT 53 */ | ||
91 | 3, /* PNX8335_PIC_VMSP1_1_INT 54 */ | ||
92 | 4, /* PNX8335_PIC_VMSP1_DMA_INT 55 */ | ||
93 | 4, /* PNX8335_PIC_TDGR_DE_INT 56 */ | ||
94 | 4, /* PNX8335_PIC_IR1_IRQ_INT 57 */ | ||
95 | #endif | ||
96 | }; | ||
97 | |||
98 | static void pnx833x_timer_dispatch(void) | ||
99 | { | ||
100 | do_IRQ(mips_cpu_timer_irq); | ||
101 | } | ||
102 | |||
103 | static void pic_dispatch(void) | ||
104 | { | ||
105 | unsigned int irq = PNX833X_REGFIELD(PIC_INT_SRC, INT_SRC); | ||
106 | |||
107 | if ((irq >= 1) && (irq < (PNX833X_PIC_NUM_IRQ))) { | ||
108 | unsigned long priority = PNX833X_PIC_INT_PRIORITY; | ||
109 | PNX833X_PIC_INT_PRIORITY = irq_prio[irq]; | ||
110 | |||
111 | if (irq == PNX833X_PIC_GPIO_INT) { | ||
112 | unsigned long mask = PNX833X_PIO_INT_STATUS & PNX833X_PIO_INT_ENABLE; | ||
113 | int pin; | ||
114 | while ((pin = ffs(mask & 0xffff))) { | ||
115 | pin -= 1; | ||
116 | do_IRQ(PNX833X_GPIO_IRQ_BASE + pin); | ||
117 | mask &= ~(1 << pin); | ||
118 | } | ||
119 | } else { | ||
120 | do_IRQ(irq + PNX833X_PIC_IRQ_BASE); | ||
121 | } | ||
122 | |||
123 | PNX833X_PIC_INT_PRIORITY = priority; | ||
124 | } else { | ||
125 | printk(KERN_ERR "plat_irq_dispatch: unexpected irq %u\n", irq); | ||
126 | } | ||
127 | } | ||
128 | |||
129 | asmlinkage void plat_irq_dispatch(void) | ||
130 | { | ||
131 | unsigned int pending = read_c0_status() & read_c0_cause(); | ||
132 | |||
133 | if (pending & STATUSF_IP4) | ||
134 | pic_dispatch(); | ||
135 | else if (pending & STATUSF_IP7) | ||
136 | do_IRQ(PNX833X_TIMER_IRQ); | ||
137 | else | ||
138 | spurious_interrupt(); | ||
139 | } | ||
140 | |||
141 | static inline void pnx833x_hard_enable_pic_irq(unsigned int irq) | ||
142 | { | ||
143 | /* Currently we do this by setting IRQ priority to 1. | ||
144 | If priority support is being implemented, 1 should be repalced | ||
145 | by a better value. */ | ||
146 | PNX833X_PIC_INT_REG(irq) = irq_prio[irq]; | ||
147 | } | ||
148 | |||
149 | static inline void pnx833x_hard_disable_pic_irq(unsigned int irq) | ||
150 | { | ||
151 | /* Disable IRQ by writing setting it's priority to 0 */ | ||
152 | PNX833X_PIC_INT_REG(irq) = 0; | ||
153 | } | ||
154 | |||
155 | static int irqflags[PNX833X_PIC_NUM_IRQ]; /* initialized by zeroes */ | ||
156 | #define IRQFLAG_STARTED 1 | ||
157 | #define IRQFLAG_DISABLED 2 | ||
158 | |||
159 | static DEFINE_SPINLOCK(pnx833x_irq_lock); | ||
160 | |||
161 | static unsigned int pnx833x_startup_pic_irq(unsigned int irq) | ||
162 | { | ||
163 | unsigned long flags; | ||
164 | unsigned int pic_irq = irq - PNX833X_PIC_IRQ_BASE; | ||
165 | |||
166 | spin_lock_irqsave(&pnx833x_irq_lock, flags); | ||
167 | |||
168 | irqflags[pic_irq] = IRQFLAG_STARTED; /* started, not disabled */ | ||
169 | pnx833x_hard_enable_pic_irq(pic_irq); | ||
170 | |||
171 | spin_unlock_irqrestore(&pnx833x_irq_lock, flags); | ||
172 | return 0; | ||
173 | } | ||
174 | |||
175 | static void pnx833x_shutdown_pic_irq(unsigned int irq) | ||
176 | { | ||
177 | unsigned long flags; | ||
178 | unsigned int pic_irq = irq - PNX833X_PIC_IRQ_BASE; | ||
179 | |||
180 | spin_lock_irqsave(&pnx833x_irq_lock, flags); | ||
181 | |||
182 | irqflags[pic_irq] = 0; /* not started */ | ||
183 | pnx833x_hard_disable_pic_irq(pic_irq); | ||
184 | |||
185 | spin_unlock_irqrestore(&pnx833x_irq_lock, flags); | ||
186 | } | ||
187 | |||
188 | static void pnx833x_enable_pic_irq(unsigned int irq) | ||
189 | { | ||
190 | unsigned long flags; | ||
191 | unsigned int pic_irq = irq - PNX833X_PIC_IRQ_BASE; | ||
192 | |||
193 | spin_lock_irqsave(&pnx833x_irq_lock, flags); | ||
194 | |||
195 | irqflags[pic_irq] &= ~IRQFLAG_DISABLED; | ||
196 | if (irqflags[pic_irq] == IRQFLAG_STARTED) | ||
197 | pnx833x_hard_enable_pic_irq(pic_irq); | ||
198 | |||
199 | spin_unlock_irqrestore(&pnx833x_irq_lock, flags); | ||
200 | } | ||
201 | |||
202 | static void pnx833x_disable_pic_irq(unsigned int irq) | ||
203 | { | ||
204 | unsigned long flags; | ||
205 | unsigned int pic_irq = irq - PNX833X_PIC_IRQ_BASE; | ||
206 | |||
207 | spin_lock_irqsave(&pnx833x_irq_lock, flags); | ||
208 | |||
209 | irqflags[pic_irq] |= IRQFLAG_DISABLED; | ||
210 | pnx833x_hard_disable_pic_irq(pic_irq); | ||
211 | |||
212 | spin_unlock_irqrestore(&pnx833x_irq_lock, flags); | ||
213 | } | ||
214 | |||
215 | static void pnx833x_ack_pic_irq(unsigned int irq) | ||
216 | { | ||
217 | } | ||
218 | |||
219 | static void pnx833x_end_pic_irq(unsigned int irq) | ||
220 | { | ||
221 | } | ||
222 | |||
223 | static DEFINE_SPINLOCK(pnx833x_gpio_pnx833x_irq_lock); | ||
224 | |||
225 | static unsigned int pnx833x_startup_gpio_irq(unsigned int irq) | ||
226 | { | ||
227 | int pin = irq - PNX833X_GPIO_IRQ_BASE; | ||
228 | unsigned long flags; | ||
229 | spin_lock_irqsave(&pnx833x_gpio_pnx833x_irq_lock, flags); | ||
230 | pnx833x_gpio_enable_irq(pin); | ||
231 | spin_unlock_irqrestore(&pnx833x_gpio_pnx833x_irq_lock, flags); | ||
232 | return 0; | ||
233 | } | ||
234 | |||
235 | static void pnx833x_enable_gpio_irq(unsigned int irq) | ||
236 | { | ||
237 | int pin = irq - PNX833X_GPIO_IRQ_BASE; | ||
238 | unsigned long flags; | ||
239 | spin_lock_irqsave(&pnx833x_gpio_pnx833x_irq_lock, flags); | ||
240 | pnx833x_gpio_enable_irq(pin); | ||
241 | spin_unlock_irqrestore(&pnx833x_gpio_pnx833x_irq_lock, flags); | ||
242 | } | ||
243 | |||
244 | static void pnx833x_disable_gpio_irq(unsigned int irq) | ||
245 | { | ||
246 | int pin = irq - PNX833X_GPIO_IRQ_BASE; | ||
247 | unsigned long flags; | ||
248 | spin_lock_irqsave(&pnx833x_gpio_pnx833x_irq_lock, flags); | ||
249 | pnx833x_gpio_disable_irq(pin); | ||
250 | spin_unlock_irqrestore(&pnx833x_gpio_pnx833x_irq_lock, flags); | ||
251 | } | ||
252 | |||
253 | static void pnx833x_ack_gpio_irq(unsigned int irq) | ||
254 | { | ||
255 | } | ||
256 | |||
257 | static void pnx833x_end_gpio_irq(unsigned int irq) | ||
258 | { | ||
259 | int pin = irq - PNX833X_GPIO_IRQ_BASE; | ||
260 | unsigned long flags; | ||
261 | spin_lock_irqsave(&pnx833x_gpio_pnx833x_irq_lock, flags); | ||
262 | pnx833x_gpio_clear_irq(pin); | ||
263 | spin_unlock_irqrestore(&pnx833x_gpio_pnx833x_irq_lock, flags); | ||
264 | } | ||
265 | |||
266 | static int pnx833x_set_type_gpio_irq(unsigned int irq, unsigned int flow_type) | ||
267 | { | ||
268 | int pin = irq - PNX833X_GPIO_IRQ_BASE; | ||
269 | int gpio_mode; | ||
270 | |||
271 | switch (flow_type) { | ||
272 | case IRQ_TYPE_EDGE_RISING: | ||
273 | gpio_mode = GPIO_INT_EDGE_RISING; | ||
274 | break; | ||
275 | case IRQ_TYPE_EDGE_FALLING: | ||
276 | gpio_mode = GPIO_INT_EDGE_FALLING; | ||
277 | break; | ||
278 | case IRQ_TYPE_EDGE_BOTH: | ||
279 | gpio_mode = GPIO_INT_EDGE_BOTH; | ||
280 | break; | ||
281 | case IRQ_TYPE_LEVEL_HIGH: | ||
282 | gpio_mode = GPIO_INT_LEVEL_HIGH; | ||
283 | break; | ||
284 | case IRQ_TYPE_LEVEL_LOW: | ||
285 | gpio_mode = GPIO_INT_LEVEL_LOW; | ||
286 | break; | ||
287 | default: | ||
288 | gpio_mode = GPIO_INT_NONE; | ||
289 | break; | ||
290 | } | ||
291 | |||
292 | pnx833x_gpio_setup_irq(gpio_mode, pin); | ||
293 | |||
294 | return 0; | ||
295 | } | ||
296 | |||
297 | static struct irq_chip pnx833x_pic_irq_type = { | ||
298 | .typename = "PNX-PIC", | ||
299 | .startup = pnx833x_startup_pic_irq, | ||
300 | .shutdown = pnx833x_shutdown_pic_irq, | ||
301 | .enable = pnx833x_enable_pic_irq, | ||
302 | .disable = pnx833x_disable_pic_irq, | ||
303 | .ack = pnx833x_ack_pic_irq, | ||
304 | .end = pnx833x_end_pic_irq | ||
305 | }; | ||
306 | |||
307 | static struct irq_chip pnx833x_gpio_irq_type = { | ||
308 | .typename = "PNX-GPIO", | ||
309 | .startup = pnx833x_startup_gpio_irq, | ||
310 | .shutdown = pnx833x_disable_gpio_irq, | ||
311 | .enable = pnx833x_enable_gpio_irq, | ||
312 | .disable = pnx833x_disable_gpio_irq, | ||
313 | .ack = pnx833x_ack_gpio_irq, | ||
314 | .end = pnx833x_end_gpio_irq, | ||
315 | .set_type = pnx833x_set_type_gpio_irq | ||
316 | }; | ||
317 | |||
318 | void __init arch_init_irq(void) | ||
319 | { | ||
320 | unsigned int irq; | ||
321 | |||
322 | /* setup standard internal cpu irqs */ | ||
323 | mips_cpu_irq_init(); | ||
324 | |||
325 | /* Set IRQ information in irq_desc */ | ||
326 | for (irq = PNX833X_PIC_IRQ_BASE; irq < (PNX833X_PIC_IRQ_BASE + PNX833X_PIC_NUM_IRQ); irq++) { | ||
327 | pnx833x_hard_disable_pic_irq(irq); | ||
328 | set_irq_chip_and_handler(irq, &pnx833x_pic_irq_type, handle_simple_irq); | ||
329 | } | ||
330 | |||
331 | for (irq = PNX833X_GPIO_IRQ_BASE; irq < (PNX833X_GPIO_IRQ_BASE + PNX833X_GPIO_NUM_IRQ); irq++) | ||
332 | set_irq_chip_and_handler(irq, &pnx833x_gpio_irq_type, handle_simple_irq); | ||
333 | |||
334 | /* Set PIC priority limiter register to 0 */ | ||
335 | PNX833X_PIC_INT_PRIORITY = 0; | ||
336 | |||
337 | /* Setup GPIO IRQ dispatching */ | ||
338 | pnx833x_startup_pic_irq(PNX833X_PIC_GPIO_INT); | ||
339 | |||
340 | /* Enable PIC IRQs (HWIRQ2) */ | ||
341 | if (cpu_has_vint) | ||
342 | set_vi_handler(4, pic_dispatch); | ||
343 | |||
344 | write_c0_status(read_c0_status() | IE_IRQ2); | ||
345 | } | ||
346 | |||
347 | unsigned int __cpuinit get_c0_compare_int(void) | ||
348 | { | ||
349 | if (cpu_has_vint) | ||
350 | set_vi_handler(cp0_compare_irq, pnx833x_timer_dispatch); | ||
351 | |||
352 | mips_cpu_timer_irq = MIPS_CPU_IRQ_BASE + cp0_compare_irq; | ||
353 | return mips_cpu_timer_irq; | ||
354 | } | ||
355 | |||
356 | void __init plat_time_init(void) | ||
357 | { | ||
358 | /* calculate mips_hpt_frequency based on PNX833X_CLOCK_CPUCP_CTL reg */ | ||
359 | |||
360 | extern unsigned long mips_hpt_frequency; | ||
361 | unsigned long reg = PNX833X_CLOCK_CPUCP_CTL; | ||
362 | |||
363 | if (!(PNX833X_BIT(reg, CLOCK_CPUCP_CTL, EXIT_RESET))) { | ||
364 | /* Functional clock is disabled so use crystal frequency */ | ||
365 | mips_hpt_frequency = 25; | ||
366 | } else { | ||
367 | #if defined(CONFIG_SOC_PNX8335) | ||
368 | /* Functional clock is enabled, so get clock multiplier */ | ||
369 | mips_hpt_frequency = 90 + (10 * PNX8335_REGFIELD(CLOCK_PLL_CPU_CTL, FREQ)); | ||
370 | #else | ||
371 | static const unsigned long int freq[4] = {240, 160, 120, 80}; | ||
372 | mips_hpt_frequency = freq[PNX833X_FIELD(reg, CLOCK_CPUCP_CTL, DIV_CLOCK)]; | ||
373 | #endif | ||
374 | } | ||
375 | |||
376 | printk(KERN_INFO "CPU clock is %ld MHz\n", mips_hpt_frequency); | ||
377 | |||
378 | mips_hpt_frequency *= 500000; | ||
379 | } | ||
380 | |||
diff --git a/arch/mips/nxp/pnx833x/common/platform.c b/arch/mips/nxp/pnx833x/common/platform.c new file mode 100644 index 000000000000..b1ccbcc18f78 --- /dev/null +++ b/arch/mips/nxp/pnx833x/common/platform.c | |||
@@ -0,0 +1,319 @@ | |||
1 | /* | ||
2 | * platform.c: platform support for PNX833X. | ||
3 | * | ||
4 | * Copyright 2008 NXP Semiconductors | ||
5 | * Chris Steel <chris.steel@nxp.com> | ||
6 | * Daniel Laird <daniel.j.laird@nxp.com> | ||
7 | * | ||
8 | * Based on software written by: | ||
9 | * Nikita Youshchenko <yoush@debian.org>, based on PNX8550 code. | ||
10 | * | ||
11 | * This program is free software; you can redistribute it and/or modify | ||
12 | * it under the terms of the GNU General Public License as published by | ||
13 | * the Free Software Foundation; either version 2 of the License, or | ||
14 | * (at your option) any later version. | ||
15 | * | ||
16 | * This program is distributed in the hope that it will be useful, | ||
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
19 | * GNU General Public License for more details. | ||
20 | * | ||
21 | * You should have received a copy of the GNU General Public License | ||
22 | * along with this program; if not, write to the Free Software | ||
23 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
24 | */ | ||
25 | #include <linux/device.h> | ||
26 | #include <linux/dma-mapping.h> | ||
27 | #include <linux/platform_device.h> | ||
28 | #include <linux/kernel.h> | ||
29 | #include <linux/init.h> | ||
30 | #include <linux/resource.h> | ||
31 | #include <linux/serial.h> | ||
32 | #include <linux/serial_pnx8xxx.h> | ||
33 | #include <linux/mtd/nand.h> | ||
34 | #include <linux/mtd/partitions.h> | ||
35 | |||
36 | #ifdef CONFIG_I2C_PNX0105 | ||
37 | /* Until i2c driver available in kernel.*/ | ||
38 | #include <linux/i2c-pnx0105.h> | ||
39 | #endif | ||
40 | |||
41 | #include <irq.h> | ||
42 | #include <irq-mapping.h> | ||
43 | #include <pnx833x.h> | ||
44 | |||
45 | static u64 uart_dmamask = DMA_32BIT_MASK; | ||
46 | |||
47 | static struct resource pnx833x_uart_resources[] = { | ||
48 | [0] = { | ||
49 | .start = PNX833X_UART0_PORTS_START, | ||
50 | .end = PNX833X_UART0_PORTS_END, | ||
51 | .flags = IORESOURCE_MEM, | ||
52 | }, | ||
53 | [1] = { | ||
54 | .start = PNX833X_PIC_UART0_INT, | ||
55 | .end = PNX833X_PIC_UART0_INT, | ||
56 | .flags = IORESOURCE_IRQ, | ||
57 | }, | ||
58 | [2] = { | ||
59 | .start = PNX833X_UART1_PORTS_START, | ||
60 | .end = PNX833X_UART1_PORTS_END, | ||
61 | .flags = IORESOURCE_MEM, | ||
62 | }, | ||
63 | [3] = { | ||
64 | .start = PNX833X_PIC_UART1_INT, | ||
65 | .end = PNX833X_PIC_UART1_INT, | ||
66 | .flags = IORESOURCE_IRQ, | ||
67 | }, | ||
68 | }; | ||
69 | |||
70 | struct pnx8xxx_port pnx8xxx_ports[] = { | ||
71 | [0] = { | ||
72 | .port = { | ||
73 | .type = PORT_PNX8XXX, | ||
74 | .iotype = UPIO_MEM, | ||
75 | .membase = (void __iomem *)PNX833X_UART0_PORTS_START, | ||
76 | .mapbase = PNX833X_UART0_PORTS_START, | ||
77 | .irq = PNX833X_PIC_UART0_INT, | ||
78 | .uartclk = 3692300, | ||
79 | .fifosize = 16, | ||
80 | .flags = UPF_BOOT_AUTOCONF, | ||
81 | .line = 0, | ||
82 | }, | ||
83 | }, | ||
84 | [1] = { | ||
85 | .port = { | ||
86 | .type = PORT_PNX8XXX, | ||
87 | .iotype = UPIO_MEM, | ||
88 | .membase = (void __iomem *)PNX833X_UART1_PORTS_START, | ||
89 | .mapbase = PNX833X_UART1_PORTS_START, | ||
90 | .irq = PNX833X_PIC_UART1_INT, | ||
91 | .uartclk = 3692300, | ||
92 | .fifosize = 16, | ||
93 | .flags = UPF_BOOT_AUTOCONF, | ||
94 | .line = 1, | ||
95 | }, | ||
96 | }, | ||
97 | }; | ||
98 | |||
99 | static struct platform_device pnx833x_uart_device = { | ||
100 | .name = "pnx8xxx-uart", | ||
101 | .id = -1, | ||
102 | .dev = { | ||
103 | .dma_mask = &uart_dmamask, | ||
104 | .coherent_dma_mask = DMA_32BIT_MASK, | ||
105 | .platform_data = pnx8xxx_ports, | ||
106 | }, | ||
107 | .num_resources = ARRAY_SIZE(pnx833x_uart_resources), | ||
108 | .resource = pnx833x_uart_resources, | ||
109 | }; | ||
110 | |||
111 | static u64 ehci_dmamask = DMA_32BIT_MASK; | ||
112 | |||
113 | static struct resource pnx833x_usb_ehci_resources[] = { | ||
114 | [0] = { | ||
115 | .start = PNX833X_USB_PORTS_START, | ||
116 | .end = PNX833X_USB_PORTS_END, | ||
117 | .flags = IORESOURCE_MEM, | ||
118 | }, | ||
119 | [1] = { | ||
120 | .start = PNX833X_PIC_USB_INT, | ||
121 | .end = PNX833X_PIC_USB_INT, | ||
122 | .flags = IORESOURCE_IRQ, | ||
123 | }, | ||
124 | }; | ||
125 | |||
126 | static struct platform_device pnx833x_usb_ehci_device = { | ||
127 | .name = "pnx833x-ehci", | ||
128 | .id = -1, | ||
129 | .dev = { | ||
130 | .dma_mask = &ehci_dmamask, | ||
131 | .coherent_dma_mask = DMA_32BIT_MASK, | ||
132 | }, | ||
133 | .num_resources = ARRAY_SIZE(pnx833x_usb_ehci_resources), | ||
134 | .resource = pnx833x_usb_ehci_resources, | ||
135 | }; | ||
136 | |||
137 | #ifdef CONFIG_I2C_PNX0105 | ||
138 | static struct resource pnx833x_i2c0_resources[] = { | ||
139 | { | ||
140 | .start = PNX833X_I2C0_PORTS_START, | ||
141 | .end = PNX833X_I2C0_PORTS_END, | ||
142 | .flags = IORESOURCE_MEM, | ||
143 | }, | ||
144 | { | ||
145 | .start = PNX833X_PIC_I2C0_INT, | ||
146 | .end = PNX833X_PIC_I2C0_INT, | ||
147 | .flags = IORESOURCE_IRQ, | ||
148 | }, | ||
149 | }; | ||
150 | |||
151 | static struct resource pnx833x_i2c1_resources[] = { | ||
152 | { | ||
153 | .start = PNX833X_I2C1_PORTS_START, | ||
154 | .end = PNX833X_I2C1_PORTS_END, | ||
155 | .flags = IORESOURCE_MEM, | ||
156 | }, | ||
157 | { | ||
158 | .start = PNX833X_PIC_I2C1_INT, | ||
159 | .end = PNX833X_PIC_I2C1_INT, | ||
160 | .flags = IORESOURCE_IRQ, | ||
161 | }, | ||
162 | }; | ||
163 | |||
164 | static struct i2c_pnx0105_dev pnx833x_i2c_dev[] = { | ||
165 | { | ||
166 | .base = PNX833X_I2C0_PORTS_START, | ||
167 | .irq = -1, /* should be PNX833X_PIC_I2C0_INT but polling is faster */ | ||
168 | .clock = 6, /* 0 == 400 kHz, 4 == 100 kHz(Maximum HDMI), 6 = 50kHz(Prefered HDCP) */ | ||
169 | .bus_addr = 0, /* no slave support */ | ||
170 | }, | ||
171 | { | ||
172 | .base = PNX833X_I2C1_PORTS_START, | ||
173 | .irq = -1, /* on high freq, polling is faster */ | ||
174 | /*.irq = PNX833X_PIC_I2C1_INT,*/ | ||
175 | .clock = 4, /* 0 == 400 kHz, 4 == 100 kHz. 100 kHz seems a safe default for now */ | ||
176 | .bus_addr = 0, /* no slave support */ | ||
177 | }, | ||
178 | }; | ||
179 | |||
180 | static struct platform_device pnx833x_i2c0_device = { | ||
181 | .name = "i2c-pnx0105", | ||
182 | .id = 0, | ||
183 | .dev = { | ||
184 | .platform_data = &pnx833x_i2c_dev[0], | ||
185 | }, | ||
186 | .num_resources = ARRAY_SIZE(pnx833x_i2c0_resources), | ||
187 | .resource = pnx833x_i2c0_resources, | ||
188 | }; | ||
189 | |||
190 | static struct platform_device pnx833x_i2c1_device = { | ||
191 | .name = "i2c-pnx0105", | ||
192 | .id = 1, | ||
193 | .dev = { | ||
194 | .platform_data = &pnx833x_i2c_dev[1], | ||
195 | }, | ||
196 | .num_resources = ARRAY_SIZE(pnx833x_i2c1_resources), | ||
197 | .resource = pnx833x_i2c1_resources, | ||
198 | }; | ||
199 | #endif | ||
200 | |||
201 | static u64 ethernet_dmamask = DMA_32BIT_MASK; | ||
202 | |||
203 | static struct resource pnx833x_ethernet_resources[] = { | ||
204 | [0] = { | ||
205 | .start = PNX8335_IP3902_PORTS_START, | ||
206 | .end = PNX8335_IP3902_PORTS_END, | ||
207 | .flags = IORESOURCE_MEM, | ||
208 | }, | ||
209 | [1] = { | ||
210 | .start = PNX8335_PIC_ETHERNET_INT, | ||
211 | .end = PNX8335_PIC_ETHERNET_INT, | ||
212 | .flags = IORESOURCE_IRQ, | ||
213 | }, | ||
214 | }; | ||
215 | |||
216 | static struct platform_device pnx833x_ethernet_device = { | ||
217 | .name = "ip3902-eth", | ||
218 | .id = -1, | ||
219 | .dev = { | ||
220 | .dma_mask = ðernet_dmamask, | ||
221 | .coherent_dma_mask = DMA_32BIT_MASK, | ||
222 | }, | ||
223 | .num_resources = ARRAY_SIZE(pnx833x_ethernet_resources), | ||
224 | .resource = pnx833x_ethernet_resources, | ||
225 | }; | ||
226 | |||
227 | static struct resource pnx833x_sata_resources[] = { | ||
228 | [0] = { | ||
229 | .start = PNX8335_SATA_PORTS_START, | ||
230 | .end = PNX8335_SATA_PORTS_END, | ||
231 | .flags = IORESOURCE_MEM, | ||
232 | }, | ||
233 | [1] = { | ||
234 | .start = PNX8335_PIC_SATA_INT, | ||
235 | .end = PNX8335_PIC_SATA_INT, | ||
236 | .flags = IORESOURCE_IRQ, | ||
237 | }, | ||
238 | }; | ||
239 | |||
240 | static struct platform_device pnx833x_sata_device = { | ||
241 | .name = "pnx833x-sata", | ||
242 | .id = -1, | ||
243 | .num_resources = ARRAY_SIZE(pnx833x_sata_resources), | ||
244 | .resource = pnx833x_sata_resources, | ||
245 | }; | ||
246 | |||
247 | static const char *part_probes[] = { | ||
248 | "cmdlinepart", | ||
249 | NULL | ||
250 | }; | ||
251 | |||
252 | static void | ||
253 | pnx833x_flash_nand_cmd_ctrl(struct mtd_info *mtd, int cmd, unsigned int ctrl) | ||
254 | { | ||
255 | struct nand_chip *this = mtd->priv; | ||
256 | unsigned long nandaddr = (unsigned long)this->IO_ADDR_W; | ||
257 | |||
258 | if (cmd == NAND_CMD_NONE) | ||
259 | return; | ||
260 | |||
261 | if (ctrl & NAND_CLE) | ||
262 | writeb(cmd, (void __iomem *)(nandaddr + PNX8335_NAND_CLE_MASK)); | ||
263 | else | ||
264 | writeb(cmd, (void __iomem *)(nandaddr + PNX8335_NAND_ALE_MASK)); | ||
265 | } | ||
266 | |||
267 | static struct platform_nand_data pnx833x_flash_nand_data = { | ||
268 | .chip = { | ||
269 | .chip_delay = 25, | ||
270 | .part_probe_types = part_probes, | ||
271 | }, | ||
272 | .ctrl = { | ||
273 | .cmd_ctrl = pnx833x_flash_nand_cmd_ctrl | ||
274 | } | ||
275 | }; | ||
276 | |||
277 | /* | ||
278 | * Set start to be the correct address (PNX8335_NAND_BASE with no 0xb!!), | ||
279 | * 12 bytes more seems to be the standard that allows for NAND access. | ||
280 | */ | ||
281 | static struct resource pnx833x_flash_nand_resource = { | ||
282 | .start = PNX8335_NAND_BASE, | ||
283 | .end = PNX8335_NAND_BASE + 12, | ||
284 | .flags = IORESOURCE_MEM, | ||
285 | }; | ||
286 | |||
287 | static struct platform_device pnx833x_flash_nand = { | ||
288 | .name = "gen_nand", | ||
289 | .id = -1, | ||
290 | .num_resources = 1, | ||
291 | .resource = &pnx833x_flash_nand_resource, | ||
292 | .dev = { | ||
293 | .platform_data = &pnx833x_flash_nand_data, | ||
294 | }, | ||
295 | }; | ||
296 | |||
297 | static struct platform_device *pnx833x_platform_devices[] __initdata = { | ||
298 | &pnx833x_uart_device, | ||
299 | &pnx833x_usb_ehci_device, | ||
300 | #ifdef CONFIG_I2C_PNX0105 | ||
301 | &pnx833x_i2c0_device, | ||
302 | &pnx833x_i2c1_device, | ||
303 | #endif | ||
304 | &pnx833x_ethernet_device, | ||
305 | &pnx833x_sata_device, | ||
306 | &pnx833x_flash_nand, | ||
307 | }; | ||
308 | |||
309 | static int __init pnx833x_platform_init(void) | ||
310 | { | ||
311 | int res; | ||
312 | |||
313 | res = platform_add_devices(pnx833x_platform_devices, | ||
314 | ARRAY_SIZE(pnx833x_platform_devices)); | ||
315 | |||
316 | return res; | ||
317 | } | ||
318 | |||
319 | arch_initcall(pnx833x_platform_init); | ||
diff --git a/arch/mips/nxp/pnx833x/common/prom.c b/arch/mips/nxp/pnx833x/common/prom.c new file mode 100644 index 000000000000..2a41e8fec210 --- /dev/null +++ b/arch/mips/nxp/pnx833x/common/prom.c | |||
@@ -0,0 +1,70 @@ | |||
1 | /* | ||
2 | * prom.c: | ||
3 | * | ||
4 | * Copyright 2008 NXP Semiconductors | ||
5 | * Chris Steel <chris.steel@nxp.com> | ||
6 | * Daniel Laird <daniel.j.laird@nxp.com> | ||
7 | * | ||
8 | * Based on software written by: | ||
9 | * Nikita Youshchenko <yoush@debian.org>, based on PNX8550 code. | ||
10 | * | ||
11 | * This program is free software; you can redistribute it and/or modify | ||
12 | * it under the terms of the GNU General Public License as published by | ||
13 | * the Free Software Foundation; either version 2 of the License, or | ||
14 | * (at your option) any later version. | ||
15 | * | ||
16 | * This program is distributed in the hope that it will be useful, | ||
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
19 | * GNU General Public License for more details. | ||
20 | * | ||
21 | * You should have received a copy of the GNU General Public License | ||
22 | * along with this program; if not, write to the Free Software | ||
23 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
24 | */ | ||
25 | #include <linux/init.h> | ||
26 | #include <asm/bootinfo.h> | ||
27 | #include <linux/string.h> | ||
28 | |||
29 | void __init prom_init_cmdline(void) | ||
30 | { | ||
31 | int argc = fw_arg0; | ||
32 | char **argv = (char **)fw_arg1; | ||
33 | char *c = &(arcs_cmdline[0]); | ||
34 | int i; | ||
35 | |||
36 | for (i = 1; i < argc; i++) { | ||
37 | strcpy(c, argv[i]); | ||
38 | c += strlen(argv[i]); | ||
39 | if (i < argc-1) | ||
40 | *c++ = ' '; | ||
41 | } | ||
42 | *c = 0; | ||
43 | } | ||
44 | |||
45 | char __init *prom_getenv(char *envname) | ||
46 | { | ||
47 | extern char **prom_envp; | ||
48 | char **env = prom_envp; | ||
49 | int i; | ||
50 | |||
51 | i = strlen(envname); | ||
52 | |||
53 | while (*env) { | ||
54 | if (strncmp(envname, *env, i) == 0 && *(*env+i) == '=') | ||
55 | return *env + i + 1; | ||
56 | env++; | ||
57 | } | ||
58 | |||
59 | return 0; | ||
60 | } | ||
61 | |||
62 | void __init prom_free_prom_memory(void) | ||
63 | { | ||
64 | } | ||
65 | |||
66 | char * __init prom_getcmdline(void) | ||
67 | { | ||
68 | return arcs_cmdline; | ||
69 | } | ||
70 | |||
diff --git a/arch/mips/nxp/pnx833x/common/reset.c b/arch/mips/nxp/pnx833x/common/reset.c new file mode 100644 index 000000000000..a9bc9bacad2b --- /dev/null +++ b/arch/mips/nxp/pnx833x/common/reset.c | |||
@@ -0,0 +1,45 @@ | |||
1 | /* | ||
2 | * reset.c: reset support for PNX833X. | ||
3 | * | ||
4 | * Copyright 2008 NXP Semiconductors | ||
5 | * Chris Steel <chris.steel@nxp.com> | ||
6 | * Daniel Laird <daniel.j.laird@nxp.com> | ||
7 | * | ||
8 | * Based on software written by: | ||
9 | * Nikita Youshchenko <yoush@debian.org>, based on PNX8550 code. | ||
10 | * | ||
11 | * This program is free software; you can redistribute it and/or modify | ||
12 | * it under the terms of the GNU General Public License as published by | ||
13 | * the Free Software Foundation; either version 2 of the License, or | ||
14 | * (at your option) any later version. | ||
15 | * | ||
16 | * This program is distributed in the hope that it will be useful, | ||
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
19 | * GNU General Public License for more details. | ||
20 | * | ||
21 | * You should have received a copy of the GNU General Public License | ||
22 | * along with this program; if not, write to the Free Software | ||
23 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
24 | */ | ||
25 | #include <linux/slab.h> | ||
26 | #include <linux/reboot.h> | ||
27 | #include <pnx833x.h> | ||
28 | |||
29 | void pnx833x_machine_restart(char *command) | ||
30 | { | ||
31 | PNX833X_RESET_CONTROL_2 = 0; | ||
32 | PNX833X_RESET_CONTROL = 0; | ||
33 | } | ||
34 | |||
35 | void pnx833x_machine_halt(void) | ||
36 | { | ||
37 | while (1) | ||
38 | __asm__ __volatile__ ("wait"); | ||
39 | |||
40 | } | ||
41 | |||
42 | void pnx833x_machine_power_off(void) | ||
43 | { | ||
44 | pnx833x_machine_halt(); | ||
45 | } | ||
diff --git a/arch/mips/nxp/pnx833x/common/setup.c b/arch/mips/nxp/pnx833x/common/setup.c new file mode 100644 index 000000000000..e51fbc4b644d --- /dev/null +++ b/arch/mips/nxp/pnx833x/common/setup.c | |||
@@ -0,0 +1,64 @@ | |||
1 | /* | ||
2 | * setup.c: Setup PNX833X Soc. | ||
3 | * | ||
4 | * Copyright 2008 NXP Semiconductors | ||
5 | * Chris Steel <chris.steel@nxp.com> | ||
6 | * Daniel Laird <daniel.j.laird@nxp.com> | ||
7 | * | ||
8 | * Based on software written by: | ||
9 | * Nikita Youshchenko <yoush@debian.org>, based on PNX8550 code. | ||
10 | * | ||
11 | * This program is free software; you can redistribute it and/or modify | ||
12 | * it under the terms of the GNU General Public License as published by | ||
13 | * the Free Software Foundation; either version 2 of the License, or | ||
14 | * (at your option) any later version. | ||
15 | * | ||
16 | * This program is distributed in the hope that it will be useful, | ||
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
19 | * GNU General Public License for more details. | ||
20 | * | ||
21 | * You should have received a copy of the GNU General Public License | ||
22 | * along with this program; if not, write to the Free Software | ||
23 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
24 | */ | ||
25 | #include <linux/init.h> | ||
26 | #include <linux/interrupt.h> | ||
27 | #include <linux/ioport.h> | ||
28 | #include <linux/io.h> | ||
29 | #include <linux/pci.h> | ||
30 | #include <asm/reboot.h> | ||
31 | #include <pnx833x.h> | ||
32 | #include <gpio.h> | ||
33 | |||
34 | extern void pnx833x_board_setup(void); | ||
35 | extern void pnx833x_machine_restart(char *); | ||
36 | extern void pnx833x_machine_halt(void); | ||
37 | extern void pnx833x_machine_power_off(void); | ||
38 | |||
39 | int __init plat_mem_setup(void) | ||
40 | { | ||
41 | /* fake pci bus to avoid bounce buffers */ | ||
42 | PCI_DMA_BUS_IS_PHYS = 1; | ||
43 | |||
44 | /* set mips clock to 320MHz */ | ||
45 | #if defined(CONFIG_SOC_PNX8335) | ||
46 | PNX8335_WRITEFIELD(0x17, CLOCK_PLL_CPU_CTL, FREQ); | ||
47 | #endif | ||
48 | pnx833x_gpio_init(); /* so it will be ready in board_setup() */ | ||
49 | |||
50 | pnx833x_board_setup(); | ||
51 | |||
52 | _machine_restart = pnx833x_machine_restart; | ||
53 | _machine_halt = pnx833x_machine_halt; | ||
54 | pm_power_off = pnx833x_machine_power_off; | ||
55 | |||
56 | /* IO/MEM resources. */ | ||
57 | set_io_port_base(KSEG1); | ||
58 | ioport_resource.start = 0; | ||
59 | ioport_resource.end = ~0; | ||
60 | iomem_resource.start = 0; | ||
61 | iomem_resource.end = ~0; | ||
62 | |||
63 | return 0; | ||
64 | } | ||
diff --git a/arch/mips/nxp/pnx833x/stb22x/Makefile b/arch/mips/nxp/pnx833x/stb22x/Makefile new file mode 100644 index 000000000000..f81c5801f455 --- /dev/null +++ b/arch/mips/nxp/pnx833x/stb22x/Makefile | |||
@@ -0,0 +1,3 @@ | |||
1 | lib-y := board.o | ||
2 | |||
3 | EXTRA_CFLAGS += -Werror | ||
diff --git a/arch/mips/nxp/pnx833x/stb22x/board.c b/arch/mips/nxp/pnx833x/stb22x/board.c new file mode 100644 index 000000000000..90cc604bdadf --- /dev/null +++ b/arch/mips/nxp/pnx833x/stb22x/board.c | |||
@@ -0,0 +1,133 @@ | |||
1 | /* | ||
2 | * board.c: STB225 board support. | ||
3 | * | ||
4 | * Copyright 2008 NXP Semiconductors | ||
5 | * Chris Steel <chris.steel@nxp.com> | ||
6 | * Daniel Laird <daniel.j.laird@nxp.com> | ||
7 | * | ||
8 | * Based on software written by: | ||
9 | * Nikita Youshchenko <yoush@debian.org>, based on PNX8550 code. | ||
10 | * | ||
11 | * This program is free software; you can redistribute it and/or modify | ||
12 | * it under the terms of the GNU General Public License as published by | ||
13 | * the Free Software Foundation; either version 2 of the License, or | ||
14 | * (at your option) any later version. | ||
15 | * | ||
16 | * This program is distributed in the hope that it will be useful, | ||
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
19 | * GNU General Public License for more details. | ||
20 | * | ||
21 | * You should have received a copy of the GNU General Public License | ||
22 | * along with this program; if not, write to the Free Software | ||
23 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
24 | */ | ||
25 | #include <linux/init.h> | ||
26 | #include <asm/bootinfo.h> | ||
27 | #include <linux/mm.h> | ||
28 | #include <pnx833x.h> | ||
29 | #include <gpio.h> | ||
30 | |||
31 | /* endianess twiddlers */ | ||
32 | #define PNX8335_DEBUG0 0x4400 | ||
33 | #define PNX8335_DEBUG1 0x4404 | ||
34 | #define PNX8335_DEBUG2 0x4408 | ||
35 | #define PNX8335_DEBUG3 0x440c | ||
36 | #define PNX8335_DEBUG4 0x4410 | ||
37 | #define PNX8335_DEBUG5 0x4414 | ||
38 | #define PNX8335_DEBUG6 0x4418 | ||
39 | #define PNX8335_DEBUG7 0x441c | ||
40 | |||
41 | int prom_argc; | ||
42 | char **prom_argv = 0, **prom_envp = 0; | ||
43 | |||
44 | extern void prom_init_cmdline(void); | ||
45 | extern char *prom_getenv(char *envname); | ||
46 | |||
47 | const char *get_system_type(void) | ||
48 | { | ||
49 | return "NXP STB22x"; | ||
50 | } | ||
51 | |||
52 | static inline unsigned long env_or_default(char *env, unsigned long dfl) | ||
53 | { | ||
54 | char *str = prom_getenv(env); | ||
55 | return str ? simple_strtol(str, 0, 0) : dfl; | ||
56 | } | ||
57 | |||
58 | void __init prom_init(void) | ||
59 | { | ||
60 | unsigned long memsize; | ||
61 | |||
62 | prom_argc = fw_arg0; | ||
63 | prom_argv = (char **)fw_arg1; | ||
64 | prom_envp = (char **)fw_arg2; | ||
65 | |||
66 | prom_init_cmdline(); | ||
67 | |||
68 | memsize = env_or_default("memsize", 0x02000000); | ||
69 | add_memory_region(0, memsize, BOOT_MEM_RAM); | ||
70 | } | ||
71 | |||
72 | void __init pnx833x_board_setup(void) | ||
73 | { | ||
74 | pnx833x_gpio_select_function_alt(4); | ||
75 | pnx833x_gpio_select_output(4); | ||
76 | pnx833x_gpio_select_function_alt(5); | ||
77 | pnx833x_gpio_select_input(5); | ||
78 | pnx833x_gpio_select_function_alt(6); | ||
79 | pnx833x_gpio_select_input(6); | ||
80 | pnx833x_gpio_select_function_alt(7); | ||
81 | pnx833x_gpio_select_output(7); | ||
82 | |||
83 | pnx833x_gpio_select_function_alt(25); | ||
84 | pnx833x_gpio_select_function_alt(26); | ||
85 | |||
86 | pnx833x_gpio_select_function_alt(27); | ||
87 | pnx833x_gpio_select_function_alt(28); | ||
88 | pnx833x_gpio_select_function_alt(29); | ||
89 | pnx833x_gpio_select_function_alt(30); | ||
90 | pnx833x_gpio_select_function_alt(31); | ||
91 | pnx833x_gpio_select_function_alt(32); | ||
92 | pnx833x_gpio_select_function_alt(33); | ||
93 | |||
94 | #if defined(CONFIG_MTD_NAND_PLATFORM) || defined(CONFIG_MTD_NAND_PLATFORM_MODULE) | ||
95 | /* Setup MIU for NAND access on CS0... | ||
96 | * | ||
97 | * (it seems that we must also configure CS1 for reliable operation, | ||
98 | * otherwise the first read ID command will fail if it's read as 4 bytes | ||
99 | * but pass if it's read as 1 word.) | ||
100 | */ | ||
101 | |||
102 | /* Setup MIU CS0 & CS1 timing */ | ||
103 | PNX833X_MIU_SEL0 = 0; | ||
104 | PNX833X_MIU_SEL1 = 0; | ||
105 | PNX833X_MIU_SEL0_TIMING = 0x50003081; | ||
106 | PNX833X_MIU_SEL1_TIMING = 0x50003081; | ||
107 | |||
108 | /* Setup GPIO 00 for use as MIU CS1 (CS0 is not multiplexed, so does not need this) */ | ||
109 | pnx833x_gpio_select_function_alt(0); | ||
110 | |||
111 | /* Setup GPIO 04 to input NAND read/busy signal */ | ||
112 | pnx833x_gpio_select_function_io(4); | ||
113 | pnx833x_gpio_select_input(4); | ||
114 | |||
115 | /* Setup GPIO 05 to disable NAND write protect */ | ||
116 | pnx833x_gpio_select_function_io(5); | ||
117 | pnx833x_gpio_select_output(5); | ||
118 | pnx833x_gpio_write(1, 5); | ||
119 | |||
120 | #elif defined(CONFIG_MTD_CFI) || defined(CONFIG_MTD_CFI_MODULE) | ||
121 | |||
122 | /* Set up MIU for 16-bit NOR access on CS0 and CS1... */ | ||
123 | |||
124 | /* Setup MIU CS0 & CS1 timing */ | ||
125 | PNX833X_MIU_SEL0 = 1; | ||
126 | PNX833X_MIU_SEL1 = 1; | ||
127 | PNX833X_MIU_SEL0_TIMING = 0x6A08D082; | ||
128 | PNX833X_MIU_SEL1_TIMING = 0x6A08D082; | ||
129 | |||
130 | /* Setup GPIO 00 for use as MIU CS1 (CS0 is not multiplexed, so does not need this) */ | ||
131 | pnx833x_gpio_select_function_alt(0); | ||
132 | #endif | ||
133 | } | ||
diff --git a/arch/mips/pci/Makefile b/arch/mips/pci/Makefile index b1886244cedf..e8a97f59e066 100644 --- a/arch/mips/pci/Makefile +++ b/arch/mips/pci/Makefile | |||
@@ -13,7 +13,7 @@ obj-$(CONFIG_MIPS_MSC) += ops-msc.o | |||
13 | obj-$(CONFIG_MIPS_NILE4) += ops-nile4.o | 13 | obj-$(CONFIG_MIPS_NILE4) += ops-nile4.o |
14 | obj-$(CONFIG_SOC_TX3927) += ops-tx3927.o | 14 | obj-$(CONFIG_SOC_TX3927) += ops-tx3927.o |
15 | obj-$(CONFIG_PCI_VR41XX) += ops-vr41xx.o pci-vr41xx.o | 15 | obj-$(CONFIG_PCI_VR41XX) += ops-vr41xx.o pci-vr41xx.o |
16 | obj-$(CONFIG_MARKEINS) += ops-emma2rh.o pci-emma2rh.o fixup-emma2rh.o | 16 | obj-$(CONFIG_NEC_MARKEINS) += ops-emma2rh.o pci-emma2rh.o fixup-emma2rh.o |
17 | obj-$(CONFIG_PCI_TX4927) += ops-tx4927.o | 17 | obj-$(CONFIG_PCI_TX4927) += ops-tx4927.o |
18 | obj-$(CONFIG_BCM47XX) += pci-bcm47xx.o | 18 | obj-$(CONFIG_BCM47XX) += pci-bcm47xx.o |
19 | 19 | ||
diff --git a/arch/mips/pci/fixup-emma2rh.c b/arch/mips/pci/fixup-emma2rh.c index 846eae9cdd05..fba5aad00d51 100644 --- a/arch/mips/pci/fixup-emma2rh.c +++ b/arch/mips/pci/fixup-emma2rh.c | |||
@@ -30,7 +30,7 @@ | |||
30 | 30 | ||
31 | #include <asm/bootinfo.h> | 31 | #include <asm/bootinfo.h> |
32 | 32 | ||
33 | #include <asm/emma2rh/emma2rh.h> | 33 | #include <asm/emma/emma2rh.h> |
34 | 34 | ||
35 | #define EMMA2RH_PCI_HOST_SLOT 0x09 | 35 | #define EMMA2RH_PCI_HOST_SLOT 0x09 |
36 | #define EMMA2RH_USB_SLOT 0x03 | 36 | #define EMMA2RH_USB_SLOT 0x03 |
diff --git a/arch/mips/pci/fixup-rc32434.c b/arch/mips/pci/fixup-rc32434.c index 75b90dcb7a09..3d86823d03a0 100644 --- a/arch/mips/pci/fixup-rc32434.c +++ b/arch/mips/pci/fixup-rc32434.c | |||
@@ -30,6 +30,7 @@ | |||
30 | #include <linux/init.h> | 30 | #include <linux/init.h> |
31 | 31 | ||
32 | #include <asm/mach-rc32434/rc32434.h> | 32 | #include <asm/mach-rc32434/rc32434.h> |
33 | #include <asm/mach-rc32434/irq.h> | ||
33 | 34 | ||
34 | static int __devinitdata irq_map[2][12] = { | 35 | static int __devinitdata irq_map[2][12] = { |
35 | {0, 0, 2, 3, 2, 3, 0, 0, 0, 0, 0, 1}, | 36 | {0, 0, 2, 3, 2, 3, 0, 0, 0, 0, 0, 1}, |
diff --git a/arch/mips/pci/ops-emma2rh.c b/arch/mips/pci/ops-emma2rh.c index d31bfc6d4150..5947a70b0b7f 100644 --- a/arch/mips/pci/ops-emma2rh.c +++ b/arch/mips/pci/ops-emma2rh.c | |||
@@ -30,7 +30,7 @@ | |||
30 | #include <asm/addrspace.h> | 30 | #include <asm/addrspace.h> |
31 | #include <asm/debug.h> | 31 | #include <asm/debug.h> |
32 | 32 | ||
33 | #include <asm/emma2rh/emma2rh.h> | 33 | #include <asm/emma/emma2rh.h> |
34 | 34 | ||
35 | #define RTABORT (0x1<<9) | 35 | #define RTABORT (0x1<<9) |
36 | #define RMABORT (0x1<<10) | 36 | #define RMABORT (0x1<<10) |
diff --git a/arch/mips/pci/pci-emma2rh.c b/arch/mips/pci/pci-emma2rh.c index 772e283daa63..2df4190232cd 100644 --- a/arch/mips/pci/pci-emma2rh.c +++ b/arch/mips/pci/pci-emma2rh.c | |||
@@ -30,7 +30,7 @@ | |||
30 | 30 | ||
31 | #include <asm/bootinfo.h> | 31 | #include <asm/bootinfo.h> |
32 | 32 | ||
33 | #include <asm/emma2rh/emma2rh.h> | 33 | #include <asm/emma/emma2rh.h> |
34 | 34 | ||
35 | static struct resource pci_io_resource = { | 35 | static struct resource pci_io_resource = { |
36 | .name = "pci IO space", | 36 | .name = "pci IO space", |
diff --git a/arch/mips/rb532/devices.c b/arch/mips/rb532/devices.c index 31619c601b11..2f22d714d5b0 100644 --- a/arch/mips/rb532/devices.c +++ b/arch/mips/rb532/devices.c | |||
@@ -280,7 +280,7 @@ static int __init plat_setup_devices(void) | |||
280 | { | 280 | { |
281 | /* Look for the CF card reader */ | 281 | /* Look for the CF card reader */ |
282 | if (!readl(IDT434_REG_BASE + DEV1MASK)) | 282 | if (!readl(IDT434_REG_BASE + DEV1MASK)) |
283 | rb532_devs[1] = NULL; | 283 | rb532_devs[2] = NULL; /* disable cf_slot0 at index 2 */ |
284 | else { | 284 | else { |
285 | cf_slot0_res[0].start = | 285 | cf_slot0_res[0].start = |
286 | readl(IDT434_REG_BASE + DEV1BASE); | 286 | readl(IDT434_REG_BASE + DEV1BASE); |
diff --git a/arch/mips/rb532/gpio.c b/arch/mips/rb532/gpio.c index 76a7fd96d564..70c4a6726377 100644 --- a/arch/mips/rb532/gpio.c +++ b/arch/mips/rb532/gpio.c | |||
@@ -310,6 +310,10 @@ int __init rb532_gpio_init(void) | |||
310 | return -ENXIO; | 310 | return -ENXIO; |
311 | } | 311 | } |
312 | 312 | ||
313 | /* Set the interrupt status and level for the CF pin */ | ||
314 | rb532_gpio_set_int_level(&rb532_gpio_chip->chip, CF_GPIO_NUM, 1); | ||
315 | rb532_gpio_set_int_status(&rb532_gpio_chip->chip, CF_GPIO_NUM, 0); | ||
316 | |||
313 | return 0; | 317 | return 0; |
314 | } | 318 | } |
315 | arch_initcall(rb532_gpio_init); | 319 | arch_initcall(rb532_gpio_init); |
diff --git a/arch/mips/sgi-ip22/ip22-int.c b/arch/mips/sgi-ip22/ip22-int.c index f6d9bf4b26e7..f8b18af141a1 100644 --- a/arch/mips/sgi-ip22/ip22-int.c +++ b/arch/mips/sgi-ip22/ip22-int.c | |||
@@ -12,20 +12,11 @@ | |||
12 | #include <linux/types.h> | 12 | #include <linux/types.h> |
13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
14 | #include <linux/kernel_stat.h> | 14 | #include <linux/kernel_stat.h> |
15 | #include <linux/signal.h> | ||
16 | #include <linux/sched.h> | ||
17 | #include <linux/interrupt.h> | 15 | #include <linux/interrupt.h> |
18 | #include <linux/irq.h> | ||
19 | 16 | ||
20 | #include <asm/mipsregs.h> | ||
21 | #include <asm/addrspace.h> | ||
22 | #include <asm/irq_cpu.h> | 17 | #include <asm/irq_cpu.h> |
23 | #include <asm/sgi/ioc.h> | ||
24 | #include <asm/sgi/hpc3.h> | 18 | #include <asm/sgi/hpc3.h> |
25 | #include <asm/sgi/ip22.h> | 19 | #include <asm/sgi/ip22.h> |
26 | #include <asm/time.h> | ||
27 | |||
28 | /* #define DEBUG_SGINT */ | ||
29 | 20 | ||
30 | /* So far nothing hangs here */ | 21 | /* So far nothing hangs here */ |
31 | #undef USE_LIO3_IRQ | 22 | #undef USE_LIO3_IRQ |
@@ -68,7 +59,7 @@ static void enable_local1_irq(unsigned int irq) | |||
68 | sgint->imask1 |= (1 << (irq - SGINT_LOCAL1)); | 59 | sgint->imask1 |= (1 << (irq - SGINT_LOCAL1)); |
69 | } | 60 | } |
70 | 61 | ||
71 | void disable_local1_irq(unsigned int irq) | 62 | static void disable_local1_irq(unsigned int irq) |
72 | { | 63 | { |
73 | sgint->imask1 &= ~(1 << (irq - SGINT_LOCAL1)); | 64 | sgint->imask1 &= ~(1 << (irq - SGINT_LOCAL1)); |
74 | } | 65 | } |
@@ -87,7 +78,7 @@ static void enable_local2_irq(unsigned int irq) | |||
87 | sgint->cmeimask0 |= (1 << (irq - SGINT_LOCAL2)); | 78 | sgint->cmeimask0 |= (1 << (irq - SGINT_LOCAL2)); |
88 | } | 79 | } |
89 | 80 | ||
90 | void disable_local2_irq(unsigned int irq) | 81 | static void disable_local2_irq(unsigned int irq) |
91 | { | 82 | { |
92 | sgint->cmeimask0 &= ~(1 << (irq - SGINT_LOCAL2)); | 83 | sgint->cmeimask0 &= ~(1 << (irq - SGINT_LOCAL2)); |
93 | if (!sgint->cmeimask0) | 84 | if (!sgint->cmeimask0) |
@@ -108,7 +99,7 @@ static void enable_local3_irq(unsigned int irq) | |||
108 | sgint->cmeimask1 |= (1 << (irq - SGINT_LOCAL3)); | 99 | sgint->cmeimask1 |= (1 << (irq - SGINT_LOCAL3)); |
109 | } | 100 | } |
110 | 101 | ||
111 | void disable_local3_irq(unsigned int irq) | 102 | static void disable_local3_irq(unsigned int irq) |
112 | { | 103 | { |
113 | sgint->cmeimask1 &= ~(1 << (irq - SGINT_LOCAL3)); | 104 | sgint->cmeimask1 &= ~(1 << (irq - SGINT_LOCAL3)); |
114 | if (!sgint->cmeimask1) | 105 | if (!sgint->cmeimask1) |
@@ -344,6 +335,6 @@ void __init arch_init_irq(void) | |||
344 | 335 | ||
345 | #ifdef CONFIG_EISA | 336 | #ifdef CONFIG_EISA |
346 | if (ip22_is_fullhouse()) /* Only Indigo-2 has EISA stuff */ | 337 | if (ip22_is_fullhouse()) /* Only Indigo-2 has EISA stuff */ |
347 | ip22_eisa_init(); | 338 | ip22_eisa_init(); |
348 | #endif | 339 | #endif |
349 | } | 340 | } |
diff --git a/arch/mips/txx9/Kconfig b/arch/mips/txx9/Kconfig index 17052db4161d..226e8bb2f0a1 100644 --- a/arch/mips/txx9/Kconfig +++ b/arch/mips/txx9/Kconfig | |||
@@ -46,9 +46,10 @@ config TOSHIBA_RBTX4938 | |||
46 | support this machine type | 46 | support this machine type |
47 | 47 | ||
48 | config TOSHIBA_RBTX4939 | 48 | config TOSHIBA_RBTX4939 |
49 | bool "Toshiba RBTX4939 bobard" | 49 | bool "Toshiba RBTX4939 board" |
50 | depends on MACH_TX49XX | 50 | depends on MACH_TX49XX |
51 | select SOC_TX4939 | 51 | select SOC_TX4939 |
52 | select TXX9_7SEGLED | ||
52 | help | 53 | help |
53 | This Toshiba board is based on the TX4939 processor. Say Y here to | 54 | This Toshiba board is based on the TX4939 processor. Say Y here to |
54 | support this machine type | 55 | support this machine type |
@@ -86,6 +87,9 @@ config SOC_TX4939 | |||
86 | select HW_HAS_PCI | 87 | select HW_HAS_PCI |
87 | select PCI_TX4927 | 88 | select PCI_TX4927 |
88 | 89 | ||
90 | config TXX9_7SEGLED | ||
91 | bool | ||
92 | |||
89 | config TOSHIBA_FPCIB0 | 93 | config TOSHIBA_FPCIB0 |
90 | bool "FPCIB0 Backplane Support" | 94 | bool "FPCIB0 Backplane Support" |
91 | depends on PCI && MACH_TXX9 | 95 | depends on PCI && MACH_TXX9 |
diff --git a/arch/mips/txx9/generic/7segled.c b/arch/mips/txx9/generic/7segled.c new file mode 100644 index 000000000000..727ab21b6618 --- /dev/null +++ b/arch/mips/txx9/generic/7segled.c | |||
@@ -0,0 +1,112 @@ | |||
1 | /* | ||
2 | * 7 Segment LED routines | ||
3 | * Based on RBTX49xx patch from CELF patch archive. | ||
4 | * | ||
5 | * This file is subject to the terms and conditions of the GNU General Public | ||
6 | * License. See the file "COPYING" in the main directory of this archive | ||
7 | * for more details. | ||
8 | * | ||
9 | * (C) Copyright TOSHIBA CORPORATION 2005-2007 | ||
10 | * All Rights Reserved. | ||
11 | */ | ||
12 | #include <linux/sysdev.h> | ||
13 | #include <linux/slab.h> | ||
14 | #include <linux/map_to_7segment.h> | ||
15 | #include <asm/txx9/generic.h> | ||
16 | |||
17 | static unsigned int tx_7segled_num; | ||
18 | static void (*tx_7segled_putc)(unsigned int pos, unsigned char val); | ||
19 | |||
20 | void __init txx9_7segled_init(unsigned int num, | ||
21 | void (*putc)(unsigned int pos, unsigned char val)) | ||
22 | { | ||
23 | tx_7segled_num = num; | ||
24 | tx_7segled_putc = putc; | ||
25 | } | ||
26 | |||
27 | static SEG7_CONVERSION_MAP(txx9_seg7map, MAP_ASCII7SEG_ALPHANUM_LC); | ||
28 | |||
29 | int txx9_7segled_putc(unsigned int pos, char c) | ||
30 | { | ||
31 | if (pos >= tx_7segled_num) | ||
32 | return -EINVAL; | ||
33 | c = map_to_seg7(&txx9_seg7map, c); | ||
34 | if (c < 0) | ||
35 | return c; | ||
36 | tx_7segled_putc(pos, c); | ||
37 | return 0; | ||
38 | } | ||
39 | |||
40 | static ssize_t ascii_store(struct sys_device *dev, | ||
41 | struct sysdev_attribute *attr, | ||
42 | const char *buf, size_t size) | ||
43 | { | ||
44 | unsigned int ch = dev->id; | ||
45 | txx9_7segled_putc(ch, buf[0]); | ||
46 | return size; | ||
47 | } | ||
48 | |||
49 | static ssize_t raw_store(struct sys_device *dev, | ||
50 | struct sysdev_attribute *attr, | ||
51 | const char *buf, size_t size) | ||
52 | { | ||
53 | unsigned int ch = dev->id; | ||
54 | tx_7segled_putc(ch, buf[0]); | ||
55 | return size; | ||
56 | } | ||
57 | |||
58 | static SYSDEV_ATTR(ascii, 0200, NULL, ascii_store); | ||
59 | static SYSDEV_ATTR(raw, 0200, NULL, raw_store); | ||
60 | |||
61 | static ssize_t map_seg7_show(struct sysdev_class *class, char *buf) | ||
62 | { | ||
63 | memcpy(buf, &txx9_seg7map, sizeof(txx9_seg7map)); | ||
64 | return sizeof(txx9_seg7map); | ||
65 | } | ||
66 | |||
67 | static ssize_t map_seg7_store(struct sysdev_class *class, | ||
68 | const char *buf, size_t size) | ||
69 | { | ||
70 | if (size != sizeof(txx9_seg7map)) | ||
71 | return -EINVAL; | ||
72 | memcpy(&txx9_seg7map, buf, size); | ||
73 | return size; | ||
74 | } | ||
75 | |||
76 | static SYSDEV_CLASS_ATTR(map_seg7, 0600, map_seg7_show, map_seg7_store); | ||
77 | |||
78 | static struct sysdev_class tx_7segled_sysdev_class = { | ||
79 | .name = "7segled", | ||
80 | }; | ||
81 | |||
82 | static int __init tx_7segled_init_sysfs(void) | ||
83 | { | ||
84 | int error, i; | ||
85 | if (!tx_7segled_num) | ||
86 | return -ENODEV; | ||
87 | error = sysdev_class_register(&tx_7segled_sysdev_class); | ||
88 | if (error) | ||
89 | return error; | ||
90 | error = sysdev_class_create_file(&tx_7segled_sysdev_class, | ||
91 | &attr_map_seg7); | ||
92 | if (error) | ||
93 | return error; | ||
94 | for (i = 0; i < tx_7segled_num; i++) { | ||
95 | struct sys_device *dev; | ||
96 | dev = kzalloc(sizeof(*dev), GFP_KERNEL); | ||
97 | if (!dev) { | ||
98 | error = -ENODEV; | ||
99 | break; | ||
100 | } | ||
101 | dev->id = i; | ||
102 | dev->cls = &tx_7segled_sysdev_class; | ||
103 | error = sysdev_register(dev); | ||
104 | if (!error) { | ||
105 | sysdev_create_file(dev, &attr_ascii); | ||
106 | sysdev_create_file(dev, &attr_raw); | ||
107 | } | ||
108 | } | ||
109 | return error; | ||
110 | } | ||
111 | |||
112 | device_initcall(tx_7segled_init_sysfs); | ||
diff --git a/arch/mips/txx9/generic/Makefile b/arch/mips/txx9/generic/Makefile index 0030d23bef5b..f2579ce054a1 100644 --- a/arch/mips/txx9/generic/Makefile +++ b/arch/mips/txx9/generic/Makefile | |||
@@ -10,5 +10,6 @@ obj-$(CONFIG_SOC_TX4938) += mem_tx4927.o setup_tx4938.o irq_tx4938.o | |||
10 | obj-$(CONFIG_SOC_TX4939) += setup_tx4939.o irq_tx4939.o | 10 | obj-$(CONFIG_SOC_TX4939) += setup_tx4939.o irq_tx4939.o |
11 | obj-$(CONFIG_TOSHIBA_FPCIB0) += smsc_fdc37m81x.o | 11 | obj-$(CONFIG_TOSHIBA_FPCIB0) += smsc_fdc37m81x.o |
12 | obj-$(CONFIG_SPI) += spi_eeprom.o | 12 | obj-$(CONFIG_SPI) += spi_eeprom.o |
13 | obj-$(CONFIG_TXX9_7SEGLED) += 7segled.o | ||
13 | 14 | ||
14 | EXTRA_CFLAGS += -Werror | 15 | EXTRA_CFLAGS += -Werror |
diff --git a/arch/mips/txx9/generic/setup.c b/arch/mips/txx9/generic/setup.c index 5526375010f8..a13a08b8c9ec 100644 --- a/arch/mips/txx9/generic/setup.c +++ b/arch/mips/txx9/generic/setup.c | |||
@@ -156,11 +156,23 @@ static struct txx9_board_vec *__init find_board_byname(const char *name) | |||
156 | 156 | ||
157 | static void __init prom_init_cmdline(void) | 157 | static void __init prom_init_cmdline(void) |
158 | { | 158 | { |
159 | int argc = (int)fw_arg0; | 159 | int argc; |
160 | int *argv32 = (int *)fw_arg1; | 160 | int *argv32; |
161 | int i; /* Always ignore the "-c" at argv[0] */ | 161 | int i; /* Always ignore the "-c" at argv[0] */ |
162 | char builtin[CL_SIZE]; | 162 | char builtin[CL_SIZE]; |
163 | 163 | ||
164 | if (fw_arg0 >= CKSEG0 || fw_arg1 < CKSEG0) { | ||
165 | /* | ||
166 | * argc is not a valid number, or argv32 is not a valid | ||
167 | * pointer | ||
168 | */ | ||
169 | argc = 0; | ||
170 | argv32 = NULL; | ||
171 | } else { | ||
172 | argc = (int)fw_arg0; | ||
173 | argv32 = (int *)fw_arg1; | ||
174 | } | ||
175 | |||
164 | /* ignore all built-in args if any f/w args given */ | 176 | /* ignore all built-in args if any f/w args given */ |
165 | /* | 177 | /* |
166 | * But if built-in strings was started with '+', append them | 178 | * But if built-in strings was started with '+', append them |
@@ -414,10 +426,12 @@ char * __init prom_getcmdline(void) | |||
414 | 426 | ||
415 | const char *__init prom_getenv(const char *name) | 427 | const char *__init prom_getenv(const char *name) |
416 | { | 428 | { |
417 | const s32 *str = (const s32 *)fw_arg2; | 429 | const s32 *str; |
418 | 430 | ||
419 | if (!str) | 431 | if (fw_arg2 < CKSEG0) |
420 | return NULL; | 432 | return NULL; |
433 | |||
434 | str = (const s32 *)fw_arg2; | ||
421 | /* YAMON style ("name", "value" pairs) */ | 435 | /* YAMON style ("name", "value" pairs) */ |
422 | while (str[0] && str[1]) { | 436 | while (str[0] && str[1]) { |
423 | if (!strcmp((const char *)(unsigned long)str[0], name)) | 437 | if (!strcmp((const char *)(unsigned long)str[0], name)) |
@@ -622,6 +636,21 @@ unsigned long (*__swizzle_addr_b)(unsigned long port) = __swizzle_addr_none; | |||
622 | EXPORT_SYMBOL(__swizzle_addr_b); | 636 | EXPORT_SYMBOL(__swizzle_addr_b); |
623 | #endif | 637 | #endif |
624 | 638 | ||
639 | #ifdef NEEDS_TXX9_IOSWABW | ||
640 | static u16 ioswabw_default(volatile u16 *a, u16 x) | ||
641 | { | ||
642 | return le16_to_cpu(x); | ||
643 | } | ||
644 | static u16 __mem_ioswabw_default(volatile u16 *a, u16 x) | ||
645 | { | ||
646 | return x; | ||
647 | } | ||
648 | u16 (*ioswabw)(volatile u16 *a, u16 x) = ioswabw_default; | ||
649 | EXPORT_SYMBOL(ioswabw); | ||
650 | u16 (*__mem_ioswabw)(volatile u16 *a, u16 x) = __mem_ioswabw_default; | ||
651 | EXPORT_SYMBOL(__mem_ioswabw); | ||
652 | #endif | ||
653 | |||
625 | void __init txx9_physmap_flash_init(int no, unsigned long addr, | 654 | void __init txx9_physmap_flash_init(int no, unsigned long addr, |
626 | unsigned long size, | 655 | unsigned long size, |
627 | const struct physmap_flash_data *pdata) | 656 | const struct physmap_flash_data *pdata) |
diff --git a/arch/mips/txx9/generic/setup_tx4938.c b/arch/mips/txx9/generic/setup_tx4938.c index af724e53ef91..25819ff1c350 100644 --- a/arch/mips/txx9/generic/setup_tx4938.c +++ b/arch/mips/txx9/generic/setup_tx4938.c | |||
@@ -16,6 +16,7 @@ | |||
16 | #include <linux/param.h> | 16 | #include <linux/param.h> |
17 | #include <linux/ptrace.h> | 17 | #include <linux/ptrace.h> |
18 | #include <linux/mtd/physmap.h> | 18 | #include <linux/mtd/physmap.h> |
19 | #include <linux/platform_device.h> | ||
19 | #include <asm/reboot.h> | 20 | #include <asm/reboot.h> |
20 | #include <asm/traps.h> | 21 | #include <asm/traps.h> |
21 | #include <asm/txx9irq.h> | 22 | #include <asm/txx9irq.h> |
@@ -335,6 +336,52 @@ void __init tx4938_mtd_init(int ch) | |||
335 | txx9_physmap_flash_init(ch, start, size, &pdata); | 336 | txx9_physmap_flash_init(ch, start, size, &pdata); |
336 | } | 337 | } |
337 | 338 | ||
339 | void __init tx4938_ata_init(unsigned int irq, unsigned int shift, int tune) | ||
340 | { | ||
341 | struct platform_device *pdev; | ||
342 | struct resource res[] = { | ||
343 | { | ||
344 | /* .start and .end are filled in later */ | ||
345 | .flags = IORESOURCE_MEM, | ||
346 | }, { | ||
347 | .start = irq, | ||
348 | .flags = IORESOURCE_IRQ, | ||
349 | }, | ||
350 | }; | ||
351 | struct tx4938ide_platform_info pdata = { | ||
352 | .ioport_shift = shift, | ||
353 | /* | ||
354 | * The IDE driver should not change bus timings if other ISA | ||
355 | * devices existed. | ||
356 | */ | ||
357 | .gbus_clock = tune ? txx9_gbus_clock : 0, | ||
358 | }; | ||
359 | u64 ebccr; | ||
360 | int i; | ||
361 | |||
362 | if ((__raw_readq(&tx4938_ccfgptr->pcfg) & | ||
363 | (TX4938_PCFG_ATA_SEL | TX4938_PCFG_NDF_SEL)) | ||
364 | != TX4938_PCFG_ATA_SEL) | ||
365 | return; | ||
366 | for (i = 0; i < 8; i++) { | ||
367 | /* check EBCCRn.ISA, EBCCRn.BSZ, EBCCRn.ME */ | ||
368 | ebccr = __raw_readq(&tx4938_ebuscptr->cr[i]); | ||
369 | if ((ebccr & 0x00f00008) == 0x00e00008) | ||
370 | break; | ||
371 | } | ||
372 | if (i == 8) | ||
373 | return; | ||
374 | pdata.ebus_ch = i; | ||
375 | res[0].start = ((ebccr >> 48) << 20) + 0x10000; | ||
376 | res[0].end = res[0].start + 0x20000 - 1; | ||
377 | pdev = platform_device_alloc("tx4938ide", -1); | ||
378 | if (!pdev || | ||
379 | platform_device_add_resources(pdev, res, ARRAY_SIZE(res)) || | ||
380 | platform_device_add_data(pdev, &pdata, sizeof(pdata)) || | ||
381 | platform_device_add(pdev)) | ||
382 | platform_device_put(pdev); | ||
383 | } | ||
384 | |||
338 | static void __init tx4938_stop_unused_modules(void) | 385 | static void __init tx4938_stop_unused_modules(void) |
339 | { | 386 | { |
340 | __u64 pcfg, rst = 0, ckd = 0; | 387 | __u64 pcfg, rst = 0, ckd = 0; |
diff --git a/arch/mips/txx9/rbtx4938/setup.c b/arch/mips/txx9/rbtx4938/setup.c index e077cc4d3a59..547ff2920bf0 100644 --- a/arch/mips/txx9/rbtx4938/setup.c +++ b/arch/mips/txx9/rbtx4938/setup.c | |||
@@ -352,6 +352,7 @@ static void __init rbtx4938_device_init(void) | |||
352 | rbtx4938_ne_init(); | 352 | rbtx4938_ne_init(); |
353 | tx4938_wdt_init(); | 353 | tx4938_wdt_init(); |
354 | rbtx4938_mtd_init(); | 354 | rbtx4938_mtd_init(); |
355 | tx4938_ata_init(RBTX4938_IRQ_IOC_ATA, 0, 1); | ||
355 | txx9_iocled_init(RBTX4938_LED_ADDR - IO_BASE, -1, 8, 1, "green", NULL); | 356 | txx9_iocled_init(RBTX4938_LED_ADDR - IO_BASE, -1, 8, 1, "green", NULL); |
356 | } | 357 | } |
357 | 358 | ||
diff --git a/arch/mips/txx9/rbtx4939/setup.c b/arch/mips/txx9/rbtx4939/setup.c index 9855d7bccc20..6daee9b1cd5e 100644 --- a/arch/mips/txx9/rbtx4939/setup.c +++ b/arch/mips/txx9/rbtx4939/setup.c | |||
@@ -14,6 +14,8 @@ | |||
14 | #include <linux/types.h> | 14 | #include <linux/types.h> |
15 | #include <linux/platform_device.h> | 15 | #include <linux/platform_device.h> |
16 | #include <linux/leds.h> | 16 | #include <linux/leds.h> |
17 | #include <linux/interrupt.h> | ||
18 | #include <linux/smc91x.h> | ||
17 | #include <asm/reboot.h> | 19 | #include <asm/reboot.h> |
18 | #include <asm/txx9/generic.h> | 20 | #include <asm/txx9/generic.h> |
19 | #include <asm/txx9/pci.h> | 21 | #include <asm/txx9/pci.h> |
@@ -33,6 +35,21 @@ static void __init rbtx4939_time_init(void) | |||
33 | tx4939_time_init(0); | 35 | tx4939_time_init(0); |
34 | } | 36 | } |
35 | 37 | ||
38 | #if defined(__BIG_ENDIAN) && \ | ||
39 | (defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE)) | ||
40 | #define HAVE_RBTX4939_IOSWAB | ||
41 | #define IS_CE1_ADDR(addr) \ | ||
42 | ((((unsigned long)(addr) - IO_BASE) & 0xfff00000) == TXX9_CE(1)) | ||
43 | static u16 rbtx4939_ioswabw(volatile u16 *a, u16 x) | ||
44 | { | ||
45 | return IS_CE1_ADDR(a) ? x : le16_to_cpu(x); | ||
46 | } | ||
47 | static u16 rbtx4939_mem_ioswabw(volatile u16 *a, u16 x) | ||
48 | { | ||
49 | return !IS_CE1_ADDR(a) ? x : le16_to_cpu(x); | ||
50 | } | ||
51 | #endif /* __BIG_ENDIAN && CONFIG_SMC91X */ | ||
52 | |||
36 | static void __init rbtx4939_pci_setup(void) | 53 | static void __init rbtx4939_pci_setup(void) |
37 | { | 54 | { |
38 | #ifdef CONFIG_PCI | 55 | #ifdef CONFIG_PCI |
@@ -239,6 +256,32 @@ static inline void rbtx4939_led_setup(void) | |||
239 | } | 256 | } |
240 | #endif | 257 | #endif |
241 | 258 | ||
259 | static void __rbtx4939_7segled_putc(unsigned int pos, unsigned char val) | ||
260 | { | ||
261 | #if defined(CONFIG_LEDS_CLASS) || defined(CONFIG_LEDS_CLASS_MODULE) | ||
262 | unsigned long flags; | ||
263 | local_irq_save(flags); | ||
264 | /* bit7: reserved for LED class */ | ||
265 | led_val[pos] = (led_val[pos] & 0x80) | (val & 0x7f); | ||
266 | val = led_val[pos]; | ||
267 | local_irq_restore(flags); | ||
268 | #endif | ||
269 | writeb(val, rbtx4939_7seg_addr(pos / 4, pos % 4)); | ||
270 | } | ||
271 | |||
272 | static void rbtx4939_7segled_putc(unsigned int pos, unsigned char val) | ||
273 | { | ||
274 | /* convert from map_to_seg7() notation */ | ||
275 | val = (val & 0x88) | | ||
276 | ((val & 0x40) >> 6) | | ||
277 | ((val & 0x20) >> 4) | | ||
278 | ((val & 0x10) >> 2) | | ||
279 | ((val & 0x04) << 2) | | ||
280 | ((val & 0x02) << 4) | | ||
281 | ((val & 0x01) << 6); | ||
282 | __rbtx4939_7segled_putc(pos, val); | ||
283 | } | ||
284 | |||
242 | static void __init rbtx4939_arch_init(void) | 285 | static void __init rbtx4939_arch_init(void) |
243 | { | 286 | { |
244 | rbtx4939_pci_setup(); | 287 | rbtx4939_pci_setup(); |
@@ -246,6 +289,22 @@ static void __init rbtx4939_arch_init(void) | |||
246 | 289 | ||
247 | static void __init rbtx4939_device_init(void) | 290 | static void __init rbtx4939_device_init(void) |
248 | { | 291 | { |
292 | unsigned long smc_addr = RBTX4939_ETHER_ADDR - IO_BASE; | ||
293 | struct resource smc_res[] = { | ||
294 | { | ||
295 | .start = smc_addr, | ||
296 | .end = smc_addr + 0x10 - 1, | ||
297 | .flags = IORESOURCE_MEM, | ||
298 | }, { | ||
299 | .start = RBTX4939_IRQ_ETHER, | ||
300 | /* override default irq flag defined in smc91x.h */ | ||
301 | .flags = IORESOURCE_IRQ | IRQF_TRIGGER_LOW, | ||
302 | }, | ||
303 | }; | ||
304 | struct smc91x_platdata smc_pdata = { | ||
305 | .flags = SMC91X_USE_16BIT, | ||
306 | }; | ||
307 | struct platform_device *pdev; | ||
249 | #if defined(CONFIG_TC35815) || defined(CONFIG_TC35815_MODULE) | 308 | #if defined(CONFIG_TC35815) || defined(CONFIG_TC35815_MODULE) |
250 | int i, j; | 309 | int i, j; |
251 | unsigned char ethaddr[2][6]; | 310 | unsigned char ethaddr[2][6]; |
@@ -262,6 +321,12 @@ static void __init rbtx4939_device_init(void) | |||
262 | } | 321 | } |
263 | tx4939_ethaddr_init(ethaddr[0], ethaddr[1]); | 322 | tx4939_ethaddr_init(ethaddr[0], ethaddr[1]); |
264 | #endif | 323 | #endif |
324 | pdev = platform_device_alloc("smc91x", -1); | ||
325 | if (!pdev || | ||
326 | platform_device_add_resources(pdev, smc_res, ARRAY_SIZE(smc_res)) || | ||
327 | platform_device_add_data(pdev, &smc_pdata, sizeof(smc_pdata)) || | ||
328 | platform_device_add(pdev)) | ||
329 | platform_device_put(pdev); | ||
265 | rbtx4939_led_setup(); | 330 | rbtx4939_led_setup(); |
266 | tx4939_wdt_init(); | 331 | tx4939_wdt_init(); |
267 | tx4939_ata_init(); | 332 | tx4939_ata_init(); |
@@ -269,6 +334,8 @@ static void __init rbtx4939_device_init(void) | |||
269 | 334 | ||
270 | static void __init rbtx4939_setup(void) | 335 | static void __init rbtx4939_setup(void) |
271 | { | 336 | { |
337 | int i; | ||
338 | |||
272 | rbtx4939_ebusc_setup(); | 339 | rbtx4939_ebusc_setup(); |
273 | /* always enable ATA0 */ | 340 | /* always enable ATA0 */ |
274 | txx9_set64(&tx4939_ccfgptr->pcfg, TX4939_PCFG_ATA0MODE); | 341 | txx9_set64(&tx4939_ccfgptr->pcfg, TX4939_PCFG_ATA0MODE); |
@@ -276,9 +343,16 @@ static void __init rbtx4939_setup(void) | |||
276 | if (txx9_master_clock == 0) | 343 | if (txx9_master_clock == 0) |
277 | txx9_master_clock = 20000000; | 344 | txx9_master_clock = 20000000; |
278 | tx4939_setup(); | 345 | tx4939_setup(); |
346 | #ifdef HAVE_RBTX4939_IOSWAB | ||
347 | ioswabw = rbtx4939_ioswabw; | ||
348 | __mem_ioswabw = rbtx4939_mem_ioswabw; | ||
349 | #endif | ||
279 | 350 | ||
280 | _machine_restart = rbtx4939_machine_restart; | 351 | _machine_restart = rbtx4939_machine_restart; |
281 | 352 | ||
353 | txx9_7segled_init(RBTX4939_MAX_7SEGLEDS, rbtx4939_7segled_putc); | ||
354 | for (i = 0; i < RBTX4939_MAX_7SEGLEDS; i++) | ||
355 | txx9_7segled_putc(i, '-'); | ||
282 | pr_info("RBTX4939 (Rev %02x) --- FPGA(Rev %02x) DIPSW:%02x,%02x\n", | 356 | pr_info("RBTX4939 (Rev %02x) --- FPGA(Rev %02x) DIPSW:%02x,%02x\n", |
283 | readb(rbtx4939_board_rev_addr), readb(rbtx4939_ioc_rev_addr), | 357 | readb(rbtx4939_board_rev_addr), readb(rbtx4939_ioc_rev_addr), |
284 | readb(rbtx4939_udipsw_addr), readb(rbtx4939_bdipsw_addr)); | 358 | readb(rbtx4939_udipsw_addr), readb(rbtx4939_bdipsw_addr)); |
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig index 70b7645ce745..8116a3328a19 100644 --- a/arch/s390/Kconfig +++ b/arch/s390/Kconfig | |||
@@ -241,19 +241,17 @@ config PACK_STACK | |||
241 | Say Y if you are unsure. | 241 | Say Y if you are unsure. |
242 | 242 | ||
243 | config SMALL_STACK | 243 | config SMALL_STACK |
244 | bool "Use 4kb/8kb for kernel stack instead of 8kb/16kb" | 244 | bool "Use 8kb for kernel stack instead of 16kb" |
245 | depends on PACK_STACK && !LOCKDEP | 245 | depends on PACK_STACK && 64BIT && !LOCKDEP |
246 | help | 246 | help |
247 | If you say Y here and the compiler supports the -mkernel-backchain | 247 | If you say Y here and the compiler supports the -mkernel-backchain |
248 | option the kernel will use a smaller kernel stack size. For 31 bit | 248 | option the kernel will use a smaller kernel stack size. The reduced |
249 | the reduced size is 4kb instead of 8kb and for 64 bit it is 8kb | 249 | size is 8kb instead of 16kb. This allows to run more threads on a |
250 | instead of 16kb. This allows to run more thread on a system and | 250 | system and reduces the pressure on the memory management for higher |
251 | reduces the pressure on the memory management for higher order | 251 | order page allocations. |
252 | page allocations. | ||
253 | 252 | ||
254 | Say N if you are unsure. | 253 | Say N if you are unsure. |
255 | 254 | ||
256 | |||
257 | config CHECK_STACK | 255 | config CHECK_STACK |
258 | bool "Detect kernel stack overflow" | 256 | bool "Detect kernel stack overflow" |
259 | help | 257 | help |
@@ -384,7 +382,7 @@ config IPL | |||
384 | choice | 382 | choice |
385 | prompt "IPL method generated into head.S" | 383 | prompt "IPL method generated into head.S" |
386 | depends on IPL | 384 | depends on IPL |
387 | default IPL_TAPE | 385 | default IPL_VM |
388 | help | 386 | help |
389 | Select "tape" if you want to IPL the image from a Tape. | 387 | Select "tape" if you want to IPL the image from a Tape. |
390 | 388 | ||
diff --git a/arch/s390/appldata/appldata_base.c b/arch/s390/appldata/appldata_base.c index a7f8979fb925..a06a47cdd5e0 100644 --- a/arch/s390/appldata/appldata_base.c +++ b/arch/s390/appldata/appldata_base.c | |||
@@ -424,7 +424,7 @@ out: | |||
424 | */ | 424 | */ |
425 | int appldata_register_ops(struct appldata_ops *ops) | 425 | int appldata_register_ops(struct appldata_ops *ops) |
426 | { | 426 | { |
427 | if ((ops->size > APPLDATA_MAX_REC_SIZE) || (ops->size < 0)) | 427 | if (ops->size > APPLDATA_MAX_REC_SIZE) |
428 | return -EINVAL; | 428 | return -EINVAL; |
429 | 429 | ||
430 | ops->ctl_table = kzalloc(4 * sizeof(struct ctl_table), GFP_KERNEL); | 430 | ops->ctl_table = kzalloc(4 * sizeof(struct ctl_table), GFP_KERNEL); |
diff --git a/arch/s390/include/asm/kvm_virtio.h b/arch/s390/include/asm/kvm_virtio.h index 146100224def..c13568b9351c 100644 --- a/arch/s390/include/asm/kvm_virtio.h +++ b/arch/s390/include/asm/kvm_virtio.h | |||
@@ -52,7 +52,7 @@ struct kvm_vqconfig { | |||
52 | 52 | ||
53 | #ifdef __KERNEL__ | 53 | #ifdef __KERNEL__ |
54 | /* early virtio console setup */ | 54 | /* early virtio console setup */ |
55 | #ifdef CONFIG_VIRTIO_CONSOLE | 55 | #ifdef CONFIG_S390_GUEST |
56 | extern void s390_virtio_console_init(void); | 56 | extern void s390_virtio_console_init(void); |
57 | #else | 57 | #else |
58 | static inline void s390_virtio_console_init(void) | 58 | static inline void s390_virtio_console_init(void) |
diff --git a/arch/s390/include/asm/mmu.h b/arch/s390/include/asm/mmu.h index 5dd5e7b3476f..d2b4ff831477 100644 --- a/arch/s390/include/asm/mmu.h +++ b/arch/s390/include/asm/mmu.h | |||
@@ -7,7 +7,8 @@ typedef struct { | |||
7 | unsigned long asce_bits; | 7 | unsigned long asce_bits; |
8 | unsigned long asce_limit; | 8 | unsigned long asce_limit; |
9 | int noexec; | 9 | int noexec; |
10 | int pgstes; | 10 | int has_pgste; /* The mmu context has extended page tables */ |
11 | int alloc_pgste; /* cloned contexts will have extended page tables */ | ||
11 | } mm_context_t; | 12 | } mm_context_t; |
12 | 13 | ||
13 | #endif | 14 | #endif |
diff --git a/arch/s390/include/asm/mmu_context.h b/arch/s390/include/asm/mmu_context.h index 4c2fbf48c9c4..28ec870655af 100644 --- a/arch/s390/include/asm/mmu_context.h +++ b/arch/s390/include/asm/mmu_context.h | |||
@@ -20,12 +20,25 @@ static inline int init_new_context(struct task_struct *tsk, | |||
20 | #ifdef CONFIG_64BIT | 20 | #ifdef CONFIG_64BIT |
21 | mm->context.asce_bits |= _ASCE_TYPE_REGION3; | 21 | mm->context.asce_bits |= _ASCE_TYPE_REGION3; |
22 | #endif | 22 | #endif |
23 | if (current->mm->context.pgstes) { | 23 | if (current->mm->context.alloc_pgste) { |
24 | /* | ||
25 | * alloc_pgste indicates, that any NEW context will be created | ||
26 | * with extended page tables. The old context is unchanged. The | ||
27 | * page table allocation and the page table operations will | ||
28 | * look at has_pgste to distinguish normal and extended page | ||
29 | * tables. The only way to create extended page tables is to | ||
30 | * set alloc_pgste and then create a new context (e.g. dup_mm). | ||
31 | * The page table allocation is called after init_new_context | ||
32 | * and if has_pgste is set, it will create extended page | ||
33 | * tables. | ||
34 | */ | ||
24 | mm->context.noexec = 0; | 35 | mm->context.noexec = 0; |
25 | mm->context.pgstes = 1; | 36 | mm->context.has_pgste = 1; |
37 | mm->context.alloc_pgste = 1; | ||
26 | } else { | 38 | } else { |
27 | mm->context.noexec = s390_noexec; | 39 | mm->context.noexec = s390_noexec; |
28 | mm->context.pgstes = 0; | 40 | mm->context.has_pgste = 0; |
41 | mm->context.alloc_pgste = 0; | ||
29 | } | 42 | } |
30 | mm->context.asce_limit = STACK_TOP_MAX; | 43 | mm->context.asce_limit = STACK_TOP_MAX; |
31 | crst_table_init((unsigned long *) mm->pgd, pgd_entry_type(mm)); | 44 | crst_table_init((unsigned long *) mm->pgd, pgd_entry_type(mm)); |
diff --git a/arch/s390/include/asm/pgtable.h b/arch/s390/include/asm/pgtable.h index 1a928f84afd6..7fc76133b3e4 100644 --- a/arch/s390/include/asm/pgtable.h +++ b/arch/s390/include/asm/pgtable.h | |||
@@ -679,7 +679,7 @@ static inline void pmd_clear(pmd_t *pmd) | |||
679 | 679 | ||
680 | static inline void pte_clear(struct mm_struct *mm, unsigned long addr, pte_t *ptep) | 680 | static inline void pte_clear(struct mm_struct *mm, unsigned long addr, pte_t *ptep) |
681 | { | 681 | { |
682 | if (mm->context.pgstes) | 682 | if (mm->context.has_pgste) |
683 | ptep_rcp_copy(ptep); | 683 | ptep_rcp_copy(ptep); |
684 | pte_val(*ptep) = _PAGE_TYPE_EMPTY; | 684 | pte_val(*ptep) = _PAGE_TYPE_EMPTY; |
685 | if (mm->context.noexec) | 685 | if (mm->context.noexec) |
@@ -763,7 +763,7 @@ static inline int kvm_s390_test_and_clear_page_dirty(struct mm_struct *mm, | |||
763 | struct page *page; | 763 | struct page *page; |
764 | unsigned int skey; | 764 | unsigned int skey; |
765 | 765 | ||
766 | if (!mm->context.pgstes) | 766 | if (!mm->context.has_pgste) |
767 | return -EINVAL; | 767 | return -EINVAL; |
768 | rcp_lock(ptep); | 768 | rcp_lock(ptep); |
769 | pgste = (unsigned long *) (ptep + PTRS_PER_PTE); | 769 | pgste = (unsigned long *) (ptep + PTRS_PER_PTE); |
@@ -794,7 +794,7 @@ static inline int ptep_test_and_clear_young(struct vm_area_struct *vma, | |||
794 | int young; | 794 | int young; |
795 | unsigned long *pgste; | 795 | unsigned long *pgste; |
796 | 796 | ||
797 | if (!vma->vm_mm->context.pgstes) | 797 | if (!vma->vm_mm->context.has_pgste) |
798 | return 0; | 798 | return 0; |
799 | physpage = pte_val(*ptep) & PAGE_MASK; | 799 | physpage = pte_val(*ptep) & PAGE_MASK; |
800 | pgste = (unsigned long *) (ptep + PTRS_PER_PTE); | 800 | pgste = (unsigned long *) (ptep + PTRS_PER_PTE); |
@@ -844,7 +844,7 @@ static inline void __ptep_ipte(unsigned long address, pte_t *ptep) | |||
844 | static inline void ptep_invalidate(struct mm_struct *mm, | 844 | static inline void ptep_invalidate(struct mm_struct *mm, |
845 | unsigned long address, pte_t *ptep) | 845 | unsigned long address, pte_t *ptep) |
846 | { | 846 | { |
847 | if (mm->context.pgstes) { | 847 | if (mm->context.has_pgste) { |
848 | rcp_lock(ptep); | 848 | rcp_lock(ptep); |
849 | __ptep_ipte(address, ptep); | 849 | __ptep_ipte(address, ptep); |
850 | ptep_rcp_copy(ptep); | 850 | ptep_rcp_copy(ptep); |
diff --git a/arch/s390/include/asm/thread_info.h b/arch/s390/include/asm/thread_info.h index de3fad60c682..c1eaf9604da7 100644 --- a/arch/s390/include/asm/thread_info.h +++ b/arch/s390/include/asm/thread_info.h | |||
@@ -15,13 +15,8 @@ | |||
15 | * Size of kernel stack for each process | 15 | * Size of kernel stack for each process |
16 | */ | 16 | */ |
17 | #ifndef __s390x__ | 17 | #ifndef __s390x__ |
18 | #ifndef __SMALL_STACK | ||
19 | #define THREAD_ORDER 1 | 18 | #define THREAD_ORDER 1 |
20 | #define ASYNC_ORDER 1 | 19 | #define ASYNC_ORDER 1 |
21 | #else | ||
22 | #define THREAD_ORDER 0 | ||
23 | #define ASYNC_ORDER 0 | ||
24 | #endif | ||
25 | #else /* __s390x__ */ | 20 | #else /* __s390x__ */ |
26 | #ifndef __SMALL_STACK | 21 | #ifndef __SMALL_STACK |
27 | #define THREAD_ORDER 2 | 22 | #define THREAD_ORDER 2 |
diff --git a/arch/s390/kernel/smp.c b/arch/s390/kernel/smp.c index 9e8b1f9b8f4d..b5595688a477 100644 --- a/arch/s390/kernel/smp.c +++ b/arch/s390/kernel/smp.c | |||
@@ -1119,9 +1119,7 @@ out: | |||
1119 | return rc; | 1119 | return rc; |
1120 | } | 1120 | } |
1121 | 1121 | ||
1122 | static ssize_t __ref rescan_store(struct sys_device *dev, | 1122 | static ssize_t __ref rescan_store(struct sysdev_class *class, const char *buf, |
1123 | struct sysdev_attribute *attr, | ||
1124 | const char *buf, | ||
1125 | size_t count) | 1123 | size_t count) |
1126 | { | 1124 | { |
1127 | int rc; | 1125 | int rc; |
@@ -1129,12 +1127,10 @@ static ssize_t __ref rescan_store(struct sys_device *dev, | |||
1129 | rc = smp_rescan_cpus(); | 1127 | rc = smp_rescan_cpus(); |
1130 | return rc ? rc : count; | 1128 | return rc ? rc : count; |
1131 | } | 1129 | } |
1132 | static SYSDEV_ATTR(rescan, 0200, NULL, rescan_store); | 1130 | static SYSDEV_CLASS_ATTR(rescan, 0200, NULL, rescan_store); |
1133 | #endif /* CONFIG_HOTPLUG_CPU */ | 1131 | #endif /* CONFIG_HOTPLUG_CPU */ |
1134 | 1132 | ||
1135 | static ssize_t dispatching_show(struct sys_device *dev, | 1133 | static ssize_t dispatching_show(struct sysdev_class *class, char *buf) |
1136 | struct sysdev_attribute *attr, | ||
1137 | char *buf) | ||
1138 | { | 1134 | { |
1139 | ssize_t count; | 1135 | ssize_t count; |
1140 | 1136 | ||
@@ -1144,9 +1140,8 @@ static ssize_t dispatching_show(struct sys_device *dev, | |||
1144 | return count; | 1140 | return count; |
1145 | } | 1141 | } |
1146 | 1142 | ||
1147 | static ssize_t dispatching_store(struct sys_device *dev, | 1143 | static ssize_t dispatching_store(struct sysdev_class *dev, const char *buf, |
1148 | struct sysdev_attribute *attr, | 1144 | size_t count) |
1149 | const char *buf, size_t count) | ||
1150 | { | 1145 | { |
1151 | int val, rc; | 1146 | int val, rc; |
1152 | char delim; | 1147 | char delim; |
@@ -1168,7 +1163,8 @@ out: | |||
1168 | put_online_cpus(); | 1163 | put_online_cpus(); |
1169 | return rc ? rc : count; | 1164 | return rc ? rc : count; |
1170 | } | 1165 | } |
1171 | static SYSDEV_ATTR(dispatching, 0644, dispatching_show, dispatching_store); | 1166 | static SYSDEV_CLASS_ATTR(dispatching, 0644, dispatching_show, |
1167 | dispatching_store); | ||
1172 | 1168 | ||
1173 | static int __init topology_init(void) | 1169 | static int __init topology_init(void) |
1174 | { | 1170 | { |
@@ -1178,13 +1174,11 @@ static int __init topology_init(void) | |||
1178 | register_cpu_notifier(&smp_cpu_nb); | 1174 | register_cpu_notifier(&smp_cpu_nb); |
1179 | 1175 | ||
1180 | #ifdef CONFIG_HOTPLUG_CPU | 1176 | #ifdef CONFIG_HOTPLUG_CPU |
1181 | rc = sysfs_create_file(&cpu_sysdev_class.kset.kobj, | 1177 | rc = sysdev_class_create_file(&cpu_sysdev_class, &attr_rescan); |
1182 | &attr_rescan.attr); | ||
1183 | if (rc) | 1178 | if (rc) |
1184 | return rc; | 1179 | return rc; |
1185 | #endif | 1180 | #endif |
1186 | rc = sysfs_create_file(&cpu_sysdev_class.kset.kobj, | 1181 | rc = sysdev_class_create_file(&cpu_sysdev_class, &attr_dispatching); |
1187 | &attr_dispatching.attr); | ||
1188 | if (rc) | 1182 | if (rc) |
1189 | return rc; | 1183 | return rc; |
1190 | for_each_present_cpu(cpu) { | 1184 | for_each_present_cpu(cpu) { |
diff --git a/arch/s390/mm/pgtable.c b/arch/s390/mm/pgtable.c index 3d98ba82ea67..ef3635b52fc0 100644 --- a/arch/s390/mm/pgtable.c +++ b/arch/s390/mm/pgtable.c | |||
@@ -169,7 +169,7 @@ unsigned long *page_table_alloc(struct mm_struct *mm) | |||
169 | unsigned long *table; | 169 | unsigned long *table; |
170 | unsigned long bits; | 170 | unsigned long bits; |
171 | 171 | ||
172 | bits = (mm->context.noexec || mm->context.pgstes) ? 3UL : 1UL; | 172 | bits = (mm->context.noexec || mm->context.has_pgste) ? 3UL : 1UL; |
173 | spin_lock(&mm->page_table_lock); | 173 | spin_lock(&mm->page_table_lock); |
174 | page = NULL; | 174 | page = NULL; |
175 | if (!list_empty(&mm->context.pgtable_list)) { | 175 | if (!list_empty(&mm->context.pgtable_list)) { |
@@ -186,7 +186,7 @@ unsigned long *page_table_alloc(struct mm_struct *mm) | |||
186 | pgtable_page_ctor(page); | 186 | pgtable_page_ctor(page); |
187 | page->flags &= ~FRAG_MASK; | 187 | page->flags &= ~FRAG_MASK; |
188 | table = (unsigned long *) page_to_phys(page); | 188 | table = (unsigned long *) page_to_phys(page); |
189 | if (mm->context.pgstes) | 189 | if (mm->context.has_pgste) |
190 | clear_table_pgstes(table); | 190 | clear_table_pgstes(table); |
191 | else | 191 | else |
192 | clear_table(table, _PAGE_TYPE_EMPTY, PAGE_SIZE); | 192 | clear_table(table, _PAGE_TYPE_EMPTY, PAGE_SIZE); |
@@ -210,7 +210,7 @@ void page_table_free(struct mm_struct *mm, unsigned long *table) | |||
210 | struct page *page; | 210 | struct page *page; |
211 | unsigned long bits; | 211 | unsigned long bits; |
212 | 212 | ||
213 | bits = (mm->context.noexec || mm->context.pgstes) ? 3UL : 1UL; | 213 | bits = (mm->context.noexec || mm->context.has_pgste) ? 3UL : 1UL; |
214 | bits <<= (__pa(table) & (PAGE_SIZE - 1)) / 256 / sizeof(unsigned long); | 214 | bits <<= (__pa(table) & (PAGE_SIZE - 1)) / 256 / sizeof(unsigned long); |
215 | page = pfn_to_page(__pa(table) >> PAGE_SHIFT); | 215 | page = pfn_to_page(__pa(table) >> PAGE_SHIFT); |
216 | spin_lock(&mm->page_table_lock); | 216 | spin_lock(&mm->page_table_lock); |
@@ -257,7 +257,7 @@ int s390_enable_sie(void) | |||
257 | struct mm_struct *mm, *old_mm; | 257 | struct mm_struct *mm, *old_mm; |
258 | 258 | ||
259 | /* Do we have pgstes? if yes, we are done */ | 259 | /* Do we have pgstes? if yes, we are done */ |
260 | if (tsk->mm->context.pgstes) | 260 | if (tsk->mm->context.has_pgste) |
261 | return 0; | 261 | return 0; |
262 | 262 | ||
263 | /* lets check if we are allowed to replace the mm */ | 263 | /* lets check if we are allowed to replace the mm */ |
@@ -269,14 +269,14 @@ int s390_enable_sie(void) | |||
269 | } | 269 | } |
270 | task_unlock(tsk); | 270 | task_unlock(tsk); |
271 | 271 | ||
272 | /* we copy the mm with pgstes enabled */ | 272 | /* we copy the mm and let dup_mm create the page tables with_pgstes */ |
273 | tsk->mm->context.pgstes = 1; | 273 | tsk->mm->context.alloc_pgste = 1; |
274 | mm = dup_mm(tsk); | 274 | mm = dup_mm(tsk); |
275 | tsk->mm->context.pgstes = 0; | 275 | tsk->mm->context.alloc_pgste = 0; |
276 | if (!mm) | 276 | if (!mm) |
277 | return -ENOMEM; | 277 | return -ENOMEM; |
278 | 278 | ||
279 | /* Now lets check again if somebody attached ptrace etc */ | 279 | /* Now lets check again if something happened */ |
280 | task_lock(tsk); | 280 | task_lock(tsk); |
281 | if (!tsk->mm || atomic_read(&tsk->mm->mm_users) > 1 || | 281 | if (!tsk->mm || atomic_read(&tsk->mm->mm_users) > 1 || |
282 | tsk->mm != tsk->active_mm || tsk->mm->ioctx_list) { | 282 | tsk->mm != tsk->active_mm || tsk->mm->ioctx_list) { |
diff --git a/arch/sparc/kernel/apc.c b/arch/sparc/kernel/apc.c index 4dd1ba752ce6..9c115823c4b5 100644 --- a/arch/sparc/kernel/apc.c +++ b/arch/sparc/kernel/apc.c | |||
@@ -31,7 +31,7 @@ | |||
31 | #define APC_DEVNAME "apc" | 31 | #define APC_DEVNAME "apc" |
32 | 32 | ||
33 | static u8 __iomem *regs; | 33 | static u8 __iomem *regs; |
34 | static int apc_no_idle __initdata = 0; | 34 | static int apc_no_idle __devinitdata = 0; |
35 | 35 | ||
36 | #define apc_readb(offs) (sbus_readb(regs+offs)) | 36 | #define apc_readb(offs) (sbus_readb(regs+offs)) |
37 | #define apc_writeb(val, offs) (sbus_writeb(val, regs+offs)) | 37 | #define apc_writeb(val, offs) (sbus_writeb(val, regs+offs)) |
diff --git a/arch/sparc/kernel/head.S b/arch/sparc/kernel/head.S index 2d325fd84579..2fe2c117e772 100644 --- a/arch/sparc/kernel/head.S +++ b/arch/sparc/kernel/head.S | |||
@@ -465,6 +465,7 @@ gokernel: | |||
465 | mov %o7, %g4 ! Save %o7 | 465 | mov %o7, %g4 ! Save %o7 |
466 | 466 | ||
467 | /* Jump to it, and pray... */ | 467 | /* Jump to it, and pray... */ |
468 | __INIT | ||
468 | current_pc: | 469 | current_pc: |
469 | call 1f | 470 | call 1f |
470 | nop | 471 | nop |
diff --git a/arch/sparc64/kernel/trampoline.S b/arch/sparc64/kernel/trampoline.S index 704a3afcfd06..83abd5ae88a4 100644 --- a/arch/sparc64/kernel/trampoline.S +++ b/arch/sparc64/kernel/trampoline.S | |||
@@ -328,6 +328,12 @@ after_lock_tlb: | |||
328 | 328 | ||
329 | wrpr %g0, 0, %wstate | 329 | wrpr %g0, 0, %wstate |
330 | 330 | ||
331 | sethi %hi(prom_entry_lock), %g2 | ||
332 | 1: ldstub [%g2 + %lo(prom_entry_lock)], %g1 | ||
333 | membar #StoreLoad | #StoreStore | ||
334 | brnz,pn %g1, 1b | ||
335 | nop | ||
336 | |||
331 | /* As a hack, put &init_thread_union into %g6. | 337 | /* As a hack, put &init_thread_union into %g6. |
332 | * prom_world() loads from here to restore the %asi | 338 | * prom_world() loads from here to restore the %asi |
333 | * register. | 339 | * register. |
@@ -337,7 +343,7 @@ after_lock_tlb: | |||
337 | 343 | ||
338 | sethi %hi(is_sun4v), %o0 | 344 | sethi %hi(is_sun4v), %o0 |
339 | lduw [%o0 + %lo(is_sun4v)], %o0 | 345 | lduw [%o0 + %lo(is_sun4v)], %o0 |
340 | brz,pt %o0, 1f | 346 | brz,pt %o0, 2f |
341 | nop | 347 | nop |
342 | 348 | ||
343 | TRAP_LOAD_TRAP_BLOCK(%g2, %g3) | 349 | TRAP_LOAD_TRAP_BLOCK(%g2, %g3) |
@@ -369,10 +375,10 @@ after_lock_tlb: | |||
369 | call %o1 | 375 | call %o1 |
370 | add %sp, (2047 + 128), %o0 | 376 | add %sp, (2047 + 128), %o0 |
371 | 377 | ||
372 | ba,pt %xcc, 2f | 378 | ba,pt %xcc, 3f |
373 | nop | 379 | nop |
374 | 380 | ||
375 | 1: sethi %hi(sparc64_ttable_tl0), %o0 | 381 | 2: sethi %hi(sparc64_ttable_tl0), %o0 |
376 | set prom_set_trap_table_name, %g2 | 382 | set prom_set_trap_table_name, %g2 |
377 | stx %g2, [%sp + 2047 + 128 + 0x00] | 383 | stx %g2, [%sp + 2047 + 128 + 0x00] |
378 | mov 1, %g2 | 384 | mov 1, %g2 |
@@ -386,7 +392,11 @@ after_lock_tlb: | |||
386 | call %o1 | 392 | call %o1 |
387 | add %sp, (2047 + 128), %o0 | 393 | add %sp, (2047 + 128), %o0 |
388 | 394 | ||
389 | 2: ldx [%l0], %g6 | 395 | 3: sethi %hi(prom_entry_lock), %g2 |
396 | stb %g0, [%g2 + %lo(prom_entry_lock)] | ||
397 | membar #StoreStore | #StoreLoad | ||
398 | |||
399 | ldx [%l0], %g6 | ||
390 | ldx [%g6 + TI_TASK], %g4 | 400 | ldx [%g6 + TI_TASK], %g4 |
391 | 401 | ||
392 | mov 1, %g5 | 402 | mov 1, %g5 |
diff --git a/arch/x86/boot/video-bios.c b/arch/x86/boot/video-bios.c index 49f26aaaebc8..3fa979c9c363 100644 --- a/arch/x86/boot/video-bios.c +++ b/arch/x86/boot/video-bios.c | |||
@@ -17,7 +17,7 @@ | |||
17 | #include "boot.h" | 17 | #include "boot.h" |
18 | #include "video.h" | 18 | #include "video.h" |
19 | 19 | ||
20 | __videocard video_bios; | 20 | static __videocard video_bios; |
21 | 21 | ||
22 | /* Set a conventional BIOS mode */ | 22 | /* Set a conventional BIOS mode */ |
23 | static int set_bios_mode(u8 mode); | 23 | static int set_bios_mode(u8 mode); |
@@ -119,7 +119,7 @@ static int bios_probe(void) | |||
119 | return nmodes; | 119 | return nmodes; |
120 | } | 120 | } |
121 | 121 | ||
122 | __videocard video_bios = | 122 | static __videocard video_bios = |
123 | { | 123 | { |
124 | .card_name = "BIOS", | 124 | .card_name = "BIOS", |
125 | .probe = bios_probe, | 125 | .probe = bios_probe, |
diff --git a/arch/x86/boot/video-vesa.c b/arch/x86/boot/video-vesa.c index 99b3079dc6ab..75115849af33 100644 --- a/arch/x86/boot/video-vesa.c +++ b/arch/x86/boot/video-vesa.c | |||
@@ -20,7 +20,7 @@ | |||
20 | static struct vesa_general_info vginfo; | 20 | static struct vesa_general_info vginfo; |
21 | static struct vesa_mode_info vminfo; | 21 | static struct vesa_mode_info vminfo; |
22 | 22 | ||
23 | __videocard video_vesa; | 23 | static __videocard video_vesa; |
24 | 24 | ||
25 | #ifndef _WAKEUP | 25 | #ifndef _WAKEUP |
26 | static void vesa_store_mode_params_graphics(void); | 26 | static void vesa_store_mode_params_graphics(void); |
@@ -293,7 +293,7 @@ void vesa_store_edid(void) | |||
293 | 293 | ||
294 | #endif /* not _WAKEUP */ | 294 | #endif /* not _WAKEUP */ |
295 | 295 | ||
296 | __videocard video_vesa = | 296 | static __videocard video_vesa = |
297 | { | 297 | { |
298 | .card_name = "VESA", | 298 | .card_name = "VESA", |
299 | .probe = vesa_probe, | 299 | .probe = vesa_probe, |
diff --git a/arch/x86/include/asm/syscall.h b/arch/x86/include/asm/syscall.h index 1d88f6957d39..d82f39bb7905 100644 --- a/arch/x86/include/asm/syscall.h +++ b/arch/x86/include/asm/syscall.h | |||
@@ -93,26 +93,26 @@ static inline void syscall_get_arguments(struct task_struct *task, | |||
93 | { | 93 | { |
94 | # ifdef CONFIG_IA32_EMULATION | 94 | # ifdef CONFIG_IA32_EMULATION |
95 | if (task_thread_info(task)->status & TS_COMPAT) | 95 | if (task_thread_info(task)->status & TS_COMPAT) |
96 | switch (i + n) { | 96 | switch (i) { |
97 | case 6: | 97 | case 0: |
98 | if (!n--) break; | 98 | if (!n--) break; |
99 | *args++ = regs->bp; | 99 | *args++ = regs->bx; |
100 | case 5: | 100 | case 1: |
101 | if (!n--) break; | 101 | if (!n--) break; |
102 | *args++ = regs->di; | 102 | *args++ = regs->cx; |
103 | case 4: | 103 | case 2: |
104 | if (!n--) break; | 104 | if (!n--) break; |
105 | *args++ = regs->si; | 105 | *args++ = regs->dx; |
106 | case 3: | 106 | case 3: |
107 | if (!n--) break; | 107 | if (!n--) break; |
108 | *args++ = regs->dx; | 108 | *args++ = regs->si; |
109 | case 2: | 109 | case 4: |
110 | if (!n--) break; | 110 | if (!n--) break; |
111 | *args++ = regs->cx; | 111 | *args++ = regs->di; |
112 | case 1: | 112 | case 5: |
113 | if (!n--) break; | 113 | if (!n--) break; |
114 | *args++ = regs->bx; | 114 | *args++ = regs->bp; |
115 | case 0: | 115 | case 6: |
116 | if (!n--) break; | 116 | if (!n--) break; |
117 | default: | 117 | default: |
118 | BUG(); | 118 | BUG(); |
@@ -120,26 +120,26 @@ static inline void syscall_get_arguments(struct task_struct *task, | |||
120 | } | 120 | } |
121 | else | 121 | else |
122 | # endif | 122 | # endif |
123 | switch (i + n) { | 123 | switch (i) { |
124 | case 6: | 124 | case 0: |
125 | if (!n--) break; | 125 | if (!n--) break; |
126 | *args++ = regs->r9; | 126 | *args++ = regs->di; |
127 | case 5: | 127 | case 1: |
128 | if (!n--) break; | 128 | if (!n--) break; |
129 | *args++ = regs->r8; | 129 | *args++ = regs->si; |
130 | case 4: | 130 | case 2: |
131 | if (!n--) break; | 131 | if (!n--) break; |
132 | *args++ = regs->r10; | 132 | *args++ = regs->dx; |
133 | case 3: | 133 | case 3: |
134 | if (!n--) break; | 134 | if (!n--) break; |
135 | *args++ = regs->dx; | 135 | *args++ = regs->r10; |
136 | case 2: | 136 | case 4: |
137 | if (!n--) break; | 137 | if (!n--) break; |
138 | *args++ = regs->si; | 138 | *args++ = regs->r8; |
139 | case 1: | 139 | case 5: |
140 | if (!n--) break; | 140 | if (!n--) break; |
141 | *args++ = regs->di; | 141 | *args++ = regs->r9; |
142 | case 0: | 142 | case 6: |
143 | if (!n--) break; | 143 | if (!n--) break; |
144 | default: | 144 | default: |
145 | BUG(); | 145 | BUG(); |
@@ -154,55 +154,57 @@ static inline void syscall_set_arguments(struct task_struct *task, | |||
154 | { | 154 | { |
155 | # ifdef CONFIG_IA32_EMULATION | 155 | # ifdef CONFIG_IA32_EMULATION |
156 | if (task_thread_info(task)->status & TS_COMPAT) | 156 | if (task_thread_info(task)->status & TS_COMPAT) |
157 | switch (i + n) { | 157 | switch (i) { |
158 | case 6: | 158 | case 0: |
159 | if (!n--) break; | 159 | if (!n--) break; |
160 | regs->bp = *args++; | 160 | regs->bx = *args++; |
161 | case 5: | 161 | case 1: |
162 | if (!n--) break; | 162 | if (!n--) break; |
163 | regs->di = *args++; | 163 | regs->cx = *args++; |
164 | case 4: | 164 | case 2: |
165 | if (!n--) break; | 165 | if (!n--) break; |
166 | regs->si = *args++; | 166 | regs->dx = *args++; |
167 | case 3: | 167 | case 3: |
168 | if (!n--) break; | 168 | if (!n--) break; |
169 | regs->dx = *args++; | 169 | regs->si = *args++; |
170 | case 2: | 170 | case 4: |
171 | if (!n--) break; | 171 | if (!n--) break; |
172 | regs->cx = *args++; | 172 | regs->di = *args++; |
173 | case 1: | 173 | case 5: |
174 | if (!n--) break; | 174 | if (!n--) break; |
175 | regs->bx = *args++; | 175 | regs->bp = *args++; |
176 | case 0: | 176 | case 6: |
177 | if (!n--) break; | 177 | if (!n--) break; |
178 | default: | 178 | default: |
179 | BUG(); | 179 | BUG(); |
180 | break; | ||
180 | } | 181 | } |
181 | else | 182 | else |
182 | # endif | 183 | # endif |
183 | switch (i + n) { | 184 | switch (i) { |
184 | case 6: | 185 | case 0: |
185 | if (!n--) break; | 186 | if (!n--) break; |
186 | regs->r9 = *args++; | 187 | regs->di = *args++; |
187 | case 5: | 188 | case 1: |
188 | if (!n--) break; | 189 | if (!n--) break; |
189 | regs->r8 = *args++; | 190 | regs->si = *args++; |
190 | case 4: | 191 | case 2: |
191 | if (!n--) break; | 192 | if (!n--) break; |
192 | regs->r10 = *args++; | 193 | regs->dx = *args++; |
193 | case 3: | 194 | case 3: |
194 | if (!n--) break; | 195 | if (!n--) break; |
195 | regs->dx = *args++; | 196 | regs->r10 = *args++; |
196 | case 2: | 197 | case 4: |
197 | if (!n--) break; | 198 | if (!n--) break; |
198 | regs->si = *args++; | 199 | regs->r8 = *args++; |
199 | case 1: | 200 | case 5: |
200 | if (!n--) break; | 201 | if (!n--) break; |
201 | regs->di = *args++; | 202 | regs->r9 = *args++; |
202 | case 0: | 203 | case 6: |
203 | if (!n--) break; | 204 | if (!n--) break; |
204 | default: | 205 | default: |
205 | BUG(); | 206 | BUG(); |
207 | break; | ||
206 | } | 208 | } |
207 | } | 209 | } |
208 | 210 | ||
diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c index 53b01a1ae10c..8c1f76abae9e 100644 --- a/arch/x86/kernel/acpi/boot.c +++ b/arch/x86/kernel/acpi/boot.c | |||
@@ -1137,7 +1137,7 @@ int mp_register_gsi(u32 gsi, int triggering, int polarity) | |||
1137 | return gsi; | 1137 | return gsi; |
1138 | } | 1138 | } |
1139 | if (test_bit(ioapic_pin, mp_ioapic_routing[ioapic].pin_programmed)) { | 1139 | if (test_bit(ioapic_pin, mp_ioapic_routing[ioapic].pin_programmed)) { |
1140 | pr_debug(KERN_DEBUG "Pin %d-%d already programmed\n", | 1140 | pr_debug("Pin %d-%d already programmed\n", |
1141 | mp_ioapic_routing[ioapic].apic_id, ioapic_pin); | 1141 | mp_ioapic_routing[ioapic].apic_id, ioapic_pin); |
1142 | #ifdef CONFIG_X86_32 | 1142 | #ifdef CONFIG_X86_32 |
1143 | return (gsi < IRQ_COMPRESSION_START ? gsi : gsi_to_irq[gsi]); | 1143 | return (gsi < IRQ_COMPRESSION_START ? gsi : gsi_to_irq[gsi]); |
@@ -1599,6 +1599,11 @@ static struct dmi_system_id __initdata acpi_dmi_table[] = { | |||
1599 | DMI_MATCH(DMI_PRODUCT_NAME, "TravelMate 360"), | 1599 | DMI_MATCH(DMI_PRODUCT_NAME, "TravelMate 360"), |
1600 | }, | 1600 | }, |
1601 | }, | 1601 | }, |
1602 | {} | ||
1603 | }; | ||
1604 | |||
1605 | /* second table for DMI checks that should run after early-quirks */ | ||
1606 | static struct dmi_system_id __initdata acpi_dmi_table_late[] = { | ||
1602 | /* | 1607 | /* |
1603 | * HP laptops which use a DSDT reporting as HP/SB400/10000, | 1608 | * HP laptops which use a DSDT reporting as HP/SB400/10000, |
1604 | * which includes some code which overrides all temperature | 1609 | * which includes some code which overrides all temperature |
@@ -1727,6 +1732,9 @@ int __init early_acpi_boot_init(void) | |||
1727 | 1732 | ||
1728 | int __init acpi_boot_init(void) | 1733 | int __init acpi_boot_init(void) |
1729 | { | 1734 | { |
1735 | /* those are executed after early-quirks are executed */ | ||
1736 | dmi_check_system(acpi_dmi_table_late); | ||
1737 | |||
1730 | /* | 1738 | /* |
1731 | * If acpi_disabled, bail out | 1739 | * If acpi_disabled, bail out |
1732 | * One exception: acpi=ht continues far enough to enumerate LAPICs | 1740 | * One exception: acpi=ht continues far enough to enumerate LAPICs |
diff --git a/arch/x86/kernel/cpu/proc.c b/arch/x86/kernel/cpu/proc.c index a26c480b9491..01b1244ef1c0 100644 --- a/arch/x86/kernel/cpu/proc.c +++ b/arch/x86/kernel/cpu/proc.c | |||
@@ -160,14 +160,16 @@ static void *c_start(struct seq_file *m, loff_t *pos) | |||
160 | { | 160 | { |
161 | if (*pos == 0) /* just in case, cpu 0 is not the first */ | 161 | if (*pos == 0) /* just in case, cpu 0 is not the first */ |
162 | *pos = first_cpu(cpu_online_map); | 162 | *pos = first_cpu(cpu_online_map); |
163 | if ((*pos) < nr_cpu_ids && cpu_online(*pos)) | 163 | else |
164 | *pos = next_cpu_nr(*pos - 1, cpu_online_map); | ||
165 | if ((*pos) < nr_cpu_ids) | ||
164 | return &cpu_data(*pos); | 166 | return &cpu_data(*pos); |
165 | return NULL; | 167 | return NULL; |
166 | } | 168 | } |
167 | 169 | ||
168 | static void *c_next(struct seq_file *m, void *v, loff_t *pos) | 170 | static void *c_next(struct seq_file *m, void *v, loff_t *pos) |
169 | { | 171 | { |
170 | *pos = next_cpu(*pos, cpu_online_map); | 172 | (*pos)++; |
171 | return c_start(m, pos); | 173 | return c_start(m, pos); |
172 | } | 174 | } |
173 | 175 | ||
diff --git a/arch/x86/kernel/dumpstack_32.c b/arch/x86/kernel/dumpstack_32.c index 1a78180f08d3..b3614752197b 100644 --- a/arch/x86/kernel/dumpstack_32.c +++ b/arch/x86/kernel/dumpstack_32.c | |||
@@ -405,7 +405,6 @@ die_nmi(char *str, struct pt_regs *regs, int do_panic) | |||
405 | panic("Non maskable interrupt"); | 405 | panic("Non maskable interrupt"); |
406 | console_silent(); | 406 | console_silent(); |
407 | spin_unlock(&nmi_print_lock); | 407 | spin_unlock(&nmi_print_lock); |
408 | bust_spinlocks(0); | ||
409 | 408 | ||
410 | /* | 409 | /* |
411 | * If we are in kernel we are probably nested up pretty bad | 410 | * If we are in kernel we are probably nested up pretty bad |
@@ -416,6 +415,7 @@ die_nmi(char *str, struct pt_regs *regs, int do_panic) | |||
416 | crash_kexec(regs); | 415 | crash_kexec(regs); |
417 | } | 416 | } |
418 | 417 | ||
418 | bust_spinlocks(0); | ||
419 | do_exit(SIGSEGV); | 419 | do_exit(SIGSEGV); |
420 | } | 420 | } |
421 | 421 | ||
diff --git a/arch/x86/kernel/entry_32.S b/arch/x86/kernel/entry_32.S index c356423a6026..dd65143941a8 100644 --- a/arch/x86/kernel/entry_32.S +++ b/arch/x86/kernel/entry_32.S | |||
@@ -1024,7 +1024,7 @@ ENTRY(machine_check) | |||
1024 | RING0_INT_FRAME | 1024 | RING0_INT_FRAME |
1025 | pushl $0 | 1025 | pushl $0 |
1026 | CFI_ADJUST_CFA_OFFSET 4 | 1026 | CFI_ADJUST_CFA_OFFSET 4 |
1027 | pushl $do_machine_check | 1027 | pushl machine_check_vector |
1028 | CFI_ADJUST_CFA_OFFSET 4 | 1028 | CFI_ADJUST_CFA_OFFSET 4 |
1029 | jmp error_code | 1029 | jmp error_code |
1030 | CFI_ENDPROC | 1030 | CFI_ENDPROC |
diff --git a/arch/x86/kernel/genapic_flat_64.c b/arch/x86/kernel/genapic_flat_64.c index 2ec2de8d8c46..c0262791bda4 100644 --- a/arch/x86/kernel/genapic_flat_64.c +++ b/arch/x86/kernel/genapic_flat_64.c | |||
@@ -25,7 +25,7 @@ | |||
25 | #include <acpi/acpi_bus.h> | 25 | #include <acpi/acpi_bus.h> |
26 | #endif | 26 | #endif |
27 | 27 | ||
28 | static int __init flat_acpi_madt_oem_check(char *oem_id, char *oem_table_id) | 28 | static int flat_acpi_madt_oem_check(char *oem_id, char *oem_table_id) |
29 | { | 29 | { |
30 | return 1; | 30 | return 1; |
31 | } | 31 | } |
@@ -170,7 +170,7 @@ struct genapic apic_flat = { | |||
170 | * We cannot use logical delivery in this case because the mask | 170 | * We cannot use logical delivery in this case because the mask |
171 | * overflows, so use physical mode. | 171 | * overflows, so use physical mode. |
172 | */ | 172 | */ |
173 | static int __init physflat_acpi_madt_oem_check(char *oem_id, char *oem_table_id) | 173 | static int physflat_acpi_madt_oem_check(char *oem_id, char *oem_table_id) |
174 | { | 174 | { |
175 | #ifdef CONFIG_ACPI | 175 | #ifdef CONFIG_ACPI |
176 | /* | 176 | /* |
diff --git a/arch/x86/kernel/genx2apic_cluster.c b/arch/x86/kernel/genx2apic_cluster.c index e4bf2cc0d743..f6a2c8eb48a6 100644 --- a/arch/x86/kernel/genx2apic_cluster.c +++ b/arch/x86/kernel/genx2apic_cluster.c | |||
@@ -12,7 +12,7 @@ | |||
12 | 12 | ||
13 | DEFINE_PER_CPU(u32, x86_cpu_to_logical_apicid); | 13 | DEFINE_PER_CPU(u32, x86_cpu_to_logical_apicid); |
14 | 14 | ||
15 | static int __init x2apic_acpi_madt_oem_check(char *oem_id, char *oem_table_id) | 15 | static int x2apic_acpi_madt_oem_check(char *oem_id, char *oem_table_id) |
16 | { | 16 | { |
17 | if (cpu_has_x2apic) | 17 | if (cpu_has_x2apic) |
18 | return 1; | 18 | return 1; |
diff --git a/arch/x86/kernel/genx2apic_phys.c b/arch/x86/kernel/genx2apic_phys.c index 8f1343df2627..d042211768b7 100644 --- a/arch/x86/kernel/genx2apic_phys.c +++ b/arch/x86/kernel/genx2apic_phys.c | |||
@@ -19,7 +19,7 @@ static int set_x2apic_phys_mode(char *arg) | |||
19 | } | 19 | } |
20 | early_param("x2apic_phys", set_x2apic_phys_mode); | 20 | early_param("x2apic_phys", set_x2apic_phys_mode); |
21 | 21 | ||
22 | static int __init x2apic_acpi_madt_oem_check(char *oem_id, char *oem_table_id) | 22 | static int x2apic_acpi_madt_oem_check(char *oem_id, char *oem_table_id) |
23 | { | 23 | { |
24 | if (cpu_has_x2apic && x2apic_phys) | 24 | if (cpu_has_x2apic && x2apic_phys) |
25 | return 1; | 25 | return 1; |
diff --git a/arch/x86/kernel/genx2apic_uv_x.c b/arch/x86/kernel/genx2apic_uv_x.c index bfd532843df6..2c7dbdb98278 100644 --- a/arch/x86/kernel/genx2apic_uv_x.c +++ b/arch/x86/kernel/genx2apic_uv_x.c | |||
@@ -15,7 +15,6 @@ | |||
15 | #include <linux/ctype.h> | 15 | #include <linux/ctype.h> |
16 | #include <linux/init.h> | 16 | #include <linux/init.h> |
17 | #include <linux/sched.h> | 17 | #include <linux/sched.h> |
18 | #include <linux/bootmem.h> | ||
19 | #include <linux/module.h> | 18 | #include <linux/module.h> |
20 | #include <linux/hardirq.h> | 19 | #include <linux/hardirq.h> |
21 | #include <asm/smp.h> | 20 | #include <asm/smp.h> |
@@ -30,7 +29,7 @@ DEFINE_PER_CPU(int, x2apic_extra_bits); | |||
30 | 29 | ||
31 | static enum uv_system_type uv_system_type; | 30 | static enum uv_system_type uv_system_type; |
32 | 31 | ||
33 | static int __init uv_acpi_madt_oem_check(char *oem_id, char *oem_table_id) | 32 | static int uv_acpi_madt_oem_check(char *oem_id, char *oem_table_id) |
34 | { | 33 | { |
35 | if (!strcmp(oem_id, "SGI")) { | 34 | if (!strcmp(oem_id, "SGI")) { |
36 | if (!strcmp(oem_table_id, "UVL")) | 35 | if (!strcmp(oem_table_id, "UVL")) |
@@ -398,16 +397,16 @@ void __init uv_system_init(void) | |||
398 | printk(KERN_DEBUG "UV: Found %d blades\n", uv_num_possible_blades()); | 397 | printk(KERN_DEBUG "UV: Found %d blades\n", uv_num_possible_blades()); |
399 | 398 | ||
400 | bytes = sizeof(struct uv_blade_info) * uv_num_possible_blades(); | 399 | bytes = sizeof(struct uv_blade_info) * uv_num_possible_blades(); |
401 | uv_blade_info = alloc_bootmem_pages(bytes); | 400 | uv_blade_info = kmalloc(bytes, GFP_KERNEL); |
402 | 401 | ||
403 | get_lowmem_redirect(&lowmem_redir_base, &lowmem_redir_size); | 402 | get_lowmem_redirect(&lowmem_redir_base, &lowmem_redir_size); |
404 | 403 | ||
405 | bytes = sizeof(uv_node_to_blade[0]) * num_possible_nodes(); | 404 | bytes = sizeof(uv_node_to_blade[0]) * num_possible_nodes(); |
406 | uv_node_to_blade = alloc_bootmem_pages(bytes); | 405 | uv_node_to_blade = kmalloc(bytes, GFP_KERNEL); |
407 | memset(uv_node_to_blade, 255, bytes); | 406 | memset(uv_node_to_blade, 255, bytes); |
408 | 407 | ||
409 | bytes = sizeof(uv_cpu_to_blade[0]) * num_possible_cpus(); | 408 | bytes = sizeof(uv_cpu_to_blade[0]) * num_possible_cpus(); |
410 | uv_cpu_to_blade = alloc_bootmem_pages(bytes); | 409 | uv_cpu_to_blade = kmalloc(bytes, GFP_KERNEL); |
411 | memset(uv_cpu_to_blade, 255, bytes); | 410 | memset(uv_cpu_to_blade, 255, bytes); |
412 | 411 | ||
413 | blade = 0; | 412 | blade = 0; |
diff --git a/arch/x86/kernel/setup_percpu.c b/arch/x86/kernel/setup_percpu.c index 410c88f0bfeb..ae0c0d3bb770 100644 --- a/arch/x86/kernel/setup_percpu.c +++ b/arch/x86/kernel/setup_percpu.c | |||
@@ -218,7 +218,7 @@ static void __init setup_node_to_cpumask_map(void) | |||
218 | /* allocate the map */ | 218 | /* allocate the map */ |
219 | map = alloc_bootmem_low(nr_node_ids * sizeof(cpumask_t)); | 219 | map = alloc_bootmem_low(nr_node_ids * sizeof(cpumask_t)); |
220 | 220 | ||
221 | pr_debug(KERN_DEBUG "Node to cpumask map at %p for %d nodes\n", | 221 | pr_debug("Node to cpumask map at %p for %d nodes\n", |
222 | map, nr_node_ids); | 222 | map, nr_node_ids); |
223 | 223 | ||
224 | /* node_to_cpumask() will now work */ | 224 | /* node_to_cpumask() will now work */ |
diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c index 7ece815ea637..7b1093397319 100644 --- a/arch/x86/kernel/smpboot.c +++ b/arch/x86/kernel/smpboot.c | |||
@@ -893,9 +893,11 @@ do_rest: | |||
893 | smpboot_setup_warm_reset_vector(start_ip); | 893 | smpboot_setup_warm_reset_vector(start_ip); |
894 | /* | 894 | /* |
895 | * Be paranoid about clearing APIC errors. | 895 | * Be paranoid about clearing APIC errors. |
896 | */ | 896 | */ |
897 | apic_write(APIC_ESR, 0); | 897 | if (APIC_INTEGRATED(apic_version[boot_cpu_physical_apicid])) { |
898 | apic_read(APIC_ESR); | 898 | apic_write(APIC_ESR, 0); |
899 | apic_read(APIC_ESR); | ||
900 | } | ||
899 | } | 901 | } |
900 | 902 | ||
901 | /* | 903 | /* |
diff --git a/arch/x86/kernel/tlb_uv.c b/arch/x86/kernel/tlb_uv.c index 8b8c0d6640fa..04431f34fd16 100644 --- a/arch/x86/kernel/tlb_uv.c +++ b/arch/x86/kernel/tlb_uv.c | |||
@@ -6,7 +6,7 @@ | |||
6 | * This code is released under the GNU General Public License version 2 or | 6 | * This code is released under the GNU General Public License version 2 or |
7 | * later. | 7 | * later. |
8 | */ | 8 | */ |
9 | #include <linux/mc146818rtc.h> | 9 | #include <linux/seq_file.h> |
10 | #include <linux/proc_fs.h> | 10 | #include <linux/proc_fs.h> |
11 | #include <linux/kernel.h> | 11 | #include <linux/kernel.h> |
12 | 12 | ||
diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c index e062974cce34..04d242ab0161 100644 --- a/arch/x86/kernel/traps.c +++ b/arch/x86/kernel/traps.c | |||
@@ -931,14 +931,6 @@ do_device_not_available(struct pt_regs *regs, long error) | |||
931 | } | 931 | } |
932 | 932 | ||
933 | #ifdef CONFIG_X86_32 | 933 | #ifdef CONFIG_X86_32 |
934 | #ifdef CONFIG_X86_MCE | ||
935 | dotraplinkage void __kprobes do_machine_check(struct pt_regs *regs, long error) | ||
936 | { | ||
937 | conditional_sti(regs); | ||
938 | machine_check_vector(regs, error); | ||
939 | } | ||
940 | #endif | ||
941 | |||
942 | dotraplinkage void do_iret_error(struct pt_regs *regs, long error_code) | 934 | dotraplinkage void do_iret_error(struct pt_regs *regs, long error_code) |
943 | { | 935 | { |
944 | siginfo_t info; | 936 | siginfo_t info; |
diff --git a/arch/x86/kernel/xsave.c b/arch/x86/kernel/xsave.c index 9abac8a9d823..b13acb75e822 100644 --- a/arch/x86/kernel/xsave.c +++ b/arch/x86/kernel/xsave.c | |||
@@ -248,7 +248,7 @@ clear: | |||
248 | * This will be saved when ever the FP and extended state context is | 248 | * This will be saved when ever the FP and extended state context is |
249 | * saved on the user stack during the signal handler delivery to the user. | 249 | * saved on the user stack during the signal handler delivery to the user. |
250 | */ | 250 | */ |
251 | void prepare_fx_sw_frame(void) | 251 | static void prepare_fx_sw_frame(void) |
252 | { | 252 | { |
253 | int size_extended = (xstate_size - sizeof(struct i387_fxsave_struct)) + | 253 | int size_extended = (xstate_size - sizeof(struct i387_fxsave_struct)) + |
254 | FP_XSTATE_MAGIC2_SIZE; | 254 | FP_XSTATE_MAGIC2_SIZE; |
diff --git a/arch/x86/mm/init_64.c b/arch/x86/mm/init_64.c index b8e461d49412..f79a02f64d10 100644 --- a/arch/x86/mm/init_64.c +++ b/arch/x86/mm/init_64.c | |||
@@ -350,8 +350,10 @@ phys_pte_init(pte_t *pte_page, unsigned long addr, unsigned long end, | |||
350 | * pagetable pages as RO. So assume someone who pre-setup | 350 | * pagetable pages as RO. So assume someone who pre-setup |
351 | * these mappings are more intelligent. | 351 | * these mappings are more intelligent. |
352 | */ | 352 | */ |
353 | if (pte_val(*pte)) | 353 | if (pte_val(*pte)) { |
354 | pages++; | ||
354 | continue; | 355 | continue; |
356 | } | ||
355 | 357 | ||
356 | if (0) | 358 | if (0) |
357 | printk(" pte=%p addr=%lx pte=%016lx\n", | 359 | printk(" pte=%p addr=%lx pte=%016lx\n", |
@@ -418,8 +420,10 @@ phys_pmd_init(pmd_t *pmd_page, unsigned long address, unsigned long end, | |||
418 | * not differ with respect to page frame and | 420 | * not differ with respect to page frame and |
419 | * attributes. | 421 | * attributes. |
420 | */ | 422 | */ |
421 | if (page_size_mask & (1 << PG_LEVEL_2M)) | 423 | if (page_size_mask & (1 << PG_LEVEL_2M)) { |
424 | pages++; | ||
422 | continue; | 425 | continue; |
426 | } | ||
423 | new_prot = pte_pgprot(pte_clrhuge(*(pte_t *)pmd)); | 427 | new_prot = pte_pgprot(pte_clrhuge(*(pte_t *)pmd)); |
424 | } | 428 | } |
425 | 429 | ||
@@ -499,8 +503,10 @@ phys_pud_init(pud_t *pud_page, unsigned long addr, unsigned long end, | |||
499 | * not differ with respect to page frame and | 503 | * not differ with respect to page frame and |
500 | * attributes. | 504 | * attributes. |
501 | */ | 505 | */ |
502 | if (page_size_mask & (1 << PG_LEVEL_1G)) | 506 | if (page_size_mask & (1 << PG_LEVEL_1G)) { |
507 | pages++; | ||
503 | continue; | 508 | continue; |
509 | } | ||
504 | prot = pte_pgprot(pte_clrhuge(*(pte_t *)pud)); | 510 | prot = pte_pgprot(pte_clrhuge(*(pte_t *)pud)); |
505 | } | 511 | } |
506 | 512 | ||
@@ -831,7 +837,7 @@ int arch_add_memory(int nid, u64 start, u64 size) | |||
831 | unsigned long nr_pages = size >> PAGE_SHIFT; | 837 | unsigned long nr_pages = size >> PAGE_SHIFT; |
832 | int ret; | 838 | int ret; |
833 | 839 | ||
834 | last_mapped_pfn = init_memory_mapping(start, start + size-1); | 840 | last_mapped_pfn = init_memory_mapping(start, start + size); |
835 | if (last_mapped_pfn > max_pfn_mapped) | 841 | if (last_mapped_pfn > max_pfn_mapped) |
836 | max_pfn_mapped = last_mapped_pfn; | 842 | max_pfn_mapped = last_mapped_pfn; |
837 | 843 | ||
diff --git a/arch/x86/mm/memtest.c b/arch/x86/mm/memtest.c index 672e17f8262a..9cab18b0b857 100644 --- a/arch/x86/mm/memtest.c +++ b/arch/x86/mm/memtest.c | |||
@@ -61,9 +61,9 @@ static void __init memtest(unsigned long start_phys, unsigned long size, | |||
61 | last_bad += incr; | 61 | last_bad += incr; |
62 | } else { | 62 | } else { |
63 | if (start_bad) { | 63 | if (start_bad) { |
64 | printk(KERN_CONT "\n %010lx bad mem addr %010lx - %010lx reserved", | 64 | printk(KERN_CONT "\n %016lx bad mem addr %010lx - %010lx reserved", |
65 | val, start_bad, last_bad + incr); | 65 | val, start_bad, last_bad + incr); |
66 | reserve_early(start_bad, last_bad - start_bad, "BAD RAM"); | 66 | reserve_early(start_bad, last_bad + incr, "BAD RAM"); |
67 | } | 67 | } |
68 | start_bad = last_bad = start_phys_aligned; | 68 | start_bad = last_bad = start_phys_aligned; |
69 | } | 69 | } |
@@ -72,9 +72,8 @@ static void __init memtest(unsigned long start_phys, unsigned long size, | |||
72 | if (start_bad) { | 72 | if (start_bad) { |
73 | printk(KERN_CONT "\n %016lx bad mem addr %010lx - %010lx reserved", | 73 | printk(KERN_CONT "\n %016lx bad mem addr %010lx - %010lx reserved", |
74 | val, start_bad, last_bad + incr); | 74 | val, start_bad, last_bad + incr); |
75 | reserve_early(start_bad, last_bad - start_bad, "BAD RAM"); | 75 | reserve_early(start_bad, last_bad + incr, "BAD RAM"); |
76 | } | 76 | } |
77 | |||
78 | } | 77 | } |
79 | 78 | ||
80 | /* default is disabled */ | 79 | /* default is disabled */ |
diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c index d4d52f5a1cf7..aba77b2b7d18 100644 --- a/arch/x86/xen/mmu.c +++ b/arch/x86/xen/mmu.c | |||
@@ -246,11 +246,21 @@ xmaddr_t arbitrary_virt_to_machine(void *vaddr) | |||
246 | { | 246 | { |
247 | unsigned long address = (unsigned long)vaddr; | 247 | unsigned long address = (unsigned long)vaddr; |
248 | unsigned int level; | 248 | unsigned int level; |
249 | pte_t *pte = lookup_address(address, &level); | 249 | pte_t *pte; |
250 | unsigned offset = address & ~PAGE_MASK; | 250 | unsigned offset; |
251 | 251 | ||
252 | BUG_ON(pte == NULL); | 252 | /* |
253 | * if the PFN is in the linear mapped vaddr range, we can just use | ||
254 | * the (quick) virt_to_machine() p2m lookup | ||
255 | */ | ||
256 | if (virt_addr_valid(vaddr)) | ||
257 | return virt_to_machine(vaddr); | ||
253 | 258 | ||
259 | /* otherwise we have to do a (slower) full page-table walk */ | ||
260 | |||
261 | pte = lookup_address(address, &level); | ||
262 | BUG_ON(pte == NULL); | ||
263 | offset = address & ~PAGE_MASK; | ||
254 | return XMADDR(((phys_addr_t)pte_mfn(*pte) << PAGE_SHIFT) + offset); | 264 | return XMADDR(((phys_addr_t)pte_mfn(*pte) << PAGE_SHIFT) + offset); |
255 | } | 265 | } |
256 | 266 | ||
@@ -410,7 +420,7 @@ void xen_ptep_modify_prot_commit(struct mm_struct *mm, unsigned long addr, | |||
410 | 420 | ||
411 | xen_mc_batch(); | 421 | xen_mc_batch(); |
412 | 422 | ||
413 | u.ptr = virt_to_machine(ptep).maddr | MMU_PT_UPDATE_PRESERVE_AD; | 423 | u.ptr = arbitrary_virt_to_machine(ptep).maddr | MMU_PT_UPDATE_PRESERVE_AD; |
414 | u.val = pte_val_ma(pte); | 424 | u.val = pte_val_ma(pte); |
415 | xen_extend_mmu_update(&u); | 425 | xen_extend_mmu_update(&u); |
416 | 426 | ||
diff --git a/drivers/Makefile b/drivers/Makefile index 2503f7b99b2f..fceb71a741c3 100644 --- a/drivers/Makefile +++ b/drivers/Makefile | |||
@@ -56,6 +56,7 @@ obj-$(CONFIG_MAC) += macintosh/ | |||
56 | obj-$(CONFIG_ATA_OVER_ETH) += block/aoe/ | 56 | obj-$(CONFIG_ATA_OVER_ETH) += block/aoe/ |
57 | obj-$(CONFIG_PARIDE) += block/paride/ | 57 | obj-$(CONFIG_PARIDE) += block/paride/ |
58 | obj-$(CONFIG_TC) += tc/ | 58 | obj-$(CONFIG_TC) += tc/ |
59 | obj-$(CONFIG_UWB) += uwb/ | ||
59 | obj-$(CONFIG_USB) += usb/ | 60 | obj-$(CONFIG_USB) += usb/ |
60 | obj-$(CONFIG_USB_MUSB_HDRC) += usb/musb/ | 61 | obj-$(CONFIG_USB_MUSB_HDRC) += usb/musb/ |
61 | obj-$(CONFIG_PCI) += usb/ | 62 | obj-$(CONFIG_PCI) += usb/ |
@@ -101,4 +102,3 @@ obj-$(CONFIG_SSB) += ssb/ | |||
101 | obj-$(CONFIG_VIRTIO) += virtio/ | 102 | obj-$(CONFIG_VIRTIO) += virtio/ |
102 | obj-$(CONFIG_REGULATOR) += regulator/ | 103 | obj-$(CONFIG_REGULATOR) += regulator/ |
103 | obj-$(CONFIG_STAGING) += staging/ | 104 | obj-$(CONFIG_STAGING) += staging/ |
104 | obj-$(CONFIG_UWB) += uwb/ | ||
diff --git a/drivers/acpi/button.c b/drivers/acpi/button.c index 9d568d417eaa..cb046c3fc3f2 100644 --- a/drivers/acpi/button.c +++ b/drivers/acpi/button.c | |||
@@ -262,6 +262,7 @@ static int acpi_lid_send_state(struct acpi_button *button) | |||
262 | return -ENODEV; | 262 | return -ENODEV; |
263 | /* input layer checks if event is redundant */ | 263 | /* input layer checks if event is redundant */ |
264 | input_report_switch(button->input, SW_LID, !state); | 264 | input_report_switch(button->input, SW_LID, !state); |
265 | input_sync(button->input); | ||
265 | return 0; | 266 | return 0; |
266 | } | 267 | } |
267 | 268 | ||
@@ -285,8 +286,8 @@ static void acpi_button_notify(acpi_handle handle, u32 event, void *data) | |||
285 | input_report_key(input, keycode, 1); | 286 | input_report_key(input, keycode, 1); |
286 | input_sync(input); | 287 | input_sync(input); |
287 | input_report_key(input, keycode, 0); | 288 | input_report_key(input, keycode, 0); |
289 | input_sync(input); | ||
288 | } | 290 | } |
289 | input_sync(input); | ||
290 | 291 | ||
291 | acpi_bus_generate_proc_event(button->device, event, | 292 | acpi_bus_generate_proc_event(button->device, event, |
292 | ++button->pushed); | 293 | ++button->pushed); |
diff --git a/drivers/acpi/processor_perflib.c b/drivers/acpi/processor_perflib.c index dc98f7a6f2c4..dbcf260ea93f 100644 --- a/drivers/acpi/processor_perflib.c +++ b/drivers/acpi/processor_perflib.c | |||
@@ -38,7 +38,10 @@ | |||
38 | 38 | ||
39 | #include <asm/uaccess.h> | 39 | #include <asm/uaccess.h> |
40 | #endif | 40 | #endif |
41 | |||
42 | #ifdef CONFIG_X86 | ||
41 | #include <asm/cpufeature.h> | 43 | #include <asm/cpufeature.h> |
44 | #endif | ||
42 | 45 | ||
43 | #include <acpi/acpi_bus.h> | 46 | #include <acpi/acpi_bus.h> |
44 | #include <acpi/processor.h> | 47 | #include <acpi/processor.h> |
@@ -360,11 +363,13 @@ static int acpi_processor_get_performance_info(struct acpi_processor *pr) | |||
360 | * the BIOS is older than the CPU and does not know its frequencies | 363 | * the BIOS is older than the CPU and does not know its frequencies |
361 | */ | 364 | */ |
362 | update_bios: | 365 | update_bios: |
366 | #ifdef CONFIG_X86 | ||
363 | if (ACPI_SUCCESS(acpi_get_handle(pr->handle, "_PPC", &handle))){ | 367 | if (ACPI_SUCCESS(acpi_get_handle(pr->handle, "_PPC", &handle))){ |
364 | if(boot_cpu_has(X86_FEATURE_EST)) | 368 | if(boot_cpu_has(X86_FEATURE_EST)) |
365 | printk(KERN_WARNING FW_BUG "BIOS needs update for CPU " | 369 | printk(KERN_WARNING FW_BUG "BIOS needs update for CPU " |
366 | "frequency support\n"); | 370 | "frequency support\n"); |
367 | } | 371 | } |
372 | #endif | ||
368 | return result; | 373 | return result; |
369 | } | 374 | } |
370 | 375 | ||
diff --git a/drivers/acpi/sleep/main.c b/drivers/acpi/sleep/main.c index 26571bafb158..80c0868d0480 100644 --- a/drivers/acpi/sleep/main.c +++ b/drivers/acpi/sleep/main.c | |||
@@ -163,6 +163,8 @@ static void acpi_pm_end(void) | |||
163 | acpi_target_sleep_state = ACPI_STATE_S0; | 163 | acpi_target_sleep_state = ACPI_STATE_S0; |
164 | acpi_sleep_tts_switch(acpi_target_sleep_state); | 164 | acpi_sleep_tts_switch(acpi_target_sleep_state); |
165 | } | 165 | } |
166 | #else /* !CONFIG_ACPI_SLEEP */ | ||
167 | #define acpi_target_sleep_state ACPI_STATE_S0 | ||
166 | #endif /* CONFIG_ACPI_SLEEP */ | 168 | #endif /* CONFIG_ACPI_SLEEP */ |
167 | 169 | ||
168 | #ifdef CONFIG_SUSPEND | 170 | #ifdef CONFIG_SUSPEND |
diff --git a/drivers/acpi/toshiba_acpi.c b/drivers/acpi/toshiba_acpi.c index 2a632f8b7a05..66aac06f2ac5 100644 --- a/drivers/acpi/toshiba_acpi.c +++ b/drivers/acpi/toshiba_acpi.c | |||
@@ -371,6 +371,7 @@ static void bt_poll_rfkill(struct input_polled_dev *poll_dev) | |||
371 | RFKILL_STATE_HARD_BLOCKED); | 371 | RFKILL_STATE_HARD_BLOCKED); |
372 | input_report_switch(poll_dev->input, SW_RFKILL_ALL, | 372 | input_report_switch(poll_dev->input, SW_RFKILL_ALL, |
373 | new_rfk_state); | 373 | new_rfk_state); |
374 | input_sync(poll_dev->input); | ||
374 | } | 375 | } |
375 | } | 376 | } |
376 | 377 | ||
@@ -842,6 +843,7 @@ static int __init toshiba_acpi_init(void) | |||
842 | set_bit(EV_SW, toshiba_acpi.poll_dev->input->evbit); | 843 | set_bit(EV_SW, toshiba_acpi.poll_dev->input->evbit); |
843 | set_bit(SW_RFKILL_ALL, toshiba_acpi.poll_dev->input->swbit); | 844 | set_bit(SW_RFKILL_ALL, toshiba_acpi.poll_dev->input->swbit); |
844 | input_report_switch(toshiba_acpi.poll_dev->input, SW_RFKILL_ALL, TRUE); | 845 | input_report_switch(toshiba_acpi.poll_dev->input, SW_RFKILL_ALL, TRUE); |
846 | input_sync(toshiba_acpi.poll_dev->input); | ||
845 | 847 | ||
846 | ret = input_register_polled_device(toshiba_acpi.poll_dev); | 848 | ret = input_register_polled_device(toshiba_acpi.poll_dev); |
847 | if (ret) { | 849 | if (ret) { |
diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c index aeadd00411a1..a67b8e7c712d 100644 --- a/drivers/ata/ahci.c +++ b/drivers/ata/ahci.c | |||
@@ -49,6 +49,17 @@ | |||
49 | #define DRV_NAME "ahci" | 49 | #define DRV_NAME "ahci" |
50 | #define DRV_VERSION "3.0" | 50 | #define DRV_VERSION "3.0" |
51 | 51 | ||
52 | /* Enclosure Management Control */ | ||
53 | #define EM_CTRL_MSG_TYPE 0x000f0000 | ||
54 | |||
55 | /* Enclosure Management LED Message Type */ | ||
56 | #define EM_MSG_LED_HBA_PORT 0x0000000f | ||
57 | #define EM_MSG_LED_PMP_SLOT 0x0000ff00 | ||
58 | #define EM_MSG_LED_VALUE 0xffff0000 | ||
59 | #define EM_MSG_LED_VALUE_ACTIVITY 0x00070000 | ||
60 | #define EM_MSG_LED_VALUE_OFF 0xfff80000 | ||
61 | #define EM_MSG_LED_VALUE_ON 0x00010000 | ||
62 | |||
52 | static int ahci_skip_host_reset; | 63 | static int ahci_skip_host_reset; |
53 | module_param_named(skip_host_reset, ahci_skip_host_reset, int, 0444); | 64 | module_param_named(skip_host_reset, ahci_skip_host_reset, int, 0444); |
54 | MODULE_PARM_DESC(skip_host_reset, "skip global host reset (0=don't skip, 1=skip)"); | 65 | MODULE_PARM_DESC(skip_host_reset, "skip global host reset (0=don't skip, 1=skip)"); |
@@ -588,6 +599,9 @@ static const struct pci_device_id ahci_pci_tbl[] = { | |||
588 | { PCI_VDEVICE(MARVELL, 0x6145), board_ahci_mv }, /* 6145 */ | 599 | { PCI_VDEVICE(MARVELL, 0x6145), board_ahci_mv }, /* 6145 */ |
589 | { PCI_VDEVICE(MARVELL, 0x6121), board_ahci_mv }, /* 6121 */ | 600 | { PCI_VDEVICE(MARVELL, 0x6121), board_ahci_mv }, /* 6121 */ |
590 | 601 | ||
602 | /* Promise */ | ||
603 | { PCI_VDEVICE(PROMISE, 0x3f20), board_ahci }, /* PDC42819 */ | ||
604 | |||
591 | /* Generic, PCI class code for AHCI */ | 605 | /* Generic, PCI class code for AHCI */ |
592 | { PCI_ANY_ID, PCI_ANY_ID, PCI_ANY_ID, PCI_ANY_ID, | 606 | { PCI_ANY_ID, PCI_ANY_ID, PCI_ANY_ID, PCI_ANY_ID, |
593 | PCI_CLASS_STORAGE_SATA_AHCI, 0xffffff, board_ahci }, | 607 | PCI_CLASS_STORAGE_SATA_AHCI, 0xffffff, board_ahci }, |
@@ -1220,18 +1234,20 @@ static void ahci_sw_activity_blink(unsigned long arg) | |||
1220 | struct ahci_em_priv *emp = &pp->em_priv[link->pmp]; | 1234 | struct ahci_em_priv *emp = &pp->em_priv[link->pmp]; |
1221 | unsigned long led_message = emp->led_state; | 1235 | unsigned long led_message = emp->led_state; |
1222 | u32 activity_led_state; | 1236 | u32 activity_led_state; |
1237 | unsigned long flags; | ||
1223 | 1238 | ||
1224 | led_message &= 0xffff0000; | 1239 | led_message &= EM_MSG_LED_VALUE; |
1225 | led_message |= ap->port_no | (link->pmp << 8); | 1240 | led_message |= ap->port_no | (link->pmp << 8); |
1226 | 1241 | ||
1227 | /* check to see if we've had activity. If so, | 1242 | /* check to see if we've had activity. If so, |
1228 | * toggle state of LED and reset timer. If not, | 1243 | * toggle state of LED and reset timer. If not, |
1229 | * turn LED to desired idle state. | 1244 | * turn LED to desired idle state. |
1230 | */ | 1245 | */ |
1246 | spin_lock_irqsave(ap->lock, flags); | ||
1231 | if (emp->saved_activity != emp->activity) { | 1247 | if (emp->saved_activity != emp->activity) { |
1232 | emp->saved_activity = emp->activity; | 1248 | emp->saved_activity = emp->activity; |
1233 | /* get the current LED state */ | 1249 | /* get the current LED state */ |
1234 | activity_led_state = led_message & 0x00010000; | 1250 | activity_led_state = led_message & EM_MSG_LED_VALUE_ON; |
1235 | 1251 | ||
1236 | if (activity_led_state) | 1252 | if (activity_led_state) |
1237 | activity_led_state = 0; | 1253 | activity_led_state = 0; |
@@ -1239,17 +1255,18 @@ static void ahci_sw_activity_blink(unsigned long arg) | |||
1239 | activity_led_state = 1; | 1255 | activity_led_state = 1; |
1240 | 1256 | ||
1241 | /* clear old state */ | 1257 | /* clear old state */ |
1242 | led_message &= 0xfff8ffff; | 1258 | led_message &= ~EM_MSG_LED_VALUE_ACTIVITY; |
1243 | 1259 | ||
1244 | /* toggle state */ | 1260 | /* toggle state */ |
1245 | led_message |= (activity_led_state << 16); | 1261 | led_message |= (activity_led_state << 16); |
1246 | mod_timer(&emp->timer, jiffies + msecs_to_jiffies(100)); | 1262 | mod_timer(&emp->timer, jiffies + msecs_to_jiffies(100)); |
1247 | } else { | 1263 | } else { |
1248 | /* switch to idle */ | 1264 | /* switch to idle */ |
1249 | led_message &= 0xfff8ffff; | 1265 | led_message &= ~EM_MSG_LED_VALUE_ACTIVITY; |
1250 | if (emp->blink_policy == BLINK_OFF) | 1266 | if (emp->blink_policy == BLINK_OFF) |
1251 | led_message |= (1 << 16); | 1267 | led_message |= (1 << 16); |
1252 | } | 1268 | } |
1269 | spin_unlock_irqrestore(ap->lock, flags); | ||
1253 | ahci_transmit_led_message(ap, led_message, 4); | 1270 | ahci_transmit_led_message(ap, led_message, 4); |
1254 | } | 1271 | } |
1255 | 1272 | ||
@@ -1294,7 +1311,7 @@ static ssize_t ahci_transmit_led_message(struct ata_port *ap, u32 state, | |||
1294 | struct ahci_em_priv *emp; | 1311 | struct ahci_em_priv *emp; |
1295 | 1312 | ||
1296 | /* get the slot number from the message */ | 1313 | /* get the slot number from the message */ |
1297 | pmp = (state & 0x0000ff00) >> 8; | 1314 | pmp = (state & EM_MSG_LED_PMP_SLOT) >> 8; |
1298 | if (pmp < MAX_SLOTS) | 1315 | if (pmp < MAX_SLOTS) |
1299 | emp = &pp->em_priv[pmp]; | 1316 | emp = &pp->em_priv[pmp]; |
1300 | else | 1317 | else |
@@ -1319,7 +1336,7 @@ static ssize_t ahci_transmit_led_message(struct ata_port *ap, u32 state, | |||
1319 | message[0] |= (4 << 8); | 1336 | message[0] |= (4 << 8); |
1320 | 1337 | ||
1321 | /* ignore 0:4 of byte zero, fill in port info yourself */ | 1338 | /* ignore 0:4 of byte zero, fill in port info yourself */ |
1322 | message[1] = ((state & 0xfffffff0) | ap->port_no); | 1339 | message[1] = ((state & ~EM_MSG_LED_HBA_PORT) | ap->port_no); |
1323 | 1340 | ||
1324 | /* write message to EM_LOC */ | 1341 | /* write message to EM_LOC */ |
1325 | writel(message[0], mmio + hpriv->em_loc); | 1342 | writel(message[0], mmio + hpriv->em_loc); |
@@ -1362,7 +1379,7 @@ static ssize_t ahci_led_store(struct ata_port *ap, const char *buf, | |||
1362 | state = simple_strtoul(buf, NULL, 0); | 1379 | state = simple_strtoul(buf, NULL, 0); |
1363 | 1380 | ||
1364 | /* get the slot number from the message */ | 1381 | /* get the slot number from the message */ |
1365 | pmp = (state & 0x0000ff00) >> 8; | 1382 | pmp = (state & EM_MSG_LED_PMP_SLOT) >> 8; |
1366 | if (pmp < MAX_SLOTS) | 1383 | if (pmp < MAX_SLOTS) |
1367 | emp = &pp->em_priv[pmp]; | 1384 | emp = &pp->em_priv[pmp]; |
1368 | else | 1385 | else |
@@ -1373,7 +1390,7 @@ static ssize_t ahci_led_store(struct ata_port *ap, const char *buf, | |||
1373 | * activity led through em_message | 1390 | * activity led through em_message |
1374 | */ | 1391 | */ |
1375 | if (emp->blink_policy) | 1392 | if (emp->blink_policy) |
1376 | state &= 0xfff8ffff; | 1393 | state &= ~EM_MSG_LED_VALUE_ACTIVITY; |
1377 | 1394 | ||
1378 | return ahci_transmit_led_message(ap, state, size); | 1395 | return ahci_transmit_led_message(ap, state, size); |
1379 | } | 1396 | } |
@@ -1392,16 +1409,16 @@ static ssize_t ahci_activity_store(struct ata_device *dev, enum sw_activity val) | |||
1392 | link->flags &= ~(ATA_LFLAG_SW_ACTIVITY); | 1409 | link->flags &= ~(ATA_LFLAG_SW_ACTIVITY); |
1393 | 1410 | ||
1394 | /* set the LED to OFF */ | 1411 | /* set the LED to OFF */ |
1395 | port_led_state &= 0xfff80000; | 1412 | port_led_state &= EM_MSG_LED_VALUE_OFF; |
1396 | port_led_state |= (ap->port_no | (link->pmp << 8)); | 1413 | port_led_state |= (ap->port_no | (link->pmp << 8)); |
1397 | ahci_transmit_led_message(ap, port_led_state, 4); | 1414 | ahci_transmit_led_message(ap, port_led_state, 4); |
1398 | } else { | 1415 | } else { |
1399 | link->flags |= ATA_LFLAG_SW_ACTIVITY; | 1416 | link->flags |= ATA_LFLAG_SW_ACTIVITY; |
1400 | if (val == BLINK_OFF) { | 1417 | if (val == BLINK_OFF) { |
1401 | /* set LED to ON for idle */ | 1418 | /* set LED to ON for idle */ |
1402 | port_led_state &= 0xfff80000; | 1419 | port_led_state &= EM_MSG_LED_VALUE_OFF; |
1403 | port_led_state |= (ap->port_no | (link->pmp << 8)); | 1420 | port_led_state |= (ap->port_no | (link->pmp << 8)); |
1404 | port_led_state |= 0x00010000; /* check this */ | 1421 | port_led_state |= EM_MSG_LED_VALUE_ON; /* check this */ |
1405 | ahci_transmit_led_message(ap, port_led_state, 4); | 1422 | ahci_transmit_led_message(ap, port_led_state, 4); |
1406 | } | 1423 | } |
1407 | } | 1424 | } |
@@ -2612,7 +2629,7 @@ static int ahci_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
2612 | u32 em_loc = readl(mmio + HOST_EM_LOC); | 2629 | u32 em_loc = readl(mmio + HOST_EM_LOC); |
2613 | u32 em_ctl = readl(mmio + HOST_EM_CTL); | 2630 | u32 em_ctl = readl(mmio + HOST_EM_CTL); |
2614 | 2631 | ||
2615 | messages = (em_ctl & 0x000f0000) >> 16; | 2632 | messages = (em_ctl & EM_CTRL_MSG_TYPE) >> 16; |
2616 | 2633 | ||
2617 | /* we only support LED message type right now */ | 2634 | /* we only support LED message type right now */ |
2618 | if ((messages & 0x01) && (ahci_em_messages == 1)) { | 2635 | if ((messages & 0x01) && (ahci_em_messages == 1)) { |
diff --git a/drivers/ata/ata_generic.c b/drivers/ata/ata_generic.c index 75a406f5e694..5c33767e66de 100644 --- a/drivers/ata/ata_generic.c +++ b/drivers/ata/ata_generic.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * ata_generic.c - Generic PATA/SATA controller driver. | 2 | * ata_generic.c - Generic PATA/SATA controller driver. |
3 | * Copyright 2005 Red Hat Inc <alan@redhat.com>, all rights reserved. | 3 | * Copyright 2005 Red Hat Inc, all rights reserved. |
4 | * | 4 | * |
5 | * Elements from ide/pci/generic.c | 5 | * Elements from ide/pci/generic.c |
6 | * Copyright (C) 2001-2002 Andre Hedrick <andre@linux-ide.org> | 6 | * Copyright (C) 2001-2002 Andre Hedrick <andre@linux-ide.org> |
diff --git a/drivers/ata/ata_piix.c b/drivers/ata/ata_piix.c index e9e32ed6b1a3..52dc2d8b8f22 100644 --- a/drivers/ata/ata_piix.c +++ b/drivers/ata/ata_piix.c | |||
@@ -14,7 +14,7 @@ | |||
14 | * | 14 | * |
15 | * Copyright (C) 1998-1999 Andrzej Krzysztofowicz, Author and Maintainer | 15 | * Copyright (C) 1998-1999 Andrzej Krzysztofowicz, Author and Maintainer |
16 | * Copyright (C) 1998-2000 Andre Hedrick <andre@linux-ide.org> | 16 | * Copyright (C) 1998-2000 Andre Hedrick <andre@linux-ide.org> |
17 | * Copyright (C) 2003 Red Hat Inc <alan@redhat.com> | 17 | * Copyright (C) 2003 Red Hat Inc |
18 | * | 18 | * |
19 | * | 19 | * |
20 | * This program is free software; you can redistribute it and/or modify | 20 | * This program is free software; you can redistribute it and/or modify |
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index bbb3cae57492..2ff633c119e2 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c | |||
@@ -1713,8 +1713,6 @@ unsigned ata_exec_internal_sg(struct ata_device *dev, | |||
1713 | else | 1713 | else |
1714 | tag = 0; | 1714 | tag = 0; |
1715 | 1715 | ||
1716 | if (test_and_set_bit(tag, &ap->qc_allocated)) | ||
1717 | BUG(); | ||
1718 | qc = __ata_qc_from_tag(ap, tag); | 1716 | qc = __ata_qc_from_tag(ap, tag); |
1719 | 1717 | ||
1720 | qc->tag = tag; | 1718 | qc->tag = tag; |
@@ -4158,29 +4156,33 @@ static int cable_is_40wire(struct ata_port *ap) | |||
4158 | struct ata_link *link; | 4156 | struct ata_link *link; |
4159 | struct ata_device *dev; | 4157 | struct ata_device *dev; |
4160 | 4158 | ||
4161 | /* If the controller thinks we are 40 wire, we are */ | 4159 | /* If the controller thinks we are 40 wire, we are. */ |
4162 | if (ap->cbl == ATA_CBL_PATA40) | 4160 | if (ap->cbl == ATA_CBL_PATA40) |
4163 | return 1; | 4161 | return 1; |
4164 | /* If the controller thinks we are 80 wire, we are */ | 4162 | |
4163 | /* If the controller thinks we are 80 wire, we are. */ | ||
4165 | if (ap->cbl == ATA_CBL_PATA80 || ap->cbl == ATA_CBL_SATA) | 4164 | if (ap->cbl == ATA_CBL_PATA80 || ap->cbl == ATA_CBL_SATA) |
4166 | return 0; | 4165 | return 0; |
4167 | /* If the system is known to be 40 wire short cable (eg laptop), | 4166 | |
4168 | then we allow 80 wire modes even if the drive isn't sure */ | 4167 | /* If the system is known to be 40 wire short cable (eg |
4168 | * laptop), then we allow 80 wire modes even if the drive | ||
4169 | * isn't sure. | ||
4170 | */ | ||
4169 | if (ap->cbl == ATA_CBL_PATA40_SHORT) | 4171 | if (ap->cbl == ATA_CBL_PATA40_SHORT) |
4170 | return 0; | 4172 | return 0; |
4171 | /* If the controller doesn't know we scan | 4173 | |
4172 | 4174 | /* If the controller doesn't know, we scan. | |
4173 | - Note: We look for all 40 wire detects at this point. | 4175 | * |
4174 | Any 80 wire detect is taken to be 80 wire cable | 4176 | * Note: We look for all 40 wire detects at this point. Any |
4175 | because | 4177 | * 80 wire detect is taken to be 80 wire cable because |
4176 | - In many setups only the one drive (slave if present) | 4178 | * - in many setups only the one drive (slave if present) will |
4177 | will give a valid detect | 4179 | * give a valid detect |
4178 | - If you have a non detect capable drive you don't | 4180 | * - if you have a non detect capable drive you don't want it |
4179 | want it to colour the choice | 4181 | * to colour the choice |
4180 | */ | 4182 | */ |
4181 | ata_port_for_each_link(link, ap) { | 4183 | ata_port_for_each_link(link, ap) { |
4182 | ata_link_for_each_dev(dev, link) { | 4184 | ata_link_for_each_dev(dev, link) { |
4183 | if (!ata_is_40wire(dev)) | 4185 | if (ata_dev_enabled(dev) && !ata_is_40wire(dev)) |
4184 | return 0; | 4186 | return 0; |
4185 | } | 4187 | } |
4186 | } | 4188 | } |
@@ -4553,54 +4555,28 @@ void swap_buf_le16(u16 *buf, unsigned int buf_words) | |||
4553 | } | 4555 | } |
4554 | 4556 | ||
4555 | /** | 4557 | /** |
4556 | * ata_qc_new - Request an available ATA command, for queueing | ||
4557 | * @ap: Port associated with device @dev | ||
4558 | * @dev: Device from whom we request an available command structure | ||
4559 | * | ||
4560 | * LOCKING: | ||
4561 | * None. | ||
4562 | */ | ||
4563 | |||
4564 | static struct ata_queued_cmd *ata_qc_new(struct ata_port *ap) | ||
4565 | { | ||
4566 | struct ata_queued_cmd *qc = NULL; | ||
4567 | unsigned int i; | ||
4568 | |||
4569 | /* no command while frozen */ | ||
4570 | if (unlikely(ap->pflags & ATA_PFLAG_FROZEN)) | ||
4571 | return NULL; | ||
4572 | |||
4573 | /* the last tag is reserved for internal command. */ | ||
4574 | for (i = 0; i < ATA_MAX_QUEUE - 1; i++) | ||
4575 | if (!test_and_set_bit(i, &ap->qc_allocated)) { | ||
4576 | qc = __ata_qc_from_tag(ap, i); | ||
4577 | break; | ||
4578 | } | ||
4579 | |||
4580 | if (qc) | ||
4581 | qc->tag = i; | ||
4582 | |||
4583 | return qc; | ||
4584 | } | ||
4585 | |||
4586 | /** | ||
4587 | * ata_qc_new_init - Request an available ATA command, and initialize it | 4558 | * ata_qc_new_init - Request an available ATA command, and initialize it |
4588 | * @dev: Device from whom we request an available command structure | 4559 | * @dev: Device from whom we request an available command structure |
4560 | * @tag: command tag | ||
4589 | * | 4561 | * |
4590 | * LOCKING: | 4562 | * LOCKING: |
4591 | * None. | 4563 | * None. |
4592 | */ | 4564 | */ |
4593 | 4565 | ||
4594 | struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev) | 4566 | struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev, int tag) |
4595 | { | 4567 | { |
4596 | struct ata_port *ap = dev->link->ap; | 4568 | struct ata_port *ap = dev->link->ap; |
4597 | struct ata_queued_cmd *qc; | 4569 | struct ata_queued_cmd *qc; |
4598 | 4570 | ||
4599 | qc = ata_qc_new(ap); | 4571 | if (unlikely(ap->pflags & ATA_PFLAG_FROZEN)) |
4572 | return NULL; | ||
4573 | |||
4574 | qc = __ata_qc_from_tag(ap, tag); | ||
4600 | if (qc) { | 4575 | if (qc) { |
4601 | qc->scsicmd = NULL; | 4576 | qc->scsicmd = NULL; |
4602 | qc->ap = ap; | 4577 | qc->ap = ap; |
4603 | qc->dev = dev; | 4578 | qc->dev = dev; |
4579 | qc->tag = tag; | ||
4604 | 4580 | ||
4605 | ata_qc_reinit(qc); | 4581 | ata_qc_reinit(qc); |
4606 | } | 4582 | } |
@@ -4608,31 +4584,6 @@ struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev) | |||
4608 | return qc; | 4584 | return qc; |
4609 | } | 4585 | } |
4610 | 4586 | ||
4611 | /** | ||
4612 | * ata_qc_free - free unused ata_queued_cmd | ||
4613 | * @qc: Command to complete | ||
4614 | * | ||
4615 | * Designed to free unused ata_queued_cmd object | ||
4616 | * in case something prevents using it. | ||
4617 | * | ||
4618 | * LOCKING: | ||
4619 | * spin_lock_irqsave(host lock) | ||
4620 | */ | ||
4621 | void ata_qc_free(struct ata_queued_cmd *qc) | ||
4622 | { | ||
4623 | struct ata_port *ap = qc->ap; | ||
4624 | unsigned int tag; | ||
4625 | |||
4626 | WARN_ON(qc == NULL); /* ata_qc_from_tag _might_ return NULL */ | ||
4627 | |||
4628 | qc->flags = 0; | ||
4629 | tag = qc->tag; | ||
4630 | if (likely(ata_tag_valid(tag))) { | ||
4631 | qc->tag = ATA_TAG_POISON; | ||
4632 | clear_bit(tag, &ap->qc_allocated); | ||
4633 | } | ||
4634 | } | ||
4635 | |||
4636 | void __ata_qc_complete(struct ata_queued_cmd *qc) | 4587 | void __ata_qc_complete(struct ata_queued_cmd *qc) |
4637 | { | 4588 | { |
4638 | struct ata_port *ap = qc->ap; | 4589 | struct ata_port *ap = qc->ap; |
diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c index 5d687d7cffae..8077bdf5d30d 100644 --- a/drivers/ata/libata-eh.c +++ b/drivers/ata/libata-eh.c | |||
@@ -603,6 +603,9 @@ void ata_scsi_error(struct Scsi_Host *host) | |||
603 | ata_link_for_each_dev(dev, link) { | 603 | ata_link_for_each_dev(dev, link) { |
604 | int devno = dev->devno; | 604 | int devno = dev->devno; |
605 | 605 | ||
606 | if (!ata_dev_enabled(dev)) | ||
607 | continue; | ||
608 | |||
606 | ehc->saved_xfer_mode[devno] = dev->xfer_mode; | 609 | ehc->saved_xfer_mode[devno] = dev->xfer_mode; |
607 | if (ata_ncq_enabled(dev)) | 610 | if (ata_ncq_enabled(dev)) |
608 | ehc->saved_ncq_enabled |= 1 << devno; | 611 | ehc->saved_ncq_enabled |= 1 << devno; |
@@ -1161,6 +1164,7 @@ void ata_eh_detach_dev(struct ata_device *dev) | |||
1161 | { | 1164 | { |
1162 | struct ata_link *link = dev->link; | 1165 | struct ata_link *link = dev->link; |
1163 | struct ata_port *ap = link->ap; | 1166 | struct ata_port *ap = link->ap; |
1167 | struct ata_eh_context *ehc = &link->eh_context; | ||
1164 | unsigned long flags; | 1168 | unsigned long flags; |
1165 | 1169 | ||
1166 | ata_dev_disable(dev); | 1170 | ata_dev_disable(dev); |
@@ -1174,9 +1178,11 @@ void ata_eh_detach_dev(struct ata_device *dev) | |||
1174 | ap->pflags |= ATA_PFLAG_SCSI_HOTPLUG; | 1178 | ap->pflags |= ATA_PFLAG_SCSI_HOTPLUG; |
1175 | } | 1179 | } |
1176 | 1180 | ||
1177 | /* clear per-dev EH actions */ | 1181 | /* clear per-dev EH info */ |
1178 | ata_eh_clear_action(link, dev, &link->eh_info, ATA_EH_PERDEV_MASK); | 1182 | ata_eh_clear_action(link, dev, &link->eh_info, ATA_EH_PERDEV_MASK); |
1179 | ata_eh_clear_action(link, dev, &link->eh_context.i, ATA_EH_PERDEV_MASK); | 1183 | ata_eh_clear_action(link, dev, &link->eh_context.i, ATA_EH_PERDEV_MASK); |
1184 | ehc->saved_xfer_mode[dev->devno] = 0; | ||
1185 | ehc->saved_ncq_enabled &= ~(1 << dev->devno); | ||
1180 | 1186 | ||
1181 | spin_unlock_irqrestore(ap->lock, flags); | 1187 | spin_unlock_irqrestore(ap->lock, flags); |
1182 | } | 1188 | } |
@@ -2787,6 +2793,9 @@ int ata_set_mode(struct ata_link *link, struct ata_device **r_failed_dev) | |||
2787 | 2793 | ||
2788 | /* if data transfer is verified, clear DUBIOUS_XFER on ering top */ | 2794 | /* if data transfer is verified, clear DUBIOUS_XFER on ering top */ |
2789 | ata_link_for_each_dev(dev, link) { | 2795 | ata_link_for_each_dev(dev, link) { |
2796 | if (!ata_dev_enabled(dev)) | ||
2797 | continue; | ||
2798 | |||
2790 | if (!(dev->flags & ATA_DFLAG_DUBIOUS_XFER)) { | 2799 | if (!(dev->flags & ATA_DFLAG_DUBIOUS_XFER)) { |
2791 | struct ata_ering_entry *ent; | 2800 | struct ata_ering_entry *ent; |
2792 | 2801 | ||
@@ -2808,6 +2817,9 @@ int ata_set_mode(struct ata_link *link, struct ata_device **r_failed_dev) | |||
2808 | u8 saved_xfer_mode = ehc->saved_xfer_mode[dev->devno]; | 2817 | u8 saved_xfer_mode = ehc->saved_xfer_mode[dev->devno]; |
2809 | u8 saved_ncq = !!(ehc->saved_ncq_enabled & (1 << dev->devno)); | 2818 | u8 saved_ncq = !!(ehc->saved_ncq_enabled & (1 << dev->devno)); |
2810 | 2819 | ||
2820 | if (!ata_dev_enabled(dev)) | ||
2821 | continue; | ||
2822 | |||
2811 | if (dev->xfer_mode != saved_xfer_mode || | 2823 | if (dev->xfer_mode != saved_xfer_mode || |
2812 | ata_ncq_enabled(dev) != saved_ncq) | 2824 | ata_ncq_enabled(dev) != saved_ncq) |
2813 | dev->flags |= ATA_DFLAG_DUBIOUS_XFER; | 2825 | dev->flags |= ATA_DFLAG_DUBIOUS_XFER; |
diff --git a/drivers/ata/libata-scsi.c b/drivers/ata/libata-scsi.c index 5d312dc9be9f..bbb30d882f05 100644 --- a/drivers/ata/libata-scsi.c +++ b/drivers/ata/libata-scsi.c | |||
@@ -708,7 +708,11 @@ static struct ata_queued_cmd *ata_scsi_qc_new(struct ata_device *dev, | |||
708 | { | 708 | { |
709 | struct ata_queued_cmd *qc; | 709 | struct ata_queued_cmd *qc; |
710 | 710 | ||
711 | qc = ata_qc_new_init(dev); | 711 | if (cmd->request->tag != -1) |
712 | qc = ata_qc_new_init(dev, cmd->request->tag); | ||
713 | else | ||
714 | qc = ata_qc_new_init(dev, 0); | ||
715 | |||
712 | if (qc) { | 716 | if (qc) { |
713 | qc->scsicmd = cmd; | 717 | qc->scsicmd = cmd; |
714 | qc->scsidone = done; | 718 | qc->scsidone = done; |
@@ -1103,7 +1107,17 @@ static int ata_scsi_dev_config(struct scsi_device *sdev, | |||
1103 | 1107 | ||
1104 | depth = min(sdev->host->can_queue, ata_id_queue_depth(dev->id)); | 1108 | depth = min(sdev->host->can_queue, ata_id_queue_depth(dev->id)); |
1105 | depth = min(ATA_MAX_QUEUE - 1, depth); | 1109 | depth = min(ATA_MAX_QUEUE - 1, depth); |
1106 | scsi_adjust_queue_depth(sdev, MSG_SIMPLE_TAG, depth); | 1110 | |
1111 | /* | ||
1112 | * If this device is behind a port multiplier, we have | ||
1113 | * to share the tag map between all devices on that PMP. | ||
1114 | * Set up the shared tag map here and we get automatic. | ||
1115 | */ | ||
1116 | if (dev->link->ap->pmp_link) | ||
1117 | scsi_init_shared_tag_map(sdev->host, ATA_MAX_QUEUE - 1); | ||
1118 | |||
1119 | scsi_set_tag_type(sdev, MSG_SIMPLE_TAG); | ||
1120 | scsi_activate_tcq(sdev, depth); | ||
1107 | } | 1121 | } |
1108 | 1122 | ||
1109 | return 0; | 1123 | return 0; |
@@ -1943,6 +1957,11 @@ static unsigned int ata_scsiop_inq_std(struct ata_scsi_args *args, u8 *rbuf) | |||
1943 | hdr[1] |= (1 << 7); | 1957 | hdr[1] |= (1 << 7); |
1944 | 1958 | ||
1945 | memcpy(rbuf, hdr, sizeof(hdr)); | 1959 | memcpy(rbuf, hdr, sizeof(hdr)); |
1960 | |||
1961 | /* if ncq, set tags supported */ | ||
1962 | if (ata_id_has_ncq(args->id)) | ||
1963 | rbuf[7] |= (1 << 1); | ||
1964 | |||
1946 | memcpy(&rbuf[8], "ATA ", 8); | 1965 | memcpy(&rbuf[8], "ATA ", 8); |
1947 | ata_id_string(args->id, &rbuf[16], ATA_ID_PROD, 16); | 1966 | ata_id_string(args->id, &rbuf[16], ATA_ID_PROD, 16); |
1948 | ata_id_string(args->id, &rbuf[32], ATA_ID_FW_REV, 4); | 1967 | ata_id_string(args->id, &rbuf[32], ATA_ID_FW_REV, 4); |
diff --git a/drivers/ata/libata.h b/drivers/ata/libata.h index fe2839e58774..d3831d39bdaa 100644 --- a/drivers/ata/libata.h +++ b/drivers/ata/libata.h | |||
@@ -74,7 +74,7 @@ extern struct ata_link *ata_dev_phys_link(struct ata_device *dev); | |||
74 | extern void ata_force_cbl(struct ata_port *ap); | 74 | extern void ata_force_cbl(struct ata_port *ap); |
75 | extern u64 ata_tf_to_lba(const struct ata_taskfile *tf); | 75 | extern u64 ata_tf_to_lba(const struct ata_taskfile *tf); |
76 | extern u64 ata_tf_to_lba48(const struct ata_taskfile *tf); | 76 | extern u64 ata_tf_to_lba48(const struct ata_taskfile *tf); |
77 | extern struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev); | 77 | extern struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev, int tag); |
78 | extern int ata_build_rw_tf(struct ata_taskfile *tf, struct ata_device *dev, | 78 | extern int ata_build_rw_tf(struct ata_taskfile *tf, struct ata_device *dev, |
79 | u64 block, u32 n_block, unsigned int tf_flags, | 79 | u64 block, u32 n_block, unsigned int tf_flags, |
80 | unsigned int tag); | 80 | unsigned int tag); |
@@ -103,7 +103,6 @@ extern int ata_dev_configure(struct ata_device *dev); | |||
103 | extern int sata_down_spd_limit(struct ata_link *link); | 103 | extern int sata_down_spd_limit(struct ata_link *link); |
104 | extern int ata_down_xfermask_limit(struct ata_device *dev, unsigned int sel); | 104 | extern int ata_down_xfermask_limit(struct ata_device *dev, unsigned int sel); |
105 | extern void ata_sg_clean(struct ata_queued_cmd *qc); | 105 | extern void ata_sg_clean(struct ata_queued_cmd *qc); |
106 | extern void ata_qc_free(struct ata_queued_cmd *qc); | ||
107 | extern void ata_qc_issue(struct ata_queued_cmd *qc); | 106 | extern void ata_qc_issue(struct ata_queued_cmd *qc); |
108 | extern void __ata_qc_complete(struct ata_queued_cmd *qc); | 107 | extern void __ata_qc_complete(struct ata_queued_cmd *qc); |
109 | extern int atapi_check_dma(struct ata_queued_cmd *qc); | 108 | extern int atapi_check_dma(struct ata_queued_cmd *qc); |
@@ -119,6 +118,22 @@ extern struct ata_port *ata_port_alloc(struct ata_host *host); | |||
119 | extern void ata_dev_enable_pm(struct ata_device *dev, enum link_pm policy); | 118 | extern void ata_dev_enable_pm(struct ata_device *dev, enum link_pm policy); |
120 | extern void ata_lpm_schedule(struct ata_port *ap, enum link_pm); | 119 | extern void ata_lpm_schedule(struct ata_port *ap, enum link_pm); |
121 | 120 | ||
121 | /** | ||
122 | * ata_qc_free - free unused ata_queued_cmd | ||
123 | * @qc: Command to complete | ||
124 | * | ||
125 | * Designed to free unused ata_queued_cmd object | ||
126 | * in case something prevents using it. | ||
127 | * | ||
128 | * LOCKING: | ||
129 | * spin_lock_irqsave(host lock) | ||
130 | */ | ||
131 | static inline void ata_qc_free(struct ata_queued_cmd *qc) | ||
132 | { | ||
133 | qc->flags = 0; | ||
134 | qc->tag = ATA_TAG_POISON; | ||
135 | } | ||
136 | |||
122 | /* libata-acpi.c */ | 137 | /* libata-acpi.c */ |
123 | #ifdef CONFIG_ATA_ACPI | 138 | #ifdef CONFIG_ATA_ACPI |
124 | extern void ata_acpi_associate_sata_port(struct ata_port *ap); | 139 | extern void ata_acpi_associate_sata_port(struct ata_port *ap); |
diff --git a/drivers/ata/pata_acpi.c b/drivers/ata/pata_acpi.c index eb919c16a03e..e2e332d8ff95 100644 --- a/drivers/ata/pata_acpi.c +++ b/drivers/ata/pata_acpi.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * ACPI PATA driver | 2 | * ACPI PATA driver |
3 | * | 3 | * |
4 | * (c) 2007 Red Hat <alan@redhat.com> | 4 | * (c) 2007 Red Hat |
5 | */ | 5 | */ |
6 | 6 | ||
7 | #include <linux/kernel.h> | 7 | #include <linux/kernel.h> |
diff --git a/drivers/ata/pata_ali.c b/drivers/ata/pata_ali.c index 5ca70fa1f587..73c466e452ca 100644 --- a/drivers/ata/pata_ali.c +++ b/drivers/ata/pata_ali.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_ali.c - ALI 15x3 PATA for new ATA layer | 2 | * pata_ali.c - ALI 15x3 PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * based in part upon | 5 | * based in part upon |
7 | * linux/drivers/ide/pci/alim15x3.c Version 0.17 2003/01/02 | 6 | * linux/drivers/ide/pci/alim15x3.c Version 0.17 2003/01/02 |
diff --git a/drivers/ata/pata_amd.c b/drivers/ata/pata_amd.c index 57dd00f463d3..0ec9c7d9fe9d 100644 --- a/drivers/ata/pata_amd.c +++ b/drivers/ata/pata_amd.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_amd.c - AMD PATA for new ATA layer | 2 | * pata_amd.c - AMD PATA for new ATA layer |
3 | * (C) 2005-2006 Red Hat Inc | 3 | * (C) 2005-2006 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * Based on pata-sil680. Errata information is taken from data sheets | 5 | * Based on pata-sil680. Errata information is taken from data sheets |
7 | * and the amd74xx.c driver by Vojtech Pavlik. Nvidia SATA devices are | 6 | * and the amd74xx.c driver by Vojtech Pavlik. Nvidia SATA devices are |
diff --git a/drivers/ata/pata_artop.c b/drivers/ata/pata_artop.c index 0f513bc11193..6b3092c75ffe 100644 --- a/drivers/ata/pata_artop.c +++ b/drivers/ata/pata_artop.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_artop.c - ARTOP ATA controller driver | 2 | * pata_artop.c - ARTOP ATA controller driver |
3 | * | 3 | * |
4 | * (C) 2006 Red Hat <alan@redhat.com> | 4 | * (C) 2006 Red Hat |
5 | * (C) 2007 Bartlomiej Zolnierkiewicz | 5 | * (C) 2007 Bartlomiej Zolnierkiewicz |
6 | * | 6 | * |
7 | * Based in part on drivers/ide/pci/aec62xx.c | 7 | * Based in part on drivers/ide/pci/aec62xx.c |
diff --git a/drivers/ata/pata_atiixp.c b/drivers/ata/pata_atiixp.c index e8a0d99d7356..0e2cde8f9973 100644 --- a/drivers/ata/pata_atiixp.c +++ b/drivers/ata/pata_atiixp.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_atiixp.c - ATI PATA for new ATA layer | 2 | * pata_atiixp.c - ATI PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * Based on | 5 | * Based on |
7 | * | 6 | * |
diff --git a/drivers/ata/pata_cmd640.c b/drivers/ata/pata_cmd640.c index 2de30b990278..34a394264c3d 100644 --- a/drivers/ata/pata_cmd640.c +++ b/drivers/ata/pata_cmd640.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_cmd640.c - CMD640 PCI PATA for new ATA layer | 2 | * pata_cmd640.c - CMD640 PCI PATA for new ATA layer |
3 | * (C) 2007 Red Hat Inc | 3 | * (C) 2007 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * Based upon | 5 | * Based upon |
7 | * linux/drivers/ide/pci/cmd640.c Version 1.02 Sep 01, 1996 | 6 | * linux/drivers/ide/pci/cmd640.c Version 1.02 Sep 01, 1996 |
diff --git a/drivers/ata/pata_cmd64x.c b/drivers/ata/pata_cmd64x.c index ddd09b7d98c9..3167d8fed2f2 100644 --- a/drivers/ata/pata_cmd64x.c +++ b/drivers/ata/pata_cmd64x.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_cmd64x.c - CMD64x PATA for new ATA layer | 2 | * pata_cmd64x.c - CMD64x PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | 4 | * Alan Cox <alan@lxorguk.ukuu.org.uk> |
5 | * | 5 | * |
6 | * Based upon | 6 | * Based upon |
7 | * linux/drivers/ide/pci/cmd64x.c Version 1.30 Sept 10, 2002 | 7 | * linux/drivers/ide/pci/cmd64x.c Version 1.30 Sept 10, 2002 |
diff --git a/drivers/ata/pata_cs5530.c b/drivers/ata/pata_cs5530.c index 0c4b271a9d5a..bba453381f44 100644 --- a/drivers/ata/pata_cs5530.c +++ b/drivers/ata/pata_cs5530.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata-cs5530.c - CS5530 PATA for new ATA layer | 2 | * pata-cs5530.c - CS5530 PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * based upon cs5530.c by Mark Lord. | 5 | * based upon cs5530.c by Mark Lord. |
7 | * | 6 | * |
diff --git a/drivers/ata/pata_cs5535.c b/drivers/ata/pata_cs5535.c index f1b6556f0483..1b2d4a0f5f74 100644 --- a/drivers/ata/pata_cs5535.c +++ b/drivers/ata/pata_cs5535.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata-cs5535.c - CS5535 PATA for new ATA layer | 2 | * pata-cs5535.c - CS5535 PATA for new ATA layer |
3 | * (C) 2005-2006 Red Hat Inc | 3 | * (C) 2005-2006 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | 4 | * Alan Cox <alan@lxorguk.ukuu.org.uk> |
5 | * | 5 | * |
6 | * based upon cs5535.c from AMD <Jens.Altmann@amd.com> as cleaned up and | 6 | * based upon cs5535.c from AMD <Jens.Altmann@amd.com> as cleaned up and |
7 | * made readable and Linux style by Wolfgang Zuleger <wolfgang.zuleger@gmx.de | 7 | * made readable and Linux style by Wolfgang Zuleger <wolfgang.zuleger@gmx.de |
diff --git a/drivers/ata/pata_cypress.c b/drivers/ata/pata_cypress.c index 2ff62608ae37..d546425cd380 100644 --- a/drivers/ata/pata_cypress.c +++ b/drivers/ata/pata_cypress.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_cypress.c - Cypress PATA for new ATA layer | 2 | * pata_cypress.c - Cypress PATA for new ATA layer |
3 | * (C) 2006 Red Hat Inc | 3 | * (C) 2006 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | 4 | * Alan Cox |
5 | * | 5 | * |
6 | * Based heavily on | 6 | * Based heavily on |
7 | * linux/drivers/ide/pci/cy82c693.c Version 0.40 Sep. 10, 2002 | 7 | * linux/drivers/ide/pci/cy82c693.c Version 0.40 Sep. 10, 2002 |
diff --git a/drivers/ata/pata_efar.c b/drivers/ata/pata_efar.c index 9fba82976ba6..ac6392ea35b0 100644 --- a/drivers/ata/pata_efar.c +++ b/drivers/ata/pata_efar.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_efar.c - EFAR PIIX clone controller driver | 2 | * pata_efar.c - EFAR PIIX clone controller driver |
3 | * | 3 | * |
4 | * (C) 2005 Red Hat <alan@redhat.com> | 4 | * (C) 2005 Red Hat |
5 | * | 5 | * |
6 | * Some parts based on ata_piix.c by Jeff Garzik and others. | 6 | * Some parts based on ata_piix.c by Jeff Garzik and others. |
7 | * | 7 | * |
diff --git a/drivers/ata/pata_isapnp.c b/drivers/ata/pata_isapnp.c index 6a111baab523..15cdb9148aab 100644 --- a/drivers/ata/pata_isapnp.c +++ b/drivers/ata/pata_isapnp.c | |||
@@ -1,7 +1,7 @@ | |||
1 | 1 | ||
2 | /* | 2 | /* |
3 | * pata-isapnp.c - ISA PnP PATA controller driver. | 3 | * pata-isapnp.c - ISA PnP PATA controller driver. |
4 | * Copyright 2005/2006 Red Hat Inc <alan@redhat.com>, all rights reserved. | 4 | * Copyright 2005/2006 Red Hat Inc, all rights reserved. |
5 | * | 5 | * |
6 | * Based in part on ide-pnp.c by Andrey Panin <pazke@donpac.ru> | 6 | * Based in part on ide-pnp.c by Andrey Panin <pazke@donpac.ru> |
7 | */ | 7 | */ |
diff --git a/drivers/ata/pata_it821x.c b/drivers/ata/pata_it821x.c index 0221c9a46769..860ede526282 100644 --- a/drivers/ata/pata_it821x.c +++ b/drivers/ata/pata_it821x.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_it821x.c - IT821x PATA for new ATA layer | 2 | * pata_it821x.c - IT821x PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | 4 | * Alan Cox <alan@lxorguk.ukuu.org.uk> |
5 | * (C) 2007 Bartlomiej Zolnierkiewicz | 5 | * (C) 2007 Bartlomiej Zolnierkiewicz |
6 | * | 6 | * |
7 | * based upon | 7 | * based upon |
@@ -10,7 +10,7 @@ | |||
10 | * | 10 | * |
11 | * linux/drivers/ide/pci/it821x.c Version 0.09 December 2004 | 11 | * linux/drivers/ide/pci/it821x.c Version 0.09 December 2004 |
12 | * | 12 | * |
13 | * Copyright (C) 2004 Red Hat <alan@redhat.com> | 13 | * Copyright (C) 2004 Red Hat |
14 | * | 14 | * |
15 | * May be copied or modified under the terms of the GNU General Public License | 15 | * May be copied or modified under the terms of the GNU General Public License |
16 | * Based in part on the ITE vendor provided SCSI driver. | 16 | * Based in part on the ITE vendor provided SCSI driver. |
@@ -557,9 +557,8 @@ static unsigned int it821x_read_id(struct ata_device *adev, | |||
557 | if (strstr(model_num, "Integrated Technology Express")) { | 557 | if (strstr(model_num, "Integrated Technology Express")) { |
558 | /* Set feature bits the firmware neglects */ | 558 | /* Set feature bits the firmware neglects */ |
559 | id[49] |= 0x0300; /* LBA, DMA */ | 559 | id[49] |= 0x0300; /* LBA, DMA */ |
560 | id[82] |= 0x0400; /* LBA48 */ | ||
561 | id[83] &= 0x7FFF; | 560 | id[83] &= 0x7FFF; |
562 | id[83] |= 0x4000; /* Word 83 is valid */ | 561 | id[83] |= 0x4400; /* Word 83 is valid and LBA48 */ |
563 | id[86] |= 0x0400; /* LBA48 on */ | 562 | id[86] |= 0x0400; /* LBA48 on */ |
564 | id[ATA_ID_MAJOR_VER] |= 0x1F; | 563 | id[ATA_ID_MAJOR_VER] |= 0x1F; |
565 | } | 564 | } |
diff --git a/drivers/ata/pata_jmicron.c b/drivers/ata/pata_jmicron.c index 73b7596816b4..38cf1ab2d289 100644 --- a/drivers/ata/pata_jmicron.c +++ b/drivers/ata/pata_jmicron.c | |||
@@ -4,7 +4,7 @@ | |||
4 | * driven by AHCI in the usual configuration although | 4 | * driven by AHCI in the usual configuration although |
5 | * this driver can handle other setups if we need it. | 5 | * this driver can handle other setups if we need it. |
6 | * | 6 | * |
7 | * (c) 2006 Red Hat <alan@redhat.com> | 7 | * (c) 2006 Red Hat |
8 | */ | 8 | */ |
9 | 9 | ||
10 | #include <linux/kernel.h> | 10 | #include <linux/kernel.h> |
diff --git a/drivers/ata/pata_legacy.c b/drivers/ata/pata_legacy.c index bc037ffce200..930c2208640b 100644 --- a/drivers/ata/pata_legacy.c +++ b/drivers/ata/pata_legacy.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata-legacy.c - Legacy port PATA/SATA controller driver. | 2 | * pata-legacy.c - Legacy port PATA/SATA controller driver. |
3 | * Copyright 2005/2006 Red Hat <alan@redhat.com>, all rights reserved. | 3 | * Copyright 2005/2006 Red Hat, all rights reserved. |
4 | * | 4 | * |
5 | * This program is free software; you can redistribute it and/or modify | 5 | * This program is free software; you can redistribute it and/or modify |
6 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
diff --git a/drivers/ata/pata_marvell.c b/drivers/ata/pata_marvell.c index 0d87eec84966..76e399bf8c1b 100644 --- a/drivers/ata/pata_marvell.c +++ b/drivers/ata/pata_marvell.c | |||
@@ -5,7 +5,7 @@ | |||
5 | * isn't making full use of the device functionality but it is | 5 | * isn't making full use of the device functionality but it is |
6 | * easy to get working. | 6 | * easy to get working. |
7 | * | 7 | * |
8 | * (c) 2006 Red Hat <alan@redhat.com> | 8 | * (c) 2006 Red Hat |
9 | */ | 9 | */ |
10 | 10 | ||
11 | #include <linux/kernel.h> | 11 | #include <linux/kernel.h> |
diff --git a/drivers/ata/pata_mpiix.c b/drivers/ata/pata_mpiix.c index 7d7e3fdab71f..7c8faa48b5f3 100644 --- a/drivers/ata/pata_mpiix.c +++ b/drivers/ata/pata_mpiix.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_mpiix.c - Intel MPIIX PATA for new ATA layer | 2 | * pata_mpiix.c - Intel MPIIX PATA for new ATA layer |
3 | * (C) 2005-2006 Red Hat Inc | 3 | * (C) 2005-2006 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | 4 | * Alan Cox <alan@lxorguk.ukuu.org.uk> |
5 | * | 5 | * |
6 | * The MPIIX is different enough to the PIIX4 and friends that we give it | 6 | * The MPIIX is different enough to the PIIX4 and friends that we give it |
7 | * a separate driver. The old ide/pci code handles this by just not tuning | 7 | * a separate driver. The old ide/pci code handles this by just not tuning |
diff --git a/drivers/ata/pata_netcell.c b/drivers/ata/pata_netcell.c index d9719c8b9dbe..9dc05e1656a8 100644 --- a/drivers/ata/pata_netcell.c +++ b/drivers/ata/pata_netcell.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_netcell.c - Netcell PATA driver | 2 | * pata_netcell.c - Netcell PATA driver |
3 | * | 3 | * |
4 | * (c) 2006 Red Hat <alan@redhat.com> | 4 | * (c) 2006 Red Hat |
5 | */ | 5 | */ |
6 | 6 | ||
7 | #include <linux/kernel.h> | 7 | #include <linux/kernel.h> |
diff --git a/drivers/ata/pata_ninja32.c b/drivers/ata/pata_ninja32.c index 565e67cd13fa..4e466eae8b46 100644 --- a/drivers/ata/pata_ninja32.c +++ b/drivers/ata/pata_ninja32.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_ninja32.c - Ninja32 PATA for new ATA layer | 2 | * pata_ninja32.c - Ninja32 PATA for new ATA layer |
3 | * (C) 2007 Red Hat Inc | 3 | * (C) 2007 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * Note: The controller like many controllers has shared timings for | 5 | * Note: The controller like many controllers has shared timings for |
7 | * PIO and DMA. We thus flip to the DMA timings in dma_start and flip back | 6 | * PIO and DMA. We thus flip to the DMA timings in dma_start and flip back |
@@ -45,7 +44,7 @@ | |||
45 | #include <linux/libata.h> | 44 | #include <linux/libata.h> |
46 | 45 | ||
47 | #define DRV_NAME "pata_ninja32" | 46 | #define DRV_NAME "pata_ninja32" |
48 | #define DRV_VERSION "0.0.1" | 47 | #define DRV_VERSION "0.1.1" |
49 | 48 | ||
50 | 49 | ||
51 | /** | 50 | /** |
@@ -89,6 +88,17 @@ static struct ata_port_operations ninja32_port_ops = { | |||
89 | .set_piomode = ninja32_set_piomode, | 88 | .set_piomode = ninja32_set_piomode, |
90 | }; | 89 | }; |
91 | 90 | ||
91 | static void ninja32_program(void __iomem *base) | ||
92 | { | ||
93 | iowrite8(0x05, base + 0x01); /* Enable interrupt lines */ | ||
94 | iowrite8(0xBE, base + 0x02); /* Burst, ?? setup */ | ||
95 | iowrite8(0x01, base + 0x03); /* Unknown */ | ||
96 | iowrite8(0x20, base + 0x04); /* WAIT0 */ | ||
97 | iowrite8(0x8f, base + 0x05); /* Unknown */ | ||
98 | iowrite8(0xa4, base + 0x1c); /* Unknown */ | ||
99 | iowrite8(0x83, base + 0x1d); /* BMDMA control: WAIT0 */ | ||
100 | } | ||
101 | |||
92 | static int ninja32_init_one(struct pci_dev *dev, const struct pci_device_id *id) | 102 | static int ninja32_init_one(struct pci_dev *dev, const struct pci_device_id *id) |
93 | { | 103 | { |
94 | struct ata_host *host; | 104 | struct ata_host *host; |
@@ -134,18 +144,28 @@ static int ninja32_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
134 | ap->ioaddr.bmdma_addr = base; | 144 | ap->ioaddr.bmdma_addr = base; |
135 | ata_sff_std_ports(&ap->ioaddr); | 145 | ata_sff_std_ports(&ap->ioaddr); |
136 | 146 | ||
137 | iowrite8(0x05, base + 0x01); /* Enable interrupt lines */ | 147 | ninja32_program(base); |
138 | iowrite8(0xBE, base + 0x02); /* Burst, ?? setup */ | ||
139 | iowrite8(0x01, base + 0x03); /* Unknown */ | ||
140 | iowrite8(0x20, base + 0x04); /* WAIT0 */ | ||
141 | iowrite8(0x8f, base + 0x05); /* Unknown */ | ||
142 | iowrite8(0xa4, base + 0x1c); /* Unknown */ | ||
143 | iowrite8(0x83, base + 0x1d); /* BMDMA control: WAIT0 */ | ||
144 | /* FIXME: Should we disable them at remove ? */ | 148 | /* FIXME: Should we disable them at remove ? */ |
145 | return ata_host_activate(host, dev->irq, ata_sff_interrupt, | 149 | return ata_host_activate(host, dev->irq, ata_sff_interrupt, |
146 | IRQF_SHARED, &ninja32_sht); | 150 | IRQF_SHARED, &ninja32_sht); |
147 | } | 151 | } |
148 | 152 | ||
153 | #ifdef CONFIG_PM | ||
154 | |||
155 | static int ninja32_reinit_one(struct pci_dev *pdev) | ||
156 | { | ||
157 | struct ata_host *host = dev_get_drvdata(&pdev->dev); | ||
158 | int rc; | ||
159 | |||
160 | rc = ata_pci_device_do_resume(pdev); | ||
161 | if (rc) | ||
162 | return rc; | ||
163 | ninja32_program(host->iomap[0]); | ||
164 | ata_host_resume(host); | ||
165 | return 0; | ||
166 | } | ||
167 | #endif | ||
168 | |||
149 | static const struct pci_device_id ninja32[] = { | 169 | static const struct pci_device_id ninja32[] = { |
150 | { 0x1145, 0xf021, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, | 170 | { 0x1145, 0xf021, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, |
151 | { 0x1145, 0xf024, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, | 171 | { 0x1145, 0xf024, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, |
@@ -156,7 +176,11 @@ static struct pci_driver ninja32_pci_driver = { | |||
156 | .name = DRV_NAME, | 176 | .name = DRV_NAME, |
157 | .id_table = ninja32, | 177 | .id_table = ninja32, |
158 | .probe = ninja32_init_one, | 178 | .probe = ninja32_init_one, |
159 | .remove = ata_pci_remove_one | 179 | .remove = ata_pci_remove_one, |
180 | #ifdef CONFIG_PM | ||
181 | .suspend = ata_pci_device_suspend, | ||
182 | .resume = ninja32_reinit_one, | ||
183 | #endif | ||
160 | }; | 184 | }; |
161 | 185 | ||
162 | static int __init ninja32_init(void) | 186 | static int __init ninja32_init(void) |
diff --git a/drivers/ata/pata_ns87410.c b/drivers/ata/pata_ns87410.c index be756b7ef07e..40d411c460de 100644 --- a/drivers/ata/pata_ns87410.c +++ b/drivers/ata/pata_ns87410.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_ns87410.c - National Semiconductor 87410 PATA for new ATA layer | 2 | * pata_ns87410.c - National Semiconductor 87410 PATA for new ATA layer |
3 | * (C) 2006 Red Hat Inc | 3 | * (C) 2006 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * This program is free software; you can redistribute it and/or modify | 5 | * This program is free software; you can redistribute it and/or modify |
7 | * it under the terms of the GNU General Public License as published by | 6 | * it under the terms of the GNU General Public License as published by |
diff --git a/drivers/ata/pata_ns87415.c b/drivers/ata/pata_ns87415.c index e0aa7eaaee0a..89bf5f865d6a 100644 --- a/drivers/ata/pata_ns87415.c +++ b/drivers/ata/pata_ns87415.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_ns87415.c - NS87415 (non PARISC) PATA | 2 | * pata_ns87415.c - NS87415 (non PARISC) PATA |
3 | * | 3 | * |
4 | * (C) 2005 Red Hat <alan@redhat.com> | 4 | * (C) 2005 Red Hat <alan@lxorguk.ukuu.org.uk> |
5 | * | 5 | * |
6 | * This is a fairly generic MWDMA controller. It has some limitations | 6 | * This is a fairly generic MWDMA controller. It has some limitations |
7 | * as it requires timing reloads on PIO/DMA transitions but it is otherwise | 7 | * as it requires timing reloads on PIO/DMA transitions but it is otherwise |
diff --git a/drivers/ata/pata_oldpiix.c b/drivers/ata/pata_oldpiix.c index df64f2443001..c0dbc46a348e 100644 --- a/drivers/ata/pata_oldpiix.c +++ b/drivers/ata/pata_oldpiix.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_oldpiix.c - Intel PATA/SATA controllers | 2 | * pata_oldpiix.c - Intel PATA/SATA controllers |
3 | * | 3 | * |
4 | * (C) 2005 Red Hat <alan@redhat.com> | 4 | * (C) 2005 Red Hat |
5 | * | 5 | * |
6 | * Some parts based on ata_piix.c by Jeff Garzik and others. | 6 | * Some parts based on ata_piix.c by Jeff Garzik and others. |
7 | * | 7 | * |
diff --git a/drivers/ata/pata_opti.c b/drivers/ata/pata_opti.c index fb2cf661b0e8..e4fa4d565e96 100644 --- a/drivers/ata/pata_opti.c +++ b/drivers/ata/pata_opti.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_opti.c - ATI PATA for new ATA layer | 2 | * pata_opti.c - ATI PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * Based on | 5 | * Based on |
7 | * linux/drivers/ide/pci/opti621.c Version 0.7 Sept 10, 2002 | 6 | * linux/drivers/ide/pci/opti621.c Version 0.7 Sept 10, 2002 |
diff --git a/drivers/ata/pata_optidma.c b/drivers/ata/pata_optidma.c index 4cd744456313..93bb6e91973f 100644 --- a/drivers/ata/pata_optidma.c +++ b/drivers/ata/pata_optidma.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_optidma.c - Opti DMA PATA for new ATA layer | 2 | * pata_optidma.c - Opti DMA PATA for new ATA layer |
3 | * (C) 2006 Red Hat Inc | 3 | * (C) 2006 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * The Opti DMA controllers are related to the older PIO PCI controllers | 5 | * The Opti DMA controllers are related to the older PIO PCI controllers |
7 | * and indeed the VLB ones. The main differences are that the timing | 6 | * and indeed the VLB ones. The main differences are that the timing |
diff --git a/drivers/ata/pata_pcmcia.c b/drivers/ata/pata_pcmcia.c index 02b596b9cf6a..271cb64d429e 100644 --- a/drivers/ata/pata_pcmcia.c +++ b/drivers/ata/pata_pcmcia.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_pcmcia.c - PCMCIA PATA controller driver. | 2 | * pata_pcmcia.c - PCMCIA PATA controller driver. |
3 | * Copyright 2005-2006 Red Hat Inc <alan@redhat.com>, all rights reserved. | 3 | * Copyright 2005-2006 Red Hat Inc, all rights reserved. |
4 | * PCMCIA ident update Copyright 2006 Marcin Juszkiewicz | 4 | * PCMCIA ident update Copyright 2006 Marcin Juszkiewicz |
5 | * <openembedded@hrw.one.pl> | 5 | * <openembedded@hrw.one.pl> |
6 | * | 6 | * |
diff --git a/drivers/ata/pata_pdc202xx_old.c b/drivers/ata/pata_pdc202xx_old.c index d2673060bc8d..799a6a098712 100644 --- a/drivers/ata/pata_pdc202xx_old.c +++ b/drivers/ata/pata_pdc202xx_old.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_pdc202xx_old.c - Promise PDC202xx PATA for new ATA layer | 2 | * pata_pdc202xx_old.c - Promise PDC202xx PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | 4 | * Alan Cox <alan@lxorguk.ukuu.org.uk> |
5 | * (C) 2007 Bartlomiej Zolnierkiewicz | 5 | * (C) 2007 Bartlomiej Zolnierkiewicz |
6 | * | 6 | * |
7 | * Based in part on linux/drivers/ide/pci/pdc202xx_old.c | 7 | * Based in part on linux/drivers/ide/pci/pdc202xx_old.c |
diff --git a/drivers/ata/pata_platform.c b/drivers/ata/pata_platform.c index 8f65ad61b8af..77e4e3b17f54 100644 --- a/drivers/ata/pata_platform.c +++ b/drivers/ata/pata_platform.c | |||
@@ -5,7 +5,7 @@ | |||
5 | * | 5 | * |
6 | * Based on pata_pcmcia: | 6 | * Based on pata_pcmcia: |
7 | * | 7 | * |
8 | * Copyright 2005-2006 Red Hat Inc <alan@redhat.com>, all rights reserved. | 8 | * Copyright 2005-2006 Red Hat Inc, all rights reserved. |
9 | * | 9 | * |
10 | * This file is subject to the terms and conditions of the GNU General Public | 10 | * This file is subject to the terms and conditions of the GNU General Public |
11 | * License. See the file "COPYING" in the main directory of this archive | 11 | * License. See the file "COPYING" in the main directory of this archive |
diff --git a/drivers/ata/pata_qdi.c b/drivers/ata/pata_qdi.c index 63b7a1c165a5..3080f371222c 100644 --- a/drivers/ata/pata_qdi.c +++ b/drivers/ata/pata_qdi.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_qdi.c - QDI VLB ATA controllers | 2 | * pata_qdi.c - QDI VLB ATA controllers |
3 | * (C) 2006 Red Hat <alan@redhat.com> | 3 | * (C) 2006 Red Hat |
4 | * | 4 | * |
5 | * This driver mostly exists as a proof of concept for non PCI devices under | 5 | * This driver mostly exists as a proof of concept for non PCI devices under |
6 | * libata. While the QDI6580 was 'neat' in 1993 it is no longer terribly | 6 | * libata. While the QDI6580 was 'neat' in 1993 it is no longer terribly |
diff --git a/drivers/ata/pata_radisys.c b/drivers/ata/pata_radisys.c index 1c0d9fa7ee54..0b0aa452de14 100644 --- a/drivers/ata/pata_radisys.c +++ b/drivers/ata/pata_radisys.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_radisys.c - Intel PATA/SATA controllers | 2 | * pata_radisys.c - Intel PATA/SATA controllers |
3 | * | 3 | * |
4 | * (C) 2006 Red Hat <alan@redhat.com> | 4 | * (C) 2006 Red Hat <alan@lxorguk.ukuu.org.uk> |
5 | * | 5 | * |
6 | * Some parts based on ata_piix.c by Jeff Garzik and others. | 6 | * Some parts based on ata_piix.c by Jeff Garzik and others. |
7 | * | 7 | * |
diff --git a/drivers/ata/pata_sc1200.c b/drivers/ata/pata_sc1200.c index 0278fd2b8fb1..9a4bdca54616 100644 --- a/drivers/ata/pata_sc1200.c +++ b/drivers/ata/pata_sc1200.c | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * New ATA layer SC1200 driver Alan Cox <alan@redhat.com> | 2 | * New ATA layer SC1200 driver Alan Cox <alan@lxorguk.ukuu.org.uk> |
3 | * | 3 | * |
4 | * TODO: Mode selection filtering | 4 | * TODO: Mode selection filtering |
5 | * TODO: Can't enable second channel until ATA core has serialize | 5 | * TODO: Can't enable second channel until ATA core has serialize |
diff --git a/drivers/ata/pata_scc.c b/drivers/ata/pata_scc.c index 16673d168573..cf3707e516a2 100644 --- a/drivers/ata/pata_scc.c +++ b/drivers/ata/pata_scc.c | |||
@@ -8,7 +8,7 @@ | |||
8 | * Copyright 2003-2005 Jeff Garzik | 8 | * Copyright 2003-2005 Jeff Garzik |
9 | * Copyright (C) 1998-1999 Andrzej Krzysztofowicz, Author and Maintainer | 9 | * Copyright (C) 1998-1999 Andrzej Krzysztofowicz, Author and Maintainer |
10 | * Copyright (C) 1998-2000 Andre Hedrick <andre@linux-ide.org> | 10 | * Copyright (C) 1998-2000 Andre Hedrick <andre@linux-ide.org> |
11 | * Copyright (C) 2003 Red Hat Inc <alan@redhat.com> | 11 | * Copyright (C) 2003 Red Hat Inc |
12 | * | 12 | * |
13 | * and drivers/ata/ahci.c: | 13 | * and drivers/ata/ahci.c: |
14 | * Copyright 2004-2005 Red Hat, Inc. | 14 | * Copyright 2004-2005 Red Hat, Inc. |
diff --git a/drivers/ata/pata_serverworks.c b/drivers/ata/pata_serverworks.c index ffd26d0dc50d..72e41c9f969b 100644 --- a/drivers/ata/pata_serverworks.c +++ b/drivers/ata/pata_serverworks.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_serverworks.c - Serverworks PATA for new ATA layer | 2 | * pata_serverworks.c - Serverworks PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * based upon | 5 | * based upon |
7 | * | 6 | * |
diff --git a/drivers/ata/pata_sil680.c b/drivers/ata/pata_sil680.c index a598bb36aafc..83580a59db58 100644 --- a/drivers/ata/pata_sil680.c +++ b/drivers/ata/pata_sil680.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_sil680.c - SIL680 PATA for new ATA layer | 2 | * pata_sil680.c - SIL680 PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * based upon | 5 | * based upon |
7 | * | 6 | * |
diff --git a/drivers/ata/pata_sis.c b/drivers/ata/pata_sis.c index 26345d7b531c..d34236611752 100644 --- a/drivers/ata/pata_sis.c +++ b/drivers/ata/pata_sis.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_sis.c - SiS ATA driver | 2 | * pata_sis.c - SiS ATA driver |
3 | * | 3 | * |
4 | * (C) 2005 Red Hat <alan@redhat.com> | 4 | * (C) 2005 Red Hat |
5 | * (C) 2007 Bartlomiej Zolnierkiewicz | 5 | * (C) 2007 Bartlomiej Zolnierkiewicz |
6 | * | 6 | * |
7 | * Based upon linux/drivers/ide/pci/sis5513.c | 7 | * Based upon linux/drivers/ide/pci/sis5513.c |
diff --git a/drivers/ata/pata_sl82c105.c b/drivers/ata/pata_sl82c105.c index 69877bd81815..1b0e7b6d8ef5 100644 --- a/drivers/ata/pata_sl82c105.c +++ b/drivers/ata/pata_sl82c105.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_sl82c105.c - SL82C105 PATA for new ATA layer | 2 | * pata_sl82c105.c - SL82C105 PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * Based in part on linux/drivers/ide/pci/sl82c105.c | 5 | * Based in part on linux/drivers/ide/pci/sl82c105.c |
7 | * SL82C105/Winbond 553 IDE driver | 6 | * SL82C105/Winbond 553 IDE driver |
diff --git a/drivers/ata/pata_triflex.c b/drivers/ata/pata_triflex.c index b181261f2743..ef9597517cdd 100644 --- a/drivers/ata/pata_triflex.c +++ b/drivers/ata/pata_triflex.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * pata_triflex.c - Compaq PATA for new ATA layer | 2 | * pata_triflex.c - Compaq PATA for new ATA layer |
3 | * (C) 2005 Red Hat Inc | 3 | * (C) 2005 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | 4 | * Alan Cox <alan@lxorguk.ukuu.org.uk> |
5 | * | 5 | * |
6 | * based upon | 6 | * based upon |
7 | * | 7 | * |
diff --git a/drivers/ata/pata_via.c b/drivers/ata/pata_via.c index 8fdb2ce73210..681169c9c640 100644 --- a/drivers/ata/pata_via.c +++ b/drivers/ata/pata_via.c | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_via.c - VIA PATA for new ATA layer | 2 | * pata_via.c - VIA PATA for new ATA layer |
3 | * (C) 2005-2006 Red Hat Inc | 3 | * (C) 2005-2006 Red Hat Inc |
4 | * Alan Cox <alan@redhat.com> | ||
5 | * | 4 | * |
6 | * Documentation | 5 | * Documentation |
7 | * Most chipset documentation available under NDA only | 6 | * Most chipset documentation available under NDA only |
diff --git a/drivers/ata/pata_winbond.c b/drivers/ata/pata_winbond.c index a7606b044a61..319e164a3d74 100644 --- a/drivers/ata/pata_winbond.c +++ b/drivers/ata/pata_winbond.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * pata_winbond.c - Winbond VLB ATA controllers | 2 | * pata_winbond.c - Winbond VLB ATA controllers |
3 | * (C) 2006 Red Hat <alan@redhat.com> | 3 | * (C) 2006 Red Hat |
4 | * | 4 | * |
5 | * Support for the Winbond 83759A when operating in advanced mode. | 5 | * Support for the Winbond 83759A when operating in advanced mode. |
6 | * Multichip mode is not currently supported. | 6 | * Multichip mode is not currently supported. |
diff --git a/drivers/ata/sata_sil24.c b/drivers/ata/sata_sil24.c index 4621807a1a6a..ccee930f1e12 100644 --- a/drivers/ata/sata_sil24.c +++ b/drivers/ata/sata_sil24.c | |||
@@ -1329,6 +1329,11 @@ static int sil24_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
1329 | } | 1329 | } |
1330 | } | 1330 | } |
1331 | 1331 | ||
1332 | /* Set max read request size to 4096. This slightly increases | ||
1333 | * write throughput for pci-e variants. | ||
1334 | */ | ||
1335 | pcie_set_readrq(pdev, 4096); | ||
1336 | |||
1332 | sil24_init_controller(host); | 1337 | sil24_init_controller(host); |
1333 | 1338 | ||
1334 | pci_set_master(pdev); | 1339 | pci_set_master(pdev); |
diff --git a/drivers/bluetooth/btsdio.c b/drivers/bluetooth/btsdio.c index 58630cc1eff2..cda6c7cc944b 100644 --- a/drivers/bluetooth/btsdio.c +++ b/drivers/bluetooth/btsdio.c | |||
@@ -152,7 +152,7 @@ static int btsdio_rx_packet(struct btsdio_data *data) | |||
152 | 152 | ||
153 | err = sdio_readsb(data->func, skb->data, REG_RDAT, len - 4); | 153 | err = sdio_readsb(data->func, skb->data, REG_RDAT, len - 4); |
154 | if (err < 0) { | 154 | if (err < 0) { |
155 | kfree(skb); | 155 | kfree_skb(skb); |
156 | return err; | 156 | return err; |
157 | } | 157 | } |
158 | 158 | ||
diff --git a/drivers/char/amiserial.c b/drivers/char/amiserial.c index 98821f97583c..b97aebd7aeb8 100644 --- a/drivers/char/amiserial.c +++ b/drivers/char/amiserial.c | |||
@@ -2071,12 +2071,13 @@ module_init(rs_init) | |||
2071 | module_exit(rs_exit) | 2071 | module_exit(rs_exit) |
2072 | 2072 | ||
2073 | 2073 | ||
2074 | #if defined(CONFIG_SERIAL_CONSOLE) && !defined(MODULE) | ||
2075 | |||
2074 | /* | 2076 | /* |
2075 | * ------------------------------------------------------------ | 2077 | * ------------------------------------------------------------ |
2076 | * Serial console driver | 2078 | * Serial console driver |
2077 | * ------------------------------------------------------------ | 2079 | * ------------------------------------------------------------ |
2078 | */ | 2080 | */ |
2079 | #ifdef CONFIG_SERIAL_CONSOLE | ||
2080 | 2081 | ||
2081 | static void amiga_serial_putc(char c) | 2082 | static void amiga_serial_putc(char c) |
2082 | { | 2083 | { |
@@ -2130,6 +2131,7 @@ static int __init amiserial_console_init(void) | |||
2130 | return 0; | 2131 | return 0; |
2131 | } | 2132 | } |
2132 | console_initcall(amiserial_console_init); | 2133 | console_initcall(amiserial_console_init); |
2133 | #endif | 2134 | |
2135 | #endif /* CONFIG_SERIAL_CONSOLE && !MODULE */ | ||
2134 | 2136 | ||
2135 | MODULE_LICENSE("GPL"); | 2137 | MODULE_LICENSE("GPL"); |
diff --git a/drivers/char/hw_random/amd-rng.c b/drivers/char/hw_random/amd-rng.c index c422e870dc52..cd0ba51f7c80 100644 --- a/drivers/char/hw_random/amd-rng.c +++ b/drivers/char/hw_random/amd-rng.c | |||
@@ -11,7 +11,7 @@ | |||
11 | * derived from | 11 | * derived from |
12 | * | 12 | * |
13 | * Hardware driver for the AMD 768 Random Number Generator (RNG) | 13 | * Hardware driver for the AMD 768 Random Number Generator (RNG) |
14 | * (c) Copyright 2001 Red Hat Inc <alan@redhat.com> | 14 | * (c) Copyright 2001 Red Hat Inc |
15 | * | 15 | * |
16 | * derived from | 16 | * derived from |
17 | * | 17 | * |
diff --git a/drivers/char/hw_random/geode-rng.c b/drivers/char/hw_random/geode-rng.c index fed4ef5569f5..64d513f68368 100644 --- a/drivers/char/hw_random/geode-rng.c +++ b/drivers/char/hw_random/geode-rng.c | |||
@@ -11,7 +11,7 @@ | |||
11 | * derived from | 11 | * derived from |
12 | * | 12 | * |
13 | * Hardware driver for the AMD 768 Random Number Generator (RNG) | 13 | * Hardware driver for the AMD 768 Random Number Generator (RNG) |
14 | * (c) Copyright 2001 Red Hat Inc <alan@redhat.com> | 14 | * (c) Copyright 2001 Red Hat Inc |
15 | * | 15 | * |
16 | * derived from | 16 | * derived from |
17 | * | 17 | * |
diff --git a/drivers/char/hw_random/intel-rng.c b/drivers/char/hw_random/intel-rng.c index 8a2fce0756ec..5dcbe603eca2 100644 --- a/drivers/char/hw_random/intel-rng.c +++ b/drivers/char/hw_random/intel-rng.c | |||
@@ -11,7 +11,7 @@ | |||
11 | * derived from | 11 | * derived from |
12 | * | 12 | * |
13 | * Hardware driver for the AMD 768 Random Number Generator (RNG) | 13 | * Hardware driver for the AMD 768 Random Number Generator (RNG) |
14 | * (c) Copyright 2001 Red Hat Inc <alan@redhat.com> | 14 | * (c) Copyright 2001 Red Hat Inc |
15 | * | 15 | * |
16 | * derived from | 16 | * derived from |
17 | * | 17 | * |
diff --git a/drivers/char/hw_random/via-rng.c b/drivers/char/hw_random/via-rng.c index 128202e18fc9..4e9573c1d39e 100644 --- a/drivers/char/hw_random/via-rng.c +++ b/drivers/char/hw_random/via-rng.c | |||
@@ -11,7 +11,7 @@ | |||
11 | * derived from | 11 | * derived from |
12 | * | 12 | * |
13 | * Hardware driver for the AMD 768 Random Number Generator (RNG) | 13 | * Hardware driver for the AMD 768 Random Number Generator (RNG) |
14 | * (c) Copyright 2001 Red Hat Inc <alan@redhat.com> | 14 | * (c) Copyright 2001 Red Hat Inc |
15 | * | 15 | * |
16 | * derived from | 16 | * derived from |
17 | * | 17 | * |
diff --git a/drivers/dma/ioat_dma.c b/drivers/dma/ioat_dma.c index 43b8cefad2c6..b0438c4f0c30 100644 --- a/drivers/dma/ioat_dma.c +++ b/drivers/dma/ioat_dma.c | |||
@@ -33,6 +33,7 @@ | |||
33 | #include <linux/delay.h> | 33 | #include <linux/delay.h> |
34 | #include <linux/dma-mapping.h> | 34 | #include <linux/dma-mapping.h> |
35 | #include <linux/workqueue.h> | 35 | #include <linux/workqueue.h> |
36 | #include <linux/i7300_idle.h> | ||
36 | #include "ioatdma.h" | 37 | #include "ioatdma.h" |
37 | #include "ioatdma_registers.h" | 38 | #include "ioatdma_registers.h" |
38 | #include "ioatdma_hw.h" | 39 | #include "ioatdma_hw.h" |
@@ -171,8 +172,10 @@ static int ioat_dma_enumerate_channels(struct ioatdma_device *device) | |||
171 | xfercap_scale = readb(device->reg_base + IOAT_XFERCAP_OFFSET); | 172 | xfercap_scale = readb(device->reg_base + IOAT_XFERCAP_OFFSET); |
172 | xfercap = (xfercap_scale == 0 ? -1 : (1UL << xfercap_scale)); | 173 | xfercap = (xfercap_scale == 0 ? -1 : (1UL << xfercap_scale)); |
173 | 174 | ||
174 | #if CONFIG_I7300_IDLE_IOAT_CHANNEL | 175 | #ifdef CONFIG_I7300_IDLE_IOAT_CHANNEL |
175 | device->common.chancnt--; | 176 | if (i7300_idle_platform_probe(NULL, NULL) == 0) { |
177 | device->common.chancnt--; | ||
178 | } | ||
176 | #endif | 179 | #endif |
177 | for (i = 0; i < device->common.chancnt; i++) { | 180 | for (i = 0; i < device->common.chancnt; i++) { |
178 | ioat_chan = kzalloc(sizeof(*ioat_chan), GFP_KERNEL); | 181 | ioat_chan = kzalloc(sizeof(*ioat_chan), GFP_KERNEL); |
diff --git a/drivers/firewire/fw-ohci.c b/drivers/firewire/fw-ohci.c index 251416f2148f..8e16bfbdcb3d 100644 --- a/drivers/firewire/fw-ohci.c +++ b/drivers/firewire/fw-ohci.c | |||
@@ -476,6 +476,7 @@ static int ar_context_add_page(struct ar_context *ctx) | |||
476 | if (ab == NULL) | 476 | if (ab == NULL) |
477 | return -ENOMEM; | 477 | return -ENOMEM; |
478 | 478 | ||
479 | ab->next = NULL; | ||
479 | memset(&ab->descriptor, 0, sizeof(ab->descriptor)); | 480 | memset(&ab->descriptor, 0, sizeof(ab->descriptor)); |
480 | ab->descriptor.control = cpu_to_le16(DESCRIPTOR_INPUT_MORE | | 481 | ab->descriptor.control = cpu_to_le16(DESCRIPTOR_INPUT_MORE | |
481 | DESCRIPTOR_STATUS | | 482 | DESCRIPTOR_STATUS | |
@@ -496,6 +497,21 @@ static int ar_context_add_page(struct ar_context *ctx) | |||
496 | return 0; | 497 | return 0; |
497 | } | 498 | } |
498 | 499 | ||
500 | static void ar_context_release(struct ar_context *ctx) | ||
501 | { | ||
502 | struct ar_buffer *ab, *ab_next; | ||
503 | size_t offset; | ||
504 | dma_addr_t ab_bus; | ||
505 | |||
506 | for (ab = ctx->current_buffer; ab; ab = ab_next) { | ||
507 | ab_next = ab->next; | ||
508 | offset = offsetof(struct ar_buffer, data); | ||
509 | ab_bus = le32_to_cpu(ab->descriptor.data_address) - offset; | ||
510 | dma_free_coherent(ctx->ohci->card.device, PAGE_SIZE, | ||
511 | ab, ab_bus); | ||
512 | } | ||
513 | } | ||
514 | |||
499 | #if defined(CONFIG_PPC_PMAC) && defined(CONFIG_PPC32) | 515 | #if defined(CONFIG_PPC_PMAC) && defined(CONFIG_PPC32) |
500 | #define cond_le32_to_cpu(v) \ | 516 | #define cond_le32_to_cpu(v) \ |
501 | (ohci->old_uninorth ? (__force __u32)(v) : le32_to_cpu(v)) | 517 | (ohci->old_uninorth ? (__force __u32)(v) : le32_to_cpu(v)) |
@@ -2349,8 +2365,8 @@ pci_probe(struct pci_dev *dev, const struct pci_device_id *ent) | |||
2349 | 2365 | ||
2350 | ohci = kzalloc(sizeof(*ohci), GFP_KERNEL); | 2366 | ohci = kzalloc(sizeof(*ohci), GFP_KERNEL); |
2351 | if (ohci == NULL) { | 2367 | if (ohci == NULL) { |
2352 | fw_error("Could not malloc fw_ohci data.\n"); | 2368 | err = -ENOMEM; |
2353 | return -ENOMEM; | 2369 | goto fail; |
2354 | } | 2370 | } |
2355 | 2371 | ||
2356 | fw_card_initialize(&ohci->card, &ohci_driver, &dev->dev); | 2372 | fw_card_initialize(&ohci->card, &ohci_driver, &dev->dev); |
@@ -2359,7 +2375,7 @@ pci_probe(struct pci_dev *dev, const struct pci_device_id *ent) | |||
2359 | 2375 | ||
2360 | err = pci_enable_device(dev); | 2376 | err = pci_enable_device(dev); |
2361 | if (err) { | 2377 | if (err) { |
2362 | fw_error("Failed to enable OHCI hardware.\n"); | 2378 | fw_error("Failed to enable OHCI hardware\n"); |
2363 | goto fail_free; | 2379 | goto fail_free; |
2364 | } | 2380 | } |
2365 | 2381 | ||
@@ -2427,9 +2443,8 @@ pci_probe(struct pci_dev *dev, const struct pci_device_id *ent) | |||
2427 | ohci->ir_context_list = kzalloc(size, GFP_KERNEL); | 2443 | ohci->ir_context_list = kzalloc(size, GFP_KERNEL); |
2428 | 2444 | ||
2429 | if (ohci->it_context_list == NULL || ohci->ir_context_list == NULL) { | 2445 | if (ohci->it_context_list == NULL || ohci->ir_context_list == NULL) { |
2430 | fw_error("Out of memory for it/ir contexts.\n"); | ||
2431 | err = -ENOMEM; | 2446 | err = -ENOMEM; |
2432 | goto fail_registers; | 2447 | goto fail_contexts; |
2433 | } | 2448 | } |
2434 | 2449 | ||
2435 | /* self-id dma buffer allocation */ | 2450 | /* self-id dma buffer allocation */ |
@@ -2438,9 +2453,8 @@ pci_probe(struct pci_dev *dev, const struct pci_device_id *ent) | |||
2438 | &ohci->self_id_bus, | 2453 | &ohci->self_id_bus, |
2439 | GFP_KERNEL); | 2454 | GFP_KERNEL); |
2440 | if (ohci->self_id_cpu == NULL) { | 2455 | if (ohci->self_id_cpu == NULL) { |
2441 | fw_error("Out of memory for self ID buffer.\n"); | ||
2442 | err = -ENOMEM; | 2456 | err = -ENOMEM; |
2443 | goto fail_registers; | 2457 | goto fail_contexts; |
2444 | } | 2458 | } |
2445 | 2459 | ||
2446 | bus_options = reg_read(ohci, OHCI1394_BusOptions); | 2460 | bus_options = reg_read(ohci, OHCI1394_BusOptions); |
@@ -2460,9 +2474,13 @@ pci_probe(struct pci_dev *dev, const struct pci_device_id *ent) | |||
2460 | fail_self_id: | 2474 | fail_self_id: |
2461 | dma_free_coherent(ohci->card.device, SELF_ID_BUF_SIZE, | 2475 | dma_free_coherent(ohci->card.device, SELF_ID_BUF_SIZE, |
2462 | ohci->self_id_cpu, ohci->self_id_bus); | 2476 | ohci->self_id_cpu, ohci->self_id_bus); |
2463 | fail_registers: | 2477 | fail_contexts: |
2464 | kfree(ohci->it_context_list); | ||
2465 | kfree(ohci->ir_context_list); | 2478 | kfree(ohci->ir_context_list); |
2479 | kfree(ohci->it_context_list); | ||
2480 | context_release(&ohci->at_response_ctx); | ||
2481 | context_release(&ohci->at_request_ctx); | ||
2482 | ar_context_release(&ohci->ar_response_ctx); | ||
2483 | ar_context_release(&ohci->ar_request_ctx); | ||
2466 | pci_iounmap(dev, ohci->registers); | 2484 | pci_iounmap(dev, ohci->registers); |
2467 | fail_iomem: | 2485 | fail_iomem: |
2468 | pci_release_region(dev, 0); | 2486 | pci_release_region(dev, 0); |
@@ -2471,6 +2489,9 @@ pci_probe(struct pci_dev *dev, const struct pci_device_id *ent) | |||
2471 | fail_free: | 2489 | fail_free: |
2472 | kfree(&ohci->card); | 2490 | kfree(&ohci->card); |
2473 | ohci_pmac_off(dev); | 2491 | ohci_pmac_off(dev); |
2492 | fail: | ||
2493 | if (err == -ENOMEM) | ||
2494 | fw_error("Out of memory\n"); | ||
2474 | 2495 | ||
2475 | return err; | 2496 | return err; |
2476 | } | 2497 | } |
@@ -2491,8 +2512,19 @@ static void pci_remove(struct pci_dev *dev) | |||
2491 | 2512 | ||
2492 | software_reset(ohci); | 2513 | software_reset(ohci); |
2493 | free_irq(dev->irq, ohci); | 2514 | free_irq(dev->irq, ohci); |
2515 | |||
2516 | if (ohci->next_config_rom && ohci->next_config_rom != ohci->config_rom) | ||
2517 | dma_free_coherent(ohci->card.device, CONFIG_ROM_SIZE, | ||
2518 | ohci->next_config_rom, ohci->next_config_rom_bus); | ||
2519 | if (ohci->config_rom) | ||
2520 | dma_free_coherent(ohci->card.device, CONFIG_ROM_SIZE, | ||
2521 | ohci->config_rom, ohci->config_rom_bus); | ||
2494 | dma_free_coherent(ohci->card.device, SELF_ID_BUF_SIZE, | 2522 | dma_free_coherent(ohci->card.device, SELF_ID_BUF_SIZE, |
2495 | ohci->self_id_cpu, ohci->self_id_bus); | 2523 | ohci->self_id_cpu, ohci->self_id_bus); |
2524 | ar_context_release(&ohci->ar_request_ctx); | ||
2525 | ar_context_release(&ohci->ar_response_ctx); | ||
2526 | context_release(&ohci->at_request_ctx); | ||
2527 | context_release(&ohci->at_response_ctx); | ||
2496 | kfree(ohci->it_context_list); | 2528 | kfree(ohci->it_context_list); |
2497 | kfree(ohci->ir_context_list); | 2529 | kfree(ohci->ir_context_list); |
2498 | pci_iounmap(dev, ohci->registers); | 2530 | pci_iounmap(dev, ohci->registers); |
diff --git a/drivers/firewire/fw-sbp2.c b/drivers/firewire/fw-sbp2.c index ef0b9b419c27..d334cac5e1fc 100644 --- a/drivers/firewire/fw-sbp2.c +++ b/drivers/firewire/fw-sbp2.c | |||
@@ -173,6 +173,9 @@ struct sbp2_target { | |||
173 | int blocked; /* ditto */ | 173 | int blocked; /* ditto */ |
174 | }; | 174 | }; |
175 | 175 | ||
176 | /* Impossible login_id, to detect logout attempt before successful login */ | ||
177 | #define INVALID_LOGIN_ID 0x10000 | ||
178 | |||
176 | /* | 179 | /* |
177 | * Per section 7.4.8 of the SBP-2 spec, a mgt_ORB_timeout value can be | 180 | * Per section 7.4.8 of the SBP-2 spec, a mgt_ORB_timeout value can be |
178 | * provided in the config rom. Most devices do provide a value, which | 181 | * provided in the config rom. Most devices do provide a value, which |
@@ -788,9 +791,20 @@ static void sbp2_release_target(struct kref *kref) | |||
788 | scsi_remove_device(sdev); | 791 | scsi_remove_device(sdev); |
789 | scsi_device_put(sdev); | 792 | scsi_device_put(sdev); |
790 | } | 793 | } |
791 | sbp2_send_management_orb(lu, tgt->node_id, lu->generation, | 794 | if (lu->login_id != INVALID_LOGIN_ID) { |
792 | SBP2_LOGOUT_REQUEST, lu->login_id, NULL); | 795 | int generation, node_id; |
793 | 796 | /* | |
797 | * tgt->node_id may be obsolete here if we failed | ||
798 | * during initial login or after a bus reset where | ||
799 | * the topology changed. | ||
800 | */ | ||
801 | generation = device->generation; | ||
802 | smp_rmb(); /* node_id vs. generation */ | ||
803 | node_id = device->node_id; | ||
804 | sbp2_send_management_orb(lu, node_id, generation, | ||
805 | SBP2_LOGOUT_REQUEST, | ||
806 | lu->login_id, NULL); | ||
807 | } | ||
794 | fw_core_remove_address_handler(&lu->address_handler); | 808 | fw_core_remove_address_handler(&lu->address_handler); |
795 | list_del(&lu->link); | 809 | list_del(&lu->link); |
796 | kfree(lu); | 810 | kfree(lu); |
@@ -805,19 +819,20 @@ static void sbp2_release_target(struct kref *kref) | |||
805 | 819 | ||
806 | static struct workqueue_struct *sbp2_wq; | 820 | static struct workqueue_struct *sbp2_wq; |
807 | 821 | ||
822 | static void sbp2_target_put(struct sbp2_target *tgt) | ||
823 | { | ||
824 | kref_put(&tgt->kref, sbp2_release_target); | ||
825 | } | ||
826 | |||
808 | /* | 827 | /* |
809 | * Always get the target's kref when scheduling work on one its units. | 828 | * Always get the target's kref when scheduling work on one its units. |
810 | * Each workqueue job is responsible to call sbp2_target_put() upon return. | 829 | * Each workqueue job is responsible to call sbp2_target_put() upon return. |
811 | */ | 830 | */ |
812 | static void sbp2_queue_work(struct sbp2_logical_unit *lu, unsigned long delay) | 831 | static void sbp2_queue_work(struct sbp2_logical_unit *lu, unsigned long delay) |
813 | { | 832 | { |
814 | if (queue_delayed_work(sbp2_wq, &lu->work, delay)) | 833 | kref_get(&lu->tgt->kref); |
815 | kref_get(&lu->tgt->kref); | 834 | if (!queue_delayed_work(sbp2_wq, &lu->work, delay)) |
816 | } | 835 | sbp2_target_put(lu->tgt); |
817 | |||
818 | static void sbp2_target_put(struct sbp2_target *tgt) | ||
819 | { | ||
820 | kref_put(&tgt->kref, sbp2_release_target); | ||
821 | } | 836 | } |
822 | 837 | ||
823 | /* | 838 | /* |
@@ -978,6 +993,7 @@ static int sbp2_add_logical_unit(struct sbp2_target *tgt, int lun_entry) | |||
978 | 993 | ||
979 | lu->tgt = tgt; | 994 | lu->tgt = tgt; |
980 | lu->lun = lun_entry & 0xffff; | 995 | lu->lun = lun_entry & 0xffff; |
996 | lu->login_id = INVALID_LOGIN_ID; | ||
981 | lu->retries = 0; | 997 | lu->retries = 0; |
982 | lu->has_sdev = false; | 998 | lu->has_sdev = false; |
983 | lu->blocked = false; | 999 | lu->blocked = false; |
@@ -1147,7 +1163,7 @@ static int sbp2_probe(struct device *dev) | |||
1147 | 1163 | ||
1148 | /* Do the login in a workqueue so we can easily reschedule retries. */ | 1164 | /* Do the login in a workqueue so we can easily reschedule retries. */ |
1149 | list_for_each_entry(lu, &tgt->lu_list, link) | 1165 | list_for_each_entry(lu, &tgt->lu_list, link) |
1150 | sbp2_queue_work(lu, 0); | 1166 | sbp2_queue_work(lu, DIV_ROUND_UP(HZ, 5)); |
1151 | return 0; | 1167 | return 0; |
1152 | 1168 | ||
1153 | fail_tgt_put: | 1169 | fail_tgt_put: |
diff --git a/drivers/firewire/fw-topology.c b/drivers/firewire/fw-topology.c index c1b81077c4a8..5e204713002d 100644 --- a/drivers/firewire/fw-topology.c +++ b/drivers/firewire/fw-topology.c | |||
@@ -413,7 +413,7 @@ static void | |||
413 | update_tree(struct fw_card *card, struct fw_node *root) | 413 | update_tree(struct fw_card *card, struct fw_node *root) |
414 | { | 414 | { |
415 | struct list_head list0, list1; | 415 | struct list_head list0, list1; |
416 | struct fw_node *node0, *node1; | 416 | struct fw_node *node0, *node1, *next1; |
417 | int i, event; | 417 | int i, event; |
418 | 418 | ||
419 | INIT_LIST_HEAD(&list0); | 419 | INIT_LIST_HEAD(&list0); |
@@ -485,7 +485,9 @@ update_tree(struct fw_card *card, struct fw_node *root) | |||
485 | } | 485 | } |
486 | 486 | ||
487 | node0 = fw_node(node0->link.next); | 487 | node0 = fw_node(node0->link.next); |
488 | node1 = fw_node(node1->link.next); | 488 | next1 = fw_node(node1->link.next); |
489 | fw_node_put(node1); | ||
490 | node1 = next1; | ||
489 | } | 491 | } |
490 | } | 492 | } |
491 | 493 | ||
diff --git a/drivers/firewire/fw-transaction.h b/drivers/firewire/fw-transaction.h index 027f58ce81ad..aed7dbb17cda 100644 --- a/drivers/firewire/fw-transaction.h +++ b/drivers/firewire/fw-transaction.h | |||
@@ -248,7 +248,7 @@ struct fw_card { | |||
248 | struct fw_node *local_node; | 248 | struct fw_node *local_node; |
249 | struct fw_node *root_node; | 249 | struct fw_node *root_node; |
250 | struct fw_node *irm_node; | 250 | struct fw_node *irm_node; |
251 | int color; | 251 | u8 color; /* must be u8 to match the definition in struct fw_node */ |
252 | int gap_count; | 252 | int gap_count; |
253 | bool beta_repeaters_present; | 253 | bool beta_repeaters_present; |
254 | 254 | ||
diff --git a/drivers/hid/Kconfig b/drivers/hid/Kconfig index f5999a91614e..b4fd8ca701a4 100644 --- a/drivers/hid/Kconfig +++ b/drivers/hid/Kconfig | |||
@@ -247,7 +247,6 @@ config HID_SUNPLUS | |||
247 | 247 | ||
248 | config THRUSTMASTER_FF | 248 | config THRUSTMASTER_FF |
249 | tristate "ThrustMaster devices support" | 249 | tristate "ThrustMaster devices support" |
250 | default m | ||
251 | depends on USB_HID | 250 | depends on USB_HID |
252 | select INPUT_FF_MEMLESS | 251 | select INPUT_FF_MEMLESS |
253 | help | 252 | help |
@@ -256,7 +255,6 @@ config THRUSTMASTER_FF | |||
256 | 255 | ||
257 | config ZEROPLUS_FF | 256 | config ZEROPLUS_FF |
258 | tristate "Zeroplus based game controller support" | 257 | tristate "Zeroplus based game controller support" |
259 | default m | ||
260 | depends on USB_HID | 258 | depends on USB_HID |
261 | select INPUT_FF_MEMLESS | 259 | select INPUT_FF_MEMLESS |
262 | help | 260 | help |
diff --git a/drivers/hid/hid-apple.c b/drivers/hid/hid-apple.c index fd7f896b34f7..c6ab4ba60c52 100644 --- a/drivers/hid/hid-apple.c +++ b/drivers/hid/hid-apple.c | |||
@@ -312,13 +312,6 @@ static int apple_probe(struct hid_device *hdev, | |||
312 | unsigned int connect_mask = HID_CONNECT_DEFAULT; | 312 | unsigned int connect_mask = HID_CONNECT_DEFAULT; |
313 | int ret; | 313 | int ret; |
314 | 314 | ||
315 | /* return something else or move to hid layer? device will reside | ||
316 | allocated */ | ||
317 | if (id->bus == BUS_USB && (quirks & APPLE_IGNORE_MOUSE) && | ||
318 | to_usb_interface(hdev->dev.parent)->cur_altsetting-> | ||
319 | desc.bInterfaceProtocol == USB_INTERFACE_PROTOCOL_MOUSE) | ||
320 | return -ENODEV; | ||
321 | |||
322 | asc = kzalloc(sizeof(*asc), GFP_KERNEL); | 315 | asc = kzalloc(sizeof(*asc), GFP_KERNEL); |
323 | if (asc == NULL) { | 316 | if (asc == NULL) { |
324 | dev_err(&hdev->dev, "can't alloc apple descriptor\n"); | 317 | dev_err(&hdev->dev, "can't alloc apple descriptor\n"); |
@@ -367,38 +360,32 @@ static const struct hid_device_id apple_devices[] = { | |||
367 | .driver_data = APPLE_MIGHTYMOUSE | APPLE_INVERT_HWHEEL }, | 360 | .driver_data = APPLE_MIGHTYMOUSE | APPLE_INVERT_HWHEEL }, |
368 | 361 | ||
369 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_FOUNTAIN_ANSI), | 362 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_FOUNTAIN_ANSI), |
370 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 363 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
371 | APPLE_IGNORE_MOUSE }, | ||
372 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_FOUNTAIN_ISO), | 364 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_FOUNTAIN_ISO), |
373 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 365 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
374 | APPLE_IGNORE_MOUSE }, | ||
375 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER_ANSI), | 366 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER_ANSI), |
376 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 367 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
377 | APPLE_IGNORE_MOUSE }, | ||
378 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER_ISO), | 368 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER_ISO), |
379 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 369 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | |
380 | APPLE_IGNORE_MOUSE | APPLE_ISO_KEYBOARD }, | 370 | APPLE_ISO_KEYBOARD }, |
381 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER_JIS), | 371 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER_JIS), |
382 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 372 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
383 | APPLE_IGNORE_MOUSE }, | ||
384 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER3_ANSI), | 373 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER3_ANSI), |
385 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 374 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
386 | APPLE_IGNORE_MOUSE }, | ||
387 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER3_ISO), | 375 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER3_ISO), |
388 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 376 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | |
389 | APPLE_IGNORE_MOUSE | APPLE_ISO_KEYBOARD }, | 377 | APPLE_ISO_KEYBOARD }, |
390 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER3_JIS), | 378 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER3_JIS), |
391 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 379 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | |
392 | APPLE_IGNORE_MOUSE | APPLE_RDESC_JIS }, | 380 | APPLE_RDESC_JIS }, |
393 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_ANSI), | 381 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_ANSI), |
394 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 382 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
395 | APPLE_IGNORE_MOUSE }, | ||
396 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_ISO), | 383 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_ISO), |
397 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 384 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | |
398 | APPLE_IGNORE_MOUSE | APPLE_ISO_KEYBOARD }, | 385 | APPLE_ISO_KEYBOARD }, |
399 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_JIS), | 386 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_JIS), |
400 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 387 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | |
401 | APPLE_IGNORE_MOUSE | APPLE_RDESC_JIS}, | 388 | APPLE_RDESC_JIS }, |
402 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_ANSI), | 389 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_ANSI), |
403 | .driver_data = APPLE_HAS_FN }, | 390 | .driver_data = APPLE_HAS_FN }, |
404 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_ISO), | 391 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_ISO), |
@@ -406,14 +393,12 @@ static const struct hid_device_id apple_devices[] = { | |||
406 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_JIS), | 393 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_JIS), |
407 | .driver_data = APPLE_HAS_FN }, | 394 | .driver_data = APPLE_HAS_FN }, |
408 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_HF_ANSI), | 395 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_HF_ANSI), |
409 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 396 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
410 | APPLE_IGNORE_MOUSE }, | ||
411 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_HF_ISO), | 397 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_HF_ISO), |
412 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 398 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
413 | APPLE_IGNORE_MOUSE }, | ||
414 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_HF_JIS), | 399 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_HF_JIS), |
415 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 400 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | |
416 | APPLE_IGNORE_MOUSE | APPLE_RDESC_JIS }, | 401 | APPLE_RDESC_JIS }, |
417 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_ANSI), | 402 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_ANSI), |
418 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, | 403 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
419 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_ISO), | 404 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_ISO), |
@@ -422,25 +407,21 @@ static const struct hid_device_id apple_devices[] = { | |||
422 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_JIS), | 407 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_JIS), |
423 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, | 408 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
424 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING_ANSI), | 409 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING_ANSI), |
425 | .driver_data = APPLE_HAS_FN | APPLE_IGNORE_MOUSE }, | 410 | .driver_data = APPLE_HAS_FN }, |
426 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING_ISO), | 411 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING_ISO), |
427 | .driver_data = APPLE_HAS_FN | APPLE_ISO_KEYBOARD | | 412 | .driver_data = APPLE_HAS_FN | APPLE_ISO_KEYBOARD }, |
428 | APPLE_IGNORE_MOUSE }, | ||
429 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING_JIS), | 413 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING_JIS), |
430 | .driver_data = APPLE_HAS_FN | APPLE_IGNORE_MOUSE | APPLE_RDESC_JIS }, | 414 | .driver_data = APPLE_HAS_FN | APPLE_RDESC_JIS }, |
431 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING2_ANSI), | 415 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING2_ANSI), |
432 | .driver_data = APPLE_HAS_FN | APPLE_IGNORE_MOUSE }, | 416 | .driver_data = APPLE_HAS_FN }, |
433 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING2_ISO), | 417 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING2_ISO), |
434 | .driver_data = APPLE_HAS_FN | APPLE_ISO_KEYBOARD | | 418 | .driver_data = APPLE_HAS_FN | APPLE_ISO_KEYBOARD }, |
435 | APPLE_IGNORE_MOUSE }, | ||
436 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING2_JIS), | 419 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING2_JIS), |
437 | .driver_data = APPLE_HAS_FN | APPLE_IGNORE_MOUSE | APPLE_RDESC_JIS }, | 420 | .driver_data = APPLE_HAS_FN | APPLE_RDESC_JIS }, |
438 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_FOUNTAIN_TP_ONLY), | 421 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_FOUNTAIN_TP_ONLY), |
439 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 422 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
440 | APPLE_IGNORE_MOUSE }, | ||
441 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER1_TP_ONLY), | 423 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER1_TP_ONLY), |
442 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN | | 424 | .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN }, |
443 | APPLE_IGNORE_MOUSE }, | ||
444 | 425 | ||
445 | /* Apple wireless Mighty Mouse */ | 426 | /* Apple wireless Mighty Mouse */ |
446 | { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE, 0x030c), | 427 | { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE, 0x030c), |
diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c index 721a36d97582..743e6f8cb202 100644 --- a/drivers/hid/hid-core.c +++ b/drivers/hid/hid-core.c | |||
@@ -1264,6 +1264,7 @@ static const struct hid_device_id hid_blacklist[] = { | |||
1264 | { HID_USB_DEVICE(USB_VENDOR_ID_DELL, USB_DEVICE_ID_DELL_SK8115) }, | 1264 | { HID_USB_DEVICE(USB_VENDOR_ID_DELL, USB_DEVICE_ID_DELL_SK8115) }, |
1265 | { HID_USB_DEVICE(USB_VENDOR_ID_EZKEY, USB_DEVICE_ID_BTC_8193) }, | 1265 | { HID_USB_DEVICE(USB_VENDOR_ID_EZKEY, USB_DEVICE_ID_BTC_8193) }, |
1266 | { HID_USB_DEVICE(USB_VENDOR_ID_GYRATION, USB_DEVICE_ID_GYRATION_REMOTE) }, | 1266 | { HID_USB_DEVICE(USB_VENDOR_ID_GYRATION, USB_DEVICE_ID_GYRATION_REMOTE) }, |
1267 | { HID_USB_DEVICE(USB_VENDOR_ID_GYRATION, USB_DEVICE_ID_GYRATION_REMOTE_2) }, | ||
1267 | { HID_USB_DEVICE(USB_VENDOR_ID_LABTEC, USB_DEVICE_ID_LABTEC_WIRELESS_KEYBOARD) }, | 1268 | { HID_USB_DEVICE(USB_VENDOR_ID_LABTEC, USB_DEVICE_ID_LABTEC_WIRELESS_KEYBOARD) }, |
1268 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_MX3000_RECEIVER) }, | 1269 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_MX3000_RECEIVER) }, |
1269 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_S510_RECEIVER) }, | 1270 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_S510_RECEIVER) }, |
@@ -1275,8 +1276,6 @@ static const struct hid_device_id hid_blacklist[] = { | |||
1275 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_KBD) }, | 1276 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_KBD) }, |
1276 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_ELITE_KBD) }, | 1277 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_ELITE_KBD) }, |
1277 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_CORDLESS_DESKTOP_LX500) }, | 1278 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_CORDLESS_DESKTOP_LX500) }, |
1278 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_LX3) }, | ||
1279 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_V150) }, | ||
1280 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_EXTREME_3D) }, | 1279 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_EXTREME_3D) }, |
1281 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_WHEEL) }, | 1280 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_WHEEL) }, |
1282 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_RUMBLEPAD) }, | 1281 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_RUMBLEPAD) }, |
@@ -1295,6 +1294,7 @@ static const struct hid_device_id hid_blacklist[] = { | |||
1295 | { HID_USB_DEVICE(USB_VENDOR_ID_PETALYNX, USB_DEVICE_ID_PETALYNX_MAXTER_REMOTE) }, | 1294 | { HID_USB_DEVICE(USB_VENDOR_ID_PETALYNX, USB_DEVICE_ID_PETALYNX_MAXTER_REMOTE) }, |
1296 | { HID_USB_DEVICE(USB_VENDOR_ID_SAMSUNG, USB_DEVICE_ID_SAMSUNG_IR_REMOTE) }, | 1295 | { HID_USB_DEVICE(USB_VENDOR_ID_SAMSUNG, USB_DEVICE_ID_SAMSUNG_IR_REMOTE) }, |
1297 | { HID_USB_DEVICE(USB_VENDOR_ID_SONY, USB_DEVICE_ID_SONY_PS3_CONTROLLER) }, | 1296 | { HID_USB_DEVICE(USB_VENDOR_ID_SONY, USB_DEVICE_ID_SONY_PS3_CONTROLLER) }, |
1297 | { HID_USB_DEVICE(USB_VENDOR_ID_SONY, USB_DEVICE_ID_SONY_VAIO_VGX_MOUSE) }, | ||
1298 | { HID_USB_DEVICE(USB_VENDOR_ID_SUNPLUS, USB_DEVICE_ID_SUNPLUS_WDESKTOP) }, | 1298 | { HID_USB_DEVICE(USB_VENDOR_ID_SUNPLUS, USB_DEVICE_ID_SUNPLUS_WDESKTOP) }, |
1299 | 1299 | ||
1300 | { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE, 0x030c) }, | 1300 | { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE, 0x030c) }, |
@@ -1406,6 +1406,7 @@ static const struct hid_device_id hid_ignore_list[] = { | |||
1406 | { HID_USB_DEVICE(USB_VENDOR_ID_AIRCABLE, USB_DEVICE_ID_AIRCABLE1) }, | 1406 | { HID_USB_DEVICE(USB_VENDOR_ID_AIRCABLE, USB_DEVICE_ID_AIRCABLE1) }, |
1407 | { HID_USB_DEVICE(USB_VENDOR_ID_ALCOR, USB_DEVICE_ID_ALCOR_USBRS232) }, | 1407 | { HID_USB_DEVICE(USB_VENDOR_ID_ALCOR, USB_DEVICE_ID_ALCOR_USBRS232) }, |
1408 | { HID_USB_DEVICE(USB_VENDOR_ID_ASUS, USB_DEVICE_ID_ASUS_LCM)}, | 1408 | { HID_USB_DEVICE(USB_VENDOR_ID_ASUS, USB_DEVICE_ID_ASUS_LCM)}, |
1409 | { HID_USB_DEVICE(USB_VENDOR_ID_ASUS, USB_DEVICE_ID_ASUS_LCM2)}, | ||
1409 | { HID_USB_DEVICE(USB_VENDOR_ID_BERKSHIRE, USB_DEVICE_ID_BERKSHIRE_PCWD) }, | 1410 | { HID_USB_DEVICE(USB_VENDOR_ID_BERKSHIRE, USB_DEVICE_ID_BERKSHIRE_PCWD) }, |
1410 | { HID_USB_DEVICE(USB_VENDOR_ID_CIDC, 0x0103) }, | 1411 | { HID_USB_DEVICE(USB_VENDOR_ID_CIDC, 0x0103) }, |
1411 | { HID_USB_DEVICE(USB_VENDOR_ID_CYGNAL, USB_DEVICE_ID_CYGNAL_RADIO_SI470X) }, | 1412 | { HID_USB_DEVICE(USB_VENDOR_ID_CYGNAL, USB_DEVICE_ID_CYGNAL_RADIO_SI470X) }, |
@@ -1541,6 +1542,40 @@ static const struct hid_device_id hid_ignore_list[] = { | |||
1541 | { } | 1542 | { } |
1542 | }; | 1543 | }; |
1543 | 1544 | ||
1545 | /** | ||
1546 | * hid_mouse_ignore_list - mouse devices which should not be handled by the hid layer | ||
1547 | * | ||
1548 | * There are composite devices for which we want to ignore only a certain | ||
1549 | * interface. This is a list of devices for which only the mouse interface will | ||
1550 | * be ignored. This allows a dedicated driver to take care of the interface. | ||
1551 | */ | ||
1552 | static const struct hid_device_id hid_mouse_ignore_list[] = { | ||
1553 | /* appletouch driver */ | ||
1554 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_FOUNTAIN_ANSI) }, | ||
1555 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_FOUNTAIN_ISO) }, | ||
1556 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER_ANSI) }, | ||
1557 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER_ISO) }, | ||
1558 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER_JIS) }, | ||
1559 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER3_ANSI) }, | ||
1560 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER3_ISO) }, | ||
1561 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER3_JIS) }, | ||
1562 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_ANSI) }, | ||
1563 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_ISO) }, | ||
1564 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_JIS) }, | ||
1565 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_HF_ANSI) }, | ||
1566 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_HF_ISO) }, | ||
1567 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER4_HF_JIS) }, | ||
1568 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING_ANSI) }, | ||
1569 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING_ISO) }, | ||
1570 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING_JIS) }, | ||
1571 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING2_ANSI) }, | ||
1572 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING2_ISO) }, | ||
1573 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING2_JIS) }, | ||
1574 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_FOUNTAIN_TP_ONLY) }, | ||
1575 | { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER1_TP_ONLY) }, | ||
1576 | { } | ||
1577 | }; | ||
1578 | |||
1544 | static bool hid_ignore(struct hid_device *hdev) | 1579 | static bool hid_ignore(struct hid_device *hdev) |
1545 | { | 1580 | { |
1546 | switch (hdev->vendor) { | 1581 | switch (hdev->vendor) { |
@@ -1557,6 +1592,10 @@ static bool hid_ignore(struct hid_device *hdev) | |||
1557 | break; | 1592 | break; |
1558 | } | 1593 | } |
1559 | 1594 | ||
1595 | if (hdev->type == HID_TYPE_USBMOUSE && | ||
1596 | hid_match_id(hdev, hid_mouse_ignore_list)) | ||
1597 | return true; | ||
1598 | |||
1560 | return !!hid_match_id(hdev, hid_ignore_list); | 1599 | return !!hid_match_id(hdev, hid_ignore_list); |
1561 | } | 1600 | } |
1562 | 1601 | ||
diff --git a/drivers/hid/hid-gyration.c b/drivers/hid/hid-gyration.c index ac5120f542cc..04a0afec52ac 100644 --- a/drivers/hid/hid-gyration.c +++ b/drivers/hid/hid-gyration.c | |||
@@ -4,9 +4,9 @@ | |||
4 | * Copyright (c) 1999 Andreas Gal | 4 | * Copyright (c) 1999 Andreas Gal |
5 | * Copyright (c) 2000-2005 Vojtech Pavlik <vojtech@suse.cz> | 5 | * Copyright (c) 2000-2005 Vojtech Pavlik <vojtech@suse.cz> |
6 | * Copyright (c) 2005 Michael Haboustak <mike-@cinci.rr.com> for Concept2, Inc | 6 | * Copyright (c) 2005 Michael Haboustak <mike-@cinci.rr.com> for Concept2, Inc |
7 | * Copyright (c) 2006-2007 Jiri Kosina | ||
8 | * Copyright (c) 2007 Paul Walmsley | 7 | * Copyright (c) 2007 Paul Walmsley |
9 | * Copyright (c) 2008 Jiri Slaby | 8 | * Copyright (c) 2008 Jiri Slaby |
9 | * Copyright (c) 2006-2008 Jiri Kosina | ||
10 | */ | 10 | */ |
11 | 11 | ||
12 | /* | 12 | /* |
@@ -40,6 +40,7 @@ static int gyration_input_mapping(struct hid_device *hdev, struct hid_input *hi, | |||
40 | case 0x025: gy_map_key_clear(KEY_PVR); break; | 40 | case 0x025: gy_map_key_clear(KEY_PVR); break; |
41 | case 0x046: gy_map_key_clear(KEY_MEDIA); break; | 41 | case 0x046: gy_map_key_clear(KEY_MEDIA); break; |
42 | case 0x047: gy_map_key_clear(KEY_MP3); break; | 42 | case 0x047: gy_map_key_clear(KEY_MP3); break; |
43 | case 0x048: gy_map_key_clear(KEY_MEDIA); break; | ||
43 | case 0x049: gy_map_key_clear(KEY_CAMERA); break; | 44 | case 0x049: gy_map_key_clear(KEY_CAMERA); break; |
44 | case 0x04a: gy_map_key_clear(KEY_VIDEO); break; | 45 | case 0x04a: gy_map_key_clear(KEY_VIDEO); break; |
45 | 46 | ||
@@ -68,6 +69,7 @@ static int gyration_event(struct hid_device *hdev, struct hid_field *field, | |||
68 | 69 | ||
69 | static const struct hid_device_id gyration_devices[] = { | 70 | static const struct hid_device_id gyration_devices[] = { |
70 | { HID_USB_DEVICE(USB_VENDOR_ID_GYRATION, USB_DEVICE_ID_GYRATION_REMOTE) }, | 71 | { HID_USB_DEVICE(USB_VENDOR_ID_GYRATION, USB_DEVICE_ID_GYRATION_REMOTE) }, |
72 | { HID_USB_DEVICE(USB_VENDOR_ID_GYRATION, USB_DEVICE_ID_GYRATION_REMOTE_2) }, | ||
71 | { } | 73 | { } |
72 | }; | 74 | }; |
73 | MODULE_DEVICE_TABLE(hid, gyration_devices); | 75 | MODULE_DEVICE_TABLE(hid, gyration_devices); |
diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h index d9a1ba920c23..a0d6a6cb1842 100644 --- a/drivers/hid/hid-ids.h +++ b/drivers/hid/hid-ids.h | |||
@@ -89,6 +89,7 @@ | |||
89 | 89 | ||
90 | #define USB_VENDOR_ID_ASUS 0x0b05 | 90 | #define USB_VENDOR_ID_ASUS 0x0b05 |
91 | #define USB_DEVICE_ID_ASUS_LCM 0x1726 | 91 | #define USB_DEVICE_ID_ASUS_LCM 0x1726 |
92 | #define USB_DEVICE_ID_ASUS_LCM2 0x175b | ||
92 | 93 | ||
93 | #define USB_VENDOR_ID_ATEN 0x0557 | 94 | #define USB_VENDOR_ID_ATEN 0x0557 |
94 | #define USB_DEVICE_ID_ATEN_UC100KM 0x2004 | 95 | #define USB_DEVICE_ID_ATEN_UC100KM 0x2004 |
@@ -236,6 +237,7 @@ | |||
236 | 237 | ||
237 | #define USB_VENDOR_ID_GYRATION 0x0c16 | 238 | #define USB_VENDOR_ID_GYRATION 0x0c16 |
238 | #define USB_DEVICE_ID_GYRATION_REMOTE 0x0002 | 239 | #define USB_DEVICE_ID_GYRATION_REMOTE 0x0002 |
240 | #define USB_DEVICE_ID_GYRATION_REMOTE_2 0x0003 | ||
239 | 241 | ||
240 | #define USB_VENDOR_ID_HAPP 0x078b | 242 | #define USB_VENDOR_ID_HAPP 0x078b |
241 | #define USB_DEVICE_ID_UGCI_DRIVING 0x0010 | 243 | #define USB_DEVICE_ID_UGCI_DRIVING 0x0010 |
@@ -268,8 +270,6 @@ | |||
268 | #define USB_DEVICE_ID_LD_MACHINETEST 0x2040 | 270 | #define USB_DEVICE_ID_LD_MACHINETEST 0x2040 |
269 | 271 | ||
270 | #define USB_VENDOR_ID_LOGITECH 0x046d | 272 | #define USB_VENDOR_ID_LOGITECH 0x046d |
271 | #define USB_DEVICE_ID_LOGITECH_LX3 0xc044 | ||
272 | #define USB_DEVICE_ID_LOGITECH_V150 0xc047 | ||
273 | #define USB_DEVICE_ID_LOGITECH_RECEIVER 0xc101 | 273 | #define USB_DEVICE_ID_LOGITECH_RECEIVER 0xc101 |
274 | #define USB_DEVICE_ID_LOGITECH_HARMONY_FIRST 0xc110 | 274 | #define USB_DEVICE_ID_LOGITECH_HARMONY_FIRST 0xc110 |
275 | #define USB_DEVICE_ID_LOGITECH_HARMONY_LAST 0xc14f | 275 | #define USB_DEVICE_ID_LOGITECH_HARMONY_LAST 0xc14f |
@@ -350,6 +350,7 @@ | |||
350 | #define USB_DEVICE_ID_SAMSUNG_IR_REMOTE 0x0001 | 350 | #define USB_DEVICE_ID_SAMSUNG_IR_REMOTE 0x0001 |
351 | 351 | ||
352 | #define USB_VENDOR_ID_SONY 0x054c | 352 | #define USB_VENDOR_ID_SONY 0x054c |
353 | #define USB_DEVICE_ID_SONY_VAIO_VGX_MOUSE 0x024b | ||
353 | #define USB_DEVICE_ID_SONY_PS3_CONTROLLER 0x0268 | 354 | #define USB_DEVICE_ID_SONY_PS3_CONTROLLER 0x0268 |
354 | 355 | ||
355 | #define USB_VENDOR_ID_SOUNDGRAPH 0x15c2 | 356 | #define USB_VENDOR_ID_SOUNDGRAPH 0x15c2 |
diff --git a/drivers/hid/hid-lg.c b/drivers/hid/hid-lg.c index 406d8c82abf1..2bae340eafe2 100644 --- a/drivers/hid/hid-lg.c +++ b/drivers/hid/hid-lg.c | |||
@@ -287,11 +287,6 @@ static const struct hid_device_id lg_devices[] = { | |||
287 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_CORDLESS_DESKTOP_LX500), | 287 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_CORDLESS_DESKTOP_LX500), |
288 | .driver_data = LG_IGNORE_DOUBLED_WHEEL | LG_EXPANDED_KEYMAP }, | 288 | .driver_data = LG_IGNORE_DOUBLED_WHEEL | LG_EXPANDED_KEYMAP }, |
289 | 289 | ||
290 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_LX3), | ||
291 | .driver_data = LG_INVERT_HWHEEL }, | ||
292 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_V150), | ||
293 | .driver_data = LG_INVERT_HWHEEL }, | ||
294 | |||
295 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_EXTREME_3D), | 290 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_EXTREME_3D), |
296 | .driver_data = LG_NOGET }, | 291 | .driver_data = LG_NOGET }, |
297 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_WHEEL), | 292 | { HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_WHEEL), |
diff --git a/drivers/hid/hid-sony.c b/drivers/hid/hid-sony.c index 3af8095a7de1..86e563b8d644 100644 --- a/drivers/hid/hid-sony.c +++ b/drivers/hid/hid-sony.c | |||
@@ -4,9 +4,9 @@ | |||
4 | * Copyright (c) 1999 Andreas Gal | 4 | * Copyright (c) 1999 Andreas Gal |
5 | * Copyright (c) 2000-2005 Vojtech Pavlik <vojtech@suse.cz> | 5 | * Copyright (c) 2000-2005 Vojtech Pavlik <vojtech@suse.cz> |
6 | * Copyright (c) 2005 Michael Haboustak <mike-@cinci.rr.com> for Concept2, Inc | 6 | * Copyright (c) 2005 Michael Haboustak <mike-@cinci.rr.com> for Concept2, Inc |
7 | * Copyright (c) 2006-2007 Jiri Kosina | ||
8 | * Copyright (c) 2007 Paul Walmsley | 7 | * Copyright (c) 2007 Paul Walmsley |
9 | * Copyright (c) 2008 Jiri Slaby | 8 | * Copyright (c) 2008 Jiri Slaby |
9 | * Copyright (c) 2006-2008 Jiri Kosina | ||
10 | */ | 10 | */ |
11 | 11 | ||
12 | /* | 12 | /* |
@@ -23,6 +23,26 @@ | |||
23 | 23 | ||
24 | #include "hid-ids.h" | 24 | #include "hid-ids.h" |
25 | 25 | ||
26 | #define VAIO_RDESC_CONSTANT 0x0001 | ||
27 | |||
28 | struct sony_sc { | ||
29 | unsigned long quirks; | ||
30 | }; | ||
31 | |||
32 | /* Sony Vaio VGX has wrongly mouse pointer declared as constant */ | ||
33 | static void sony_report_fixup(struct hid_device *hdev, __u8 *rdesc, | ||
34 | unsigned int rsize) | ||
35 | { | ||
36 | struct sony_sc *sc = hid_get_drvdata(hdev); | ||
37 | |||
38 | if ((sc->quirks & VAIO_RDESC_CONSTANT) && | ||
39 | rsize >= 56 && rdesc[54] == 0x81 && rdesc[55] == 0x07) { | ||
40 | dev_info(&hdev->dev, "Fixing up Sony Vaio VGX report " | ||
41 | "descriptor\n"); | ||
42 | rdesc[55] = 0x06; | ||
43 | } | ||
44 | } | ||
45 | |||
26 | /* | 46 | /* |
27 | * Sending HID_REQ_GET_REPORT changes the operation mode of the ps3 controller | 47 | * Sending HID_REQ_GET_REPORT changes the operation mode of the ps3 controller |
28 | * to "operational". Without this, the ps3 controller will not report any | 48 | * to "operational". Without this, the ps3 controller will not report any |
@@ -56,6 +76,17 @@ static int sony_set_operational(struct hid_device *hdev) | |||
56 | static int sony_probe(struct hid_device *hdev, const struct hid_device_id *id) | 76 | static int sony_probe(struct hid_device *hdev, const struct hid_device_id *id) |
57 | { | 77 | { |
58 | int ret; | 78 | int ret; |
79 | unsigned long quirks = id->driver_data; | ||
80 | struct sony_sc *sc; | ||
81 | |||
82 | sc = kzalloc(sizeof(*sc), GFP_KERNEL); | ||
83 | if (sc == NULL) { | ||
84 | dev_err(&hdev->dev, "can't alloc apple descriptor\n"); | ||
85 | return -ENOMEM; | ||
86 | } | ||
87 | |||
88 | sc->quirks = quirks; | ||
89 | hid_set_drvdata(hdev, sc); | ||
59 | 90 | ||
60 | ret = hid_parse(hdev); | 91 | ret = hid_parse(hdev); |
61 | if (ret) { | 92 | if (ret) { |
@@ -78,11 +109,20 @@ static int sony_probe(struct hid_device *hdev, const struct hid_device_id *id) | |||
78 | err_stop: | 109 | err_stop: |
79 | hid_hw_stop(hdev); | 110 | hid_hw_stop(hdev); |
80 | err_free: | 111 | err_free: |
112 | kfree(sc); | ||
81 | return ret; | 113 | return ret; |
82 | } | 114 | } |
83 | 115 | ||
116 | static void sony_remove(struct hid_device *hdev) | ||
117 | { | ||
118 | hid_hw_stop(hdev); | ||
119 | kfree(hid_get_drvdata(hdev)); | ||
120 | } | ||
121 | |||
84 | static const struct hid_device_id sony_devices[] = { | 122 | static const struct hid_device_id sony_devices[] = { |
85 | { HID_USB_DEVICE(USB_VENDOR_ID_SONY, USB_DEVICE_ID_SONY_PS3_CONTROLLER) }, | 123 | { HID_USB_DEVICE(USB_VENDOR_ID_SONY, USB_DEVICE_ID_SONY_PS3_CONTROLLER) }, |
124 | { HID_USB_DEVICE(USB_VENDOR_ID_SONY, USB_DEVICE_ID_SONY_VAIO_VGX_MOUSE), | ||
125 | .driver_data = VAIO_RDESC_CONSTANT }, | ||
86 | { } | 126 | { } |
87 | }; | 127 | }; |
88 | MODULE_DEVICE_TABLE(hid, sony_devices); | 128 | MODULE_DEVICE_TABLE(hid, sony_devices); |
@@ -91,6 +131,8 @@ static struct hid_driver sony_driver = { | |||
91 | .name = "sony", | 131 | .name = "sony", |
92 | .id_table = sony_devices, | 132 | .id_table = sony_devices, |
93 | .probe = sony_probe, | 133 | .probe = sony_probe, |
134 | .remove = sony_remove, | ||
135 | .report_fixup = sony_report_fixup, | ||
94 | }; | 136 | }; |
95 | 137 | ||
96 | static int sony_init(void) | 138 | static int sony_init(void) |
diff --git a/drivers/hid/hidraw.c b/drivers/hid/hidraw.c index af3edb98df43..894d52e05bf9 100644 --- a/drivers/hid/hidraw.c +++ b/drivers/hid/hidraw.c | |||
@@ -264,6 +264,7 @@ static long hidraw_ioctl(struct file *file, unsigned int cmd, | |||
264 | default: | 264 | default: |
265 | ret = -ENOTTY; | 265 | ret = -ENOTTY; |
266 | } | 266 | } |
267 | unlock_kernel(); | ||
267 | return ret; | 268 | return ret; |
268 | } | 269 | } |
269 | 270 | ||
@@ -403,7 +404,7 @@ out: | |||
403 | return result; | 404 | return result; |
404 | } | 405 | } |
405 | 406 | ||
406 | void __exit hidraw_exit(void) | 407 | void hidraw_exit(void) |
407 | { | 408 | { |
408 | dev_t dev_id = MKDEV(hidraw_major, 0); | 409 | dev_t dev_id = MKDEV(hidraw_major, 0); |
409 | 410 | ||
diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c index 705a43cdeea4..42bdd83444c1 100644 --- a/drivers/hid/usbhid/hid-core.c +++ b/drivers/hid/usbhid/hid-core.c | |||
@@ -972,6 +972,9 @@ static int hid_probe(struct usb_interface *intf, const struct usb_device_id *id) | |||
972 | hid->vendor = le16_to_cpu(dev->descriptor.idVendor); | 972 | hid->vendor = le16_to_cpu(dev->descriptor.idVendor); |
973 | hid->product = le16_to_cpu(dev->descriptor.idProduct); | 973 | hid->product = le16_to_cpu(dev->descriptor.idProduct); |
974 | hid->name[0] = 0; | 974 | hid->name[0] = 0; |
975 | if (intf->cur_altsetting->desc.bInterfaceProtocol == | ||
976 | USB_INTERFACE_PROTOCOL_MOUSE) | ||
977 | hid->type = HID_TYPE_USBMOUSE; | ||
975 | 978 | ||
976 | if (dev->manufacturer) | 979 | if (dev->manufacturer) |
977 | strlcpy(hid->name, dev->manufacturer, sizeof(hid->name)); | 980 | strlcpy(hid->name, dev->manufacturer, sizeof(hid->name)); |
diff --git a/drivers/hid/usbhid/hiddev.c b/drivers/hid/usbhid/hiddev.c index babd65dd46ad..3ac320785fc5 100644 --- a/drivers/hid/usbhid/hiddev.c +++ b/drivers/hid/usbhid/hiddev.c | |||
@@ -436,8 +436,7 @@ static noinline int hiddev_ioctl_usage(struct hiddev *hiddev, unsigned int cmd, | |||
436 | if (copy_to_user(user_arg, uref, sizeof(*uref))) | 436 | if (copy_to_user(user_arg, uref, sizeof(*uref))) |
437 | goto fault; | 437 | goto fault; |
438 | 438 | ||
439 | kfree(uref_multi); | 439 | goto goodreturn; |
440 | return 0; | ||
441 | 440 | ||
442 | default: | 441 | default: |
443 | if (cmd != HIDIOCGUSAGE && | 442 | if (cmd != HIDIOCGUSAGE && |
diff --git a/drivers/hwmon/abituguru3.c b/drivers/hwmon/abituguru3.c index d9e7a49d6cbf..70bb854086df 100644 --- a/drivers/hwmon/abituguru3.c +++ b/drivers/hwmon/abituguru3.c | |||
@@ -178,7 +178,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
178 | { "+3.3V", 10, 0, 20, 1, 0 }, | 178 | { "+3.3V", 10, 0, 20, 1, 0 }, |
179 | { "5VSB", 11, 0, 30, 1, 0 }, | 179 | { "5VSB", 11, 0, 30, 1, 0 }, |
180 | { "CPU", 24, 1, 1, 1, 0 }, | 180 | { "CPU", 24, 1, 1, 1, 0 }, |
181 | { "System ", 25, 1, 1, 1, 0 }, | 181 | { "System", 25, 1, 1, 1, 0 }, |
182 | { "PWM", 26, 1, 1, 1, 0 }, | 182 | { "PWM", 26, 1, 1, 1, 0 }, |
183 | { "CPU Fan", 32, 2, 60, 1, 0 }, | 183 | { "CPU Fan", 32, 2, 60, 1, 0 }, |
184 | { "NB Fan", 33, 2, 60, 1, 0 }, | 184 | { "NB Fan", 33, 2, 60, 1, 0 }, |
@@ -200,7 +200,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
200 | { "+3.3V", 10, 0, 20, 1, 0 }, | 200 | { "+3.3V", 10, 0, 20, 1, 0 }, |
201 | { "5VSB", 11, 0, 30, 1, 0 }, | 201 | { "5VSB", 11, 0, 30, 1, 0 }, |
202 | { "CPU", 24, 1, 1, 1, 0 }, | 202 | { "CPU", 24, 1, 1, 1, 0 }, |
203 | { "System ", 25, 1, 1, 1, 0 }, | 203 | { "System", 25, 1, 1, 1, 0 }, |
204 | { "PWM1", 26, 1, 1, 1, 0 }, | 204 | { "PWM1", 26, 1, 1, 1, 0 }, |
205 | { "PWM2", 27, 1, 1, 1, 0 }, | 205 | { "PWM2", 27, 1, 1, 1, 0 }, |
206 | { "PWM3", 28, 1, 1, 1, 0 }, | 206 | { "PWM3", 28, 1, 1, 1, 0 }, |
@@ -229,7 +229,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
229 | { "+3.3V", 10, 0, 20, 1, 0 }, | 229 | { "+3.3V", 10, 0, 20, 1, 0 }, |
230 | { "5VSB", 11, 0, 30, 1, 0 }, | 230 | { "5VSB", 11, 0, 30, 1, 0 }, |
231 | { "CPU", 24, 1, 1, 1, 0 }, | 231 | { "CPU", 24, 1, 1, 1, 0 }, |
232 | { "System ", 25, 1, 1, 1, 0 }, | 232 | { "System", 25, 1, 1, 1, 0 }, |
233 | { "PWM", 26, 1, 1, 1, 0 }, | 233 | { "PWM", 26, 1, 1, 1, 0 }, |
234 | { "CPU Fan", 32, 2, 60, 1, 0 }, | 234 | { "CPU Fan", 32, 2, 60, 1, 0 }, |
235 | { "NB Fan", 33, 2, 60, 1, 0 }, | 235 | { "NB Fan", 33, 2, 60, 1, 0 }, |
@@ -250,7 +250,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
250 | { "+3.3V", 10, 0, 20, 1, 0 }, | 250 | { "+3.3V", 10, 0, 20, 1, 0 }, |
251 | { "5VSB", 11, 0, 30, 1, 0 }, | 251 | { "5VSB", 11, 0, 30, 1, 0 }, |
252 | { "CPU", 24, 1, 1, 1, 0 }, | 252 | { "CPU", 24, 1, 1, 1, 0 }, |
253 | { "System ", 25, 1, 1, 1, 0 }, | 253 | { "System", 25, 1, 1, 1, 0 }, |
254 | { "PWM", 26, 1, 1, 1, 0 }, | 254 | { "PWM", 26, 1, 1, 1, 0 }, |
255 | { "CPU Fan", 32, 2, 60, 1, 0 }, | 255 | { "CPU Fan", 32, 2, 60, 1, 0 }, |
256 | { "NB Fan", 33, 2, 60, 1, 0 }, | 256 | { "NB Fan", 33, 2, 60, 1, 0 }, |
@@ -342,7 +342,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
342 | { "+3.3V", 10, 0, 20, 1, 0 }, | 342 | { "+3.3V", 10, 0, 20, 1, 0 }, |
343 | { "5VSB", 11, 0, 30, 1, 0 }, | 343 | { "5VSB", 11, 0, 30, 1, 0 }, |
344 | { "CPU", 24, 1, 1, 1, 0 }, | 344 | { "CPU", 24, 1, 1, 1, 0 }, |
345 | { "System ", 25, 1, 1, 1, 0 }, | 345 | { "System", 25, 1, 1, 1, 0 }, |
346 | { "PWM1", 26, 1, 1, 1, 0 }, | 346 | { "PWM1", 26, 1, 1, 1, 0 }, |
347 | { "PWM2", 27, 1, 1, 1, 0 }, | 347 | { "PWM2", 27, 1, 1, 1, 0 }, |
348 | { "PWM3", 28, 1, 1, 1, 0 }, | 348 | { "PWM3", 28, 1, 1, 1, 0 }, |
@@ -371,7 +371,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
371 | { "+3.3V", 10, 0, 20, 1, 0 }, | 371 | { "+3.3V", 10, 0, 20, 1, 0 }, |
372 | { "5VSB", 11, 0, 30, 1, 0 }, | 372 | { "5VSB", 11, 0, 30, 1, 0 }, |
373 | { "CPU", 24, 1, 1, 1, 0 }, | 373 | { "CPU", 24, 1, 1, 1, 0 }, |
374 | { "System ", 25, 1, 1, 1, 0 }, | 374 | { "System", 25, 1, 1, 1, 0 }, |
375 | { "PWM", 26, 1, 1, 1, 0 }, | 375 | { "PWM", 26, 1, 1, 1, 0 }, |
376 | { "CPU Fan", 32, 2, 60, 1, 0 }, | 376 | { "CPU Fan", 32, 2, 60, 1, 0 }, |
377 | { "NB Fan", 33, 2, 60, 1, 0 }, | 377 | { "NB Fan", 33, 2, 60, 1, 0 }, |
@@ -402,7 +402,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
402 | { "AUX3 Fan", 36, 2, 60, 1, 0 }, | 402 | { "AUX3 Fan", 36, 2, 60, 1, 0 }, |
403 | { NULL, 0, 0, 0, 0, 0 } } | 403 | { NULL, 0, 0, 0, 0, 0 } } |
404 | }, | 404 | }, |
405 | { 0x0016, NULL /* AW9D-MAX, need DMI string */, { | 405 | { 0x0016, "AW9D-MAX (Intel i975-ICH7)", { |
406 | { "CPU Core", 0, 0, 10, 1, 0 }, | 406 | { "CPU Core", 0, 0, 10, 1, 0 }, |
407 | { "DDR2", 1, 0, 20, 1, 0 }, | 407 | { "DDR2", 1, 0, 20, 1, 0 }, |
408 | { "DDR2 VTT", 2, 0, 10, 1, 0 }, | 408 | { "DDR2 VTT", 2, 0, 10, 1, 0 }, |
@@ -416,7 +416,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
416 | { "+3.3V", 10, 0, 20, 1, 0 }, | 416 | { "+3.3V", 10, 0, 20, 1, 0 }, |
417 | { "5VSB", 11, 0, 30, 1, 0 }, | 417 | { "5VSB", 11, 0, 30, 1, 0 }, |
418 | { "CPU", 24, 1, 1, 1, 0 }, | 418 | { "CPU", 24, 1, 1, 1, 0 }, |
419 | { "System ", 25, 1, 1, 1, 0 }, | 419 | { "System", 25, 1, 1, 1, 0 }, |
420 | { "PWM1", 26, 1, 1, 1, 0 }, | 420 | { "PWM1", 26, 1, 1, 1, 0 }, |
421 | { "PWM2", 27, 1, 1, 1, 0 }, | 421 | { "PWM2", 27, 1, 1, 1, 0 }, |
422 | { "PWM3", 28, 1, 1, 1, 0 }, | 422 | { "PWM3", 28, 1, 1, 1, 0 }, |
@@ -446,7 +446,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
446 | { "ATX +3.3V", 10, 0, 20, 1, 0 }, | 446 | { "ATX +3.3V", 10, 0, 20, 1, 0 }, |
447 | { "ATX 5VSB", 11, 0, 30, 1, 0 }, | 447 | { "ATX 5VSB", 11, 0, 30, 1, 0 }, |
448 | { "CPU", 24, 1, 1, 1, 0 }, | 448 | { "CPU", 24, 1, 1, 1, 0 }, |
449 | { "System ", 26, 1, 1, 1, 0 }, | 449 | { "System", 26, 1, 1, 1, 0 }, |
450 | { "PWM", 27, 1, 1, 1, 0 }, | 450 | { "PWM", 27, 1, 1, 1, 0 }, |
451 | { "CPU FAN", 32, 2, 60, 1, 0 }, | 451 | { "CPU FAN", 32, 2, 60, 1, 0 }, |
452 | { "SYS FAN", 34, 2, 60, 1, 0 }, | 452 | { "SYS FAN", 34, 2, 60, 1, 0 }, |
@@ -469,7 +469,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
469 | { "+3.3V", 10, 0, 20, 1, 0 }, | 469 | { "+3.3V", 10, 0, 20, 1, 0 }, |
470 | { "5VSB", 11, 0, 30, 1, 0 }, | 470 | { "5VSB", 11, 0, 30, 1, 0 }, |
471 | { "CPU", 24, 1, 1, 1, 0 }, | 471 | { "CPU", 24, 1, 1, 1, 0 }, |
472 | { "System ", 25, 1, 1, 1, 0 }, | 472 | { "System", 25, 1, 1, 1, 0 }, |
473 | { "PWM Phase1", 26, 1, 1, 1, 0 }, | 473 | { "PWM Phase1", 26, 1, 1, 1, 0 }, |
474 | { "PWM Phase2", 27, 1, 1, 1, 0 }, | 474 | { "PWM Phase2", 27, 1, 1, 1, 0 }, |
475 | { "PWM Phase3", 28, 1, 1, 1, 0 }, | 475 | { "PWM Phase3", 28, 1, 1, 1, 0 }, |
@@ -487,7 +487,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
487 | { "DDR2", 13, 0, 20, 1, 0 }, | 487 | { "DDR2", 13, 0, 20, 1, 0 }, |
488 | { "DDR2 VTT", 14, 0, 10, 1, 0 }, | 488 | { "DDR2 VTT", 14, 0, 10, 1, 0 }, |
489 | { "CPU VTT", 3, 0, 20, 1, 0 }, | 489 | { "CPU VTT", 3, 0, 20, 1, 0 }, |
490 | { "NB 1.2V ", 4, 0, 10, 1, 0 }, | 490 | { "NB 1.2V", 4, 0, 10, 1, 0 }, |
491 | { "SB 1.5V", 6, 0, 10, 1, 0 }, | 491 | { "SB 1.5V", 6, 0, 10, 1, 0 }, |
492 | { "HyperTransport", 5, 0, 10, 1, 0 }, | 492 | { "HyperTransport", 5, 0, 10, 1, 0 }, |
493 | { "ATX +12V (24-Pin)", 12, 0, 60, 1, 0 }, | 493 | { "ATX +12V (24-Pin)", 12, 0, 60, 1, 0 }, |
@@ -496,7 +496,7 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
496 | { "ATX +3.3V", 10, 0, 20, 1, 0 }, | 496 | { "ATX +3.3V", 10, 0, 20, 1, 0 }, |
497 | { "ATX 5VSB", 11, 0, 30, 1, 0 }, | 497 | { "ATX 5VSB", 11, 0, 30, 1, 0 }, |
498 | { "CPU", 24, 1, 1, 1, 0 }, | 498 | { "CPU", 24, 1, 1, 1, 0 }, |
499 | { "System ", 25, 1, 1, 1, 0 }, | 499 | { "System", 25, 1, 1, 1, 0 }, |
500 | { "PWM Phase1", 26, 1, 1, 1, 0 }, | 500 | { "PWM Phase1", 26, 1, 1, 1, 0 }, |
501 | { "PWM Phase2", 27, 1, 1, 1, 0 }, | 501 | { "PWM Phase2", 27, 1, 1, 1, 0 }, |
502 | { "PWM Phase3", 28, 1, 1, 1, 0 }, | 502 | { "PWM Phase3", 28, 1, 1, 1, 0 }, |
@@ -523,8 +523,8 @@ static const struct abituguru3_motherboard_info abituguru3_motherboards[] = { | |||
523 | { "+3.3V", 10, 0, 20, 1, 0 }, | 523 | { "+3.3V", 10, 0, 20, 1, 0 }, |
524 | { "5VSB", 11, 0, 30, 1, 0 }, | 524 | { "5VSB", 11, 0, 30, 1, 0 }, |
525 | { "CPU", 24, 1, 1, 1, 0 }, | 525 | { "CPU", 24, 1, 1, 1, 0 }, |
526 | { "System ", 25, 1, 1, 1, 0 }, | 526 | { "System", 25, 1, 1, 1, 0 }, |
527 | { "PWM ", 26, 1, 1, 1, 0 }, | 527 | { "PWM", 26, 1, 1, 1, 0 }, |
528 | { "PWM Phase2", 27, 1, 1, 1, 0 }, | 528 | { "PWM Phase2", 27, 1, 1, 1, 0 }, |
529 | { "PWM Phase3", 28, 1, 1, 1, 0 }, | 529 | { "PWM Phase3", 28, 1, 1, 1, 0 }, |
530 | { "PWM Phase4", 29, 1, 1, 1, 0 }, | 530 | { "PWM Phase4", 29, 1, 1, 1, 0 }, |
@@ -947,7 +947,7 @@ static int __devinit abituguru3_probe(struct platform_device *pdev) | |||
947 | if (!abituguru3_motherboards[i].dmi_name) { | 947 | if (!abituguru3_motherboards[i].dmi_name) { |
948 | printk(KERN_WARNING ABIT_UGURU3_NAME ": this motherboard was " | 948 | printk(KERN_WARNING ABIT_UGURU3_NAME ": this motherboard was " |
949 | "not detected using DMI. Please send the output of " | 949 | "not detected using DMI. Please send the output of " |
950 | "\"dmidecode\" to the abituguru3 maintainer" | 950 | "\"dmidecode\" to the abituguru3 maintainer " |
951 | "(see MAINTAINERS)\n"); | 951 | "(see MAINTAINERS)\n"); |
952 | } | 952 | } |
953 | #endif | 953 | #endif |
diff --git a/drivers/hwmon/adt7473.c b/drivers/hwmon/adt7473.c index 3a0b63136479..b9a8ea30c99c 100644 --- a/drivers/hwmon/adt7473.c +++ b/drivers/hwmon/adt7473.c | |||
@@ -319,35 +319,24 @@ out: | |||
319 | } | 319 | } |
320 | 320 | ||
321 | /* | 321 | /* |
322 | * On this chip, voltages are given as a count of steps between a minimum | 322 | * Conversions |
323 | * and maximum voltage, not a direct voltage. | ||
324 | */ | 323 | */ |
325 | static const int volt_convert_table[][2] = { | 324 | |
326 | {2997, 3}, | 325 | /* IN are scaled acording to built-in resistors */ |
327 | {4395, 4}, | 326 | static const int adt7473_scaling[] = { /* .001 Volts */ |
327 | 2250, 3300 | ||
328 | }; | 328 | }; |
329 | #define SCALE(val, from, to) (((val) * (to) + ((from) / 2)) / (from)) | ||
329 | 330 | ||
330 | static int decode_volt(int volt_index, u8 raw) | 331 | static int decode_volt(int volt_index, u8 raw) |
331 | { | 332 | { |
332 | int cmax = volt_convert_table[volt_index][0]; | 333 | return SCALE(raw, 192, adt7473_scaling[volt_index]); |
333 | int cmin = volt_convert_table[volt_index][1]; | ||
334 | return ((raw * (cmax - cmin)) / 255) + cmin; | ||
335 | } | 334 | } |
336 | 335 | ||
337 | static u8 encode_volt(int volt_index, int cooked) | 336 | static u8 encode_volt(int volt_index, int cooked) |
338 | { | 337 | { |
339 | int cmax = volt_convert_table[volt_index][0]; | 338 | int raw = SCALE(cooked, adt7473_scaling[volt_index], 192); |
340 | int cmin = volt_convert_table[volt_index][1]; | 339 | return SENSORS_LIMIT(raw, 0, 255); |
341 | u8 x; | ||
342 | |||
343 | if (cooked > cmax) | ||
344 | cooked = cmax; | ||
345 | else if (cooked < cmin) | ||
346 | cooked = cmin; | ||
347 | |||
348 | x = ((cooked - cmin) * 255) / (cmax - cmin); | ||
349 | |||
350 | return x; | ||
351 | } | 340 | } |
352 | 341 | ||
353 | static ssize_t show_volt_min(struct device *dev, | 342 | static ssize_t show_volt_min(struct device *dev, |
diff --git a/drivers/hwmon/hwmon-vid.c b/drivers/hwmon/hwmon-vid.c index c54eff92be4a..bfc296145bba 100644 --- a/drivers/hwmon/hwmon-vid.c +++ b/drivers/hwmon/hwmon-vid.c | |||
@@ -180,6 +180,7 @@ static struct vrm_model vrm_models[] = { | |||
180 | {X86_VENDOR_AMD, 0x6, ANY, ANY, 90}, /* Athlon Duron etc */ | 180 | {X86_VENDOR_AMD, 0x6, ANY, ANY, 90}, /* Athlon Duron etc */ |
181 | {X86_VENDOR_AMD, 0xF, 0x3F, ANY, 24}, /* Athlon 64, Opteron */ | 181 | {X86_VENDOR_AMD, 0xF, 0x3F, ANY, 24}, /* Athlon 64, Opteron */ |
182 | {X86_VENDOR_AMD, 0xF, ANY, ANY, 25}, /* NPT family 0Fh */ | 182 | {X86_VENDOR_AMD, 0xF, ANY, ANY, 25}, /* NPT family 0Fh */ |
183 | {X86_VENDOR_AMD, 0x10, ANY, ANY, 25}, /* NPT family 10h */ | ||
183 | {X86_VENDOR_INTEL, 0x6, 0x9, ANY, 13}, /* Pentium M (130 nm) */ | 184 | {X86_VENDOR_INTEL, 0x6, 0x9, ANY, 13}, /* Pentium M (130 nm) */ |
184 | {X86_VENDOR_INTEL, 0x6, 0xB, ANY, 85}, /* Tualatin */ | 185 | {X86_VENDOR_INTEL, 0x6, 0xB, ANY, 85}, /* Tualatin */ |
185 | {X86_VENDOR_INTEL, 0x6, 0xD, ANY, 13}, /* Pentium M (90 nm) */ | 186 | {X86_VENDOR_INTEL, 0x6, 0xD, ANY, 13}, /* Pentium M (90 nm) */ |
diff --git a/drivers/hwmon/lm90.c b/drivers/hwmon/lm90.c index 3edeebc0b835..96a701866726 100644 --- a/drivers/hwmon/lm90.c +++ b/drivers/hwmon/lm90.c | |||
@@ -12,9 +12,9 @@ | |||
12 | * made by National Semiconductor. Both have an increased remote | 12 | * made by National Semiconductor. Both have an increased remote |
13 | * temperature measurement accuracy (1 degree), and the LM99 | 13 | * temperature measurement accuracy (1 degree), and the LM99 |
14 | * additionally shifts remote temperatures (measured and limits) by 16 | 14 | * additionally shifts remote temperatures (measured and limits) by 16 |
15 | * degrees, which allows for higher temperatures measurement. The | 15 | * degrees, which allows for higher temperatures measurement. |
16 | * driver doesn't handle it since it can be done easily in user-space. | ||
17 | * Note that there is no way to differentiate between both chips. | 16 | * Note that there is no way to differentiate between both chips. |
17 | * When device is auto-detected, the driver will assume an LM99. | ||
18 | * | 18 | * |
19 | * This driver also supports the LM86, another sensor chip made by | 19 | * This driver also supports the LM86, another sensor chip made by |
20 | * National Semiconductor. It is exactly similar to the LM90 except it | 20 | * National Semiconductor. It is exactly similar to the LM90 except it |
@@ -169,8 +169,8 @@ static const struct i2c_device_id lm90_id[] = { | |||
169 | { "adt7461", adt7461 }, | 169 | { "adt7461", adt7461 }, |
170 | { "lm90", lm90 }, | 170 | { "lm90", lm90 }, |
171 | { "lm86", lm86 }, | 171 | { "lm86", lm86 }, |
172 | { "lm89", lm99 }, | 172 | { "lm89", lm86 }, |
173 | { "lm99", lm99 }, /* Missing temperature offset */ | 173 | { "lm99", lm99 }, |
174 | { "max6646", max6646 }, | 174 | { "max6646", max6646 }, |
175 | { "max6647", max6646 }, | 175 | { "max6647", max6646 }, |
176 | { "max6649", max6646 }, | 176 | { "max6649", max6646 }, |
@@ -366,6 +366,10 @@ static ssize_t show_temp8(struct device *dev, struct device_attribute *devattr, | |||
366 | else | 366 | else |
367 | temp = temp_from_s8(data->temp8[attr->index]); | 367 | temp = temp_from_s8(data->temp8[attr->index]); |
368 | 368 | ||
369 | /* +16 degrees offset for temp2 for the LM99 */ | ||
370 | if (data->kind == lm99 && attr->index == 3) | ||
371 | temp += 16000; | ||
372 | |||
369 | return sprintf(buf, "%d\n", temp); | 373 | return sprintf(buf, "%d\n", temp); |
370 | } | 374 | } |
371 | 375 | ||
@@ -385,6 +389,10 @@ static ssize_t set_temp8(struct device *dev, struct device_attribute *devattr, | |||
385 | long val = simple_strtol(buf, NULL, 10); | 389 | long val = simple_strtol(buf, NULL, 10); |
386 | int nr = attr->index; | 390 | int nr = attr->index; |
387 | 391 | ||
392 | /* +16 degrees offset for temp2 for the LM99 */ | ||
393 | if (data->kind == lm99 && attr->index == 3) | ||
394 | val -= 16000; | ||
395 | |||
388 | mutex_lock(&data->update_lock); | 396 | mutex_lock(&data->update_lock); |
389 | if (data->kind == adt7461) | 397 | if (data->kind == adt7461) |
390 | data->temp8[nr] = temp_to_u8_adt7461(data, val); | 398 | data->temp8[nr] = temp_to_u8_adt7461(data, val); |
@@ -411,6 +419,10 @@ static ssize_t show_temp11(struct device *dev, struct device_attribute *devattr, | |||
411 | else | 419 | else |
412 | temp = temp_from_s16(data->temp11[attr->index]); | 420 | temp = temp_from_s16(data->temp11[attr->index]); |
413 | 421 | ||
422 | /* +16 degrees offset for temp2 for the LM99 */ | ||
423 | if (data->kind == lm99 && attr->index <= 2) | ||
424 | temp += 16000; | ||
425 | |||
414 | return sprintf(buf, "%d\n", temp); | 426 | return sprintf(buf, "%d\n", temp); |
415 | } | 427 | } |
416 | 428 | ||
@@ -432,6 +444,10 @@ static ssize_t set_temp11(struct device *dev, struct device_attribute *devattr, | |||
432 | long val = simple_strtol(buf, NULL, 10); | 444 | long val = simple_strtol(buf, NULL, 10); |
433 | int nr = attr->index; | 445 | int nr = attr->index; |
434 | 446 | ||
447 | /* +16 degrees offset for temp2 for the LM99 */ | ||
448 | if (data->kind == lm99 && attr->index <= 2) | ||
449 | val -= 16000; | ||
450 | |||
435 | mutex_lock(&data->update_lock); | 451 | mutex_lock(&data->update_lock); |
436 | if (data->kind == adt7461) | 452 | if (data->kind == adt7461) |
437 | data->temp11[nr] = temp_to_u16_adt7461(data, val); | 453 | data->temp11[nr] = temp_to_u16_adt7461(data, val); |
@@ -461,9 +477,15 @@ static ssize_t show_temphyst(struct device *dev, struct device_attribute *devatt | |||
461 | 477 | ||
462 | if (data->kind == adt7461) | 478 | if (data->kind == adt7461) |
463 | temp = temp_from_u8_adt7461(data, data->temp8[attr->index]); | 479 | temp = temp_from_u8_adt7461(data, data->temp8[attr->index]); |
480 | else if (data->kind == max6646) | ||
481 | temp = temp_from_u8(data->temp8[attr->index]); | ||
464 | else | 482 | else |
465 | temp = temp_from_s8(data->temp8[attr->index]); | 483 | temp = temp_from_s8(data->temp8[attr->index]); |
466 | 484 | ||
485 | /* +16 degrees offset for temp2 for the LM99 */ | ||
486 | if (data->kind == lm99 && attr->index == 3) | ||
487 | temp += 16000; | ||
488 | |||
467 | return sprintf(buf, "%d\n", temp - temp_from_s8(data->temp_hyst)); | 489 | return sprintf(buf, "%d\n", temp - temp_from_s8(data->temp_hyst)); |
468 | } | 490 | } |
469 | 491 | ||
@@ -473,12 +495,19 @@ static ssize_t set_temphyst(struct device *dev, struct device_attribute *dummy, | |||
473 | struct i2c_client *client = to_i2c_client(dev); | 495 | struct i2c_client *client = to_i2c_client(dev); |
474 | struct lm90_data *data = i2c_get_clientdata(client); | 496 | struct lm90_data *data = i2c_get_clientdata(client); |
475 | long val = simple_strtol(buf, NULL, 10); | 497 | long val = simple_strtol(buf, NULL, 10); |
476 | long hyst; | 498 | int temp; |
477 | 499 | ||
478 | mutex_lock(&data->update_lock); | 500 | mutex_lock(&data->update_lock); |
479 | hyst = temp_from_s8(data->temp8[2]) - val; | 501 | if (data->kind == adt7461) |
502 | temp = temp_from_u8_adt7461(data, data->temp8[2]); | ||
503 | else if (data->kind == max6646) | ||
504 | temp = temp_from_u8(data->temp8[2]); | ||
505 | else | ||
506 | temp = temp_from_s8(data->temp8[2]); | ||
507 | |||
508 | data->temp_hyst = hyst_to_reg(temp - val); | ||
480 | i2c_smbus_write_byte_data(client, LM90_REG_W_TCRIT_HYST, | 509 | i2c_smbus_write_byte_data(client, LM90_REG_W_TCRIT_HYST, |
481 | hyst_to_reg(hyst)); | 510 | data->temp_hyst); |
482 | mutex_unlock(&data->update_lock); | 511 | mutex_unlock(&data->update_lock); |
483 | return count; | 512 | return count; |
484 | } | 513 | } |
@@ -682,6 +711,15 @@ static int lm90_detect(struct i2c_client *new_client, int kind, | |||
682 | } else | 711 | } else |
683 | if ((chip_id & 0xF0) == 0x30) { /* LM89/LM99 */ | 712 | if ((chip_id & 0xF0) == 0x30) { /* LM89/LM99 */ |
684 | kind = lm99; | 713 | kind = lm99; |
714 | dev_info(&adapter->dev, | ||
715 | "Assuming LM99 chip at " | ||
716 | "0x%02x\n", address); | ||
717 | dev_info(&adapter->dev, | ||
718 | "If it is an LM89, pass " | ||
719 | "force_lm86=%d,0x%02x when " | ||
720 | "loading the lm90 driver\n", | ||
721 | i2c_adapter_id(adapter), | ||
722 | address); | ||
685 | } else | 723 | } else |
686 | if (address == 0x4C | 724 | if (address == 0x4C |
687 | && (chip_id & 0xF0) == 0x10) { /* LM86 */ | 725 | && (chip_id & 0xF0) == 0x10) { /* LM86 */ |
diff --git a/drivers/hwmon/w83781d.c b/drivers/hwmon/w83781d.c index d4d1b859d4f1..fc12bd412e3a 100644 --- a/drivers/hwmon/w83781d.c +++ b/drivers/hwmon/w83781d.c | |||
@@ -1968,7 +1968,7 @@ exit: | |||
1968 | return res; | 1968 | return res; |
1969 | } | 1969 | } |
1970 | 1970 | ||
1971 | static void __exit | 1971 | static void |
1972 | w83781d_isa_unregister(void) | 1972 | w83781d_isa_unregister(void) |
1973 | { | 1973 | { |
1974 | if (pdev) { | 1974 | if (pdev) { |
@@ -2017,7 +2017,7 @@ w83781d_isa_register(void) | |||
2017 | return 0; | 2017 | return 0; |
2018 | } | 2018 | } |
2019 | 2019 | ||
2020 | static void __exit | 2020 | static void |
2021 | w83781d_isa_unregister(void) | 2021 | w83781d_isa_unregister(void) |
2022 | { | 2022 | { |
2023 | } | 2023 | } |
diff --git a/drivers/ide/Kconfig b/drivers/ide/Kconfig index a820ca6fc327..6d7401772a8f 100644 --- a/drivers/ide/Kconfig +++ b/drivers/ide/Kconfig | |||
@@ -720,6 +720,16 @@ config BLK_DEV_IDE_AU1XXX_SEQTS_PER_RQ | |||
720 | default "128" | 720 | default "128" |
721 | depends on BLK_DEV_IDE_AU1XXX | 721 | depends on BLK_DEV_IDE_AU1XXX |
722 | 722 | ||
723 | config BLK_DEV_IDE_TX4938 | ||
724 | tristate "TX4938 internal IDE support" | ||
725 | depends on SOC_TX4938 | ||
726 | select IDE_TIMINGS | ||
727 | |||
728 | config BLK_DEV_IDE_TX4939 | ||
729 | tristate "TX4939 internal IDE support" | ||
730 | depends on SOC_TX4939 | ||
731 | select BLK_DEV_IDEDMA_SFF | ||
732 | |||
723 | config IDE_ARM | 733 | config IDE_ARM |
724 | tristate "ARM IDE support" | 734 | tristate "ARM IDE support" |
725 | depends on ARM && (ARCH_CLPS7500 || ARCH_RPC || ARCH_SHARK) | 735 | depends on ARM && (ARCH_CLPS7500 || ARCH_RPC || ARCH_SHARK) |
diff --git a/drivers/ide/Makefile b/drivers/ide/Makefile index 9cf92ac939d2..7818d402b188 100644 --- a/drivers/ide/Makefile +++ b/drivers/ide/Makefile | |||
@@ -68,7 +68,6 @@ obj-$(CONFIG_BLK_DEV_VIA82CXXX) += via82cxxx.o | |||
68 | 68 | ||
69 | # Must appear at the end of the block | 69 | # Must appear at the end of the block |
70 | obj-$(CONFIG_BLK_DEV_GENERIC) += ide-pci-generic.o | 70 | obj-$(CONFIG_BLK_DEV_GENERIC) += ide-pci-generic.o |
71 | ide-pci-generic-y += generic.o | ||
72 | 71 | ||
73 | obj-$(CONFIG_IDEPCI_PCIBUS_ORDER) += ide-scan-pci.o | 72 | obj-$(CONFIG_IDEPCI_PCIBUS_ORDER) += ide-scan-pci.o |
74 | 73 | ||
@@ -111,3 +110,6 @@ obj-$(CONFIG_BLK_DEV_IDE_RAPIDE) += rapide.o | |||
111 | obj-$(CONFIG_BLK_DEV_PALMCHIP_BK3710) += palm_bk3710.o | 110 | obj-$(CONFIG_BLK_DEV_PALMCHIP_BK3710) += palm_bk3710.o |
112 | 111 | ||
113 | obj-$(CONFIG_BLK_DEV_IDE_AU1XXX) += au1xxx-ide.o | 112 | obj-$(CONFIG_BLK_DEV_IDE_AU1XXX) += au1xxx-ide.o |
113 | |||
114 | obj-$(CONFIG_BLK_DEV_IDE_TX4938) += tx4938ide.o | ||
115 | obj-$(CONFIG_BLK_DEV_IDE_TX4939) += tx4939ide.o | ||
diff --git a/drivers/ide/icside.c b/drivers/ide/icside.c index 76bdc9a27f6f..2d848010499d 100644 --- a/drivers/ide/icside.c +++ b/drivers/ide/icside.c | |||
@@ -690,9 +690,9 @@ static int __init icside_init(void) | |||
690 | return ecard_register_driver(&icside_driver); | 690 | return ecard_register_driver(&icside_driver); |
691 | } | 691 | } |
692 | 692 | ||
693 | static void __exit icside_exit(void); | 693 | static void __exit icside_exit(void) |
694 | { | 694 | { |
695 | ecard_unregister_driver(&icside_driver); | 695 | ecard_remove_driver(&icside_driver); |
696 | } | 696 | } |
697 | 697 | ||
698 | MODULE_AUTHOR("Russell King <rmk@arm.linux.org.uk>"); | 698 | MODULE_AUTHOR("Russell King <rmk@arm.linux.org.uk>"); |
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c index 133afd09843c..48b5eda3ab41 100644 --- a/drivers/ide/ide-cd.c +++ b/drivers/ide/ide-cd.c | |||
@@ -1966,6 +1966,7 @@ static const struct cd_list_entry ide_cd_quirks_list[] = { | |||
1966 | { "Optiarc DVD RW AD-5200A", NULL, IDE_AFLAG_PLAY_AUDIO_OK }, | 1966 | { "Optiarc DVD RW AD-5200A", NULL, IDE_AFLAG_PLAY_AUDIO_OK }, |
1967 | { "Optiarc DVD RW AD-7200A", NULL, IDE_AFLAG_PLAY_AUDIO_OK }, | 1967 | { "Optiarc DVD RW AD-7200A", NULL, IDE_AFLAG_PLAY_AUDIO_OK }, |
1968 | { "Optiarc DVD RW AD-7543A", NULL, IDE_AFLAG_NO_AUTOCLOSE }, | 1968 | { "Optiarc DVD RW AD-7543A", NULL, IDE_AFLAG_NO_AUTOCLOSE }, |
1969 | { "TEAC CD-ROM CD-224E", NULL, IDE_AFLAG_NO_AUTOCLOSE }, | ||
1969 | { NULL, NULL, 0 } | 1970 | { NULL, NULL, 0 } |
1970 | }; | 1971 | }; |
1971 | 1972 | ||
diff --git a/drivers/ide/ide-disk.c b/drivers/ide/ide-disk.c index 223750c1b5a6..e5adebe8ac2c 100644 --- a/drivers/ide/ide-disk.c +++ b/drivers/ide/ide-disk.c | |||
@@ -600,6 +600,7 @@ static int ide_disk_check(ide_drive_t *drive, const char *s) | |||
600 | static void ide_disk_setup(ide_drive_t *drive) | 600 | static void ide_disk_setup(ide_drive_t *drive) |
601 | { | 601 | { |
602 | struct ide_disk_obj *idkp = drive->driver_data; | 602 | struct ide_disk_obj *idkp = drive->driver_data; |
603 | struct request_queue *q = drive->queue; | ||
603 | ide_hwif_t *hwif = drive->hwif; | 604 | ide_hwif_t *hwif = drive->hwif; |
604 | u16 *id = drive->id; | 605 | u16 *id = drive->id; |
605 | char *m = (char *)&id[ATA_ID_PROD]; | 606 | char *m = (char *)&id[ATA_ID_PROD]; |
@@ -626,11 +627,14 @@ static void ide_disk_setup(ide_drive_t *drive) | |||
626 | if (max_s > hwif->rqsize) | 627 | if (max_s > hwif->rqsize) |
627 | max_s = hwif->rqsize; | 628 | max_s = hwif->rqsize; |
628 | 629 | ||
629 | blk_queue_max_sectors(drive->queue, max_s); | 630 | blk_queue_max_sectors(q, max_s); |
630 | } | 631 | } |
631 | 632 | ||
632 | printk(KERN_INFO "%s: max request size: %dKiB\n", drive->name, | 633 | printk(KERN_INFO "%s: max request size: %dKiB\n", drive->name, |
633 | drive->queue->max_sectors / 2); | 634 | q->max_sectors / 2); |
635 | |||
636 | if (ata_id_is_ssd(id) || ata_id_is_cfa(id)) | ||
637 | queue_flag_set_unlocked(QUEUE_FLAG_NONROT, q); | ||
634 | 638 | ||
635 | /* calculate drive capacity, and select LBA if possible */ | 639 | /* calculate drive capacity, and select LBA if possible */ |
636 | ide_disk_get_capacity(drive); | 640 | ide_disk_get_capacity(drive); |
diff --git a/drivers/ide/generic.c b/drivers/ide/ide-pci-generic.c index 474f96a7c076..474f96a7c076 100644 --- a/drivers/ide/generic.c +++ b/drivers/ide/ide-pci-generic.c | |||
diff --git a/drivers/ide/rapide.c b/drivers/ide/rapide.c index 78d27d9ae430..d5003ca69801 100644 --- a/drivers/ide/rapide.c +++ b/drivers/ide/rapide.c | |||
@@ -11,7 +11,7 @@ | |||
11 | 11 | ||
12 | #include <asm/ecard.h> | 12 | #include <asm/ecard.h> |
13 | 13 | ||
14 | static struct const ide_port_info rapide_port_info = { | 14 | static const struct ide_port_info rapide_port_info = { |
15 | .host_flags = IDE_HFLAG_MMIO | IDE_HFLAG_NO_DMA, | 15 | .host_flags = IDE_HFLAG_MMIO | IDE_HFLAG_NO_DMA, |
16 | }; | 16 | }; |
17 | 17 | ||
@@ -97,7 +97,7 @@ static int __init rapide_init(void) | |||
97 | 97 | ||
98 | static void __exit rapide_exit(void) | 98 | static void __exit rapide_exit(void) |
99 | { | 99 | { |
100 | ecard_unregister_driver(&rapide_driver); | 100 | ecard_remove_driver(&rapide_driver); |
101 | } | 101 | } |
102 | 102 | ||
103 | MODULE_LICENSE("GPL"); | 103 | MODULE_LICENSE("GPL"); |
diff --git a/drivers/ide/scc_pata.c b/drivers/ide/scc_pata.c index 49f163aa51e3..f26aa5d54efb 100644 --- a/drivers/ide/scc_pata.c +++ b/drivers/ide/scc_pata.c | |||
@@ -536,10 +536,6 @@ static u8 scc_udma_filter(ide_drive_t *drive) | |||
536 | 536 | ||
537 | static int setup_mmio_scc (struct pci_dev *dev, const char *name) | 537 | static int setup_mmio_scc (struct pci_dev *dev, const char *name) |
538 | { | 538 | { |
539 | unsigned long ctl_base = pci_resource_start(dev, 0); | ||
540 | unsigned long dma_base = pci_resource_start(dev, 1); | ||
541 | unsigned long ctl_size = pci_resource_len(dev, 0); | ||
542 | unsigned long dma_size = pci_resource_len(dev, 1); | ||
543 | void __iomem *ctl_addr; | 539 | void __iomem *ctl_addr; |
544 | void __iomem *dma_addr; | 540 | void __iomem *dma_addr; |
545 | int i, ret; | 541 | int i, ret; |
@@ -557,10 +553,12 @@ static int setup_mmio_scc (struct pci_dev *dev, const char *name) | |||
557 | return ret; | 553 | return ret; |
558 | } | 554 | } |
559 | 555 | ||
560 | if ((ctl_addr = ioremap(ctl_base, ctl_size)) == NULL) | 556 | ctl_addr = pci_ioremap_bar(dev, 0); |
557 | if (!ctl_addr) | ||
561 | goto fail_0; | 558 | goto fail_0; |
562 | 559 | ||
563 | if ((dma_addr = ioremap(dma_base, dma_size)) == NULL) | 560 | dma_addr = pci_ioremap_bar(dev, 1); |
561 | if (!dma_addr) | ||
564 | goto fail_1; | 562 | goto fail_1; |
565 | 563 | ||
566 | pci_set_master(dev); | 564 | pci_set_master(dev); |
diff --git a/drivers/ide/sgiioc4.c b/drivers/ide/sgiioc4.c index 8af9b23499fd..7defa0ae2014 100644 --- a/drivers/ide/sgiioc4.c +++ b/drivers/ide/sgiioc4.c | |||
@@ -567,14 +567,12 @@ sgiioc4_ide_setup_pci_device(struct pci_dev *dev) | |||
567 | unsigned long cmd_base, irqport; | 567 | unsigned long cmd_base, irqport; |
568 | unsigned long bar0, cmd_phys_base, ctl; | 568 | unsigned long bar0, cmd_phys_base, ctl; |
569 | void __iomem *virt_base; | 569 | void __iomem *virt_base; |
570 | struct ide_host *host; | ||
571 | hw_regs_t hw, *hws[] = { &hw, NULL, NULL, NULL }; | 570 | hw_regs_t hw, *hws[] = { &hw, NULL, NULL, NULL }; |
572 | struct ide_port_info d = sgiioc4_port_info; | ||
573 | int rc; | 571 | int rc; |
574 | 572 | ||
575 | /* Get the CmdBlk and CtrlBlk Base Registers */ | 573 | /* Get the CmdBlk and CtrlBlk Base Registers */ |
576 | bar0 = pci_resource_start(dev, 0); | 574 | bar0 = pci_resource_start(dev, 0); |
577 | virt_base = ioremap(bar0, pci_resource_len(dev, 0)); | 575 | virt_base = pci_ioremap_bar(dev, 0); |
578 | if (virt_base == NULL) { | 576 | if (virt_base == NULL) { |
579 | printk(KERN_ERR "%s: Unable to remap BAR 0 address: 0x%lx\n", | 577 | printk(KERN_ERR "%s: Unable to remap BAR 0 address: 0x%lx\n", |
580 | DRV_NAME, bar0); | 578 | DRV_NAME, bar0); |
@@ -590,7 +588,8 @@ sgiioc4_ide_setup_pci_device(struct pci_dev *dev) | |||
590 | printk(KERN_ERR "%s %s -- ERROR: addresses 0x%08lx to 0x%08lx " | 588 | printk(KERN_ERR "%s %s -- ERROR: addresses 0x%08lx to 0x%08lx " |
591 | "already in use\n", DRV_NAME, pci_name(dev), | 589 | "already in use\n", DRV_NAME, pci_name(dev), |
592 | cmd_phys_base, cmd_phys_base + IOC4_CMD_CTL_BLK_SIZE); | 590 | cmd_phys_base, cmd_phys_base + IOC4_CMD_CTL_BLK_SIZE); |
593 | return -EBUSY; | 591 | rc = -EBUSY; |
592 | goto req_mem_rgn_err; | ||
594 | } | 593 | } |
595 | 594 | ||
596 | /* Initialize the IO registers */ | 595 | /* Initialize the IO registers */ |
@@ -603,21 +602,12 @@ sgiioc4_ide_setup_pci_device(struct pci_dev *dev) | |||
603 | /* Initializing chipset IRQ Registers */ | 602 | /* Initializing chipset IRQ Registers */ |
604 | writel(0x03, (void __iomem *)(irqport + IOC4_INTR_SET * 4)); | 603 | writel(0x03, (void __iomem *)(irqport + IOC4_INTR_SET * 4)); |
605 | 604 | ||
606 | host = ide_host_alloc(&d, hws); | 605 | rc = ide_host_add(&sgiioc4_port_info, hws, NULL); |
607 | if (host == NULL) { | 606 | if (!rc) |
608 | rc = -ENOMEM; | 607 | return 0; |
609 | goto err; | ||
610 | } | ||
611 | |||
612 | rc = ide_host_register(host, &d, hws); | ||
613 | if (rc) | ||
614 | goto err_free; | ||
615 | 608 | ||
616 | return 0; | ||
617 | err_free: | ||
618 | ide_host_free(host); | ||
619 | err: | ||
620 | release_mem_region(cmd_phys_base, IOC4_CMD_CTL_BLK_SIZE); | 609 | release_mem_region(cmd_phys_base, IOC4_CMD_CTL_BLK_SIZE); |
610 | req_mem_rgn_err: | ||
621 | iounmap(virt_base); | 611 | iounmap(virt_base); |
622 | return rc; | 612 | return rc; |
623 | } | 613 | } |
diff --git a/drivers/ide/siimage.c b/drivers/ide/siimage.c index eb4faf92c571..c3107df7773d 100644 --- a/drivers/ide/siimage.c +++ b/drivers/ide/siimage.c | |||
@@ -784,7 +784,7 @@ static int __devinit siimage_init_one(struct pci_dev *dev, | |||
784 | printk(KERN_WARNING DRV_NAME " %s: MMIO ports not " | 784 | printk(KERN_WARNING DRV_NAME " %s: MMIO ports not " |
785 | "available\n", pci_name(dev)); | 785 | "available\n", pci_name(dev)); |
786 | } else { | 786 | } else { |
787 | ioaddr = ioremap(bar5, barsize); | 787 | ioaddr = pci_ioremap_bar(dev, 5); |
788 | if (ioaddr == NULL) | 788 | if (ioaddr == NULL) |
789 | release_mem_region(bar5, barsize); | 789 | release_mem_region(bar5, barsize); |
790 | } | 790 | } |
diff --git a/drivers/ide/tx4938ide.c b/drivers/ide/tx4938ide.c new file mode 100644 index 000000000000..fa660f931a11 --- /dev/null +++ b/drivers/ide/tx4938ide.c | |||
@@ -0,0 +1,310 @@ | |||
1 | /* | ||
2 | * TX4938 internal IDE driver | ||
3 | * Based on tx4939ide.c. | ||
4 | * | ||
5 | * This file is subject to the terms and conditions of the GNU General Public | ||
6 | * License. See the file "COPYING" in the main directory of this archive | ||
7 | * for more details. | ||
8 | * | ||
9 | * (C) Copyright TOSHIBA CORPORATION 2005-2007 | ||
10 | */ | ||
11 | |||
12 | #include <linux/module.h> | ||
13 | #include <linux/types.h> | ||
14 | #include <linux/ide.h> | ||
15 | #include <linux/init.h> | ||
16 | #include <linux/platform_device.h> | ||
17 | #include <linux/io.h> | ||
18 | #include <asm/txx9/tx4938.h> | ||
19 | |||
20 | static void tx4938ide_tune_ebusc(unsigned int ebus_ch, | ||
21 | unsigned int gbus_clock, | ||
22 | u8 pio) | ||
23 | { | ||
24 | struct ide_timing *t = ide_timing_find_mode(XFER_PIO_0 + pio); | ||
25 | u64 cr = __raw_readq(&tx4938_ebuscptr->cr[ebus_ch]); | ||
26 | unsigned int sp = (cr >> 4) & 3; | ||
27 | unsigned int clock = gbus_clock / (4 - sp); | ||
28 | unsigned int cycle = 1000000000 / clock; | ||
29 | unsigned int wt, shwt; | ||
30 | |||
31 | /* Minimum DIOx- active time */ | ||
32 | wt = DIV_ROUND_UP(t->act8b, cycle) - 2; | ||
33 | /* IORDY setup time: 35ns */ | ||
34 | wt = max(wt, DIV_ROUND_UP(35, cycle)); | ||
35 | /* actual wait-cycle is max(wt & ~1, 1) */ | ||
36 | if (wt > 2 && (wt & 1)) | ||
37 | wt++; | ||
38 | wt &= ~1; | ||
39 | /* Address-valid to DIOR/DIOW setup */ | ||
40 | shwt = DIV_ROUND_UP(t->setup, cycle); | ||
41 | |||
42 | pr_debug("tx4938ide: ebus %d, bus cycle %dns, WT %d, SHWT %d\n", | ||
43 | ebus_ch, cycle, wt, shwt); | ||
44 | |||
45 | __raw_writeq((cr & ~(0x3f007ull)) | (wt << 12) | shwt, | ||
46 | &tx4938_ebuscptr->cr[ebus_ch]); | ||
47 | } | ||
48 | |||
49 | static void tx4938ide_set_pio_mode(ide_drive_t *drive, const u8 pio) | ||
50 | { | ||
51 | ide_hwif_t *hwif = drive->hwif; | ||
52 | struct tx4938ide_platform_info *pdata = hwif->dev->platform_data; | ||
53 | u8 safe = pio; | ||
54 | ide_drive_t *pair; | ||
55 | |||
56 | pair = ide_get_pair_dev(drive); | ||
57 | if (pair) | ||
58 | safe = min(safe, ide_get_best_pio_mode(pair, 255, 5)); | ||
59 | tx4938ide_tune_ebusc(pdata->ebus_ch, pdata->gbus_clock, safe); | ||
60 | } | ||
61 | |||
62 | #ifdef __BIG_ENDIAN | ||
63 | |||
64 | /* custom iops (independent from SWAP_IO_SPACE) */ | ||
65 | static u8 tx4938ide_inb(unsigned long port) | ||
66 | { | ||
67 | return __raw_readb((void __iomem *)port); | ||
68 | } | ||
69 | |||
70 | static void tx4938ide_outb(u8 value, unsigned long port) | ||
71 | { | ||
72 | __raw_writeb(value, (void __iomem *)port); | ||
73 | } | ||
74 | |||
75 | static void tx4938ide_tf_load(ide_drive_t *drive, ide_task_t *task) | ||
76 | { | ||
77 | ide_hwif_t *hwif = drive->hwif; | ||
78 | struct ide_io_ports *io_ports = &hwif->io_ports; | ||
79 | struct ide_taskfile *tf = &task->tf; | ||
80 | u8 HIHI = task->tf_flags & IDE_TFLAG_LBA48 ? 0xE0 : 0xEF; | ||
81 | |||
82 | if (task->tf_flags & IDE_TFLAG_FLAGGED) | ||
83 | HIHI = 0xFF; | ||
84 | |||
85 | if (task->tf_flags & IDE_TFLAG_OUT_DATA) { | ||
86 | u16 data = (tf->hob_data << 8) | tf->data; | ||
87 | |||
88 | /* no endian swap */ | ||
89 | __raw_writew(data, (void __iomem *)io_ports->data_addr); | ||
90 | } | ||
91 | |||
92 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_FEATURE) | ||
93 | tx4938ide_outb(tf->hob_feature, io_ports->feature_addr); | ||
94 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_NSECT) | ||
95 | tx4938ide_outb(tf->hob_nsect, io_ports->nsect_addr); | ||
96 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAL) | ||
97 | tx4938ide_outb(tf->hob_lbal, io_ports->lbal_addr); | ||
98 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAM) | ||
99 | tx4938ide_outb(tf->hob_lbam, io_ports->lbam_addr); | ||
100 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAH) | ||
101 | tx4938ide_outb(tf->hob_lbah, io_ports->lbah_addr); | ||
102 | |||
103 | if (task->tf_flags & IDE_TFLAG_OUT_FEATURE) | ||
104 | tx4938ide_outb(tf->feature, io_ports->feature_addr); | ||
105 | if (task->tf_flags & IDE_TFLAG_OUT_NSECT) | ||
106 | tx4938ide_outb(tf->nsect, io_ports->nsect_addr); | ||
107 | if (task->tf_flags & IDE_TFLAG_OUT_LBAL) | ||
108 | tx4938ide_outb(tf->lbal, io_ports->lbal_addr); | ||
109 | if (task->tf_flags & IDE_TFLAG_OUT_LBAM) | ||
110 | tx4938ide_outb(tf->lbam, io_ports->lbam_addr); | ||
111 | if (task->tf_flags & IDE_TFLAG_OUT_LBAH) | ||
112 | tx4938ide_outb(tf->lbah, io_ports->lbah_addr); | ||
113 | |||
114 | if (task->tf_flags & IDE_TFLAG_OUT_DEVICE) | ||
115 | tx4938ide_outb((tf->device & HIHI) | drive->select, | ||
116 | io_ports->device_addr); | ||
117 | } | ||
118 | |||
119 | static void tx4938ide_tf_read(ide_drive_t *drive, ide_task_t *task) | ||
120 | { | ||
121 | ide_hwif_t *hwif = drive->hwif; | ||
122 | struct ide_io_ports *io_ports = &hwif->io_ports; | ||
123 | struct ide_taskfile *tf = &task->tf; | ||
124 | |||
125 | if (task->tf_flags & IDE_TFLAG_IN_DATA) { | ||
126 | u16 data; | ||
127 | |||
128 | /* no endian swap */ | ||
129 | data = __raw_readw((void __iomem *)io_ports->data_addr); | ||
130 | tf->data = data & 0xff; | ||
131 | tf->hob_data = (data >> 8) & 0xff; | ||
132 | } | ||
133 | |||
134 | /* be sure we're looking at the low order bits */ | ||
135 | tx4938ide_outb(ATA_DEVCTL_OBS & ~0x80, io_ports->ctl_addr); | ||
136 | |||
137 | if (task->tf_flags & IDE_TFLAG_IN_FEATURE) | ||
138 | tf->feature = tx4938ide_inb(io_ports->feature_addr); | ||
139 | if (task->tf_flags & IDE_TFLAG_IN_NSECT) | ||
140 | tf->nsect = tx4938ide_inb(io_ports->nsect_addr); | ||
141 | if (task->tf_flags & IDE_TFLAG_IN_LBAL) | ||
142 | tf->lbal = tx4938ide_inb(io_ports->lbal_addr); | ||
143 | if (task->tf_flags & IDE_TFLAG_IN_LBAM) | ||
144 | tf->lbam = tx4938ide_inb(io_ports->lbam_addr); | ||
145 | if (task->tf_flags & IDE_TFLAG_IN_LBAH) | ||
146 | tf->lbah = tx4938ide_inb(io_ports->lbah_addr); | ||
147 | if (task->tf_flags & IDE_TFLAG_IN_DEVICE) | ||
148 | tf->device = tx4938ide_inb(io_ports->device_addr); | ||
149 | |||
150 | if (task->tf_flags & IDE_TFLAG_LBA48) { | ||
151 | tx4938ide_outb(ATA_DEVCTL_OBS | 0x80, io_ports->ctl_addr); | ||
152 | |||
153 | if (task->tf_flags & IDE_TFLAG_IN_HOB_FEATURE) | ||
154 | tf->hob_feature = | ||
155 | tx4938ide_inb(io_ports->feature_addr); | ||
156 | if (task->tf_flags & IDE_TFLAG_IN_HOB_NSECT) | ||
157 | tf->hob_nsect = tx4938ide_inb(io_ports->nsect_addr); | ||
158 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAL) | ||
159 | tf->hob_lbal = tx4938ide_inb(io_ports->lbal_addr); | ||
160 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAM) | ||
161 | tf->hob_lbam = tx4938ide_inb(io_ports->lbam_addr); | ||
162 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAH) | ||
163 | tf->hob_lbah = tx4938ide_inb(io_ports->lbah_addr); | ||
164 | } | ||
165 | } | ||
166 | |||
167 | static void tx4938ide_input_data_swap(ide_drive_t *drive, struct request *rq, | ||
168 | void *buf, unsigned int len) | ||
169 | { | ||
170 | unsigned long port = drive->hwif->io_ports.data_addr; | ||
171 | unsigned short *ptr = buf; | ||
172 | unsigned int count = (len + 1) / 2; | ||
173 | |||
174 | while (count--) | ||
175 | *ptr++ = cpu_to_le16(__raw_readw((void __iomem *)port)); | ||
176 | __ide_flush_dcache_range((unsigned long)buf, count * 2); | ||
177 | } | ||
178 | |||
179 | static void tx4938ide_output_data_swap(ide_drive_t *drive, struct request *rq, | ||
180 | void *buf, unsigned int len) | ||
181 | { | ||
182 | unsigned long port = drive->hwif->io_ports.data_addr; | ||
183 | unsigned short *ptr = buf; | ||
184 | unsigned int count = (len + 1) / 2; | ||
185 | |||
186 | while (count--) { | ||
187 | __raw_writew(le16_to_cpu(*ptr), (void __iomem *)port); | ||
188 | ptr++; | ||
189 | } | ||
190 | __ide_flush_dcache_range((unsigned long)buf, count * 2); | ||
191 | } | ||
192 | |||
193 | static const struct ide_tp_ops tx4938ide_tp_ops = { | ||
194 | .exec_command = ide_exec_command, | ||
195 | .read_status = ide_read_status, | ||
196 | .read_altstatus = ide_read_altstatus, | ||
197 | .read_sff_dma_status = ide_read_sff_dma_status, | ||
198 | |||
199 | .set_irq = ide_set_irq, | ||
200 | |||
201 | .tf_load = tx4938ide_tf_load, | ||
202 | .tf_read = tx4938ide_tf_read, | ||
203 | |||
204 | .input_data = tx4938ide_input_data_swap, | ||
205 | .output_data = tx4938ide_output_data_swap, | ||
206 | }; | ||
207 | |||
208 | #endif /* __BIG_ENDIAN */ | ||
209 | |||
210 | static const struct ide_port_ops tx4938ide_port_ops = { | ||
211 | .set_pio_mode = tx4938ide_set_pio_mode, | ||
212 | }; | ||
213 | |||
214 | static const struct ide_port_info tx4938ide_port_info __initdata = { | ||
215 | .port_ops = &tx4938ide_port_ops, | ||
216 | #ifdef __BIG_ENDIAN | ||
217 | .tp_ops = &tx4938ide_tp_ops, | ||
218 | #endif | ||
219 | .host_flags = IDE_HFLAG_MMIO | IDE_HFLAG_NO_DMA, | ||
220 | .pio_mask = ATA_PIO5, | ||
221 | }; | ||
222 | |||
223 | static int __init tx4938ide_probe(struct platform_device *pdev) | ||
224 | { | ||
225 | hw_regs_t hw; | ||
226 | hw_regs_t *hws[] = { &hw, NULL, NULL, NULL }; | ||
227 | struct ide_host *host; | ||
228 | struct resource *res; | ||
229 | struct tx4938ide_platform_info *pdata = pdev->dev.platform_data; | ||
230 | int irq, ret, i; | ||
231 | unsigned long mapbase; | ||
232 | struct ide_port_info d = tx4938ide_port_info; | ||
233 | |||
234 | irq = platform_get_irq(pdev, 0); | ||
235 | if (irq < 0) | ||
236 | return -ENODEV; | ||
237 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | ||
238 | if (!res) | ||
239 | return -ENODEV; | ||
240 | |||
241 | if (!devm_request_mem_region(&pdev->dev, res->start, | ||
242 | res->end - res->start + 1, "tx4938ide")) | ||
243 | return -EBUSY; | ||
244 | mapbase = (unsigned long)devm_ioremap(&pdev->dev, res->start, | ||
245 | res->end - res->start + 1); | ||
246 | if (!mapbase) | ||
247 | return -EBUSY; | ||
248 | |||
249 | memset(&hw, 0, sizeof(hw)); | ||
250 | if (pdata->ioport_shift) { | ||
251 | unsigned long port = mapbase; | ||
252 | |||
253 | hw.io_ports_array[0] = port; | ||
254 | #ifdef __BIG_ENDIAN | ||
255 | port++; | ||
256 | #endif | ||
257 | for (i = 1; i <= 7; i++) | ||
258 | hw.io_ports_array[i] = | ||
259 | port + (i << pdata->ioport_shift); | ||
260 | hw.io_ports.ctl_addr = | ||
261 | port + 0x10000 + (6 << pdata->ioport_shift); | ||
262 | } else | ||
263 | ide_std_init_ports(&hw, mapbase, mapbase + 0x10006); | ||
264 | hw.irq = irq; | ||
265 | hw.dev = &pdev->dev; | ||
266 | |||
267 | pr_info("TX4938 IDE interface (base %#lx, irq %d)\n", mapbase, hw.irq); | ||
268 | if (pdata->gbus_clock) | ||
269 | tx4938ide_tune_ebusc(pdata->ebus_ch, pdata->gbus_clock, 0); | ||
270 | else | ||
271 | d.port_ops = NULL; | ||
272 | ret = ide_host_add(&d, hws, &host); | ||
273 | if (ret) | ||
274 | return ret; | ||
275 | platform_set_drvdata(pdev, host); | ||
276 | return 0; | ||
277 | } | ||
278 | |||
279 | static int __exit tx4938ide_remove(struct platform_device *pdev) | ||
280 | { | ||
281 | struct ide_host *host = platform_get_drvdata(pdev); | ||
282 | |||
283 | ide_host_remove(host); | ||
284 | return 0; | ||
285 | } | ||
286 | |||
287 | static struct platform_driver tx4938ide_driver = { | ||
288 | .driver = { | ||
289 | .name = "tx4938ide", | ||
290 | .owner = THIS_MODULE, | ||
291 | }, | ||
292 | .remove = __exit_p(tx4938ide_remove), | ||
293 | }; | ||
294 | |||
295 | static int __init tx4938ide_init(void) | ||
296 | { | ||
297 | return platform_driver_probe(&tx4938ide_driver, tx4938ide_probe); | ||
298 | } | ||
299 | |||
300 | static void __exit tx4938ide_exit(void) | ||
301 | { | ||
302 | platform_driver_unregister(&tx4938ide_driver); | ||
303 | } | ||
304 | |||
305 | module_init(tx4938ide_init); | ||
306 | module_exit(tx4938ide_exit); | ||
307 | |||
308 | MODULE_DESCRIPTION("TX4938 internal IDE driver"); | ||
309 | MODULE_LICENSE("GPL"); | ||
310 | MODULE_ALIAS("platform:tx4938ide"); | ||
diff --git a/drivers/ide/tx4939ide.c b/drivers/ide/tx4939ide.c new file mode 100644 index 000000000000..bafb7d1a22e2 --- /dev/null +++ b/drivers/ide/tx4939ide.c | |||
@@ -0,0 +1,754 @@ | |||
1 | /* | ||
2 | * TX4939 internal IDE driver | ||
3 | * Based on RBTX49xx patch from CELF patch archive. | ||
4 | * | ||
5 | * This file is subject to the terms and conditions of the GNU General Public | ||
6 | * License. See the file "COPYING" in the main directory of this archive | ||
7 | * for more details. | ||
8 | * | ||
9 | * (C) Copyright TOSHIBA CORPORATION 2005-2007 | ||
10 | */ | ||
11 | |||
12 | #include <linux/module.h> | ||
13 | #include <linux/types.h> | ||
14 | #include <linux/ide.h> | ||
15 | #include <linux/init.h> | ||
16 | #include <linux/delay.h> | ||
17 | #include <linux/platform_device.h> | ||
18 | #include <linux/io.h> | ||
19 | #include <linux/scatterlist.h> | ||
20 | |||
21 | #define MODNAME "tx4939ide" | ||
22 | |||
23 | /* ATA Shadow Registers (8-bit except for Data which is 16-bit) */ | ||
24 | #define TX4939IDE_Data 0x000 | ||
25 | #define TX4939IDE_Error_Feature 0x001 | ||
26 | #define TX4939IDE_Sec 0x002 | ||
27 | #define TX4939IDE_LBA0 0x003 | ||
28 | #define TX4939IDE_LBA1 0x004 | ||
29 | #define TX4939IDE_LBA2 0x005 | ||
30 | #define TX4939IDE_DevHead 0x006 | ||
31 | #define TX4939IDE_Stat_Cmd 0x007 | ||
32 | #define TX4939IDE_AltStat_DevCtl 0x402 | ||
33 | /* H/W DMA Registers */ | ||
34 | #define TX4939IDE_DMA_Cmd 0x800 /* 8-bit */ | ||
35 | #define TX4939IDE_DMA_Stat 0x802 /* 8-bit */ | ||
36 | #define TX4939IDE_PRD_Ptr 0x804 /* 32-bit */ | ||
37 | /* ATA100 CORE Registers (16-bit) */ | ||
38 | #define TX4939IDE_Sys_Ctl 0xc00 | ||
39 | #define TX4939IDE_Xfer_Cnt_1 0xc08 | ||
40 | #define TX4939IDE_Xfer_Cnt_2 0xc0a | ||
41 | #define TX4939IDE_Sec_Cnt 0xc10 | ||
42 | #define TX4939IDE_Start_Lo_Addr 0xc18 | ||
43 | #define TX4939IDE_Start_Up_Addr 0xc20 | ||
44 | #define TX4939IDE_Add_Ctl 0xc28 | ||
45 | #define TX4939IDE_Lo_Burst_Cnt 0xc30 | ||
46 | #define TX4939IDE_Up_Burst_Cnt 0xc38 | ||
47 | #define TX4939IDE_PIO_Addr 0xc88 | ||
48 | #define TX4939IDE_H_Rst_Tim 0xc90 | ||
49 | #define TX4939IDE_Int_Ctl 0xc98 | ||
50 | #define TX4939IDE_Pkt_Cmd 0xcb8 | ||
51 | #define TX4939IDE_Bxfer_Cnt_Hi 0xcc0 | ||
52 | #define TX4939IDE_Bxfer_Cnt_Lo 0xcc8 | ||
53 | #define TX4939IDE_Dev_TErr 0xcd0 | ||
54 | #define TX4939IDE_Pkt_Xfer_Ctl 0xcd8 | ||
55 | #define TX4939IDE_Start_TAddr 0xce0 | ||
56 | |||
57 | /* bits for Int_Ctl */ | ||
58 | #define TX4939IDE_INT_ADDRERR 0x80 | ||
59 | #define TX4939IDE_INT_REACHMUL 0x40 | ||
60 | #define TX4939IDE_INT_DEVTIMING 0x20 | ||
61 | #define TX4939IDE_INT_UDMATERM 0x10 | ||
62 | #define TX4939IDE_INT_TIMER 0x08 | ||
63 | #define TX4939IDE_INT_BUSERR 0x04 | ||
64 | #define TX4939IDE_INT_XFEREND 0x02 | ||
65 | #define TX4939IDE_INT_HOST 0x01 | ||
66 | |||
67 | #define TX4939IDE_IGNORE_INTS \ | ||
68 | (TX4939IDE_INT_ADDRERR | TX4939IDE_INT_REACHMUL | \ | ||
69 | TX4939IDE_INT_DEVTIMING | TX4939IDE_INT_UDMATERM | \ | ||
70 | TX4939IDE_INT_TIMER | TX4939IDE_INT_XFEREND) | ||
71 | |||
72 | #ifdef __BIG_ENDIAN | ||
73 | #define tx4939ide_swizzlel(a) ((a) ^ 4) | ||
74 | #define tx4939ide_swizzlew(a) ((a) ^ 6) | ||
75 | #define tx4939ide_swizzleb(a) ((a) ^ 7) | ||
76 | #else | ||
77 | #define tx4939ide_swizzlel(a) (a) | ||
78 | #define tx4939ide_swizzlew(a) (a) | ||
79 | #define tx4939ide_swizzleb(a) (a) | ||
80 | #endif | ||
81 | |||
82 | static u16 tx4939ide_readw(void __iomem *base, u32 reg) | ||
83 | { | ||
84 | return __raw_readw(base + tx4939ide_swizzlew(reg)); | ||
85 | } | ||
86 | static u8 tx4939ide_readb(void __iomem *base, u32 reg) | ||
87 | { | ||
88 | return __raw_readb(base + tx4939ide_swizzleb(reg)); | ||
89 | } | ||
90 | static void tx4939ide_writel(u32 val, void __iomem *base, u32 reg) | ||
91 | { | ||
92 | __raw_writel(val, base + tx4939ide_swizzlel(reg)); | ||
93 | } | ||
94 | static void tx4939ide_writew(u16 val, void __iomem *base, u32 reg) | ||
95 | { | ||
96 | __raw_writew(val, base + tx4939ide_swizzlew(reg)); | ||
97 | } | ||
98 | static void tx4939ide_writeb(u8 val, void __iomem *base, u32 reg) | ||
99 | { | ||
100 | __raw_writeb(val, base + tx4939ide_swizzleb(reg)); | ||
101 | } | ||
102 | |||
103 | #define TX4939IDE_BASE(hwif) ((void __iomem *)(hwif)->extra_base) | ||
104 | |||
105 | static void tx4939ide_set_pio_mode(ide_drive_t *drive, const u8 pio) | ||
106 | { | ||
107 | ide_hwif_t *hwif = drive->hwif; | ||
108 | int is_slave = drive->dn; | ||
109 | u32 mask, val; | ||
110 | u8 safe = pio; | ||
111 | ide_drive_t *pair; | ||
112 | |||
113 | pair = ide_get_pair_dev(drive); | ||
114 | if (pair) | ||
115 | safe = min(safe, ide_get_best_pio_mode(pair, 255, 4)); | ||
116 | /* | ||
117 | * Update Command Transfer Mode for master/slave and Data | ||
118 | * Transfer Mode for this drive. | ||
119 | */ | ||
120 | mask = is_slave ? 0x07f00000 : 0x000007f0; | ||
121 | val = ((safe << 8) | (pio << 4)) << (is_slave ? 16 : 0); | ||
122 | hwif->select_data = (hwif->select_data & ~mask) | val; | ||
123 | /* tx4939ide_tf_load_fixup() will set the Sys_Ctl register */ | ||
124 | } | ||
125 | |||
126 | static void tx4939ide_set_dma_mode(ide_drive_t *drive, const u8 mode) | ||
127 | { | ||
128 | ide_hwif_t *hwif = drive->hwif; | ||
129 | u32 mask, val; | ||
130 | |||
131 | /* Update Data Transfer Mode for this drive. */ | ||
132 | if (mode >= XFER_UDMA_0) | ||
133 | val = mode - XFER_UDMA_0 + 8; | ||
134 | else | ||
135 | val = mode - XFER_MW_DMA_0 + 5; | ||
136 | if (drive->dn) { | ||
137 | mask = 0x00f00000; | ||
138 | val <<= 20; | ||
139 | } else { | ||
140 | mask = 0x000000f0; | ||
141 | val <<= 4; | ||
142 | } | ||
143 | hwif->select_data = (hwif->select_data & ~mask) | val; | ||
144 | /* tx4939ide_tf_load_fixup() will set the Sys_Ctl register */ | ||
145 | } | ||
146 | |||
147 | static u16 tx4939ide_check_error_ints(ide_hwif_t *hwif) | ||
148 | { | ||
149 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
150 | u16 ctl = tx4939ide_readw(base, TX4939IDE_Int_Ctl); | ||
151 | |||
152 | if (ctl & TX4939IDE_INT_BUSERR) { | ||
153 | /* reset FIFO */ | ||
154 | u16 sysctl = tx4939ide_readw(base, TX4939IDE_Sys_Ctl); | ||
155 | |||
156 | tx4939ide_writew(sysctl | 0x4000, base, TX4939IDE_Sys_Ctl); | ||
157 | mmiowb(); | ||
158 | /* wait 12GBUSCLK (typ. 60ns @ GBUS200MHz, max 270ns) */ | ||
159 | ndelay(270); | ||
160 | tx4939ide_writew(sysctl, base, TX4939IDE_Sys_Ctl); | ||
161 | } | ||
162 | if (ctl & (TX4939IDE_INT_ADDRERR | | ||
163 | TX4939IDE_INT_DEVTIMING | TX4939IDE_INT_BUSERR)) | ||
164 | pr_err("%s: Error interrupt %#x (%s%s%s )\n", | ||
165 | hwif->name, ctl, | ||
166 | ctl & TX4939IDE_INT_ADDRERR ? " Address-Error" : "", | ||
167 | ctl & TX4939IDE_INT_DEVTIMING ? " DEV-Timing" : "", | ||
168 | ctl & TX4939IDE_INT_BUSERR ? " Bus-Error" : ""); | ||
169 | return ctl; | ||
170 | } | ||
171 | |||
172 | static void tx4939ide_clear_irq(ide_drive_t *drive) | ||
173 | { | ||
174 | ide_hwif_t *hwif; | ||
175 | void __iomem *base; | ||
176 | u16 ctl; | ||
177 | |||
178 | /* | ||
179 | * tx4939ide_dma_test_irq() and tx4939ide_dma_end() do all job | ||
180 | * for DMA case. | ||
181 | */ | ||
182 | if (drive->waiting_for_dma) | ||
183 | return; | ||
184 | hwif = drive->hwif; | ||
185 | base = TX4939IDE_BASE(hwif); | ||
186 | ctl = tx4939ide_check_error_ints(hwif); | ||
187 | tx4939ide_writew(ctl, base, TX4939IDE_Int_Ctl); | ||
188 | } | ||
189 | |||
190 | static u8 tx4939ide_cable_detect(ide_hwif_t *hwif) | ||
191 | { | ||
192 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
193 | |||
194 | return tx4939ide_readw(base, TX4939IDE_Sys_Ctl) & 0x2000 ? | ||
195 | ATA_CBL_PATA40 : ATA_CBL_PATA80; | ||
196 | } | ||
197 | |||
198 | #ifdef __BIG_ENDIAN | ||
199 | static void tx4939ide_dma_host_set(ide_drive_t *drive, int on) | ||
200 | { | ||
201 | ide_hwif_t *hwif = drive->hwif; | ||
202 | u8 unit = drive->dn; | ||
203 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
204 | u8 dma_stat = tx4939ide_readb(base, TX4939IDE_DMA_Stat); | ||
205 | |||
206 | if (on) | ||
207 | dma_stat |= (1 << (5 + unit)); | ||
208 | else | ||
209 | dma_stat &= ~(1 << (5 + unit)); | ||
210 | |||
211 | tx4939ide_writeb(dma_stat, base, TX4939IDE_DMA_Stat); | ||
212 | } | ||
213 | #else | ||
214 | #define tx4939ide_dma_host_set ide_dma_host_set | ||
215 | #endif | ||
216 | |||
217 | static u8 tx4939ide_clear_dma_status(void __iomem *base) | ||
218 | { | ||
219 | u8 dma_stat; | ||
220 | |||
221 | /* read DMA status for INTR & ERROR flags */ | ||
222 | dma_stat = tx4939ide_readb(base, TX4939IDE_DMA_Stat); | ||
223 | /* clear INTR & ERROR flags */ | ||
224 | tx4939ide_writeb(dma_stat | ATA_DMA_INTR | ATA_DMA_ERR, base, | ||
225 | TX4939IDE_DMA_Stat); | ||
226 | /* recover intmask cleared by writing to bit2 of DMA_Stat */ | ||
227 | tx4939ide_writew(TX4939IDE_IGNORE_INTS << 8, base, TX4939IDE_Int_Ctl); | ||
228 | return dma_stat; | ||
229 | } | ||
230 | |||
231 | #ifdef __BIG_ENDIAN | ||
232 | /* custom ide_build_dmatable to handle swapped layout */ | ||
233 | static int tx4939ide_build_dmatable(ide_drive_t *drive, struct request *rq) | ||
234 | { | ||
235 | ide_hwif_t *hwif = drive->hwif; | ||
236 | u32 *table = (u32 *)hwif->dmatable_cpu; | ||
237 | unsigned int count = 0; | ||
238 | int i; | ||
239 | struct scatterlist *sg; | ||
240 | |||
241 | hwif->sg_nents = ide_build_sglist(drive, rq); | ||
242 | if (hwif->sg_nents == 0) | ||
243 | return 0; | ||
244 | |||
245 | for_each_sg(hwif->sg_table, sg, hwif->sg_nents, i) { | ||
246 | u32 cur_addr, cur_len, bcount; | ||
247 | |||
248 | cur_addr = sg_dma_address(sg); | ||
249 | cur_len = sg_dma_len(sg); | ||
250 | |||
251 | /* | ||
252 | * Fill in the DMA table, without crossing any 64kB boundaries. | ||
253 | */ | ||
254 | |||
255 | while (cur_len) { | ||
256 | if (count++ >= PRD_ENTRIES) | ||
257 | goto use_pio_instead; | ||
258 | |||
259 | bcount = 0x10000 - (cur_addr & 0xffff); | ||
260 | if (bcount > cur_len) | ||
261 | bcount = cur_len; | ||
262 | *table++ = bcount & 0xffff; | ||
263 | *table++ = cur_addr; | ||
264 | cur_addr += bcount; | ||
265 | cur_len -= bcount; | ||
266 | } | ||
267 | } | ||
268 | |||
269 | if (count) { | ||
270 | *(table - 2) |= 0x80000000; | ||
271 | return count; | ||
272 | } | ||
273 | |||
274 | use_pio_instead: | ||
275 | printk(KERN_ERR "%s: %s\n", drive->name, | ||
276 | count ? "DMA table too small" : "empty DMA table?"); | ||
277 | |||
278 | ide_destroy_dmatable(drive); | ||
279 | |||
280 | return 0; /* revert to PIO for this request */ | ||
281 | } | ||
282 | #else | ||
283 | #define tx4939ide_build_dmatable ide_build_dmatable | ||
284 | #endif | ||
285 | |||
286 | static int tx4939ide_dma_setup(ide_drive_t *drive) | ||
287 | { | ||
288 | ide_hwif_t *hwif = drive->hwif; | ||
289 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
290 | struct request *rq = hwif->hwgroup->rq; | ||
291 | u8 reading; | ||
292 | int nent; | ||
293 | |||
294 | if (rq_data_dir(rq)) | ||
295 | reading = 0; | ||
296 | else | ||
297 | reading = ATA_DMA_WR; | ||
298 | |||
299 | /* fall back to PIO! */ | ||
300 | nent = tx4939ide_build_dmatable(drive, rq); | ||
301 | if (!nent) { | ||
302 | ide_map_sg(drive, rq); | ||
303 | return 1; | ||
304 | } | ||
305 | |||
306 | /* PRD table */ | ||
307 | tx4939ide_writel(hwif->dmatable_dma, base, TX4939IDE_PRD_Ptr); | ||
308 | |||
309 | /* specify r/w */ | ||
310 | tx4939ide_writeb(reading, base, TX4939IDE_DMA_Cmd); | ||
311 | |||
312 | /* clear INTR & ERROR flags */ | ||
313 | tx4939ide_clear_dma_status(base); | ||
314 | |||
315 | drive->waiting_for_dma = 1; | ||
316 | |||
317 | tx4939ide_writew(SECTOR_SIZE / 2, base, drive->dn ? | ||
318 | TX4939IDE_Xfer_Cnt_2 : TX4939IDE_Xfer_Cnt_1); | ||
319 | tx4939ide_writew(rq->nr_sectors, base, TX4939IDE_Sec_Cnt); | ||
320 | return 0; | ||
321 | } | ||
322 | |||
323 | static int tx4939ide_dma_end(ide_drive_t *drive) | ||
324 | { | ||
325 | ide_hwif_t *hwif = drive->hwif; | ||
326 | u8 dma_stat, dma_cmd; | ||
327 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
328 | u16 ctl = tx4939ide_readw(base, TX4939IDE_Int_Ctl); | ||
329 | |||
330 | drive->waiting_for_dma = 0; | ||
331 | |||
332 | /* get DMA command mode */ | ||
333 | dma_cmd = tx4939ide_readb(base, TX4939IDE_DMA_Cmd); | ||
334 | /* stop DMA */ | ||
335 | tx4939ide_writeb(dma_cmd & ~ATA_DMA_START, base, TX4939IDE_DMA_Cmd); | ||
336 | |||
337 | /* read and clear the INTR & ERROR bits */ | ||
338 | dma_stat = tx4939ide_clear_dma_status(base); | ||
339 | |||
340 | /* purge DMA mappings */ | ||
341 | ide_destroy_dmatable(drive); | ||
342 | /* verify good DMA status */ | ||
343 | wmb(); | ||
344 | |||
345 | if ((dma_stat & (ATA_DMA_INTR | ATA_DMA_ERR | ATA_DMA_ACTIVE)) == 0 && | ||
346 | (ctl & (TX4939IDE_INT_XFEREND | TX4939IDE_INT_HOST)) == | ||
347 | (TX4939IDE_INT_XFEREND | TX4939IDE_INT_HOST)) | ||
348 | /* INT_IDE lost... bug? */ | ||
349 | return 0; | ||
350 | return ((dma_stat & (ATA_DMA_INTR | ATA_DMA_ERR | ATA_DMA_ACTIVE)) != | ||
351 | ATA_DMA_INTR) ? 0x10 | dma_stat : 0; | ||
352 | } | ||
353 | |||
354 | /* returns 1 if DMA IRQ issued, 0 otherwise */ | ||
355 | static int tx4939ide_dma_test_irq(ide_drive_t *drive) | ||
356 | { | ||
357 | ide_hwif_t *hwif = drive->hwif; | ||
358 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
359 | u16 ctl, ide_int; | ||
360 | u8 dma_stat, stat; | ||
361 | int found = 0; | ||
362 | |||
363 | ctl = tx4939ide_check_error_ints(hwif); | ||
364 | ide_int = ctl & (TX4939IDE_INT_XFEREND | TX4939IDE_INT_HOST); | ||
365 | switch (ide_int) { | ||
366 | case TX4939IDE_INT_HOST: | ||
367 | /* On error, XFEREND might not be asserted. */ | ||
368 | stat = tx4939ide_readb(base, TX4939IDE_AltStat_DevCtl); | ||
369 | if ((stat & (ATA_BUSY | ATA_DRQ | ATA_ERR)) == ATA_ERR) | ||
370 | found = 1; | ||
371 | else | ||
372 | /* Wait for XFEREND (Mask HOST and unmask XFEREND) */ | ||
373 | ctl &= ~TX4939IDE_INT_XFEREND << 8; | ||
374 | ctl |= ide_int << 8; | ||
375 | break; | ||
376 | case TX4939IDE_INT_HOST | TX4939IDE_INT_XFEREND: | ||
377 | dma_stat = tx4939ide_readb(base, TX4939IDE_DMA_Stat); | ||
378 | if (!(dma_stat & ATA_DMA_INTR)) | ||
379 | pr_warning("%s: weird interrupt status. " | ||
380 | "DMA_Stat %#02x int_ctl %#04x\n", | ||
381 | hwif->name, dma_stat, ctl); | ||
382 | found = 1; | ||
383 | break; | ||
384 | } | ||
385 | /* | ||
386 | * Do not clear XFEREND, HOST now. They will be cleared by | ||
387 | * clearing bit2 of DMA_Stat. | ||
388 | */ | ||
389 | ctl &= ~ide_int; | ||
390 | tx4939ide_writew(ctl, base, TX4939IDE_Int_Ctl); | ||
391 | return found; | ||
392 | } | ||
393 | |||
394 | static void tx4939ide_init_hwif(ide_hwif_t *hwif) | ||
395 | { | ||
396 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
397 | |||
398 | /* Soft Reset */ | ||
399 | tx4939ide_writew(0x8000, base, TX4939IDE_Sys_Ctl); | ||
400 | mmiowb(); | ||
401 | /* at least 20 GBUSCLK (typ. 100ns @ GBUS200MHz, max 450ns) */ | ||
402 | ndelay(450); | ||
403 | tx4939ide_writew(0x0000, base, TX4939IDE_Sys_Ctl); | ||
404 | /* mask some interrupts and clear all interrupts */ | ||
405 | tx4939ide_writew((TX4939IDE_IGNORE_INTS << 8) | 0xff, base, | ||
406 | TX4939IDE_Int_Ctl); | ||
407 | |||
408 | tx4939ide_writew(0x0008, base, TX4939IDE_Lo_Burst_Cnt); | ||
409 | tx4939ide_writew(0, base, TX4939IDE_Up_Burst_Cnt); | ||
410 | } | ||
411 | |||
412 | static int tx4939ide_init_dma(ide_hwif_t *hwif, const struct ide_port_info *d) | ||
413 | { | ||
414 | hwif->dma_base = | ||
415 | hwif->extra_base + tx4939ide_swizzleb(TX4939IDE_DMA_Cmd); | ||
416 | /* | ||
417 | * Note that we cannot use ATA_DMA_TABLE_OFS, ATA_DMA_STATUS | ||
418 | * for big endian. | ||
419 | */ | ||
420 | return ide_allocate_dma_engine(hwif); | ||
421 | } | ||
422 | |||
423 | static void tx4939ide_tf_load_fixup(ide_drive_t *drive, ide_task_t *task) | ||
424 | { | ||
425 | ide_hwif_t *hwif = drive->hwif; | ||
426 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
427 | u16 sysctl = hwif->select_data >> (drive->dn ? 16 : 0); | ||
428 | |||
429 | /* | ||
430 | * Fix ATA100 CORE System Control Register. (The write to the | ||
431 | * Device/Head register may write wrong data to the System | ||
432 | * Control Register) | ||
433 | * While Sys_Ctl is written here, selectproc is not needed. | ||
434 | */ | ||
435 | tx4939ide_writew(sysctl, base, TX4939IDE_Sys_Ctl); | ||
436 | } | ||
437 | |||
438 | #ifdef __BIG_ENDIAN | ||
439 | |||
440 | static u8 tx4939ide_read_sff_dma_status(ide_hwif_t *hwif) | ||
441 | { | ||
442 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
443 | |||
444 | return tx4939ide_readb(base, TX4939IDE_DMA_Stat); | ||
445 | } | ||
446 | |||
447 | /* custom iops (independent from SWAP_IO_SPACE) */ | ||
448 | static u8 tx4939ide_inb(unsigned long port) | ||
449 | { | ||
450 | return __raw_readb((void __iomem *)port); | ||
451 | } | ||
452 | |||
453 | static void tx4939ide_outb(u8 value, unsigned long port) | ||
454 | { | ||
455 | __raw_writeb(value, (void __iomem *)port); | ||
456 | } | ||
457 | |||
458 | static void tx4939ide_tf_load(ide_drive_t *drive, ide_task_t *task) | ||
459 | { | ||
460 | ide_hwif_t *hwif = drive->hwif; | ||
461 | struct ide_io_ports *io_ports = &hwif->io_ports; | ||
462 | struct ide_taskfile *tf = &task->tf; | ||
463 | u8 HIHI = task->tf_flags & IDE_TFLAG_LBA48 ? 0xE0 : 0xEF; | ||
464 | |||
465 | if (task->tf_flags & IDE_TFLAG_FLAGGED) | ||
466 | HIHI = 0xFF; | ||
467 | |||
468 | if (task->tf_flags & IDE_TFLAG_OUT_DATA) { | ||
469 | u16 data = (tf->hob_data << 8) | tf->data; | ||
470 | |||
471 | /* no endian swap */ | ||
472 | __raw_writew(data, (void __iomem *)io_ports->data_addr); | ||
473 | } | ||
474 | |||
475 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_FEATURE) | ||
476 | tx4939ide_outb(tf->hob_feature, io_ports->feature_addr); | ||
477 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_NSECT) | ||
478 | tx4939ide_outb(tf->hob_nsect, io_ports->nsect_addr); | ||
479 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAL) | ||
480 | tx4939ide_outb(tf->hob_lbal, io_ports->lbal_addr); | ||
481 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAM) | ||
482 | tx4939ide_outb(tf->hob_lbam, io_ports->lbam_addr); | ||
483 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAH) | ||
484 | tx4939ide_outb(tf->hob_lbah, io_ports->lbah_addr); | ||
485 | |||
486 | if (task->tf_flags & IDE_TFLAG_OUT_FEATURE) | ||
487 | tx4939ide_outb(tf->feature, io_ports->feature_addr); | ||
488 | if (task->tf_flags & IDE_TFLAG_OUT_NSECT) | ||
489 | tx4939ide_outb(tf->nsect, io_ports->nsect_addr); | ||
490 | if (task->tf_flags & IDE_TFLAG_OUT_LBAL) | ||
491 | tx4939ide_outb(tf->lbal, io_ports->lbal_addr); | ||
492 | if (task->tf_flags & IDE_TFLAG_OUT_LBAM) | ||
493 | tx4939ide_outb(tf->lbam, io_ports->lbam_addr); | ||
494 | if (task->tf_flags & IDE_TFLAG_OUT_LBAH) | ||
495 | tx4939ide_outb(tf->lbah, io_ports->lbah_addr); | ||
496 | |||
497 | if (task->tf_flags & IDE_TFLAG_OUT_DEVICE) { | ||
498 | tx4939ide_outb((tf->device & HIHI) | drive->select, | ||
499 | io_ports->device_addr); | ||
500 | tx4939ide_tf_load_fixup(drive, task); | ||
501 | } | ||
502 | } | ||
503 | |||
504 | static void tx4939ide_tf_read(ide_drive_t *drive, ide_task_t *task) | ||
505 | { | ||
506 | ide_hwif_t *hwif = drive->hwif; | ||
507 | struct ide_io_ports *io_ports = &hwif->io_ports; | ||
508 | struct ide_taskfile *tf = &task->tf; | ||
509 | |||
510 | if (task->tf_flags & IDE_TFLAG_IN_DATA) { | ||
511 | u16 data; | ||
512 | |||
513 | /* no endian swap */ | ||
514 | data = __raw_readw((void __iomem *)io_ports->data_addr); | ||
515 | tf->data = data & 0xff; | ||
516 | tf->hob_data = (data >> 8) & 0xff; | ||
517 | } | ||
518 | |||
519 | /* be sure we're looking at the low order bits */ | ||
520 | tx4939ide_outb(ATA_DEVCTL_OBS & ~0x80, io_ports->ctl_addr); | ||
521 | |||
522 | if (task->tf_flags & IDE_TFLAG_IN_FEATURE) | ||
523 | tf->feature = tx4939ide_inb(io_ports->feature_addr); | ||
524 | if (task->tf_flags & IDE_TFLAG_IN_NSECT) | ||
525 | tf->nsect = tx4939ide_inb(io_ports->nsect_addr); | ||
526 | if (task->tf_flags & IDE_TFLAG_IN_LBAL) | ||
527 | tf->lbal = tx4939ide_inb(io_ports->lbal_addr); | ||
528 | if (task->tf_flags & IDE_TFLAG_IN_LBAM) | ||
529 | tf->lbam = tx4939ide_inb(io_ports->lbam_addr); | ||
530 | if (task->tf_flags & IDE_TFLAG_IN_LBAH) | ||
531 | tf->lbah = tx4939ide_inb(io_ports->lbah_addr); | ||
532 | if (task->tf_flags & IDE_TFLAG_IN_DEVICE) | ||
533 | tf->device = tx4939ide_inb(io_ports->device_addr); | ||
534 | |||
535 | if (task->tf_flags & IDE_TFLAG_LBA48) { | ||
536 | tx4939ide_outb(ATA_DEVCTL_OBS | 0x80, io_ports->ctl_addr); | ||
537 | |||
538 | if (task->tf_flags & IDE_TFLAG_IN_HOB_FEATURE) | ||
539 | tf->hob_feature = | ||
540 | tx4939ide_inb(io_ports->feature_addr); | ||
541 | if (task->tf_flags & IDE_TFLAG_IN_HOB_NSECT) | ||
542 | tf->hob_nsect = tx4939ide_inb(io_ports->nsect_addr); | ||
543 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAL) | ||
544 | tf->hob_lbal = tx4939ide_inb(io_ports->lbal_addr); | ||
545 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAM) | ||
546 | tf->hob_lbam = tx4939ide_inb(io_ports->lbam_addr); | ||
547 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAH) | ||
548 | tf->hob_lbah = tx4939ide_inb(io_ports->lbah_addr); | ||
549 | } | ||
550 | } | ||
551 | |||
552 | static void tx4939ide_input_data_swap(ide_drive_t *drive, struct request *rq, | ||
553 | void *buf, unsigned int len) | ||
554 | { | ||
555 | unsigned long port = drive->hwif->io_ports.data_addr; | ||
556 | unsigned short *ptr = buf; | ||
557 | unsigned int count = (len + 1) / 2; | ||
558 | |||
559 | while (count--) | ||
560 | *ptr++ = cpu_to_le16(__raw_readw((void __iomem *)port)); | ||
561 | __ide_flush_dcache_range((unsigned long)buf, count * 2); | ||
562 | } | ||
563 | |||
564 | static void tx4939ide_output_data_swap(ide_drive_t *drive, struct request *rq, | ||
565 | void *buf, unsigned int len) | ||
566 | { | ||
567 | unsigned long port = drive->hwif->io_ports.data_addr; | ||
568 | unsigned short *ptr = buf; | ||
569 | unsigned int count = (len + 1) / 2; | ||
570 | |||
571 | while (count--) { | ||
572 | __raw_writew(le16_to_cpu(*ptr), (void __iomem *)port); | ||
573 | ptr++; | ||
574 | } | ||
575 | __ide_flush_dcache_range((unsigned long)buf, count * 2); | ||
576 | } | ||
577 | |||
578 | static const struct ide_tp_ops tx4939ide_tp_ops = { | ||
579 | .exec_command = ide_exec_command, | ||
580 | .read_status = ide_read_status, | ||
581 | .read_altstatus = ide_read_altstatus, | ||
582 | .read_sff_dma_status = tx4939ide_read_sff_dma_status, | ||
583 | |||
584 | .set_irq = ide_set_irq, | ||
585 | |||
586 | .tf_load = tx4939ide_tf_load, | ||
587 | .tf_read = tx4939ide_tf_read, | ||
588 | |||
589 | .input_data = tx4939ide_input_data_swap, | ||
590 | .output_data = tx4939ide_output_data_swap, | ||
591 | }; | ||
592 | |||
593 | #else /* __LITTLE_ENDIAN */ | ||
594 | |||
595 | static void tx4939ide_tf_load(ide_drive_t *drive, ide_task_t *task) | ||
596 | { | ||
597 | ide_tf_load(drive, task); | ||
598 | if (task->tf_flags & IDE_TFLAG_OUT_DEVICE) | ||
599 | tx4939ide_tf_load_fixup(drive, task); | ||
600 | } | ||
601 | |||
602 | static const struct ide_tp_ops tx4939ide_tp_ops = { | ||
603 | .exec_command = ide_exec_command, | ||
604 | .read_status = ide_read_status, | ||
605 | .read_altstatus = ide_read_altstatus, | ||
606 | .read_sff_dma_status = ide_read_sff_dma_status, | ||
607 | |||
608 | .set_irq = ide_set_irq, | ||
609 | |||
610 | .tf_load = tx4939ide_tf_load, | ||
611 | .tf_read = ide_tf_read, | ||
612 | |||
613 | .input_data = ide_input_data, | ||
614 | .output_data = ide_output_data, | ||
615 | }; | ||
616 | |||
617 | #endif /* __LITTLE_ENDIAN */ | ||
618 | |||
619 | static const struct ide_port_ops tx4939ide_port_ops = { | ||
620 | .set_pio_mode = tx4939ide_set_pio_mode, | ||
621 | .set_dma_mode = tx4939ide_set_dma_mode, | ||
622 | .clear_irq = tx4939ide_clear_irq, | ||
623 | .cable_detect = tx4939ide_cable_detect, | ||
624 | }; | ||
625 | |||
626 | static const struct ide_dma_ops tx4939ide_dma_ops = { | ||
627 | .dma_host_set = tx4939ide_dma_host_set, | ||
628 | .dma_setup = tx4939ide_dma_setup, | ||
629 | .dma_exec_cmd = ide_dma_exec_cmd, | ||
630 | .dma_start = ide_dma_start, | ||
631 | .dma_end = tx4939ide_dma_end, | ||
632 | .dma_test_irq = tx4939ide_dma_test_irq, | ||
633 | .dma_lost_irq = ide_dma_lost_irq, | ||
634 | .dma_timeout = ide_dma_timeout, | ||
635 | }; | ||
636 | |||
637 | static const struct ide_port_info tx4939ide_port_info __initdata = { | ||
638 | .init_hwif = tx4939ide_init_hwif, | ||
639 | .init_dma = tx4939ide_init_dma, | ||
640 | .port_ops = &tx4939ide_port_ops, | ||
641 | .dma_ops = &tx4939ide_dma_ops, | ||
642 | .tp_ops = &tx4939ide_tp_ops, | ||
643 | .host_flags = IDE_HFLAG_MMIO, | ||
644 | .pio_mask = ATA_PIO4, | ||
645 | .mwdma_mask = ATA_MWDMA2, | ||
646 | .udma_mask = ATA_UDMA5, | ||
647 | }; | ||
648 | |||
649 | static int __init tx4939ide_probe(struct platform_device *pdev) | ||
650 | { | ||
651 | hw_regs_t hw; | ||
652 | hw_regs_t *hws[] = { &hw, NULL, NULL, NULL }; | ||
653 | struct ide_host *host; | ||
654 | struct resource *res; | ||
655 | int irq, ret; | ||
656 | unsigned long mapbase; | ||
657 | |||
658 | irq = platform_get_irq(pdev, 0); | ||
659 | if (irq < 0) | ||
660 | return -ENODEV; | ||
661 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | ||
662 | if (!res) | ||
663 | return -ENODEV; | ||
664 | |||
665 | if (!devm_request_mem_region(&pdev->dev, res->start, | ||
666 | res->end - res->start + 1, "tx4938ide")) | ||
667 | return -EBUSY; | ||
668 | mapbase = (unsigned long)devm_ioremap(&pdev->dev, res->start, | ||
669 | res->end - res->start + 1); | ||
670 | if (!mapbase) | ||
671 | return -EBUSY; | ||
672 | memset(&hw, 0, sizeof(hw)); | ||
673 | hw.io_ports.data_addr = | ||
674 | mapbase + tx4939ide_swizzlew(TX4939IDE_Data); | ||
675 | hw.io_ports.error_addr = | ||
676 | mapbase + tx4939ide_swizzleb(TX4939IDE_Error_Feature); | ||
677 | hw.io_ports.nsect_addr = | ||
678 | mapbase + tx4939ide_swizzleb(TX4939IDE_Sec); | ||
679 | hw.io_ports.lbal_addr = | ||
680 | mapbase + tx4939ide_swizzleb(TX4939IDE_LBA0); | ||
681 | hw.io_ports.lbam_addr = | ||
682 | mapbase + tx4939ide_swizzleb(TX4939IDE_LBA1); | ||
683 | hw.io_ports.lbah_addr = | ||
684 | mapbase + tx4939ide_swizzleb(TX4939IDE_LBA2); | ||
685 | hw.io_ports.device_addr = | ||
686 | mapbase + tx4939ide_swizzleb(TX4939IDE_DevHead); | ||
687 | hw.io_ports.command_addr = | ||
688 | mapbase + tx4939ide_swizzleb(TX4939IDE_Stat_Cmd); | ||
689 | hw.io_ports.ctl_addr = | ||
690 | mapbase + tx4939ide_swizzleb(TX4939IDE_AltStat_DevCtl); | ||
691 | hw.irq = irq; | ||
692 | hw.dev = &pdev->dev; | ||
693 | |||
694 | pr_info("TX4939 IDE interface (base %#lx, irq %d)\n", mapbase, irq); | ||
695 | host = ide_host_alloc(&tx4939ide_port_info, hws); | ||
696 | if (!host) | ||
697 | return -ENOMEM; | ||
698 | /* use extra_base for base address of the all registers */ | ||
699 | host->ports[0]->extra_base = mapbase; | ||
700 | ret = ide_host_register(host, &tx4939ide_port_info, hws); | ||
701 | if (ret) { | ||
702 | ide_host_free(host); | ||
703 | return ret; | ||
704 | } | ||
705 | platform_set_drvdata(pdev, host); | ||
706 | return 0; | ||
707 | } | ||
708 | |||
709 | static int __exit tx4939ide_remove(struct platform_device *pdev) | ||
710 | { | ||
711 | struct ide_host *host = platform_get_drvdata(pdev); | ||
712 | |||
713 | ide_host_remove(host); | ||
714 | return 0; | ||
715 | } | ||
716 | |||
717 | #ifdef CONFIG_PM | ||
718 | static int tx4939ide_resume(struct platform_device *dev) | ||
719 | { | ||
720 | struct ide_host *host = platform_get_drvdata(dev); | ||
721 | ide_hwif_t *hwif = host->ports[0]; | ||
722 | |||
723 | tx4939ide_init_hwif(hwif); | ||
724 | return 0; | ||
725 | } | ||
726 | #else | ||
727 | #define tx4939ide_resume NULL | ||
728 | #endif | ||
729 | |||
730 | static struct platform_driver tx4939ide_driver = { | ||
731 | .driver = { | ||
732 | .name = MODNAME, | ||
733 | .owner = THIS_MODULE, | ||
734 | }, | ||
735 | .remove = __exit_p(tx4939ide_remove), | ||
736 | .resume = tx4939ide_resume, | ||
737 | }; | ||
738 | |||
739 | static int __init tx4939ide_init(void) | ||
740 | { | ||
741 | return platform_driver_probe(&tx4939ide_driver, tx4939ide_probe); | ||
742 | } | ||
743 | |||
744 | static void __exit tx4939ide_exit(void) | ||
745 | { | ||
746 | platform_driver_unregister(&tx4939ide_driver); | ||
747 | } | ||
748 | |||
749 | module_init(tx4939ide_init); | ||
750 | module_exit(tx4939ide_exit); | ||
751 | |||
752 | MODULE_DESCRIPTION("TX4939 internal IDE driver"); | ||
753 | MODULE_LICENSE("GPL"); | ||
754 | MODULE_ALIAS("platform:tx4939ide"); | ||
diff --git a/drivers/idle/Kconfig b/drivers/idle/Kconfig index f5b26dd579e4..108264de0ac9 100644 --- a/drivers/idle/Kconfig +++ b/drivers/idle/Kconfig | |||
@@ -5,12 +5,13 @@ config I7300_IDLE_IOAT_CHANNEL | |||
5 | bool | 5 | bool |
6 | 6 | ||
7 | config I7300_IDLE | 7 | config I7300_IDLE |
8 | tristate "Intel chipset idle power saving driver" | 8 | tristate "Intel chipset idle memory power saving driver" |
9 | select I7300_IDLE_IOAT_CHANNEL | 9 | select I7300_IDLE_IOAT_CHANNEL |
10 | depends on X86_64 | 10 | depends on X86_64 && EXPERIMENTAL |
11 | help | 11 | help |
12 | Enable idle power savings with certain Intel server chipsets. | 12 | Enable memory power savings when idle with certain Intel server |
13 | The chipset must have I/O AT support, such as the Intel 7300. | 13 | chipsets. The chipset must have I/O AT support, such as the |
14 | The power savings depends on the type and quantity of DRAM devices. | 14 | Intel 7300. The power savings depends on the type and quantity of |
15 | DRAM devices. | ||
15 | 16 | ||
16 | endmenu | 17 | endmenu |
diff --git a/drivers/idle/i7300_idle.c b/drivers/idle/i7300_idle.c index 59d1bbc3cd3c..fb176f6ef9f8 100644 --- a/drivers/idle/i7300_idle.c +++ b/drivers/idle/i7300_idle.c | |||
@@ -25,6 +25,7 @@ | |||
25 | #include <linux/delay.h> | 25 | #include <linux/delay.h> |
26 | #include <linux/debugfs.h> | 26 | #include <linux/debugfs.h> |
27 | #include <linux/stop_machine.h> | 27 | #include <linux/stop_machine.h> |
28 | #include <linux/i7300_idle.h> | ||
28 | 29 | ||
29 | #include <asm/idle.h> | 30 | #include <asm/idle.h> |
30 | 31 | ||
@@ -34,6 +35,8 @@ | |||
34 | #define I7300_IDLE_DRIVER_VERSION "1.55" | 35 | #define I7300_IDLE_DRIVER_VERSION "1.55" |
35 | #define I7300_PRINT "i7300_idle:" | 36 | #define I7300_PRINT "i7300_idle:" |
36 | 37 | ||
38 | #define MAX_STOP_RETRIES 10 | ||
39 | |||
37 | static int debug; | 40 | static int debug; |
38 | module_param_named(debug, debug, uint, 0644); | 41 | module_param_named(debug, debug, uint, 0644); |
39 | MODULE_PARM_DESC(debug, "Enable debug printks in this driver"); | 42 | MODULE_PARM_DESC(debug, "Enable debug printks in this driver"); |
@@ -46,12 +49,12 @@ MODULE_PARM_DESC(debug, "Enable debug printks in this driver"); | |||
46 | * 0 = No throttling | 49 | * 0 = No throttling |
47 | * 1 = Throttle when > 4 activations per eval window (Maximum throttling) | 50 | * 1 = Throttle when > 4 activations per eval window (Maximum throttling) |
48 | * 2 = Throttle when > 8 activations | 51 | * 2 = Throttle when > 8 activations |
49 | * 168 = Throttle when > 168 activations (Minimum throttling) | 52 | * 168 = Throttle when > 672 activations (Minimum throttling) |
50 | */ | 53 | */ |
51 | #define MAX_THRTLWLIMIT 168 | 54 | #define MAX_THROTTLE_LOW_LIMIT 168 |
52 | static uint i7300_idle_thrtlowlm = 1; | 55 | static uint throttle_low_limit = 1; |
53 | module_param_named(thrtlwlimit, i7300_idle_thrtlowlm, uint, 0644); | 56 | module_param_named(throttle_low_limit, throttle_low_limit, uint, 0644); |
54 | MODULE_PARM_DESC(thrtlwlimit, | 57 | MODULE_PARM_DESC(throttle_low_limit, |
55 | "Value for THRTLOWLM activation field " | 58 | "Value for THRTLOWLM activation field " |
56 | "(0 = disable throttle, 1 = Max throttle, 168 = Min throttle)"); | 59 | "(0 = disable throttle, 1 = Max throttle, 168 = Min throttle)"); |
57 | 60 | ||
@@ -110,9 +113,9 @@ static int i7300_idle_ioat_start(void) | |||
110 | static void i7300_idle_ioat_stop(void) | 113 | static void i7300_idle_ioat_stop(void) |
111 | { | 114 | { |
112 | int i; | 115 | int i; |
113 | u8 sts; | 116 | u64 sts; |
114 | 117 | ||
115 | for (i = 0; i < 5; i++) { | 118 | for (i = 0; i < MAX_STOP_RETRIES; i++) { |
116 | writeb(IOAT_CHANCMD_RESET, | 119 | writeb(IOAT_CHANCMD_RESET, |
117 | ioat_chanbase + IOAT1_CHANCMD_OFFSET); | 120 | ioat_chanbase + IOAT1_CHANCMD_OFFSET); |
118 | 121 | ||
@@ -126,9 +129,10 @@ static void i7300_idle_ioat_stop(void) | |||
126 | 129 | ||
127 | } | 130 | } |
128 | 131 | ||
129 | if (i == 5) | 132 | if (i == MAX_STOP_RETRIES) { |
130 | dprintk("failed to suspend+reset I/O AT after 5 retries\n"); | 133 | dprintk("failed to stop I/O AT after %d retries\n", |
131 | 134 | MAX_STOP_RETRIES); | |
135 | } | ||
132 | } | 136 | } |
133 | 137 | ||
134 | /* Test I/O AT by copying 1024 byte from 2k to 1k */ | 138 | /* Test I/O AT by copying 1024 byte from 2k to 1k */ |
@@ -275,7 +279,7 @@ static void __exit i7300_idle_ioat_exit(void) | |||
275 | i7300_idle_ioat_stop(); | 279 | i7300_idle_ioat_stop(); |
276 | 280 | ||
277 | /* Wait for a while for the channel to halt before releasing */ | 281 | /* Wait for a while for the channel to halt before releasing */ |
278 | for (i = 0; i < 10; i++) { | 282 | for (i = 0; i < MAX_STOP_RETRIES; i++) { |
279 | writeb(IOAT_CHANCMD_RESET, | 283 | writeb(IOAT_CHANCMD_RESET, |
280 | ioat_chanbase + IOAT1_CHANCMD_OFFSET); | 284 | ioat_chanbase + IOAT1_CHANCMD_OFFSET); |
281 | 285 | ||
@@ -389,9 +393,9 @@ static void i7300_idle_start(void) | |||
389 | new_ctl = i7300_idle_thrtctl_saved & ~DIMM_THRTCTL_THRMHUNT; | 393 | new_ctl = i7300_idle_thrtctl_saved & ~DIMM_THRTCTL_THRMHUNT; |
390 | pci_write_config_byte(fbd_dev, DIMM_THRTCTL, new_ctl); | 394 | pci_write_config_byte(fbd_dev, DIMM_THRTCTL, new_ctl); |
391 | 395 | ||
392 | limit = i7300_idle_thrtlowlm; | 396 | limit = throttle_low_limit; |
393 | if (unlikely(limit > MAX_THRTLWLIMIT)) | 397 | if (unlikely(limit > MAX_THROTTLE_LOW_LIMIT)) |
394 | limit = MAX_THRTLWLIMIT; | 398 | limit = MAX_THROTTLE_LOW_LIMIT; |
395 | 399 | ||
396 | pci_write_config_byte(fbd_dev, DIMM_THRTLOW, limit); | 400 | pci_write_config_byte(fbd_dev, DIMM_THRTLOW, limit); |
397 | 401 | ||
@@ -440,7 +444,7 @@ static int i7300_idle_notifier(struct notifier_block *nb, unsigned long val, | |||
440 | static ktime_t idle_begin_time; | 444 | static ktime_t idle_begin_time; |
441 | static int time_init = 1; | 445 | static int time_init = 1; |
442 | 446 | ||
443 | if (!i7300_idle_thrtlowlm) | 447 | if (!throttle_low_limit) |
444 | return 0; | 448 | return 0; |
445 | 449 | ||
446 | if (unlikely(time_init)) { | 450 | if (unlikely(time_init)) { |
@@ -505,77 +509,8 @@ static struct notifier_block i7300_idle_nb = { | |||
505 | .notifier_call = i7300_idle_notifier, | 509 | .notifier_call = i7300_idle_notifier, |
506 | }; | 510 | }; |
507 | 511 | ||
508 | /* | ||
509 | * I/O AT controls (PCI bus 0 device 8 function 0) | ||
510 | * DIMM controls (PCI bus 0 device 16 function 1) | ||
511 | */ | ||
512 | #define IOAT_BUS 0 | ||
513 | #define IOAT_DEVFN PCI_DEVFN(8, 0) | ||
514 | #define MEMCTL_BUS 0 | ||
515 | #define MEMCTL_DEVFN PCI_DEVFN(16, 1) | ||
516 | |||
517 | struct fbd_ioat { | ||
518 | unsigned int vendor; | ||
519 | unsigned int ioat_dev; | ||
520 | }; | ||
521 | |||
522 | /* | ||
523 | * The i5000 chip-set has the same hooks as the i7300 | ||
524 | * but support is disabled by default because this driver | ||
525 | * has not been validated on that platform. | ||
526 | */ | ||
527 | #define SUPPORT_I5000 0 | ||
528 | |||
529 | static const struct fbd_ioat fbd_ioat_list[] = { | ||
530 | {PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_IOAT_CNB}, | ||
531 | #if SUPPORT_I5000 | ||
532 | {PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_IOAT}, | ||
533 | #endif | ||
534 | {0, 0} | ||
535 | }; | ||
536 | |||
537 | /* table of devices that work with this driver */ | ||
538 | static const struct pci_device_id pci_tbl[] = { | ||
539 | { PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_FBD_CNB) }, | ||
540 | #if SUPPORT_I5000 | ||
541 | { PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_5000_ERR) }, | ||
542 | #endif | ||
543 | { } /* Terminating entry */ | ||
544 | }; | ||
545 | |||
546 | MODULE_DEVICE_TABLE(pci, pci_tbl); | 512 | MODULE_DEVICE_TABLE(pci, pci_tbl); |
547 | 513 | ||
548 | /* Check for known platforms with I/O-AT */ | ||
549 | static int __init i7300_idle_platform_probe(void) | ||
550 | { | ||
551 | int i; | ||
552 | |||
553 | fbd_dev = pci_get_bus_and_slot(MEMCTL_BUS, MEMCTL_DEVFN); | ||
554 | if (!fbd_dev) | ||
555 | return -ENODEV; | ||
556 | |||
557 | for (i = 0; pci_tbl[i].vendor != 0; i++) { | ||
558 | if (fbd_dev->vendor == pci_tbl[i].vendor && | ||
559 | fbd_dev->device == pci_tbl[i].device) { | ||
560 | break; | ||
561 | } | ||
562 | } | ||
563 | if (pci_tbl[i].vendor == 0) | ||
564 | return -ENODEV; | ||
565 | |||
566 | ioat_dev = pci_get_bus_and_slot(IOAT_BUS, IOAT_DEVFN); | ||
567 | if (!ioat_dev) | ||
568 | return -ENODEV; | ||
569 | |||
570 | for (i = 0; fbd_ioat_list[i].vendor != 0; i++) { | ||
571 | if (ioat_dev->vendor == fbd_ioat_list[i].vendor && | ||
572 | ioat_dev->device == fbd_ioat_list[i].ioat_dev) { | ||
573 | return 0; | ||
574 | } | ||
575 | } | ||
576 | return -ENODEV; | ||
577 | } | ||
578 | |||
579 | int stats_open_generic(struct inode *inode, struct file *fp) | 514 | int stats_open_generic(struct inode *inode, struct file *fp) |
580 | { | 515 | { |
581 | fp->private_data = inode->i_private; | 516 | fp->private_data = inode->i_private; |
@@ -617,7 +552,7 @@ static int __init i7300_idle_init(void) | |||
617 | cpus_clear(idle_cpumask); | 552 | cpus_clear(idle_cpumask); |
618 | total_us = 0; | 553 | total_us = 0; |
619 | 554 | ||
620 | if (i7300_idle_platform_probe()) | 555 | if (i7300_idle_platform_probe(&fbd_dev, &ioat_dev)) |
621 | return -ENODEV; | 556 | return -ENODEV; |
622 | 557 | ||
623 | if (i7300_idle_thrt_save()) | 558 | if (i7300_idle_thrt_save()) |
diff --git a/drivers/input/misc/sgi_btns.c b/drivers/input/misc/sgi_btns.c index ce238f59b3c8..be3a15f5b25d 100644 --- a/drivers/input/misc/sgi_btns.c +++ b/drivers/input/misc/sgi_btns.c | |||
@@ -174,5 +174,6 @@ static void __exit sgi_buttons_exit(void) | |||
174 | platform_driver_unregister(&sgi_buttons_driver); | 174 | platform_driver_unregister(&sgi_buttons_driver); |
175 | } | 175 | } |
176 | 176 | ||
177 | MODULE_LICENSE("GPL"); | ||
177 | module_init(sgi_buttons_init); | 178 | module_init(sgi_buttons_init); |
178 | module_exit(sgi_buttons_exit); | 179 | module_exit(sgi_buttons_exit); |
diff --git a/drivers/input/mouse/Kconfig b/drivers/input/mouse/Kconfig index f488b6852baf..4e9934259775 100644 --- a/drivers/input/mouse/Kconfig +++ b/drivers/input/mouse/Kconfig | |||
@@ -25,8 +25,8 @@ config MOUSE_PS2 | |||
25 | mice with wheels and extra buttons, Microsoft, Logitech or Genius | 25 | mice with wheels and extra buttons, Microsoft, Logitech or Genius |
26 | compatible. | 26 | compatible. |
27 | 27 | ||
28 | Synaptics TouchPad users might be interested in a specialized | 28 | Synaptics, ALPS or Elantech TouchPad users might be interested |
29 | XFree86 driver at: | 29 | in a specialized Xorg/XFree86 driver at: |
30 | <http://w1.894.telia.com/~u89404340/touchpad/index.html> | 30 | <http://w1.894.telia.com/~u89404340/touchpad/index.html> |
31 | and a new version of GPM at: | 31 | and a new version of GPM at: |
32 | <http://www.geocities.com/dt_or/gpm/gpm.html> | 32 | <http://www.geocities.com/dt_or/gpm/gpm.html> |
@@ -87,6 +87,27 @@ config MOUSE_PS2_TRACKPOINT | |||
87 | 87 | ||
88 | If unsure, say Y. | 88 | If unsure, say Y. |
89 | 89 | ||
90 | config MOUSE_PS2_ELANTECH | ||
91 | bool "Elantech PS/2 protocol extension" | ||
92 | depends on MOUSE_PS2 | ||
93 | help | ||
94 | Say Y here if you have an Elantech PS/2 touchpad connected | ||
95 | to your system. | ||
96 | |||
97 | Note that if you enable this driver you will need an updated | ||
98 | X.org Synaptics driver that does not require ABS_PRESSURE | ||
99 | reports from the touchpad (i.e. post 1.5.0 version). You can | ||
100 | grab a patch for the driver here: | ||
101 | |||
102 | http://userweb.kernel.org/~dtor/synaptics-no-abspressure.patch | ||
103 | |||
104 | If unsure, say N. | ||
105 | |||
106 | This driver exposes some configuration registers via sysfs | ||
107 | entries. For further information, | ||
108 | see <file:Documentation/input/elantech.txt>. | ||
109 | |||
110 | |||
90 | config MOUSE_PS2_TOUCHKIT | 111 | config MOUSE_PS2_TOUCHKIT |
91 | bool "eGalax TouchKit PS/2 protocol extension" | 112 | bool "eGalax TouchKit PS/2 protocol extension" |
92 | depends on MOUSE_PS2 | 113 | depends on MOUSE_PS2 |
diff --git a/drivers/input/mouse/Makefile b/drivers/input/mouse/Makefile index 8e6e69097801..96f1dd8037f8 100644 --- a/drivers/input/mouse/Makefile +++ b/drivers/input/mouse/Makefile | |||
@@ -21,6 +21,7 @@ obj-$(CONFIG_MOUSE_GPIO) += gpio_mouse.o | |||
21 | psmouse-objs := psmouse-base.o synaptics.o | 21 | psmouse-objs := psmouse-base.o synaptics.o |
22 | 22 | ||
23 | psmouse-$(CONFIG_MOUSE_PS2_ALPS) += alps.o | 23 | psmouse-$(CONFIG_MOUSE_PS2_ALPS) += alps.o |
24 | psmouse-$(CONFIG_MOUSE_PS2_ELANTECH) += elantech.o | ||
24 | psmouse-$(CONFIG_MOUSE_PS2_OLPC) += hgpk.o | 25 | psmouse-$(CONFIG_MOUSE_PS2_OLPC) += hgpk.o |
25 | psmouse-$(CONFIG_MOUSE_PS2_LOGIPS2PP) += logips2pp.o | 26 | psmouse-$(CONFIG_MOUSE_PS2_LOGIPS2PP) += logips2pp.o |
26 | psmouse-$(CONFIG_MOUSE_PS2_LIFEBOOK) += lifebook.o | 27 | psmouse-$(CONFIG_MOUSE_PS2_LIFEBOOK) += lifebook.o |
diff --git a/drivers/input/mouse/elantech.c b/drivers/input/mouse/elantech.c new file mode 100644 index 000000000000..b9a25d57bc5e --- /dev/null +++ b/drivers/input/mouse/elantech.c | |||
@@ -0,0 +1,674 @@ | |||
1 | /* | ||
2 | * Elantech Touchpad driver (v5) | ||
3 | * | ||
4 | * Copyright (C) 2007-2008 Arjan Opmeer <arjan@opmeer.net> | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify it | ||
7 | * under the terms of the GNU General Public License version 2 as published | ||
8 | * by the Free Software Foundation. | ||
9 | * | ||
10 | * Trademarks are the property of their respective owners. | ||
11 | */ | ||
12 | |||
13 | #include <linux/delay.h> | ||
14 | #include <linux/module.h> | ||
15 | #include <linux/input.h> | ||
16 | #include <linux/serio.h> | ||
17 | #include <linux/libps2.h> | ||
18 | #include "psmouse.h" | ||
19 | #include "elantech.h" | ||
20 | |||
21 | #define elantech_debug(format, arg...) \ | ||
22 | do { \ | ||
23 | if (etd->debug) \ | ||
24 | printk(KERN_DEBUG format, ##arg); \ | ||
25 | } while (0) | ||
26 | |||
27 | /* | ||
28 | * Send a Synaptics style sliced query command | ||
29 | */ | ||
30 | static int synaptics_send_cmd(struct psmouse *psmouse, unsigned char c, | ||
31 | unsigned char *param) | ||
32 | { | ||
33 | if (psmouse_sliced_command(psmouse, c) || | ||
34 | ps2_command(&psmouse->ps2dev, param, PSMOUSE_CMD_GETINFO)) { | ||
35 | pr_err("elantech.c: synaptics_send_cmd query 0x%02x failed.\n", c); | ||
36 | return -1; | ||
37 | } | ||
38 | |||
39 | return 0; | ||
40 | } | ||
41 | |||
42 | /* | ||
43 | * A retrying version of ps2_command | ||
44 | */ | ||
45 | static int elantech_ps2_command(struct psmouse *psmouse, | ||
46 | unsigned char *param, int command) | ||
47 | { | ||
48 | struct ps2dev *ps2dev = &psmouse->ps2dev; | ||
49 | struct elantech_data *etd = psmouse->private; | ||
50 | int rc; | ||
51 | int tries = ETP_PS2_COMMAND_TRIES; | ||
52 | |||
53 | do { | ||
54 | rc = ps2_command(ps2dev, param, command); | ||
55 | if (rc == 0) | ||
56 | break; | ||
57 | tries--; | ||
58 | elantech_debug("elantech.c: retrying ps2 command 0x%02x (%d).\n", | ||
59 | command, tries); | ||
60 | msleep(ETP_PS2_COMMAND_DELAY); | ||
61 | } while (tries > 0); | ||
62 | |||
63 | if (rc) | ||
64 | pr_err("elantech.c: ps2 command 0x%02x failed.\n", command); | ||
65 | |||
66 | return rc; | ||
67 | } | ||
68 | |||
69 | /* | ||
70 | * Send an Elantech style special command to read a value from a register | ||
71 | */ | ||
72 | static int elantech_read_reg(struct psmouse *psmouse, unsigned char reg, | ||
73 | unsigned char *val) | ||
74 | { | ||
75 | struct elantech_data *etd = psmouse->private; | ||
76 | unsigned char param[3]; | ||
77 | int rc = 0; | ||
78 | |||
79 | if (reg < 0x10 || reg > 0x26) | ||
80 | return -1; | ||
81 | |||
82 | if (reg > 0x11 && reg < 0x20) | ||
83 | return -1; | ||
84 | |||
85 | switch (etd->hw_version) { | ||
86 | case 1: | ||
87 | if (psmouse_sliced_command(psmouse, ETP_REGISTER_READ) || | ||
88 | psmouse_sliced_command(psmouse, reg) || | ||
89 | ps2_command(&psmouse->ps2dev, param, PSMOUSE_CMD_GETINFO)) { | ||
90 | rc = -1; | ||
91 | } | ||
92 | break; | ||
93 | |||
94 | case 2: | ||
95 | if (elantech_ps2_command(psmouse, NULL, ETP_PS2_CUSTOM_COMMAND) || | ||
96 | elantech_ps2_command(psmouse, NULL, ETP_REGISTER_READ) || | ||
97 | elantech_ps2_command(psmouse, NULL, ETP_PS2_CUSTOM_COMMAND) || | ||
98 | elantech_ps2_command(psmouse, NULL, reg) || | ||
99 | elantech_ps2_command(psmouse, param, PSMOUSE_CMD_GETINFO)) { | ||
100 | rc = -1; | ||
101 | } | ||
102 | break; | ||
103 | } | ||
104 | |||
105 | if (rc) | ||
106 | pr_err("elantech.c: failed to read register 0x%02x.\n", reg); | ||
107 | else | ||
108 | *val = param[0]; | ||
109 | |||
110 | return rc; | ||
111 | } | ||
112 | |||
113 | /* | ||
114 | * Send an Elantech style special command to write a register with a value | ||
115 | */ | ||
116 | static int elantech_write_reg(struct psmouse *psmouse, unsigned char reg, | ||
117 | unsigned char val) | ||
118 | { | ||
119 | struct elantech_data *etd = psmouse->private; | ||
120 | int rc = 0; | ||
121 | |||
122 | if (reg < 0x10 || reg > 0x26) | ||
123 | return -1; | ||
124 | |||
125 | if (reg > 0x11 && reg < 0x20) | ||
126 | return -1; | ||
127 | |||
128 | switch (etd->hw_version) { | ||
129 | case 1: | ||
130 | if (psmouse_sliced_command(psmouse, ETP_REGISTER_WRITE) || | ||
131 | psmouse_sliced_command(psmouse, reg) || | ||
132 | psmouse_sliced_command(psmouse, val) || | ||
133 | ps2_command(&psmouse->ps2dev, NULL, PSMOUSE_CMD_SETSCALE11)) { | ||
134 | rc = -1; | ||
135 | } | ||
136 | break; | ||
137 | |||
138 | case 2: | ||
139 | if (elantech_ps2_command(psmouse, NULL, ETP_PS2_CUSTOM_COMMAND) || | ||
140 | elantech_ps2_command(psmouse, NULL, ETP_REGISTER_WRITE) || | ||
141 | elantech_ps2_command(psmouse, NULL, ETP_PS2_CUSTOM_COMMAND) || | ||
142 | elantech_ps2_command(psmouse, NULL, reg) || | ||
143 | elantech_ps2_command(psmouse, NULL, ETP_PS2_CUSTOM_COMMAND) || | ||
144 | elantech_ps2_command(psmouse, NULL, val) || | ||
145 | elantech_ps2_command(psmouse, NULL, PSMOUSE_CMD_SETSCALE11)) { | ||
146 | rc = -1; | ||
147 | } | ||
148 | break; | ||
149 | } | ||
150 | |||
151 | if (rc) | ||
152 | pr_err("elantech.c: failed to write register 0x%02x with value 0x%02x.\n", | ||
153 | reg, val); | ||
154 | |||
155 | return rc; | ||
156 | } | ||
157 | |||
158 | /* | ||
159 | * Dump a complete mouse movement packet to the syslog | ||
160 | */ | ||
161 | static void elantech_packet_dump(unsigned char *packet, int size) | ||
162 | { | ||
163 | int i; | ||
164 | |||
165 | printk(KERN_DEBUG "elantech.c: PS/2 packet ["); | ||
166 | for (i = 0; i < size; i++) | ||
167 | printk("%s0x%02x ", (i) ? ", " : " ", packet[i]); | ||
168 | printk("]\n"); | ||
169 | } | ||
170 | |||
171 | /* | ||
172 | * Interpret complete data packets and report absolute mode input events for | ||
173 | * hardware version 1. (4 byte packets) | ||
174 | */ | ||
175 | static void elantech_report_absolute_v1(struct psmouse *psmouse) | ||
176 | { | ||
177 | struct input_dev *dev = psmouse->dev; | ||
178 | struct elantech_data *etd = psmouse->private; | ||
179 | unsigned char *packet = psmouse->packet; | ||
180 | int fingers; | ||
181 | |||
182 | if (etd->fw_version_maj == 0x01) { | ||
183 | /* byte 0: D U p1 p2 1 p3 R L | ||
184 | byte 1: f 0 th tw x9 x8 y9 y8 */ | ||
185 | fingers = ((packet[1] & 0x80) >> 7) + | ||
186 | ((packet[1] & 0x30) >> 4); | ||
187 | } else { | ||
188 | /* byte 0: n1 n0 p2 p1 1 p3 R L | ||
189 | byte 1: 0 0 0 0 x9 x8 y9 y8 */ | ||
190 | fingers = (packet[0] & 0xc0) >> 6; | ||
191 | } | ||
192 | |||
193 | input_report_key(dev, BTN_TOUCH, fingers != 0); | ||
194 | |||
195 | /* byte 2: x7 x6 x5 x4 x3 x2 x1 x0 | ||
196 | byte 3: y7 y6 y5 y4 y3 y2 y1 y0 */ | ||
197 | if (fingers) { | ||
198 | input_report_abs(dev, ABS_X, | ||
199 | ((packet[1] & 0x0c) << 6) | packet[2]); | ||
200 | input_report_abs(dev, ABS_Y, ETP_YMAX_V1 - | ||
201 | (((packet[1] & 0x03) << 8) | packet[3])); | ||
202 | } | ||
203 | |||
204 | input_report_key(dev, BTN_TOOL_FINGER, fingers == 1); | ||
205 | input_report_key(dev, BTN_TOOL_DOUBLETAP, fingers == 2); | ||
206 | input_report_key(dev, BTN_TOOL_TRIPLETAP, fingers == 3); | ||
207 | input_report_key(dev, BTN_LEFT, packet[0] & 0x01); | ||
208 | input_report_key(dev, BTN_RIGHT, packet[0] & 0x02); | ||
209 | |||
210 | if ((etd->fw_version_maj == 0x01) && | ||
211 | (etd->capabilities & ETP_CAP_HAS_ROCKER)) { | ||
212 | /* rocker up */ | ||
213 | input_report_key(dev, BTN_FORWARD, packet[0] & 0x40); | ||
214 | /* rocker down */ | ||
215 | input_report_key(dev, BTN_BACK, packet[0] & 0x80); | ||
216 | } | ||
217 | |||
218 | input_sync(dev); | ||
219 | } | ||
220 | |||
221 | /* | ||
222 | * Interpret complete data packets and report absolute mode input events for | ||
223 | * hardware version 2. (6 byte packets) | ||
224 | */ | ||
225 | static void elantech_report_absolute_v2(struct psmouse *psmouse) | ||
226 | { | ||
227 | struct input_dev *dev = psmouse->dev; | ||
228 | unsigned char *packet = psmouse->packet; | ||
229 | int fingers, x1, y1, x2, y2; | ||
230 | |||
231 | /* byte 0: n1 n0 . . . . R L */ | ||
232 | fingers = (packet[0] & 0xc0) >> 6; | ||
233 | input_report_key(dev, BTN_TOUCH, fingers != 0); | ||
234 | |||
235 | switch (fingers) { | ||
236 | case 1: | ||
237 | /* byte 1: x15 x14 x13 x12 x11 x10 x9 x8 | ||
238 | byte 2: x7 x6 x5 x4 x4 x2 x1 x0 */ | ||
239 | input_report_abs(dev, ABS_X, (packet[1] << 8) | packet[2]); | ||
240 | /* byte 4: y15 y14 y13 y12 y11 y10 y8 y8 | ||
241 | byte 5: y7 y6 y5 y4 y3 y2 y1 y0 */ | ||
242 | input_report_abs(dev, ABS_Y, ETP_YMAX_V2 - | ||
243 | ((packet[4] << 8) | packet[5])); | ||
244 | break; | ||
245 | |||
246 | case 2: | ||
247 | /* The coordinate of each finger is reported separately with | ||
248 | a lower resolution for two finger touches */ | ||
249 | /* byte 0: . . ay8 ax8 . . . . | ||
250 | byte 1: ax7 ax6 ax5 ax4 ax3 ax2 ax1 ax0 */ | ||
251 | x1 = ((packet[0] & 0x10) << 4) | packet[1]; | ||
252 | /* byte 2: ay7 ay6 ay5 ay4 ay3 ay2 ay1 ay0 */ | ||
253 | y1 = ETP_2FT_YMAX - (((packet[0] & 0x20) << 3) | packet[2]); | ||
254 | /* byte 3: . . by8 bx8 . . . . | ||
255 | byte 4: bx7 bx6 bx5 bx4 bx3 bx2 bx1 bx0 */ | ||
256 | x2 = ((packet[3] & 0x10) << 4) | packet[4]; | ||
257 | /* byte 5: by7 by8 by5 by4 by3 by2 by1 by0 */ | ||
258 | y2 = ETP_2FT_YMAX - (((packet[3] & 0x20) << 3) | packet[5]); | ||
259 | /* For compatibility with the X Synaptics driver scale up one | ||
260 | coordinate and report as ordinary mouse movent */ | ||
261 | input_report_abs(dev, ABS_X, x1 << 2); | ||
262 | input_report_abs(dev, ABS_Y, y1 << 2); | ||
263 | /* For compatibility with the proprietary X Elantech driver | ||
264 | report both coordinates as hat coordinates */ | ||
265 | input_report_abs(dev, ABS_HAT0X, x1); | ||
266 | input_report_abs(dev, ABS_HAT0Y, y1); | ||
267 | input_report_abs(dev, ABS_HAT1X, x2); | ||
268 | input_report_abs(dev, ABS_HAT1Y, y2); | ||
269 | break; | ||
270 | } | ||
271 | |||
272 | input_report_key(dev, BTN_TOOL_FINGER, fingers == 1); | ||
273 | input_report_key(dev, BTN_TOOL_DOUBLETAP, fingers == 2); | ||
274 | input_report_key(dev, BTN_TOOL_TRIPLETAP, fingers == 3); | ||
275 | input_report_key(dev, BTN_LEFT, packet[0] & 0x01); | ||
276 | input_report_key(dev, BTN_RIGHT, packet[0] & 0x02); | ||
277 | |||
278 | input_sync(dev); | ||
279 | } | ||
280 | |||
281 | static int elantech_check_parity_v1(struct psmouse *psmouse) | ||
282 | { | ||
283 | struct elantech_data *etd = psmouse->private; | ||
284 | unsigned char *packet = psmouse->packet; | ||
285 | unsigned char p1, p2, p3; | ||
286 | |||
287 | /* Parity bits are placed differently */ | ||
288 | if (etd->fw_version_maj == 0x01) { | ||
289 | /* byte 0: D U p1 p2 1 p3 R L */ | ||
290 | p1 = (packet[0] & 0x20) >> 5; | ||
291 | p2 = (packet[0] & 0x10) >> 4; | ||
292 | } else { | ||
293 | /* byte 0: n1 n0 p2 p1 1 p3 R L */ | ||
294 | p1 = (packet[0] & 0x10) >> 4; | ||
295 | p2 = (packet[0] & 0x20) >> 5; | ||
296 | } | ||
297 | |||
298 | p3 = (packet[0] & 0x04) >> 2; | ||
299 | |||
300 | return etd->parity[packet[1]] == p1 && | ||
301 | etd->parity[packet[2]] == p2 && | ||
302 | etd->parity[packet[3]] == p3; | ||
303 | } | ||
304 | |||
305 | /* | ||
306 | * Process byte stream from mouse and handle complete packets | ||
307 | */ | ||
308 | static psmouse_ret_t elantech_process_byte(struct psmouse *psmouse) | ||
309 | { | ||
310 | struct elantech_data *etd = psmouse->private; | ||
311 | |||
312 | if (psmouse->pktcnt < psmouse->pktsize) | ||
313 | return PSMOUSE_GOOD_DATA; | ||
314 | |||
315 | if (etd->debug > 1) | ||
316 | elantech_packet_dump(psmouse->packet, psmouse->pktsize); | ||
317 | |||
318 | switch (etd->hw_version) { | ||
319 | case 1: | ||
320 | if (etd->paritycheck && !elantech_check_parity_v1(psmouse)) | ||
321 | return PSMOUSE_BAD_DATA; | ||
322 | |||
323 | elantech_report_absolute_v1(psmouse); | ||
324 | break; | ||
325 | |||
326 | case 2: | ||
327 | /* We don't know how to check parity in protocol v2 */ | ||
328 | elantech_report_absolute_v2(psmouse); | ||
329 | break; | ||
330 | } | ||
331 | |||
332 | return PSMOUSE_FULL_PACKET; | ||
333 | } | ||
334 | |||
335 | /* | ||
336 | * Put the touchpad into absolute mode | ||
337 | */ | ||
338 | static int elantech_set_absolute_mode(struct psmouse *psmouse) | ||
339 | { | ||
340 | struct elantech_data *etd = psmouse->private; | ||
341 | unsigned char val; | ||
342 | int tries = ETP_READ_BACK_TRIES; | ||
343 | int rc = 0; | ||
344 | |||
345 | switch (etd->hw_version) { | ||
346 | case 1: | ||
347 | etd->reg_10 = 0x16; | ||
348 | etd->reg_11 = 0x8f; | ||
349 | if (elantech_write_reg(psmouse, 0x10, etd->reg_10) || | ||
350 | elantech_write_reg(psmouse, 0x11, etd->reg_11)) { | ||
351 | rc = -1; | ||
352 | } | ||
353 | break; | ||
354 | |||
355 | case 2: | ||
356 | /* Windows driver values */ | ||
357 | etd->reg_10 = 0x54; | ||
358 | etd->reg_11 = 0x88; /* 0x8a */ | ||
359 | etd->reg_21 = 0x60; /* 0x00 */ | ||
360 | if (elantech_write_reg(psmouse, 0x10, etd->reg_10) || | ||
361 | elantech_write_reg(psmouse, 0x11, etd->reg_11) || | ||
362 | elantech_write_reg(psmouse, 0x21, etd->reg_21)) { | ||
363 | rc = -1; | ||
364 | break; | ||
365 | } | ||
366 | /* | ||
367 | * Read back reg 0x10. The touchpad is probably initalising | ||
368 | * and not ready until we read back the value we just wrote. | ||
369 | */ | ||
370 | do { | ||
371 | rc = elantech_read_reg(psmouse, 0x10, &val); | ||
372 | if (rc == 0) | ||
373 | break; | ||
374 | tries--; | ||
375 | elantech_debug("elantech.c: retrying read (%d).\n", | ||
376 | tries); | ||
377 | msleep(ETP_READ_BACK_DELAY); | ||
378 | } while (tries > 0); | ||
379 | if (rc) | ||
380 | pr_err("elantech.c: failed to read back register 0x10.\n"); | ||
381 | break; | ||
382 | } | ||
383 | |||
384 | if (rc) | ||
385 | pr_err("elantech.c: failed to initialise registers.\n"); | ||
386 | |||
387 | return rc; | ||
388 | } | ||
389 | |||
390 | /* | ||
391 | * Set the appropriate event bits for the input subsystem | ||
392 | */ | ||
393 | static void elantech_set_input_params(struct psmouse *psmouse) | ||
394 | { | ||
395 | struct input_dev *dev = psmouse->dev; | ||
396 | struct elantech_data *etd = psmouse->private; | ||
397 | |||
398 | __set_bit(EV_KEY, dev->evbit); | ||
399 | __set_bit(EV_ABS, dev->evbit); | ||
400 | |||
401 | __set_bit(BTN_LEFT, dev->keybit); | ||
402 | __set_bit(BTN_RIGHT, dev->keybit); | ||
403 | |||
404 | __set_bit(BTN_TOUCH, dev->keybit); | ||
405 | __set_bit(BTN_TOOL_FINGER, dev->keybit); | ||
406 | __set_bit(BTN_TOOL_DOUBLETAP, dev->keybit); | ||
407 | __set_bit(BTN_TOOL_TRIPLETAP, dev->keybit); | ||
408 | |||
409 | switch (etd->hw_version) { | ||
410 | case 1: | ||
411 | /* Rocker button */ | ||
412 | if ((etd->fw_version_maj == 0x01) && | ||
413 | (etd->capabilities & ETP_CAP_HAS_ROCKER)) { | ||
414 | __set_bit(BTN_FORWARD, dev->keybit); | ||
415 | __set_bit(BTN_BACK, dev->keybit); | ||
416 | } | ||
417 | input_set_abs_params(dev, ABS_X, ETP_XMIN_V1, ETP_XMAX_V1, 0, 0); | ||
418 | input_set_abs_params(dev, ABS_Y, ETP_YMIN_V1, ETP_YMAX_V1, 0, 0); | ||
419 | break; | ||
420 | |||
421 | case 2: | ||
422 | input_set_abs_params(dev, ABS_X, ETP_XMIN_V2, ETP_XMAX_V2, 0, 0); | ||
423 | input_set_abs_params(dev, ABS_Y, ETP_YMIN_V2, ETP_YMAX_V2, 0, 0); | ||
424 | input_set_abs_params(dev, ABS_HAT0X, ETP_2FT_XMIN, ETP_2FT_XMAX, 0, 0); | ||
425 | input_set_abs_params(dev, ABS_HAT0Y, ETP_2FT_YMIN, ETP_2FT_YMAX, 0, 0); | ||
426 | input_set_abs_params(dev, ABS_HAT1X, ETP_2FT_XMIN, ETP_2FT_XMAX, 0, 0); | ||
427 | input_set_abs_params(dev, ABS_HAT1Y, ETP_2FT_YMIN, ETP_2FT_YMAX, 0, 0); | ||
428 | break; | ||
429 | } | ||
430 | } | ||
431 | |||
432 | struct elantech_attr_data { | ||
433 | size_t field_offset; | ||
434 | unsigned char reg; | ||
435 | }; | ||
436 | |||
437 | /* | ||
438 | * Display a register value by reading a sysfs entry | ||
439 | */ | ||
440 | static ssize_t elantech_show_int_attr(struct psmouse *psmouse, void *data, | ||
441 | char *buf) | ||
442 | { | ||
443 | struct elantech_data *etd = psmouse->private; | ||
444 | struct elantech_attr_data *attr = data; | ||
445 | unsigned char *reg = (unsigned char *) etd + attr->field_offset; | ||
446 | int rc = 0; | ||
447 | |||
448 | if (attr->reg) | ||
449 | rc = elantech_read_reg(psmouse, attr->reg, reg); | ||
450 | |||
451 | return sprintf(buf, "0x%02x\n", (attr->reg && rc) ? -1 : *reg); | ||
452 | } | ||
453 | |||
454 | /* | ||
455 | * Write a register value by writing a sysfs entry | ||
456 | */ | ||
457 | static ssize_t elantech_set_int_attr(struct psmouse *psmouse, | ||
458 | void *data, const char *buf, size_t count) | ||
459 | { | ||
460 | struct elantech_data *etd = psmouse->private; | ||
461 | struct elantech_attr_data *attr = data; | ||
462 | unsigned char *reg = (unsigned char *) etd + attr->field_offset; | ||
463 | unsigned long value; | ||
464 | int err; | ||
465 | |||
466 | err = strict_strtoul(buf, 16, &value); | ||
467 | if (err) | ||
468 | return err; | ||
469 | |||
470 | if (value > 0xff) | ||
471 | return -EINVAL; | ||
472 | |||
473 | /* Do we need to preserve some bits for version 2 hardware too? */ | ||
474 | if (etd->hw_version == 1) { | ||
475 | if (attr->reg == 0x10) | ||
476 | /* Force absolute mode always on */ | ||
477 | value |= ETP_R10_ABSOLUTE_MODE; | ||
478 | else if (attr->reg == 0x11) | ||
479 | /* Force 4 byte mode always on */ | ||
480 | value |= ETP_R11_4_BYTE_MODE; | ||
481 | } | ||
482 | |||
483 | if (!attr->reg || elantech_write_reg(psmouse, attr->reg, value) == 0) | ||
484 | *reg = value; | ||
485 | |||
486 | return count; | ||
487 | } | ||
488 | |||
489 | #define ELANTECH_INT_ATTR(_name, _register) \ | ||
490 | static struct elantech_attr_data elantech_attr_##_name = { \ | ||
491 | .field_offset = offsetof(struct elantech_data, _name), \ | ||
492 | .reg = _register, \ | ||
493 | }; \ | ||
494 | PSMOUSE_DEFINE_ATTR(_name, S_IWUSR | S_IRUGO, \ | ||
495 | &elantech_attr_##_name, \ | ||
496 | elantech_show_int_attr, \ | ||
497 | elantech_set_int_attr) | ||
498 | |||
499 | ELANTECH_INT_ATTR(reg_10, 0x10); | ||
500 | ELANTECH_INT_ATTR(reg_11, 0x11); | ||
501 | ELANTECH_INT_ATTR(reg_20, 0x20); | ||
502 | ELANTECH_INT_ATTR(reg_21, 0x21); | ||
503 | ELANTECH_INT_ATTR(reg_22, 0x22); | ||
504 | ELANTECH_INT_ATTR(reg_23, 0x23); | ||
505 | ELANTECH_INT_ATTR(reg_24, 0x24); | ||
506 | ELANTECH_INT_ATTR(reg_25, 0x25); | ||
507 | ELANTECH_INT_ATTR(reg_26, 0x26); | ||
508 | ELANTECH_INT_ATTR(debug, 0); | ||
509 | ELANTECH_INT_ATTR(paritycheck, 0); | ||
510 | |||
511 | static struct attribute *elantech_attrs[] = { | ||
512 | &psmouse_attr_reg_10.dattr.attr, | ||
513 | &psmouse_attr_reg_11.dattr.attr, | ||
514 | &psmouse_attr_reg_20.dattr.attr, | ||
515 | &psmouse_attr_reg_21.dattr.attr, | ||
516 | &psmouse_attr_reg_22.dattr.attr, | ||
517 | &psmouse_attr_reg_23.dattr.attr, | ||
518 | &psmouse_attr_reg_24.dattr.attr, | ||
519 | &psmouse_attr_reg_25.dattr.attr, | ||
520 | &psmouse_attr_reg_26.dattr.attr, | ||
521 | &psmouse_attr_debug.dattr.attr, | ||
522 | &psmouse_attr_paritycheck.dattr.attr, | ||
523 | NULL | ||
524 | }; | ||
525 | |||
526 | static struct attribute_group elantech_attr_group = { | ||
527 | .attrs = elantech_attrs, | ||
528 | }; | ||
529 | |||
530 | /* | ||
531 | * Use magic knock to detect Elantech touchpad | ||
532 | */ | ||
533 | int elantech_detect(struct psmouse *psmouse, int set_properties) | ||
534 | { | ||
535 | struct ps2dev *ps2dev = &psmouse->ps2dev; | ||
536 | unsigned char param[3]; | ||
537 | |||
538 | ps2_command(&psmouse->ps2dev, NULL, PSMOUSE_CMD_RESET_DIS); | ||
539 | |||
540 | if (ps2_command(ps2dev, NULL, PSMOUSE_CMD_DISABLE) || | ||
541 | ps2_command(ps2dev, NULL, PSMOUSE_CMD_SETSCALE11) || | ||
542 | ps2_command(ps2dev, NULL, PSMOUSE_CMD_SETSCALE11) || | ||
543 | ps2_command(ps2dev, NULL, PSMOUSE_CMD_SETSCALE11) || | ||
544 | ps2_command(ps2dev, param, PSMOUSE_CMD_GETINFO)) { | ||
545 | pr_err("elantech.c: sending Elantech magic knock failed.\n"); | ||
546 | return -1; | ||
547 | } | ||
548 | |||
549 | /* | ||
550 | * Report this in case there are Elantech models that use a different | ||
551 | * set of magic numbers | ||
552 | */ | ||
553 | if (param[0] != 0x3c || param[1] != 0x03 || param[2] != 0xc8) { | ||
554 | pr_info("elantech.c: unexpected magic knock result 0x%02x, 0x%02x, 0x%02x.\n", | ||
555 | param[0], param[1], param[2]); | ||
556 | return -1; | ||
557 | } | ||
558 | |||
559 | if (set_properties) { | ||
560 | psmouse->vendor = "Elantech"; | ||
561 | psmouse->name = "Touchpad"; | ||
562 | } | ||
563 | |||
564 | return 0; | ||
565 | } | ||
566 | |||
567 | /* | ||
568 | * Clean up sysfs entries when disconnecting | ||
569 | */ | ||
570 | static void elantech_disconnect(struct psmouse *psmouse) | ||
571 | { | ||
572 | sysfs_remove_group(&psmouse->ps2dev.serio->dev.kobj, | ||
573 | &elantech_attr_group); | ||
574 | kfree(psmouse->private); | ||
575 | psmouse->private = NULL; | ||
576 | } | ||
577 | |||
578 | /* | ||
579 | * Put the touchpad back into absolute mode when reconnecting | ||
580 | */ | ||
581 | static int elantech_reconnect(struct psmouse *psmouse) | ||
582 | { | ||
583 | if (elantech_detect(psmouse, 0)) | ||
584 | return -1; | ||
585 | |||
586 | if (elantech_set_absolute_mode(psmouse)) { | ||
587 | pr_err("elantech.c: failed to put touchpad back into absolute mode.\n"); | ||
588 | return -1; | ||
589 | } | ||
590 | |||
591 | return 0; | ||
592 | } | ||
593 | |||
594 | /* | ||
595 | * Initialize the touchpad and create sysfs entries | ||
596 | */ | ||
597 | int elantech_init(struct psmouse *psmouse) | ||
598 | { | ||
599 | struct elantech_data *etd; | ||
600 | int i, error; | ||
601 | unsigned char param[3]; | ||
602 | |||
603 | etd = kzalloc(sizeof(struct elantech_data), GFP_KERNEL); | ||
604 | psmouse->private = etd; | ||
605 | if (!etd) | ||
606 | return -1; | ||
607 | |||
608 | etd->parity[0] = 1; | ||
609 | for (i = 1; i < 256; i++) | ||
610 | etd->parity[i] = etd->parity[i & (i - 1)] ^ 1; | ||
611 | |||
612 | /* | ||
613 | * Find out what version hardware this is | ||
614 | */ | ||
615 | if (synaptics_send_cmd(psmouse, ETP_FW_VERSION_QUERY, param)) { | ||
616 | pr_err("elantech.c: failed to query firmware version.\n"); | ||
617 | goto init_fail; | ||
618 | } | ||
619 | pr_info("elantech.c: Elantech version query result 0x%02x, 0x%02x, 0x%02x.\n", | ||
620 | param[0], param[1], param[2]); | ||
621 | etd->fw_version_maj = param[0]; | ||
622 | etd->fw_version_min = param[2]; | ||
623 | |||
624 | /* | ||
625 | * Assume every version greater than this is new EeePC style | ||
626 | * hardware with 6 byte packets | ||
627 | */ | ||
628 | if (etd->fw_version_maj >= 0x02 && etd->fw_version_min >= 0x30) { | ||
629 | etd->hw_version = 2; | ||
630 | /* For now show extra debug information */ | ||
631 | etd->debug = 1; | ||
632 | /* Don't know how to do parity checking for version 2 */ | ||
633 | etd->paritycheck = 0; | ||
634 | } else { | ||
635 | etd->hw_version = 1; | ||
636 | etd->paritycheck = 1; | ||
637 | } | ||
638 | pr_info("elantech.c: assuming hardware version %d, firmware version %d.%d\n", | ||
639 | etd->hw_version, etd->fw_version_maj, etd->fw_version_min); | ||
640 | |||
641 | if (synaptics_send_cmd(psmouse, ETP_CAPABILITIES_QUERY, param)) { | ||
642 | pr_err("elantech.c: failed to query capabilities.\n"); | ||
643 | goto init_fail; | ||
644 | } | ||
645 | pr_info("elantech.c: Synaptics capabilities query result 0x%02x, 0x%02x, 0x%02x.\n", | ||
646 | param[0], param[1], param[2]); | ||
647 | etd->capabilities = param[0]; | ||
648 | |||
649 | if (elantech_set_absolute_mode(psmouse)) { | ||
650 | pr_err("elantech.c: failed to put touchpad into absolute mode.\n"); | ||
651 | goto init_fail; | ||
652 | } | ||
653 | |||
654 | elantech_set_input_params(psmouse); | ||
655 | |||
656 | error = sysfs_create_group(&psmouse->ps2dev.serio->dev.kobj, | ||
657 | &elantech_attr_group); | ||
658 | if (error) { | ||
659 | pr_err("elantech.c: failed to create sysfs attributes, error: %d.\n", | ||
660 | error); | ||
661 | goto init_fail; | ||
662 | } | ||
663 | |||
664 | psmouse->protocol_handler = elantech_process_byte; | ||
665 | psmouse->disconnect = elantech_disconnect; | ||
666 | psmouse->reconnect = elantech_reconnect; | ||
667 | psmouse->pktsize = etd->hw_version == 2 ? 6 : 4; | ||
668 | |||
669 | return 0; | ||
670 | |||
671 | init_fail: | ||
672 | kfree(etd); | ||
673 | return -1; | ||
674 | } | ||
diff --git a/drivers/input/mouse/elantech.h b/drivers/input/mouse/elantech.h new file mode 100644 index 000000000000..bee282b540bc --- /dev/null +++ b/drivers/input/mouse/elantech.h | |||
@@ -0,0 +1,124 @@ | |||
1 | /* | ||
2 | * Elantech Touchpad driver (v5) | ||
3 | * | ||
4 | * Copyright (C) 2007-2008 Arjan Opmeer <arjan@opmeer.net> | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify it | ||
7 | * under the terms of the GNU General Public License version 2 as published | ||
8 | * by the Free Software Foundation. | ||
9 | * | ||
10 | * Trademarks are the property of their respective owners. | ||
11 | */ | ||
12 | |||
13 | #ifndef _ELANTECH_H | ||
14 | #define _ELANTECH_H | ||
15 | |||
16 | /* | ||
17 | * Command values for Synaptics style queries | ||
18 | */ | ||
19 | #define ETP_FW_VERSION_QUERY 0x01 | ||
20 | #define ETP_CAPABILITIES_QUERY 0x02 | ||
21 | |||
22 | /* | ||
23 | * Command values for register reading or writing | ||
24 | */ | ||
25 | #define ETP_REGISTER_READ 0x10 | ||
26 | #define ETP_REGISTER_WRITE 0x11 | ||
27 | |||
28 | /* | ||
29 | * Hardware version 2 custom PS/2 command value | ||
30 | */ | ||
31 | #define ETP_PS2_CUSTOM_COMMAND 0xf8 | ||
32 | |||
33 | /* | ||
34 | * Times to retry a ps2_command and millisecond delay between tries | ||
35 | */ | ||
36 | #define ETP_PS2_COMMAND_TRIES 3 | ||
37 | #define ETP_PS2_COMMAND_DELAY 500 | ||
38 | |||
39 | /* | ||
40 | * Times to try to read back a register and millisecond delay between tries | ||
41 | */ | ||
42 | #define ETP_READ_BACK_TRIES 5 | ||
43 | #define ETP_READ_BACK_DELAY 2000 | ||
44 | |||
45 | /* | ||
46 | * Register bitmasks for hardware version 1 | ||
47 | */ | ||
48 | #define ETP_R10_ABSOLUTE_MODE 0x04 | ||
49 | #define ETP_R11_4_BYTE_MODE 0x02 | ||
50 | |||
51 | /* | ||
52 | * Capability bitmasks | ||
53 | */ | ||
54 | #define ETP_CAP_HAS_ROCKER 0x04 | ||
55 | |||
56 | /* | ||
57 | * One hard to find application note states that X axis range is 0 to 576 | ||
58 | * and Y axis range is 0 to 384 for harware version 1. | ||
59 | * Edge fuzz might be necessary because of bezel around the touchpad | ||
60 | */ | ||
61 | #define ETP_EDGE_FUZZ_V1 32 | ||
62 | |||
63 | #define ETP_XMIN_V1 ( 0 + ETP_EDGE_FUZZ_V1) | ||
64 | #define ETP_XMAX_V1 (576 - ETP_EDGE_FUZZ_V1) | ||
65 | #define ETP_YMIN_V1 ( 0 + ETP_EDGE_FUZZ_V1) | ||
66 | #define ETP_YMAX_V1 (384 - ETP_EDGE_FUZZ_V1) | ||
67 | |||
68 | /* | ||
69 | * It seems the resolution for hardware version 2 doubled. | ||
70 | * Hence the X and Y ranges are doubled too. | ||
71 | * The bezel around the pad also appears to be smaller | ||
72 | */ | ||
73 | #define ETP_EDGE_FUZZ_V2 8 | ||
74 | |||
75 | #define ETP_XMIN_V2 ( 0 + ETP_EDGE_FUZZ_V2) | ||
76 | #define ETP_XMAX_V2 (1152 - ETP_EDGE_FUZZ_V2) | ||
77 | #define ETP_YMIN_V2 ( 0 + ETP_EDGE_FUZZ_V2) | ||
78 | #define ETP_YMAX_V2 ( 768 - ETP_EDGE_FUZZ_V2) | ||
79 | |||
80 | /* | ||
81 | * For two finger touches the coordinate of each finger gets reported | ||
82 | * separately but with reduced resolution. | ||
83 | */ | ||
84 | #define ETP_2FT_FUZZ 4 | ||
85 | |||
86 | #define ETP_2FT_XMIN ( 0 + ETP_2FT_FUZZ) | ||
87 | #define ETP_2FT_XMAX (288 - ETP_2FT_FUZZ) | ||
88 | #define ETP_2FT_YMIN ( 0 + ETP_2FT_FUZZ) | ||
89 | #define ETP_2FT_YMAX (192 - ETP_2FT_FUZZ) | ||
90 | |||
91 | struct elantech_data { | ||
92 | unsigned char reg_10; | ||
93 | unsigned char reg_11; | ||
94 | unsigned char reg_20; | ||
95 | unsigned char reg_21; | ||
96 | unsigned char reg_22; | ||
97 | unsigned char reg_23; | ||
98 | unsigned char reg_24; | ||
99 | unsigned char reg_25; | ||
100 | unsigned char reg_26; | ||
101 | unsigned char debug; | ||
102 | unsigned char capabilities; | ||
103 | unsigned char fw_version_maj; | ||
104 | unsigned char fw_version_min; | ||
105 | unsigned char hw_version; | ||
106 | unsigned char paritycheck; | ||
107 | unsigned char parity[256]; | ||
108 | }; | ||
109 | |||
110 | #ifdef CONFIG_MOUSE_PS2_ELANTECH | ||
111 | int elantech_detect(struct psmouse *psmouse, int set_properties); | ||
112 | int elantech_init(struct psmouse *psmouse); | ||
113 | #else | ||
114 | static inline int elantech_detect(struct psmouse *psmouse, int set_properties) | ||
115 | { | ||
116 | return -ENOSYS; | ||
117 | } | ||
118 | static inline int elantech_init(struct psmouse *psmouse) | ||
119 | { | ||
120 | return -ENOSYS; | ||
121 | } | ||
122 | #endif /* CONFIG_MOUSE_PS2_ELANTECH */ | ||
123 | |||
124 | #endif | ||
diff --git a/drivers/input/mouse/psmouse-base.c b/drivers/input/mouse/psmouse-base.c index 126e977e199e..f8f86de694bb 100644 --- a/drivers/input/mouse/psmouse-base.c +++ b/drivers/input/mouse/psmouse-base.c | |||
@@ -29,6 +29,7 @@ | |||
29 | #include "lifebook.h" | 29 | #include "lifebook.h" |
30 | #include "trackpoint.h" | 30 | #include "trackpoint.h" |
31 | #include "touchkit_ps2.h" | 31 | #include "touchkit_ps2.h" |
32 | #include "elantech.h" | ||
32 | 33 | ||
33 | #define DRIVER_DESC "PS/2 mouse driver" | 34 | #define DRIVER_DESC "PS/2 mouse driver" |
34 | 35 | ||
@@ -650,6 +651,19 @@ static int psmouse_extensions(struct psmouse *psmouse, | |||
650 | max_proto = PSMOUSE_IMEX; | 651 | max_proto = PSMOUSE_IMEX; |
651 | } | 652 | } |
652 | 653 | ||
654 | /* | ||
655 | * Try Elantech touchpad. | ||
656 | */ | ||
657 | if (max_proto > PSMOUSE_IMEX && | ||
658 | elantech_detect(psmouse, set_properties) == 0) { | ||
659 | if (!set_properties || elantech_init(psmouse) == 0) | ||
660 | return PSMOUSE_ELANTECH; | ||
661 | /* | ||
662 | * Init failed, try basic relative protocols | ||
663 | */ | ||
664 | max_proto = PSMOUSE_IMEX; | ||
665 | } | ||
666 | |||
653 | if (max_proto > PSMOUSE_IMEX) { | 667 | if (max_proto > PSMOUSE_IMEX) { |
654 | if (genius_detect(psmouse, set_properties) == 0) | 668 | if (genius_detect(psmouse, set_properties) == 0) |
655 | return PSMOUSE_GENPS; | 669 | return PSMOUSE_GENPS; |
@@ -789,6 +803,15 @@ static const struct psmouse_protocol psmouse_protocols[] = { | |||
789 | .detect = hgpk_detect, | 803 | .detect = hgpk_detect, |
790 | }, | 804 | }, |
791 | #endif | 805 | #endif |
806 | #ifdef CONFIG_MOUSE_PS2_ELANTECH | ||
807 | { | ||
808 | .type = PSMOUSE_ELANTECH, | ||
809 | .name = "ETPS/2", | ||
810 | .alias = "elantech", | ||
811 | .detect = elantech_detect, | ||
812 | .init = elantech_init, | ||
813 | }, | ||
814 | #endif | ||
792 | { | 815 | { |
793 | .type = PSMOUSE_CORTRON, | 816 | .type = PSMOUSE_CORTRON, |
794 | .name = "CortronPS/2", | 817 | .name = "CortronPS/2", |
diff --git a/drivers/input/mouse/psmouse.h b/drivers/input/mouse/psmouse.h index 8b608a1cdd12..54ed267894bd 100644 --- a/drivers/input/mouse/psmouse.h +++ b/drivers/input/mouse/psmouse.h | |||
@@ -90,6 +90,7 @@ enum psmouse_type { | |||
90 | PSMOUSE_TOUCHKIT_PS2, | 90 | PSMOUSE_TOUCHKIT_PS2, |
91 | PSMOUSE_CORTRON, | 91 | PSMOUSE_CORTRON, |
92 | PSMOUSE_HGPK, | 92 | PSMOUSE_HGPK, |
93 | PSMOUSE_ELANTECH, | ||
93 | PSMOUSE_AUTO /* This one should always be last */ | 94 | PSMOUSE_AUTO /* This one should always be last */ |
94 | }; | 95 | }; |
95 | 96 | ||
diff --git a/drivers/input/serio/i8042-x86ia64io.h b/drivers/input/serio/i8042-x86ia64io.h index a321aea2c7b5..eec375cd10e6 100644 --- a/drivers/input/serio/i8042-x86ia64io.h +++ b/drivers/input/serio/i8042-x86ia64io.h | |||
@@ -135,6 +135,14 @@ static struct dmi_system_id __initdata i8042_dmi_noloop_table[] = { | |||
135 | DMI_MATCH(DMI_PRODUCT_VERSION, "5a"), | 135 | DMI_MATCH(DMI_PRODUCT_VERSION, "5a"), |
136 | }, | 136 | }, |
137 | }, | 137 | }, |
138 | { | ||
139 | .ident = "Blue FB5601", | ||
140 | .matches = { | ||
141 | DMI_MATCH(DMI_SYS_VENDOR, "blue"), | ||
142 | DMI_MATCH(DMI_PRODUCT_NAME, "FB5601"), | ||
143 | DMI_MATCH(DMI_PRODUCT_VERSION, "M606"), | ||
144 | }, | ||
145 | }, | ||
138 | { } | 146 | { } |
139 | }; | 147 | }; |
140 | 148 | ||
diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig index 8317fdef1691..3d1ab8fa9acc 100644 --- a/drivers/input/touchscreen/Kconfig +++ b/drivers/input/touchscreen/Kconfig | |||
@@ -42,8 +42,9 @@ config TOUCHSCREEN_BITSY | |||
42 | module will be called h3600_ts_input. | 42 | module will be called h3600_ts_input. |
43 | 43 | ||
44 | config TOUCHSCREEN_CORGI | 44 | config TOUCHSCREEN_CORGI |
45 | tristate "SharpSL (Corgi and Spitz series) touchscreen driver" | 45 | tristate "SharpSL (Corgi and Spitz series) touchscreen driver (DEPRECATED)" |
46 | depends on PXA_SHARPSL | 46 | depends on PXA_SHARPSL |
47 | select CORGI_SSP_DEPRECATED | ||
47 | default y | 48 | default y |
48 | help | 49 | help |
49 | Say Y here to enable the driver for the touchscreen on the | 50 | Say Y here to enable the driver for the touchscreen on the |
@@ -54,6 +55,9 @@ config TOUCHSCREEN_CORGI | |||
54 | To compile this driver as a module, choose M here: the | 55 | To compile this driver as a module, choose M here: the |
55 | module will be called corgi_ts. | 56 | module will be called corgi_ts. |
56 | 57 | ||
58 | NOTE: this driver is deprecated, try enable SPI and generic | ||
59 | ADS7846-based touchscreen driver. | ||
60 | |||
57 | config TOUCHSCREEN_FUJITSU | 61 | config TOUCHSCREEN_FUJITSU |
58 | tristate "Fujitsu serial touchscreen" | 62 | tristate "Fujitsu serial touchscreen" |
59 | select SERIO | 63 | select SERIO |
diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig index c7ff1e11ea85..e7fb7d2fcbfc 100644 --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig | |||
@@ -113,11 +113,12 @@ config LEDS_GPIO | |||
113 | outputs. To be useful the particular board must have LEDs | 113 | outputs. To be useful the particular board must have LEDs |
114 | and they must be connected to the GPIO lines. | 114 | and they must be connected to the GPIO lines. |
115 | 115 | ||
116 | config LEDS_CM_X270 | 116 | config LEDS_HP_DISK |
117 | tristate "LED Support for the CM-X270 LEDs" | 117 | tristate "LED Support for disk protection LED on HP notebooks" |
118 | depends on LEDS_CLASS && MACH_ARMCORE | 118 | depends on LEDS_CLASS && ACPI |
119 | help | 119 | help |
120 | This option enables support for the CM-X270 LEDs. | 120 | This option enable support for disk protection LED, found on |
121 | newer HP notebooks. | ||
121 | 122 | ||
122 | config LEDS_CLEVO_MAIL | 123 | config LEDS_CLEVO_MAIL |
123 | tristate "Mail LED on Clevo notebook (EXPERIMENTAL)" | 124 | tristate "Mail LED on Clevo notebook (EXPERIMENTAL)" |
@@ -157,6 +158,13 @@ config LEDS_PCA955X | |||
157 | LED driver chips accessed via the I2C bus. Supported | 158 | LED driver chips accessed via the I2C bus. Supported |
158 | devices include PCA9550, PCA9551, PCA9552, and PCA9553. | 159 | devices include PCA9550, PCA9551, PCA9552, and PCA9553. |
159 | 160 | ||
161 | config LEDS_DA903X | ||
162 | tristate "LED Support for DA9030/DA9034 PMIC" | ||
163 | depends on LEDS_CLASS && PMIC_DA903X | ||
164 | help | ||
165 | This option enables support for on-chip LED drivers found | ||
166 | on Dialog Semiconductor DA9030/DA9034 PMICs. | ||
167 | |||
160 | comment "LED Triggers" | 168 | comment "LED Triggers" |
161 | 169 | ||
162 | config LEDS_TRIGGERS | 170 | config LEDS_TRIGGERS |
@@ -193,6 +201,15 @@ config LEDS_TRIGGER_HEARTBEAT | |||
193 | load average. | 201 | load average. |
194 | If unsure, say Y. | 202 | If unsure, say Y. |
195 | 203 | ||
204 | config LEDS_TRIGGER_BACKLIGHT | ||
205 | tristate "LED backlight Trigger" | ||
206 | depends on LEDS_TRIGGERS | ||
207 | help | ||
208 | This allows LEDs to be controlled as a backlight device: they | ||
209 | turn off and on when the display is blanked and unblanked. | ||
210 | |||
211 | If unsure, say N. | ||
212 | |||
196 | config LEDS_TRIGGER_DEFAULT_ON | 213 | config LEDS_TRIGGER_DEFAULT_ON |
197 | tristate "LED Default ON Trigger" | 214 | tristate "LED Default ON Trigger" |
198 | depends on LEDS_TRIGGERS | 215 | depends on LEDS_TRIGGERS |
diff --git a/drivers/leds/Makefile b/drivers/leds/Makefile index eb186c351a1c..e1967a29850e 100644 --- a/drivers/leds/Makefile +++ b/drivers/leds/Makefile | |||
@@ -17,14 +17,16 @@ obj-$(CONFIG_LEDS_COBALT_RAQ) += leds-cobalt-raq.o | |||
17 | obj-$(CONFIG_LEDS_SUNFIRE) += leds-sunfire.o | 17 | obj-$(CONFIG_LEDS_SUNFIRE) += leds-sunfire.o |
18 | obj-$(CONFIG_LEDS_PCA9532) += leds-pca9532.o | 18 | obj-$(CONFIG_LEDS_PCA9532) += leds-pca9532.o |
19 | obj-$(CONFIG_LEDS_GPIO) += leds-gpio.o | 19 | obj-$(CONFIG_LEDS_GPIO) += leds-gpio.o |
20 | obj-$(CONFIG_LEDS_CM_X270) += leds-cm-x270.o | ||
21 | obj-$(CONFIG_LEDS_CLEVO_MAIL) += leds-clevo-mail.o | 20 | obj-$(CONFIG_LEDS_CLEVO_MAIL) += leds-clevo-mail.o |
22 | obj-$(CONFIG_LEDS_HP6XX) += leds-hp6xx.o | 21 | obj-$(CONFIG_LEDS_HP6XX) += leds-hp6xx.o |
23 | obj-$(CONFIG_LEDS_FSG) += leds-fsg.o | 22 | obj-$(CONFIG_LEDS_FSG) += leds-fsg.o |
24 | obj-$(CONFIG_LEDS_PCA955X) += leds-pca955x.o | 23 | obj-$(CONFIG_LEDS_PCA955X) += leds-pca955x.o |
24 | obj-$(CONFIG_LEDS_DA903X) += leds-da903x.o | ||
25 | obj-$(CONFIG_LEDS_HP_DISK) += leds-hp-disk.o | ||
25 | 26 | ||
26 | # LED Triggers | 27 | # LED Triggers |
27 | obj-$(CONFIG_LEDS_TRIGGER_TIMER) += ledtrig-timer.o | 28 | obj-$(CONFIG_LEDS_TRIGGER_TIMER) += ledtrig-timer.o |
28 | obj-$(CONFIG_LEDS_TRIGGER_IDE_DISK) += ledtrig-ide-disk.o | 29 | obj-$(CONFIG_LEDS_TRIGGER_IDE_DISK) += ledtrig-ide-disk.o |
29 | obj-$(CONFIG_LEDS_TRIGGER_HEARTBEAT) += ledtrig-heartbeat.o | 30 | obj-$(CONFIG_LEDS_TRIGGER_HEARTBEAT) += ledtrig-heartbeat.o |
31 | obj-$(CONFIG_LEDS_TRIGGER_BACKLIGHT) += ledtrig-backlight.o | ||
30 | obj-$(CONFIG_LEDS_TRIGGER_DEFAULT_ON) += ledtrig-default-on.o | 32 | obj-$(CONFIG_LEDS_TRIGGER_DEFAULT_ON) += ledtrig-default-on.o |
diff --git a/drivers/leds/led-class.c b/drivers/leds/led-class.c index ee74ee7b2acc..6c4a326176d7 100644 --- a/drivers/leds/led-class.c +++ b/drivers/leds/led-class.c | |||
@@ -34,14 +34,11 @@ static ssize_t led_brightness_show(struct device *dev, | |||
34 | struct device_attribute *attr, char *buf) | 34 | struct device_attribute *attr, char *buf) |
35 | { | 35 | { |
36 | struct led_classdev *led_cdev = dev_get_drvdata(dev); | 36 | struct led_classdev *led_cdev = dev_get_drvdata(dev); |
37 | ssize_t ret = 0; | ||
38 | 37 | ||
39 | /* no lock needed for this */ | 38 | /* no lock needed for this */ |
40 | led_update_brightness(led_cdev); | 39 | led_update_brightness(led_cdev); |
41 | sprintf(buf, "%u\n", led_cdev->brightness); | ||
42 | ret = strlen(buf) + 1; | ||
43 | 40 | ||
44 | return ret; | 41 | return sprintf(buf, "%u\n", led_cdev->brightness); |
45 | } | 42 | } |
46 | 43 | ||
47 | static ssize_t led_brightness_store(struct device *dev, | 44 | static ssize_t led_brightness_store(struct device *dev, |
@@ -113,6 +110,9 @@ int led_classdev_register(struct device *parent, struct led_classdev *led_cdev) | |||
113 | if (rc) | 110 | if (rc) |
114 | goto err_out; | 111 | goto err_out; |
115 | 112 | ||
113 | #ifdef CONFIG_LEDS_TRIGGERS | ||
114 | init_rwsem(&led_cdev->trigger_lock); | ||
115 | #endif | ||
116 | /* add to the list of leds */ | 116 | /* add to the list of leds */ |
117 | down_write(&leds_list_lock); | 117 | down_write(&leds_list_lock); |
118 | list_add_tail(&led_cdev->node, &leds_list); | 118 | list_add_tail(&led_cdev->node, &leds_list); |
@@ -121,8 +121,6 @@ int led_classdev_register(struct device *parent, struct led_classdev *led_cdev) | |||
121 | led_update_brightness(led_cdev); | 121 | led_update_brightness(led_cdev); |
122 | 122 | ||
123 | #ifdef CONFIG_LEDS_TRIGGERS | 123 | #ifdef CONFIG_LEDS_TRIGGERS |
124 | init_rwsem(&led_cdev->trigger_lock); | ||
125 | |||
126 | rc = device_create_file(led_cdev->dev, &dev_attr_trigger); | 124 | rc = device_create_file(led_cdev->dev, &dev_attr_trigger); |
127 | if (rc) | 125 | if (rc) |
128 | goto err_out_led_list; | 126 | goto err_out_led_list; |
@@ -147,7 +145,7 @@ err_out: | |||
147 | EXPORT_SYMBOL_GPL(led_classdev_register); | 145 | EXPORT_SYMBOL_GPL(led_classdev_register); |
148 | 146 | ||
149 | /** | 147 | /** |
150 | * __led_classdev_unregister - unregisters a object of led_properties class. | 148 | * led_classdev_unregister - unregisters a object of led_properties class. |
151 | * @led_cdev: the led device to unregister | 149 | * @led_cdev: the led device to unregister |
152 | * | 150 | * |
153 | * Unregisters a previously registered via led_classdev_register object. | 151 | * Unregisters a previously registered via led_classdev_register object. |
diff --git a/drivers/leds/leds-ams-delta.c b/drivers/leds/leds-ams-delta.c index 32c98b2efa3f..1bd590bb3a6e 100644 --- a/drivers/leds/leds-ams-delta.c +++ b/drivers/leds/leds-ams-delta.c | |||
@@ -107,27 +107,27 @@ static int ams_delta_led_resume(struct platform_device *dev) | |||
107 | 107 | ||
108 | static int ams_delta_led_probe(struct platform_device *pdev) | 108 | static int ams_delta_led_probe(struct platform_device *pdev) |
109 | { | 109 | { |
110 | int i; | 110 | int i, ret; |
111 | int ret; | ||
112 | 111 | ||
113 | for (i = ret = 0; ret >= 0 && i < ARRAY_SIZE(ams_delta_leds); i++) { | 112 | for (i = 0; i < ARRAY_SIZE(ams_delta_leds); i++) { |
114 | ret = led_classdev_register(&pdev->dev, | 113 | ret = led_classdev_register(&pdev->dev, |
115 | &ams_delta_leds[i].cdev); | 114 | &ams_delta_leds[i].cdev); |
115 | if (ret < 0) | ||
116 | goto fail; | ||
116 | } | 117 | } |
117 | 118 | ||
118 | if (ret < 0 && i > 1) { | 119 | return 0; |
119 | for (i = i - 2; i >= 0; i--) | 120 | fail: |
120 | led_classdev_unregister(&ams_delta_leds[i].cdev); | 121 | while (--i >= 0) |
121 | } | 122 | led_classdev_unregister(&ams_delta_leds[i].cdev); |
122 | 123 | return ret; | |
123 | return ret; | ||
124 | } | 124 | } |
125 | 125 | ||
126 | static int ams_delta_led_remove(struct platform_device *pdev) | 126 | static int ams_delta_led_remove(struct platform_device *pdev) |
127 | { | 127 | { |
128 | int i; | 128 | int i; |
129 | 129 | ||
130 | for (i = ARRAY_SIZE(ams_delta_leds) - 1; i >= 0; i--) | 130 | for (i = 0; i < ARRAY_SIZE(ams_delta_leds); i--) |
131 | led_classdev_unregister(&ams_delta_leds[i].cdev); | 131 | led_classdev_unregister(&ams_delta_leds[i].cdev); |
132 | 132 | ||
133 | return 0; | 133 | return 0; |
diff --git a/drivers/leds/leds-cm-x270.c b/drivers/leds/leds-cm-x270.c deleted file mode 100644 index 836a43d776e6..000000000000 --- a/drivers/leds/leds-cm-x270.c +++ /dev/null | |||
@@ -1,124 +0,0 @@ | |||
1 | /* | ||
2 | * drivers/leds/leds-cm-x270.c | ||
3 | * | ||
4 | * Copyright 2007 CompuLab Ltd. | ||
5 | * Author: Mike Rapoport <mike@compulab.co.il> | ||
6 | * | ||
7 | * Based on leds-corgi.c | ||
8 | * Author: Richard Purdie <rpurdie@openedhand.com> | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License version 2 as | ||
12 | * published by the Free Software Foundation. | ||
13 | * | ||
14 | */ | ||
15 | |||
16 | #include <linux/kernel.h> | ||
17 | #include <linux/init.h> | ||
18 | #include <linux/platform_device.h> | ||
19 | #include <linux/leds.h> | ||
20 | |||
21 | #include <mach/hardware.h> | ||
22 | #include <mach/pxa-regs.h> | ||
23 | |||
24 | #define GPIO_RED_LED (93) | ||
25 | #define GPIO_GREEN_LED (94) | ||
26 | |||
27 | static void cmx270_red_set(struct led_classdev *led_cdev, | ||
28 | enum led_brightness value) | ||
29 | { | ||
30 | if (value) | ||
31 | GPCR(GPIO_RED_LED) = GPIO_bit(GPIO_RED_LED); | ||
32 | else | ||
33 | GPSR(GPIO_RED_LED) = GPIO_bit(GPIO_RED_LED); | ||
34 | } | ||
35 | |||
36 | static void cmx270_green_set(struct led_classdev *led_cdev, | ||
37 | enum led_brightness value) | ||
38 | { | ||
39 | if (value) | ||
40 | GPCR(GPIO_GREEN_LED) = GPIO_bit(GPIO_GREEN_LED); | ||
41 | else | ||
42 | GPSR(GPIO_GREEN_LED) = GPIO_bit(GPIO_GREEN_LED); | ||
43 | } | ||
44 | |||
45 | static struct led_classdev cmx270_red_led = { | ||
46 | .name = "cm-x270:red", | ||
47 | .default_trigger = "nand-disk", | ||
48 | .brightness_set = cmx270_red_set, | ||
49 | }; | ||
50 | |||
51 | static struct led_classdev cmx270_green_led = { | ||
52 | .name = "cm-x270:green", | ||
53 | .default_trigger = "heartbeat", | ||
54 | .brightness_set = cmx270_green_set, | ||
55 | }; | ||
56 | |||
57 | #ifdef CONFIG_PM | ||
58 | static int cmx270led_suspend(struct platform_device *dev, pm_message_t state) | ||
59 | { | ||
60 | led_classdev_suspend(&cmx270_red_led); | ||
61 | led_classdev_suspend(&cmx270_green_led); | ||
62 | return 0; | ||
63 | } | ||
64 | |||
65 | static int cmx270led_resume(struct platform_device *dev) | ||
66 | { | ||
67 | led_classdev_resume(&cmx270_red_led); | ||
68 | led_classdev_resume(&cmx270_green_led); | ||
69 | return 0; | ||
70 | } | ||
71 | #endif | ||
72 | |||
73 | static int cmx270led_probe(struct platform_device *pdev) | ||
74 | { | ||
75 | int ret; | ||
76 | |||
77 | ret = led_classdev_register(&pdev->dev, &cmx270_red_led); | ||
78 | if (ret < 0) | ||
79 | return ret; | ||
80 | |||
81 | ret = led_classdev_register(&pdev->dev, &cmx270_green_led); | ||
82 | if (ret < 0) | ||
83 | led_classdev_unregister(&cmx270_red_led); | ||
84 | |||
85 | return ret; | ||
86 | } | ||
87 | |||
88 | static int cmx270led_remove(struct platform_device *pdev) | ||
89 | { | ||
90 | led_classdev_unregister(&cmx270_red_led); | ||
91 | led_classdev_unregister(&cmx270_green_led); | ||
92 | return 0; | ||
93 | } | ||
94 | |||
95 | static struct platform_driver cmx270led_driver = { | ||
96 | .probe = cmx270led_probe, | ||
97 | .remove = cmx270led_remove, | ||
98 | #ifdef CONFIG_PM | ||
99 | .suspend = cmx270led_suspend, | ||
100 | .resume = cmx270led_resume, | ||
101 | #endif | ||
102 | .driver = { | ||
103 | .name = "cm-x270-led", | ||
104 | .owner = THIS_MODULE, | ||
105 | }, | ||
106 | }; | ||
107 | |||
108 | static int __init cmx270led_init(void) | ||
109 | { | ||
110 | return platform_driver_register(&cmx270led_driver); | ||
111 | } | ||
112 | |||
113 | static void __exit cmx270led_exit(void) | ||
114 | { | ||
115 | platform_driver_unregister(&cmx270led_driver); | ||
116 | } | ||
117 | |||
118 | module_init(cmx270led_init); | ||
119 | module_exit(cmx270led_exit); | ||
120 | |||
121 | MODULE_AUTHOR("Mike Rapoport <mike@compulab.co.il>"); | ||
122 | MODULE_DESCRIPTION("CM-x270 LED driver"); | ||
123 | MODULE_LICENSE("GPL"); | ||
124 | MODULE_ALIAS("platform:cm-x270-led"); | ||
diff --git a/drivers/leds/leds-da903x.c b/drivers/leds/leds-da903x.c new file mode 100644 index 000000000000..2768c69257f6 --- /dev/null +++ b/drivers/leds/leds-da903x.c | |||
@@ -0,0 +1,176 @@ | |||
1 | /* | ||
2 | * LEDs driver for Dialog Semiconductor DA9030/DA9034 | ||
3 | * | ||
4 | * Copyright (C) 2008 Compulab, Ltd. | ||
5 | * Mike Rapoport <mike@compulab.co.il> | ||
6 | * | ||
7 | * Copyright (C) 2006-2008 Marvell International Ltd. | ||
8 | * Eric Miao <eric.miao@marvell.com> | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License version 2 as | ||
12 | * published by the Free Software Foundation. | ||
13 | */ | ||
14 | |||
15 | #include <linux/module.h> | ||
16 | #include <linux/kernel.h> | ||
17 | #include <linux/init.h> | ||
18 | #include <linux/platform_device.h> | ||
19 | #include <linux/leds.h> | ||
20 | #include <linux/workqueue.h> | ||
21 | #include <linux/mfd/da903x.h> | ||
22 | |||
23 | #define DA9030_LED1_CONTROL 0x20 | ||
24 | #define DA9030_LED2_CONTROL 0x21 | ||
25 | #define DA9030_LED3_CONTROL 0x22 | ||
26 | #define DA9030_LED4_CONTROL 0x23 | ||
27 | #define DA9030_LEDPC_CONTROL 0x24 | ||
28 | #define DA9030_MISC_CONTROL_A 0x26 /* Vibrator Control */ | ||
29 | |||
30 | #define DA9034_LED1_CONTROL 0x35 | ||
31 | #define DA9034_LED2_CONTROL 0x36 | ||
32 | #define DA9034_VIBRA 0x40 | ||
33 | |||
34 | struct da903x_led { | ||
35 | struct led_classdev cdev; | ||
36 | struct work_struct work; | ||
37 | struct device *master; | ||
38 | enum led_brightness new_brightness; | ||
39 | int id; | ||
40 | int flags; | ||
41 | }; | ||
42 | |||
43 | #define DA9030_LED_OFFSET(id) ((id) - DA9030_ID_LED_1) | ||
44 | #define DA9034_LED_OFFSET(id) ((id) - DA9034_ID_LED_1) | ||
45 | |||
46 | static void da903x_led_work(struct work_struct *work) | ||
47 | { | ||
48 | struct da903x_led *led = container_of(work, struct da903x_led, work); | ||
49 | uint8_t val; | ||
50 | int offset; | ||
51 | |||
52 | switch (led->id) { | ||
53 | case DA9030_ID_LED_1: | ||
54 | case DA9030_ID_LED_2: | ||
55 | case DA9030_ID_LED_3: | ||
56 | case DA9030_ID_LED_4: | ||
57 | case DA9030_ID_LED_PC: | ||
58 | offset = DA9030_LED_OFFSET(led->id); | ||
59 | val = led->flags & ~0x87; | ||
60 | val |= (led->new_brightness) ? 0x80 : 0; /* EN bit */ | ||
61 | val |= (led->new_brightness >> 5) & 0x7; /* PWM<2:0> */ | ||
62 | da903x_write(led->master, DA9030_LED1_CONTROL + offset, val); | ||
63 | break; | ||
64 | case DA9030_ID_VIBRA: | ||
65 | val = led->flags & ~0x80; | ||
66 | val |= (led->new_brightness) ? 0x80 : 0; /* EN bit */ | ||
67 | da903x_write(led->master, DA9030_MISC_CONTROL_A, val); | ||
68 | break; | ||
69 | case DA9034_ID_LED_1: | ||
70 | case DA9034_ID_LED_2: | ||
71 | offset = DA9034_LED_OFFSET(led->id); | ||
72 | val = (led->new_brightness * 0x5f / LED_FULL) & 0x7f; | ||
73 | val |= (led->flags & DA9034_LED_RAMP) ? 0x80 : 0; | ||
74 | da903x_write(led->master, DA9034_LED1_CONTROL + offset, val); | ||
75 | break; | ||
76 | case DA9034_ID_VIBRA: | ||
77 | val = led->new_brightness & 0xfe; | ||
78 | da903x_write(led->master, DA9034_VIBRA, val); | ||
79 | break; | ||
80 | } | ||
81 | } | ||
82 | |||
83 | static void da903x_led_set(struct led_classdev *led_cdev, | ||
84 | enum led_brightness value) | ||
85 | { | ||
86 | struct da903x_led *led; | ||
87 | |||
88 | led = container_of(led_cdev, struct da903x_led, cdev); | ||
89 | led->new_brightness = value; | ||
90 | schedule_work(&led->work); | ||
91 | } | ||
92 | |||
93 | static int __devinit da903x_led_probe(struct platform_device *pdev) | ||
94 | { | ||
95 | struct led_info *pdata = pdev->dev.platform_data; | ||
96 | struct da903x_led *led; | ||
97 | int id, ret; | ||
98 | |||
99 | if (pdata == NULL) | ||
100 | return 0; | ||
101 | |||
102 | id = pdev->id; | ||
103 | |||
104 | if (!((id >= DA9030_ID_LED_1 && id <= DA9030_ID_VIBRA) || | ||
105 | (id >= DA9034_ID_LED_1 && id <= DA9034_ID_VIBRA))) { | ||
106 | dev_err(&pdev->dev, "invalid LED ID (%d) specified\n", id); | ||
107 | return -EINVAL; | ||
108 | } | ||
109 | |||
110 | led = kzalloc(sizeof(struct da903x_led), GFP_KERNEL); | ||
111 | if (led == NULL) { | ||
112 | dev_err(&pdev->dev, "failed to alloc memory for LED%d\n", id); | ||
113 | return -ENOMEM; | ||
114 | } | ||
115 | |||
116 | led->cdev.name = pdata->name; | ||
117 | led->cdev.default_trigger = pdata->default_trigger; | ||
118 | led->cdev.brightness_set = da903x_led_set; | ||
119 | led->cdev.brightness = LED_OFF; | ||
120 | |||
121 | led->id = id; | ||
122 | led->flags = pdata->flags; | ||
123 | led->master = pdev->dev.parent; | ||
124 | led->new_brightness = LED_OFF; | ||
125 | |||
126 | INIT_WORK(&led->work, da903x_led_work); | ||
127 | |||
128 | ret = led_classdev_register(led->master, &led->cdev); | ||
129 | if (ret) { | ||
130 | dev_err(&pdev->dev, "failed to register LED %d\n", id); | ||
131 | goto err; | ||
132 | } | ||
133 | |||
134 | platform_set_drvdata(pdev, led); | ||
135 | return 0; | ||
136 | |||
137 | err: | ||
138 | kfree(led); | ||
139 | return ret; | ||
140 | } | ||
141 | |||
142 | static int __devexit da903x_led_remove(struct platform_device *pdev) | ||
143 | { | ||
144 | struct da903x_led *led = platform_get_drvdata(pdev); | ||
145 | |||
146 | led_classdev_unregister(&led->cdev); | ||
147 | kfree(led); | ||
148 | return 0; | ||
149 | } | ||
150 | |||
151 | static struct platform_driver da903x_led_driver = { | ||
152 | .driver = { | ||
153 | .name = "da903x-led", | ||
154 | .owner = THIS_MODULE, | ||
155 | }, | ||
156 | .probe = da903x_led_probe, | ||
157 | .remove = __devexit_p(da903x_led_remove), | ||
158 | }; | ||
159 | |||
160 | static int __init da903x_led_init(void) | ||
161 | { | ||
162 | return platform_driver_register(&da903x_led_driver); | ||
163 | } | ||
164 | module_init(da903x_led_init); | ||
165 | |||
166 | static void __exit da903x_led_exit(void) | ||
167 | { | ||
168 | platform_driver_unregister(&da903x_led_driver); | ||
169 | } | ||
170 | module_exit(da903x_led_exit); | ||
171 | |||
172 | MODULE_DESCRIPTION("LEDs driver for Dialog Semiconductor DA9030/DA9034"); | ||
173 | MODULE_AUTHOR("Eric Miao <eric.miao@marvell.com>" | ||
174 | "Mike Rapoport <mike@compulab.co.il>"); | ||
175 | MODULE_LICENSE("GPL"); | ||
176 | MODULE_ALIAS("platform:da903x-led"); | ||
diff --git a/drivers/leds/leds-hp-disk.c b/drivers/leds/leds-hp-disk.c new file mode 100644 index 000000000000..74645ab15660 --- /dev/null +++ b/drivers/leds/leds-hp-disk.c | |||
@@ -0,0 +1,156 @@ | |||
1 | /* | ||
2 | * leds-hp-disk.c - driver for HP "hard disk protection" LED | ||
3 | * | ||
4 | * Copyright (C) 2008 Pavel Machek | ||
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 as published by | ||
8 | * the Free Software Foundation; either version 2 of the License, or | ||
9 | * (at your option) any later version. | ||
10 | * | ||
11 | * This program is distributed in the hope that it will be useful, | ||
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
14 | * GNU General Public License for more details. | ||
15 | * | ||
16 | * You should have received a copy of the GNU General Public License | ||
17 | * along with this program; if not, write to the Free Software | ||
18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
19 | */ | ||
20 | |||
21 | #include <linux/kernel.h> | ||
22 | #include <linux/init.h> | ||
23 | #include <linux/dmi.h> | ||
24 | #include <linux/module.h> | ||
25 | #include <linux/types.h> | ||
26 | #include <linux/platform_device.h> | ||
27 | #include <linux/interrupt.h> | ||
28 | #include <linux/input.h> | ||
29 | #include <linux/kthread.h> | ||
30 | #include <linux/version.h> | ||
31 | #include <linux/leds.h> | ||
32 | #include <acpi/acpi_drivers.h> | ||
33 | |||
34 | #define DRIVER_NAME "leds-hp-disk" | ||
35 | #define ACPI_MDPS_CLASS "led" | ||
36 | |||
37 | /* For automatic insertion of the module */ | ||
38 | static struct acpi_device_id hpled_device_ids[] = { | ||
39 | {"HPQ0004", 0}, /* HP Mobile Data Protection System PNP */ | ||
40 | {"", 0}, | ||
41 | }; | ||
42 | MODULE_DEVICE_TABLE(acpi, hpled_device_ids); | ||
43 | |||
44 | struct acpi_hpled { | ||
45 | struct acpi_device *device; /* The ACPI device */ | ||
46 | }; | ||
47 | |||
48 | static struct acpi_hpled adev; | ||
49 | |||
50 | static acpi_status hpled_acpi_write(acpi_handle handle, int reg) | ||
51 | { | ||
52 | unsigned long long ret; /* Not used when writing */ | ||
53 | union acpi_object in_obj[1]; | ||
54 | struct acpi_object_list args = { 1, in_obj }; | ||
55 | |||
56 | in_obj[0].type = ACPI_TYPE_INTEGER; | ||
57 | in_obj[0].integer.value = reg; | ||
58 | |||
59 | return acpi_evaluate_integer(handle, "ALED", &args, &ret); | ||
60 | } | ||
61 | |||
62 | static void hpled_set(struct led_classdev *led_cdev, | ||
63 | enum led_brightness value) | ||
64 | { | ||
65 | hpled_acpi_write(adev.device->handle, !!value); | ||
66 | } | ||
67 | |||
68 | static struct led_classdev hpled_led = { | ||
69 | .name = "hp:red:hddprotection", | ||
70 | .default_trigger = "heartbeat", | ||
71 | .brightness_set = hpled_set, | ||
72 | }; | ||
73 | |||
74 | #ifdef CONFIG_PM | ||
75 | static int hpled_suspend(struct acpi_device *dev, pm_message_t state) | ||
76 | { | ||
77 | led_classdev_suspend(&hpled_led); | ||
78 | return 0; | ||
79 | } | ||
80 | |||
81 | static int hpled_resume(struct acpi_device *dev) | ||
82 | { | ||
83 | led_classdev_resume(&hpled_led); | ||
84 | return 0; | ||
85 | } | ||
86 | #else | ||
87 | #define hpled_suspend NULL | ||
88 | #define hpled_resume NULL | ||
89 | #endif | ||
90 | |||
91 | static int hpled_add(struct acpi_device *device) | ||
92 | { | ||
93 | int ret; | ||
94 | |||
95 | if (!device) | ||
96 | return -EINVAL; | ||
97 | |||
98 | adev.device = device; | ||
99 | strcpy(acpi_device_name(device), DRIVER_NAME); | ||
100 | strcpy(acpi_device_class(device), ACPI_MDPS_CLASS); | ||
101 | device->driver_data = &adev; | ||
102 | |||
103 | ret = led_classdev_register(NULL, &hpled_led); | ||
104 | return ret; | ||
105 | } | ||
106 | |||
107 | static int hpled_remove(struct acpi_device *device, int type) | ||
108 | { | ||
109 | if (!device) | ||
110 | return -EINVAL; | ||
111 | |||
112 | led_classdev_unregister(&hpled_led); | ||
113 | return 0; | ||
114 | } | ||
115 | |||
116 | |||
117 | |||
118 | static struct acpi_driver leds_hp_driver = { | ||
119 | .name = DRIVER_NAME, | ||
120 | .class = ACPI_MDPS_CLASS, | ||
121 | .ids = hpled_device_ids, | ||
122 | .ops = { | ||
123 | .add = hpled_add, | ||
124 | .remove = hpled_remove, | ||
125 | .suspend = hpled_suspend, | ||
126 | .resume = hpled_resume, | ||
127 | } | ||
128 | }; | ||
129 | |||
130 | static int __init hpled_init_module(void) | ||
131 | { | ||
132 | int ret; | ||
133 | |||
134 | if (acpi_disabled) | ||
135 | return -ENODEV; | ||
136 | |||
137 | ret = acpi_bus_register_driver(&leds_hp_driver); | ||
138 | if (ret < 0) | ||
139 | return ret; | ||
140 | |||
141 | printk(KERN_INFO DRIVER_NAME " driver loaded.\n"); | ||
142 | |||
143 | return 0; | ||
144 | } | ||
145 | |||
146 | static void __exit hpled_exit_module(void) | ||
147 | { | ||
148 | acpi_bus_unregister_driver(&leds_hp_driver); | ||
149 | } | ||
150 | |||
151 | MODULE_DESCRIPTION("Driver for HP disk protection LED"); | ||
152 | MODULE_AUTHOR("Pavel Machek <pavel@suse.cz>"); | ||
153 | MODULE_LICENSE("GPL"); | ||
154 | |||
155 | module_init(hpled_init_module); | ||
156 | module_exit(hpled_exit_module); | ||
diff --git a/drivers/leds/leds-pca955x.c b/drivers/leds/leds-pca955x.c index f508729123b5..4e2d1a42b48f 100644 --- a/drivers/leds/leds-pca955x.c +++ b/drivers/leds/leds-pca955x.c | |||
@@ -226,7 +226,7 @@ static void pca955x_led_work(struct work_struct *work) | |||
226 | pca955x_write_ls(pca955x->client, chip_ls, ls); | 226 | pca955x_write_ls(pca955x->client, chip_ls, ls); |
227 | } | 227 | } |
228 | 228 | ||
229 | void pca955x_led_set(struct led_classdev *led_cdev, enum led_brightness value) | 229 | static void pca955x_led_set(struct led_classdev *led_cdev, enum led_brightness value) |
230 | { | 230 | { |
231 | struct pca955x_led *pca955x; | 231 | struct pca955x_led *pca955x; |
232 | 232 | ||
diff --git a/drivers/leds/leds-wrap.c b/drivers/leds/leds-wrap.c index 7ac61a7b56ad..2f3aa87f2a1f 100644 --- a/drivers/leds/leds-wrap.c +++ b/drivers/leds/leds-wrap.c | |||
@@ -53,8 +53,9 @@ static void wrap_extra_led_set(struct led_classdev *led_cdev, | |||
53 | } | 53 | } |
54 | 54 | ||
55 | static struct led_classdev wrap_power_led = { | 55 | static struct led_classdev wrap_power_led = { |
56 | .name = "wrap::power", | 56 | .name = "wrap::power", |
57 | .brightness_set = wrap_power_led_set, | 57 | .brightness_set = wrap_power_led_set, |
58 | .default_trigger = "default-on", | ||
58 | }; | 59 | }; |
59 | 60 | ||
60 | static struct led_classdev wrap_error_led = { | 61 | static struct led_classdev wrap_error_led = { |
diff --git a/drivers/leds/ledtrig-backlight.c b/drivers/leds/ledtrig-backlight.c new file mode 100644 index 000000000000..d3dfcfb417b8 --- /dev/null +++ b/drivers/leds/ledtrig-backlight.c | |||
@@ -0,0 +1,110 @@ | |||
1 | /* | ||
2 | * Backlight emulation LED trigger | ||
3 | * | ||
4 | * Copyright 2008 (C) Rodolfo Giometti <giometti@linux.it> | ||
5 | * Copyright 2008 (C) Eurotech S.p.A. <info@eurotech.it> | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License version 2 as | ||
9 | * published by the Free Software Foundation. | ||
10 | * | ||
11 | */ | ||
12 | |||
13 | #include <linux/module.h> | ||
14 | #include <linux/kernel.h> | ||
15 | #include <linux/init.h> | ||
16 | #include <linux/fb.h> | ||
17 | #include <linux/leds.h> | ||
18 | #include "leds.h" | ||
19 | |||
20 | #define BLANK 1 | ||
21 | #define UNBLANK 0 | ||
22 | |||
23 | struct bl_trig_notifier { | ||
24 | struct led_classdev *led; | ||
25 | int brightness; | ||
26 | int old_status; | ||
27 | struct notifier_block notifier; | ||
28 | }; | ||
29 | |||
30 | static int fb_notifier_callback(struct notifier_block *p, | ||
31 | unsigned long event, void *data) | ||
32 | { | ||
33 | struct bl_trig_notifier *n = container_of(p, | ||
34 | struct bl_trig_notifier, notifier); | ||
35 | struct led_classdev *led = n->led; | ||
36 | struct fb_event *fb_event = data; | ||
37 | int *blank = fb_event->data; | ||
38 | |||
39 | switch (event) { | ||
40 | case FB_EVENT_BLANK : | ||
41 | if (*blank && n->old_status == UNBLANK) { | ||
42 | n->brightness = led->brightness; | ||
43 | led_set_brightness(led, LED_OFF); | ||
44 | n->old_status = BLANK; | ||
45 | } else if (!*blank && n->old_status == BLANK) { | ||
46 | led_set_brightness(led, n->brightness); | ||
47 | n->old_status = UNBLANK; | ||
48 | } | ||
49 | break; | ||
50 | } | ||
51 | |||
52 | return 0; | ||
53 | } | ||
54 | |||
55 | static void bl_trig_activate(struct led_classdev *led) | ||
56 | { | ||
57 | int ret; | ||
58 | |||
59 | struct bl_trig_notifier *n; | ||
60 | |||
61 | n = kzalloc(sizeof(struct bl_trig_notifier), GFP_KERNEL); | ||
62 | led->trigger_data = n; | ||
63 | if (!n) { | ||
64 | dev_err(led->dev, "unable to allocate backlight trigger\n"); | ||
65 | return; | ||
66 | } | ||
67 | |||
68 | n->led = led; | ||
69 | n->brightness = led->brightness; | ||
70 | n->old_status = UNBLANK; | ||
71 | n->notifier.notifier_call = fb_notifier_callback; | ||
72 | |||
73 | ret = fb_register_client(&n->notifier); | ||
74 | if (ret) | ||
75 | dev_err(led->dev, "unable to register backlight trigger\n"); | ||
76 | } | ||
77 | |||
78 | static void bl_trig_deactivate(struct led_classdev *led) | ||
79 | { | ||
80 | struct bl_trig_notifier *n = | ||
81 | (struct bl_trig_notifier *) led->trigger_data; | ||
82 | |||
83 | if (n) { | ||
84 | fb_unregister_client(&n->notifier); | ||
85 | kfree(n); | ||
86 | } | ||
87 | } | ||
88 | |||
89 | static struct led_trigger bl_led_trigger = { | ||
90 | .name = "backlight", | ||
91 | .activate = bl_trig_activate, | ||
92 | .deactivate = bl_trig_deactivate | ||
93 | }; | ||
94 | |||
95 | static int __init bl_trig_init(void) | ||
96 | { | ||
97 | return led_trigger_register(&bl_led_trigger); | ||
98 | } | ||
99 | |||
100 | static void __exit bl_trig_exit(void) | ||
101 | { | ||
102 | led_trigger_unregister(&bl_led_trigger); | ||
103 | } | ||
104 | |||
105 | module_init(bl_trig_init); | ||
106 | module_exit(bl_trig_exit); | ||
107 | |||
108 | MODULE_AUTHOR("Rodolfo Giometti <giometti@linux.it>"); | ||
109 | MODULE_DESCRIPTION("Backlight emulation LED trigger"); | ||
110 | MODULE_LICENSE("GPL v2"); | ||
diff --git a/drivers/leds/ledtrig-timer.c b/drivers/leds/ledtrig-timer.c index 5c99f4f0c692..db681962d7bb 100644 --- a/drivers/leds/ledtrig-timer.c +++ b/drivers/leds/ledtrig-timer.c | |||
@@ -70,9 +70,7 @@ static ssize_t led_delay_on_show(struct device *dev, | |||
70 | struct led_classdev *led_cdev = dev_get_drvdata(dev); | 70 | struct led_classdev *led_cdev = dev_get_drvdata(dev); |
71 | struct timer_trig_data *timer_data = led_cdev->trigger_data; | 71 | struct timer_trig_data *timer_data = led_cdev->trigger_data; |
72 | 72 | ||
73 | sprintf(buf, "%lu\n", timer_data->delay_on); | 73 | return sprintf(buf, "%lu\n", timer_data->delay_on); |
74 | |||
75 | return strlen(buf) + 1; | ||
76 | } | 74 | } |
77 | 75 | ||
78 | static ssize_t led_delay_on_store(struct device *dev, | 76 | static ssize_t led_delay_on_store(struct device *dev, |
@@ -116,9 +114,7 @@ static ssize_t led_delay_off_show(struct device *dev, | |||
116 | struct led_classdev *led_cdev = dev_get_drvdata(dev); | 114 | struct led_classdev *led_cdev = dev_get_drvdata(dev); |
117 | struct timer_trig_data *timer_data = led_cdev->trigger_data; | 115 | struct timer_trig_data *timer_data = led_cdev->trigger_data; |
118 | 116 | ||
119 | sprintf(buf, "%lu\n", timer_data->delay_off); | 117 | return sprintf(buf, "%lu\n", timer_data->delay_off); |
120 | |||
121 | return strlen(buf) + 1; | ||
122 | } | 118 | } |
123 | 119 | ||
124 | static ssize_t led_delay_off_store(struct device *dev, | 120 | static ssize_t led_delay_off_store(struct device *dev, |
diff --git a/drivers/md/md.c b/drivers/md/md.c index c1a837ca193c..b4162f6f1b79 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c | |||
@@ -222,6 +222,9 @@ static void mddev_put(mddev_t *mddev) | |||
222 | list_del(&mddev->all_mddevs); | 222 | list_del(&mddev->all_mddevs); |
223 | spin_unlock(&all_mddevs_lock); | 223 | spin_unlock(&all_mddevs_lock); |
224 | blk_cleanup_queue(mddev->queue); | 224 | blk_cleanup_queue(mddev->queue); |
225 | if (mddev->sysfs_state) | ||
226 | sysfs_put(mddev->sysfs_state); | ||
227 | mddev->sysfs_state = NULL; | ||
225 | kobject_put(&mddev->kobj); | 228 | kobject_put(&mddev->kobj); |
226 | } else | 229 | } else |
227 | spin_unlock(&all_mddevs_lock); | 230 | spin_unlock(&all_mddevs_lock); |
@@ -1459,6 +1462,8 @@ static int bind_rdev_to_array(mdk_rdev_t * rdev, mddev_t * mddev) | |||
1459 | kobject_del(&rdev->kobj); | 1462 | kobject_del(&rdev->kobj); |
1460 | goto fail; | 1463 | goto fail; |
1461 | } | 1464 | } |
1465 | rdev->sysfs_state = sysfs_get_dirent(rdev->kobj.sd, "state"); | ||
1466 | |||
1462 | list_add_rcu(&rdev->same_set, &mddev->disks); | 1467 | list_add_rcu(&rdev->same_set, &mddev->disks); |
1463 | bd_claim_by_disk(rdev->bdev, rdev->bdev->bd_holder, mddev->gendisk); | 1468 | bd_claim_by_disk(rdev->bdev, rdev->bdev->bd_holder, mddev->gendisk); |
1464 | return 0; | 1469 | return 0; |
@@ -1488,7 +1493,8 @@ static void unbind_rdev_from_array(mdk_rdev_t * rdev) | |||
1488 | printk(KERN_INFO "md: unbind<%s>\n", bdevname(rdev->bdev,b)); | 1493 | printk(KERN_INFO "md: unbind<%s>\n", bdevname(rdev->bdev,b)); |
1489 | rdev->mddev = NULL; | 1494 | rdev->mddev = NULL; |
1490 | sysfs_remove_link(&rdev->kobj, "block"); | 1495 | sysfs_remove_link(&rdev->kobj, "block"); |
1491 | 1496 | sysfs_put(rdev->sysfs_state); | |
1497 | rdev->sysfs_state = NULL; | ||
1492 | /* We need to delay this, otherwise we can deadlock when | 1498 | /* We need to delay this, otherwise we can deadlock when |
1493 | * writing to 'remove' to "dev/state". We also need | 1499 | * writing to 'remove' to "dev/state". We also need |
1494 | * to delay it due to rcu usage. | 1500 | * to delay it due to rcu usage. |
@@ -1923,8 +1929,8 @@ state_store(mdk_rdev_t *rdev, const char *buf, size_t len) | |||
1923 | 1929 | ||
1924 | err = 0; | 1930 | err = 0; |
1925 | } | 1931 | } |
1926 | if (!err) | 1932 | if (!err && rdev->sysfs_state) |
1927 | sysfs_notify(&rdev->kobj, NULL, "state"); | 1933 | sysfs_notify_dirent(rdev->sysfs_state); |
1928 | return err ? err : len; | 1934 | return err ? err : len; |
1929 | } | 1935 | } |
1930 | static struct rdev_sysfs_entry rdev_state = | 1936 | static struct rdev_sysfs_entry rdev_state = |
@@ -2019,7 +2025,7 @@ slot_store(mdk_rdev_t *rdev, const char *buf, size_t len) | |||
2019 | rdev->raid_disk = -1; | 2025 | rdev->raid_disk = -1; |
2020 | return err; | 2026 | return err; |
2021 | } else | 2027 | } else |
2022 | sysfs_notify(&rdev->kobj, NULL, "state"); | 2028 | sysfs_notify_dirent(rdev->sysfs_state); |
2023 | sprintf(nm, "rd%d", rdev->raid_disk); | 2029 | sprintf(nm, "rd%d", rdev->raid_disk); |
2024 | if (sysfs_create_link(&rdev->mddev->kobj, &rdev->kobj, nm)) | 2030 | if (sysfs_create_link(&rdev->mddev->kobj, &rdev->kobj, nm)) |
2025 | printk(KERN_WARNING | 2031 | printk(KERN_WARNING |
@@ -2036,7 +2042,7 @@ slot_store(mdk_rdev_t *rdev, const char *buf, size_t len) | |||
2036 | clear_bit(Faulty, &rdev->flags); | 2042 | clear_bit(Faulty, &rdev->flags); |
2037 | clear_bit(WriteMostly, &rdev->flags); | 2043 | clear_bit(WriteMostly, &rdev->flags); |
2038 | set_bit(In_sync, &rdev->flags); | 2044 | set_bit(In_sync, &rdev->flags); |
2039 | sysfs_notify(&rdev->kobj, NULL, "state"); | 2045 | sysfs_notify_dirent(rdev->sysfs_state); |
2040 | } | 2046 | } |
2041 | return len; | 2047 | return len; |
2042 | } | 2048 | } |
@@ -2770,7 +2776,7 @@ array_state_store(mddev_t *mddev, const char *buf, size_t len) | |||
2770 | if (err) | 2776 | if (err) |
2771 | return err; | 2777 | return err; |
2772 | else { | 2778 | else { |
2773 | sysfs_notify(&mddev->kobj, NULL, "array_state"); | 2779 | sysfs_notify_dirent(mddev->sysfs_state); |
2774 | return len; | 2780 | return len; |
2775 | } | 2781 | } |
2776 | } | 2782 | } |
@@ -3457,6 +3463,11 @@ static struct kobject *md_probe(dev_t dev, int *part, void *data) | |||
3457 | disk->fops = &md_fops; | 3463 | disk->fops = &md_fops; |
3458 | disk->private_data = mddev; | 3464 | disk->private_data = mddev; |
3459 | disk->queue = mddev->queue; | 3465 | disk->queue = mddev->queue; |
3466 | /* Allow extended partitions. This makes the | ||
3467 | * 'mdp' device redundant, but we can really | ||
3468 | * remove it now. | ||
3469 | */ | ||
3470 | disk->flags |= GENHD_FL_EXT_DEVT; | ||
3460 | add_disk(disk); | 3471 | add_disk(disk); |
3461 | mddev->gendisk = disk; | 3472 | mddev->gendisk = disk; |
3462 | error = kobject_init_and_add(&mddev->kobj, &md_ktype, | 3473 | error = kobject_init_and_add(&mddev->kobj, &md_ktype, |
@@ -3465,8 +3476,10 @@ static struct kobject *md_probe(dev_t dev, int *part, void *data) | |||
3465 | if (error) | 3476 | if (error) |
3466 | printk(KERN_WARNING "md: cannot register %s/md - name in use\n", | 3477 | printk(KERN_WARNING "md: cannot register %s/md - name in use\n", |
3467 | disk->disk_name); | 3478 | disk->disk_name); |
3468 | else | 3479 | else { |
3469 | kobject_uevent(&mddev->kobj, KOBJ_ADD); | 3480 | kobject_uevent(&mddev->kobj, KOBJ_ADD); |
3481 | mddev->sysfs_state = sysfs_get_dirent(mddev->kobj.sd, "array_state"); | ||
3482 | } | ||
3470 | return NULL; | 3483 | return NULL; |
3471 | } | 3484 | } |
3472 | 3485 | ||
@@ -3477,7 +3490,7 @@ static void md_safemode_timeout(unsigned long data) | |||
3477 | if (!atomic_read(&mddev->writes_pending)) { | 3490 | if (!atomic_read(&mddev->writes_pending)) { |
3478 | mddev->safemode = 1; | 3491 | mddev->safemode = 1; |
3479 | if (mddev->external) | 3492 | if (mddev->external) |
3480 | set_bit(MD_NOTIFY_ARRAY_STATE, &mddev->flags); | 3493 | sysfs_notify_dirent(mddev->sysfs_state); |
3481 | } | 3494 | } |
3482 | md_wakeup_thread(mddev->thread); | 3495 | md_wakeup_thread(mddev->thread); |
3483 | } | 3496 | } |
@@ -3578,7 +3591,7 @@ static int do_md_run(mddev_t * mddev) | |||
3578 | return -EINVAL; | 3591 | return -EINVAL; |
3579 | } | 3592 | } |
3580 | } | 3593 | } |
3581 | sysfs_notify(&rdev->kobj, NULL, "state"); | 3594 | sysfs_notify_dirent(rdev->sysfs_state); |
3582 | } | 3595 | } |
3583 | 3596 | ||
3584 | md_probe(mddev->unit, NULL, NULL); | 3597 | md_probe(mddev->unit, NULL, NULL); |
@@ -3740,7 +3753,7 @@ static int do_md_run(mddev_t * mddev) | |||
3740 | 3753 | ||
3741 | mddev->changed = 1; | 3754 | mddev->changed = 1; |
3742 | md_new_event(mddev); | 3755 | md_new_event(mddev); |
3743 | sysfs_notify(&mddev->kobj, NULL, "array_state"); | 3756 | sysfs_notify_dirent(mddev->sysfs_state); |
3744 | sysfs_notify(&mddev->kobj, NULL, "sync_action"); | 3757 | sysfs_notify(&mddev->kobj, NULL, "sync_action"); |
3745 | sysfs_notify(&mddev->kobj, NULL, "degraded"); | 3758 | sysfs_notify(&mddev->kobj, NULL, "degraded"); |
3746 | kobject_uevent(&disk_to_dev(mddev->gendisk)->kobj, KOBJ_CHANGE); | 3759 | kobject_uevent(&disk_to_dev(mddev->gendisk)->kobj, KOBJ_CHANGE); |
@@ -3767,7 +3780,7 @@ static int restart_array(mddev_t *mddev) | |||
3767 | set_bit(MD_RECOVERY_NEEDED, &mddev->recovery); | 3780 | set_bit(MD_RECOVERY_NEEDED, &mddev->recovery); |
3768 | md_wakeup_thread(mddev->thread); | 3781 | md_wakeup_thread(mddev->thread); |
3769 | md_wakeup_thread(mddev->sync_thread); | 3782 | md_wakeup_thread(mddev->sync_thread); |
3770 | sysfs_notify(&mddev->kobj, NULL, "array_state"); | 3783 | sysfs_notify_dirent(mddev->sysfs_state); |
3771 | return 0; | 3784 | return 0; |
3772 | } | 3785 | } |
3773 | 3786 | ||
@@ -3847,7 +3860,7 @@ static int do_md_stop(mddev_t * mddev, int mode, int is_open) | |||
3847 | module_put(mddev->pers->owner); | 3860 | module_put(mddev->pers->owner); |
3848 | mddev->pers = NULL; | 3861 | mddev->pers = NULL; |
3849 | /* tell userspace to handle 'inactive' */ | 3862 | /* tell userspace to handle 'inactive' */ |
3850 | sysfs_notify(&mddev->kobj, NULL, "array_state"); | 3863 | sysfs_notify_dirent(mddev->sysfs_state); |
3851 | 3864 | ||
3852 | set_capacity(disk, 0); | 3865 | set_capacity(disk, 0); |
3853 | mddev->changed = 1; | 3866 | mddev->changed = 1; |
@@ -3933,7 +3946,7 @@ static int do_md_stop(mddev_t * mddev, int mode, int is_open) | |||
3933 | mdname(mddev)); | 3946 | mdname(mddev)); |
3934 | err = 0; | 3947 | err = 0; |
3935 | md_new_event(mddev); | 3948 | md_new_event(mddev); |
3936 | sysfs_notify(&mddev->kobj, NULL, "array_state"); | 3949 | sysfs_notify_dirent(mddev->sysfs_state); |
3937 | out: | 3950 | out: |
3938 | return err; | 3951 | return err; |
3939 | } | 3952 | } |
@@ -4297,7 +4310,7 @@ static int add_new_disk(mddev_t * mddev, mdu_disk_info_t *info) | |||
4297 | if (err) | 4310 | if (err) |
4298 | export_rdev(rdev); | 4311 | export_rdev(rdev); |
4299 | else | 4312 | else |
4300 | sysfs_notify(&rdev->kobj, NULL, "state"); | 4313 | sysfs_notify_dirent(rdev->sysfs_state); |
4301 | 4314 | ||
4302 | md_update_sb(mddev, 1); | 4315 | md_update_sb(mddev, 1); |
4303 | if (mddev->degraded) | 4316 | if (mddev->degraded) |
@@ -4938,7 +4951,7 @@ static int md_ioctl(struct block_device *bdev, fmode_t mode, | |||
4938 | if (_IOC_TYPE(cmd) == MD_MAJOR && mddev->ro && mddev->pers) { | 4951 | if (_IOC_TYPE(cmd) == MD_MAJOR && mddev->ro && mddev->pers) { |
4939 | if (mddev->ro == 2) { | 4952 | if (mddev->ro == 2) { |
4940 | mddev->ro = 0; | 4953 | mddev->ro = 0; |
4941 | sysfs_notify(&mddev->kobj, NULL, "array_state"); | 4954 | sysfs_notify_dirent(mddev->sysfs_state); |
4942 | set_bit(MD_RECOVERY_NEEDED, &mddev->recovery); | 4955 | set_bit(MD_RECOVERY_NEEDED, &mddev->recovery); |
4943 | md_wakeup_thread(mddev->thread); | 4956 | md_wakeup_thread(mddev->thread); |
4944 | } else { | 4957 | } else { |
@@ -5612,7 +5625,7 @@ void md_write_start(mddev_t *mddev, struct bio *bi) | |||
5612 | spin_unlock_irq(&mddev->write_lock); | 5625 | spin_unlock_irq(&mddev->write_lock); |
5613 | } | 5626 | } |
5614 | if (did_change) | 5627 | if (did_change) |
5615 | sysfs_notify(&mddev->kobj, NULL, "array_state"); | 5628 | sysfs_notify_dirent(mddev->sysfs_state); |
5616 | wait_event(mddev->sb_wait, | 5629 | wait_event(mddev->sb_wait, |
5617 | !test_bit(MD_CHANGE_CLEAN, &mddev->flags) && | 5630 | !test_bit(MD_CHANGE_CLEAN, &mddev->flags) && |
5618 | !test_bit(MD_CHANGE_PENDING, &mddev->flags)); | 5631 | !test_bit(MD_CHANGE_PENDING, &mddev->flags)); |
@@ -5655,7 +5668,7 @@ int md_allow_write(mddev_t *mddev) | |||
5655 | mddev->safemode = 1; | 5668 | mddev->safemode = 1; |
5656 | spin_unlock_irq(&mddev->write_lock); | 5669 | spin_unlock_irq(&mddev->write_lock); |
5657 | md_update_sb(mddev, 0); | 5670 | md_update_sb(mddev, 0); |
5658 | sysfs_notify(&mddev->kobj, NULL, "array_state"); | 5671 | sysfs_notify_dirent(mddev->sysfs_state); |
5659 | } else | 5672 | } else |
5660 | spin_unlock_irq(&mddev->write_lock); | 5673 | spin_unlock_irq(&mddev->write_lock); |
5661 | 5674 | ||
@@ -6048,9 +6061,6 @@ void md_check_recovery(mddev_t *mddev) | |||
6048 | if (mddev->bitmap) | 6061 | if (mddev->bitmap) |
6049 | bitmap_daemon_work(mddev->bitmap); | 6062 | bitmap_daemon_work(mddev->bitmap); |
6050 | 6063 | ||
6051 | if (test_and_clear_bit(MD_NOTIFY_ARRAY_STATE, &mddev->flags)) | ||
6052 | sysfs_notify(&mddev->kobj, NULL, "array_state"); | ||
6053 | |||
6054 | if (mddev->ro) | 6064 | if (mddev->ro) |
6055 | return; | 6065 | return; |
6056 | 6066 | ||
@@ -6103,7 +6113,7 @@ void md_check_recovery(mddev_t *mddev) | |||
6103 | mddev->safemode = 0; | 6113 | mddev->safemode = 0; |
6104 | spin_unlock_irq(&mddev->write_lock); | 6114 | spin_unlock_irq(&mddev->write_lock); |
6105 | if (did_change) | 6115 | if (did_change) |
6106 | sysfs_notify(&mddev->kobj, NULL, "array_state"); | 6116 | sysfs_notify_dirent(mddev->sysfs_state); |
6107 | } | 6117 | } |
6108 | 6118 | ||
6109 | if (mddev->flags) | 6119 | if (mddev->flags) |
@@ -6111,7 +6121,7 @@ void md_check_recovery(mddev_t *mddev) | |||
6111 | 6121 | ||
6112 | rdev_for_each(rdev, rtmp, mddev) | 6122 | rdev_for_each(rdev, rtmp, mddev) |
6113 | if (test_and_clear_bit(StateChanged, &rdev->flags)) | 6123 | if (test_and_clear_bit(StateChanged, &rdev->flags)) |
6114 | sysfs_notify(&rdev->kobj, NULL, "state"); | 6124 | sysfs_notify_dirent(rdev->sysfs_state); |
6115 | 6125 | ||
6116 | 6126 | ||
6117 | if (test_bit(MD_RECOVERY_RUNNING, &mddev->recovery) && | 6127 | if (test_bit(MD_RECOVERY_RUNNING, &mddev->recovery) && |
@@ -6221,7 +6231,7 @@ void md_check_recovery(mddev_t *mddev) | |||
6221 | 6231 | ||
6222 | void md_wait_for_blocked_rdev(mdk_rdev_t *rdev, mddev_t *mddev) | 6232 | void md_wait_for_blocked_rdev(mdk_rdev_t *rdev, mddev_t *mddev) |
6223 | { | 6233 | { |
6224 | sysfs_notify(&rdev->kobj, NULL, "state"); | 6234 | sysfs_notify_dirent(rdev->sysfs_state); |
6225 | wait_event_timeout(rdev->blocked_wait, | 6235 | wait_event_timeout(rdev->blocked_wait, |
6226 | !test_bit(Blocked, &rdev->flags), | 6236 | !test_bit(Blocked, &rdev->flags), |
6227 | msecs_to_jiffies(5000)); | 6237 | msecs_to_jiffies(5000)); |
diff --git a/drivers/message/fusion/mptscsih.c b/drivers/message/fusion/mptscsih.c index 9f9354fd3516..d62fd4f6b52e 100644 --- a/drivers/message/fusion/mptscsih.c +++ b/drivers/message/fusion/mptscsih.c | |||
@@ -1760,10 +1760,9 @@ mptscsih_get_tm_timeout(MPT_ADAPTER *ioc) | |||
1760 | case FC: | 1760 | case FC: |
1761 | return 40; | 1761 | return 40; |
1762 | case SAS: | 1762 | case SAS: |
1763 | return 10; | ||
1764 | case SPI: | 1763 | case SPI: |
1765 | default: | 1764 | default: |
1766 | return 2; | 1765 | return 10; |
1767 | } | 1766 | } |
1768 | } | 1767 | } |
1769 | 1768 | ||
diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig index 5a79d2d4cdae..b550267c8d5e 100644 --- a/drivers/mfd/Kconfig +++ b/drivers/mfd/Kconfig | |||
@@ -103,8 +103,20 @@ config MFD_TC6393XB | |||
103 | help | 103 | help |
104 | Support for Toshiba Mobile IO Controller TC6393XB | 104 | Support for Toshiba Mobile IO Controller TC6393XB |
105 | 105 | ||
106 | config PMIC_DA903X | ||
107 | bool "Dialog Semiconductor DA9030/DA9034 PMIC Support" | ||
108 | depends on I2C=y | ||
109 | help | ||
110 | Say yes here to support for Dialog Semiconductor DA9030 (a.k.a | ||
111 | ARAVA) and DA9034 (a.k.a MICCO), these are Power Management IC | ||
112 | usually found on PXA processors-based platforms. This includes | ||
113 | the I2C driver and the core APIs _only_, you have to select | ||
114 | individual components like LCD backlight, voltage regulators, | ||
115 | LEDs and battery-charger under the corresponding menus. | ||
116 | |||
106 | config MFD_WM8400 | 117 | config MFD_WM8400 |
107 | tristate "Support Wolfson Microelectronics WM8400" | 118 | tristate "Support Wolfson Microelectronics WM8400" |
119 | depends on I2C | ||
108 | help | 120 | help |
109 | Support for the Wolfson Microelecronics WM8400 PMIC and audio | 121 | Support for the Wolfson Microelecronics WM8400 PMIC and audio |
110 | CODEC. This driver adds provides common support for accessing | 122 | CODEC. This driver adds provides common support for accessing |
diff --git a/drivers/mfd/Makefile b/drivers/mfd/Makefile index 0acefe8aff87..9a5ad8af9116 100644 --- a/drivers/mfd/Makefile +++ b/drivers/mfd/Makefile | |||
@@ -30,3 +30,5 @@ ifeq ($(CONFIG_SA1100_ASSABET),y) | |||
30 | obj-$(CONFIG_MCP_UCB1200) += ucb1x00-assabet.o | 30 | obj-$(CONFIG_MCP_UCB1200) += ucb1x00-assabet.o |
31 | endif | 31 | endif |
32 | obj-$(CONFIG_UCB1400_CORE) += ucb1400_core.o | 32 | obj-$(CONFIG_UCB1400_CORE) += ucb1400_core.o |
33 | |||
34 | obj-$(CONFIG_PMIC_DA903X) += da903x.o \ No newline at end of file | ||
diff --git a/drivers/net/8139cp.c b/drivers/net/8139cp.c index 85fa40a0a667..9ba1f0b46429 100644 --- a/drivers/net/8139cp.c +++ b/drivers/net/8139cp.c | |||
@@ -1836,10 +1836,9 @@ static int cp_init_one (struct pci_dev *pdev, const struct pci_device_id *ent) | |||
1836 | 1836 | ||
1837 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && | 1837 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && |
1838 | pdev->device == PCI_DEVICE_ID_REALTEK_8139 && pdev->revision < 0x20) { | 1838 | pdev->device == PCI_DEVICE_ID_REALTEK_8139 && pdev->revision < 0x20) { |
1839 | dev_err(&pdev->dev, | 1839 | dev_info(&pdev->dev, |
1840 | "This (id %04x:%04x rev %02x) is not an 8139C+ compatible chip\n", | 1840 | "This (id %04x:%04x rev %02x) is not an 8139C+ compatible chip, use 8139too\n", |
1841 | pdev->vendor, pdev->device, pdev->revision); | 1841 | pdev->vendor, pdev->device, pdev->revision); |
1842 | dev_err(&pdev->dev, "Try the \"8139too\" driver instead.\n"); | ||
1843 | return -ENODEV; | 1842 | return -ENODEV; |
1844 | } | 1843 | } |
1845 | 1844 | ||
diff --git a/drivers/net/8139too.c b/drivers/net/8139too.c index 0daf8c15e381..63f906b04899 100644 --- a/drivers/net/8139too.c +++ b/drivers/net/8139too.c | |||
@@ -946,10 +946,9 @@ static int __devinit rtl8139_init_one (struct pci_dev *pdev, | |||
946 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && | 946 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && |
947 | pdev->device == PCI_DEVICE_ID_REALTEK_8139 && pdev->revision >= 0x20) { | 947 | pdev->device == PCI_DEVICE_ID_REALTEK_8139 && pdev->revision >= 0x20) { |
948 | dev_info(&pdev->dev, | 948 | dev_info(&pdev->dev, |
949 | "This (id %04x:%04x rev %02x) is an enhanced 8139C+ chip\n", | 949 | "This (id %04x:%04x rev %02x) is an enhanced 8139C+ chip, use 8139cp\n", |
950 | pdev->vendor, pdev->device, pdev->revision); | 950 | pdev->vendor, pdev->device, pdev->revision); |
951 | dev_info(&pdev->dev, | 951 | return -ENODEV; |
952 | "Use the \"8139cp\" driver for improved performance and stability.\n"); | ||
953 | } | 952 | } |
954 | 953 | ||
955 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && | 954 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && |
diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig index 0b71ebc074b6..f749b40f954e 100644 --- a/drivers/net/Kconfig +++ b/drivers/net/Kconfig | |||
@@ -894,7 +894,7 @@ config SMC91X | |||
894 | select CRC32 | 894 | select CRC32 |
895 | select MII | 895 | select MII |
896 | depends on ARM || REDWOOD_5 || REDWOOD_6 || M32R || SUPERH || \ | 896 | depends on ARM || REDWOOD_5 || REDWOOD_6 || M32R || SUPERH || \ |
897 | SOC_AU1X00 || BLACKFIN || MN10300 | 897 | MIPS || BLACKFIN || MN10300 |
898 | help | 898 | help |
899 | This is a driver for SMC's 91x series of Ethernet chipsets, | 899 | This is a driver for SMC's 91x series of Ethernet chipsets, |
900 | including the SMC91C94 and the SMC91C111. Say Y if you want it | 900 | including the SMC91C94 and the SMC91C111. Say Y if you want it |
@@ -966,7 +966,7 @@ config SMC911X | |||
966 | tristate "SMSC LAN911[5678] support" | 966 | tristate "SMSC LAN911[5678] support" |
967 | select CRC32 | 967 | select CRC32 |
968 | select MII | 968 | select MII |
969 | depends on ARCH_PXA || SUPERH | 969 | depends on ARM || SUPERH |
970 | help | 970 | help |
971 | This is a driver for SMSC's LAN911x series of Ethernet chipsets | 971 | This is a driver for SMSC's LAN911x series of Ethernet chipsets |
972 | including the new LAN9115, LAN9116, LAN9117, and LAN9118. | 972 | including the new LAN9115, LAN9116, LAN9117, and LAN9118. |
@@ -2009,6 +2009,11 @@ config IGB_LRO | |||
2009 | 2009 | ||
2010 | If in doubt, say N. | 2010 | If in doubt, say N. |
2011 | 2011 | ||
2012 | config IGB_DCA | ||
2013 | bool "Enable DCA" | ||
2014 | default y | ||
2015 | depends on IGB && DCA && !(IGB=y && DCA=m) | ||
2016 | |||
2012 | source "drivers/net/ixp2000/Kconfig" | 2017 | source "drivers/net/ixp2000/Kconfig" |
2013 | 2018 | ||
2014 | config MYRI_SBUS | 2019 | config MYRI_SBUS |
diff --git a/drivers/net/ax88796.c b/drivers/net/ax88796.c index 4207d6efddc0..9a314d88e7b6 100644 --- a/drivers/net/ax88796.c +++ b/drivers/net/ax88796.c | |||
@@ -838,12 +838,12 @@ static int ax_probe(struct platform_device *pdev) | |||
838 | 838 | ||
839 | /* find the platform resources */ | 839 | /* find the platform resources */ |
840 | 840 | ||
841 | dev->irq = platform_get_irq(pdev, 0); | 841 | ret = platform_get_irq(pdev, 0); |
842 | if (dev->irq < 0) { | 842 | if (ret < 0) { |
843 | dev_err(&pdev->dev, "no IRQ specified\n"); | 843 | dev_err(&pdev->dev, "no IRQ specified\n"); |
844 | ret = -ENXIO; | ||
845 | goto exit_mem; | 844 | goto exit_mem; |
846 | } | 845 | } |
846 | dev->irq = ret; | ||
847 | 847 | ||
848 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | 848 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
849 | if (res == NULL) { | 849 | if (res == NULL) { |
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c index 8e2be24f3fe4..832739f38db4 100644 --- a/drivers/net/bonding/bond_main.c +++ b/drivers/net/bonding/bond_main.c | |||
@@ -1341,18 +1341,24 @@ static int bond_compute_features(struct bonding *bond) | |||
1341 | int i; | 1341 | int i; |
1342 | 1342 | ||
1343 | features &= ~(NETIF_F_ALL_CSUM | BOND_VLAN_FEATURES); | 1343 | features &= ~(NETIF_F_ALL_CSUM | BOND_VLAN_FEATURES); |
1344 | features |= NETIF_F_SG | NETIF_F_FRAGLIST | NETIF_F_HIGHDMA | | 1344 | features |= NETIF_F_GSO_MASK | NETIF_F_NO_CSUM; |
1345 | NETIF_F_GSO_MASK | NETIF_F_NO_CSUM; | 1345 | |
1346 | if (!bond->first_slave) | ||
1347 | goto done; | ||
1348 | |||
1349 | features &= ~NETIF_F_ONE_FOR_ALL; | ||
1346 | 1350 | ||
1347 | bond_for_each_slave(bond, slave, i) { | 1351 | bond_for_each_slave(bond, slave, i) { |
1348 | features = netdev_compute_features(features, | 1352 | features = netdev_increment_features(features, |
1349 | slave->dev->features); | 1353 | slave->dev->features, |
1354 | NETIF_F_ONE_FOR_ALL); | ||
1350 | if (slave->dev->hard_header_len > max_hard_header_len) | 1355 | if (slave->dev->hard_header_len > max_hard_header_len) |
1351 | max_hard_header_len = slave->dev->hard_header_len; | 1356 | max_hard_header_len = slave->dev->hard_header_len; |
1352 | } | 1357 | } |
1353 | 1358 | ||
1359 | done: | ||
1354 | features |= (bond_dev->features & BOND_VLAN_FEATURES); | 1360 | features |= (bond_dev->features & BOND_VLAN_FEATURES); |
1355 | bond_dev->features = features; | 1361 | bond_dev->features = netdev_fix_features(features, NULL); |
1356 | bond_dev->hard_header_len = max_hard_header_len; | 1362 | bond_dev->hard_header_len = max_hard_header_len; |
1357 | 1363 | ||
1358 | return 0; | 1364 | return 0; |
diff --git a/drivers/net/cxgb3/l2t.c b/drivers/net/cxgb3/l2t.c index 4407ac9bb555..ff1611f90e7a 100644 --- a/drivers/net/cxgb3/l2t.c +++ b/drivers/net/cxgb3/l2t.c | |||
@@ -431,6 +431,7 @@ struct l2t_data *t3_init_l2t(unsigned int l2t_capacity) | |||
431 | for (i = 0; i < l2t_capacity; ++i) { | 431 | for (i = 0; i < l2t_capacity; ++i) { |
432 | d->l2tab[i].idx = i; | 432 | d->l2tab[i].idx = i; |
433 | d->l2tab[i].state = L2T_STATE_UNUSED; | 433 | d->l2tab[i].state = L2T_STATE_UNUSED; |
434 | __skb_queue_head_init(&d->l2tab[i].arpq); | ||
434 | spin_lock_init(&d->l2tab[i].lock); | 435 | spin_lock_init(&d->l2tab[i].lock); |
435 | atomic_set(&d->l2tab[i].refcnt, 0); | 436 | atomic_set(&d->l2tab[i].refcnt, 0); |
436 | } | 437 | } |
diff --git a/drivers/net/dm9000.c b/drivers/net/dm9000.c index f42c23f42652..5a9083e3f443 100644 --- a/drivers/net/dm9000.c +++ b/drivers/net/dm9000.c | |||
@@ -47,15 +47,6 @@ | |||
47 | #define CARDNAME "dm9000" | 47 | #define CARDNAME "dm9000" |
48 | #define DRV_VERSION "1.31" | 48 | #define DRV_VERSION "1.31" |
49 | 49 | ||
50 | #ifdef CONFIG_BLACKFIN | ||
51 | #define readsb insb | ||
52 | #define readsw insw | ||
53 | #define readsl insl | ||
54 | #define writesb outsb | ||
55 | #define writesw outsw | ||
56 | #define writesl outsl | ||
57 | #endif | ||
58 | |||
59 | /* | 50 | /* |
60 | * Transmit timeout, default 5 seconds. | 51 | * Transmit timeout, default 5 seconds. |
61 | */ | 52 | */ |
diff --git a/drivers/net/ehea/ehea.h b/drivers/net/ehea/ehea.h index 5524271eedca..82dd1a891ce7 100644 --- a/drivers/net/ehea/ehea.h +++ b/drivers/net/ehea/ehea.h | |||
@@ -40,7 +40,7 @@ | |||
40 | #include <asm/io.h> | 40 | #include <asm/io.h> |
41 | 41 | ||
42 | #define DRV_NAME "ehea" | 42 | #define DRV_NAME "ehea" |
43 | #define DRV_VERSION "EHEA_0093" | 43 | #define DRV_VERSION "EHEA_0094" |
44 | 44 | ||
45 | /* eHEA capability flags */ | 45 | /* eHEA capability flags */ |
46 | #define DLPAR_PORT_ADD_REM 1 | 46 | #define DLPAR_PORT_ADD_REM 1 |
diff --git a/drivers/net/ehea/ehea_main.c b/drivers/net/ehea/ehea_main.c index b70c5314f537..422fcb93e2c3 100644 --- a/drivers/net/ehea/ehea_main.c +++ b/drivers/net/ehea/ehea_main.c | |||
@@ -2863,7 +2863,7 @@ static void ehea_rereg_mrs(struct work_struct *work) | |||
2863 | struct ehea_adapter *adapter; | 2863 | struct ehea_adapter *adapter; |
2864 | 2864 | ||
2865 | mutex_lock(&dlpar_mem_lock); | 2865 | mutex_lock(&dlpar_mem_lock); |
2866 | ehea_info("LPAR memory enlarged - re-initializing driver"); | 2866 | ehea_info("LPAR memory changed - re-initializing driver"); |
2867 | 2867 | ||
2868 | list_for_each_entry(adapter, &adapter_list, list) | 2868 | list_for_each_entry(adapter, &adapter_list, list) |
2869 | if (adapter->active_ports) { | 2869 | if (adapter->active_ports) { |
@@ -2900,13 +2900,6 @@ static void ehea_rereg_mrs(struct work_struct *work) | |||
2900 | } | 2900 | } |
2901 | } | 2901 | } |
2902 | 2902 | ||
2903 | ehea_destroy_busmap(); | ||
2904 | ret = ehea_create_busmap(); | ||
2905 | if (ret) { | ||
2906 | ehea_error("creating ehea busmap failed"); | ||
2907 | goto out; | ||
2908 | } | ||
2909 | |||
2910 | clear_bit(__EHEA_STOP_XFER, &ehea_driver_flags); | 2903 | clear_bit(__EHEA_STOP_XFER, &ehea_driver_flags); |
2911 | 2904 | ||
2912 | list_for_each_entry(adapter, &adapter_list, list) | 2905 | list_for_each_entry(adapter, &adapter_list, list) |
@@ -3519,9 +3512,21 @@ void ehea_crash_handler(void) | |||
3519 | static int ehea_mem_notifier(struct notifier_block *nb, | 3512 | static int ehea_mem_notifier(struct notifier_block *nb, |
3520 | unsigned long action, void *data) | 3513 | unsigned long action, void *data) |
3521 | { | 3514 | { |
3515 | struct memory_notify *arg = data; | ||
3522 | switch (action) { | 3516 | switch (action) { |
3523 | case MEM_OFFLINE: | 3517 | case MEM_CANCEL_OFFLINE: |
3524 | ehea_info("memory has been removed"); | 3518 | ehea_info("memory offlining canceled"); |
3519 | /* Readd canceled memory block */ | ||
3520 | case MEM_ONLINE: | ||
3521 | ehea_info("memory is going online"); | ||
3522 | if (ehea_add_sect_bmap(arg->start_pfn, arg->nr_pages)) | ||
3523 | return NOTIFY_BAD; | ||
3524 | ehea_rereg_mrs(NULL); | ||
3525 | break; | ||
3526 | case MEM_GOING_OFFLINE: | ||
3527 | ehea_info("memory is going offline"); | ||
3528 | if (ehea_rem_sect_bmap(arg->start_pfn, arg->nr_pages)) | ||
3529 | return NOTIFY_BAD; | ||
3525 | ehea_rereg_mrs(NULL); | 3530 | ehea_rereg_mrs(NULL); |
3526 | break; | 3531 | break; |
3527 | default: | 3532 | default: |
diff --git a/drivers/net/ehea/ehea_qmr.c b/drivers/net/ehea/ehea_qmr.c index db8a9257e680..9b61dc9865d1 100644 --- a/drivers/net/ehea/ehea_qmr.c +++ b/drivers/net/ehea/ehea_qmr.c | |||
@@ -567,7 +567,7 @@ static inline int ehea_calc_index(unsigned long i, unsigned long s) | |||
567 | static inline int ehea_init_top_bmap(struct ehea_top_bmap *ehea_top_bmap, | 567 | static inline int ehea_init_top_bmap(struct ehea_top_bmap *ehea_top_bmap, |
568 | int dir) | 568 | int dir) |
569 | { | 569 | { |
570 | if(!ehea_top_bmap->dir[dir]) { | 570 | if (!ehea_top_bmap->dir[dir]) { |
571 | ehea_top_bmap->dir[dir] = | 571 | ehea_top_bmap->dir[dir] = |
572 | kzalloc(sizeof(struct ehea_dir_bmap), GFP_KERNEL); | 572 | kzalloc(sizeof(struct ehea_dir_bmap), GFP_KERNEL); |
573 | if (!ehea_top_bmap->dir[dir]) | 573 | if (!ehea_top_bmap->dir[dir]) |
@@ -578,7 +578,7 @@ static inline int ehea_init_top_bmap(struct ehea_top_bmap *ehea_top_bmap, | |||
578 | 578 | ||
579 | static inline int ehea_init_bmap(struct ehea_bmap *ehea_bmap, int top, int dir) | 579 | static inline int ehea_init_bmap(struct ehea_bmap *ehea_bmap, int top, int dir) |
580 | { | 580 | { |
581 | if(!ehea_bmap->top[top]) { | 581 | if (!ehea_bmap->top[top]) { |
582 | ehea_bmap->top[top] = | 582 | ehea_bmap->top[top] = |
583 | kzalloc(sizeof(struct ehea_top_bmap), GFP_KERNEL); | 583 | kzalloc(sizeof(struct ehea_top_bmap), GFP_KERNEL); |
584 | if (!ehea_bmap->top[top]) | 584 | if (!ehea_bmap->top[top]) |
@@ -587,53 +587,124 @@ static inline int ehea_init_bmap(struct ehea_bmap *ehea_bmap, int top, int dir) | |||
587 | return ehea_init_top_bmap(ehea_bmap->top[top], dir); | 587 | return ehea_init_top_bmap(ehea_bmap->top[top], dir); |
588 | } | 588 | } |
589 | 589 | ||
590 | static int ehea_create_busmap_callback(unsigned long pfn, | 590 | static DEFINE_MUTEX(ehea_busmap_mutex); |
591 | unsigned long nr_pages, void *arg) | 591 | static unsigned long ehea_mr_len; |
592 | { | ||
593 | unsigned long i, mr_len, start_section, end_section; | ||
594 | start_section = (pfn * PAGE_SIZE) / EHEA_SECTSIZE; | ||
595 | end_section = start_section + ((nr_pages * PAGE_SIZE) / EHEA_SECTSIZE); | ||
596 | mr_len = *(unsigned long *)arg; | ||
597 | 592 | ||
598 | if (!ehea_bmap) | 593 | #define EHEA_BUSMAP_ADD_SECT 1 |
599 | ehea_bmap = kzalloc(sizeof(struct ehea_bmap), GFP_KERNEL); | 594 | #define EHEA_BUSMAP_REM_SECT 0 |
600 | if (!ehea_bmap) | ||
601 | return -ENOMEM; | ||
602 | 595 | ||
603 | for (i = start_section; i < end_section; i++) { | 596 | static void ehea_rebuild_busmap(void) |
604 | int ret; | 597 | { |
605 | int top, dir, idx; | 598 | u64 vaddr = EHEA_BUSMAP_START; |
606 | u64 vaddr; | 599 | int top, dir, idx; |
600 | |||
601 | for (top = 0; top < EHEA_MAP_ENTRIES; top++) { | ||
602 | struct ehea_top_bmap *ehea_top; | ||
603 | int valid_dir_entries = 0; | ||
607 | 604 | ||
608 | top = ehea_calc_index(i, EHEA_TOP_INDEX_SHIFT); | 605 | if (!ehea_bmap->top[top]) |
609 | dir = ehea_calc_index(i, EHEA_DIR_INDEX_SHIFT); | 606 | continue; |
607 | ehea_top = ehea_bmap->top[top]; | ||
608 | for (dir = 0; dir < EHEA_MAP_ENTRIES; dir++) { | ||
609 | struct ehea_dir_bmap *ehea_dir; | ||
610 | int valid_entries = 0; | ||
610 | 611 | ||
611 | ret = ehea_init_bmap(ehea_bmap, top, dir); | 612 | if (!ehea_top->dir[dir]) |
612 | if(ret) | 613 | continue; |
613 | return ret; | 614 | valid_dir_entries++; |
615 | ehea_dir = ehea_top->dir[dir]; | ||
616 | for (idx = 0; idx < EHEA_MAP_ENTRIES; idx++) { | ||
617 | if (!ehea_dir->ent[idx]) | ||
618 | continue; | ||
619 | valid_entries++; | ||
620 | ehea_dir->ent[idx] = vaddr; | ||
621 | vaddr += EHEA_SECTSIZE; | ||
622 | } | ||
623 | if (!valid_entries) { | ||
624 | ehea_top->dir[dir] = NULL; | ||
625 | kfree(ehea_dir); | ||
626 | } | ||
627 | } | ||
628 | if (!valid_dir_entries) { | ||
629 | ehea_bmap->top[top] = NULL; | ||
630 | kfree(ehea_top); | ||
631 | } | ||
632 | } | ||
633 | } | ||
614 | 634 | ||
615 | idx = i & EHEA_INDEX_MASK; | 635 | static int ehea_update_busmap(unsigned long pfn, unsigned long pgnum, int add) |
616 | vaddr = EHEA_BUSMAP_START + mr_len + i * EHEA_SECTSIZE; | 636 | { |
637 | unsigned long i, start_section, end_section; | ||
617 | 638 | ||
618 | ehea_bmap->top[top]->dir[dir]->ent[idx] = vaddr; | 639 | if (!ehea_bmap) { |
640 | ehea_bmap = kzalloc(sizeof(struct ehea_bmap), GFP_KERNEL); | ||
641 | if (!ehea_bmap) | ||
642 | return -ENOMEM; | ||
619 | } | 643 | } |
620 | 644 | ||
621 | mr_len += nr_pages * PAGE_SIZE; | 645 | start_section = (pfn * PAGE_SIZE) / EHEA_SECTSIZE; |
622 | *(unsigned long *)arg = mr_len; | 646 | end_section = start_section + ((pgnum * PAGE_SIZE) / EHEA_SECTSIZE); |
647 | /* Mark entries as valid or invalid only; address is assigned later */ | ||
648 | for (i = start_section; i < end_section; i++) { | ||
649 | u64 flag; | ||
650 | int top = ehea_calc_index(i, EHEA_TOP_INDEX_SHIFT); | ||
651 | int dir = ehea_calc_index(i, EHEA_DIR_INDEX_SHIFT); | ||
652 | int idx = i & EHEA_INDEX_MASK; | ||
653 | |||
654 | if (add) { | ||
655 | int ret = ehea_init_bmap(ehea_bmap, top, dir); | ||
656 | if (ret) | ||
657 | return ret; | ||
658 | flag = 1; /* valid */ | ||
659 | ehea_mr_len += EHEA_SECTSIZE; | ||
660 | } else { | ||
661 | if (!ehea_bmap->top[top]) | ||
662 | continue; | ||
663 | if (!ehea_bmap->top[top]->dir[dir]) | ||
664 | continue; | ||
665 | flag = 0; /* invalid */ | ||
666 | ehea_mr_len -= EHEA_SECTSIZE; | ||
667 | } | ||
623 | 668 | ||
669 | ehea_bmap->top[top]->dir[dir]->ent[idx] = flag; | ||
670 | } | ||
671 | ehea_rebuild_busmap(); /* Assign contiguous addresses for mr */ | ||
624 | return 0; | 672 | return 0; |
625 | } | 673 | } |
626 | 674 | ||
627 | static unsigned long ehea_mr_len; | 675 | int ehea_add_sect_bmap(unsigned long pfn, unsigned long nr_pages) |
676 | { | ||
677 | int ret; | ||
628 | 678 | ||
629 | static DEFINE_MUTEX(ehea_busmap_mutex); | 679 | mutex_lock(&ehea_busmap_mutex); |
680 | ret = ehea_update_busmap(pfn, nr_pages, EHEA_BUSMAP_ADD_SECT); | ||
681 | mutex_unlock(&ehea_busmap_mutex); | ||
682 | return ret; | ||
683 | } | ||
684 | |||
685 | int ehea_rem_sect_bmap(unsigned long pfn, unsigned long nr_pages) | ||
686 | { | ||
687 | int ret; | ||
688 | |||
689 | mutex_lock(&ehea_busmap_mutex); | ||
690 | ret = ehea_update_busmap(pfn, nr_pages, EHEA_BUSMAP_REM_SECT); | ||
691 | mutex_unlock(&ehea_busmap_mutex); | ||
692 | return ret; | ||
693 | } | ||
694 | |||
695 | static int ehea_create_busmap_callback(unsigned long pfn, | ||
696 | unsigned long nr_pages, void *arg) | ||
697 | { | ||
698 | return ehea_update_busmap(pfn, nr_pages, EHEA_BUSMAP_ADD_SECT); | ||
699 | } | ||
630 | 700 | ||
631 | int ehea_create_busmap(void) | 701 | int ehea_create_busmap(void) |
632 | { | 702 | { |
633 | int ret; | 703 | int ret; |
704 | |||
634 | mutex_lock(&ehea_busmap_mutex); | 705 | mutex_lock(&ehea_busmap_mutex); |
635 | ehea_mr_len = 0; | 706 | ehea_mr_len = 0; |
636 | ret = walk_memory_resource(0, 1ULL << MAX_PHYSMEM_BITS, &ehea_mr_len, | 707 | ret = walk_memory_resource(0, 1ULL << MAX_PHYSMEM_BITS, NULL, |
637 | ehea_create_busmap_callback); | 708 | ehea_create_busmap_callback); |
638 | mutex_unlock(&ehea_busmap_mutex); | 709 | mutex_unlock(&ehea_busmap_mutex); |
639 | return ret; | 710 | return ret; |
diff --git a/drivers/net/ehea/ehea_qmr.h b/drivers/net/ehea/ehea_qmr.h index 0bb6f92fa2f8..1e58dc06b7d2 100644 --- a/drivers/net/ehea/ehea_qmr.h +++ b/drivers/net/ehea/ehea_qmr.h | |||
@@ -378,6 +378,8 @@ int ehea_rem_mr(struct ehea_mr *mr); | |||
378 | 378 | ||
379 | void ehea_error_data(struct ehea_adapter *adapter, u64 res_handle); | 379 | void ehea_error_data(struct ehea_adapter *adapter, u64 res_handle); |
380 | 380 | ||
381 | int ehea_add_sect_bmap(unsigned long pfn, unsigned long nr_pages); | ||
382 | int ehea_rem_sect_bmap(unsigned long pfn, unsigned long nr_pages); | ||
381 | int ehea_create_busmap(void); | 383 | int ehea_create_busmap(void); |
382 | void ehea_destroy_busmap(void); | 384 | void ehea_destroy_busmap(void); |
383 | u64 ehea_map_vaddr(void *caddr); | 385 | u64 ehea_map_vaddr(void *caddr); |
diff --git a/drivers/net/fec_mpc52xx.c b/drivers/net/fec_mpc52xx.c index 4e4f68304e82..aec3b97e794d 100644 --- a/drivers/net/fec_mpc52xx.c +++ b/drivers/net/fec_mpc52xx.c | |||
@@ -401,6 +401,21 @@ static int mpc52xx_fec_hard_start_xmit(struct sk_buff *skb, struct net_device *d | |||
401 | return 0; | 401 | return 0; |
402 | } | 402 | } |
403 | 403 | ||
404 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
405 | static void mpc52xx_fec_poll_controller(struct net_device *dev) | ||
406 | { | ||
407 | struct mpc52xx_fec_priv *priv = netdev_priv(dev); | ||
408 | |||
409 | disable_irq(priv->t_irq); | ||
410 | mpc52xx_fec_tx_interrupt(priv->t_irq, dev); | ||
411 | enable_irq(priv->t_irq); | ||
412 | disable_irq(priv->r_irq); | ||
413 | mpc52xx_fec_rx_interrupt(priv->r_irq, dev); | ||
414 | enable_irq(priv->r_irq); | ||
415 | } | ||
416 | #endif | ||
417 | |||
418 | |||
404 | /* This handles BestComm transmit task interrupts | 419 | /* This handles BestComm transmit task interrupts |
405 | */ | 420 | */ |
406 | static irqreturn_t mpc52xx_fec_tx_interrupt(int irq, void *dev_id) | 421 | static irqreturn_t mpc52xx_fec_tx_interrupt(int irq, void *dev_id) |
@@ -926,6 +941,9 @@ mpc52xx_fec_probe(struct of_device *op, const struct of_device_id *match) | |||
926 | ndev->tx_timeout = mpc52xx_fec_tx_timeout; | 941 | ndev->tx_timeout = mpc52xx_fec_tx_timeout; |
927 | ndev->watchdog_timeo = FEC_WATCHDOG_TIMEOUT; | 942 | ndev->watchdog_timeo = FEC_WATCHDOG_TIMEOUT; |
928 | ndev->base_addr = mem.start; | 943 | ndev->base_addr = mem.start; |
944 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
945 | ndev->poll_controller = mpc52xx_fec_poll_controller; | ||
946 | #endif | ||
929 | 947 | ||
930 | priv->t_irq = priv->r_irq = ndev->irq = NO_IRQ; /* IRQ are free for now */ | 948 | priv->t_irq = priv->r_irq = ndev->irq = NO_IRQ; /* IRQ are free for now */ |
931 | 949 | ||
diff --git a/drivers/net/gianfar.c b/drivers/net/gianfar.c index b5bb7ae2817f..64b201134fdb 100644 --- a/drivers/net/gianfar.c +++ b/drivers/net/gianfar.c | |||
@@ -161,7 +161,7 @@ static int gfar_probe(struct platform_device *pdev) | |||
161 | struct gfar_private *priv = NULL; | 161 | struct gfar_private *priv = NULL; |
162 | struct gianfar_platform_data *einfo; | 162 | struct gianfar_platform_data *einfo; |
163 | struct resource *r; | 163 | struct resource *r; |
164 | int err = 0; | 164 | int err = 0, irq; |
165 | DECLARE_MAC_BUF(mac); | 165 | DECLARE_MAC_BUF(mac); |
166 | 166 | ||
167 | einfo = (struct gianfar_platform_data *) pdev->dev.platform_data; | 167 | einfo = (struct gianfar_platform_data *) pdev->dev.platform_data; |
@@ -187,15 +187,25 @@ static int gfar_probe(struct platform_device *pdev) | |||
187 | 187 | ||
188 | /* fill out IRQ fields */ | 188 | /* fill out IRQ fields */ |
189 | if (einfo->device_flags & FSL_GIANFAR_DEV_HAS_MULTI_INTR) { | 189 | if (einfo->device_flags & FSL_GIANFAR_DEV_HAS_MULTI_INTR) { |
190 | priv->interruptTransmit = platform_get_irq_byname(pdev, "tx"); | 190 | irq = platform_get_irq_byname(pdev, "tx"); |
191 | priv->interruptReceive = platform_get_irq_byname(pdev, "rx"); | 191 | if (irq < 0) |
192 | priv->interruptError = platform_get_irq_byname(pdev, "error"); | 192 | goto regs_fail; |
193 | if (priv->interruptTransmit < 0 || priv->interruptReceive < 0 || priv->interruptError < 0) | 193 | priv->interruptTransmit = irq; |
194 | |||
195 | irq = platform_get_irq_byname(pdev, "rx"); | ||
196 | if (irq < 0) | ||
197 | goto regs_fail; | ||
198 | priv->interruptReceive = irq; | ||
199 | |||
200 | irq = platform_get_irq_byname(pdev, "error"); | ||
201 | if (irq < 0) | ||
194 | goto regs_fail; | 202 | goto regs_fail; |
203 | priv->interruptError = irq; | ||
195 | } else { | 204 | } else { |
196 | priv->interruptTransmit = platform_get_irq(pdev, 0); | 205 | irq = platform_get_irq(pdev, 0); |
197 | if (priv->interruptTransmit < 0) | 206 | if (irq < 0) |
198 | goto regs_fail; | 207 | goto regs_fail; |
208 | priv->interruptTransmit = irq; | ||
199 | } | 209 | } |
200 | 210 | ||
201 | /* get a pointer to the register memory */ | 211 | /* get a pointer to the register memory */ |
diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c index 93d02efa9a0a..1f397cd99414 100644 --- a/drivers/net/igb/igb_main.c +++ b/drivers/net/igb/igb_main.c | |||
@@ -38,10 +38,11 @@ | |||
38 | #include <linux/ethtool.h> | 38 | #include <linux/ethtool.h> |
39 | #include <linux/if_vlan.h> | 39 | #include <linux/if_vlan.h> |
40 | #include <linux/pci.h> | 40 | #include <linux/pci.h> |
41 | #include <linux/pci-aspm.h> | ||
41 | #include <linux/delay.h> | 42 | #include <linux/delay.h> |
42 | #include <linux/interrupt.h> | 43 | #include <linux/interrupt.h> |
43 | #include <linux/if_ether.h> | 44 | #include <linux/if_ether.h> |
44 | #ifdef CONFIG_DCA | 45 | #ifdef CONFIG_IGB_DCA |
45 | #include <linux/dca.h> | 46 | #include <linux/dca.h> |
46 | #endif | 47 | #endif |
47 | #include "igb.h" | 48 | #include "igb.h" |
@@ -106,11 +107,11 @@ static irqreturn_t igb_msix_other(int irq, void *); | |||
106 | static irqreturn_t igb_msix_rx(int irq, void *); | 107 | static irqreturn_t igb_msix_rx(int irq, void *); |
107 | static irqreturn_t igb_msix_tx(int irq, void *); | 108 | static irqreturn_t igb_msix_tx(int irq, void *); |
108 | static int igb_clean_rx_ring_msix(struct napi_struct *, int); | 109 | static int igb_clean_rx_ring_msix(struct napi_struct *, int); |
109 | #ifdef CONFIG_DCA | 110 | #ifdef CONFIG_IGB_DCA |
110 | static void igb_update_rx_dca(struct igb_ring *); | 111 | static void igb_update_rx_dca(struct igb_ring *); |
111 | static void igb_update_tx_dca(struct igb_ring *); | 112 | static void igb_update_tx_dca(struct igb_ring *); |
112 | static void igb_setup_dca(struct igb_adapter *); | 113 | static void igb_setup_dca(struct igb_adapter *); |
113 | #endif /* CONFIG_DCA */ | 114 | #endif /* CONFIG_IGB_DCA */ |
114 | static bool igb_clean_tx_irq(struct igb_ring *); | 115 | static bool igb_clean_tx_irq(struct igb_ring *); |
115 | static int igb_poll(struct napi_struct *, int); | 116 | static int igb_poll(struct napi_struct *, int); |
116 | static bool igb_clean_rx_irq_adv(struct igb_ring *, int *, int); | 117 | static bool igb_clean_rx_irq_adv(struct igb_ring *, int *, int); |
@@ -131,7 +132,7 @@ static int igb_suspend(struct pci_dev *, pm_message_t); | |||
131 | static int igb_resume(struct pci_dev *); | 132 | static int igb_resume(struct pci_dev *); |
132 | #endif | 133 | #endif |
133 | static void igb_shutdown(struct pci_dev *); | 134 | static void igb_shutdown(struct pci_dev *); |
134 | #ifdef CONFIG_DCA | 135 | #ifdef CONFIG_IGB_DCA |
135 | static int igb_notify_dca(struct notifier_block *, unsigned long, void *); | 136 | static int igb_notify_dca(struct notifier_block *, unsigned long, void *); |
136 | static struct notifier_block dca_notifier = { | 137 | static struct notifier_block dca_notifier = { |
137 | .notifier_call = igb_notify_dca, | 138 | .notifier_call = igb_notify_dca, |
@@ -207,7 +208,7 @@ static int __init igb_init_module(void) | |||
207 | global_quad_port_a = 0; | 208 | global_quad_port_a = 0; |
208 | 209 | ||
209 | ret = pci_register_driver(&igb_driver); | 210 | ret = pci_register_driver(&igb_driver); |
210 | #ifdef CONFIG_DCA | 211 | #ifdef CONFIG_IGB_DCA |
211 | dca_register_notify(&dca_notifier); | 212 | dca_register_notify(&dca_notifier); |
212 | #endif | 213 | #endif |
213 | return ret; | 214 | return ret; |
@@ -223,7 +224,7 @@ module_init(igb_init_module); | |||
223 | **/ | 224 | **/ |
224 | static void __exit igb_exit_module(void) | 225 | static void __exit igb_exit_module(void) |
225 | { | 226 | { |
226 | #ifdef CONFIG_DCA | 227 | #ifdef CONFIG_IGB_DCA |
227 | dca_unregister_notify(&dca_notifier); | 228 | dca_unregister_notify(&dca_notifier); |
228 | #endif | 229 | #endif |
229 | pci_unregister_driver(&igb_driver); | 230 | pci_unregister_driver(&igb_driver); |
@@ -966,10 +967,11 @@ static int __devinit igb_probe(struct pci_dev *pdev, | |||
966 | struct net_device *netdev; | 967 | struct net_device *netdev; |
967 | struct igb_adapter *adapter; | 968 | struct igb_adapter *adapter; |
968 | struct e1000_hw *hw; | 969 | struct e1000_hw *hw; |
970 | struct pci_dev *us_dev; | ||
969 | const struct e1000_info *ei = igb_info_tbl[ent->driver_data]; | 971 | const struct e1000_info *ei = igb_info_tbl[ent->driver_data]; |
970 | unsigned long mmio_start, mmio_len; | 972 | unsigned long mmio_start, mmio_len; |
971 | int i, err, pci_using_dac; | 973 | int i, err, pci_using_dac, pos; |
972 | u16 eeprom_data = 0; | 974 | u16 eeprom_data = 0, state = 0; |
973 | u16 eeprom_apme_mask = IGB_EEPROM_APME; | 975 | u16 eeprom_apme_mask = IGB_EEPROM_APME; |
974 | u32 part_num; | 976 | u32 part_num; |
975 | int bars, need_ioport; | 977 | int bars, need_ioport; |
@@ -1004,6 +1006,28 @@ static int __devinit igb_probe(struct pci_dev *pdev, | |||
1004 | } | 1006 | } |
1005 | } | 1007 | } |
1006 | 1008 | ||
1009 | /* 82575 requires that the pci-e link partner disable the L0s state */ | ||
1010 | switch (pdev->device) { | ||
1011 | case E1000_DEV_ID_82575EB_COPPER: | ||
1012 | case E1000_DEV_ID_82575EB_FIBER_SERDES: | ||
1013 | case E1000_DEV_ID_82575GB_QUAD_COPPER: | ||
1014 | us_dev = pdev->bus->self; | ||
1015 | pos = pci_find_capability(us_dev, PCI_CAP_ID_EXP); | ||
1016 | if (pos) { | ||
1017 | pci_read_config_word(us_dev, pos + PCI_EXP_LNKCTL, | ||
1018 | &state); | ||
1019 | state &= ~PCIE_LINK_STATE_L0S; | ||
1020 | pci_write_config_word(us_dev, pos + PCI_EXP_LNKCTL, | ||
1021 | state); | ||
1022 | printk(KERN_INFO "Disabling ASPM L0s upstream switch " | ||
1023 | "port %x:%x.%x\n", us_dev->bus->number, | ||
1024 | PCI_SLOT(us_dev->devfn), | ||
1025 | PCI_FUNC(us_dev->devfn)); | ||
1026 | } | ||
1027 | default: | ||
1028 | break; | ||
1029 | } | ||
1030 | |||
1007 | err = pci_request_selected_regions(pdev, bars, igb_driver_name); | 1031 | err = pci_request_selected_regions(pdev, bars, igb_driver_name); |
1008 | if (err) | 1032 | if (err) |
1009 | goto err_pci_reg; | 1033 | goto err_pci_reg; |
@@ -1237,7 +1261,7 @@ static int __devinit igb_probe(struct pci_dev *pdev, | |||
1237 | if (err) | 1261 | if (err) |
1238 | goto err_register; | 1262 | goto err_register; |
1239 | 1263 | ||
1240 | #ifdef CONFIG_DCA | 1264 | #ifdef CONFIG_IGB_DCA |
1241 | if ((adapter->flags & IGB_FLAG_HAS_DCA) && | 1265 | if ((adapter->flags & IGB_FLAG_HAS_DCA) && |
1242 | (dca_add_requester(&pdev->dev) == 0)) { | 1266 | (dca_add_requester(&pdev->dev) == 0)) { |
1243 | adapter->flags |= IGB_FLAG_DCA_ENABLED; | 1267 | adapter->flags |= IGB_FLAG_DCA_ENABLED; |
@@ -1311,7 +1335,7 @@ static void __devexit igb_remove(struct pci_dev *pdev) | |||
1311 | { | 1335 | { |
1312 | struct net_device *netdev = pci_get_drvdata(pdev); | 1336 | struct net_device *netdev = pci_get_drvdata(pdev); |
1313 | struct igb_adapter *adapter = netdev_priv(netdev); | 1337 | struct igb_adapter *adapter = netdev_priv(netdev); |
1314 | #ifdef CONFIG_DCA | 1338 | #ifdef CONFIG_IGB_DCA |
1315 | struct e1000_hw *hw = &adapter->hw; | 1339 | struct e1000_hw *hw = &adapter->hw; |
1316 | #endif | 1340 | #endif |
1317 | 1341 | ||
@@ -1323,7 +1347,7 @@ static void __devexit igb_remove(struct pci_dev *pdev) | |||
1323 | 1347 | ||
1324 | flush_scheduled_work(); | 1348 | flush_scheduled_work(); |
1325 | 1349 | ||
1326 | #ifdef CONFIG_DCA | 1350 | #ifdef CONFIG_IGB_DCA |
1327 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) { | 1351 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) { |
1328 | dev_info(&pdev->dev, "DCA disabled\n"); | 1352 | dev_info(&pdev->dev, "DCA disabled\n"); |
1329 | dca_remove_requester(&pdev->dev); | 1353 | dca_remove_requester(&pdev->dev); |
@@ -3271,7 +3295,7 @@ static irqreturn_t igb_msix_tx(int irq, void *data) | |||
3271 | struct igb_adapter *adapter = tx_ring->adapter; | 3295 | struct igb_adapter *adapter = tx_ring->adapter; |
3272 | struct e1000_hw *hw = &adapter->hw; | 3296 | struct e1000_hw *hw = &adapter->hw; |
3273 | 3297 | ||
3274 | #ifdef CONFIG_DCA | 3298 | #ifdef CONFIG_IGB_DCA |
3275 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) | 3299 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) |
3276 | igb_update_tx_dca(tx_ring); | 3300 | igb_update_tx_dca(tx_ring); |
3277 | #endif | 3301 | #endif |
@@ -3323,14 +3347,14 @@ static irqreturn_t igb_msix_rx(int irq, void *data) | |||
3323 | if (netif_rx_schedule_prep(adapter->netdev, &rx_ring->napi)) | 3347 | if (netif_rx_schedule_prep(adapter->netdev, &rx_ring->napi)) |
3324 | __netif_rx_schedule(adapter->netdev, &rx_ring->napi); | 3348 | __netif_rx_schedule(adapter->netdev, &rx_ring->napi); |
3325 | 3349 | ||
3326 | #ifdef CONFIG_DCA | 3350 | #ifdef CONFIG_IGB_DCA |
3327 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) | 3351 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) |
3328 | igb_update_rx_dca(rx_ring); | 3352 | igb_update_rx_dca(rx_ring); |
3329 | #endif | 3353 | #endif |
3330 | return IRQ_HANDLED; | 3354 | return IRQ_HANDLED; |
3331 | } | 3355 | } |
3332 | 3356 | ||
3333 | #ifdef CONFIG_DCA | 3357 | #ifdef CONFIG_IGB_DCA |
3334 | static void igb_update_rx_dca(struct igb_ring *rx_ring) | 3358 | static void igb_update_rx_dca(struct igb_ring *rx_ring) |
3335 | { | 3359 | { |
3336 | u32 dca_rxctrl; | 3360 | u32 dca_rxctrl; |
@@ -3450,7 +3474,7 @@ static int igb_notify_dca(struct notifier_block *nb, unsigned long event, | |||
3450 | 3474 | ||
3451 | return ret_val ? NOTIFY_BAD : NOTIFY_DONE; | 3475 | return ret_val ? NOTIFY_BAD : NOTIFY_DONE; |
3452 | } | 3476 | } |
3453 | #endif /* CONFIG_DCA */ | 3477 | #endif /* CONFIG_IGB_DCA */ |
3454 | 3478 | ||
3455 | /** | 3479 | /** |
3456 | * igb_intr_msi - Interrupt Handler | 3480 | * igb_intr_msi - Interrupt Handler |
@@ -3529,13 +3553,13 @@ static int igb_poll(struct napi_struct *napi, int budget) | |||
3529 | int tx_clean_complete, work_done = 0; | 3553 | int tx_clean_complete, work_done = 0; |
3530 | 3554 | ||
3531 | /* this poll routine only supports one tx and one rx queue */ | 3555 | /* this poll routine only supports one tx and one rx queue */ |
3532 | #ifdef CONFIG_DCA | 3556 | #ifdef CONFIG_IGB_DCA |
3533 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) | 3557 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) |
3534 | igb_update_tx_dca(&adapter->tx_ring[0]); | 3558 | igb_update_tx_dca(&adapter->tx_ring[0]); |
3535 | #endif | 3559 | #endif |
3536 | tx_clean_complete = igb_clean_tx_irq(&adapter->tx_ring[0]); | 3560 | tx_clean_complete = igb_clean_tx_irq(&adapter->tx_ring[0]); |
3537 | 3561 | ||
3538 | #ifdef CONFIG_DCA | 3562 | #ifdef CONFIG_IGB_DCA |
3539 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) | 3563 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) |
3540 | igb_update_rx_dca(&adapter->rx_ring[0]); | 3564 | igb_update_rx_dca(&adapter->rx_ring[0]); |
3541 | #endif | 3565 | #endif |
@@ -3563,7 +3587,7 @@ static int igb_clean_rx_ring_msix(struct napi_struct *napi, int budget) | |||
3563 | struct net_device *netdev = adapter->netdev; | 3587 | struct net_device *netdev = adapter->netdev; |
3564 | int work_done = 0; | 3588 | int work_done = 0; |
3565 | 3589 | ||
3566 | #ifdef CONFIG_DCA | 3590 | #ifdef CONFIG_IGB_DCA |
3567 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) | 3591 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) |
3568 | igb_update_rx_dca(rx_ring); | 3592 | igb_update_rx_dca(rx_ring); |
3569 | #endif | 3593 | #endif |
diff --git a/drivers/net/myri10ge/myri10ge.c b/drivers/net/myri10ge/myri10ge.c index a9aebad52652..b1556b2e404c 100644 --- a/drivers/net/myri10ge/myri10ge.c +++ b/drivers/net/myri10ge/myri10ge.c | |||
@@ -75,7 +75,7 @@ | |||
75 | #include "myri10ge_mcp.h" | 75 | #include "myri10ge_mcp.h" |
76 | #include "myri10ge_mcp_gen_header.h" | 76 | #include "myri10ge_mcp_gen_header.h" |
77 | 77 | ||
78 | #define MYRI10GE_VERSION_STR "1.4.3-1.369" | 78 | #define MYRI10GE_VERSION_STR "1.4.3-1.371" |
79 | 79 | ||
80 | MODULE_DESCRIPTION("Myricom 10G driver (10GbE)"); | 80 | MODULE_DESCRIPTION("Myricom 10G driver (10GbE)"); |
81 | MODULE_AUTHOR("Maintainer: help@myri.com"); | 81 | MODULE_AUTHOR("Maintainer: help@myri.com"); |
@@ -2497,6 +2497,10 @@ static int myri10ge_open(struct net_device *dev) | |||
2497 | return 0; | 2497 | return 0; |
2498 | 2498 | ||
2499 | abort_with_rings: | 2499 | abort_with_rings: |
2500 | while (slice) { | ||
2501 | slice--; | ||
2502 | napi_disable(&mgp->ss[slice].napi); | ||
2503 | } | ||
2500 | for (i = 0; i < mgp->num_slices; i++) | 2504 | for (i = 0; i < mgp->num_slices; i++) |
2501 | myri10ge_free_rings(&mgp->ss[i]); | 2505 | myri10ge_free_rings(&mgp->ss[i]); |
2502 | 2506 | ||
diff --git a/drivers/net/qlge/qlge.h b/drivers/net/qlge/qlge.h index 38116f9d4163..ba2e1c5b6bcf 100644 --- a/drivers/net/qlge/qlge.h +++ b/drivers/net/qlge/qlge.h | |||
@@ -1375,7 +1375,6 @@ struct ql_adapter { | |||
1375 | spinlock_t adapter_lock; | 1375 | spinlock_t adapter_lock; |
1376 | spinlock_t hw_lock; | 1376 | spinlock_t hw_lock; |
1377 | spinlock_t stats_lock; | 1377 | spinlock_t stats_lock; |
1378 | spinlock_t legacy_lock; /* used for maintaining legacy intr sync */ | ||
1379 | 1378 | ||
1380 | /* PCI Bus Relative Register Addresses */ | 1379 | /* PCI Bus Relative Register Addresses */ |
1381 | void __iomem *reg_base; | 1380 | void __iomem *reg_base; |
@@ -1399,8 +1398,6 @@ struct ql_adapter { | |||
1399 | struct msix_entry *msi_x_entry; | 1398 | struct msix_entry *msi_x_entry; |
1400 | struct intr_context intr_context[MAX_RX_RINGS]; | 1399 | struct intr_context intr_context[MAX_RX_RINGS]; |
1401 | 1400 | ||
1402 | int (*legacy_check) (struct ql_adapter *); | ||
1403 | |||
1404 | int tx_ring_count; /* One per online CPU. */ | 1401 | int tx_ring_count; /* One per online CPU. */ |
1405 | u32 rss_ring_first_cq_id;/* index of first inbound (rss) rx_ring */ | 1402 | u32 rss_ring_first_cq_id;/* index of first inbound (rss) rx_ring */ |
1406 | u32 rss_ring_count; /* One per online CPU. */ | 1403 | u32 rss_ring_count; /* One per online CPU. */ |
@@ -1502,7 +1499,7 @@ void ql_mpi_work(struct work_struct *work); | |||
1502 | void ql_mpi_reset_work(struct work_struct *work); | 1499 | void ql_mpi_reset_work(struct work_struct *work); |
1503 | int ql_wait_reg_rdy(struct ql_adapter *qdev, u32 reg, u32 bit, u32 ebit); | 1500 | int ql_wait_reg_rdy(struct ql_adapter *qdev, u32 reg, u32 bit, u32 ebit); |
1504 | void ql_queue_asic_error(struct ql_adapter *qdev); | 1501 | void ql_queue_asic_error(struct ql_adapter *qdev); |
1505 | void ql_enable_completion_interrupt(struct ql_adapter *qdev, u32 intr); | 1502 | u32 ql_enable_completion_interrupt(struct ql_adapter *qdev, u32 intr); |
1506 | void ql_set_ethtool_ops(struct net_device *ndev); | 1503 | void ql_set_ethtool_ops(struct net_device *ndev); |
1507 | int ql_read_xgmac_reg64(struct ql_adapter *qdev, u32 reg, u64 *data); | 1504 | int ql_read_xgmac_reg64(struct ql_adapter *qdev, u32 reg, u64 *data); |
1508 | 1505 | ||
diff --git a/drivers/net/qlge/qlge_main.c b/drivers/net/qlge/qlge_main.c index 4b2caa6b7ac5..b83a9c9b6a97 100644 --- a/drivers/net/qlge/qlge_main.c +++ b/drivers/net/qlge/qlge_main.c | |||
@@ -577,41 +577,53 @@ static void ql_disable_interrupts(struct ql_adapter *qdev) | |||
577 | * incremented everytime we queue a worker and decremented everytime | 577 | * incremented everytime we queue a worker and decremented everytime |
578 | * a worker finishes. Once it hits zero we enable the interrupt. | 578 | * a worker finishes. Once it hits zero we enable the interrupt. |
579 | */ | 579 | */ |
580 | void ql_enable_completion_interrupt(struct ql_adapter *qdev, u32 intr) | 580 | u32 ql_enable_completion_interrupt(struct ql_adapter *qdev, u32 intr) |
581 | { | 581 | { |
582 | if (likely(test_bit(QL_MSIX_ENABLED, &qdev->flags))) | 582 | u32 var = 0; |
583 | unsigned long hw_flags = 0; | ||
584 | struct intr_context *ctx = qdev->intr_context + intr; | ||
585 | |||
586 | if (likely(test_bit(QL_MSIX_ENABLED, &qdev->flags) && intr)) { | ||
587 | /* Always enable if we're MSIX multi interrupts and | ||
588 | * it's not the default (zeroeth) interrupt. | ||
589 | */ | ||
583 | ql_write32(qdev, INTR_EN, | 590 | ql_write32(qdev, INTR_EN, |
584 | qdev->intr_context[intr].intr_en_mask); | 591 | ctx->intr_en_mask); |
585 | else { | 592 | var = ql_read32(qdev, STS); |
586 | if (qdev->legacy_check) | 593 | return var; |
587 | spin_lock(&qdev->legacy_lock); | ||
588 | if (atomic_dec_and_test(&qdev->intr_context[intr].irq_cnt)) { | ||
589 | QPRINTK(qdev, INTR, ERR, "Enabling interrupt %d.\n", | ||
590 | intr); | ||
591 | ql_write32(qdev, INTR_EN, | ||
592 | qdev->intr_context[intr].intr_en_mask); | ||
593 | } else { | ||
594 | QPRINTK(qdev, INTR, ERR, | ||
595 | "Skip enable, other queue(s) are active.\n"); | ||
596 | } | ||
597 | if (qdev->legacy_check) | ||
598 | spin_unlock(&qdev->legacy_lock); | ||
599 | } | 594 | } |
595 | |||
596 | spin_lock_irqsave(&qdev->hw_lock, hw_flags); | ||
597 | if (atomic_dec_and_test(&ctx->irq_cnt)) { | ||
598 | ql_write32(qdev, INTR_EN, | ||
599 | ctx->intr_en_mask); | ||
600 | var = ql_read32(qdev, STS); | ||
601 | } | ||
602 | spin_unlock_irqrestore(&qdev->hw_lock, hw_flags); | ||
603 | return var; | ||
600 | } | 604 | } |
601 | 605 | ||
602 | static u32 ql_disable_completion_interrupt(struct ql_adapter *qdev, u32 intr) | 606 | static u32 ql_disable_completion_interrupt(struct ql_adapter *qdev, u32 intr) |
603 | { | 607 | { |
604 | u32 var = 0; | 608 | u32 var = 0; |
609 | unsigned long hw_flags; | ||
610 | struct intr_context *ctx; | ||
605 | 611 | ||
606 | if (likely(test_bit(QL_MSIX_ENABLED, &qdev->flags))) | 612 | /* HW disables for us if we're MSIX multi interrupts and |
607 | goto exit; | 613 | * it's not the default (zeroeth) interrupt. |
608 | else if (!atomic_read(&qdev->intr_context[intr].irq_cnt)) { | 614 | */ |
615 | if (likely(test_bit(QL_MSIX_ENABLED, &qdev->flags) && intr)) | ||
616 | return 0; | ||
617 | |||
618 | ctx = qdev->intr_context + intr; | ||
619 | spin_lock_irqsave(&qdev->hw_lock, hw_flags); | ||
620 | if (!atomic_read(&ctx->irq_cnt)) { | ||
609 | ql_write32(qdev, INTR_EN, | 621 | ql_write32(qdev, INTR_EN, |
610 | qdev->intr_context[intr].intr_dis_mask); | 622 | ctx->intr_dis_mask); |
611 | var = ql_read32(qdev, STS); | 623 | var = ql_read32(qdev, STS); |
612 | } | 624 | } |
613 | atomic_inc(&qdev->intr_context[intr].irq_cnt); | 625 | atomic_inc(&ctx->irq_cnt); |
614 | exit: | 626 | spin_unlock_irqrestore(&qdev->hw_lock, hw_flags); |
615 | return var; | 627 | return var; |
616 | } | 628 | } |
617 | 629 | ||
@@ -623,7 +635,9 @@ static void ql_enable_all_completion_interrupts(struct ql_adapter *qdev) | |||
623 | * and enables only if the result is zero. | 635 | * and enables only if the result is zero. |
624 | * So we precharge it here. | 636 | * So we precharge it here. |
625 | */ | 637 | */ |
626 | atomic_set(&qdev->intr_context[i].irq_cnt, 1); | 638 | if (unlikely(!test_bit(QL_MSIX_ENABLED, &qdev->flags) || |
639 | i == 0)) | ||
640 | atomic_set(&qdev->intr_context[i].irq_cnt, 1); | ||
627 | ql_enable_completion_interrupt(qdev, i); | 641 | ql_enable_completion_interrupt(qdev, i); |
628 | } | 642 | } |
629 | 643 | ||
@@ -1725,19 +1739,6 @@ static irqreturn_t qlge_msix_rx_isr(int irq, void *dev_id) | |||
1725 | return IRQ_HANDLED; | 1739 | return IRQ_HANDLED; |
1726 | } | 1740 | } |
1727 | 1741 | ||
1728 | /* We check here to see if we're already handling a legacy | ||
1729 | * interrupt. If we are, then it must belong to another | ||
1730 | * chip with which we're sharing the interrupt line. | ||
1731 | */ | ||
1732 | int ql_legacy_check(struct ql_adapter *qdev) | ||
1733 | { | ||
1734 | int err; | ||
1735 | spin_lock(&qdev->legacy_lock); | ||
1736 | err = atomic_read(&qdev->intr_context[0].irq_cnt); | ||
1737 | spin_unlock(&qdev->legacy_lock); | ||
1738 | return err; | ||
1739 | } | ||
1740 | |||
1741 | /* This handles a fatal error, MPI activity, and the default | 1742 | /* This handles a fatal error, MPI activity, and the default |
1742 | * rx_ring in an MSI-X multiple vector environment. | 1743 | * rx_ring in an MSI-X multiple vector environment. |
1743 | * In MSI/Legacy environment it also process the rest of | 1744 | * In MSI/Legacy environment it also process the rest of |
@@ -1752,12 +1753,15 @@ static irqreturn_t qlge_isr(int irq, void *dev_id) | |||
1752 | int i; | 1753 | int i; |
1753 | int work_done = 0; | 1754 | int work_done = 0; |
1754 | 1755 | ||
1755 | if (qdev->legacy_check && qdev->legacy_check(qdev)) { | 1756 | spin_lock(&qdev->hw_lock); |
1756 | QPRINTK(qdev, INTR, INFO, "Already busy, not our interrupt.\n"); | 1757 | if (atomic_read(&qdev->intr_context[0].irq_cnt)) { |
1757 | return IRQ_NONE; /* Not our interrupt */ | 1758 | QPRINTK(qdev, INTR, DEBUG, "Shared Interrupt, Not ours!\n"); |
1759 | spin_unlock(&qdev->hw_lock); | ||
1760 | return IRQ_NONE; | ||
1758 | } | 1761 | } |
1762 | spin_unlock(&qdev->hw_lock); | ||
1759 | 1763 | ||
1760 | var = ql_read32(qdev, STS); | 1764 | var = ql_disable_completion_interrupt(qdev, intr_context->intr); |
1761 | 1765 | ||
1762 | /* | 1766 | /* |
1763 | * Check for fatal error. | 1767 | * Check for fatal error. |
@@ -1823,6 +1827,7 @@ static irqreturn_t qlge_isr(int irq, void *dev_id) | |||
1823 | } | 1827 | } |
1824 | } | 1828 | } |
1825 | } | 1829 | } |
1830 | ql_enable_completion_interrupt(qdev, intr_context->intr); | ||
1826 | return work_done ? IRQ_HANDLED : IRQ_NONE; | 1831 | return work_done ? IRQ_HANDLED : IRQ_NONE; |
1827 | } | 1832 | } |
1828 | 1833 | ||
@@ -2701,8 +2706,6 @@ msi: | |||
2701 | } | 2706 | } |
2702 | } | 2707 | } |
2703 | irq_type = LEG_IRQ; | 2708 | irq_type = LEG_IRQ; |
2704 | spin_lock_init(&qdev->legacy_lock); | ||
2705 | qdev->legacy_check = ql_legacy_check; | ||
2706 | QPRINTK(qdev, IFUP, DEBUG, "Running with legacy interrupts.\n"); | 2709 | QPRINTK(qdev, IFUP, DEBUG, "Running with legacy interrupts.\n"); |
2707 | } | 2710 | } |
2708 | 2711 | ||
diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c index c821da21d8eb..4b7cb389dc49 100644 --- a/drivers/net/r8169.c +++ b/drivers/net/r8169.c | |||
@@ -81,6 +81,10 @@ static const int multicast_filter_limit = 32; | |||
81 | #define RTL8169_TX_TIMEOUT (6*HZ) | 81 | #define RTL8169_TX_TIMEOUT (6*HZ) |
82 | #define RTL8169_PHY_TIMEOUT (10*HZ) | 82 | #define RTL8169_PHY_TIMEOUT (10*HZ) |
83 | 83 | ||
84 | #define RTL_EEPROM_SIG cpu_to_le32(0x8129) | ||
85 | #define RTL_EEPROM_SIG_MASK cpu_to_le32(0xffff) | ||
86 | #define RTL_EEPROM_SIG_ADDR 0x0000 | ||
87 | |||
84 | /* write/read MMIO register */ | 88 | /* write/read MMIO register */ |
85 | #define RTL_W8(reg, val8) writeb ((val8), ioaddr + (reg)) | 89 | #define RTL_W8(reg, val8) writeb ((val8), ioaddr + (reg)) |
86 | #define RTL_W16(reg, val16) writew ((val16), ioaddr + (reg)) | 90 | #define RTL_W16(reg, val16) writew ((val16), ioaddr + (reg)) |
@@ -1911,74 +1915,6 @@ static void rtl_disable_msi(struct pci_dev *pdev, struct rtl8169_private *tp) | |||
1911 | } | 1915 | } |
1912 | } | 1916 | } |
1913 | 1917 | ||
1914 | static int rtl_eeprom_read(struct pci_dev *pdev, int cap, int addr, __le32 *val) | ||
1915 | { | ||
1916 | int ret, count = 100; | ||
1917 | u16 status = 0; | ||
1918 | u32 value; | ||
1919 | |||
1920 | ret = pci_write_config_word(pdev, cap + PCI_VPD_ADDR, addr); | ||
1921 | if (ret < 0) | ||
1922 | return ret; | ||
1923 | |||
1924 | do { | ||
1925 | udelay(10); | ||
1926 | ret = pci_read_config_word(pdev, cap + PCI_VPD_ADDR, &status); | ||
1927 | if (ret < 0) | ||
1928 | return ret; | ||
1929 | } while (!(status & PCI_VPD_ADDR_F) && --count); | ||
1930 | |||
1931 | if (!(status & PCI_VPD_ADDR_F)) | ||
1932 | return -ETIMEDOUT; | ||
1933 | |||
1934 | ret = pci_read_config_dword(pdev, cap + PCI_VPD_DATA, &value); | ||
1935 | if (ret < 0) | ||
1936 | return ret; | ||
1937 | |||
1938 | *val = cpu_to_le32(value); | ||
1939 | |||
1940 | return 0; | ||
1941 | } | ||
1942 | |||
1943 | static void rtl_init_mac_address(struct rtl8169_private *tp, | ||
1944 | void __iomem *ioaddr) | ||
1945 | { | ||
1946 | struct pci_dev *pdev = tp->pci_dev; | ||
1947 | u8 cfg1; | ||
1948 | int vpd_cap; | ||
1949 | u8 mac[8]; | ||
1950 | DECLARE_MAC_BUF(buf); | ||
1951 | |||
1952 | cfg1 = RTL_R8(Config1); | ||
1953 | if (!(cfg1 & VPD)) { | ||
1954 | dprintk("VPD access not enabled, enabling\n"); | ||
1955 | RTL_W8(Cfg9346, Cfg9346_Unlock); | ||
1956 | RTL_W8(Config1, cfg1 | VPD); | ||
1957 | RTL_W8(Cfg9346, Cfg9346_Lock); | ||
1958 | } | ||
1959 | |||
1960 | vpd_cap = pci_find_capability(pdev, PCI_CAP_ID_VPD); | ||
1961 | if (!vpd_cap) | ||
1962 | return; | ||
1963 | |||
1964 | /* MAC address is stored in EEPROM at offset 0x0e | ||
1965 | * Realtek says: "The VPD address does not have to be a DWORD-aligned | ||
1966 | * address as defined in the PCI 2.2 Specifications, but the VPD data | ||
1967 | * is always consecutive 4-byte data starting from the VPD address | ||
1968 | * specified." | ||
1969 | */ | ||
1970 | if (rtl_eeprom_read(pdev, vpd_cap, 0x000e, (__le32*)&mac[0]) < 0 || | ||
1971 | rtl_eeprom_read(pdev, vpd_cap, 0x0012, (__le32*)&mac[4]) < 0) { | ||
1972 | dprintk("Reading MAC address from EEPROM failed\n"); | ||
1973 | return; | ||
1974 | } | ||
1975 | |||
1976 | dprintk("MAC address found in EEPROM: %s\n", print_mac(buf, mac)); | ||
1977 | |||
1978 | /* Write MAC address */ | ||
1979 | rtl_rar_set(tp, mac); | ||
1980 | } | ||
1981 | |||
1982 | static int __devinit | 1918 | static int __devinit |
1983 | rtl8169_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) | 1919 | rtl8169_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) |
1984 | { | 1920 | { |
@@ -2156,8 +2092,6 @@ rtl8169_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
2156 | 2092 | ||
2157 | tp->mmio_addr = ioaddr; | 2093 | tp->mmio_addr = ioaddr; |
2158 | 2094 | ||
2159 | rtl_init_mac_address(tp, ioaddr); | ||
2160 | |||
2161 | /* Get MAC address */ | 2095 | /* Get MAC address */ |
2162 | for (i = 0; i < MAC_ADDR_LEN; i++) | 2096 | for (i = 0; i < MAC_ADDR_LEN; i++) |
2163 | dev->dev_addr[i] = RTL_R8(MAC0 + i); | 2097 | dev->dev_addr[i] = RTL_R8(MAC0 + i); |
diff --git a/drivers/net/sis190.c b/drivers/net/sis190.c index 3fe01763760e..e6e3bf58a569 100644 --- a/drivers/net/sis190.c +++ b/drivers/net/sis190.c | |||
@@ -317,6 +317,7 @@ static struct mii_chip_info { | |||
317 | unsigned int type; | 317 | unsigned int type; |
318 | u32 feature; | 318 | u32 feature; |
319 | } mii_chip_table[] = { | 319 | } mii_chip_table[] = { |
320 | { "Atheros PHY AR8012", { 0x004d, 0xd020 }, LAN, 0 }, | ||
320 | { "Broadcom PHY BCM5461", { 0x0020, 0x60c0 }, LAN, F_PHY_BCM5461 }, | 321 | { "Broadcom PHY BCM5461", { 0x0020, 0x60c0 }, LAN, F_PHY_BCM5461 }, |
321 | { "Broadcom PHY AC131", { 0x0143, 0xbc70 }, LAN, 0 }, | 322 | { "Broadcom PHY AC131", { 0x0143, 0xbc70 }, LAN, 0 }, |
322 | { "Agere PHY ET1101B", { 0x0282, 0xf010 }, LAN, 0 }, | 323 | { "Agere PHY ET1101B", { 0x0282, 0xf010 }, LAN, 0 }, |
diff --git a/drivers/net/smc911x.c b/drivers/net/smc911x.c index 8aa7460ef0e3..f59c7772f344 100644 --- a/drivers/net/smc911x.c +++ b/drivers/net/smc911x.c | |||
@@ -155,23 +155,17 @@ static void PRINT_PKT(u_char *buf, int length) | |||
155 | /* this enables an interrupt in the interrupt mask register */ | 155 | /* this enables an interrupt in the interrupt mask register */ |
156 | #define SMC_ENABLE_INT(lp, x) do { \ | 156 | #define SMC_ENABLE_INT(lp, x) do { \ |
157 | unsigned int __mask; \ | 157 | unsigned int __mask; \ |
158 | unsigned long __flags; \ | ||
159 | spin_lock_irqsave(&lp->lock, __flags); \ | ||
160 | __mask = SMC_GET_INT_EN((lp)); \ | 158 | __mask = SMC_GET_INT_EN((lp)); \ |
161 | __mask |= (x); \ | 159 | __mask |= (x); \ |
162 | SMC_SET_INT_EN((lp), __mask); \ | 160 | SMC_SET_INT_EN((lp), __mask); \ |
163 | spin_unlock_irqrestore(&lp->lock, __flags); \ | ||
164 | } while (0) | 161 | } while (0) |
165 | 162 | ||
166 | /* this disables an interrupt from the interrupt mask register */ | 163 | /* this disables an interrupt from the interrupt mask register */ |
167 | #define SMC_DISABLE_INT(lp, x) do { \ | 164 | #define SMC_DISABLE_INT(lp, x) do { \ |
168 | unsigned int __mask; \ | 165 | unsigned int __mask; \ |
169 | unsigned long __flags; \ | ||
170 | spin_lock_irqsave(&lp->lock, __flags); \ | ||
171 | __mask = SMC_GET_INT_EN((lp)); \ | 166 | __mask = SMC_GET_INT_EN((lp)); \ |
172 | __mask &= ~(x); \ | 167 | __mask &= ~(x); \ |
173 | SMC_SET_INT_EN((lp), __mask); \ | 168 | SMC_SET_INT_EN((lp), __mask); \ |
174 | spin_unlock_irqrestore(&lp->lock, __flags); \ | ||
175 | } while (0) | 169 | } while (0) |
176 | 170 | ||
177 | /* | 171 | /* |
@@ -180,7 +174,7 @@ static void PRINT_PKT(u_char *buf, int length) | |||
180 | static void smc911x_reset(struct net_device *dev) | 174 | static void smc911x_reset(struct net_device *dev) |
181 | { | 175 | { |
182 | struct smc911x_local *lp = netdev_priv(dev); | 176 | struct smc911x_local *lp = netdev_priv(dev); |
183 | unsigned int reg, timeout=0, resets=1; | 177 | unsigned int reg, timeout=0, resets=1, irq_cfg; |
184 | unsigned long flags; | 178 | unsigned long flags; |
185 | 179 | ||
186 | DBG(SMC_DEBUG_FUNC, "%s: --> %s\n", dev->name, __func__); | 180 | DBG(SMC_DEBUG_FUNC, "%s: --> %s\n", dev->name, __func__); |
@@ -252,7 +246,12 @@ static void smc911x_reset(struct net_device *dev) | |||
252 | * Deassert IRQ for 1*10us for edge type interrupts | 246 | * Deassert IRQ for 1*10us for edge type interrupts |
253 | * and drive IRQ pin push-pull | 247 | * and drive IRQ pin push-pull |
254 | */ | 248 | */ |
255 | SMC_SET_IRQ_CFG(lp, (1 << 24) | INT_CFG_IRQ_EN_ | INT_CFG_IRQ_TYPE_); | 249 | irq_cfg = (1 << 24) | INT_CFG_IRQ_EN_ | INT_CFG_IRQ_TYPE_; |
250 | #ifdef SMC_DYNAMIC_BUS_CONFIG | ||
251 | if (lp->cfg.irq_polarity) | ||
252 | irq_cfg |= INT_CFG_IRQ_POL_; | ||
253 | #endif | ||
254 | SMC_SET_IRQ_CFG(lp, irq_cfg); | ||
256 | 255 | ||
257 | /* clear anything saved */ | 256 | /* clear anything saved */ |
258 | if (lp->pending_tx_skb != NULL) { | 257 | if (lp->pending_tx_skb != NULL) { |
@@ -274,6 +273,8 @@ static void smc911x_enable(struct net_device *dev) | |||
274 | 273 | ||
275 | DBG(SMC_DEBUG_FUNC, "%s: --> %s\n", dev->name, __func__); | 274 | DBG(SMC_DEBUG_FUNC, "%s: --> %s\n", dev->name, __func__); |
276 | 275 | ||
276 | spin_lock_irqsave(&lp->lock, flags); | ||
277 | |||
277 | SMC_SET_MAC_ADDR(lp, dev->dev_addr); | 278 | SMC_SET_MAC_ADDR(lp, dev->dev_addr); |
278 | 279 | ||
279 | /* Enable TX */ | 280 | /* Enable TX */ |
@@ -286,12 +287,10 @@ static void smc911x_enable(struct net_device *dev) | |||
286 | SMC_SET_FIFO_TSL(lp, 64); | 287 | SMC_SET_FIFO_TSL(lp, 64); |
287 | SMC_SET_GPT_CFG(lp, GPT_CFG_TIMER_EN_ | 10000); | 288 | SMC_SET_GPT_CFG(lp, GPT_CFG_TIMER_EN_ | 10000); |
288 | 289 | ||
289 | spin_lock_irqsave(&lp->lock, flags); | ||
290 | SMC_GET_MAC_CR(lp, cr); | 290 | SMC_GET_MAC_CR(lp, cr); |
291 | cr |= MAC_CR_TXEN_ | MAC_CR_HBDIS_; | 291 | cr |= MAC_CR_TXEN_ | MAC_CR_HBDIS_; |
292 | SMC_SET_MAC_CR(lp, cr); | 292 | SMC_SET_MAC_CR(lp, cr); |
293 | SMC_SET_TX_CFG(lp, TX_CFG_TX_ON_); | 293 | SMC_SET_TX_CFG(lp, TX_CFG_TX_ON_); |
294 | spin_unlock_irqrestore(&lp->lock, flags); | ||
295 | 294 | ||
296 | /* Add 2 byte padding to start of packets */ | 295 | /* Add 2 byte padding to start of packets */ |
297 | SMC_SET_RX_CFG(lp, (2<<8) & RX_CFG_RXDOFF_); | 296 | SMC_SET_RX_CFG(lp, (2<<8) & RX_CFG_RXDOFF_); |
@@ -300,9 +299,7 @@ static void smc911x_enable(struct net_device *dev) | |||
300 | if (cr & MAC_CR_RXEN_) | 299 | if (cr & MAC_CR_RXEN_) |
301 | DBG(SMC_DEBUG_RX, "%s: Receiver already enabled\n", dev->name); | 300 | DBG(SMC_DEBUG_RX, "%s: Receiver already enabled\n", dev->name); |
302 | 301 | ||
303 | spin_lock_irqsave(&lp->lock, flags); | ||
304 | SMC_SET_MAC_CR(lp, cr | MAC_CR_RXEN_); | 302 | SMC_SET_MAC_CR(lp, cr | MAC_CR_RXEN_); |
305 | spin_unlock_irqrestore(&lp->lock, flags); | ||
306 | 303 | ||
307 | /* Interrupt on every received packet */ | 304 | /* Interrupt on every received packet */ |
308 | SMC_SET_FIFO_RSA(lp, 0x01); | 305 | SMC_SET_FIFO_RSA(lp, 0x01); |
@@ -318,6 +315,8 @@ static void smc911x_enable(struct net_device *dev) | |||
318 | mask|=INT_EN_RDFO_EN_; | 315 | mask|=INT_EN_RDFO_EN_; |
319 | } | 316 | } |
320 | SMC_ENABLE_INT(lp, mask); | 317 | SMC_ENABLE_INT(lp, mask); |
318 | |||
319 | spin_unlock_irqrestore(&lp->lock, flags); | ||
321 | } | 320 | } |
322 | 321 | ||
323 | /* | 322 | /* |
@@ -458,7 +457,6 @@ static void smc911x_hardware_send_pkt(struct net_device *dev) | |||
458 | struct sk_buff *skb; | 457 | struct sk_buff *skb; |
459 | unsigned int cmdA, cmdB, len; | 458 | unsigned int cmdA, cmdB, len; |
460 | unsigned char *buf; | 459 | unsigned char *buf; |
461 | unsigned long flags; | ||
462 | 460 | ||
463 | DBG(SMC_DEBUG_FUNC | SMC_DEBUG_TX, "%s: --> %s\n", dev->name, __func__); | 461 | DBG(SMC_DEBUG_FUNC | SMC_DEBUG_TX, "%s: --> %s\n", dev->name, __func__); |
464 | BUG_ON(lp->pending_tx_skb == NULL); | 462 | BUG_ON(lp->pending_tx_skb == NULL); |
@@ -503,11 +501,9 @@ static void smc911x_hardware_send_pkt(struct net_device *dev) | |||
503 | dev->trans_start = jiffies; | 501 | dev->trans_start = jiffies; |
504 | dev_kfree_skb(skb); | 502 | dev_kfree_skb(skb); |
505 | #endif | 503 | #endif |
506 | spin_lock_irqsave(&lp->lock, flags); | ||
507 | if (!lp->tx_throttle) { | 504 | if (!lp->tx_throttle) { |
508 | netif_wake_queue(dev); | 505 | netif_wake_queue(dev); |
509 | } | 506 | } |
510 | spin_unlock_irqrestore(&lp->lock, flags); | ||
511 | SMC_ENABLE_INT(lp, INT_EN_TDFA_EN_ | INT_EN_TSFL_EN_); | 507 | SMC_ENABLE_INT(lp, INT_EN_TDFA_EN_ | INT_EN_TSFL_EN_); |
512 | } | 508 | } |
513 | 509 | ||
@@ -526,6 +522,8 @@ static int smc911x_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
526 | DBG(SMC_DEBUG_FUNC | SMC_DEBUG_TX, "%s: --> %s\n", | 522 | DBG(SMC_DEBUG_FUNC | SMC_DEBUG_TX, "%s: --> %s\n", |
527 | dev->name, __func__); | 523 | dev->name, __func__); |
528 | 524 | ||
525 | spin_lock_irqsave(&lp->lock, flags); | ||
526 | |||
529 | BUG_ON(lp->pending_tx_skb != NULL); | 527 | BUG_ON(lp->pending_tx_skb != NULL); |
530 | 528 | ||
531 | free = SMC_GET_TX_FIFO_INF(lp) & TX_FIFO_INF_TDFREE_; | 529 | free = SMC_GET_TX_FIFO_INF(lp) & TX_FIFO_INF_TDFREE_; |
@@ -535,12 +533,10 @@ static int smc911x_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
535 | if (free <= SMC911X_TX_FIFO_LOW_THRESHOLD) { | 533 | if (free <= SMC911X_TX_FIFO_LOW_THRESHOLD) { |
536 | DBG(SMC_DEBUG_TX, "%s: Disabling data flow due to low FIFO space (%d)\n", | 534 | DBG(SMC_DEBUG_TX, "%s: Disabling data flow due to low FIFO space (%d)\n", |
537 | dev->name, free); | 535 | dev->name, free); |
538 | spin_lock_irqsave(&lp->lock, flags); | ||
539 | /* Reenable when at least 1 packet of size MTU present */ | 536 | /* Reenable when at least 1 packet of size MTU present */ |
540 | SMC_SET_FIFO_TDA(lp, (SMC911X_TX_FIFO_LOW_THRESHOLD)/64); | 537 | SMC_SET_FIFO_TDA(lp, (SMC911X_TX_FIFO_LOW_THRESHOLD)/64); |
541 | lp->tx_throttle = 1; | 538 | lp->tx_throttle = 1; |
542 | netif_stop_queue(dev); | 539 | netif_stop_queue(dev); |
543 | spin_unlock_irqrestore(&lp->lock, flags); | ||
544 | } | 540 | } |
545 | 541 | ||
546 | /* Drop packets when we run out of space in TX FIFO | 542 | /* Drop packets when we run out of space in TX FIFO |
@@ -556,6 +552,7 @@ static int smc911x_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
556 | lp->pending_tx_skb = NULL; | 552 | lp->pending_tx_skb = NULL; |
557 | dev->stats.tx_errors++; | 553 | dev->stats.tx_errors++; |
558 | dev->stats.tx_dropped++; | 554 | dev->stats.tx_dropped++; |
555 | spin_unlock_irqrestore(&lp->lock, flags); | ||
559 | dev_kfree_skb(skb); | 556 | dev_kfree_skb(skb); |
560 | return 0; | 557 | return 0; |
561 | } | 558 | } |
@@ -565,7 +562,6 @@ static int smc911x_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
565 | /* If the DMA is already running then defer this packet Tx until | 562 | /* If the DMA is already running then defer this packet Tx until |
566 | * the DMA IRQ starts it | 563 | * the DMA IRQ starts it |
567 | */ | 564 | */ |
568 | spin_lock_irqsave(&lp->lock, flags); | ||
569 | if (lp->txdma_active) { | 565 | if (lp->txdma_active) { |
570 | DBG(SMC_DEBUG_TX | SMC_DEBUG_DMA, "%s: Tx DMA running, deferring packet\n", dev->name); | 566 | DBG(SMC_DEBUG_TX | SMC_DEBUG_DMA, "%s: Tx DMA running, deferring packet\n", dev->name); |
571 | lp->pending_tx_skb = skb; | 567 | lp->pending_tx_skb = skb; |
@@ -576,11 +572,11 @@ static int smc911x_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
576 | DBG(SMC_DEBUG_TX | SMC_DEBUG_DMA, "%s: Activating Tx DMA\n", dev->name); | 572 | DBG(SMC_DEBUG_TX | SMC_DEBUG_DMA, "%s: Activating Tx DMA\n", dev->name); |
577 | lp->txdma_active = 1; | 573 | lp->txdma_active = 1; |
578 | } | 574 | } |
579 | spin_unlock_irqrestore(&lp->lock, flags); | ||
580 | } | 575 | } |
581 | #endif | 576 | #endif |
582 | lp->pending_tx_skb = skb; | 577 | lp->pending_tx_skb = skb; |
583 | smc911x_hardware_send_pkt(dev); | 578 | smc911x_hardware_send_pkt(dev); |
579 | spin_unlock_irqrestore(&lp->lock, flags); | ||
584 | 580 | ||
585 | return 0; | 581 | return 0; |
586 | } | 582 | } |
@@ -1242,7 +1238,7 @@ smc911x_rx_dma_irq(int dma, void *data) | |||
1242 | netif_rx(skb); | 1238 | netif_rx(skb); |
1243 | 1239 | ||
1244 | spin_lock_irqsave(&lp->lock, flags); | 1240 | spin_lock_irqsave(&lp->lock, flags); |
1245 | pkts = (SMC_GET_RX_FIFO_INF() & RX_FIFO_INF_RXSUSED_) >> 16; | 1241 | pkts = (SMC_GET_RX_FIFO_INF(lp) & RX_FIFO_INF_RXSUSED_) >> 16; |
1246 | if (pkts != 0) { | 1242 | if (pkts != 0) { |
1247 | smc911x_rcv(dev); | 1243 | smc911x_rcv(dev); |
1248 | }else { | 1244 | }else { |
@@ -2054,7 +2050,7 @@ err_out: | |||
2054 | */ | 2050 | */ |
2055 | static int smc911x_drv_probe(struct platform_device *pdev) | 2051 | static int smc911x_drv_probe(struct platform_device *pdev) |
2056 | { | 2052 | { |
2057 | struct smc91x_platdata *pd = pdev->dev.platform_data; | 2053 | struct smc911x_platdata *pd = pdev->dev.platform_data; |
2058 | struct net_device *ndev; | 2054 | struct net_device *ndev; |
2059 | struct resource *res; | 2055 | struct resource *res; |
2060 | struct smc911x_local *lp; | 2056 | struct smc911x_local *lp; |
diff --git a/drivers/net/smc911x.h b/drivers/net/smc911x.h index bf6240f23f5d..cc7d85bdfb3e 100644 --- a/drivers/net/smc911x.h +++ b/drivers/net/smc911x.h | |||
@@ -50,6 +50,10 @@ | |||
50 | #define SMC_DYNAMIC_BUS_CONFIG | 50 | #define SMC_DYNAMIC_BUS_CONFIG |
51 | #endif | 51 | #endif |
52 | 52 | ||
53 | #ifdef SMC_USE_PXA_DMA | ||
54 | #define SMC_USE_DMA | ||
55 | #endif | ||
56 | |||
53 | /* store this information for the driver.. */ | 57 | /* store this information for the driver.. */ |
54 | struct smc911x_local { | 58 | struct smc911x_local { |
55 | /* | 59 | /* |
@@ -196,8 +200,6 @@ static inline void SMC_outsl(struct smc911x_local *lp, int reg, | |||
196 | 200 | ||
197 | 201 | ||
198 | #ifdef SMC_USE_PXA_DMA | 202 | #ifdef SMC_USE_PXA_DMA |
199 | #define SMC_USE_DMA | ||
200 | |||
201 | /* | 203 | /* |
202 | * Define the request and free functions | 204 | * Define the request and free functions |
203 | * These are unfortunately architecture specific as no generic allocation | 205 | * These are unfortunately architecture specific as no generic allocation |
diff --git a/drivers/net/wireless/ath5k/base.c b/drivers/net/wireless/ath5k/base.c index 9b95c4049b31..0f1d6bdd51a2 100644 --- a/drivers/net/wireless/ath5k/base.c +++ b/drivers/net/wireless/ath5k/base.c | |||
@@ -340,9 +340,9 @@ static inline u64 ath5k_extend_tsf(struct ath5k_hw *ah, u32 rstamp) | |||
340 | } | 340 | } |
341 | 341 | ||
342 | /* Interrupt handling */ | 342 | /* Interrupt handling */ |
343 | static int ath5k_init(struct ath5k_softc *sc); | 343 | static int ath5k_init(struct ath5k_softc *sc, bool is_resume); |
344 | static int ath5k_stop_locked(struct ath5k_softc *sc); | 344 | static int ath5k_stop_locked(struct ath5k_softc *sc); |
345 | static int ath5k_stop_hw(struct ath5k_softc *sc); | 345 | static int ath5k_stop_hw(struct ath5k_softc *sc, bool is_suspend); |
346 | static irqreturn_t ath5k_intr(int irq, void *dev_id); | 346 | static irqreturn_t ath5k_intr(int irq, void *dev_id); |
347 | static void ath5k_tasklet_reset(unsigned long data); | 347 | static void ath5k_tasklet_reset(unsigned long data); |
348 | 348 | ||
@@ -646,7 +646,7 @@ ath5k_pci_suspend(struct pci_dev *pdev, pm_message_t state) | |||
646 | 646 | ||
647 | ath5k_led_off(sc); | 647 | ath5k_led_off(sc); |
648 | 648 | ||
649 | ath5k_stop_hw(sc); | 649 | ath5k_stop_hw(sc, true); |
650 | 650 | ||
651 | free_irq(pdev->irq, sc); | 651 | free_irq(pdev->irq, sc); |
652 | pci_save_state(pdev); | 652 | pci_save_state(pdev); |
@@ -683,7 +683,7 @@ ath5k_pci_resume(struct pci_dev *pdev) | |||
683 | goto err_no_irq; | 683 | goto err_no_irq; |
684 | } | 684 | } |
685 | 685 | ||
686 | err = ath5k_init(sc); | 686 | err = ath5k_init(sc, true); |
687 | if (err) | 687 | if (err) |
688 | goto err_irq; | 688 | goto err_irq; |
689 | ath5k_led_enable(sc); | 689 | ath5k_led_enable(sc); |
@@ -2200,12 +2200,17 @@ ath5k_beacon_config(struct ath5k_softc *sc) | |||
2200 | \********************/ | 2200 | \********************/ |
2201 | 2201 | ||
2202 | static int | 2202 | static int |
2203 | ath5k_init(struct ath5k_softc *sc) | 2203 | ath5k_init(struct ath5k_softc *sc, bool is_resume) |
2204 | { | 2204 | { |
2205 | int ret; | 2205 | int ret; |
2206 | 2206 | ||
2207 | mutex_lock(&sc->lock); | 2207 | mutex_lock(&sc->lock); |
2208 | 2208 | ||
2209 | if (is_resume && !test_bit(ATH_STAT_STARTED, sc->status)) | ||
2210 | goto out_ok; | ||
2211 | |||
2212 | __clear_bit(ATH_STAT_STARTED, sc->status); | ||
2213 | |||
2209 | ATH5K_DBG(sc, ATH5K_DEBUG_RESET, "mode %d\n", sc->opmode); | 2214 | ATH5K_DBG(sc, ATH5K_DEBUG_RESET, "mode %d\n", sc->opmode); |
2210 | 2215 | ||
2211 | /* | 2216 | /* |
@@ -2230,12 +2235,15 @@ ath5k_init(struct ath5k_softc *sc) | |||
2230 | if (ret) | 2235 | if (ret) |
2231 | goto done; | 2236 | goto done; |
2232 | 2237 | ||
2238 | __set_bit(ATH_STAT_STARTED, sc->status); | ||
2239 | |||
2233 | /* Set ack to be sent at low bit-rates */ | 2240 | /* Set ack to be sent at low bit-rates */ |
2234 | ath5k_hw_set_ack_bitrate_high(sc->ah, false); | 2241 | ath5k_hw_set_ack_bitrate_high(sc->ah, false); |
2235 | 2242 | ||
2236 | mod_timer(&sc->calib_tim, round_jiffies(jiffies + | 2243 | mod_timer(&sc->calib_tim, round_jiffies(jiffies + |
2237 | msecs_to_jiffies(ath5k_calinterval * 1000))); | 2244 | msecs_to_jiffies(ath5k_calinterval * 1000))); |
2238 | 2245 | ||
2246 | out_ok: | ||
2239 | ret = 0; | 2247 | ret = 0; |
2240 | done: | 2248 | done: |
2241 | mmiowb(); | 2249 | mmiowb(); |
@@ -2290,7 +2298,7 @@ ath5k_stop_locked(struct ath5k_softc *sc) | |||
2290 | * stop is preempted). | 2298 | * stop is preempted). |
2291 | */ | 2299 | */ |
2292 | static int | 2300 | static int |
2293 | ath5k_stop_hw(struct ath5k_softc *sc) | 2301 | ath5k_stop_hw(struct ath5k_softc *sc, bool is_suspend) |
2294 | { | 2302 | { |
2295 | int ret; | 2303 | int ret; |
2296 | 2304 | ||
@@ -2321,6 +2329,9 @@ ath5k_stop_hw(struct ath5k_softc *sc) | |||
2321 | } | 2329 | } |
2322 | } | 2330 | } |
2323 | ath5k_txbuf_free(sc, sc->bbuf); | 2331 | ath5k_txbuf_free(sc, sc->bbuf); |
2332 | if (!is_suspend) | ||
2333 | __clear_bit(ATH_STAT_STARTED, sc->status); | ||
2334 | |||
2324 | mmiowb(); | 2335 | mmiowb(); |
2325 | mutex_unlock(&sc->lock); | 2336 | mutex_unlock(&sc->lock); |
2326 | 2337 | ||
@@ -2718,12 +2729,12 @@ ath5k_reset_wake(struct ath5k_softc *sc) | |||
2718 | 2729 | ||
2719 | static int ath5k_start(struct ieee80211_hw *hw) | 2730 | static int ath5k_start(struct ieee80211_hw *hw) |
2720 | { | 2731 | { |
2721 | return ath5k_init(hw->priv); | 2732 | return ath5k_init(hw->priv, false); |
2722 | } | 2733 | } |
2723 | 2734 | ||
2724 | static void ath5k_stop(struct ieee80211_hw *hw) | 2735 | static void ath5k_stop(struct ieee80211_hw *hw) |
2725 | { | 2736 | { |
2726 | ath5k_stop_hw(hw->priv); | 2737 | ath5k_stop_hw(hw->priv, false); |
2727 | } | 2738 | } |
2728 | 2739 | ||
2729 | static int ath5k_add_interface(struct ieee80211_hw *hw, | 2740 | static int ath5k_add_interface(struct ieee80211_hw *hw, |
diff --git a/drivers/net/wireless/ath5k/base.h b/drivers/net/wireless/ath5k/base.h index 9d0b728928e3..06d1054ca94b 100644 --- a/drivers/net/wireless/ath5k/base.h +++ b/drivers/net/wireless/ath5k/base.h | |||
@@ -128,11 +128,12 @@ struct ath5k_softc { | |||
128 | size_t desc_len; /* size of TX/RX descriptors */ | 128 | size_t desc_len; /* size of TX/RX descriptors */ |
129 | u16 cachelsz; /* cache line size */ | 129 | u16 cachelsz; /* cache line size */ |
130 | 130 | ||
131 | DECLARE_BITMAP(status, 4); | 131 | DECLARE_BITMAP(status, 5); |
132 | #define ATH_STAT_INVALID 0 /* disable hardware accesses */ | 132 | #define ATH_STAT_INVALID 0 /* disable hardware accesses */ |
133 | #define ATH_STAT_MRRETRY 1 /* multi-rate retry support */ | 133 | #define ATH_STAT_MRRETRY 1 /* multi-rate retry support */ |
134 | #define ATH_STAT_PROMISC 2 | 134 | #define ATH_STAT_PROMISC 2 |
135 | #define ATH_STAT_LEDSOFT 3 /* enable LED gpio status */ | 135 | #define ATH_STAT_LEDSOFT 3 /* enable LED gpio status */ |
136 | #define ATH_STAT_STARTED 4 /* opened & irqs enabled */ | ||
136 | 137 | ||
137 | unsigned int filter_flags; /* HW flags, AR5K_RX_FILTER_* */ | 138 | unsigned int filter_flags; /* HW flags, AR5K_RX_FILTER_* */ |
138 | unsigned int curmode; /* current phy mode */ | 139 | unsigned int curmode; /* current phy mode */ |
diff --git a/drivers/net/wireless/libertas/rx.c b/drivers/net/wireless/libertas/rx.c index 5749f22b296f..079e6aa874dc 100644 --- a/drivers/net/wireless/libertas/rx.c +++ b/drivers/net/wireless/libertas/rx.c | |||
@@ -328,7 +328,7 @@ static int process_rxed_802_11_packet(struct lbs_private *priv, | |||
328 | lbs_deb_rx("rx err: frame received with bad length\n"); | 328 | lbs_deb_rx("rx err: frame received with bad length\n"); |
329 | priv->stats.rx_length_errors++; | 329 | priv->stats.rx_length_errors++; |
330 | ret = -EINVAL; | 330 | ret = -EINVAL; |
331 | kfree(skb); | 331 | kfree_skb(skb); |
332 | goto done; | 332 | goto done; |
333 | } | 333 | } |
334 | 334 | ||
diff --git a/drivers/net/wireless/orinoco.c b/drivers/net/wireless/orinoco.c index 50904771f291..e0512e49d6d3 100644 --- a/drivers/net/wireless/orinoco.c +++ b/drivers/net/wireless/orinoco.c | |||
@@ -433,7 +433,7 @@ struct fw_info { | |||
433 | const static struct fw_info orinoco_fw[] = { | 433 | const static struct fw_info orinoco_fw[] = { |
434 | { "", "agere_sta_fw.bin", "agere_ap_fw.bin", 0x00390000, 1000 }, | 434 | { "", "agere_sta_fw.bin", "agere_ap_fw.bin", 0x00390000, 1000 }, |
435 | { "", "prism_sta_fw.bin", "prism_ap_fw.bin", 0, 1024 }, | 435 | { "", "prism_sta_fw.bin", "prism_ap_fw.bin", 0, 1024 }, |
436 | { "symbol_sp24t_prim_fw", "symbol_sp24t_sec_fw", "", 0x00003100, 0x100 } | 436 | { "symbol_sp24t_prim_fw", "symbol_sp24t_sec_fw", "", 0x00003100, 512 } |
437 | }; | 437 | }; |
438 | 438 | ||
439 | /* Structure used to access fields in FW | 439 | /* Structure used to access fields in FW |
@@ -458,7 +458,7 @@ orinoco_dl_firmware(struct orinoco_private *priv, | |||
458 | int ap) | 458 | int ap) |
459 | { | 459 | { |
460 | /* Plug Data Area (PDA) */ | 460 | /* Plug Data Area (PDA) */ |
461 | __le16 pda[512] = { 0 }; | 461 | __le16 *pda; |
462 | 462 | ||
463 | hermes_t *hw = &priv->hw; | 463 | hermes_t *hw = &priv->hw; |
464 | const struct firmware *fw_entry; | 464 | const struct firmware *fw_entry; |
@@ -467,7 +467,11 @@ orinoco_dl_firmware(struct orinoco_private *priv, | |||
467 | const unsigned char *end; | 467 | const unsigned char *end; |
468 | const char *firmware; | 468 | const char *firmware; |
469 | struct net_device *dev = priv->ndev; | 469 | struct net_device *dev = priv->ndev; |
470 | int err; | 470 | int err = 0; |
471 | |||
472 | pda = kzalloc(fw->pda_size, GFP_KERNEL); | ||
473 | if (!pda) | ||
474 | return -ENOMEM; | ||
471 | 475 | ||
472 | if (ap) | 476 | if (ap) |
473 | firmware = fw->ap_fw; | 477 | firmware = fw->ap_fw; |
@@ -478,17 +482,17 @@ orinoco_dl_firmware(struct orinoco_private *priv, | |||
478 | dev->name, firmware); | 482 | dev->name, firmware); |
479 | 483 | ||
480 | /* Read current plug data */ | 484 | /* Read current plug data */ |
481 | err = hermes_read_pda(hw, pda, fw->pda_addr, | 485 | err = hermes_read_pda(hw, pda, fw->pda_addr, fw->pda_size, 0); |
482 | min_t(u16, fw->pda_size, sizeof(pda)), 0); | ||
483 | printk(KERN_DEBUG "%s: Read PDA returned %d\n", dev->name, err); | 486 | printk(KERN_DEBUG "%s: Read PDA returned %d\n", dev->name, err); |
484 | if (err) | 487 | if (err) |
485 | return err; | 488 | goto free; |
486 | 489 | ||
487 | err = request_firmware(&fw_entry, firmware, priv->dev); | 490 | err = request_firmware(&fw_entry, firmware, priv->dev); |
488 | if (err) { | 491 | if (err) { |
489 | printk(KERN_ERR "%s: Cannot find firmware %s\n", | 492 | printk(KERN_ERR "%s: Cannot find firmware %s\n", |
490 | dev->name, firmware); | 493 | dev->name, firmware); |
491 | return -ENOENT; | 494 | err = -ENOENT; |
495 | goto free; | ||
492 | } | 496 | } |
493 | 497 | ||
494 | hdr = (const struct orinoco_fw_header *) fw_entry->data; | 498 | hdr = (const struct orinoco_fw_header *) fw_entry->data; |
@@ -532,6 +536,9 @@ orinoco_dl_firmware(struct orinoco_private *priv, | |||
532 | 536 | ||
533 | abort: | 537 | abort: |
534 | release_firmware(fw_entry); | 538 | release_firmware(fw_entry); |
539 | |||
540 | free: | ||
541 | kfree(pda); | ||
535 | return err; | 542 | return err; |
536 | } | 543 | } |
537 | 544 | ||
@@ -549,12 +556,12 @@ symbol_dl_image(struct orinoco_private *priv, const struct fw_info *fw, | |||
549 | int secondary) | 556 | int secondary) |
550 | { | 557 | { |
551 | hermes_t *hw = &priv->hw; | 558 | hermes_t *hw = &priv->hw; |
552 | int ret; | 559 | int ret = 0; |
553 | const unsigned char *ptr; | 560 | const unsigned char *ptr; |
554 | const unsigned char *first_block; | 561 | const unsigned char *first_block; |
555 | 562 | ||
556 | /* Plug Data Area (PDA) */ | 563 | /* Plug Data Area (PDA) */ |
557 | __le16 pda[256]; | 564 | __le16 *pda = NULL; |
558 | 565 | ||
559 | /* Binary block begins after the 0x1A marker */ | 566 | /* Binary block begins after the 0x1A marker */ |
560 | ptr = image; | 567 | ptr = image; |
@@ -563,28 +570,33 @@ symbol_dl_image(struct orinoco_private *priv, const struct fw_info *fw, | |||
563 | 570 | ||
564 | /* Read the PDA from EEPROM */ | 571 | /* Read the PDA from EEPROM */ |
565 | if (secondary) { | 572 | if (secondary) { |
566 | ret = hermes_read_pda(hw, pda, fw->pda_addr, sizeof(pda), 1); | 573 | pda = kzalloc(fw->pda_size, GFP_KERNEL); |
574 | if (!pda) | ||
575 | return -ENOMEM; | ||
576 | |||
577 | ret = hermes_read_pda(hw, pda, fw->pda_addr, fw->pda_size, 1); | ||
567 | if (ret) | 578 | if (ret) |
568 | return ret; | 579 | goto free; |
569 | } | 580 | } |
570 | 581 | ||
571 | /* Stop the firmware, so that it can be safely rewritten */ | 582 | /* Stop the firmware, so that it can be safely rewritten */ |
572 | if (priv->stop_fw) { | 583 | if (priv->stop_fw) { |
573 | ret = priv->stop_fw(priv, 1); | 584 | ret = priv->stop_fw(priv, 1); |
574 | if (ret) | 585 | if (ret) |
575 | return ret; | 586 | goto free; |
576 | } | 587 | } |
577 | 588 | ||
578 | /* Program the adapter with new firmware */ | 589 | /* Program the adapter with new firmware */ |
579 | ret = hermes_program(hw, first_block, end); | 590 | ret = hermes_program(hw, first_block, end); |
580 | if (ret) | 591 | if (ret) |
581 | return ret; | 592 | goto free; |
582 | 593 | ||
583 | /* Write the PDA to the adapter */ | 594 | /* Write the PDA to the adapter */ |
584 | if (secondary) { | 595 | if (secondary) { |
585 | size_t len = hermes_blocks_length(first_block); | 596 | size_t len = hermes_blocks_length(first_block); |
586 | ptr = first_block + len; | 597 | ptr = first_block + len; |
587 | ret = hermes_apply_pda(hw, ptr, pda); | 598 | ret = hermes_apply_pda(hw, ptr, pda); |
599 | kfree(pda); | ||
588 | if (ret) | 600 | if (ret) |
589 | return ret; | 601 | return ret; |
590 | } | 602 | } |
@@ -608,6 +620,10 @@ symbol_dl_image(struct orinoco_private *priv, const struct fw_info *fw, | |||
608 | return -ENODEV; | 620 | return -ENODEV; |
609 | 621 | ||
610 | return 0; | 622 | return 0; |
623 | |||
624 | free: | ||
625 | kfree(pda); | ||
626 | return ret; | ||
611 | } | 627 | } |
612 | 628 | ||
613 | 629 | ||
diff --git a/drivers/net/wireless/p54/p54common.c b/drivers/net/wireless/p54/p54common.c index 117c7d3a52b0..2d022f83774c 100644 --- a/drivers/net/wireless/p54/p54common.c +++ b/drivers/net/wireless/p54/p54common.c | |||
@@ -306,8 +306,8 @@ static int p54_convert_rev1(struct ieee80211_hw *dev, | |||
306 | return 0; | 306 | return 0; |
307 | } | 307 | } |
308 | 308 | ||
309 | static const char *p54_rf_chips[] = { "NULL", "Indigo?", "Duette", | 309 | static const char *p54_rf_chips[] = { "NULL", "Duette3", "Duette2", |
310 | "Frisbee", "Xbow", "Longbow" }; | 310 | "Frisbee", "Xbow", "Longbow", "NULL", "NULL" }; |
311 | static int p54_init_xbow_synth(struct ieee80211_hw *dev); | 311 | static int p54_init_xbow_synth(struct ieee80211_hw *dev); |
312 | 312 | ||
313 | static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) | 313 | static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) |
@@ -319,6 +319,7 @@ static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) | |||
319 | void *tmp; | 319 | void *tmp; |
320 | int err; | 320 | int err; |
321 | u8 *end = (u8 *)eeprom + len; | 321 | u8 *end = (u8 *)eeprom + len; |
322 | u16 synth; | ||
322 | DECLARE_MAC_BUF(mac); | 323 | DECLARE_MAC_BUF(mac); |
323 | 324 | ||
324 | wrap = (struct eeprom_pda_wrap *) eeprom; | 325 | wrap = (struct eeprom_pda_wrap *) eeprom; |
@@ -400,8 +401,8 @@ static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) | |||
400 | tmp = entry->data; | 401 | tmp = entry->data; |
401 | while ((u8 *)tmp < entry->data + data_len) { | 402 | while ((u8 *)tmp < entry->data + data_len) { |
402 | struct bootrec_exp_if *exp_if = tmp; | 403 | struct bootrec_exp_if *exp_if = tmp; |
403 | if (le16_to_cpu(exp_if->if_id) == 0xF) | 404 | if (le16_to_cpu(exp_if->if_id) == 0xf) |
404 | priv->rxhw = le16_to_cpu(exp_if->variant) & 0x07; | 405 | synth = le16_to_cpu(exp_if->variant); |
405 | tmp += sizeof(struct bootrec_exp_if); | 406 | tmp += sizeof(struct bootrec_exp_if); |
406 | } | 407 | } |
407 | break; | 408 | break; |
@@ -427,22 +428,13 @@ static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) | |||
427 | goto err; | 428 | goto err; |
428 | } | 429 | } |
429 | 430 | ||
430 | switch (priv->rxhw) { | 431 | priv->rxhw = synth & 0x07; |
431 | case 4: /* XBow */ | 432 | if (priv->rxhw == 4) |
432 | p54_init_xbow_synth(dev); | 433 | p54_init_xbow_synth(dev); |
433 | case 1: /* Indigo? */ | 434 | if (!(synth & 0x40)) |
434 | case 2: /* Duette */ | ||
435 | dev->wiphy->bands[IEEE80211_BAND_5GHZ] = &band_5GHz; | ||
436 | case 3: /* Frisbee */ | ||
437 | case 5: /* Longbow */ | ||
438 | dev->wiphy->bands[IEEE80211_BAND_2GHZ] = &band_2GHz; | 435 | dev->wiphy->bands[IEEE80211_BAND_2GHZ] = &band_2GHz; |
439 | break; | 436 | if (!(synth & 0x80)) |
440 | default: | 437 | dev->wiphy->bands[IEEE80211_BAND_5GHZ] = &band_5GHz; |
441 | printk(KERN_ERR "%s: unsupported RF-Chip\n", | ||
442 | wiphy_name(dev->wiphy)); | ||
443 | err = -EINVAL; | ||
444 | goto err; | ||
445 | } | ||
446 | 438 | ||
447 | if (!is_valid_ether_addr(dev->wiphy->perm_addr)) { | 439 | if (!is_valid_ether_addr(dev->wiphy->perm_addr)) { |
448 | u8 perm_addr[ETH_ALEN]; | 440 | u8 perm_addr[ETH_ALEN]; |
diff --git a/drivers/pci/Makefile b/drivers/pci/Makefile index 4b47f4ece5b7..af3bfe22847b 100644 --- a/drivers/pci/Makefile +++ b/drivers/pci/Makefile | |||
@@ -3,7 +3,8 @@ | |||
3 | # | 3 | # |
4 | 4 | ||
5 | obj-y += access.o bus.o probe.o remove.o pci.o quirks.o slot.o \ | 5 | obj-y += access.o bus.o probe.o remove.o pci.o quirks.o slot.o \ |
6 | pci-driver.o search.o pci-sysfs.o rom.o setup-res.o | 6 | pci-driver.o search.o pci-sysfs.o rom.o setup-res.o \ |
7 | irq.o | ||
7 | obj-$(CONFIG_PROC_FS) += proc.o | 8 | obj-$(CONFIG_PROC_FS) += proc.o |
8 | 9 | ||
9 | # Build PCI Express stuff if needed | 10 | # Build PCI Express stuff if needed |
diff --git a/drivers/pci/hotplug/acpiphp_ibm.c b/drivers/pci/hotplug/acpiphp_ibm.c index b291ee68b4f1..881fdd2b7313 100644 --- a/drivers/pci/hotplug/acpiphp_ibm.c +++ b/drivers/pci/hotplug/acpiphp_ibm.c | |||
@@ -204,7 +204,7 @@ static int ibm_set_attention_status(struct hotplug_slot *slot, u8 status) | |||
204 | err("APLS evaluation failed: 0x%08x\n", stat); | 204 | err("APLS evaluation failed: 0x%08x\n", stat); |
205 | return -ENODEV; | 205 | return -ENODEV; |
206 | } else if (!rc) { | 206 | } else if (!rc) { |
207 | err("APLS method failed: 0x%08lx\n", rc); | 207 | err("APLS method failed: 0x%08llx\n", rc); |
208 | return -ERANGE; | 208 | return -ERANGE; |
209 | } | 209 | } |
210 | return 0; | 210 | return 0; |
diff --git a/drivers/pci/hotplug/cpqphp_core.c b/drivers/pci/hotplug/cpqphp_core.c index 724d42c4adbc..8514c3a1746a 100644 --- a/drivers/pci/hotplug/cpqphp_core.c +++ b/drivers/pci/hotplug/cpqphp_core.c | |||
@@ -433,7 +433,7 @@ static int ctrl_slot_setup(struct controller *ctrl, | |||
433 | slot->number, ctrl->slot_device_offset, | 433 | slot->number, ctrl->slot_device_offset, |
434 | slot_number); | 434 | slot_number); |
435 | result = pci_hp_register(hotplug_slot, | 435 | result = pci_hp_register(hotplug_slot, |
436 | ctrl->pci_dev->subordinate, | 436 | ctrl->pci_dev->bus, |
437 | slot->device, | 437 | slot->device, |
438 | name); | 438 | name); |
439 | if (result) { | 439 | if (result) { |
diff --git a/drivers/pci/hotplug/pciehp.h b/drivers/pci/hotplug/pciehp.h index a4817a841fae..b2801a7ee37f 100644 --- a/drivers/pci/hotplug/pciehp.h +++ b/drivers/pci/hotplug/pciehp.h | |||
@@ -188,7 +188,7 @@ static inline struct slot *pciehp_find_slot(struct controller *ctrl, u8 device) | |||
188 | return slot; | 188 | return slot; |
189 | } | 189 | } |
190 | 190 | ||
191 | ctrl_err(ctrl, "%s: slot (device=0x%x) not found\n", __func__, device); | 191 | ctrl_err(ctrl, "Slot (device=0x%02x) not found\n", device); |
192 | return NULL; | 192 | return NULL; |
193 | } | 193 | } |
194 | 194 | ||
diff --git a/drivers/pci/hotplug/pciehp_core.c b/drivers/pci/hotplug/pciehp_core.c index 62be1b59c74b..4b23bc39b11e 100644 --- a/drivers/pci/hotplug/pciehp_core.c +++ b/drivers/pci/hotplug/pciehp_core.c | |||
@@ -184,7 +184,7 @@ static void release_slot(struct hotplug_slot *hotplug_slot) | |||
184 | { | 184 | { |
185 | struct slot *slot = hotplug_slot->private; | 185 | struct slot *slot = hotplug_slot->private; |
186 | 186 | ||
187 | ctrl_dbg(slot->ctrl, "%s - physical_slot = %s\n", | 187 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
188 | __func__, hotplug_slot_name(hotplug_slot)); | 188 | __func__, hotplug_slot_name(hotplug_slot)); |
189 | 189 | ||
190 | kfree(hotplug_slot->info); | 190 | kfree(hotplug_slot->info); |
@@ -216,9 +216,11 @@ static int init_slots(struct controller *ctrl) | |||
216 | slot->hotplug_slot = hotplug_slot; | 216 | slot->hotplug_slot = hotplug_slot; |
217 | snprintf(name, SLOT_NAME_SIZE, "%u", slot->number); | 217 | snprintf(name, SLOT_NAME_SIZE, "%u", slot->number); |
218 | 218 | ||
219 | ctrl_dbg(ctrl, "Registering bus=%x dev=%x hp_slot=%x sun=%x " | 219 | ctrl_dbg(ctrl, "Registering domain:bus:dev=%04x:%02x:%02x " |
220 | "slot_device_offset=%x\n", slot->bus, slot->device, | 220 | "hp_slot=%x sun=%x slot_device_offset=%x\n", |
221 | slot->hp_slot, slot->number, ctrl->slot_device_offset); | 221 | pci_domain_nr(ctrl->pci_dev->subordinate), |
222 | slot->bus, slot->device, slot->hp_slot, slot->number, | ||
223 | ctrl->slot_device_offset); | ||
222 | retval = pci_hp_register(hotplug_slot, | 224 | retval = pci_hp_register(hotplug_slot, |
223 | ctrl->pci_dev->subordinate, | 225 | ctrl->pci_dev->subordinate, |
224 | slot->device, | 226 | slot->device, |
@@ -238,7 +240,7 @@ static int init_slots(struct controller *ctrl) | |||
238 | &hotplug_slot_attr_lock.attr); | 240 | &hotplug_slot_attr_lock.attr); |
239 | if (retval) { | 241 | if (retval) { |
240 | pci_hp_deregister(hotplug_slot); | 242 | pci_hp_deregister(hotplug_slot); |
241 | ctrl_err(ctrl, "cannot create additional sysfs " | 243 | ctrl_err(ctrl, "Cannot create additional sysfs " |
242 | "entries\n"); | 244 | "entries\n"); |
243 | goto error_info; | 245 | goto error_info; |
244 | } | 246 | } |
@@ -273,7 +275,7 @@ static int set_attention_status(struct hotplug_slot *hotplug_slot, u8 status) | |||
273 | { | 275 | { |
274 | struct slot *slot = hotplug_slot->private; | 276 | struct slot *slot = hotplug_slot->private; |
275 | 277 | ||
276 | ctrl_dbg(slot->ctrl, "%s - physical_slot = %s\n", | 278 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
277 | __func__, slot_name(slot)); | 279 | __func__, slot_name(slot)); |
278 | 280 | ||
279 | hotplug_slot->info->attention_status = status; | 281 | hotplug_slot->info->attention_status = status; |
@@ -289,7 +291,7 @@ static int enable_slot(struct hotplug_slot *hotplug_slot) | |||
289 | { | 291 | { |
290 | struct slot *slot = hotplug_slot->private; | 292 | struct slot *slot = hotplug_slot->private; |
291 | 293 | ||
292 | ctrl_dbg(slot->ctrl, "%s - physical_slot = %s\n", | 294 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
293 | __func__, slot_name(slot)); | 295 | __func__, slot_name(slot)); |
294 | 296 | ||
295 | return pciehp_sysfs_enable_slot(slot); | 297 | return pciehp_sysfs_enable_slot(slot); |
@@ -300,7 +302,7 @@ static int disable_slot(struct hotplug_slot *hotplug_slot) | |||
300 | { | 302 | { |
301 | struct slot *slot = hotplug_slot->private; | 303 | struct slot *slot = hotplug_slot->private; |
302 | 304 | ||
303 | ctrl_dbg(slot->ctrl, "%s - physical_slot = %s\n", | 305 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
304 | __func__, slot_name(slot)); | 306 | __func__, slot_name(slot)); |
305 | 307 | ||
306 | return pciehp_sysfs_disable_slot(slot); | 308 | return pciehp_sysfs_disable_slot(slot); |
@@ -311,7 +313,7 @@ static int get_power_status(struct hotplug_slot *hotplug_slot, u8 *value) | |||
311 | struct slot *slot = hotplug_slot->private; | 313 | struct slot *slot = hotplug_slot->private; |
312 | int retval; | 314 | int retval; |
313 | 315 | ||
314 | ctrl_dbg(slot->ctrl, "%s - physical_slot = %s\n", | 316 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
315 | __func__, slot_name(slot)); | 317 | __func__, slot_name(slot)); |
316 | 318 | ||
317 | retval = slot->hpc_ops->get_power_status(slot, value); | 319 | retval = slot->hpc_ops->get_power_status(slot, value); |
@@ -326,7 +328,7 @@ static int get_attention_status(struct hotplug_slot *hotplug_slot, u8 *value) | |||
326 | struct slot *slot = hotplug_slot->private; | 328 | struct slot *slot = hotplug_slot->private; |
327 | int retval; | 329 | int retval; |
328 | 330 | ||
329 | ctrl_dbg(slot->ctrl, "%s - physical_slot = %s\n", | 331 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
330 | __func__, slot_name(slot)); | 332 | __func__, slot_name(slot)); |
331 | 333 | ||
332 | retval = slot->hpc_ops->get_attention_status(slot, value); | 334 | retval = slot->hpc_ops->get_attention_status(slot, value); |
@@ -341,7 +343,7 @@ static int get_latch_status(struct hotplug_slot *hotplug_slot, u8 *value) | |||
341 | struct slot *slot = hotplug_slot->private; | 343 | struct slot *slot = hotplug_slot->private; |
342 | int retval; | 344 | int retval; |
343 | 345 | ||
344 | ctrl_dbg(slot->ctrl, "%s - physical_slot = %s\n", | 346 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
345 | __func__, slot_name(slot)); | 347 | __func__, slot_name(slot)); |
346 | 348 | ||
347 | retval = slot->hpc_ops->get_latch_status(slot, value); | 349 | retval = slot->hpc_ops->get_latch_status(slot, value); |
@@ -356,7 +358,7 @@ static int get_adapter_status(struct hotplug_slot *hotplug_slot, u8 *value) | |||
356 | struct slot *slot = hotplug_slot->private; | 358 | struct slot *slot = hotplug_slot->private; |
357 | int retval; | 359 | int retval; |
358 | 360 | ||
359 | ctrl_dbg(slot->ctrl, "%s - physical_slot = %s\n", | 361 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
360 | __func__, slot_name(slot)); | 362 | __func__, slot_name(slot)); |
361 | 363 | ||
362 | retval = slot->hpc_ops->get_adapter_status(slot, value); | 364 | retval = slot->hpc_ops->get_adapter_status(slot, value); |
@@ -372,7 +374,7 @@ static int get_max_bus_speed(struct hotplug_slot *hotplug_slot, | |||
372 | struct slot *slot = hotplug_slot->private; | 374 | struct slot *slot = hotplug_slot->private; |
373 | int retval; | 375 | int retval; |
374 | 376 | ||
375 | ctrl_dbg(slot->ctrl, "%s - physical_slot = %s\n", | 377 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
376 | __func__, slot_name(slot)); | 378 | __func__, slot_name(slot)); |
377 | 379 | ||
378 | retval = slot->hpc_ops->get_max_bus_speed(slot, value); | 380 | retval = slot->hpc_ops->get_max_bus_speed(slot, value); |
@@ -387,7 +389,7 @@ static int get_cur_bus_speed(struct hotplug_slot *hotplug_slot, enum pci_bus_spe | |||
387 | struct slot *slot = hotplug_slot->private; | 389 | struct slot *slot = hotplug_slot->private; |
388 | int retval; | 390 | int retval; |
389 | 391 | ||
390 | ctrl_dbg(slot->ctrl, "%s - physical_slot = %s\n", | 392 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
391 | __func__, slot_name(slot)); | 393 | __func__, slot_name(slot)); |
392 | 394 | ||
393 | retval = slot->hpc_ops->get_cur_bus_speed(slot, value); | 395 | retval = slot->hpc_ops->get_cur_bus_speed(slot, value); |
@@ -414,7 +416,7 @@ static int pciehp_probe(struct pcie_device *dev, const struct pcie_port_service_ | |||
414 | 416 | ||
415 | ctrl = pcie_init(dev); | 417 | ctrl = pcie_init(dev); |
416 | if (!ctrl) { | 418 | if (!ctrl) { |
417 | dev_err(&dev->device, "controller initialization failed\n"); | 419 | dev_err(&dev->device, "Controller initialization failed\n"); |
418 | goto err_out_none; | 420 | goto err_out_none; |
419 | } | 421 | } |
420 | set_service_data(dev, ctrl); | 422 | set_service_data(dev, ctrl); |
@@ -423,10 +425,10 @@ static int pciehp_probe(struct pcie_device *dev, const struct pcie_port_service_ | |||
423 | rc = init_slots(ctrl); | 425 | rc = init_slots(ctrl); |
424 | if (rc) { | 426 | if (rc) { |
425 | if (rc == -EBUSY) | 427 | if (rc == -EBUSY) |
426 | ctrl_warn(ctrl, "slot already registered by another " | 428 | ctrl_warn(ctrl, "Slot already registered by another " |
427 | "hotplug driver\n"); | 429 | "hotplug driver\n"); |
428 | else | 430 | else |
429 | ctrl_err(ctrl, "slot initialization failed\n"); | 431 | ctrl_err(ctrl, "Slot initialization failed\n"); |
430 | goto err_out_release_ctlr; | 432 | goto err_out_release_ctlr; |
431 | } | 433 | } |
432 | 434 | ||
@@ -523,7 +525,7 @@ static int __init pcied_init(void) | |||
523 | dbg("pcie_port_service_register = %d\n", retval); | 525 | dbg("pcie_port_service_register = %d\n", retval); |
524 | info(DRIVER_DESC " version: " DRIVER_VERSION "\n"); | 526 | info(DRIVER_DESC " version: " DRIVER_VERSION "\n"); |
525 | if (retval) | 527 | if (retval) |
526 | dbg("%s: Failure to register service\n", __func__); | 528 | dbg("Failure to register service\n"); |
527 | return retval; | 529 | return retval; |
528 | } | 530 | } |
529 | 531 | ||
diff --git a/drivers/pci/hotplug/pciehp_ctrl.c b/drivers/pci/hotplug/pciehp_ctrl.c index d6c5eb297753..fead63c6b49e 100644 --- a/drivers/pci/hotplug/pciehp_ctrl.c +++ b/drivers/pci/hotplug/pciehp_ctrl.c | |||
@@ -61,7 +61,7 @@ u8 pciehp_handle_attention_button(struct slot *p_slot) | |||
61 | struct controller *ctrl = p_slot->ctrl; | 61 | struct controller *ctrl = p_slot->ctrl; |
62 | 62 | ||
63 | /* Attention Button Change */ | 63 | /* Attention Button Change */ |
64 | ctrl_dbg(ctrl, "Attention button interrupt received.\n"); | 64 | ctrl_dbg(ctrl, "Attention button interrupt received\n"); |
65 | 65 | ||
66 | /* | 66 | /* |
67 | * Button pressed - See if need to TAKE ACTION!!! | 67 | * Button pressed - See if need to TAKE ACTION!!! |
@@ -81,7 +81,7 @@ u8 pciehp_handle_switch_change(struct slot *p_slot) | |||
81 | struct controller *ctrl = p_slot->ctrl; | 81 | struct controller *ctrl = p_slot->ctrl; |
82 | 82 | ||
83 | /* Switch Change */ | 83 | /* Switch Change */ |
84 | ctrl_dbg(ctrl, "Switch interrupt received.\n"); | 84 | ctrl_dbg(ctrl, "Switch interrupt received\n"); |
85 | 85 | ||
86 | p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); | 86 | p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); |
87 | if (getstatus) { | 87 | if (getstatus) { |
@@ -110,7 +110,7 @@ u8 pciehp_handle_presence_change(struct slot *p_slot) | |||
110 | struct controller *ctrl = p_slot->ctrl; | 110 | struct controller *ctrl = p_slot->ctrl; |
111 | 111 | ||
112 | /* Presence Change */ | 112 | /* Presence Change */ |
113 | ctrl_dbg(ctrl, "Presence/Notify input change.\n"); | 113 | ctrl_dbg(ctrl, "Presence/Notify input change\n"); |
114 | 114 | ||
115 | /* Switch is open, assume a presence change | 115 | /* Switch is open, assume a presence change |
116 | * Save the presence state | 116 | * Save the presence state |
@@ -142,7 +142,7 @@ u8 pciehp_handle_power_fault(struct slot *p_slot) | |||
142 | struct controller *ctrl = p_slot->ctrl; | 142 | struct controller *ctrl = p_slot->ctrl; |
143 | 143 | ||
144 | /* power fault */ | 144 | /* power fault */ |
145 | ctrl_dbg(ctrl, "Power fault interrupt received.\n"); | 145 | ctrl_dbg(ctrl, "Power fault interrupt received\n"); |
146 | 146 | ||
147 | if ( !(p_slot->hpc_ops->query_power_fault(p_slot))) { | 147 | if ( !(p_slot->hpc_ops->query_power_fault(p_slot))) { |
148 | /* | 148 | /* |
@@ -157,7 +157,7 @@ u8 pciehp_handle_power_fault(struct slot *p_slot) | |||
157 | */ | 157 | */ |
158 | ctrl_info(ctrl, "Power fault on Slot(%s)\n", slot_name(p_slot)); | 158 | ctrl_info(ctrl, "Power fault on Slot(%s)\n", slot_name(p_slot)); |
159 | event_type = INT_POWER_FAULT; | 159 | event_type = INT_POWER_FAULT; |
160 | ctrl_info(ctrl, "power fault bit %x set\n", 0); | 160 | ctrl_info(ctrl, "Power fault bit %x set\n", 0); |
161 | } | 161 | } |
162 | 162 | ||
163 | queue_interrupt_event(p_slot, event_type); | 163 | queue_interrupt_event(p_slot, event_type); |
@@ -175,8 +175,7 @@ static void set_slot_off(struct controller *ctrl, struct slot * pslot) | |||
175 | if (POWER_CTRL(ctrl)) { | 175 | if (POWER_CTRL(ctrl)) { |
176 | if (pslot->hpc_ops->power_off_slot(pslot)) { | 176 | if (pslot->hpc_ops->power_off_slot(pslot)) { |
177 | ctrl_err(ctrl, | 177 | ctrl_err(ctrl, |
178 | "%s: Issue of Slot Power Off command failed\n", | 178 | "Issue of Slot Power Off command failed\n"); |
179 | __func__); | ||
180 | return; | 179 | return; |
181 | } | 180 | } |
182 | } | 181 | } |
@@ -193,8 +192,8 @@ static void set_slot_off(struct controller *ctrl, struct slot * pslot) | |||
193 | 192 | ||
194 | if (ATTN_LED(ctrl)) { | 193 | if (ATTN_LED(ctrl)) { |
195 | if (pslot->hpc_ops->set_attention_status(pslot, 1)) { | 194 | if (pslot->hpc_ops->set_attention_status(pslot, 1)) { |
196 | ctrl_err(ctrl, "%s: Issue of Set Attention " | 195 | ctrl_err(ctrl, |
197 | "Led command failed\n", __func__); | 196 | "Issue of Set Attention Led command failed\n"); |
198 | return; | 197 | return; |
199 | } | 198 | } |
200 | } | 199 | } |
@@ -211,8 +210,9 @@ static int board_added(struct slot *p_slot) | |||
211 | { | 210 | { |
212 | int retval = 0; | 211 | int retval = 0; |
213 | struct controller *ctrl = p_slot->ctrl; | 212 | struct controller *ctrl = p_slot->ctrl; |
213 | struct pci_bus *parent = ctrl->pci_dev->subordinate; | ||
214 | 214 | ||
215 | ctrl_dbg(ctrl, "%s: slot device, slot offset, hp slot = %d, %d ,%d\n", | 215 | ctrl_dbg(ctrl, "%s: slot device, slot offset, hp slot = %d, %d, %d\n", |
216 | __func__, p_slot->device, ctrl->slot_device_offset, | 216 | __func__, p_slot->device, ctrl->slot_device_offset, |
217 | p_slot->hp_slot); | 217 | p_slot->hp_slot); |
218 | 218 | ||
@@ -229,22 +229,22 @@ static int board_added(struct slot *p_slot) | |||
229 | /* Check link training status */ | 229 | /* Check link training status */ |
230 | retval = p_slot->hpc_ops->check_lnk_status(ctrl); | 230 | retval = p_slot->hpc_ops->check_lnk_status(ctrl); |
231 | if (retval) { | 231 | if (retval) { |
232 | ctrl_err(ctrl, "%s: Failed to check link status\n", __func__); | 232 | ctrl_err(ctrl, "Failed to check link status\n"); |
233 | set_slot_off(ctrl, p_slot); | 233 | set_slot_off(ctrl, p_slot); |
234 | return retval; | 234 | return retval; |
235 | } | 235 | } |
236 | 236 | ||
237 | /* Check for a power fault */ | 237 | /* Check for a power fault */ |
238 | if (p_slot->hpc_ops->query_power_fault(p_slot)) { | 238 | if (p_slot->hpc_ops->query_power_fault(p_slot)) { |
239 | ctrl_dbg(ctrl, "%s: power fault detected\n", __func__); | 239 | ctrl_dbg(ctrl, "Power fault detected\n"); |
240 | retval = POWER_FAILURE; | 240 | retval = POWER_FAILURE; |
241 | goto err_exit; | 241 | goto err_exit; |
242 | } | 242 | } |
243 | 243 | ||
244 | retval = pciehp_configure_device(p_slot); | 244 | retval = pciehp_configure_device(p_slot); |
245 | if (retval) { | 245 | if (retval) { |
246 | ctrl_err(ctrl, "Cannot add device 0x%x:%x\n", | 246 | ctrl_err(ctrl, "Cannot add device at %04x:%02x:%02x\n", |
247 | p_slot->bus, p_slot->device); | 247 | pci_domain_nr(parent), p_slot->bus, p_slot->device); |
248 | goto err_exit; | 248 | goto err_exit; |
249 | } | 249 | } |
250 | 250 | ||
@@ -276,14 +276,14 @@ static int remove_board(struct slot *p_slot) | |||
276 | if (retval) | 276 | if (retval) |
277 | return retval; | 277 | return retval; |
278 | 278 | ||
279 | ctrl_dbg(ctrl, "In %s, hp_slot = %d\n", __func__, p_slot->hp_slot); | 279 | ctrl_dbg(ctrl, "%s: hp_slot = %d\n", __func__, p_slot->hp_slot); |
280 | 280 | ||
281 | if (POWER_CTRL(ctrl)) { | 281 | if (POWER_CTRL(ctrl)) { |
282 | /* power off slot */ | 282 | /* power off slot */ |
283 | retval = p_slot->hpc_ops->power_off_slot(p_slot); | 283 | retval = p_slot->hpc_ops->power_off_slot(p_slot); |
284 | if (retval) { | 284 | if (retval) { |
285 | ctrl_err(ctrl, "%s: Issue of Slot Disable command " | 285 | ctrl_err(ctrl, |
286 | "failed\n", __func__); | 286 | "Issue of Slot Disable command failed\n"); |
287 | return retval; | 287 | return retval; |
288 | } | 288 | } |
289 | } | 289 | } |
@@ -324,8 +324,10 @@ static void pciehp_power_thread(struct work_struct *work) | |||
324 | switch (p_slot->state) { | 324 | switch (p_slot->state) { |
325 | case POWEROFF_STATE: | 325 | case POWEROFF_STATE: |
326 | mutex_unlock(&p_slot->lock); | 326 | mutex_unlock(&p_slot->lock); |
327 | ctrl_dbg(p_slot->ctrl, "%s: disabling bus:device(%x:%x)\n", | 327 | ctrl_dbg(p_slot->ctrl, |
328 | __func__, p_slot->bus, p_slot->device); | 328 | "Disabling domain:bus:device=%04x:%02x:%02x\n", |
329 | pci_domain_nr(p_slot->ctrl->pci_dev->subordinate), | ||
330 | p_slot->bus, p_slot->device); | ||
329 | pciehp_disable_slot(p_slot); | 331 | pciehp_disable_slot(p_slot); |
330 | mutex_lock(&p_slot->lock); | 332 | mutex_lock(&p_slot->lock); |
331 | p_slot->state = STATIC_STATE; | 333 | p_slot->state = STATIC_STATE; |
@@ -433,7 +435,6 @@ static void handle_button_press_event(struct slot *p_slot) | |||
433 | * expires to cancel hot-add or hot-remove | 435 | * expires to cancel hot-add or hot-remove |
434 | */ | 436 | */ |
435 | ctrl_info(ctrl, "Button cancel on Slot(%s)\n", slot_name(p_slot)); | 437 | ctrl_info(ctrl, "Button cancel on Slot(%s)\n", slot_name(p_slot)); |
436 | ctrl_dbg(ctrl, "%s: button cancel\n", __func__); | ||
437 | cancel_delayed_work(&p_slot->work); | 438 | cancel_delayed_work(&p_slot->work); |
438 | if (p_slot->state == BLINKINGOFF_STATE) { | 439 | if (p_slot->state == BLINKINGOFF_STATE) { |
439 | if (PWR_LED(ctrl)) | 440 | if (PWR_LED(ctrl)) |
@@ -537,16 +538,15 @@ int pciehp_enable_slot(struct slot *p_slot) | |||
537 | 538 | ||
538 | rc = p_slot->hpc_ops->get_adapter_status(p_slot, &getstatus); | 539 | rc = p_slot->hpc_ops->get_adapter_status(p_slot, &getstatus); |
539 | if (rc || !getstatus) { | 540 | if (rc || !getstatus) { |
540 | ctrl_info(ctrl, "%s: no adapter on slot(%s)\n", | 541 | ctrl_info(ctrl, "No adapter on slot(%s)\n", slot_name(p_slot)); |
541 | __func__, slot_name(p_slot)); | ||
542 | mutex_unlock(&p_slot->ctrl->crit_sect); | 542 | mutex_unlock(&p_slot->ctrl->crit_sect); |
543 | return -ENODEV; | 543 | return -ENODEV; |
544 | } | 544 | } |
545 | if (MRL_SENS(p_slot->ctrl)) { | 545 | if (MRL_SENS(p_slot->ctrl)) { |
546 | rc = p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); | 546 | rc = p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); |
547 | if (rc || getstatus) { | 547 | if (rc || getstatus) { |
548 | ctrl_info(ctrl, "%s: latch open on slot(%s)\n", | 548 | ctrl_info(ctrl, "Latch open on slot(%s)\n", |
549 | __func__, slot_name(p_slot)); | 549 | slot_name(p_slot)); |
550 | mutex_unlock(&p_slot->ctrl->crit_sect); | 550 | mutex_unlock(&p_slot->ctrl->crit_sect); |
551 | return -ENODEV; | 551 | return -ENODEV; |
552 | } | 552 | } |
@@ -555,8 +555,8 @@ int pciehp_enable_slot(struct slot *p_slot) | |||
555 | if (POWER_CTRL(p_slot->ctrl)) { | 555 | if (POWER_CTRL(p_slot->ctrl)) { |
556 | rc = p_slot->hpc_ops->get_power_status(p_slot, &getstatus); | 556 | rc = p_slot->hpc_ops->get_power_status(p_slot, &getstatus); |
557 | if (rc || getstatus) { | 557 | if (rc || getstatus) { |
558 | ctrl_info(ctrl, "%s: already enabled on slot(%s)\n", | 558 | ctrl_info(ctrl, "Already enabled on slot(%s)\n", |
559 | __func__, slot_name(p_slot)); | 559 | slot_name(p_slot)); |
560 | mutex_unlock(&p_slot->ctrl->crit_sect); | 560 | mutex_unlock(&p_slot->ctrl->crit_sect); |
561 | return -EINVAL; | 561 | return -EINVAL; |
562 | } | 562 | } |
@@ -591,8 +591,8 @@ int pciehp_disable_slot(struct slot *p_slot) | |||
591 | if (!HP_SUPR_RM(p_slot->ctrl)) { | 591 | if (!HP_SUPR_RM(p_slot->ctrl)) { |
592 | ret = p_slot->hpc_ops->get_adapter_status(p_slot, &getstatus); | 592 | ret = p_slot->hpc_ops->get_adapter_status(p_slot, &getstatus); |
593 | if (ret || !getstatus) { | 593 | if (ret || !getstatus) { |
594 | ctrl_info(ctrl, "%s: no adapter on slot(%s)\n", | 594 | ctrl_info(ctrl, "No adapter on slot(%s)\n", |
595 | __func__, slot_name(p_slot)); | 595 | slot_name(p_slot)); |
596 | mutex_unlock(&p_slot->ctrl->crit_sect); | 596 | mutex_unlock(&p_slot->ctrl->crit_sect); |
597 | return -ENODEV; | 597 | return -ENODEV; |
598 | } | 598 | } |
@@ -601,8 +601,8 @@ int pciehp_disable_slot(struct slot *p_slot) | |||
601 | if (MRL_SENS(p_slot->ctrl)) { | 601 | if (MRL_SENS(p_slot->ctrl)) { |
602 | ret = p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); | 602 | ret = p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); |
603 | if (ret || getstatus) { | 603 | if (ret || getstatus) { |
604 | ctrl_info(ctrl, "%s: latch open on slot(%s)\n", | 604 | ctrl_info(ctrl, "Latch open on slot(%s)\n", |
605 | __func__, slot_name(p_slot)); | 605 | slot_name(p_slot)); |
606 | mutex_unlock(&p_slot->ctrl->crit_sect); | 606 | mutex_unlock(&p_slot->ctrl->crit_sect); |
607 | return -ENODEV; | 607 | return -ENODEV; |
608 | } | 608 | } |
@@ -611,8 +611,8 @@ int pciehp_disable_slot(struct slot *p_slot) | |||
611 | if (POWER_CTRL(p_slot->ctrl)) { | 611 | if (POWER_CTRL(p_slot->ctrl)) { |
612 | ret = p_slot->hpc_ops->get_power_status(p_slot, &getstatus); | 612 | ret = p_slot->hpc_ops->get_power_status(p_slot, &getstatus); |
613 | if (ret || !getstatus) { | 613 | if (ret || !getstatus) { |
614 | ctrl_info(ctrl, "%s: already disabled slot(%s)\n", | 614 | ctrl_info(ctrl, "Already disabled on slot(%s)\n", |
615 | __func__, slot_name(p_slot)); | 615 | slot_name(p_slot)); |
616 | mutex_unlock(&p_slot->ctrl->crit_sect); | 616 | mutex_unlock(&p_slot->ctrl->crit_sect); |
617 | return -EINVAL; | 617 | return -EINVAL; |
618 | } | 618 | } |
diff --git a/drivers/pci/hotplug/pciehp_hpc.c b/drivers/pci/hotplug/pciehp_hpc.c index 58c72d2cc217..b643ca13e4f1 100644 --- a/drivers/pci/hotplug/pciehp_hpc.c +++ b/drivers/pci/hotplug/pciehp_hpc.c | |||
@@ -316,22 +316,19 @@ static int pcie_write_cmd(struct controller *ctrl, u16 cmd, u16 mask) | |||
316 | * proceed forward to issue the next command according | 316 | * proceed forward to issue the next command according |
317 | * to spec. Just print out the error message. | 317 | * to spec. Just print out the error message. |
318 | */ | 318 | */ |
319 | ctrl_dbg(ctrl, | 319 | ctrl_dbg(ctrl, "CMD_COMPLETED not clear after 1 sec\n"); |
320 | "%s: CMD_COMPLETED not clear after 1 sec.\n", | ||
321 | __func__); | ||
322 | } else if (!NO_CMD_CMPL(ctrl)) { | 320 | } else if (!NO_CMD_CMPL(ctrl)) { |
323 | /* | 321 | /* |
324 | * This controller semms to notify of command completed | 322 | * This controller semms to notify of command completed |
325 | * event even though it supports none of power | 323 | * event even though it supports none of power |
326 | * controller, attention led, power led and EMI. | 324 | * controller, attention led, power led and EMI. |
327 | */ | 325 | */ |
328 | ctrl_dbg(ctrl, "%s: Unexpected CMD_COMPLETED. Need to " | 326 | ctrl_dbg(ctrl, "Unexpected CMD_COMPLETED. Need to " |
329 | "wait for command completed event.\n", | 327 | "wait for command completed event.\n"); |
330 | __func__); | ||
331 | ctrl->no_cmd_complete = 0; | 328 | ctrl->no_cmd_complete = 0; |
332 | } else { | 329 | } else { |
333 | ctrl_dbg(ctrl, "%s: Unexpected CMD_COMPLETED. Maybe " | 330 | ctrl_dbg(ctrl, "Unexpected CMD_COMPLETED. Maybe " |
334 | "the controller is broken.\n", __func__); | 331 | "the controller is broken.\n"); |
335 | } | 332 | } |
336 | } | 333 | } |
337 | 334 | ||
@@ -347,8 +344,7 @@ static int pcie_write_cmd(struct controller *ctrl, u16 cmd, u16 mask) | |||
347 | smp_mb(); | 344 | smp_mb(); |
348 | retval = pciehp_writew(ctrl, SLOTCTRL, slot_ctrl); | 345 | retval = pciehp_writew(ctrl, SLOTCTRL, slot_ctrl); |
349 | if (retval) | 346 | if (retval) |
350 | ctrl_err(ctrl, "%s: Cannot write to SLOTCTRL register\n", | 347 | ctrl_err(ctrl, "Cannot write to SLOTCTRL register\n"); |
351 | __func__); | ||
352 | 348 | ||
353 | /* | 349 | /* |
354 | * Wait for command completion. | 350 | * Wait for command completion. |
@@ -418,15 +414,14 @@ static int hpc_check_lnk_status(struct controller *ctrl) | |||
418 | 414 | ||
419 | retval = pciehp_readw(ctrl, LNKSTATUS, &lnk_status); | 415 | retval = pciehp_readw(ctrl, LNKSTATUS, &lnk_status); |
420 | if (retval) { | 416 | if (retval) { |
421 | ctrl_err(ctrl, "%s: Cannot read LNKSTATUS register\n", | 417 | ctrl_err(ctrl, "Cannot read LNKSTATUS register\n"); |
422 | __func__); | ||
423 | return retval; | 418 | return retval; |
424 | } | 419 | } |
425 | 420 | ||
426 | ctrl_dbg(ctrl, "%s: lnk_status = %x\n", __func__, lnk_status); | 421 | ctrl_dbg(ctrl, "%s: lnk_status = %x\n", __func__, lnk_status); |
427 | if ( (lnk_status & LNK_TRN) || (lnk_status & LNK_TRN_ERR) || | 422 | if ( (lnk_status & LNK_TRN) || (lnk_status & LNK_TRN_ERR) || |
428 | !(lnk_status & NEG_LINK_WD)) { | 423 | !(lnk_status & NEG_LINK_WD)) { |
429 | ctrl_err(ctrl, "%s : Link Training Error occurs \n", __func__); | 424 | ctrl_err(ctrl, "Link Training Error occurs \n"); |
430 | retval = -1; | 425 | retval = -1; |
431 | return retval; | 426 | return retval; |
432 | } | 427 | } |
@@ -551,7 +546,7 @@ static int hpc_query_power_fault(struct slot *slot) | |||
551 | 546 | ||
552 | retval = pciehp_readw(ctrl, SLOTSTATUS, &slot_status); | 547 | retval = pciehp_readw(ctrl, SLOTSTATUS, &slot_status); |
553 | if (retval) { | 548 | if (retval) { |
554 | ctrl_err(ctrl, "%s: Cannot check for power fault\n", __func__); | 549 | ctrl_err(ctrl, "Cannot check for power fault\n"); |
555 | return retval; | 550 | return retval; |
556 | } | 551 | } |
557 | pwr_fault = (u8)((slot_status & PWR_FAULT_DETECTED) >> 1); | 552 | pwr_fault = (u8)((slot_status & PWR_FAULT_DETECTED) >> 1); |
@@ -567,7 +562,7 @@ static int hpc_get_emi_status(struct slot *slot, u8 *status) | |||
567 | 562 | ||
568 | retval = pciehp_readw(ctrl, SLOTSTATUS, &slot_status); | 563 | retval = pciehp_readw(ctrl, SLOTSTATUS, &slot_status); |
569 | if (retval) { | 564 | if (retval) { |
570 | ctrl_err(ctrl, "%s : Cannot check EMI status\n", __func__); | 565 | ctrl_err(ctrl, "Cannot check EMI status\n"); |
571 | return retval; | 566 | return retval; |
572 | } | 567 | } |
573 | *status = (slot_status & EMI_STATE) >> EMI_STATUS_BIT; | 568 | *status = (slot_status & EMI_STATE) >> EMI_STATUS_BIT; |
@@ -697,8 +692,7 @@ static int hpc_power_on_slot(struct slot * slot) | |||
697 | retval = pcie_write_cmd(ctrl, slot_cmd, cmd_mask); | 692 | retval = pcie_write_cmd(ctrl, slot_cmd, cmd_mask); |
698 | 693 | ||
699 | if (retval) { | 694 | if (retval) { |
700 | ctrl_err(ctrl, "%s: Write %x command failed!\n", | 695 | ctrl_err(ctrl, "Write %x command failed!\n", slot_cmd); |
701 | __func__, slot_cmd); | ||
702 | return -1; | 696 | return -1; |
703 | } | 697 | } |
704 | ctrl_dbg(ctrl, "%s: SLOTCTRL %x write cmd %x\n", | 698 | ctrl_dbg(ctrl, "%s: SLOTCTRL %x write cmd %x\n", |
@@ -776,7 +770,7 @@ static int hpc_power_off_slot(struct slot * slot) | |||
776 | 770 | ||
777 | retval = pcie_write_cmd(ctrl, slot_cmd, cmd_mask); | 771 | retval = pcie_write_cmd(ctrl, slot_cmd, cmd_mask); |
778 | if (retval) { | 772 | if (retval) { |
779 | ctrl_err(ctrl, "%s: Write command failed!\n", __func__); | 773 | ctrl_err(ctrl, "Write command failed!\n"); |
780 | retval = -1; | 774 | retval = -1; |
781 | goto out; | 775 | goto out; |
782 | } | 776 | } |
@@ -1056,8 +1050,7 @@ int pcie_enable_notification(struct controller *ctrl) | |||
1056 | PWR_FAULT_DETECT_ENABLE | HP_INTR_ENABLE | CMD_CMPL_INTR_ENABLE; | 1050 | PWR_FAULT_DETECT_ENABLE | HP_INTR_ENABLE | CMD_CMPL_INTR_ENABLE; |
1057 | 1051 | ||
1058 | if (pcie_write_cmd(ctrl, cmd, mask)) { | 1052 | if (pcie_write_cmd(ctrl, cmd, mask)) { |
1059 | ctrl_err(ctrl, "%s: Cannot enable software notification\n", | 1053 | ctrl_err(ctrl, "Cannot enable software notification\n"); |
1060 | __func__); | ||
1061 | return -1; | 1054 | return -1; |
1062 | } | 1055 | } |
1063 | return 0; | 1056 | return 0; |
@@ -1069,8 +1062,7 @@ static void pcie_disable_notification(struct controller *ctrl) | |||
1069 | mask = PRSN_DETECT_ENABLE | ATTN_BUTTN_ENABLE | MRL_DETECT_ENABLE | | 1062 | mask = PRSN_DETECT_ENABLE | ATTN_BUTTN_ENABLE | MRL_DETECT_ENABLE | |
1070 | PWR_FAULT_DETECT_ENABLE | HP_INTR_ENABLE | CMD_CMPL_INTR_ENABLE; | 1063 | PWR_FAULT_DETECT_ENABLE | HP_INTR_ENABLE | CMD_CMPL_INTR_ENABLE; |
1071 | if (pcie_write_cmd(ctrl, 0, mask)) | 1064 | if (pcie_write_cmd(ctrl, 0, mask)) |
1072 | ctrl_warn(ctrl, "%s: Cannot disable software notification\n", | 1065 | ctrl_warn(ctrl, "Cannot disable software notification\n"); |
1073 | __func__); | ||
1074 | } | 1066 | } |
1075 | 1067 | ||
1076 | static int pcie_init_notification(struct controller *ctrl) | 1068 | static int pcie_init_notification(struct controller *ctrl) |
@@ -1179,7 +1171,7 @@ struct controller *pcie_init(struct pcie_device *dev) | |||
1179 | 1171 | ||
1180 | ctrl = kzalloc(sizeof(*ctrl), GFP_KERNEL); | 1172 | ctrl = kzalloc(sizeof(*ctrl), GFP_KERNEL); |
1181 | if (!ctrl) { | 1173 | if (!ctrl) { |
1182 | dev_err(&dev->device, "%s : out of memory\n", __func__); | 1174 | dev_err(&dev->device, "%s: Out of memory\n", __func__); |
1183 | goto abort; | 1175 | goto abort; |
1184 | } | 1176 | } |
1185 | INIT_LIST_HEAD(&ctrl->slot_list); | 1177 | INIT_LIST_HEAD(&ctrl->slot_list); |
@@ -1188,12 +1180,11 @@ struct controller *pcie_init(struct pcie_device *dev) | |||
1188 | ctrl->pci_dev = pdev; | 1180 | ctrl->pci_dev = pdev; |
1189 | ctrl->cap_base = pci_find_capability(pdev, PCI_CAP_ID_EXP); | 1181 | ctrl->cap_base = pci_find_capability(pdev, PCI_CAP_ID_EXP); |
1190 | if (!ctrl->cap_base) { | 1182 | if (!ctrl->cap_base) { |
1191 | ctrl_err(ctrl, "%s: Cannot find PCI Express capability\n", | 1183 | ctrl_err(ctrl, "Cannot find PCI Express capability\n"); |
1192 | __func__); | ||
1193 | goto abort_ctrl; | 1184 | goto abort_ctrl; |
1194 | } | 1185 | } |
1195 | if (pciehp_readl(ctrl, SLOTCAP, &slot_cap)) { | 1186 | if (pciehp_readl(ctrl, SLOTCAP, &slot_cap)) { |
1196 | ctrl_err(ctrl, "%s: Cannot read SLOTCAP register\n", __func__); | 1187 | ctrl_err(ctrl, "Cannot read SLOTCAP register\n"); |
1197 | goto abort_ctrl; | 1188 | goto abort_ctrl; |
1198 | } | 1189 | } |
1199 | 1190 | ||
diff --git a/drivers/pci/hotplug/pciehp_pci.c b/drivers/pci/hotplug/pciehp_pci.c index ffd11148fbe2..10f9566cceeb 100644 --- a/drivers/pci/hotplug/pciehp_pci.c +++ b/drivers/pci/hotplug/pciehp_pci.c | |||
@@ -39,8 +39,7 @@ static void program_hpp_type0(struct pci_dev *dev, struct hpp_type0 *hpp) | |||
39 | u16 pci_cmd, pci_bctl; | 39 | u16 pci_cmd, pci_bctl; |
40 | 40 | ||
41 | if (hpp->revision > 1) { | 41 | if (hpp->revision > 1) { |
42 | printk(KERN_WARNING "%s: Rev.%d type0 record not supported\n", | 42 | warn("Rev.%d type0 record not supported\n", hpp->revision); |
43 | __func__, hpp->revision); | ||
44 | return; | 43 | return; |
45 | } | 44 | } |
46 | 45 | ||
@@ -81,8 +80,7 @@ static void program_hpp_type2(struct pci_dev *dev, struct hpp_type2 *hpp) | |||
81 | u32 reg32; | 80 | u32 reg32; |
82 | 81 | ||
83 | if (hpp->revision > 1) { | 82 | if (hpp->revision > 1) { |
84 | printk(KERN_WARNING "%s: Rev.%d type2 record not supported\n", | 83 | warn("Rev.%d type2 record not supported\n", hpp->revision); |
85 | __func__, hpp->revision); | ||
86 | return; | 84 | return; |
87 | } | 85 | } |
88 | 86 | ||
@@ -149,8 +147,7 @@ static void program_fw_provided_values(struct pci_dev *dev) | |||
149 | return; | 147 | return; |
150 | 148 | ||
151 | if (pciehp_get_hp_params_from_firmware(dev, &hpp)) { | 149 | if (pciehp_get_hp_params_from_firmware(dev, &hpp)) { |
152 | printk(KERN_WARNING "%s: Could not get hotplug parameters\n", | 150 | warn("Could not get hotplug parameters\n"); |
153 | __func__); | ||
154 | return; | 151 | return; |
155 | } | 152 | } |
156 | 153 | ||
@@ -202,9 +199,9 @@ int pciehp_configure_device(struct slot *p_slot) | |||
202 | 199 | ||
203 | dev = pci_get_slot(parent, PCI_DEVFN(p_slot->device, 0)); | 200 | dev = pci_get_slot(parent, PCI_DEVFN(p_slot->device, 0)); |
204 | if (dev) { | 201 | if (dev) { |
205 | ctrl_err(ctrl, | 202 | ctrl_err(ctrl, "Device %s already exists " |
206 | "Device %s already exists at %x:%x, cannot hot-add\n", | 203 | "at %04x:%02x:%02x, cannot hot-add\n", pci_name(dev), |
207 | pci_name(dev), p_slot->bus, p_slot->device); | 204 | pci_domain_nr(parent), p_slot->bus, p_slot->device); |
208 | pci_dev_put(dev); | 205 | pci_dev_put(dev); |
209 | return -EINVAL; | 206 | return -EINVAL; |
210 | } | 207 | } |
@@ -248,8 +245,8 @@ int pciehp_unconfigure_device(struct slot *p_slot) | |||
248 | u16 command; | 245 | u16 command; |
249 | struct controller *ctrl = p_slot->ctrl; | 246 | struct controller *ctrl = p_slot->ctrl; |
250 | 247 | ||
251 | ctrl_dbg(ctrl, "%s: bus/dev = %x/%x\n", __func__, | 248 | ctrl_dbg(ctrl, "%s: domain:bus:dev = %04x:%02x:%02x\n", |
252 | p_slot->bus, p_slot->device); | 249 | __func__, pci_domain_nr(parent), p_slot->bus, p_slot->device); |
253 | ret = p_slot->hpc_ops->get_adapter_status(p_slot, &presence); | 250 | ret = p_slot->hpc_ops->get_adapter_status(p_slot, &presence); |
254 | if (ret) | 251 | if (ret) |
255 | presence = 0; | 252 | presence = 0; |
diff --git a/drivers/pci/hotplug/shpchp.h b/drivers/pci/hotplug/shpchp.h index 4d9fed00e1d0..6aba0b6cf2e0 100644 --- a/drivers/pci/hotplug/shpchp.h +++ b/drivers/pci/hotplug/shpchp.h | |||
@@ -59,6 +59,20 @@ extern struct workqueue_struct *shpchp_wq; | |||
59 | #define warn(format, arg...) \ | 59 | #define warn(format, arg...) \ |
60 | printk(KERN_WARNING "%s: " format, MY_NAME , ## arg) | 60 | printk(KERN_WARNING "%s: " format, MY_NAME , ## arg) |
61 | 61 | ||
62 | #define ctrl_dbg(ctrl, format, arg...) \ | ||
63 | do { \ | ||
64 | if (shpchp_debug) \ | ||
65 | dev_printk(, &ctrl->pci_dev->dev, \ | ||
66 | format, ## arg); \ | ||
67 | } while (0) | ||
68 | #define ctrl_err(ctrl, format, arg...) \ | ||
69 | dev_err(&ctrl->pci_dev->dev, format, ## arg) | ||
70 | #define ctrl_info(ctrl, format, arg...) \ | ||
71 | dev_info(&ctrl->pci_dev->dev, format, ## arg) | ||
72 | #define ctrl_warn(ctrl, format, arg...) \ | ||
73 | dev_warn(&ctrl->pci_dev->dev, format, ## arg) | ||
74 | |||
75 | |||
62 | #define SLOT_NAME_SIZE 10 | 76 | #define SLOT_NAME_SIZE 10 |
63 | struct slot { | 77 | struct slot { |
64 | u8 bus; | 78 | u8 bus; |
@@ -239,7 +253,7 @@ static inline struct slot *shpchp_find_slot(struct controller *ctrl, u8 device) | |||
239 | return slot; | 253 | return slot; |
240 | } | 254 | } |
241 | 255 | ||
242 | err("%s: slot (device=0x%x) not found\n", __func__, device); | 256 | ctrl_err(ctrl, "Slot (device=0x%02x) not found\n", device); |
243 | return NULL; | 257 | return NULL; |
244 | } | 258 | } |
245 | 259 | ||
@@ -273,7 +287,9 @@ static inline void amd_pogo_errata_restore_misc_reg(struct slot *p_slot) | |||
273 | pci_read_config_dword(p_slot->ctrl->pci_dev, PCIX_MISC_BRIDGE_ERRORS_OFFSET, &pcix_bridge_errors_reg); | 287 | pci_read_config_dword(p_slot->ctrl->pci_dev, PCIX_MISC_BRIDGE_ERRORS_OFFSET, &pcix_bridge_errors_reg); |
274 | perr_set = pcix_bridge_errors_reg & PERR_OBSERVED_MASK; | 288 | perr_set = pcix_bridge_errors_reg & PERR_OBSERVED_MASK; |
275 | if (perr_set) { | 289 | if (perr_set) { |
276 | dbg ("%s W1C: Bridge_Errors[ PERR_OBSERVED = %08X]\n",__func__ , perr_set); | 290 | ctrl_dbg(p_slot->ctrl, |
291 | "Bridge_Errors[ PERR_OBSERVED = %08X] (W1C)\n", | ||
292 | perr_set); | ||
277 | 293 | ||
278 | pci_write_config_dword(p_slot->ctrl->pci_dev, PCIX_MISC_BRIDGE_ERRORS_OFFSET, perr_set); | 294 | pci_write_config_dword(p_slot->ctrl->pci_dev, PCIX_MISC_BRIDGE_ERRORS_OFFSET, perr_set); |
279 | } | 295 | } |
@@ -282,7 +298,7 @@ static inline void amd_pogo_errata_restore_misc_reg(struct slot *p_slot) | |||
282 | pci_read_config_dword(p_slot->ctrl->pci_dev, PCIX_MEM_BASE_LIMIT_OFFSET, &pcix_mem_base_reg); | 298 | pci_read_config_dword(p_slot->ctrl->pci_dev, PCIX_MEM_BASE_LIMIT_OFFSET, &pcix_mem_base_reg); |
283 | rse_set = pcix_mem_base_reg & RSE_MASK; | 299 | rse_set = pcix_mem_base_reg & RSE_MASK; |
284 | if (rse_set) { | 300 | if (rse_set) { |
285 | dbg ("%s W1C: Memory_Base_Limit[ RSE ]\n",__func__ ); | 301 | ctrl_dbg(p_slot->ctrl, "Memory_Base_Limit[ RSE ] (W1C)\n"); |
286 | 302 | ||
287 | pci_write_config_dword(p_slot->ctrl->pci_dev, PCIX_MEM_BASE_LIMIT_OFFSET, rse_set); | 303 | pci_write_config_dword(p_slot->ctrl->pci_dev, PCIX_MEM_BASE_LIMIT_OFFSET, rse_set); |
288 | } | 304 | } |
diff --git a/drivers/pci/hotplug/shpchp_core.c b/drivers/pci/hotplug/shpchp_core.c index 7af9191df4d6..fe8d149c2293 100644 --- a/drivers/pci/hotplug/shpchp_core.c +++ b/drivers/pci/hotplug/shpchp_core.c | |||
@@ -89,7 +89,8 @@ static void release_slot(struct hotplug_slot *hotplug_slot) | |||
89 | { | 89 | { |
90 | struct slot *slot = hotplug_slot->private; | 90 | struct slot *slot = hotplug_slot->private; |
91 | 91 | ||
92 | dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); | 92 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
93 | __func__, slot_name(slot)); | ||
93 | 94 | ||
94 | kfree(slot->hotplug_slot->info); | 95 | kfree(slot->hotplug_slot->info); |
95 | kfree(slot->hotplug_slot); | 96 | kfree(slot->hotplug_slot); |
@@ -135,13 +136,16 @@ static int init_slots(struct controller *ctrl) | |||
135 | snprintf(name, SLOT_NAME_SIZE, "%d", slot->number); | 136 | snprintf(name, SLOT_NAME_SIZE, "%d", slot->number); |
136 | hotplug_slot->ops = &shpchp_hotplug_slot_ops; | 137 | hotplug_slot->ops = &shpchp_hotplug_slot_ops; |
137 | 138 | ||
138 | dbg("Registering bus=%x dev=%x hp_slot=%x sun=%x " | 139 | ctrl_dbg(ctrl, "Registering domain:bus:dev=%04x:%02x:%02x " |
139 | "slot_device_offset=%x\n", slot->bus, slot->device, | 140 | "hp_slot=%x sun=%x slot_device_offset=%x\n", |
140 | slot->hp_slot, slot->number, ctrl->slot_device_offset); | 141 | pci_domain_nr(ctrl->pci_dev->subordinate), |
142 | slot->bus, slot->device, slot->hp_slot, slot->number, | ||
143 | ctrl->slot_device_offset); | ||
141 | retval = pci_hp_register(slot->hotplug_slot, | 144 | retval = pci_hp_register(slot->hotplug_slot, |
142 | ctrl->pci_dev->subordinate, slot->device, name); | 145 | ctrl->pci_dev->subordinate, slot->device, name); |
143 | if (retval) { | 146 | if (retval) { |
144 | err("pci_hp_register failed with error %d\n", retval); | 147 | ctrl_err(ctrl, "pci_hp_register failed with error %d\n", |
148 | retval); | ||
145 | goto error_info; | 149 | goto error_info; |
146 | } | 150 | } |
147 | 151 | ||
@@ -187,7 +191,8 @@ static int set_attention_status (struct hotplug_slot *hotplug_slot, u8 status) | |||
187 | { | 191 | { |
188 | struct slot *slot = get_slot(hotplug_slot); | 192 | struct slot *slot = get_slot(hotplug_slot); |
189 | 193 | ||
190 | dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); | 194 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
195 | __func__, slot_name(slot)); | ||
191 | 196 | ||
192 | hotplug_slot->info->attention_status = status; | 197 | hotplug_slot->info->attention_status = status; |
193 | slot->hpc_ops->set_attention_status(slot, status); | 198 | slot->hpc_ops->set_attention_status(slot, status); |
@@ -199,7 +204,8 @@ static int enable_slot (struct hotplug_slot *hotplug_slot) | |||
199 | { | 204 | { |
200 | struct slot *slot = get_slot(hotplug_slot); | 205 | struct slot *slot = get_slot(hotplug_slot); |
201 | 206 | ||
202 | dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); | 207 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
208 | __func__, slot_name(slot)); | ||
203 | 209 | ||
204 | return shpchp_sysfs_enable_slot(slot); | 210 | return shpchp_sysfs_enable_slot(slot); |
205 | } | 211 | } |
@@ -208,7 +214,8 @@ static int disable_slot (struct hotplug_slot *hotplug_slot) | |||
208 | { | 214 | { |
209 | struct slot *slot = get_slot(hotplug_slot); | 215 | struct slot *slot = get_slot(hotplug_slot); |
210 | 216 | ||
211 | dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); | 217 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
218 | __func__, slot_name(slot)); | ||
212 | 219 | ||
213 | return shpchp_sysfs_disable_slot(slot); | 220 | return shpchp_sysfs_disable_slot(slot); |
214 | } | 221 | } |
@@ -218,7 +225,8 @@ static int get_power_status (struct hotplug_slot *hotplug_slot, u8 *value) | |||
218 | struct slot *slot = get_slot(hotplug_slot); | 225 | struct slot *slot = get_slot(hotplug_slot); |
219 | int retval; | 226 | int retval; |
220 | 227 | ||
221 | dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); | 228 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
229 | __func__, slot_name(slot)); | ||
222 | 230 | ||
223 | retval = slot->hpc_ops->get_power_status(slot, value); | 231 | retval = slot->hpc_ops->get_power_status(slot, value); |
224 | if (retval < 0) | 232 | if (retval < 0) |
@@ -232,7 +240,8 @@ static int get_attention_status (struct hotplug_slot *hotplug_slot, u8 *value) | |||
232 | struct slot *slot = get_slot(hotplug_slot); | 240 | struct slot *slot = get_slot(hotplug_slot); |
233 | int retval; | 241 | int retval; |
234 | 242 | ||
235 | dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); | 243 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
244 | __func__, slot_name(slot)); | ||
236 | 245 | ||
237 | retval = slot->hpc_ops->get_attention_status(slot, value); | 246 | retval = slot->hpc_ops->get_attention_status(slot, value); |
238 | if (retval < 0) | 247 | if (retval < 0) |
@@ -246,7 +255,8 @@ static int get_latch_status (struct hotplug_slot *hotplug_slot, u8 *value) | |||
246 | struct slot *slot = get_slot(hotplug_slot); | 255 | struct slot *slot = get_slot(hotplug_slot); |
247 | int retval; | 256 | int retval; |
248 | 257 | ||
249 | dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); | 258 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
259 | __func__, slot_name(slot)); | ||
250 | 260 | ||
251 | retval = slot->hpc_ops->get_latch_status(slot, value); | 261 | retval = slot->hpc_ops->get_latch_status(slot, value); |
252 | if (retval < 0) | 262 | if (retval < 0) |
@@ -260,7 +270,8 @@ static int get_adapter_status (struct hotplug_slot *hotplug_slot, u8 *value) | |||
260 | struct slot *slot = get_slot(hotplug_slot); | 270 | struct slot *slot = get_slot(hotplug_slot); |
261 | int retval; | 271 | int retval; |
262 | 272 | ||
263 | dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); | 273 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
274 | __func__, slot_name(slot)); | ||
264 | 275 | ||
265 | retval = slot->hpc_ops->get_adapter_status(slot, value); | 276 | retval = slot->hpc_ops->get_adapter_status(slot, value); |
266 | if (retval < 0) | 277 | if (retval < 0) |
@@ -275,7 +286,8 @@ static int get_max_bus_speed(struct hotplug_slot *hotplug_slot, | |||
275 | struct slot *slot = get_slot(hotplug_slot); | 286 | struct slot *slot = get_slot(hotplug_slot); |
276 | int retval; | 287 | int retval; |
277 | 288 | ||
278 | dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); | 289 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
290 | __func__, slot_name(slot)); | ||
279 | 291 | ||
280 | retval = slot->hpc_ops->get_max_bus_speed(slot, value); | 292 | retval = slot->hpc_ops->get_max_bus_speed(slot, value); |
281 | if (retval < 0) | 293 | if (retval < 0) |
@@ -289,7 +301,8 @@ static int get_cur_bus_speed (struct hotplug_slot *hotplug_slot, enum pci_bus_sp | |||
289 | struct slot *slot = get_slot(hotplug_slot); | 301 | struct slot *slot = get_slot(hotplug_slot); |
290 | int retval; | 302 | int retval; |
291 | 303 | ||
292 | dbg("%s - physical_slot = %s\n", __func__, slot_name(slot)); | 304 | ctrl_dbg(slot->ctrl, "%s: physical_slot = %s\n", |
305 | __func__, slot_name(slot)); | ||
293 | 306 | ||
294 | retval = slot->hpc_ops->get_cur_bus_speed(slot, value); | 307 | retval = slot->hpc_ops->get_cur_bus_speed(slot, value); |
295 | if (retval < 0) | 308 | if (retval < 0) |
@@ -320,15 +333,14 @@ static int shpc_probe(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
320 | 333 | ||
321 | ctrl = kzalloc(sizeof(*ctrl), GFP_KERNEL); | 334 | ctrl = kzalloc(sizeof(*ctrl), GFP_KERNEL); |
322 | if (!ctrl) { | 335 | if (!ctrl) { |
323 | err("%s : out of memory\n", __func__); | 336 | dev_err(&pdev->dev, "%s: Out of memory\n", __func__); |
324 | goto err_out_none; | 337 | goto err_out_none; |
325 | } | 338 | } |
326 | INIT_LIST_HEAD(&ctrl->slot_list); | 339 | INIT_LIST_HEAD(&ctrl->slot_list); |
327 | 340 | ||
328 | rc = shpc_init(ctrl, pdev); | 341 | rc = shpc_init(ctrl, pdev); |
329 | if (rc) { | 342 | if (rc) { |
330 | dbg("%s: controller initialization failed\n", | 343 | ctrl_dbg(ctrl, "Controller initialization failed\n"); |
331 | SHPC_MODULE_NAME); | ||
332 | goto err_out_free_ctrl; | 344 | goto err_out_free_ctrl; |
333 | } | 345 | } |
334 | 346 | ||
@@ -337,7 +349,7 @@ static int shpc_probe(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
337 | /* Setup the slot information structures */ | 349 | /* Setup the slot information structures */ |
338 | rc = init_slots(ctrl); | 350 | rc = init_slots(ctrl); |
339 | if (rc) { | 351 | if (rc) { |
340 | err("%s: slot initialization failed\n", SHPC_MODULE_NAME); | 352 | ctrl_err(ctrl, "Slot initialization failed\n"); |
341 | goto err_out_release_ctlr; | 353 | goto err_out_release_ctlr; |
342 | } | 354 | } |
343 | 355 | ||
diff --git a/drivers/pci/hotplug/shpchp_ctrl.c b/drivers/pci/hotplug/shpchp_ctrl.c index 919b1ee44313..b8ab2796e66a 100644 --- a/drivers/pci/hotplug/shpchp_ctrl.c +++ b/drivers/pci/hotplug/shpchp_ctrl.c | |||
@@ -62,7 +62,7 @@ u8 shpchp_handle_attention_button(u8 hp_slot, struct controller *ctrl) | |||
62 | u32 event_type; | 62 | u32 event_type; |
63 | 63 | ||
64 | /* Attention Button Change */ | 64 | /* Attention Button Change */ |
65 | dbg("shpchp: Attention button interrupt received.\n"); | 65 | ctrl_dbg(ctrl, "Attention button interrupt received\n"); |
66 | 66 | ||
67 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); | 67 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); |
68 | p_slot->hpc_ops->get_adapter_status(p_slot, &(p_slot->presence_save)); | 68 | p_slot->hpc_ops->get_adapter_status(p_slot, &(p_slot->presence_save)); |
@@ -70,7 +70,7 @@ u8 shpchp_handle_attention_button(u8 hp_slot, struct controller *ctrl) | |||
70 | /* | 70 | /* |
71 | * Button pressed - See if need to TAKE ACTION!!! | 71 | * Button pressed - See if need to TAKE ACTION!!! |
72 | */ | 72 | */ |
73 | info("Button pressed on Slot(%s)\n", slot_name(p_slot)); | 73 | ctrl_info(ctrl, "Button pressed on Slot(%s)\n", slot_name(p_slot)); |
74 | event_type = INT_BUTTON_PRESS; | 74 | event_type = INT_BUTTON_PRESS; |
75 | 75 | ||
76 | queue_interrupt_event(p_slot, event_type); | 76 | queue_interrupt_event(p_slot, event_type); |
@@ -86,29 +86,29 @@ u8 shpchp_handle_switch_change(u8 hp_slot, struct controller *ctrl) | |||
86 | u32 event_type; | 86 | u32 event_type; |
87 | 87 | ||
88 | /* Switch Change */ | 88 | /* Switch Change */ |
89 | dbg("shpchp: Switch interrupt received.\n"); | 89 | ctrl_dbg(ctrl, "Switch interrupt received\n"); |
90 | 90 | ||
91 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); | 91 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); |
92 | p_slot->hpc_ops->get_adapter_status(p_slot, &(p_slot->presence_save)); | 92 | p_slot->hpc_ops->get_adapter_status(p_slot, &(p_slot->presence_save)); |
93 | p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); | 93 | p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); |
94 | dbg("%s: Card present %x Power status %x\n", __func__, | 94 | ctrl_dbg(ctrl, "Card present %x Power status %x\n", |
95 | p_slot->presence_save, p_slot->pwr_save); | 95 | p_slot->presence_save, p_slot->pwr_save); |
96 | 96 | ||
97 | if (getstatus) { | 97 | if (getstatus) { |
98 | /* | 98 | /* |
99 | * Switch opened | 99 | * Switch opened |
100 | */ | 100 | */ |
101 | info("Latch open on Slot(%s)\n", slot_name(p_slot)); | 101 | ctrl_info(ctrl, "Latch open on Slot(%s)\n", slot_name(p_slot)); |
102 | event_type = INT_SWITCH_OPEN; | 102 | event_type = INT_SWITCH_OPEN; |
103 | if (p_slot->pwr_save && p_slot->presence_save) { | 103 | if (p_slot->pwr_save && p_slot->presence_save) { |
104 | event_type = INT_POWER_FAULT; | 104 | event_type = INT_POWER_FAULT; |
105 | err("Surprise Removal of card\n"); | 105 | ctrl_err(ctrl, "Surprise Removal of card\n"); |
106 | } | 106 | } |
107 | } else { | 107 | } else { |
108 | /* | 108 | /* |
109 | * Switch closed | 109 | * Switch closed |
110 | */ | 110 | */ |
111 | info("Latch close on Slot(%s)\n", slot_name(p_slot)); | 111 | ctrl_info(ctrl, "Latch close on Slot(%s)\n", slot_name(p_slot)); |
112 | event_type = INT_SWITCH_CLOSE; | 112 | event_type = INT_SWITCH_CLOSE; |
113 | } | 113 | } |
114 | 114 | ||
@@ -123,7 +123,7 @@ u8 shpchp_handle_presence_change(u8 hp_slot, struct controller *ctrl) | |||
123 | u32 event_type; | 123 | u32 event_type; |
124 | 124 | ||
125 | /* Presence Change */ | 125 | /* Presence Change */ |
126 | dbg("shpchp: Presence/Notify input change.\n"); | 126 | ctrl_dbg(ctrl, "Presence/Notify input change\n"); |
127 | 127 | ||
128 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); | 128 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); |
129 | 129 | ||
@@ -135,13 +135,15 @@ u8 shpchp_handle_presence_change(u8 hp_slot, struct controller *ctrl) | |||
135 | /* | 135 | /* |
136 | * Card Present | 136 | * Card Present |
137 | */ | 137 | */ |
138 | info("Card present on Slot(%s)\n", slot_name(p_slot)); | 138 | ctrl_info(ctrl, "Card present on Slot(%s)\n", |
139 | slot_name(p_slot)); | ||
139 | event_type = INT_PRESENCE_ON; | 140 | event_type = INT_PRESENCE_ON; |
140 | } else { | 141 | } else { |
141 | /* | 142 | /* |
142 | * Not Present | 143 | * Not Present |
143 | */ | 144 | */ |
144 | info("Card not present on Slot(%s)\n", slot_name(p_slot)); | 145 | ctrl_info(ctrl, "Card not present on Slot(%s)\n", |
146 | slot_name(p_slot)); | ||
145 | event_type = INT_PRESENCE_OFF; | 147 | event_type = INT_PRESENCE_OFF; |
146 | } | 148 | } |
147 | 149 | ||
@@ -156,7 +158,7 @@ u8 shpchp_handle_power_fault(u8 hp_slot, struct controller *ctrl) | |||
156 | u32 event_type; | 158 | u32 event_type; |
157 | 159 | ||
158 | /* Power fault */ | 160 | /* Power fault */ |
159 | dbg("shpchp: Power fault interrupt received.\n"); | 161 | ctrl_dbg(ctrl, "Power fault interrupt received\n"); |
160 | 162 | ||
161 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); | 163 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); |
162 | 164 | ||
@@ -164,18 +166,19 @@ u8 shpchp_handle_power_fault(u8 hp_slot, struct controller *ctrl) | |||
164 | /* | 166 | /* |
165 | * Power fault Cleared | 167 | * Power fault Cleared |
166 | */ | 168 | */ |
167 | info("Power fault cleared on Slot(%s)\n", slot_name(p_slot)); | 169 | ctrl_info(ctrl, "Power fault cleared on Slot(%s)\n", |
170 | slot_name(p_slot)); | ||
168 | p_slot->status = 0x00; | 171 | p_slot->status = 0x00; |
169 | event_type = INT_POWER_FAULT_CLEAR; | 172 | event_type = INT_POWER_FAULT_CLEAR; |
170 | } else { | 173 | } else { |
171 | /* | 174 | /* |
172 | * Power fault | 175 | * Power fault |
173 | */ | 176 | */ |
174 | info("Power fault on Slot(%s)\n", slot_name(p_slot)); | 177 | ctrl_info(ctrl, "Power fault on Slot(%s)\n", slot_name(p_slot)); |
175 | event_type = INT_POWER_FAULT; | 178 | event_type = INT_POWER_FAULT; |
176 | /* set power fault status for this board */ | 179 | /* set power fault status for this board */ |
177 | p_slot->status = 0xFF; | 180 | p_slot->status = 0xFF; |
178 | info("power fault bit %x set\n", hp_slot); | 181 | ctrl_info(ctrl, "Power fault bit %x set\n", hp_slot); |
179 | } | 182 | } |
180 | 183 | ||
181 | queue_interrupt_event(p_slot, event_type); | 184 | queue_interrupt_event(p_slot, event_type); |
@@ -191,10 +194,10 @@ static int change_bus_speed(struct controller *ctrl, struct slot *p_slot, | |||
191 | { | 194 | { |
192 | int rc = 0; | 195 | int rc = 0; |
193 | 196 | ||
194 | dbg("%s: change to speed %d\n", __func__, speed); | 197 | ctrl_dbg(ctrl, "Change speed to %d\n", speed); |
195 | if ((rc = p_slot->hpc_ops->set_bus_speed_mode(p_slot, speed))) { | 198 | if ((rc = p_slot->hpc_ops->set_bus_speed_mode(p_slot, speed))) { |
196 | err("%s: Issue of set bus speed mode command failed\n", | 199 | ctrl_err(ctrl, "%s: Issue of set bus speed mode command " |
197 | __func__); | 200 | "failed\n", __func__); |
198 | return WRONG_BUS_FREQUENCY; | 201 | return WRONG_BUS_FREQUENCY; |
199 | } | 202 | } |
200 | return rc; | 203 | return rc; |
@@ -212,8 +215,8 @@ static int fix_bus_speed(struct controller *ctrl, struct slot *pslot, | |||
212 | */ | 215 | */ |
213 | if (flag) { | 216 | if (flag) { |
214 | if (asp < bsp) { | 217 | if (asp < bsp) { |
215 | err("%s: speed of bus %x and adapter %x mismatch\n", | 218 | ctrl_err(ctrl, "Speed of bus %x and adapter %x " |
216 | __func__, bsp, asp); | 219 | "mismatch\n", bsp, asp); |
217 | rc = WRONG_BUS_FREQUENCY; | 220 | rc = WRONG_BUS_FREQUENCY; |
218 | } | 221 | } |
219 | return rc; | 222 | return rc; |
@@ -243,17 +246,18 @@ static int board_added(struct slot *p_slot) | |||
243 | int rc = 0; | 246 | int rc = 0; |
244 | enum pci_bus_speed asp, bsp, msp; | 247 | enum pci_bus_speed asp, bsp, msp; |
245 | struct controller *ctrl = p_slot->ctrl; | 248 | struct controller *ctrl = p_slot->ctrl; |
249 | struct pci_bus *parent = ctrl->pci_dev->subordinate; | ||
246 | 250 | ||
247 | hp_slot = p_slot->device - ctrl->slot_device_offset; | 251 | hp_slot = p_slot->device - ctrl->slot_device_offset; |
248 | 252 | ||
249 | dbg("%s: p_slot->device, slot_offset, hp_slot = %d, %d ,%d\n", | 253 | ctrl_dbg(ctrl, |
250 | __func__, p_slot->device, | 254 | "%s: p_slot->device, slot_offset, hp_slot = %d, %d ,%d\n", |
251 | ctrl->slot_device_offset, hp_slot); | 255 | __func__, p_slot->device, ctrl->slot_device_offset, hp_slot); |
252 | 256 | ||
253 | /* Power on slot without connecting to bus */ | 257 | /* Power on slot without connecting to bus */ |
254 | rc = p_slot->hpc_ops->power_on_slot(p_slot); | 258 | rc = p_slot->hpc_ops->power_on_slot(p_slot); |
255 | if (rc) { | 259 | if (rc) { |
256 | err("%s: Failed to power on slot\n", __func__); | 260 | ctrl_err(ctrl, "Failed to power on slot\n"); |
257 | return -1; | 261 | return -1; |
258 | } | 262 | } |
259 | 263 | ||
@@ -262,33 +266,34 @@ static int board_added(struct slot *p_slot) | |||
262 | return WRONG_BUS_FREQUENCY; | 266 | return WRONG_BUS_FREQUENCY; |
263 | 267 | ||
264 | if ((rc = p_slot->hpc_ops->set_bus_speed_mode(p_slot, PCI_SPEED_33MHz))) { | 268 | if ((rc = p_slot->hpc_ops->set_bus_speed_mode(p_slot, PCI_SPEED_33MHz))) { |
265 | err("%s: Issue of set bus speed mode command failed\n", __func__); | 269 | ctrl_err(ctrl, "%s: Issue of set bus speed mode command" |
270 | " failed\n", __func__); | ||
266 | return WRONG_BUS_FREQUENCY; | 271 | return WRONG_BUS_FREQUENCY; |
267 | } | 272 | } |
268 | 273 | ||
269 | /* turn on board, blink green LED, turn off Amber LED */ | 274 | /* turn on board, blink green LED, turn off Amber LED */ |
270 | if ((rc = p_slot->hpc_ops->slot_enable(p_slot))) { | 275 | if ((rc = p_slot->hpc_ops->slot_enable(p_slot))) { |
271 | err("%s: Issue of Slot Enable command failed\n", __func__); | 276 | ctrl_err(ctrl, "Issue of Slot Enable command failed\n"); |
272 | return rc; | 277 | return rc; |
273 | } | 278 | } |
274 | } | 279 | } |
275 | 280 | ||
276 | rc = p_slot->hpc_ops->get_adapter_speed(p_slot, &asp); | 281 | rc = p_slot->hpc_ops->get_adapter_speed(p_slot, &asp); |
277 | if (rc) { | 282 | if (rc) { |
278 | err("%s: Can't get adapter speed or bus mode mismatch\n", | 283 | ctrl_err(ctrl, "Can't get adapter speed or " |
279 | __func__); | 284 | "bus mode mismatch\n"); |
280 | return WRONG_BUS_FREQUENCY; | 285 | return WRONG_BUS_FREQUENCY; |
281 | } | 286 | } |
282 | 287 | ||
283 | rc = p_slot->hpc_ops->get_cur_bus_speed(p_slot, &bsp); | 288 | rc = p_slot->hpc_ops->get_cur_bus_speed(p_slot, &bsp); |
284 | if (rc) { | 289 | if (rc) { |
285 | err("%s: Can't get bus operation speed\n", __func__); | 290 | ctrl_err(ctrl, "Can't get bus operation speed\n"); |
286 | return WRONG_BUS_FREQUENCY; | 291 | return WRONG_BUS_FREQUENCY; |
287 | } | 292 | } |
288 | 293 | ||
289 | rc = p_slot->hpc_ops->get_max_bus_speed(p_slot, &msp); | 294 | rc = p_slot->hpc_ops->get_max_bus_speed(p_slot, &msp); |
290 | if (rc) { | 295 | if (rc) { |
291 | err("%s: Can't get max bus operation speed\n", __func__); | 296 | ctrl_err(ctrl, "Can't get max bus operation speed\n"); |
292 | msp = bsp; | 297 | msp = bsp; |
293 | } | 298 | } |
294 | 299 | ||
@@ -296,9 +301,9 @@ static int board_added(struct slot *p_slot) | |||
296 | if (!list_empty(&ctrl->pci_dev->subordinate->devices)) | 301 | if (!list_empty(&ctrl->pci_dev->subordinate->devices)) |
297 | slots_not_empty = 1; | 302 | slots_not_empty = 1; |
298 | 303 | ||
299 | dbg("%s: slots_not_empty %d, adapter_speed %d, bus_speed %d, " | 304 | ctrl_dbg(ctrl, "%s: slots_not_empty %d, adapter_speed %d, bus_speed %d," |
300 | "max_bus_speed %d\n", __func__, slots_not_empty, asp, | 305 | " max_bus_speed %d\n", __func__, slots_not_empty, asp, |
301 | bsp, msp); | 306 | bsp, msp); |
302 | 307 | ||
303 | rc = fix_bus_speed(ctrl, p_slot, slots_not_empty, asp, bsp, msp); | 308 | rc = fix_bus_speed(ctrl, p_slot, slots_not_empty, asp, bsp, msp); |
304 | if (rc) | 309 | if (rc) |
@@ -306,26 +311,26 @@ static int board_added(struct slot *p_slot) | |||
306 | 311 | ||
307 | /* turn on board, blink green LED, turn off Amber LED */ | 312 | /* turn on board, blink green LED, turn off Amber LED */ |
308 | if ((rc = p_slot->hpc_ops->slot_enable(p_slot))) { | 313 | if ((rc = p_slot->hpc_ops->slot_enable(p_slot))) { |
309 | err("%s: Issue of Slot Enable command failed\n", __func__); | 314 | ctrl_err(ctrl, "Issue of Slot Enable command failed\n"); |
310 | return rc; | 315 | return rc; |
311 | } | 316 | } |
312 | 317 | ||
313 | /* Wait for ~1 second */ | 318 | /* Wait for ~1 second */ |
314 | msleep(1000); | 319 | msleep(1000); |
315 | 320 | ||
316 | dbg("%s: slot status = %x\n", __func__, p_slot->status); | 321 | ctrl_dbg(ctrl, "%s: slot status = %x\n", __func__, p_slot->status); |
317 | /* Check for a power fault */ | 322 | /* Check for a power fault */ |
318 | if (p_slot->status == 0xFF) { | 323 | if (p_slot->status == 0xFF) { |
319 | /* power fault occurred, but it was benign */ | 324 | /* power fault occurred, but it was benign */ |
320 | dbg("%s: power fault\n", __func__); | 325 | ctrl_dbg(ctrl, "%s: Power fault\n", __func__); |
321 | rc = POWER_FAILURE; | 326 | rc = POWER_FAILURE; |
322 | p_slot->status = 0; | 327 | p_slot->status = 0; |
323 | goto err_exit; | 328 | goto err_exit; |
324 | } | 329 | } |
325 | 330 | ||
326 | if (shpchp_configure_device(p_slot)) { | 331 | if (shpchp_configure_device(p_slot)) { |
327 | err("Cannot add device at 0x%x:0x%x\n", p_slot->bus, | 332 | ctrl_err(ctrl, "Cannot add device at %04x:%02x:%02x\n", |
328 | p_slot->device); | 333 | pci_domain_nr(parent), p_slot->bus, p_slot->device); |
329 | goto err_exit; | 334 | goto err_exit; |
330 | } | 335 | } |
331 | 336 | ||
@@ -341,7 +346,8 @@ err_exit: | |||
341 | /* turn off slot, turn on Amber LED, turn off Green LED */ | 346 | /* turn off slot, turn on Amber LED, turn off Green LED */ |
342 | rc = p_slot->hpc_ops->slot_disable(p_slot); | 347 | rc = p_slot->hpc_ops->slot_disable(p_slot); |
343 | if (rc) { | 348 | if (rc) { |
344 | err("%s: Issue of Slot Disable command failed\n", __func__); | 349 | ctrl_err(ctrl, "%s: Issue of Slot Disable command failed\n", |
350 | __func__); | ||
345 | return rc; | 351 | return rc; |
346 | } | 352 | } |
347 | 353 | ||
@@ -365,7 +371,7 @@ static int remove_board(struct slot *p_slot) | |||
365 | hp_slot = p_slot->device - ctrl->slot_device_offset; | 371 | hp_slot = p_slot->device - ctrl->slot_device_offset; |
366 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); | 372 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); |
367 | 373 | ||
368 | dbg("In %s, hp_slot = %d\n", __func__, hp_slot); | 374 | ctrl_dbg(ctrl, "%s: hp_slot = %d\n", __func__, hp_slot); |
369 | 375 | ||
370 | /* Change status to shutdown */ | 376 | /* Change status to shutdown */ |
371 | if (p_slot->is_a_board) | 377 | if (p_slot->is_a_board) |
@@ -374,13 +380,14 @@ static int remove_board(struct slot *p_slot) | |||
374 | /* turn off slot, turn on Amber LED, turn off Green LED */ | 380 | /* turn off slot, turn on Amber LED, turn off Green LED */ |
375 | rc = p_slot->hpc_ops->slot_disable(p_slot); | 381 | rc = p_slot->hpc_ops->slot_disable(p_slot); |
376 | if (rc) { | 382 | if (rc) { |
377 | err("%s: Issue of Slot Disable command failed\n", __func__); | 383 | ctrl_err(ctrl, "%s: Issue of Slot Disable command failed\n", |
384 | __func__); | ||
378 | return rc; | 385 | return rc; |
379 | } | 386 | } |
380 | 387 | ||
381 | rc = p_slot->hpc_ops->set_attention_status(p_slot, 0); | 388 | rc = p_slot->hpc_ops->set_attention_status(p_slot, 0); |
382 | if (rc) { | 389 | if (rc) { |
383 | err("%s: Issue of Set Attention command failed\n", __func__); | 390 | ctrl_err(ctrl, "Issue of Set Attention command failed\n"); |
384 | return rc; | 391 | return rc; |
385 | } | 392 | } |
386 | 393 | ||
@@ -439,7 +446,8 @@ void shpchp_queue_pushbutton_work(struct work_struct *work) | |||
439 | 446 | ||
440 | info = kmalloc(sizeof(*info), GFP_KERNEL); | 447 | info = kmalloc(sizeof(*info), GFP_KERNEL); |
441 | if (!info) { | 448 | if (!info) { |
442 | err("%s: Cannot allocate memory\n", __func__); | 449 | ctrl_err(p_slot->ctrl, "%s: Cannot allocate memory\n", |
450 | __func__); | ||
443 | return; | 451 | return; |
444 | } | 452 | } |
445 | info->p_slot = p_slot; | 453 | info->p_slot = p_slot; |
@@ -486,18 +494,19 @@ static int update_slot_info (struct slot *slot) | |||
486 | static void handle_button_press_event(struct slot *p_slot) | 494 | static void handle_button_press_event(struct slot *p_slot) |
487 | { | 495 | { |
488 | u8 getstatus; | 496 | u8 getstatus; |
497 | struct controller *ctrl = p_slot->ctrl; | ||
489 | 498 | ||
490 | switch (p_slot->state) { | 499 | switch (p_slot->state) { |
491 | case STATIC_STATE: | 500 | case STATIC_STATE: |
492 | p_slot->hpc_ops->get_power_status(p_slot, &getstatus); | 501 | p_slot->hpc_ops->get_power_status(p_slot, &getstatus); |
493 | if (getstatus) { | 502 | if (getstatus) { |
494 | p_slot->state = BLINKINGOFF_STATE; | 503 | p_slot->state = BLINKINGOFF_STATE; |
495 | info("PCI slot #%s - powering off due to button " | 504 | ctrl_info(ctrl, "PCI slot #%s - powering off due to " |
496 | "press.\n", slot_name(p_slot)); | 505 | "button press.\n", slot_name(p_slot)); |
497 | } else { | 506 | } else { |
498 | p_slot->state = BLINKINGON_STATE; | 507 | p_slot->state = BLINKINGON_STATE; |
499 | info("PCI slot #%s - powering on due to button " | 508 | ctrl_info(ctrl, "PCI slot #%s - powering on due to " |
500 | "press.\n", slot_name(p_slot)); | 509 | "button press.\n", slot_name(p_slot)); |
501 | } | 510 | } |
502 | /* blink green LED and turn off amber */ | 511 | /* blink green LED and turn off amber */ |
503 | p_slot->hpc_ops->green_led_blink(p_slot); | 512 | p_slot->hpc_ops->green_led_blink(p_slot); |
@@ -512,16 +521,16 @@ static void handle_button_press_event(struct slot *p_slot) | |||
512 | * press the attention again before the 5 sec. limit | 521 | * press the attention again before the 5 sec. limit |
513 | * expires to cancel hot-add or hot-remove | 522 | * expires to cancel hot-add or hot-remove |
514 | */ | 523 | */ |
515 | info("Button cancel on Slot(%s)\n", slot_name(p_slot)); | 524 | ctrl_info(ctrl, "Button cancel on Slot(%s)\n", |
516 | dbg("%s: button cancel\n", __func__); | 525 | slot_name(p_slot)); |
517 | cancel_delayed_work(&p_slot->work); | 526 | cancel_delayed_work(&p_slot->work); |
518 | if (p_slot->state == BLINKINGOFF_STATE) | 527 | if (p_slot->state == BLINKINGOFF_STATE) |
519 | p_slot->hpc_ops->green_led_on(p_slot); | 528 | p_slot->hpc_ops->green_led_on(p_slot); |
520 | else | 529 | else |
521 | p_slot->hpc_ops->green_led_off(p_slot); | 530 | p_slot->hpc_ops->green_led_off(p_slot); |
522 | p_slot->hpc_ops->set_attention_status(p_slot, 0); | 531 | p_slot->hpc_ops->set_attention_status(p_slot, 0); |
523 | info("PCI slot #%s - action canceled due to button press\n", | 532 | ctrl_info(ctrl, "PCI slot #%s - action canceled due to " |
524 | slot_name(p_slot)); | 533 | "button press\n", slot_name(p_slot)); |
525 | p_slot->state = STATIC_STATE; | 534 | p_slot->state = STATIC_STATE; |
526 | break; | 535 | break; |
527 | case POWEROFF_STATE: | 536 | case POWEROFF_STATE: |
@@ -531,11 +540,12 @@ static void handle_button_press_event(struct slot *p_slot) | |||
531 | * this means that the previous attention button action | 540 | * this means that the previous attention button action |
532 | * to hot-add or hot-remove is undergoing | 541 | * to hot-add or hot-remove is undergoing |
533 | */ | 542 | */ |
534 | info("Button ignore on Slot(%s)\n", slot_name(p_slot)); | 543 | ctrl_info(ctrl, "Button ignore on Slot(%s)\n", |
544 | slot_name(p_slot)); | ||
535 | update_slot_info(p_slot); | 545 | update_slot_info(p_slot); |
536 | break; | 546 | break; |
537 | default: | 547 | default: |
538 | warn("Not a valid state\n"); | 548 | ctrl_warn(ctrl, "Not a valid state\n"); |
539 | break; | 549 | break; |
540 | } | 550 | } |
541 | } | 551 | } |
@@ -551,7 +561,7 @@ static void interrupt_event_handler(struct work_struct *work) | |||
551 | handle_button_press_event(p_slot); | 561 | handle_button_press_event(p_slot); |
552 | break; | 562 | break; |
553 | case INT_POWER_FAULT: | 563 | case INT_POWER_FAULT: |
554 | dbg("%s: power fault\n", __func__); | 564 | ctrl_dbg(p_slot->ctrl, "%s: Power fault\n", __func__); |
555 | p_slot->hpc_ops->set_attention_status(p_slot, 1); | 565 | p_slot->hpc_ops->set_attention_status(p_slot, 1); |
556 | p_slot->hpc_ops->green_led_off(p_slot); | 566 | p_slot->hpc_ops->green_led_off(p_slot); |
557 | break; | 567 | break; |
@@ -569,22 +579,24 @@ static int shpchp_enable_slot (struct slot *p_slot) | |||
569 | { | 579 | { |
570 | u8 getstatus = 0; | 580 | u8 getstatus = 0; |
571 | int rc, retval = -ENODEV; | 581 | int rc, retval = -ENODEV; |
582 | struct controller *ctrl = p_slot->ctrl; | ||
572 | 583 | ||
573 | /* Check to see if (latch closed, card present, power off) */ | 584 | /* Check to see if (latch closed, card present, power off) */ |
574 | mutex_lock(&p_slot->ctrl->crit_sect); | 585 | mutex_lock(&p_slot->ctrl->crit_sect); |
575 | rc = p_slot->hpc_ops->get_adapter_status(p_slot, &getstatus); | 586 | rc = p_slot->hpc_ops->get_adapter_status(p_slot, &getstatus); |
576 | if (rc || !getstatus) { | 587 | if (rc || !getstatus) { |
577 | info("No adapter on slot(%s)\n", slot_name(p_slot)); | 588 | ctrl_info(ctrl, "No adapter on slot(%s)\n", slot_name(p_slot)); |
578 | goto out; | 589 | goto out; |
579 | } | 590 | } |
580 | rc = p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); | 591 | rc = p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); |
581 | if (rc || getstatus) { | 592 | if (rc || getstatus) { |
582 | info("Latch open on slot(%s)\n", slot_name(p_slot)); | 593 | ctrl_info(ctrl, "Latch open on slot(%s)\n", slot_name(p_slot)); |
583 | goto out; | 594 | goto out; |
584 | } | 595 | } |
585 | rc = p_slot->hpc_ops->get_power_status(p_slot, &getstatus); | 596 | rc = p_slot->hpc_ops->get_power_status(p_slot, &getstatus); |
586 | if (rc || getstatus) { | 597 | if (rc || getstatus) { |
587 | info("Already enabled on slot(%s)\n", slot_name(p_slot)); | 598 | ctrl_info(ctrl, "Already enabled on slot(%s)\n", |
599 | slot_name(p_slot)); | ||
588 | goto out; | 600 | goto out; |
589 | } | 601 | } |
590 | 602 | ||
@@ -593,7 +605,7 @@ static int shpchp_enable_slot (struct slot *p_slot) | |||
593 | /* We have to save the presence info for these slots */ | 605 | /* We have to save the presence info for these slots */ |
594 | p_slot->hpc_ops->get_adapter_status(p_slot, &(p_slot->presence_save)); | 606 | p_slot->hpc_ops->get_adapter_status(p_slot, &(p_slot->presence_save)); |
595 | p_slot->hpc_ops->get_power_status(p_slot, &(p_slot->pwr_save)); | 607 | p_slot->hpc_ops->get_power_status(p_slot, &(p_slot->pwr_save)); |
596 | dbg("%s: p_slot->pwr_save %x\n", __func__, p_slot->pwr_save); | 608 | ctrl_dbg(ctrl, "%s: p_slot->pwr_save %x\n", __func__, p_slot->pwr_save); |
597 | p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); | 609 | p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); |
598 | 610 | ||
599 | if(((p_slot->ctrl->pci_dev->vendor == PCI_VENDOR_ID_AMD) || | 611 | if(((p_slot->ctrl->pci_dev->vendor == PCI_VENDOR_ID_AMD) || |
@@ -624,6 +636,7 @@ static int shpchp_disable_slot (struct slot *p_slot) | |||
624 | { | 636 | { |
625 | u8 getstatus = 0; | 637 | u8 getstatus = 0; |
626 | int rc, retval = -ENODEV; | 638 | int rc, retval = -ENODEV; |
639 | struct controller *ctrl = p_slot->ctrl; | ||
627 | 640 | ||
628 | if (!p_slot->ctrl) | 641 | if (!p_slot->ctrl) |
629 | return -ENODEV; | 642 | return -ENODEV; |
@@ -633,17 +646,18 @@ static int shpchp_disable_slot (struct slot *p_slot) | |||
633 | 646 | ||
634 | rc = p_slot->hpc_ops->get_adapter_status(p_slot, &getstatus); | 647 | rc = p_slot->hpc_ops->get_adapter_status(p_slot, &getstatus); |
635 | if (rc || !getstatus) { | 648 | if (rc || !getstatus) { |
636 | info("No adapter on slot(%s)\n", slot_name(p_slot)); | 649 | ctrl_info(ctrl, "No adapter on slot(%s)\n", slot_name(p_slot)); |
637 | goto out; | 650 | goto out; |
638 | } | 651 | } |
639 | rc = p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); | 652 | rc = p_slot->hpc_ops->get_latch_status(p_slot, &getstatus); |
640 | if (rc || getstatus) { | 653 | if (rc || getstatus) { |
641 | info("Latch open on slot(%s)\n", slot_name(p_slot)); | 654 | ctrl_info(ctrl, "Latch open on slot(%s)\n", slot_name(p_slot)); |
642 | goto out; | 655 | goto out; |
643 | } | 656 | } |
644 | rc = p_slot->hpc_ops->get_power_status(p_slot, &getstatus); | 657 | rc = p_slot->hpc_ops->get_power_status(p_slot, &getstatus); |
645 | if (rc || !getstatus) { | 658 | if (rc || !getstatus) { |
646 | info("Already disabled slot(%s)\n", slot_name(p_slot)); | 659 | ctrl_info(ctrl, "Already disabled on slot(%s)\n", |
660 | slot_name(p_slot)); | ||
647 | goto out; | 661 | goto out; |
648 | } | 662 | } |
649 | 663 | ||
@@ -657,6 +671,7 @@ static int shpchp_disable_slot (struct slot *p_slot) | |||
657 | int shpchp_sysfs_enable_slot(struct slot *p_slot) | 671 | int shpchp_sysfs_enable_slot(struct slot *p_slot) |
658 | { | 672 | { |
659 | int retval = -ENODEV; | 673 | int retval = -ENODEV; |
674 | struct controller *ctrl = p_slot->ctrl; | ||
660 | 675 | ||
661 | mutex_lock(&p_slot->lock); | 676 | mutex_lock(&p_slot->lock); |
662 | switch (p_slot->state) { | 677 | switch (p_slot->state) { |
@@ -670,15 +685,17 @@ int shpchp_sysfs_enable_slot(struct slot *p_slot) | |||
670 | p_slot->state = STATIC_STATE; | 685 | p_slot->state = STATIC_STATE; |
671 | break; | 686 | break; |
672 | case POWERON_STATE: | 687 | case POWERON_STATE: |
673 | info("Slot %s is already in powering on state\n", | 688 | ctrl_info(ctrl, "Slot %s is already in powering on state\n", |
674 | slot_name(p_slot)); | 689 | slot_name(p_slot)); |
675 | break; | 690 | break; |
676 | case BLINKINGOFF_STATE: | 691 | case BLINKINGOFF_STATE: |
677 | case POWEROFF_STATE: | 692 | case POWEROFF_STATE: |
678 | info("Already enabled on slot %s\n", slot_name(p_slot)); | 693 | ctrl_info(ctrl, "Already enabled on slot %s\n", |
694 | slot_name(p_slot)); | ||
679 | break; | 695 | break; |
680 | default: | 696 | default: |
681 | err("Not a valid state on slot %s\n", slot_name(p_slot)); | 697 | ctrl_err(ctrl, "Not a valid state on slot %s\n", |
698 | slot_name(p_slot)); | ||
682 | break; | 699 | break; |
683 | } | 700 | } |
684 | mutex_unlock(&p_slot->lock); | 701 | mutex_unlock(&p_slot->lock); |
@@ -689,6 +706,7 @@ int shpchp_sysfs_enable_slot(struct slot *p_slot) | |||
689 | int shpchp_sysfs_disable_slot(struct slot *p_slot) | 706 | int shpchp_sysfs_disable_slot(struct slot *p_slot) |
690 | { | 707 | { |
691 | int retval = -ENODEV; | 708 | int retval = -ENODEV; |
709 | struct controller *ctrl = p_slot->ctrl; | ||
692 | 710 | ||
693 | mutex_lock(&p_slot->lock); | 711 | mutex_lock(&p_slot->lock); |
694 | switch (p_slot->state) { | 712 | switch (p_slot->state) { |
@@ -702,15 +720,17 @@ int shpchp_sysfs_disable_slot(struct slot *p_slot) | |||
702 | p_slot->state = STATIC_STATE; | 720 | p_slot->state = STATIC_STATE; |
703 | break; | 721 | break; |
704 | case POWEROFF_STATE: | 722 | case POWEROFF_STATE: |
705 | info("Slot %s is already in powering off state\n", | 723 | ctrl_info(ctrl, "Slot %s is already in powering off state\n", |
706 | slot_name(p_slot)); | 724 | slot_name(p_slot)); |
707 | break; | 725 | break; |
708 | case BLINKINGON_STATE: | 726 | case BLINKINGON_STATE: |
709 | case POWERON_STATE: | 727 | case POWERON_STATE: |
710 | info("Already disabled on slot %s\n", slot_name(p_slot)); | 728 | ctrl_info(ctrl, "Already disabled on slot %s\n", |
729 | slot_name(p_slot)); | ||
711 | break; | 730 | break; |
712 | default: | 731 | default: |
713 | err("Not a valid state on slot %s\n", slot_name(p_slot)); | 732 | ctrl_err(ctrl, "Not a valid state on slot %s\n", |
733 | slot_name(p_slot)); | ||
714 | break; | 734 | break; |
715 | } | 735 | } |
716 | mutex_unlock(&p_slot->lock); | 736 | mutex_unlock(&p_slot->lock); |
diff --git a/drivers/pci/hotplug/shpchp_hpc.c b/drivers/pci/hotplug/shpchp_hpc.c index 7a0bff364cd4..86dc39847769 100644 --- a/drivers/pci/hotplug/shpchp_hpc.c +++ b/drivers/pci/hotplug/shpchp_hpc.c | |||
@@ -300,10 +300,10 @@ static inline int shpc_wait_cmd(struct controller *ctrl) | |||
300 | !is_ctrl_busy(ctrl), timeout); | 300 | !is_ctrl_busy(ctrl), timeout); |
301 | if (!rc && is_ctrl_busy(ctrl)) { | 301 | if (!rc && is_ctrl_busy(ctrl)) { |
302 | retval = -EIO; | 302 | retval = -EIO; |
303 | err("Command not completed in 1000 msec\n"); | 303 | ctrl_err(ctrl, "Command not completed in 1000 msec\n"); |
304 | } else if (rc < 0) { | 304 | } else if (rc < 0) { |
305 | retval = -EINTR; | 305 | retval = -EINTR; |
306 | info("Command was interrupted by a signal\n"); | 306 | ctrl_info(ctrl, "Command was interrupted by a signal\n"); |
307 | } | 307 | } |
308 | 308 | ||
309 | return retval; | 309 | return retval; |
@@ -320,15 +320,14 @@ static int shpc_write_cmd(struct slot *slot, u8 t_slot, u8 cmd) | |||
320 | 320 | ||
321 | if (!shpc_poll_ctrl_busy(ctrl)) { | 321 | if (!shpc_poll_ctrl_busy(ctrl)) { |
322 | /* After 1 sec and and the controller is still busy */ | 322 | /* After 1 sec and and the controller is still busy */ |
323 | err("%s : Controller is still busy after 1 sec.\n", | 323 | ctrl_err(ctrl, "Controller is still busy after 1 sec\n"); |
324 | __func__); | ||
325 | retval = -EBUSY; | 324 | retval = -EBUSY; |
326 | goto out; | 325 | goto out; |
327 | } | 326 | } |
328 | 327 | ||
329 | ++t_slot; | 328 | ++t_slot; |
330 | temp_word = (t_slot << 8) | (cmd & 0xFF); | 329 | temp_word = (t_slot << 8) | (cmd & 0xFF); |
331 | dbg("%s: t_slot %x cmd %x\n", __func__, t_slot, cmd); | 330 | ctrl_dbg(ctrl, "%s: t_slot %x cmd %x\n", __func__, t_slot, cmd); |
332 | 331 | ||
333 | /* To make sure the Controller Busy bit is 0 before we send out the | 332 | /* To make sure the Controller Busy bit is 0 before we send out the |
334 | * command. | 333 | * command. |
@@ -344,8 +343,9 @@ static int shpc_write_cmd(struct slot *slot, u8 t_slot, u8 cmd) | |||
344 | 343 | ||
345 | cmd_status = hpc_check_cmd_status(slot->ctrl); | 344 | cmd_status = hpc_check_cmd_status(slot->ctrl); |
346 | if (cmd_status) { | 345 | if (cmd_status) { |
347 | err("%s: Failed to issued command 0x%x (error code = %d)\n", | 346 | ctrl_err(ctrl, |
348 | __func__, cmd, cmd_status); | 347 | "Failed to issued command 0x%x (error code = %d)\n", |
348 | cmd, cmd_status); | ||
349 | retval = -EIO; | 349 | retval = -EIO; |
350 | } | 350 | } |
351 | out: | 351 | out: |
@@ -364,15 +364,15 @@ static int hpc_check_cmd_status(struct controller *ctrl) | |||
364 | break; | 364 | break; |
365 | case 1: | 365 | case 1: |
366 | retval = SWITCH_OPEN; | 366 | retval = SWITCH_OPEN; |
367 | err("%s: Switch opened!\n", __func__); | 367 | ctrl_err(ctrl, "Switch opened!\n"); |
368 | break; | 368 | break; |
369 | case 2: | 369 | case 2: |
370 | retval = INVALID_CMD; | 370 | retval = INVALID_CMD; |
371 | err("%s: Invalid HPC command!\n", __func__); | 371 | ctrl_err(ctrl, "Invalid HPC command!\n"); |
372 | break; | 372 | break; |
373 | case 4: | 373 | case 4: |
374 | retval = INVALID_SPEED_MODE; | 374 | retval = INVALID_SPEED_MODE; |
375 | err("%s: Invalid bus speed/mode!\n", __func__); | 375 | ctrl_err(ctrl, "Invalid bus speed/mode!\n"); |
376 | break; | 376 | break; |
377 | default: | 377 | default: |
378 | retval = cmd_status; | 378 | retval = cmd_status; |
@@ -483,8 +483,8 @@ static int hpc_get_adapter_speed(struct slot *slot, enum pci_bus_speed *value) | |||
483 | return -ENODEV; | 483 | return -ENODEV; |
484 | } | 484 | } |
485 | 485 | ||
486 | dbg("%s: slot_reg = %x, pcix_cap = %x, m66_cap = %x\n", | 486 | ctrl_dbg(ctrl, "%s: slot_reg = %x, pcix_cap = %x, m66_cap = %x\n", |
487 | __func__, slot_reg, pcix_cap, m66_cap); | 487 | __func__, slot_reg, pcix_cap, m66_cap); |
488 | 488 | ||
489 | switch (pcix_cap) { | 489 | switch (pcix_cap) { |
490 | case 0x0: | 490 | case 0x0: |
@@ -509,7 +509,7 @@ static int hpc_get_adapter_speed(struct slot *slot, enum pci_bus_speed *value) | |||
509 | break; | 509 | break; |
510 | } | 510 | } |
511 | 511 | ||
512 | dbg("Adapter speed = %d\n", *value); | 512 | ctrl_dbg(ctrl, "Adapter speed = %d\n", *value); |
513 | return retval; | 513 | return retval; |
514 | } | 514 | } |
515 | 515 | ||
@@ -526,7 +526,7 @@ static int hpc_get_mode1_ECC_cap(struct slot *slot, u8 *mode) | |||
526 | retval = -1; | 526 | retval = -1; |
527 | } | 527 | } |
528 | 528 | ||
529 | dbg("Mode 1 ECC cap = %d\n", *mode); | 529 | ctrl_dbg(ctrl, "Mode 1 ECC cap = %d\n", *mode); |
530 | return retval; | 530 | return retval; |
531 | } | 531 | } |
532 | 532 | ||
@@ -629,7 +629,7 @@ static int hpc_power_on_slot(struct slot * slot) | |||
629 | 629 | ||
630 | retval = shpc_write_cmd(slot, slot->hp_slot, SET_SLOT_PWR); | 630 | retval = shpc_write_cmd(slot, slot->hp_slot, SET_SLOT_PWR); |
631 | if (retval) | 631 | if (retval) |
632 | err("%s: Write command failed!\n", __func__); | 632 | ctrl_err(slot->ctrl, "%s: Write command failed!\n", __func__); |
633 | 633 | ||
634 | return retval; | 634 | return retval; |
635 | } | 635 | } |
@@ -642,7 +642,7 @@ static int hpc_slot_enable(struct slot * slot) | |||
642 | retval = shpc_write_cmd(slot, slot->hp_slot, | 642 | retval = shpc_write_cmd(slot, slot->hp_slot, |
643 | SET_SLOT_ENABLE | SET_PWR_BLINK | SET_ATTN_OFF); | 643 | SET_SLOT_ENABLE | SET_PWR_BLINK | SET_ATTN_OFF); |
644 | if (retval) | 644 | if (retval) |
645 | err("%s: Write command failed!\n", __func__); | 645 | ctrl_err(slot->ctrl, "%s: Write command failed!\n", __func__); |
646 | 646 | ||
647 | return retval; | 647 | return retval; |
648 | } | 648 | } |
@@ -655,7 +655,7 @@ static int hpc_slot_disable(struct slot * slot) | |||
655 | retval = shpc_write_cmd(slot, slot->hp_slot, | 655 | retval = shpc_write_cmd(slot, slot->hp_slot, |
656 | SET_SLOT_DISABLE | SET_PWR_OFF | SET_ATTN_ON); | 656 | SET_SLOT_DISABLE | SET_PWR_OFF | SET_ATTN_ON); |
657 | if (retval) | 657 | if (retval) |
658 | err("%s: Write command failed!\n", __func__); | 658 | ctrl_err(slot->ctrl, "%s: Write command failed!\n", __func__); |
659 | 659 | ||
660 | return retval; | 660 | return retval; |
661 | } | 661 | } |
@@ -719,7 +719,7 @@ static int hpc_set_bus_speed_mode(struct slot * slot, enum pci_bus_speed value) | |||
719 | 719 | ||
720 | retval = shpc_write_cmd(slot, 0, cmd); | 720 | retval = shpc_write_cmd(slot, 0, cmd); |
721 | if (retval) | 721 | if (retval) |
722 | err("%s: Write command failed!\n", __func__); | 722 | ctrl_err(ctrl, "%s: Write command failed!\n", __func__); |
723 | 723 | ||
724 | return retval; | 724 | return retval; |
725 | } | 725 | } |
@@ -735,7 +735,7 @@ static irqreturn_t shpc_isr(int irq, void *dev_id) | |||
735 | if (!intr_loc) | 735 | if (!intr_loc) |
736 | return IRQ_NONE; | 736 | return IRQ_NONE; |
737 | 737 | ||
738 | dbg("%s: intr_loc = %x\n",__func__, intr_loc); | 738 | ctrl_dbg(ctrl, "%s: intr_loc = %x\n", __func__, intr_loc); |
739 | 739 | ||
740 | if(!shpchp_poll_mode) { | 740 | if(!shpchp_poll_mode) { |
741 | /* | 741 | /* |
@@ -748,7 +748,7 @@ static irqreturn_t shpc_isr(int irq, void *dev_id) | |||
748 | shpc_writel(ctrl, SERR_INTR_ENABLE, serr_int); | 748 | shpc_writel(ctrl, SERR_INTR_ENABLE, serr_int); |
749 | 749 | ||
750 | intr_loc2 = shpc_readl(ctrl, INTR_LOC); | 750 | intr_loc2 = shpc_readl(ctrl, INTR_LOC); |
751 | dbg("%s: intr_loc2 = %x\n",__func__, intr_loc2); | 751 | ctrl_dbg(ctrl, "%s: intr_loc2 = %x\n", __func__, intr_loc2); |
752 | } | 752 | } |
753 | 753 | ||
754 | if (intr_loc & CMD_INTR_PENDING) { | 754 | if (intr_loc & CMD_INTR_PENDING) { |
@@ -773,8 +773,8 @@ static irqreturn_t shpc_isr(int irq, void *dev_id) | |||
773 | continue; | 773 | continue; |
774 | 774 | ||
775 | slot_reg = shpc_readl(ctrl, SLOT_REG(hp_slot)); | 775 | slot_reg = shpc_readl(ctrl, SLOT_REG(hp_slot)); |
776 | dbg("%s: Slot %x with intr, slot register = %x\n", | 776 | ctrl_dbg(ctrl, "Slot %x with intr, slot register = %x\n", |
777 | __func__, hp_slot, slot_reg); | 777 | hp_slot, slot_reg); |
778 | 778 | ||
779 | if (slot_reg & MRL_CHANGE_DETECTED) | 779 | if (slot_reg & MRL_CHANGE_DETECTED) |
780 | shpchp_handle_switch_change(hp_slot, ctrl); | 780 | shpchp_handle_switch_change(hp_slot, ctrl); |
@@ -843,7 +843,7 @@ static int hpc_get_max_bus_speed (struct slot *slot, enum pci_bus_speed *value) | |||
843 | } | 843 | } |
844 | 844 | ||
845 | *value = bus_speed; | 845 | *value = bus_speed; |
846 | dbg("Max bus speed = %d\n", bus_speed); | 846 | ctrl_dbg(ctrl, "Max bus speed = %d\n", bus_speed); |
847 | 847 | ||
848 | return retval; | 848 | return retval; |
849 | } | 849 | } |
@@ -911,7 +911,7 @@ static int hpc_get_cur_bus_speed (struct slot *slot, enum pci_bus_speed *value) | |||
911 | break; | 911 | break; |
912 | } | 912 | } |
913 | 913 | ||
914 | dbg("Current bus speed = %d\n", bus_speed); | 914 | ctrl_dbg(ctrl, "Current bus speed = %d\n", bus_speed); |
915 | return retval; | 915 | return retval; |
916 | } | 916 | } |
917 | 917 | ||
@@ -949,6 +949,7 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) | |||
949 | u8 i; | 949 | u8 i; |
950 | 950 | ||
951 | ctrl->pci_dev = pdev; /* pci_dev of the P2P bridge */ | 951 | ctrl->pci_dev = pdev; /* pci_dev of the P2P bridge */ |
952 | ctrl_dbg(ctrl, "Hotplug Controller:\n"); | ||
952 | 953 | ||
953 | if ((pdev->vendor == PCI_VENDOR_ID_AMD) || (pdev->device == | 954 | if ((pdev->vendor == PCI_VENDOR_ID_AMD) || (pdev->device == |
954 | PCI_DEVICE_ID_AMD_GOLAM_7450)) { | 955 | PCI_DEVICE_ID_AMD_GOLAM_7450)) { |
@@ -958,34 +959,33 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) | |||
958 | } else { | 959 | } else { |
959 | ctrl->cap_offset = pci_find_capability(pdev, PCI_CAP_ID_SHPC); | 960 | ctrl->cap_offset = pci_find_capability(pdev, PCI_CAP_ID_SHPC); |
960 | if (!ctrl->cap_offset) { | 961 | if (!ctrl->cap_offset) { |
961 | err("%s : cap_offset == 0\n", __func__); | 962 | ctrl_err(ctrl, "Cannot find PCI capability\n"); |
962 | goto abort; | 963 | goto abort; |
963 | } | 964 | } |
964 | dbg("%s: cap_offset = %x\n", __func__, ctrl->cap_offset); | 965 | ctrl_dbg(ctrl, " cap_offset = %x\n", ctrl->cap_offset); |
965 | 966 | ||
966 | rc = shpc_indirect_read(ctrl, 0, &shpc_base_offset); | 967 | rc = shpc_indirect_read(ctrl, 0, &shpc_base_offset); |
967 | if (rc) { | 968 | if (rc) { |
968 | err("%s: cannot read base_offset\n", __func__); | 969 | ctrl_err(ctrl, "Cannot read base_offset\n"); |
969 | goto abort; | 970 | goto abort; |
970 | } | 971 | } |
971 | 972 | ||
972 | rc = shpc_indirect_read(ctrl, 3, &tempdword); | 973 | rc = shpc_indirect_read(ctrl, 3, &tempdword); |
973 | if (rc) { | 974 | if (rc) { |
974 | err("%s: cannot read slot config\n", __func__); | 975 | ctrl_err(ctrl, "Cannot read slot config\n"); |
975 | goto abort; | 976 | goto abort; |
976 | } | 977 | } |
977 | num_slots = tempdword & SLOT_NUM; | 978 | num_slots = tempdword & SLOT_NUM; |
978 | dbg("%s: num_slots (indirect) %x\n", __func__, num_slots); | 979 | ctrl_dbg(ctrl, " num_slots (indirect) %x\n", num_slots); |
979 | 980 | ||
980 | for (i = 0; i < 9 + num_slots; i++) { | 981 | for (i = 0; i < 9 + num_slots; i++) { |
981 | rc = shpc_indirect_read(ctrl, i, &tempdword); | 982 | rc = shpc_indirect_read(ctrl, i, &tempdword); |
982 | if (rc) { | 983 | if (rc) { |
983 | err("%s: cannot read creg (index = %d)\n", | 984 | ctrl_err(ctrl, |
984 | __func__, i); | 985 | "Cannot read creg (index = %d)\n", i); |
985 | goto abort; | 986 | goto abort; |
986 | } | 987 | } |
987 | dbg("%s: offset %d: value %x\n", __func__,i, | 988 | ctrl_dbg(ctrl, " offset %d: value %x\n", i, tempdword); |
988 | tempdword); | ||
989 | } | 989 | } |
990 | 990 | ||
991 | ctrl->mmio_base = | 991 | ctrl->mmio_base = |
@@ -993,30 +993,31 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) | |||
993 | ctrl->mmio_size = 0x24 + 0x4 * num_slots; | 993 | ctrl->mmio_size = 0x24 + 0x4 * num_slots; |
994 | } | 994 | } |
995 | 995 | ||
996 | info("HPC vendor_id %x device_id %x ss_vid %x ss_did %x\n", pdev->vendor, pdev->device, pdev->subsystem_vendor, | 996 | ctrl_info(ctrl, "HPC vendor_id %x device_id %x ss_vid %x ss_did %x\n", |
997 | pdev->subsystem_device); | 997 | pdev->vendor, pdev->device, pdev->subsystem_vendor, |
998 | pdev->subsystem_device); | ||
998 | 999 | ||
999 | rc = pci_enable_device(pdev); | 1000 | rc = pci_enable_device(pdev); |
1000 | if (rc) { | 1001 | if (rc) { |
1001 | err("%s: pci_enable_device failed\n", __func__); | 1002 | ctrl_err(ctrl, "pci_enable_device failed\n"); |
1002 | goto abort; | 1003 | goto abort; |
1003 | } | 1004 | } |
1004 | 1005 | ||
1005 | if (!request_mem_region(ctrl->mmio_base, ctrl->mmio_size, MY_NAME)) { | 1006 | if (!request_mem_region(ctrl->mmio_base, ctrl->mmio_size, MY_NAME)) { |
1006 | err("%s: cannot reserve MMIO region\n", __func__); | 1007 | ctrl_err(ctrl, "Cannot reserve MMIO region\n"); |
1007 | rc = -1; | 1008 | rc = -1; |
1008 | goto abort; | 1009 | goto abort; |
1009 | } | 1010 | } |
1010 | 1011 | ||
1011 | ctrl->creg = ioremap(ctrl->mmio_base, ctrl->mmio_size); | 1012 | ctrl->creg = ioremap(ctrl->mmio_base, ctrl->mmio_size); |
1012 | if (!ctrl->creg) { | 1013 | if (!ctrl->creg) { |
1013 | err("%s: cannot remap MMIO region %lx @ %lx\n", __func__, | 1014 | ctrl_err(ctrl, "Cannot remap MMIO region %lx @ %lx\n", |
1014 | ctrl->mmio_size, ctrl->mmio_base); | 1015 | ctrl->mmio_size, ctrl->mmio_base); |
1015 | release_mem_region(ctrl->mmio_base, ctrl->mmio_size); | 1016 | release_mem_region(ctrl->mmio_base, ctrl->mmio_size); |
1016 | rc = -1; | 1017 | rc = -1; |
1017 | goto abort; | 1018 | goto abort; |
1018 | } | 1019 | } |
1019 | dbg("%s: ctrl->creg %p\n", __func__, ctrl->creg); | 1020 | ctrl_dbg(ctrl, "ctrl->creg %p\n", ctrl->creg); |
1020 | 1021 | ||
1021 | mutex_init(&ctrl->crit_sect); | 1022 | mutex_init(&ctrl->crit_sect); |
1022 | mutex_init(&ctrl->cmd_lock); | 1023 | mutex_init(&ctrl->cmd_lock); |
@@ -1035,21 +1036,21 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) | |||
1035 | 1036 | ||
1036 | /* Mask Global Interrupt Mask & Command Complete Interrupt Mask */ | 1037 | /* Mask Global Interrupt Mask & Command Complete Interrupt Mask */ |
1037 | tempdword = shpc_readl(ctrl, SERR_INTR_ENABLE); | 1038 | tempdword = shpc_readl(ctrl, SERR_INTR_ENABLE); |
1038 | dbg("%s: SERR_INTR_ENABLE = %x\n", __func__, tempdword); | 1039 | ctrl_dbg(ctrl, "SERR_INTR_ENABLE = %x\n", tempdword); |
1039 | tempdword |= (GLOBAL_INTR_MASK | GLOBAL_SERR_MASK | | 1040 | tempdword |= (GLOBAL_INTR_MASK | GLOBAL_SERR_MASK | |
1040 | COMMAND_INTR_MASK | ARBITER_SERR_MASK); | 1041 | COMMAND_INTR_MASK | ARBITER_SERR_MASK); |
1041 | tempdword &= ~SERR_INTR_RSVDZ_MASK; | 1042 | tempdword &= ~SERR_INTR_RSVDZ_MASK; |
1042 | shpc_writel(ctrl, SERR_INTR_ENABLE, tempdword); | 1043 | shpc_writel(ctrl, SERR_INTR_ENABLE, tempdword); |
1043 | tempdword = shpc_readl(ctrl, SERR_INTR_ENABLE); | 1044 | tempdword = shpc_readl(ctrl, SERR_INTR_ENABLE); |
1044 | dbg("%s: SERR_INTR_ENABLE = %x\n", __func__, tempdword); | 1045 | ctrl_dbg(ctrl, "SERR_INTR_ENABLE = %x\n", tempdword); |
1045 | 1046 | ||
1046 | /* Mask the MRL sensor SERR Mask of individual slot in | 1047 | /* Mask the MRL sensor SERR Mask of individual slot in |
1047 | * Slot SERR-INT Mask & clear all the existing event if any | 1048 | * Slot SERR-INT Mask & clear all the existing event if any |
1048 | */ | 1049 | */ |
1049 | for (hp_slot = 0; hp_slot < ctrl->num_slots; hp_slot++) { | 1050 | for (hp_slot = 0; hp_slot < ctrl->num_slots; hp_slot++) { |
1050 | slot_reg = shpc_readl(ctrl, SLOT_REG(hp_slot)); | 1051 | slot_reg = shpc_readl(ctrl, SLOT_REG(hp_slot)); |
1051 | dbg("%s: Default Logical Slot Register %d value %x\n", __func__, | 1052 | ctrl_dbg(ctrl, "Default Logical Slot Register %d value %x\n", |
1052 | hp_slot, slot_reg); | 1053 | hp_slot, slot_reg); |
1053 | slot_reg |= (PRSNT_CHANGE_INTR_MASK | ISO_PFAULT_INTR_MASK | | 1054 | slot_reg |= (PRSNT_CHANGE_INTR_MASK | ISO_PFAULT_INTR_MASK | |
1054 | BUTTON_PRESS_INTR_MASK | MRL_CHANGE_INTR_MASK | | 1055 | BUTTON_PRESS_INTR_MASK | MRL_CHANGE_INTR_MASK | |
1055 | CON_PFAULT_INTR_MASK | MRL_CHANGE_SERR_MASK | | 1056 | CON_PFAULT_INTR_MASK | MRL_CHANGE_SERR_MASK | |
@@ -1066,24 +1067,24 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) | |||
1066 | /* Installs the interrupt handler */ | 1067 | /* Installs the interrupt handler */ |
1067 | rc = pci_enable_msi(pdev); | 1068 | rc = pci_enable_msi(pdev); |
1068 | if (rc) { | 1069 | if (rc) { |
1069 | info("Can't get msi for the hotplug controller\n"); | 1070 | ctrl_info(ctrl, |
1070 | info("Use INTx for the hotplug controller\n"); | 1071 | "Can't get msi for the hotplug controller\n"); |
1072 | ctrl_info(ctrl, | ||
1073 | "Use INTx for the hotplug controller\n"); | ||
1071 | } | 1074 | } |
1072 | 1075 | ||
1073 | rc = request_irq(ctrl->pci_dev->irq, shpc_isr, IRQF_SHARED, | 1076 | rc = request_irq(ctrl->pci_dev->irq, shpc_isr, IRQF_SHARED, |
1074 | MY_NAME, (void *)ctrl); | 1077 | MY_NAME, (void *)ctrl); |
1075 | dbg("%s: request_irq %d for hpc%d (returns %d)\n", | 1078 | ctrl_dbg(ctrl, "request_irq %d for hpc%d (returns %d)\n", |
1076 | __func__, ctrl->pci_dev->irq, | 1079 | ctrl->pci_dev->irq, |
1077 | atomic_read(&shpchp_num_controllers), rc); | 1080 | atomic_read(&shpchp_num_controllers), rc); |
1078 | if (rc) { | 1081 | if (rc) { |
1079 | err("Can't get irq %d for the hotplug controller\n", | 1082 | ctrl_err(ctrl, "Can't get irq %d for the hotplug " |
1080 | ctrl->pci_dev->irq); | 1083 | "controller\n", ctrl->pci_dev->irq); |
1081 | goto abort_iounmap; | 1084 | goto abort_iounmap; |
1082 | } | 1085 | } |
1083 | } | 1086 | } |
1084 | dbg("%s: HPC at b:d:f:irq=0x%x:%x:%x:%x\n", __func__, | 1087 | ctrl_dbg(ctrl, "HPC at %s irq=%x\n", pci_name(pdev), pdev->irq); |
1085 | pdev->bus->number, PCI_SLOT(pdev->devfn), | ||
1086 | PCI_FUNC(pdev->devfn), pdev->irq); | ||
1087 | 1088 | ||
1088 | /* | 1089 | /* |
1089 | * If this is the first controller to be initialized, | 1090 | * If this is the first controller to be initialized, |
@@ -1102,8 +1103,8 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) | |||
1102 | */ | 1103 | */ |
1103 | for (hp_slot = 0; hp_slot < ctrl->num_slots; hp_slot++) { | 1104 | for (hp_slot = 0; hp_slot < ctrl->num_slots; hp_slot++) { |
1104 | slot_reg = shpc_readl(ctrl, SLOT_REG(hp_slot)); | 1105 | slot_reg = shpc_readl(ctrl, SLOT_REG(hp_slot)); |
1105 | dbg("%s: Default Logical Slot Register %d value %x\n", __func__, | 1106 | ctrl_dbg(ctrl, "Default Logical Slot Register %d value %x\n", |
1106 | hp_slot, slot_reg); | 1107 | hp_slot, slot_reg); |
1107 | slot_reg &= ~(PRSNT_CHANGE_INTR_MASK | ISO_PFAULT_INTR_MASK | | 1108 | slot_reg &= ~(PRSNT_CHANGE_INTR_MASK | ISO_PFAULT_INTR_MASK | |
1108 | BUTTON_PRESS_INTR_MASK | MRL_CHANGE_INTR_MASK | | 1109 | BUTTON_PRESS_INTR_MASK | MRL_CHANGE_INTR_MASK | |
1109 | CON_PFAULT_INTR_MASK | SLOT_REG_RSVDZ_MASK); | 1110 | CON_PFAULT_INTR_MASK | SLOT_REG_RSVDZ_MASK); |
@@ -1116,7 +1117,7 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) | |||
1116 | SERR_INTR_RSVDZ_MASK); | 1117 | SERR_INTR_RSVDZ_MASK); |
1117 | shpc_writel(ctrl, SERR_INTR_ENABLE, tempdword); | 1118 | shpc_writel(ctrl, SERR_INTR_ENABLE, tempdword); |
1118 | tempdword = shpc_readl(ctrl, SERR_INTR_ENABLE); | 1119 | tempdword = shpc_readl(ctrl, SERR_INTR_ENABLE); |
1119 | dbg("%s: SERR_INTR_ENABLE = %x\n", __func__, tempdword); | 1120 | ctrl_dbg(ctrl, "SERR_INTR_ENABLE = %x\n", tempdword); |
1120 | } | 1121 | } |
1121 | 1122 | ||
1122 | return 0; | 1123 | return 0; |
diff --git a/drivers/pci/hotplug/shpchp_pci.c b/drivers/pci/hotplug/shpchp_pci.c index 3fc4ec0eea0b..138f161becc0 100644 --- a/drivers/pci/hotplug/shpchp_pci.c +++ b/drivers/pci/hotplug/shpchp_pci.c | |||
@@ -49,9 +49,7 @@ static void program_fw_provided_values(struct pci_dev *dev) | |||
49 | /* use default values if we can't get them from firmware */ | 49 | /* use default values if we can't get them from firmware */ |
50 | if (get_hp_params_from_firmware(dev, &hpp) || | 50 | if (get_hp_params_from_firmware(dev, &hpp) || |
51 | !hpp.t0 || (hpp.t0->revision > 1)) { | 51 | !hpp.t0 || (hpp.t0->revision > 1)) { |
52 | printk(KERN_WARNING | 52 | warn("Could not get hotplug parameters. Use defaults\n"); |
53 | "%s: Could not get hotplug parameters. Use defaults\n", | ||
54 | __func__); | ||
55 | hpp.t0 = &hpp.type0_data; | 53 | hpp.t0 = &hpp.type0_data; |
56 | hpp.t0->revision = 0; | 54 | hpp.t0->revision = 0; |
57 | hpp.t0->cache_line_size = 8; | 55 | hpp.t0->cache_line_size = 8; |
@@ -101,18 +99,20 @@ int __ref shpchp_configure_device(struct slot *p_slot) | |||
101 | struct pci_dev *dev; | 99 | struct pci_dev *dev; |
102 | struct pci_bus *parent = p_slot->ctrl->pci_dev->subordinate; | 100 | struct pci_bus *parent = p_slot->ctrl->pci_dev->subordinate; |
103 | int num, fn; | 101 | int num, fn; |
102 | struct controller *ctrl = p_slot->ctrl; | ||
104 | 103 | ||
105 | dev = pci_get_slot(parent, PCI_DEVFN(p_slot->device, 0)); | 104 | dev = pci_get_slot(parent, PCI_DEVFN(p_slot->device, 0)); |
106 | if (dev) { | 105 | if (dev) { |
107 | err("Device %s already exists at %x:%x, cannot hot-add\n", | 106 | ctrl_err(ctrl, "Device %s already exists " |
108 | pci_name(dev), p_slot->bus, p_slot->device); | 107 | "at %04x:%02x:%02x, cannot hot-add\n", pci_name(dev), |
108 | pci_domain_nr(parent), p_slot->bus, p_slot->device); | ||
109 | pci_dev_put(dev); | 109 | pci_dev_put(dev); |
110 | return -EINVAL; | 110 | return -EINVAL; |
111 | } | 111 | } |
112 | 112 | ||
113 | num = pci_scan_slot(parent, PCI_DEVFN(p_slot->device, 0)); | 113 | num = pci_scan_slot(parent, PCI_DEVFN(p_slot->device, 0)); |
114 | if (num == 0) { | 114 | if (num == 0) { |
115 | err("No new device found\n"); | 115 | ctrl_err(ctrl, "No new device found\n"); |
116 | return -ENODEV; | 116 | return -ENODEV; |
117 | } | 117 | } |
118 | 118 | ||
@@ -121,8 +121,8 @@ int __ref shpchp_configure_device(struct slot *p_slot) | |||
121 | if (!dev) | 121 | if (!dev) |
122 | continue; | 122 | continue; |
123 | if ((dev->class >> 16) == PCI_BASE_CLASS_DISPLAY) { | 123 | if ((dev->class >> 16) == PCI_BASE_CLASS_DISPLAY) { |
124 | err("Cannot hot-add display device %s\n", | 124 | ctrl_err(ctrl, "Cannot hot-add display device %s\n", |
125 | pci_name(dev)); | 125 | pci_name(dev)); |
126 | pci_dev_put(dev); | 126 | pci_dev_put(dev); |
127 | continue; | 127 | continue; |
128 | } | 128 | } |
@@ -138,14 +138,15 @@ int __ref shpchp_configure_device(struct slot *p_slot) | |||
138 | break; | 138 | break; |
139 | } | 139 | } |
140 | if (busnr >= end) { | 140 | if (busnr >= end) { |
141 | err("No free bus for hot-added bridge\n"); | 141 | ctrl_err(ctrl, |
142 | "No free bus for hot-added bridge\n"); | ||
142 | pci_dev_put(dev); | 143 | pci_dev_put(dev); |
143 | continue; | 144 | continue; |
144 | } | 145 | } |
145 | child = pci_add_new_bus(parent, dev, busnr); | 146 | child = pci_add_new_bus(parent, dev, busnr); |
146 | if (!child) { | 147 | if (!child) { |
147 | err("Cannot add new bus for %s\n", | 148 | ctrl_err(ctrl, "Cannot add new bus for %s\n", |
148 | pci_name(dev)); | 149 | pci_name(dev)); |
149 | pci_dev_put(dev); | 150 | pci_dev_put(dev); |
150 | continue; | 151 | continue; |
151 | } | 152 | } |
@@ -168,8 +169,10 @@ int shpchp_unconfigure_device(struct slot *p_slot) | |||
168 | int j; | 169 | int j; |
169 | u8 bctl = 0; | 170 | u8 bctl = 0; |
170 | struct pci_bus *parent = p_slot->ctrl->pci_dev->subordinate; | 171 | struct pci_bus *parent = p_slot->ctrl->pci_dev->subordinate; |
172 | struct controller *ctrl = p_slot->ctrl; | ||
171 | 173 | ||
172 | dbg("%s: bus/dev = %x/%x\n", __func__, p_slot->bus, p_slot->device); | 174 | ctrl_dbg(ctrl, "%s: domain:bus:dev = %04x:%02x:%02x\n", |
175 | __func__, pci_domain_nr(parent), p_slot->bus, p_slot->device); | ||
173 | 176 | ||
174 | for (j=0; j<8 ; j++) { | 177 | for (j=0; j<8 ; j++) { |
175 | struct pci_dev* temp = pci_get_slot(parent, | 178 | struct pci_dev* temp = pci_get_slot(parent, |
@@ -177,16 +180,17 @@ int shpchp_unconfigure_device(struct slot *p_slot) | |||
177 | if (!temp) | 180 | if (!temp) |
178 | continue; | 181 | continue; |
179 | if ((temp->class >> 16) == PCI_BASE_CLASS_DISPLAY) { | 182 | if ((temp->class >> 16) == PCI_BASE_CLASS_DISPLAY) { |
180 | err("Cannot remove display device %s\n", | 183 | ctrl_err(ctrl, "Cannot remove display device %s\n", |
181 | pci_name(temp)); | 184 | pci_name(temp)); |
182 | pci_dev_put(temp); | 185 | pci_dev_put(temp); |
183 | continue; | 186 | continue; |
184 | } | 187 | } |
185 | if (temp->hdr_type == PCI_HEADER_TYPE_BRIDGE) { | 188 | if (temp->hdr_type == PCI_HEADER_TYPE_BRIDGE) { |
186 | pci_read_config_byte(temp, PCI_BRIDGE_CONTROL, &bctl); | 189 | pci_read_config_byte(temp, PCI_BRIDGE_CONTROL, &bctl); |
187 | if (bctl & PCI_BRIDGE_CTL_VGA) { | 190 | if (bctl & PCI_BRIDGE_CTL_VGA) { |
188 | err("Cannot remove display device %s\n", | 191 | ctrl_err(ctrl, |
189 | pci_name(temp)); | 192 | "Cannot remove display device %s\n", |
193 | pci_name(temp)); | ||
190 | pci_dev_put(temp); | 194 | pci_dev_put(temp); |
191 | continue; | 195 | continue; |
192 | } | 196 | } |
diff --git a/drivers/pci/irq.c b/drivers/pci/irq.c new file mode 100644 index 000000000000..6441dfa969a3 --- /dev/null +++ b/drivers/pci/irq.c | |||
@@ -0,0 +1,60 @@ | |||
1 | /* | ||
2 | * PCI IRQ failure handing code | ||
3 | * | ||
4 | * Copyright (c) 2008 James Bottomley <James.Bottomley@HansenPartnership.com> | ||
5 | */ | ||
6 | |||
7 | #include <linux/acpi.h> | ||
8 | #include <linux/device.h> | ||
9 | #include <linux/kernel.h> | ||
10 | #include <linux/pci.h> | ||
11 | |||
12 | static void pci_note_irq_problem(struct pci_dev *pdev, const char *reason) | ||
13 | { | ||
14 | struct pci_dev *parent = to_pci_dev(pdev->dev.parent); | ||
15 | |||
16 | dev_printk(KERN_ERR, &pdev->dev, | ||
17 | "Potentially misrouted IRQ (Bridge %s %04x:%04x)\n", | ||
18 | parent->dev.bus_id, parent->vendor, parent->device); | ||
19 | dev_printk(KERN_ERR, &pdev->dev, "%s\n", reason); | ||
20 | dev_printk(KERN_ERR, &pdev->dev, "Please report to linux-kernel@vger.kernel.org\n"); | ||
21 | WARN_ON(1); | ||
22 | } | ||
23 | |||
24 | /** | ||
25 | * pci_lost_interrupt - reports a lost PCI interrupt | ||
26 | * @pdev: device whose interrupt is lost | ||
27 | * | ||
28 | * The primary function of this routine is to report a lost interrupt | ||
29 | * in a standard way which users can recognise (instead of blaming the | ||
30 | * driver). | ||
31 | * | ||
32 | * Returns: | ||
33 | * a suggestion for fixing it (although the driver is not required to | ||
34 | * act on this). | ||
35 | */ | ||
36 | enum pci_lost_interrupt_reason pci_lost_interrupt(struct pci_dev *pdev) | ||
37 | { | ||
38 | if (pdev->msi_enabled || pdev->msix_enabled) { | ||
39 | enum pci_lost_interrupt_reason ret; | ||
40 | |||
41 | if (pdev->msix_enabled) { | ||
42 | pci_note_irq_problem(pdev, "MSIX routing failure"); | ||
43 | ret = PCI_LOST_IRQ_DISABLE_MSIX; | ||
44 | } else { | ||
45 | pci_note_irq_problem(pdev, "MSI routing failure"); | ||
46 | ret = PCI_LOST_IRQ_DISABLE_MSI; | ||
47 | } | ||
48 | return ret; | ||
49 | } | ||
50 | #ifdef CONFIG_ACPI | ||
51 | if (!(acpi_disabled || acpi_noirq)) { | ||
52 | pci_note_irq_problem(pdev, "Potential ACPI misrouting please reboot with acpi=noirq"); | ||
53 | /* currently no way to fix acpi on the fly */ | ||
54 | return PCI_LOST_IRQ_DISABLE_ACPI; | ||
55 | } | ||
56 | #endif | ||
57 | pci_note_irq_problem(pdev, "unknown cause (not MSI or ACPI)"); | ||
58 | return PCI_LOST_IRQ_NO_INFORMATION; | ||
59 | } | ||
60 | EXPORT_SYMBOL(pci_lost_interrupt); | ||
diff --git a/drivers/pci/pci-acpi.c b/drivers/pci/pci-acpi.c index dfe7c8e1b185..b3a63edb6901 100644 --- a/drivers/pci/pci-acpi.c +++ b/drivers/pci/pci-acpi.c | |||
@@ -83,6 +83,9 @@ static acpi_status acpi_run_osc(acpi_handle handle, | |||
83 | if (ACPI_FAILURE(status)) | 83 | if (ACPI_FAILURE(status)) |
84 | return status; | 84 | return status; |
85 | 85 | ||
86 | if (!output.length) | ||
87 | return AE_NULL_OBJECT; | ||
88 | |||
86 | out_obj = output.pointer; | 89 | out_obj = output.pointer; |
87 | if (out_obj->type != ACPI_TYPE_BUFFER) { | 90 | if (out_obj->type != ACPI_TYPE_BUFFER) { |
88 | printk(KERN_DEBUG "Evaluate _OSC returns wrong type\n"); | 91 | printk(KERN_DEBUG "Evaluate _OSC returns wrong type\n"); |
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index 533aeb5fcbe4..21f2ac639cab 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c | |||
@@ -1309,27 +1309,32 @@ void pci_enable_ari(struct pci_dev *dev) | |||
1309 | int pos; | 1309 | int pos; |
1310 | u32 cap; | 1310 | u32 cap; |
1311 | u16 ctrl; | 1311 | u16 ctrl; |
1312 | struct pci_dev *bridge; | ||
1312 | 1313 | ||
1313 | if (!dev->is_pcie) | 1314 | if (!dev->is_pcie || dev->devfn) |
1314 | return; | 1315 | return; |
1315 | 1316 | ||
1316 | if (dev->pcie_type != PCI_EXP_TYPE_ROOT_PORT && | 1317 | pos = pci_find_ext_capability(dev, PCI_EXT_CAP_ID_ARI); |
1317 | dev->pcie_type != PCI_EXP_TYPE_DOWNSTREAM) | 1318 | if (!pos) |
1318 | return; | 1319 | return; |
1319 | 1320 | ||
1320 | pos = pci_find_capability(dev, PCI_CAP_ID_EXP); | 1321 | bridge = dev->bus->self; |
1322 | if (!bridge || !bridge->is_pcie) | ||
1323 | return; | ||
1324 | |||
1325 | pos = pci_find_capability(bridge, PCI_CAP_ID_EXP); | ||
1321 | if (!pos) | 1326 | if (!pos) |
1322 | return; | 1327 | return; |
1323 | 1328 | ||
1324 | pci_read_config_dword(dev, pos + PCI_EXP_DEVCAP2, &cap); | 1329 | pci_read_config_dword(bridge, pos + PCI_EXP_DEVCAP2, &cap); |
1325 | if (!(cap & PCI_EXP_DEVCAP2_ARI)) | 1330 | if (!(cap & PCI_EXP_DEVCAP2_ARI)) |
1326 | return; | 1331 | return; |
1327 | 1332 | ||
1328 | pci_read_config_word(dev, pos + PCI_EXP_DEVCTL2, &ctrl); | 1333 | pci_read_config_word(bridge, pos + PCI_EXP_DEVCTL2, &ctrl); |
1329 | ctrl |= PCI_EXP_DEVCTL2_ARI; | 1334 | ctrl |= PCI_EXP_DEVCTL2_ARI; |
1330 | pci_write_config_word(dev, pos + PCI_EXP_DEVCTL2, ctrl); | 1335 | pci_write_config_word(bridge, pos + PCI_EXP_DEVCTL2, ctrl); |
1331 | 1336 | ||
1332 | dev->ari_enabled = 1; | 1337 | bridge->ari_enabled = 1; |
1333 | } | 1338 | } |
1334 | 1339 | ||
1335 | int | 1340 | int |
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c index 6f1e51d77bce..003a9b3c293f 100644 --- a/drivers/pci/probe.c +++ b/drivers/pci/probe.c | |||
@@ -298,9 +298,6 @@ void __devinit pci_read_bridge_bases(struct pci_bus *child) | |||
298 | child->resource[i] = child->parent->resource[i - 3]; | 298 | child->resource[i] = child->parent->resource[i - 3]; |
299 | } | 299 | } |
300 | 300 | ||
301 | for(i=0; i<3; i++) | ||
302 | child->resource[i] = &dev->resource[PCI_BRIDGE_RESOURCES+i]; | ||
303 | |||
304 | res = child->resource[0]; | 301 | res = child->resource[0]; |
305 | pci_read_config_byte(dev, PCI_IO_BASE, &io_base_lo); | 302 | pci_read_config_byte(dev, PCI_IO_BASE, &io_base_lo); |
306 | pci_read_config_byte(dev, PCI_IO_LIMIT, &io_limit_lo); | 303 | pci_read_config_byte(dev, PCI_IO_LIMIT, &io_limit_lo); |
diff --git a/drivers/s390/char/tape_block.c b/drivers/s390/char/tape_block.c index 023803dbb0c7..ae18baf59f06 100644 --- a/drivers/s390/char/tape_block.c +++ b/drivers/s390/char/tape_block.c | |||
@@ -76,7 +76,7 @@ tapeblock_trigger_requeue(struct tape_device *device) | |||
76 | static void | 76 | static void |
77 | tapeblock_end_request(struct request *req, int error) | 77 | tapeblock_end_request(struct request *req, int error) |
78 | { | 78 | { |
79 | if (__blk_end_request(req, error, blk_rq_bytes(req))) | 79 | if (blk_end_request(req, error, blk_rq_bytes(req))) |
80 | BUG(); | 80 | BUG(); |
81 | } | 81 | } |
82 | 82 | ||
@@ -166,7 +166,7 @@ tapeblock_requeue(struct work_struct *work) { | |||
166 | nr_queued++; | 166 | nr_queued++; |
167 | spin_unlock(get_ccwdev_lock(device->cdev)); | 167 | spin_unlock(get_ccwdev_lock(device->cdev)); |
168 | 168 | ||
169 | spin_lock(&device->blk_data.request_queue_lock); | 169 | spin_lock_irq(&device->blk_data.request_queue_lock); |
170 | while ( | 170 | while ( |
171 | !blk_queue_plugged(queue) && | 171 | !blk_queue_plugged(queue) && |
172 | elv_next_request(queue) && | 172 | elv_next_request(queue) && |
@@ -176,7 +176,9 @@ tapeblock_requeue(struct work_struct *work) { | |||
176 | if (rq_data_dir(req) == WRITE) { | 176 | if (rq_data_dir(req) == WRITE) { |
177 | DBF_EVENT(1, "TBLOCK: Rejecting write request\n"); | 177 | DBF_EVENT(1, "TBLOCK: Rejecting write request\n"); |
178 | blkdev_dequeue_request(req); | 178 | blkdev_dequeue_request(req); |
179 | spin_unlock_irq(&device->blk_data.request_queue_lock); | ||
179 | tapeblock_end_request(req, -EIO); | 180 | tapeblock_end_request(req, -EIO); |
181 | spin_lock_irq(&device->blk_data.request_queue_lock); | ||
180 | continue; | 182 | continue; |
181 | } | 183 | } |
182 | blkdev_dequeue_request(req); | 184 | blkdev_dequeue_request(req); |
diff --git a/drivers/s390/char/tape_core.c b/drivers/s390/char/tape_core.c index d7073dbf825c..f9bb51fa7f5b 100644 --- a/drivers/s390/char/tape_core.c +++ b/drivers/s390/char/tape_core.c | |||
@@ -1200,7 +1200,7 @@ tape_open(struct tape_device *device) | |||
1200 | { | 1200 | { |
1201 | int rc; | 1201 | int rc; |
1202 | 1202 | ||
1203 | spin_lock(get_ccwdev_lock(device->cdev)); | 1203 | spin_lock_irq(get_ccwdev_lock(device->cdev)); |
1204 | if (device->tape_state == TS_NOT_OPER) { | 1204 | if (device->tape_state == TS_NOT_OPER) { |
1205 | DBF_EVENT(6, "TAPE:nodev\n"); | 1205 | DBF_EVENT(6, "TAPE:nodev\n"); |
1206 | rc = -ENODEV; | 1206 | rc = -ENODEV; |
@@ -1218,7 +1218,7 @@ tape_open(struct tape_device *device) | |||
1218 | tape_state_set(device, TS_IN_USE); | 1218 | tape_state_set(device, TS_IN_USE); |
1219 | rc = 0; | 1219 | rc = 0; |
1220 | } | 1220 | } |
1221 | spin_unlock(get_ccwdev_lock(device->cdev)); | 1221 | spin_unlock_irq(get_ccwdev_lock(device->cdev)); |
1222 | return rc; | 1222 | return rc; |
1223 | } | 1223 | } |
1224 | 1224 | ||
@@ -1228,11 +1228,11 @@ tape_open(struct tape_device *device) | |||
1228 | int | 1228 | int |
1229 | tape_release(struct tape_device *device) | 1229 | tape_release(struct tape_device *device) |
1230 | { | 1230 | { |
1231 | spin_lock(get_ccwdev_lock(device->cdev)); | 1231 | spin_lock_irq(get_ccwdev_lock(device->cdev)); |
1232 | if (device->tape_state == TS_IN_USE) | 1232 | if (device->tape_state == TS_IN_USE) |
1233 | tape_state_set(device, TS_UNUSED); | 1233 | tape_state_set(device, TS_UNUSED); |
1234 | module_put(device->discipline->owner); | 1234 | module_put(device->discipline->owner); |
1235 | spin_unlock(get_ccwdev_lock(device->cdev)); | 1235 | spin_unlock_irq(get_ccwdev_lock(device->cdev)); |
1236 | return 0; | 1236 | return 0; |
1237 | } | 1237 | } |
1238 | 1238 | ||
diff --git a/drivers/s390/cio/qdio_debug.c b/drivers/s390/cio/qdio_debug.c index b5390821434f..f05590355be8 100644 --- a/drivers/s390/cio/qdio_debug.c +++ b/drivers/s390/cio/qdio_debug.c | |||
@@ -20,6 +20,7 @@ static struct dentry *debugfs_root; | |||
20 | #define MAX_DEBUGFS_QUEUES 32 | 20 | #define MAX_DEBUGFS_QUEUES 32 |
21 | static struct dentry *debugfs_queues[MAX_DEBUGFS_QUEUES] = { NULL }; | 21 | static struct dentry *debugfs_queues[MAX_DEBUGFS_QUEUES] = { NULL }; |
22 | static DEFINE_MUTEX(debugfs_mutex); | 22 | static DEFINE_MUTEX(debugfs_mutex); |
23 | #define QDIO_DEBUGFS_NAME_LEN 40 | ||
23 | 24 | ||
24 | void qdio_allocate_do_dbf(struct qdio_initialize *init_data) | 25 | void qdio_allocate_do_dbf(struct qdio_initialize *init_data) |
25 | { | 26 | { |
@@ -152,17 +153,6 @@ static int qstat_seq_open(struct inode *inode, struct file *filp) | |||
152 | filp->f_path.dentry->d_inode->i_private); | 153 | filp->f_path.dentry->d_inode->i_private); |
153 | } | 154 | } |
154 | 155 | ||
155 | static void get_queue_name(struct qdio_q *q, struct ccw_device *cdev, char *name) | ||
156 | { | ||
157 | memset(name, 0, sizeof(name)); | ||
158 | sprintf(name, "%s", dev_name(&cdev->dev)); | ||
159 | if (q->is_input_q) | ||
160 | sprintf(name + strlen(name), "_input"); | ||
161 | else | ||
162 | sprintf(name + strlen(name), "_output"); | ||
163 | sprintf(name + strlen(name), "_%d", q->nr); | ||
164 | } | ||
165 | |||
166 | static void remove_debugfs_entry(struct qdio_q *q) | 156 | static void remove_debugfs_entry(struct qdio_q *q) |
167 | { | 157 | { |
168 | int i; | 158 | int i; |
@@ -189,14 +179,17 @@ static struct file_operations debugfs_fops = { | |||
189 | static void setup_debugfs_entry(struct qdio_q *q, struct ccw_device *cdev) | 179 | static void setup_debugfs_entry(struct qdio_q *q, struct ccw_device *cdev) |
190 | { | 180 | { |
191 | int i = 0; | 181 | int i = 0; |
192 | char name[40]; | 182 | char name[QDIO_DEBUGFS_NAME_LEN]; |
193 | 183 | ||
194 | while (debugfs_queues[i] != NULL) { | 184 | while (debugfs_queues[i] != NULL) { |
195 | i++; | 185 | i++; |
196 | if (i >= MAX_DEBUGFS_QUEUES) | 186 | if (i >= MAX_DEBUGFS_QUEUES) |
197 | return; | 187 | return; |
198 | } | 188 | } |
199 | get_queue_name(q, cdev, name); | 189 | snprintf(name, QDIO_DEBUGFS_NAME_LEN, "%s_%s_%d", |
190 | dev_name(&cdev->dev), | ||
191 | q->is_input_q ? "input" : "output", | ||
192 | q->nr); | ||
200 | debugfs_queues[i] = debugfs_create_file(name, S_IFREG | S_IRUGO | S_IWUSR, | 193 | debugfs_queues[i] = debugfs_create_file(name, S_IFREG | S_IRUGO | S_IWUSR, |
201 | debugfs_root, q, &debugfs_fops); | 194 | debugfs_root, q, &debugfs_fops); |
202 | } | 195 | } |
diff --git a/drivers/s390/cio/qdio_main.c b/drivers/s390/cio/qdio_main.c index a50682d2a0fa..7c8659151993 100644 --- a/drivers/s390/cio/qdio_main.c +++ b/drivers/s390/cio/qdio_main.c | |||
@@ -1083,7 +1083,6 @@ void qdio_int_handler(struct ccw_device *cdev, unsigned long intparm, | |||
1083 | case -EIO: | 1083 | case -EIO: |
1084 | sprintf(dbf_text, "ierr%4x", irq_ptr->schid.sch_no); | 1084 | sprintf(dbf_text, "ierr%4x", irq_ptr->schid.sch_no); |
1085 | QDIO_DBF_TEXT2(1, setup, dbf_text); | 1085 | QDIO_DBF_TEXT2(1, setup, dbf_text); |
1086 | qdio_int_error(cdev); | ||
1087 | return; | 1086 | return; |
1088 | case -ETIMEDOUT: | 1087 | case -ETIMEDOUT: |
1089 | sprintf(dbf_text, "qtoh%4x", irq_ptr->schid.sch_no); | 1088 | sprintf(dbf_text, "qtoh%4x", irq_ptr->schid.sch_no); |
diff --git a/drivers/scsi/3w-9xxx.c b/drivers/scsi/3w-9xxx.c index b92c19bb6876..5311317c2e4c 100644 --- a/drivers/scsi/3w-9xxx.c +++ b/drivers/scsi/3w-9xxx.c | |||
@@ -1924,12 +1924,9 @@ static void twa_scsiop_execute_scsi_complete(TW_Device_Extension *tw_dev, int re | |||
1924 | (cmd->sc_data_direction == DMA_FROM_DEVICE || | 1924 | (cmd->sc_data_direction == DMA_FROM_DEVICE || |
1925 | cmd->sc_data_direction == DMA_BIDIRECTIONAL)) { | 1925 | cmd->sc_data_direction == DMA_BIDIRECTIONAL)) { |
1926 | if (scsi_sg_count(cmd) == 1) { | 1926 | if (scsi_sg_count(cmd) == 1) { |
1927 | unsigned long flags; | ||
1928 | void *buf = tw_dev->generic_buffer_virt[request_id]; | 1927 | void *buf = tw_dev->generic_buffer_virt[request_id]; |
1929 | 1928 | ||
1930 | local_irq_save(flags); | ||
1931 | scsi_sg_copy_from_buffer(cmd, buf, TW_SECTOR_SIZE); | 1929 | scsi_sg_copy_from_buffer(cmd, buf, TW_SECTOR_SIZE); |
1932 | local_irq_restore(flags); | ||
1933 | } | 1930 | } |
1934 | } | 1931 | } |
1935 | } /* End twa_scsiop_execute_scsi_complete() */ | 1932 | } /* End twa_scsiop_execute_scsi_complete() */ |
diff --git a/drivers/scsi/3w-xxxx.c b/drivers/scsi/3w-xxxx.c index a0537f09aa21..c03f1d2c9e2e 100644 --- a/drivers/scsi/3w-xxxx.c +++ b/drivers/scsi/3w-xxxx.c | |||
@@ -1466,12 +1466,7 @@ static int tw_scsiop_inquiry(TW_Device_Extension *tw_dev, int request_id) | |||
1466 | static void tw_transfer_internal(TW_Device_Extension *tw_dev, int request_id, | 1466 | static void tw_transfer_internal(TW_Device_Extension *tw_dev, int request_id, |
1467 | void *data, unsigned int len) | 1467 | void *data, unsigned int len) |
1468 | { | 1468 | { |
1469 | struct scsi_cmnd *cmd = tw_dev->srb[request_id]; | 1469 | scsi_sg_copy_from_buffer(tw_dev->srb[request_id], data, len); |
1470 | unsigned long flags; | ||
1471 | |||
1472 | local_irq_save(flags); | ||
1473 | scsi_sg_copy_from_buffer(cmd, data, len); | ||
1474 | local_irq_restore(flags); | ||
1475 | } | 1470 | } |
1476 | 1471 | ||
1477 | /* This function is called by the isr to complete an inquiry command */ | 1472 | /* This function is called by the isr to complete an inquiry command */ |
diff --git a/drivers/scsi/aic7xxx/aic79xx.reg b/drivers/scsi/aic7xxx/aic79xx.reg index cca16fc5b4ad..0666c22ab55b 100644 --- a/drivers/scsi/aic7xxx/aic79xx.reg +++ b/drivers/scsi/aic7xxx/aic79xx.reg | |||
@@ -80,6 +80,17 @@ VERSION = "$Id: //depot/aic7xxx/aic7xxx/aic79xx.reg#77 $" | |||
80 | } | 80 | } |
81 | 81 | ||
82 | /* | 82 | /* |
83 | * Registers marked "dont_generate_debug_code" are not (yet) referenced | ||
84 | * from the driver code, and this keyword inhibit generation | ||
85 | * of debug code for them. | ||
86 | * | ||
87 | * REG_PRETTY_PRINT config will complain if dont_generate_debug_code | ||
88 | * is added to the register which is referenced in the driver. | ||
89 | * Unreferenced register with no dont_generate_debug_code will result | ||
90 | * in dead code. No warning is issued. | ||
91 | */ | ||
92 | |||
93 | /* | ||
83 | * Mode Pointer | 94 | * Mode Pointer |
84 | * Controls which of the 5, 512byte, address spaces should be used | 95 | * Controls which of the 5, 512byte, address spaces should be used |
85 | * as the source and destination of any register accesses in our | 96 | * as the source and destination of any register accesses in our |
@@ -91,6 +102,7 @@ register MODE_PTR { | |||
91 | field DST_MODE 0x70 | 102 | field DST_MODE 0x70 |
92 | field SRC_MODE 0x07 | 103 | field SRC_MODE 0x07 |
93 | mode_pointer | 104 | mode_pointer |
105 | dont_generate_debug_code | ||
94 | } | 106 | } |
95 | 107 | ||
96 | const SRC_MODE_SHIFT 0 | 108 | const SRC_MODE_SHIFT 0 |
@@ -190,6 +202,7 @@ register SEQINTCODE { | |||
190 | SAW_HWERR, | 202 | SAW_HWERR, |
191 | BAD_SCB_STATUS | 203 | BAD_SCB_STATUS |
192 | } | 204 | } |
205 | dont_generate_debug_code | ||
193 | } | 206 | } |
194 | 207 | ||
195 | /* | 208 | /* |
@@ -207,6 +220,7 @@ register CLRINT { | |||
207 | field CLRSEQINT 0x04 | 220 | field CLRSEQINT 0x04 |
208 | field CLRCMDINT 0x02 | 221 | field CLRCMDINT 0x02 |
209 | field CLRSPLTINT 0x01 | 222 | field CLRSPLTINT 0x01 |
223 | dont_generate_debug_code | ||
210 | } | 224 | } |
211 | 225 | ||
212 | /* | 226 | /* |
@@ -222,6 +236,7 @@ register ERROR { | |||
222 | field SQPARERR 0x08 | 236 | field SQPARERR 0x08 |
223 | field ILLOPCODE 0x04 | 237 | field ILLOPCODE 0x04 |
224 | field DSCTMOUT 0x02 | 238 | field DSCTMOUT 0x02 |
239 | dont_generate_debug_code | ||
225 | } | 240 | } |
226 | 241 | ||
227 | /* | 242 | /* |
@@ -255,6 +270,7 @@ register HCNTRL { | |||
255 | field INTEN 0x02 | 270 | field INTEN 0x02 |
256 | field CHIPRST 0x01 | 271 | field CHIPRST 0x01 |
257 | field CHIPRSTACK 0x01 | 272 | field CHIPRSTACK 0x01 |
273 | dont_generate_debug_code | ||
258 | } | 274 | } |
259 | 275 | ||
260 | /* | 276 | /* |
@@ -265,6 +281,7 @@ register HNSCB_QOFF { | |||
265 | access_mode RW | 281 | access_mode RW |
266 | size 2 | 282 | size 2 |
267 | count 2 | 283 | count 2 |
284 | dont_generate_debug_code | ||
268 | } | 285 | } |
269 | 286 | ||
270 | /* | 287 | /* |
@@ -274,6 +291,7 @@ register HESCB_QOFF { | |||
274 | address 0x008 | 291 | address 0x008 |
275 | access_mode RW | 292 | access_mode RW |
276 | count 2 | 293 | count 2 |
294 | dont_generate_debug_code | ||
277 | } | 295 | } |
278 | 296 | ||
279 | /* | 297 | /* |
@@ -311,6 +329,7 @@ register CLRSEQINTSTAT { | |||
311 | field CLRSEQ_SCSIINT 0x04 | 329 | field CLRSEQ_SCSIINT 0x04 |
312 | field CLRSEQ_PCIINT 0x02 | 330 | field CLRSEQ_PCIINT 0x02 |
313 | field CLRSEQ_SPLTINT 0x01 | 331 | field CLRSEQ_SPLTINT 0x01 |
332 | dont_generate_debug_code | ||
314 | } | 333 | } |
315 | 334 | ||
316 | /* | 335 | /* |
@@ -320,6 +339,7 @@ register SWTIMER { | |||
320 | address 0x00E | 339 | address 0x00E |
321 | access_mode RW | 340 | access_mode RW |
322 | size 2 | 341 | size 2 |
342 | dont_generate_debug_code | ||
323 | } | 343 | } |
324 | 344 | ||
325 | /* | 345 | /* |
@@ -330,6 +350,7 @@ register SNSCB_QOFF { | |||
330 | access_mode RW | 350 | access_mode RW |
331 | size 2 | 351 | size 2 |
332 | modes M_CCHAN | 352 | modes M_CCHAN |
353 | dont_generate_debug_code | ||
333 | } | 354 | } |
334 | 355 | ||
335 | /* | 356 | /* |
@@ -340,6 +361,7 @@ register SESCB_QOFF { | |||
340 | count 2 | 361 | count 2 |
341 | access_mode RW | 362 | access_mode RW |
342 | modes M_CCHAN | 363 | modes M_CCHAN |
364 | dont_generate_debug_code | ||
343 | } | 365 | } |
344 | 366 | ||
345 | /* | 367 | /* |
@@ -350,6 +372,7 @@ register SDSCB_QOFF { | |||
350 | access_mode RW | 372 | access_mode RW |
351 | modes M_CCHAN | 373 | modes M_CCHAN |
352 | size 2 | 374 | size 2 |
375 | dont_generate_debug_code | ||
353 | } | 376 | } |
354 | 377 | ||
355 | /* | 378 | /* |
@@ -378,6 +401,7 @@ register QOFF_CTLSTA { | |||
378 | SCB_QSIZE_8192, | 401 | SCB_QSIZE_8192, |
379 | SCB_QSIZE_16384 | 402 | SCB_QSIZE_16384 |
380 | } | 403 | } |
404 | dont_generate_debug_code | ||
381 | } | 405 | } |
382 | 406 | ||
383 | /* | 407 | /* |
@@ -431,6 +455,7 @@ register DSCOMMAND0 { | |||
431 | field EXTREQLCK 0x10 /* External Request Lock */ | 455 | field EXTREQLCK 0x10 /* External Request Lock */ |
432 | field DISABLE_TWATE 0x02 /* Rev B or greater */ | 456 | field DISABLE_TWATE 0x02 /* Rev B or greater */ |
433 | field CIOPARCKEN 0x01 /* Internal bus parity error enable */ | 457 | field CIOPARCKEN 0x01 /* Internal bus parity error enable */ |
458 | dont_generate_debug_code | ||
434 | } | 459 | } |
435 | 460 | ||
436 | /* | 461 | /* |
@@ -459,6 +484,7 @@ register SG_CACHE_PRE { | |||
459 | field SG_ADDR_MASK 0xf8 | 484 | field SG_ADDR_MASK 0xf8 |
460 | field ODD_SEG 0x04 | 485 | field ODD_SEG 0x04 |
461 | field LAST_SEG 0x02 | 486 | field LAST_SEG 0x02 |
487 | dont_generate_debug_code | ||
462 | } | 488 | } |
463 | 489 | ||
464 | register SG_CACHE_SHADOW { | 490 | register SG_CACHE_SHADOW { |
@@ -491,6 +517,7 @@ register HADDR { | |||
491 | access_mode RW | 517 | access_mode RW |
492 | size 8 | 518 | size 8 |
493 | modes M_DFF0, M_DFF1 | 519 | modes M_DFF0, M_DFF1 |
520 | dont_generate_debug_code | ||
494 | } | 521 | } |
495 | 522 | ||
496 | /* | 523 | /* |
@@ -522,6 +549,7 @@ register HCNT { | |||
522 | access_mode RW | 549 | access_mode RW |
523 | size 3 | 550 | size 3 |
524 | modes M_DFF0, M_DFF1 | 551 | modes M_DFF0, M_DFF1 |
552 | dont_generate_debug_code | ||
525 | } | 553 | } |
526 | 554 | ||
527 | /* | 555 | /* |
@@ -551,6 +579,7 @@ register SGHADDR { | |||
551 | access_mode RW | 579 | access_mode RW |
552 | size 8 | 580 | size 8 |
553 | modes M_DFF0, M_DFF1 | 581 | modes M_DFF0, M_DFF1 |
582 | dont_generate_debug_code | ||
554 | } | 583 | } |
555 | 584 | ||
556 | /* | 585 | /* |
@@ -561,6 +590,7 @@ register SCBHADDR { | |||
561 | access_mode RW | 590 | access_mode RW |
562 | size 8 | 591 | size 8 |
563 | modes M_CCHAN | 592 | modes M_CCHAN |
593 | dont_generate_debug_code | ||
564 | } | 594 | } |
565 | 595 | ||
566 | /* | 596 | /* |
@@ -570,6 +600,7 @@ register SGHCNT { | |||
570 | address 0x084 | 600 | address 0x084 |
571 | access_mode RW | 601 | access_mode RW |
572 | modes M_DFF0, M_DFF1 | 602 | modes M_DFF0, M_DFF1 |
603 | dont_generate_debug_code | ||
573 | } | 604 | } |
574 | 605 | ||
575 | /* | 606 | /* |
@@ -579,6 +610,7 @@ register SCBHCNT { | |||
579 | address 0x084 | 610 | address 0x084 |
580 | access_mode RW | 611 | access_mode RW |
581 | modes M_CCHAN | 612 | modes M_CCHAN |
613 | dont_generate_debug_code | ||
582 | } | 614 | } |
583 | 615 | ||
584 | /* | 616 | /* |
@@ -609,6 +641,7 @@ register DFF_THRSH { | |||
609 | RD_DFTHRSH_90, | 641 | RD_DFTHRSH_90, |
610 | RD_DFTHRSH_MAX | 642 | RD_DFTHRSH_MAX |
611 | } | 643 | } |
644 | dont_generate_debug_code | ||
612 | } | 645 | } |
613 | 646 | ||
614 | /* | 647 | /* |
@@ -817,6 +850,7 @@ register PCIXCTL { | |||
817 | field SRSPDPEEN 0x04 | 850 | field SRSPDPEEN 0x04 |
818 | field TSCSERREN 0x02 | 851 | field TSCSERREN 0x02 |
819 | field CMPABCDIS 0x01 | 852 | field CMPABCDIS 0x01 |
853 | dont_generate_debug_code | ||
820 | } | 854 | } |
821 | 855 | ||
822 | /* | 856 | /* |
@@ -863,6 +897,7 @@ register DCHSPLTSTAT0 { | |||
863 | field RXOVRUN 0x04 | 897 | field RXOVRUN 0x04 |
864 | field RXSCEMSG 0x02 | 898 | field RXSCEMSG 0x02 |
865 | field RXSPLTRSP 0x01 | 899 | field RXSPLTRSP 0x01 |
900 | dont_generate_debug_code | ||
866 | } | 901 | } |
867 | 902 | ||
868 | /* | 903 | /* |
@@ -908,6 +943,7 @@ register DCHSPLTSTAT1 { | |||
908 | modes M_DFF0, M_DFF1 | 943 | modes M_DFF0, M_DFF1 |
909 | count 2 | 944 | count 2 |
910 | field RXDATABUCKET 0x01 | 945 | field RXDATABUCKET 0x01 |
946 | dont_generate_debug_code | ||
911 | } | 947 | } |
912 | 948 | ||
913 | /* | 949 | /* |
@@ -1069,6 +1105,7 @@ register SGSPLTSTAT0 { | |||
1069 | field RXOVRUN 0x04 | 1105 | field RXOVRUN 0x04 |
1070 | field RXSCEMSG 0x02 | 1106 | field RXSCEMSG 0x02 |
1071 | field RXSPLTRSP 0x01 | 1107 | field RXSPLTRSP 0x01 |
1108 | dont_generate_debug_code | ||
1072 | } | 1109 | } |
1073 | 1110 | ||
1074 | /* | 1111 | /* |
@@ -1080,6 +1117,7 @@ register SGSPLTSTAT1 { | |||
1080 | modes M_DFF0, M_DFF1 | 1117 | modes M_DFF0, M_DFF1 |
1081 | count 2 | 1118 | count 2 |
1082 | field RXDATABUCKET 0x01 | 1119 | field RXDATABUCKET 0x01 |
1120 | dont_generate_debug_code | ||
1083 | } | 1121 | } |
1084 | 1122 | ||
1085 | /* | 1123 | /* |
@@ -1091,6 +1129,7 @@ register SFUNCT { | |||
1091 | modes M_CFG | 1129 | modes M_CFG |
1092 | field TEST_GROUP 0xF0 | 1130 | field TEST_GROUP 0xF0 |
1093 | field TEST_NUM 0x0F | 1131 | field TEST_NUM 0x0F |
1132 | dont_generate_debug_code | ||
1094 | } | 1133 | } |
1095 | 1134 | ||
1096 | /* | 1135 | /* |
@@ -1109,6 +1148,7 @@ register DF0PCISTAT { | |||
1109 | field RDPERR 0x04 | 1148 | field RDPERR 0x04 |
1110 | field TWATERR 0x02 | 1149 | field TWATERR 0x02 |
1111 | field DPR 0x01 | 1150 | field DPR 0x01 |
1151 | dont_generate_debug_code | ||
1112 | } | 1152 | } |
1113 | 1153 | ||
1114 | /* | 1154 | /* |
@@ -1204,6 +1244,7 @@ register TARGPCISTAT { | |||
1204 | field SSE 0x40 | 1244 | field SSE 0x40 |
1205 | field STA 0x08 | 1245 | field STA 0x08 |
1206 | field TWATERR 0x02 | 1246 | field TWATERR 0x02 |
1247 | dont_generate_debug_code | ||
1207 | } | 1248 | } |
1208 | 1249 | ||
1209 | /* | 1250 | /* |
@@ -1216,6 +1257,7 @@ register LQIN { | |||
1216 | size 20 | 1257 | size 20 |
1217 | count 2 | 1258 | count 2 |
1218 | modes M_DFF0, M_DFF1, M_SCSI | 1259 | modes M_DFF0, M_DFF1, M_SCSI |
1260 | dont_generate_debug_code | ||
1219 | } | 1261 | } |
1220 | 1262 | ||
1221 | /* | 1263 | /* |
@@ -1247,6 +1289,7 @@ register LUNPTR { | |||
1247 | access_mode RW | 1289 | access_mode RW |
1248 | modes M_CFG | 1290 | modes M_CFG |
1249 | count 2 | 1291 | count 2 |
1292 | dont_generate_debug_code | ||
1250 | } | 1293 | } |
1251 | 1294 | ||
1252 | /* | 1295 | /* |
@@ -1278,6 +1321,7 @@ register CMDLENPTR { | |||
1278 | access_mode RW | 1321 | access_mode RW |
1279 | modes M_CFG | 1322 | modes M_CFG |
1280 | count 1 | 1323 | count 1 |
1324 | dont_generate_debug_code | ||
1281 | } | 1325 | } |
1282 | 1326 | ||
1283 | /* | 1327 | /* |
@@ -1290,6 +1334,7 @@ register ATTRPTR { | |||
1290 | access_mode RW | 1334 | access_mode RW |
1291 | modes M_CFG | 1335 | modes M_CFG |
1292 | count 1 | 1336 | count 1 |
1337 | dont_generate_debug_code | ||
1293 | } | 1338 | } |
1294 | 1339 | ||
1295 | /* | 1340 | /* |
@@ -1302,6 +1347,7 @@ register FLAGPTR { | |||
1302 | access_mode RW | 1347 | access_mode RW |
1303 | modes M_CFG | 1348 | modes M_CFG |
1304 | count 1 | 1349 | count 1 |
1350 | dont_generate_debug_code | ||
1305 | } | 1351 | } |
1306 | 1352 | ||
1307 | /* | 1353 | /* |
@@ -1313,6 +1359,7 @@ register CMDPTR { | |||
1313 | access_mode RW | 1359 | access_mode RW |
1314 | modes M_CFG | 1360 | modes M_CFG |
1315 | count 1 | 1361 | count 1 |
1362 | dont_generate_debug_code | ||
1316 | } | 1363 | } |
1317 | 1364 | ||
1318 | /* | 1365 | /* |
@@ -1324,6 +1371,7 @@ register QNEXTPTR { | |||
1324 | access_mode RW | 1371 | access_mode RW |
1325 | modes M_CFG | 1372 | modes M_CFG |
1326 | count 1 | 1373 | count 1 |
1374 | dont_generate_debug_code | ||
1327 | } | 1375 | } |
1328 | 1376 | ||
1329 | /* | 1377 | /* |
@@ -1347,6 +1395,7 @@ register ABRTBYTEPTR { | |||
1347 | access_mode RW | 1395 | access_mode RW |
1348 | modes M_CFG | 1396 | modes M_CFG |
1349 | count 1 | 1397 | count 1 |
1398 | dont_generate_debug_code | ||
1350 | } | 1399 | } |
1351 | 1400 | ||
1352 | /* | 1401 | /* |
@@ -1358,6 +1407,7 @@ register ABRTBITPTR { | |||
1358 | access_mode RW | 1407 | access_mode RW |
1359 | modes M_CFG | 1408 | modes M_CFG |
1360 | count 1 | 1409 | count 1 |
1410 | dont_generate_debug_code | ||
1361 | } | 1411 | } |
1362 | 1412 | ||
1363 | /* | 1413 | /* |
@@ -1398,6 +1448,7 @@ register LUNLEN { | |||
1398 | count 2 | 1448 | count 2 |
1399 | mask ILUNLEN 0x0F | 1449 | mask ILUNLEN 0x0F |
1400 | mask TLUNLEN 0xF0 | 1450 | mask TLUNLEN 0xF0 |
1451 | dont_generate_debug_code | ||
1401 | } | 1452 | } |
1402 | const LUNLEN_SINGLE_LEVEL_LUN 0xF | 1453 | const LUNLEN_SINGLE_LEVEL_LUN 0xF |
1403 | 1454 | ||
@@ -1410,6 +1461,7 @@ register CDBLIMIT { | |||
1410 | access_mode RW | 1461 | access_mode RW |
1411 | modes M_CFG | 1462 | modes M_CFG |
1412 | count 1 | 1463 | count 1 |
1464 | dont_generate_debug_code | ||
1413 | } | 1465 | } |
1414 | 1466 | ||
1415 | /* | 1467 | /* |
@@ -1422,6 +1474,7 @@ register MAXCMD { | |||
1422 | access_mode RW | 1474 | access_mode RW |
1423 | modes M_CFG | 1475 | modes M_CFG |
1424 | count 9 | 1476 | count 9 |
1477 | dont_generate_debug_code | ||
1425 | } | 1478 | } |
1426 | 1479 | ||
1427 | /* | 1480 | /* |
@@ -1432,6 +1485,7 @@ register MAXCMDCNT { | |||
1432 | address 0x033 | 1485 | address 0x033 |
1433 | access_mode RW | 1486 | access_mode RW |
1434 | modes M_CFG | 1487 | modes M_CFG |
1488 | dont_generate_debug_code | ||
1435 | } | 1489 | } |
1436 | 1490 | ||
1437 | /* | 1491 | /* |
@@ -1490,6 +1544,7 @@ register LQCTL1 { | |||
1490 | field PCI2PCI 0x04 | 1544 | field PCI2PCI 0x04 |
1491 | field SINGLECMD 0x02 | 1545 | field SINGLECMD 0x02 |
1492 | field ABORTPENDING 0x01 | 1546 | field ABORTPENDING 0x01 |
1547 | dont_generate_debug_code | ||
1493 | } | 1548 | } |
1494 | 1549 | ||
1495 | /* | 1550 | /* |
@@ -1508,6 +1563,7 @@ register LQCTL2 { | |||
1508 | field LQOCONTINUE 0x04 | 1563 | field LQOCONTINUE 0x04 |
1509 | field LQOTOIDLE 0x02 | 1564 | field LQOTOIDLE 0x02 |
1510 | field LQOPAUSE 0x01 | 1565 | field LQOPAUSE 0x01 |
1566 | dont_generate_debug_code | ||
1511 | } | 1567 | } |
1512 | 1568 | ||
1513 | /* | 1569 | /* |
@@ -1578,6 +1634,7 @@ register SXFRCTL0 { | |||
1578 | field DFPEXP 0x40 | 1634 | field DFPEXP 0x40 |
1579 | field BIOSCANCELEN 0x10 | 1635 | field BIOSCANCELEN 0x10 |
1580 | field SPIOEN 0x08 | 1636 | field SPIOEN 0x08 |
1637 | dont_generate_debug_code | ||
1581 | } | 1638 | } |
1582 | 1639 | ||
1583 | /* | 1640 | /* |
@@ -1594,6 +1651,7 @@ register SXFRCTL1 { | |||
1594 | field ENSTIMER 0x04 | 1651 | field ENSTIMER 0x04 |
1595 | field ACTNEGEN 0x02 | 1652 | field ACTNEGEN 0x02 |
1596 | field STPWEN 0x01 | 1653 | field STPWEN 0x01 |
1654 | dont_generate_debug_code | ||
1597 | } | 1655 | } |
1598 | 1656 | ||
1599 | /* | 1657 | /* |
@@ -1696,6 +1754,7 @@ register SCSISIGO { | |||
1696 | P_STATUS CDO|IOO, | 1754 | P_STATUS CDO|IOO, |
1697 | P_MESGIN CDO|IOO|MSGO | 1755 | P_MESGIN CDO|IOO|MSGO |
1698 | } | 1756 | } |
1757 | dont_generate_debug_code | ||
1699 | } | 1758 | } |
1700 | 1759 | ||
1701 | /* | 1760 | /* |
@@ -1738,6 +1797,7 @@ register MULTARGID { | |||
1738 | modes M_CFG | 1797 | modes M_CFG |
1739 | size 2 | 1798 | size 2 |
1740 | count 2 | 1799 | count 2 |
1800 | dont_generate_debug_code | ||
1741 | } | 1801 | } |
1742 | 1802 | ||
1743 | /* | 1803 | /* |
@@ -1774,6 +1834,7 @@ register SCSIDAT { | |||
1774 | access_mode RW | 1834 | access_mode RW |
1775 | modes M_DFF0, M_DFF1, M_SCSI | 1835 | modes M_DFF0, M_DFF1, M_SCSI |
1776 | size 2 | 1836 | size 2 |
1837 | dont_generate_debug_code | ||
1777 | } | 1838 | } |
1778 | 1839 | ||
1779 | /* | 1840 | /* |
@@ -1796,6 +1857,7 @@ register TARGIDIN { | |||
1796 | count 2 | 1857 | count 2 |
1797 | field CLKOUT 0x80 | 1858 | field CLKOUT 0x80 |
1798 | field TARGID 0x0F | 1859 | field TARGID 0x0F |
1860 | dont_generate_debug_code | ||
1799 | } | 1861 | } |
1800 | 1862 | ||
1801 | /* | 1863 | /* |
@@ -1825,6 +1887,7 @@ register SBLKCTL { | |||
1825 | field ENAB40 0x08 /* LVD transceiver active */ | 1887 | field ENAB40 0x08 /* LVD transceiver active */ |
1826 | field ENAB20 0x04 /* SE/HVD transceiver active */ | 1888 | field ENAB20 0x04 /* SE/HVD transceiver active */ |
1827 | field SELWIDE 0x02 | 1889 | field SELWIDE 0x02 |
1890 | dont_generate_debug_code | ||
1828 | } | 1891 | } |
1829 | 1892 | ||
1830 | /* | 1893 | /* |
@@ -1842,6 +1905,7 @@ register OPTIONMODE { | |||
1842 | field ENDGFORMCHK 0x04 | 1905 | field ENDGFORMCHK 0x04 |
1843 | field AUTO_MSGOUT_DE 0x02 | 1906 | field AUTO_MSGOUT_DE 0x02 |
1844 | mask OPTIONMODE_DEFAULTS AUTO_MSGOUT_DE | 1907 | mask OPTIONMODE_DEFAULTS AUTO_MSGOUT_DE |
1908 | dont_generate_debug_code | ||
1845 | } | 1909 | } |
1846 | 1910 | ||
1847 | /* | 1911 | /* |
@@ -1876,6 +1940,7 @@ register CLRSINT0 { | |||
1876 | field CLROVERRUN 0x04 | 1940 | field CLROVERRUN 0x04 |
1877 | field CLRSPIORDY 0x02 | 1941 | field CLRSPIORDY 0x02 |
1878 | field CLRARBDO 0x01 | 1942 | field CLRARBDO 0x01 |
1943 | dont_generate_debug_code | ||
1879 | } | 1944 | } |
1880 | 1945 | ||
1881 | /* | 1946 | /* |
@@ -1929,6 +1994,7 @@ register CLRSINT1 { | |||
1929 | field CLRSCSIPERR 0x04 | 1994 | field CLRSCSIPERR 0x04 |
1930 | field CLRSTRB2FAST 0x02 | 1995 | field CLRSTRB2FAST 0x02 |
1931 | field CLRREQINIT 0x01 | 1996 | field CLRREQINIT 0x01 |
1997 | dont_generate_debug_code | ||
1932 | } | 1998 | } |
1933 | 1999 | ||
1934 | /* | 2000 | /* |
@@ -1962,6 +2028,7 @@ register CLRSINT2 { | |||
1962 | field CLRWIDE_RES 0x04 /* Modes 0 and 1 only */ | 2028 | field CLRWIDE_RES 0x04 /* Modes 0 and 1 only */ |
1963 | field CLRSDONE 0x02 /* Modes 0 and 1 only */ | 2029 | field CLRSDONE 0x02 /* Modes 0 and 1 only */ |
1964 | field CLRDMADONE 0x01 /* Modes 0 and 1 only */ | 2030 | field CLRDMADONE 0x01 /* Modes 0 and 1 only */ |
2031 | dont_generate_debug_code | ||
1965 | } | 2032 | } |
1966 | 2033 | ||
1967 | /* | 2034 | /* |
@@ -2002,6 +2069,7 @@ register LQISTATE { | |||
2002 | access_mode RO | 2069 | access_mode RO |
2003 | modes M_CFG | 2070 | modes M_CFG |
2004 | count 6 | 2071 | count 6 |
2072 | dont_generate_debug_code | ||
2005 | } | 2073 | } |
2006 | 2074 | ||
2007 | /* | 2075 | /* |
@@ -2022,6 +2090,7 @@ register LQOSTATE { | |||
2022 | access_mode RO | 2090 | access_mode RO |
2023 | modes M_CFG | 2091 | modes M_CFG |
2024 | count 2 | 2092 | count 2 |
2093 | dont_generate_debug_code | ||
2025 | } | 2094 | } |
2026 | 2095 | ||
2027 | /* | 2096 | /* |
@@ -2054,6 +2123,7 @@ register CLRLQIINT0 { | |||
2054 | field CLRLQIBADLQT 0x04 | 2123 | field CLRLQIBADLQT 0x04 |
2055 | field CLRLQIATNLQ 0x02 | 2124 | field CLRLQIATNLQ 0x02 |
2056 | field CLRLQIATNCMD 0x01 | 2125 | field CLRLQIATNCMD 0x01 |
2126 | dont_generate_debug_code | ||
2057 | } | 2127 | } |
2058 | 2128 | ||
2059 | /* | 2129 | /* |
@@ -2070,6 +2140,7 @@ register LQIMODE0 { | |||
2070 | field ENLQIBADLQT 0x04 | 2140 | field ENLQIBADLQT 0x04 |
2071 | field ENLQIATNLQ 0x02 | 2141 | field ENLQIATNLQ 0x02 |
2072 | field ENLQIATNCMD 0x01 | 2142 | field ENLQIATNCMD 0x01 |
2143 | dont_generate_debug_code | ||
2073 | } | 2144 | } |
2074 | 2145 | ||
2075 | /* | 2146 | /* |
@@ -2106,6 +2177,7 @@ register CLRLQIINT1 { | |||
2106 | field CLRLQIBADLQI 0x04 | 2177 | field CLRLQIBADLQI 0x04 |
2107 | field CLRLQIOVERI_LQ 0x02 | 2178 | field CLRLQIOVERI_LQ 0x02 |
2108 | field CLRLQIOVERI_NLQ 0x01 | 2179 | field CLRLQIOVERI_NLQ 0x01 |
2180 | dont_generate_debug_code | ||
2109 | } | 2181 | } |
2110 | 2182 | ||
2111 | /* | 2183 | /* |
@@ -2124,6 +2196,7 @@ register LQIMODE1 { | |||
2124 | field ENLQIBADLQI 0x04 | 2196 | field ENLQIBADLQI 0x04 |
2125 | field ENLQIOVERI_LQ 0x02 /* LQIOVERI1 */ | 2197 | field ENLQIOVERI_LQ 0x02 /* LQIOVERI1 */ |
2126 | field ENLQIOVERI_NLQ 0x01 /* LQIOVERI2 */ | 2198 | field ENLQIOVERI_NLQ 0x01 /* LQIOVERI2 */ |
2199 | dont_generate_debug_code | ||
2127 | } | 2200 | } |
2128 | 2201 | ||
2129 | /* | 2202 | /* |
@@ -2165,6 +2238,7 @@ register CLRSINT3 { | |||
2165 | count 3 | 2238 | count 3 |
2166 | field CLRNTRAMPERR 0x02 | 2239 | field CLRNTRAMPERR 0x02 |
2167 | field CLROSRAMPERR 0x01 | 2240 | field CLROSRAMPERR 0x01 |
2241 | dont_generate_debug_code | ||
2168 | } | 2242 | } |
2169 | 2243 | ||
2170 | /* | 2244 | /* |
@@ -2177,6 +2251,7 @@ register SIMODE3 { | |||
2177 | count 4 | 2251 | count 4 |
2178 | field ENNTRAMPERR 0x02 | 2252 | field ENNTRAMPERR 0x02 |
2179 | field ENOSRAMPERR 0x01 | 2253 | field ENOSRAMPERR 0x01 |
2254 | dont_generate_debug_code | ||
2180 | } | 2255 | } |
2181 | 2256 | ||
2182 | /* | 2257 | /* |
@@ -2207,6 +2282,7 @@ register CLRLQOINT0 { | |||
2207 | field CLRLQOATNLQ 0x04 | 2282 | field CLRLQOATNLQ 0x04 |
2208 | field CLRLQOATNPKT 0x02 | 2283 | field CLRLQOATNPKT 0x02 |
2209 | field CLRLQOTCRC 0x01 | 2284 | field CLRLQOTCRC 0x01 |
2285 | dont_generate_debug_code | ||
2210 | } | 2286 | } |
2211 | 2287 | ||
2212 | /* | 2288 | /* |
@@ -2222,6 +2298,7 @@ register LQOMODE0 { | |||
2222 | field ENLQOATNLQ 0x04 | 2298 | field ENLQOATNLQ 0x04 |
2223 | field ENLQOATNPKT 0x02 | 2299 | field ENLQOATNPKT 0x02 |
2224 | field ENLQOTCRC 0x01 | 2300 | field ENLQOTCRC 0x01 |
2301 | dont_generate_debug_code | ||
2225 | } | 2302 | } |
2226 | 2303 | ||
2227 | /* | 2304 | /* |
@@ -2251,6 +2328,7 @@ register CLRLQOINT1 { | |||
2251 | field CLRLQOBADQAS 0x04 | 2328 | field CLRLQOBADQAS 0x04 |
2252 | field CLRLQOBUSFREE 0x02 | 2329 | field CLRLQOBUSFREE 0x02 |
2253 | field CLRLQOPHACHGINPKT 0x01 | 2330 | field CLRLQOPHACHGINPKT 0x01 |
2331 | dont_generate_debug_code | ||
2254 | } | 2332 | } |
2255 | 2333 | ||
2256 | /* | 2334 | /* |
@@ -2266,6 +2344,7 @@ register LQOMODE1 { | |||
2266 | field ENLQOBADQAS 0x04 | 2344 | field ENLQOBADQAS 0x04 |
2267 | field ENLQOBUSFREE 0x02 | 2345 | field ENLQOBUSFREE 0x02 |
2268 | field ENLQOPHACHGINPKT 0x01 | 2346 | field ENLQOPHACHGINPKT 0x01 |
2347 | dont_generate_debug_code | ||
2269 | } | 2348 | } |
2270 | 2349 | ||
2271 | /* | 2350 | /* |
@@ -2289,6 +2368,7 @@ register OS_SPACE_CNT { | |||
2289 | access_mode RO | 2368 | access_mode RO |
2290 | modes M_CFG | 2369 | modes M_CFG |
2291 | count 2 | 2370 | count 2 |
2371 | dont_generate_debug_code | ||
2292 | } | 2372 | } |
2293 | 2373 | ||
2294 | /* | 2374 | /* |
@@ -2318,6 +2398,7 @@ register GSFIFO { | |||
2318 | access_mode RO | 2398 | access_mode RO |
2319 | size 2 | 2399 | size 2 |
2320 | modes M_DFF0, M_DFF1, M_SCSI | 2400 | modes M_DFF0, M_DFF1, M_SCSI |
2401 | dont_generate_debug_code | ||
2321 | } | 2402 | } |
2322 | 2403 | ||
2323 | /* | 2404 | /* |
@@ -2341,6 +2422,7 @@ register NEXTSCB { | |||
2341 | access_mode RW | 2422 | access_mode RW |
2342 | size 2 | 2423 | size 2 |
2343 | modes M_SCSI | 2424 | modes M_SCSI |
2425 | dont_generate_debug_code | ||
2344 | } | 2426 | } |
2345 | 2427 | ||
2346 | /* | 2428 | /* |
@@ -2357,6 +2439,7 @@ register LQOSCSCTL { | |||
2357 | field LQOBUSETDLY 0x40 | 2439 | field LQOBUSETDLY 0x40 |
2358 | field LQONOHOLDLACK 0x02 | 2440 | field LQONOHOLDLACK 0x02 |
2359 | field LQONOCHKOVER 0x01 | 2441 | field LQONOCHKOVER 0x01 |
2442 | dont_generate_debug_code | ||
2360 | } | 2443 | } |
2361 | 2444 | ||
2362 | /* | 2445 | /* |
@@ -2389,6 +2472,7 @@ register CLRSEQINTSRC { | |||
2389 | field CLRCFG4TSTAT 0x04 | 2472 | field CLRCFG4TSTAT 0x04 |
2390 | field CLRCFG4ICMD 0x02 | 2473 | field CLRCFG4ICMD 0x02 |
2391 | field CLRCFG4TCMD 0x01 | 2474 | field CLRCFG4TCMD 0x01 |
2475 | dont_generate_debug_code | ||
2392 | } | 2476 | } |
2393 | 2477 | ||
2394 | /* | 2478 | /* |
@@ -2415,6 +2499,7 @@ register CURRSCB { | |||
2415 | access_mode RW | 2499 | access_mode RW |
2416 | size 2 | 2500 | size 2 |
2417 | modes M_SCSI | 2501 | modes M_SCSI |
2502 | dont_generate_debug_code | ||
2418 | } | 2503 | } |
2419 | 2504 | ||
2420 | /* | 2505 | /* |
@@ -2472,6 +2557,7 @@ register LASTSCB { | |||
2472 | access_mode RW | 2557 | access_mode RW |
2473 | size 2 | 2558 | size 2 |
2474 | modes M_SCSI | 2559 | modes M_SCSI |
2560 | dont_generate_debug_code | ||
2475 | } | 2561 | } |
2476 | 2562 | ||
2477 | /* | 2563 | /* |
@@ -2494,6 +2580,7 @@ register SHADDR { | |||
2494 | access_mode RO | 2580 | access_mode RO |
2495 | size 8 | 2581 | size 8 |
2496 | modes M_DFF0, M_DFF1 | 2582 | modes M_DFF0, M_DFF1 |
2583 | dont_generate_debug_code | ||
2497 | } | 2584 | } |
2498 | 2585 | ||
2499 | /* | 2586 | /* |
@@ -2513,6 +2600,7 @@ register NEGOADDR { | |||
2513 | address 0x060 | 2600 | address 0x060 |
2514 | access_mode RW | 2601 | access_mode RW |
2515 | modes M_SCSI | 2602 | modes M_SCSI |
2603 | dont_generate_debug_code | ||
2516 | } | 2604 | } |
2517 | 2605 | ||
2518 | /* | 2606 | /* |
@@ -2523,6 +2611,7 @@ register NEGPERIOD { | |||
2523 | access_mode RW | 2611 | access_mode RW |
2524 | modes M_SCSI | 2612 | modes M_SCSI |
2525 | count 1 | 2613 | count 1 |
2614 | dont_generate_debug_code | ||
2526 | } | 2615 | } |
2527 | 2616 | ||
2528 | /* | 2617 | /* |
@@ -2543,6 +2632,7 @@ register NEGOFFSET { | |||
2543 | access_mode RW | 2632 | access_mode RW |
2544 | modes M_SCSI | 2633 | modes M_SCSI |
2545 | count 1 | 2634 | count 1 |
2635 | dont_generate_debug_code | ||
2546 | } | 2636 | } |
2547 | 2637 | ||
2548 | /* | 2638 | /* |
@@ -2557,6 +2647,7 @@ register NEGPPROPTS { | |||
2557 | field PPROPT_QAS 0x04 | 2647 | field PPROPT_QAS 0x04 |
2558 | field PPROPT_DT 0x02 | 2648 | field PPROPT_DT 0x02 |
2559 | field PPROPT_IUT 0x01 | 2649 | field PPROPT_IUT 0x01 |
2650 | dont_generate_debug_code | ||
2560 | } | 2651 | } |
2561 | 2652 | ||
2562 | /* | 2653 | /* |
@@ -2573,6 +2664,7 @@ register NEGCONOPTS { | |||
2573 | field ENAUTOATNI 0x04 | 2664 | field ENAUTOATNI 0x04 |
2574 | field ENAUTOATNO 0x02 | 2665 | field ENAUTOATNO 0x02 |
2575 | field WIDEXFER 0x01 | 2666 | field WIDEXFER 0x01 |
2667 | dont_generate_debug_code | ||
2576 | } | 2668 | } |
2577 | 2669 | ||
2578 | /* | 2670 | /* |
@@ -2583,6 +2675,7 @@ register ANNEXCOL { | |||
2583 | access_mode RW | 2675 | access_mode RW |
2584 | modes M_SCSI | 2676 | modes M_SCSI |
2585 | count 7 | 2677 | count 7 |
2678 | dont_generate_debug_code | ||
2586 | } | 2679 | } |
2587 | 2680 | ||
2588 | /* | 2681 | /* |
@@ -2602,6 +2695,7 @@ register SCSCHKN { | |||
2602 | field DFFACTCLR 0x04 | 2695 | field DFFACTCLR 0x04 |
2603 | field SHVALIDSTDIS 0x02 | 2696 | field SHVALIDSTDIS 0x02 |
2604 | field LSTSGCLRDIS 0x01 | 2697 | field LSTSGCLRDIS 0x01 |
2698 | dont_generate_debug_code | ||
2605 | } | 2699 | } |
2606 | 2700 | ||
2607 | const AHD_ANNEXCOL_PER_DEV0 4 | 2701 | const AHD_ANNEXCOL_PER_DEV0 4 |
@@ -2635,6 +2729,7 @@ register ANNEXDAT { | |||
2635 | access_mode RW | 2729 | access_mode RW |
2636 | modes M_SCSI | 2730 | modes M_SCSI |
2637 | count 3 | 2731 | count 3 |
2732 | dont_generate_debug_code | ||
2638 | } | 2733 | } |
2639 | 2734 | ||
2640 | /* | 2735 | /* |
@@ -2645,6 +2740,7 @@ register IOWNID { | |||
2645 | address 0x067 | 2740 | address 0x067 |
2646 | access_mode RW | 2741 | access_mode RW |
2647 | modes M_SCSI | 2742 | modes M_SCSI |
2743 | dont_generate_debug_code | ||
2648 | } | 2744 | } |
2649 | 2745 | ||
2650 | /* | 2746 | /* |
@@ -2671,6 +2767,7 @@ register TOWNID { | |||
2671 | access_mode RW | 2767 | access_mode RW |
2672 | modes M_SCSI | 2768 | modes M_SCSI |
2673 | count 2 | 2769 | count 2 |
2770 | dont_generate_debug_code | ||
2674 | } | 2771 | } |
2675 | 2772 | ||
2676 | /* | 2773 | /* |
@@ -2702,6 +2799,7 @@ register SHCNT { | |||
2702 | access_mode RW | 2799 | access_mode RW |
2703 | size 3 | 2800 | size 3 |
2704 | modes M_DFF0, M_DFF1 | 2801 | modes M_DFF0, M_DFF1 |
2802 | dont_generate_debug_code | ||
2705 | } | 2803 | } |
2706 | 2804 | ||
2707 | /* | 2805 | /* |
@@ -2789,6 +2887,7 @@ register SCBPTR { | |||
2789 | access_mode RW | 2887 | access_mode RW |
2790 | size 2 | 2888 | size 2 |
2791 | modes M_DFF0, M_DFF1, M_CCHAN, M_SCSI | 2889 | modes M_DFF0, M_DFF1, M_CCHAN, M_SCSI |
2890 | dont_generate_debug_code | ||
2792 | } | 2891 | } |
2793 | 2892 | ||
2794 | /* | 2893 | /* |
@@ -2816,6 +2915,7 @@ register SCBAUTOPTR { | |||
2816 | field AUSCBPTR_EN 0x80 | 2915 | field AUSCBPTR_EN 0x80 |
2817 | field SCBPTR_ADDR 0x38 | 2916 | field SCBPTR_ADDR 0x38 |
2818 | field SCBPTR_OFF 0x07 | 2917 | field SCBPTR_OFF 0x07 |
2918 | dont_generate_debug_code | ||
2819 | } | 2919 | } |
2820 | 2920 | ||
2821 | /* | 2921 | /* |
@@ -2825,6 +2925,7 @@ register CCSGADDR { | |||
2825 | address 0x0AC | 2925 | address 0x0AC |
2826 | access_mode RW | 2926 | access_mode RW |
2827 | modes M_DFF0, M_DFF1 | 2927 | modes M_DFF0, M_DFF1 |
2928 | dont_generate_debug_code | ||
2828 | } | 2929 | } |
2829 | 2930 | ||
2830 | /* | 2931 | /* |
@@ -2834,6 +2935,7 @@ register CCSCBADDR { | |||
2834 | address 0x0AC | 2935 | address 0x0AC |
2835 | access_mode RW | 2936 | access_mode RW |
2836 | modes M_CCHAN | 2937 | modes M_CCHAN |
2938 | dont_generate_debug_code | ||
2837 | } | 2939 | } |
2838 | 2940 | ||
2839 | /* | 2941 | /* |
@@ -2899,6 +3001,7 @@ register CCSGRAM { | |||
2899 | address 0x0B0 | 3001 | address 0x0B0 |
2900 | access_mode RW | 3002 | access_mode RW |
2901 | modes M_DFF0, M_DFF1 | 3003 | modes M_DFF0, M_DFF1 |
3004 | dont_generate_debug_code | ||
2902 | } | 3005 | } |
2903 | 3006 | ||
2904 | /* | 3007 | /* |
@@ -2908,6 +3011,7 @@ register CCSCBRAM { | |||
2908 | address 0x0B0 | 3011 | address 0x0B0 |
2909 | access_mode RW | 3012 | access_mode RW |
2910 | modes M_CCHAN | 3013 | modes M_CCHAN |
3014 | dont_generate_debug_code | ||
2911 | } | 3015 | } |
2912 | 3016 | ||
2913 | /* | 3017 | /* |
@@ -2958,6 +3062,7 @@ register BRDDAT { | |||
2958 | access_mode RW | 3062 | access_mode RW |
2959 | modes M_SCSI | 3063 | modes M_SCSI |
2960 | count 2 | 3064 | count 2 |
3065 | dont_generate_debug_code | ||
2961 | } | 3066 | } |
2962 | 3067 | ||
2963 | /* | 3068 | /* |
@@ -2974,6 +3079,7 @@ register BRDCTL { | |||
2974 | field BRDEN 0x04 | 3079 | field BRDEN 0x04 |
2975 | field BRDRW 0x02 | 3080 | field BRDRW 0x02 |
2976 | field BRDSTB 0x01 | 3081 | field BRDSTB 0x01 |
3082 | dont_generate_debug_code | ||
2977 | } | 3083 | } |
2978 | 3084 | ||
2979 | /* | 3085 | /* |
@@ -2984,6 +3090,7 @@ register SEEADR { | |||
2984 | access_mode RW | 3090 | access_mode RW |
2985 | modes M_SCSI | 3091 | modes M_SCSI |
2986 | count 4 | 3092 | count 4 |
3093 | dont_generate_debug_code | ||
2987 | } | 3094 | } |
2988 | 3095 | ||
2989 | /* | 3096 | /* |
@@ -2995,6 +3102,7 @@ register SEEDAT { | |||
2995 | size 2 | 3102 | size 2 |
2996 | modes M_SCSI | 3103 | modes M_SCSI |
2997 | count 4 | 3104 | count 4 |
3105 | dont_generate_debug_code | ||
2998 | } | 3106 | } |
2999 | 3107 | ||
3000 | /* | 3108 | /* |
@@ -3011,6 +3119,7 @@ register SEESTAT { | |||
3011 | field SEEARBACK 0x04 | 3119 | field SEEARBACK 0x04 |
3012 | field SEEBUSY 0x02 | 3120 | field SEEBUSY 0x02 |
3013 | field SEESTART 0x01 | 3121 | field SEESTART 0x01 |
3122 | dont_generate_debug_code | ||
3014 | } | 3123 | } |
3015 | 3124 | ||
3016 | /* | 3125 | /* |
@@ -3036,6 +3145,7 @@ register SEECTL { | |||
3036 | mask SEEOP_EWDS 0x40 | 3145 | mask SEEOP_EWDS 0x40 |
3037 | field SEERST 0x02 | 3146 | field SEERST 0x02 |
3038 | field SEESTART 0x01 | 3147 | field SEESTART 0x01 |
3148 | dont_generate_debug_code | ||
3039 | } | 3149 | } |
3040 | 3150 | ||
3041 | const SEEOP_ERAL_ADDR 0x80 | 3151 | const SEEOP_ERAL_ADDR 0x80 |
@@ -3050,6 +3160,7 @@ register SCBCNT { | |||
3050 | address 0x0BF | 3160 | address 0x0BF |
3051 | access_mode RW | 3161 | access_mode RW |
3052 | modes M_SCSI | 3162 | modes M_SCSI |
3163 | dont_generate_debug_code | ||
3053 | } | 3164 | } |
3054 | 3165 | ||
3055 | /* | 3166 | /* |
@@ -3061,6 +3172,7 @@ register DFWADDR { | |||
3061 | access_mode RW | 3172 | access_mode RW |
3062 | size 2 | 3173 | size 2 |
3063 | modes M_DFF0, M_DFF1 | 3174 | modes M_DFF0, M_DFF1 |
3175 | dont_generate_debug_code | ||
3064 | } | 3176 | } |
3065 | 3177 | ||
3066 | /* | 3178 | /* |
@@ -3087,6 +3199,7 @@ register DSPDATACTL { | |||
3087 | field DESQDIS 0x10 | 3199 | field DESQDIS 0x10 |
3088 | field RCVROFFSTDIS 0x04 | 3200 | field RCVROFFSTDIS 0x04 |
3089 | field XMITOFFSTDIS 0x02 | 3201 | field XMITOFFSTDIS 0x02 |
3202 | dont_generate_debug_code | ||
3090 | } | 3203 | } |
3091 | 3204 | ||
3092 | /* | 3205 | /* |
@@ -3132,6 +3245,7 @@ register DFDAT { | |||
3132 | address 0x0C4 | 3245 | address 0x0C4 |
3133 | access_mode RW | 3246 | access_mode RW |
3134 | modes M_DFF0, M_DFF1 | 3247 | modes M_DFF0, M_DFF1 |
3248 | dont_generate_debug_code | ||
3135 | } | 3249 | } |
3136 | 3250 | ||
3137 | /* | 3251 | /* |
@@ -3144,6 +3258,7 @@ register DSPSELECT { | |||
3144 | count 1 | 3258 | count 1 |
3145 | field AUTOINCEN 0x80 | 3259 | field AUTOINCEN 0x80 |
3146 | field DSPSEL 0x1F | 3260 | field DSPSEL 0x1F |
3261 | dont_generate_debug_code | ||
3147 | } | 3262 | } |
3148 | 3263 | ||
3149 | const NUMDSPS 0x14 | 3264 | const NUMDSPS 0x14 |
@@ -3158,6 +3273,7 @@ register WRTBIASCTL { | |||
3158 | count 3 | 3273 | count 3 |
3159 | field AUTOXBCDIS 0x80 | 3274 | field AUTOXBCDIS 0x80 |
3160 | field XMITMANVAL 0x3F | 3275 | field XMITMANVAL 0x3F |
3276 | dont_generate_debug_code | ||
3161 | } | 3277 | } |
3162 | 3278 | ||
3163 | /* | 3279 | /* |
@@ -3316,6 +3432,7 @@ register FLAGS { | |||
3316 | count 23 | 3432 | count 23 |
3317 | field ZERO 0x02 | 3433 | field ZERO 0x02 |
3318 | field CARRY 0x01 | 3434 | field CARRY 0x01 |
3435 | dont_generate_debug_code | ||
3319 | } | 3436 | } |
3320 | 3437 | ||
3321 | /* | 3438 | /* |
@@ -3344,6 +3461,7 @@ register SEQRAM { | |||
3344 | address 0x0DA | 3461 | address 0x0DA |
3345 | access_mode RW | 3462 | access_mode RW |
3346 | count 2 | 3463 | count 2 |
3464 | dont_generate_debug_code | ||
3347 | } | 3465 | } |
3348 | 3466 | ||
3349 | /* | 3467 | /* |
@@ -3355,6 +3473,7 @@ register PRGMCNT { | |||
3355 | access_mode RW | 3473 | access_mode RW |
3356 | size 2 | 3474 | size 2 |
3357 | count 5 | 3475 | count 5 |
3476 | dont_generate_debug_code | ||
3358 | } | 3477 | } |
3359 | 3478 | ||
3360 | /* | 3479 | /* |
@@ -3364,6 +3483,7 @@ register ACCUM { | |||
3364 | address 0x0E0 | 3483 | address 0x0E0 |
3365 | access_mode RW | 3484 | access_mode RW |
3366 | accumulator | 3485 | accumulator |
3486 | dont_generate_debug_code | ||
3367 | } | 3487 | } |
3368 | 3488 | ||
3369 | /* | 3489 | /* |
@@ -3380,6 +3500,7 @@ register SINDEX { | |||
3380 | access_mode RW | 3500 | access_mode RW |
3381 | size 2 | 3501 | size 2 |
3382 | sindex | 3502 | sindex |
3503 | dont_generate_debug_code | ||
3383 | } | 3504 | } |
3384 | 3505 | ||
3385 | /* | 3506 | /* |
@@ -3390,6 +3511,7 @@ register DINDEX { | |||
3390 | address 0x0E4 | 3511 | address 0x0E4 |
3391 | access_mode RW | 3512 | access_mode RW |
3392 | size 2 | 3513 | size 2 |
3514 | dont_generate_debug_code | ||
3393 | } | 3515 | } |
3394 | 3516 | ||
3395 | /* | 3517 | /* |
@@ -3415,6 +3537,7 @@ register ALLONES { | |||
3415 | address 0x0E8 | 3537 | address 0x0E8 |
3416 | access_mode RO | 3538 | access_mode RO |
3417 | allones | 3539 | allones |
3540 | dont_generate_debug_code | ||
3418 | } | 3541 | } |
3419 | 3542 | ||
3420 | /* | 3543 | /* |
@@ -3425,6 +3548,7 @@ register ALLZEROS { | |||
3425 | address 0x0EA | 3548 | address 0x0EA |
3426 | access_mode RO | 3549 | access_mode RO |
3427 | allzeros | 3550 | allzeros |
3551 | dont_generate_debug_code | ||
3428 | } | 3552 | } |
3429 | 3553 | ||
3430 | /* | 3554 | /* |
@@ -3435,6 +3559,7 @@ register NONE { | |||
3435 | address 0x0EA | 3559 | address 0x0EA |
3436 | access_mode WO | 3560 | access_mode WO |
3437 | none | 3561 | none |
3562 | dont_generate_debug_code | ||
3438 | } | 3563 | } |
3439 | 3564 | ||
3440 | /* | 3565 | /* |
@@ -3445,6 +3570,7 @@ register NONE { | |||
3445 | register SINDIR { | 3570 | register SINDIR { |
3446 | address 0x0EC | 3571 | address 0x0EC |
3447 | access_mode RO | 3572 | access_mode RO |
3573 | dont_generate_debug_code | ||
3448 | } | 3574 | } |
3449 | 3575 | ||
3450 | /* | 3576 | /* |
@@ -3455,6 +3581,7 @@ register SINDIR { | |||
3455 | register DINDIR { | 3581 | register DINDIR { |
3456 | address 0x0ED | 3582 | address 0x0ED |
3457 | access_mode WO | 3583 | access_mode WO |
3584 | dont_generate_debug_code | ||
3458 | } | 3585 | } |
3459 | 3586 | ||
3460 | /* | 3587 | /* |
@@ -3479,6 +3606,7 @@ register FUNCTION1 { | |||
3479 | register STACK { | 3606 | register STACK { |
3480 | address 0x0F2 | 3607 | address 0x0F2 |
3481 | access_mode RW | 3608 | access_mode RW |
3609 | dont_generate_debug_code | ||
3482 | } | 3610 | } |
3483 | 3611 | ||
3484 | /* | 3612 | /* |
@@ -3491,6 +3619,7 @@ register INTVEC1_ADDR { | |||
3491 | size 2 | 3619 | size 2 |
3492 | modes M_CFG | 3620 | modes M_CFG |
3493 | count 1 | 3621 | count 1 |
3622 | dont_generate_debug_code | ||
3494 | } | 3623 | } |
3495 | 3624 | ||
3496 | /* | 3625 | /* |
@@ -3503,6 +3632,7 @@ register CURADDR { | |||
3503 | size 2 | 3632 | size 2 |
3504 | modes M_SCSI | 3633 | modes M_SCSI |
3505 | count 2 | 3634 | count 2 |
3635 | dont_generate_debug_code | ||
3506 | } | 3636 | } |
3507 | 3637 | ||
3508 | /* | 3638 | /* |
@@ -3515,6 +3645,7 @@ register INTVEC2_ADDR { | |||
3515 | size 2 | 3645 | size 2 |
3516 | modes M_CFG | 3646 | modes M_CFG |
3517 | count 1 | 3647 | count 1 |
3648 | dont_generate_debug_code | ||
3518 | } | 3649 | } |
3519 | 3650 | ||
3520 | /* | 3651 | /* |
@@ -3543,12 +3674,14 @@ scratch_ram { | |||
3543 | modes 0, 1, 2, 3 | 3674 | modes 0, 1, 2, 3 |
3544 | REG0 { | 3675 | REG0 { |
3545 | size 2 | 3676 | size 2 |
3677 | dont_generate_debug_code | ||
3546 | } | 3678 | } |
3547 | REG1 { | 3679 | REG1 { |
3548 | size 2 | 3680 | size 2 |
3549 | } | 3681 | } |
3550 | REG_ISR { | 3682 | REG_ISR { |
3551 | size 2 | 3683 | size 2 |
3684 | dont_generate_debug_code | ||
3552 | } | 3685 | } |
3553 | SG_STATE { | 3686 | SG_STATE { |
3554 | size 1 | 3687 | size 1 |
@@ -3572,9 +3705,11 @@ scratch_ram { | |||
3572 | modes 0, 1, 2, 3 | 3705 | modes 0, 1, 2, 3 |
3573 | LONGJMP_ADDR { | 3706 | LONGJMP_ADDR { |
3574 | size 2 | 3707 | size 2 |
3708 | dont_generate_debug_code | ||
3575 | } | 3709 | } |
3576 | ACCUM_SAVE { | 3710 | ACCUM_SAVE { |
3577 | size 1 | 3711 | size 1 |
3712 | dont_generate_debug_code | ||
3578 | } | 3713 | } |
3579 | } | 3714 | } |
3580 | 3715 | ||
@@ -3591,18 +3726,22 @@ scratch_ram { | |||
3591 | */ | 3726 | */ |
3592 | WAITING_SCB_TAILS { | 3727 | WAITING_SCB_TAILS { |
3593 | size 32 | 3728 | size 32 |
3729 | dont_generate_debug_code | ||
3594 | } | 3730 | } |
3595 | WAITING_TID_HEAD { | 3731 | WAITING_TID_HEAD { |
3596 | size 2 | 3732 | size 2 |
3733 | dont_generate_debug_code | ||
3597 | } | 3734 | } |
3598 | WAITING_TID_TAIL { | 3735 | WAITING_TID_TAIL { |
3599 | size 2 | 3736 | size 2 |
3737 | dont_generate_debug_code | ||
3600 | } | 3738 | } |
3601 | /* | 3739 | /* |
3602 | * SCBID of the next SCB in the new SCB queue. | 3740 | * SCBID of the next SCB in the new SCB queue. |
3603 | */ | 3741 | */ |
3604 | NEXT_QUEUED_SCB_ADDR { | 3742 | NEXT_QUEUED_SCB_ADDR { |
3605 | size 4 | 3743 | size 4 |
3744 | dont_generate_debug_code | ||
3606 | } | 3745 | } |
3607 | /* | 3746 | /* |
3608 | * head of list of SCBs that have | 3747 | * head of list of SCBs that have |
@@ -3611,6 +3750,7 @@ scratch_ram { | |||
3611 | */ | 3750 | */ |
3612 | COMPLETE_SCB_HEAD { | 3751 | COMPLETE_SCB_HEAD { |
3613 | size 2 | 3752 | size 2 |
3753 | dont_generate_debug_code | ||
3614 | } | 3754 | } |
3615 | /* | 3755 | /* |
3616 | * The list of completed SCBs in | 3756 | * The list of completed SCBs in |
@@ -3618,6 +3758,7 @@ scratch_ram { | |||
3618 | */ | 3758 | */ |
3619 | COMPLETE_SCB_DMAINPROG_HEAD { | 3759 | COMPLETE_SCB_DMAINPROG_HEAD { |
3620 | size 2 | 3760 | size 2 |
3761 | dont_generate_debug_code | ||
3621 | } | 3762 | } |
3622 | /* | 3763 | /* |
3623 | * head of list of SCBs that have | 3764 | * head of list of SCBs that have |
@@ -3626,6 +3767,7 @@ scratch_ram { | |||
3626 | */ | 3767 | */ |
3627 | COMPLETE_DMA_SCB_HEAD { | 3768 | COMPLETE_DMA_SCB_HEAD { |
3628 | size 2 | 3769 | size 2 |
3770 | dont_generate_debug_code | ||
3629 | } | 3771 | } |
3630 | /* | 3772 | /* |
3631 | * tail of list of SCBs that have | 3773 | * tail of list of SCBs that have |
@@ -3634,6 +3776,7 @@ scratch_ram { | |||
3634 | */ | 3776 | */ |
3635 | COMPLETE_DMA_SCB_TAIL { | 3777 | COMPLETE_DMA_SCB_TAIL { |
3636 | size 2 | 3778 | size 2 |
3779 | dont_generate_debug_code | ||
3637 | } | 3780 | } |
3638 | /* | 3781 | /* |
3639 | * head of list of SCBs that have | 3782 | * head of list of SCBs that have |
@@ -3643,6 +3786,7 @@ scratch_ram { | |||
3643 | */ | 3786 | */ |
3644 | COMPLETE_ON_QFREEZE_HEAD { | 3787 | COMPLETE_ON_QFREEZE_HEAD { |
3645 | size 2 | 3788 | size 2 |
3789 | dont_generate_debug_code | ||
3646 | } | 3790 | } |
3647 | /* | 3791 | /* |
3648 | * Counting semaphore to prevent new select-outs | 3792 | * Counting semaphore to prevent new select-outs |
@@ -3667,6 +3811,7 @@ scratch_ram { | |||
3667 | */ | 3811 | */ |
3668 | MSG_OUT { | 3812 | MSG_OUT { |
3669 | size 1 | 3813 | size 1 |
3814 | dont_generate_debug_code | ||
3670 | } | 3815 | } |
3671 | /* Parameters for DMA Logic */ | 3816 | /* Parameters for DMA Logic */ |
3672 | DMAPARAMS { | 3817 | DMAPARAMS { |
@@ -3682,6 +3827,7 @@ scratch_ram { | |||
3682 | field DIRECTION 0x04 /* Set indicates PCI->SCSI */ | 3827 | field DIRECTION 0x04 /* Set indicates PCI->SCSI */ |
3683 | field FIFOFLUSH 0x02 | 3828 | field FIFOFLUSH 0x02 |
3684 | field FIFORESET 0x01 | 3829 | field FIFORESET 0x01 |
3830 | dont_generate_debug_code | ||
3685 | } | 3831 | } |
3686 | SEQ_FLAGS { | 3832 | SEQ_FLAGS { |
3687 | size 1 | 3833 | size 1 |
@@ -3703,9 +3849,11 @@ scratch_ram { | |||
3703 | */ | 3849 | */ |
3704 | SAVED_SCSIID { | 3850 | SAVED_SCSIID { |
3705 | size 1 | 3851 | size 1 |
3852 | dont_generate_debug_code | ||
3706 | } | 3853 | } |
3707 | SAVED_LUN { | 3854 | SAVED_LUN { |
3708 | size 1 | 3855 | size 1 |
3856 | dont_generate_debug_code | ||
3709 | } | 3857 | } |
3710 | /* | 3858 | /* |
3711 | * The last bus phase as seen by the sequencer. | 3859 | * The last bus phase as seen by the sequencer. |
@@ -3733,6 +3881,7 @@ scratch_ram { | |||
3733 | */ | 3881 | */ |
3734 | QOUTFIFO_ENTRY_VALID_TAG { | 3882 | QOUTFIFO_ENTRY_VALID_TAG { |
3735 | size 1 | 3883 | size 1 |
3884 | dont_generate_debug_code | ||
3736 | } | 3885 | } |
3737 | /* | 3886 | /* |
3738 | * Kernel and sequencer offsets into the queue of | 3887 | * Kernel and sequencer offsets into the queue of |
@@ -3742,10 +3891,12 @@ scratch_ram { | |||
3742 | KERNEL_TQINPOS { | 3891 | KERNEL_TQINPOS { |
3743 | size 1 | 3892 | size 1 |
3744 | count 1 | 3893 | count 1 |
3894 | dont_generate_debug_code | ||
3745 | } | 3895 | } |
3746 | TQINPOS { | 3896 | TQINPOS { |
3747 | size 1 | 3897 | size 1 |
3748 | count 8 | 3898 | count 8 |
3899 | dont_generate_debug_code | ||
3749 | } | 3900 | } |
3750 | /* | 3901 | /* |
3751 | * Base address of our shared data with the kernel driver in host | 3902 | * Base address of our shared data with the kernel driver in host |
@@ -3754,6 +3905,7 @@ scratch_ram { | |||
3754 | */ | 3905 | */ |
3755 | SHARED_DATA_ADDR { | 3906 | SHARED_DATA_ADDR { |
3756 | size 4 | 3907 | size 4 |
3908 | dont_generate_debug_code | ||
3757 | } | 3909 | } |
3758 | /* | 3910 | /* |
3759 | * Pointer to location in host memory for next | 3911 | * Pointer to location in host memory for next |
@@ -3761,6 +3913,7 @@ scratch_ram { | |||
3761 | */ | 3913 | */ |
3762 | QOUTFIFO_NEXT_ADDR { | 3914 | QOUTFIFO_NEXT_ADDR { |
3763 | size 4 | 3915 | size 4 |
3916 | dont_generate_debug_code | ||
3764 | } | 3917 | } |
3765 | ARG_1 { | 3918 | ARG_1 { |
3766 | size 1 | 3919 | size 1 |
@@ -3773,11 +3926,13 @@ scratch_ram { | |||
3773 | mask CONT_MSG_LOOP_READ 0x03 | 3926 | mask CONT_MSG_LOOP_READ 0x03 |
3774 | mask CONT_MSG_LOOP_TARG 0x02 | 3927 | mask CONT_MSG_LOOP_TARG 0x02 |
3775 | alias RETURN_1 | 3928 | alias RETURN_1 |
3929 | dont_generate_debug_code | ||
3776 | } | 3930 | } |
3777 | ARG_2 { | 3931 | ARG_2 { |
3778 | size 1 | 3932 | size 1 |
3779 | count 1 | 3933 | count 1 |
3780 | alias RETURN_2 | 3934 | alias RETURN_2 |
3935 | dont_generate_debug_code | ||
3781 | } | 3936 | } |
3782 | 3937 | ||
3783 | /* | 3938 | /* |
@@ -3785,6 +3940,7 @@ scratch_ram { | |||
3785 | */ | 3940 | */ |
3786 | LAST_MSG { | 3941 | LAST_MSG { |
3787 | size 1 | 3942 | size 1 |
3943 | dont_generate_debug_code | ||
3788 | } | 3944 | } |
3789 | 3945 | ||
3790 | /* | 3946 | /* |
@@ -3801,6 +3957,7 @@ scratch_ram { | |||
3801 | field MANUALP 0x0C | 3957 | field MANUALP 0x0C |
3802 | field ENAUTOATNP 0x02 | 3958 | field ENAUTOATNP 0x02 |
3803 | field ALTSTIM 0x01 | 3959 | field ALTSTIM 0x01 |
3960 | dont_generate_debug_code | ||
3804 | } | 3961 | } |
3805 | 3962 | ||
3806 | /* | 3963 | /* |
@@ -3809,6 +3966,7 @@ scratch_ram { | |||
3809 | INITIATOR_TAG { | 3966 | INITIATOR_TAG { |
3810 | size 1 | 3967 | size 1 |
3811 | count 1 | 3968 | count 1 |
3969 | dont_generate_debug_code | ||
3812 | } | 3970 | } |
3813 | 3971 | ||
3814 | SEQ_FLAGS2 { | 3972 | SEQ_FLAGS2 { |
@@ -3820,6 +3978,7 @@ scratch_ram { | |||
3820 | 3978 | ||
3821 | ALLOCFIFO_SCBPTR { | 3979 | ALLOCFIFO_SCBPTR { |
3822 | size 2 | 3980 | size 2 |
3981 | dont_generate_debug_code | ||
3823 | } | 3982 | } |
3824 | 3983 | ||
3825 | /* | 3984 | /* |
@@ -3829,6 +3988,7 @@ scratch_ram { | |||
3829 | */ | 3988 | */ |
3830 | INT_COALESCING_TIMER { | 3989 | INT_COALESCING_TIMER { |
3831 | size 2 | 3990 | size 2 |
3991 | dont_generate_debug_code | ||
3832 | } | 3992 | } |
3833 | 3993 | ||
3834 | /* | 3994 | /* |
@@ -3838,6 +3998,7 @@ scratch_ram { | |||
3838 | */ | 3998 | */ |
3839 | INT_COALESCING_MAXCMDS { | 3999 | INT_COALESCING_MAXCMDS { |
3840 | size 1 | 4000 | size 1 |
4001 | dont_generate_debug_code | ||
3841 | } | 4002 | } |
3842 | 4003 | ||
3843 | /* | 4004 | /* |
@@ -3846,6 +4007,7 @@ scratch_ram { | |||
3846 | */ | 4007 | */ |
3847 | INT_COALESCING_MINCMDS { | 4008 | INT_COALESCING_MINCMDS { |
3848 | size 1 | 4009 | size 1 |
4010 | dont_generate_debug_code | ||
3849 | } | 4011 | } |
3850 | 4012 | ||
3851 | /* | 4013 | /* |
@@ -3853,6 +4015,7 @@ scratch_ram { | |||
3853 | */ | 4015 | */ |
3854 | CMDS_PENDING { | 4016 | CMDS_PENDING { |
3855 | size 2 | 4017 | size 2 |
4018 | dont_generate_debug_code | ||
3856 | } | 4019 | } |
3857 | 4020 | ||
3858 | /* | 4021 | /* |
@@ -3860,6 +4023,7 @@ scratch_ram { | |||
3860 | */ | 4023 | */ |
3861 | INT_COALESCING_CMDCOUNT { | 4024 | INT_COALESCING_CMDCOUNT { |
3862 | size 1 | 4025 | size 1 |
4026 | dont_generate_debug_code | ||
3863 | } | 4027 | } |
3864 | 4028 | ||
3865 | /* | 4029 | /* |
@@ -3868,6 +4032,7 @@ scratch_ram { | |||
3868 | */ | 4032 | */ |
3869 | LOCAL_HS_MAILBOX { | 4033 | LOCAL_HS_MAILBOX { |
3870 | size 1 | 4034 | size 1 |
4035 | dont_generate_debug_code | ||
3871 | } | 4036 | } |
3872 | /* | 4037 | /* |
3873 | * Target-mode CDB type to CDB length table used | 4038 | * Target-mode CDB type to CDB length table used |
@@ -3876,6 +4041,7 @@ scratch_ram { | |||
3876 | CMDSIZE_TABLE { | 4041 | CMDSIZE_TABLE { |
3877 | size 8 | 4042 | size 8 |
3878 | count 8 | 4043 | count 8 |
4044 | dont_generate_debug_code | ||
3879 | } | 4045 | } |
3880 | /* | 4046 | /* |
3881 | * When an SCB with the MK_MESSAGE flag is | 4047 | * When an SCB with the MK_MESSAGE flag is |
@@ -3908,25 +4074,31 @@ scb { | |||
3908 | size 4 | 4074 | size 4 |
3909 | alias SCB_CDB_STORE | 4075 | alias SCB_CDB_STORE |
3910 | alias SCB_HOST_CDB_PTR | 4076 | alias SCB_HOST_CDB_PTR |
4077 | dont_generate_debug_code | ||
3911 | } | 4078 | } |
3912 | SCB_RESIDUAL_SGPTR { | 4079 | SCB_RESIDUAL_SGPTR { |
3913 | size 4 | 4080 | size 4 |
3914 | field SG_ADDR_MASK 0xf8 /* In the last byte */ | 4081 | field SG_ADDR_MASK 0xf8 /* In the last byte */ |
3915 | field SG_OVERRUN_RESID 0x02 /* In the first byte */ | 4082 | field SG_OVERRUN_RESID 0x02 /* In the first byte */ |
3916 | field SG_LIST_NULL 0x01 /* In the first byte */ | 4083 | field SG_LIST_NULL 0x01 /* In the first byte */ |
4084 | dont_generate_debug_code | ||
3917 | } | 4085 | } |
3918 | SCB_SCSI_STATUS { | 4086 | SCB_SCSI_STATUS { |
3919 | size 1 | 4087 | size 1 |
3920 | alias SCB_HOST_CDB_LEN | 4088 | alias SCB_HOST_CDB_LEN |
4089 | dont_generate_debug_code | ||
3921 | } | 4090 | } |
3922 | SCB_TARGET_PHASES { | 4091 | SCB_TARGET_PHASES { |
3923 | size 1 | 4092 | size 1 |
4093 | dont_generate_debug_code | ||
3924 | } | 4094 | } |
3925 | SCB_TARGET_DATA_DIR { | 4095 | SCB_TARGET_DATA_DIR { |
3926 | size 1 | 4096 | size 1 |
4097 | dont_generate_debug_code | ||
3927 | } | 4098 | } |
3928 | SCB_TARGET_ITAG { | 4099 | SCB_TARGET_ITAG { |
3929 | size 1 | 4100 | size 1 |
4101 | dont_generate_debug_code | ||
3930 | } | 4102 | } |
3931 | SCB_SENSE_BUSADDR { | 4103 | SCB_SENSE_BUSADDR { |
3932 | /* | 4104 | /* |
@@ -3936,10 +4108,12 @@ scb { | |||
3936 | */ | 4108 | */ |
3937 | size 4 | 4109 | size 4 |
3938 | alias SCB_NEXT_COMPLETE | 4110 | alias SCB_NEXT_COMPLETE |
4111 | dont_generate_debug_code | ||
3939 | } | 4112 | } |
3940 | SCB_TAG { | 4113 | SCB_TAG { |
3941 | alias SCB_FIFO_USE_COUNT | 4114 | alias SCB_FIFO_USE_COUNT |
3942 | size 2 | 4115 | size 2 |
4116 | dont_generate_debug_code | ||
3943 | } | 4117 | } |
3944 | SCB_CONTROL { | 4118 | SCB_CONTROL { |
3945 | size 1 | 4119 | size 1 |
@@ -3959,6 +4133,7 @@ scb { | |||
3959 | SCB_LUN { | 4133 | SCB_LUN { |
3960 | size 1 | 4134 | size 1 |
3961 | field LID 0xff | 4135 | field LID 0xff |
4136 | dont_generate_debug_code | ||
3962 | } | 4137 | } |
3963 | SCB_TASK_ATTRIBUTE { | 4138 | SCB_TASK_ATTRIBUTE { |
3964 | size 1 | 4139 | size 1 |
@@ -3967,16 +4142,20 @@ scb { | |||
3967 | * ignore wide residue message handling. | 4142 | * ignore wide residue message handling. |
3968 | */ | 4143 | */ |
3969 | field SCB_XFERLEN_ODD 0x01 | 4144 | field SCB_XFERLEN_ODD 0x01 |
4145 | dont_generate_debug_code | ||
3970 | } | 4146 | } |
3971 | SCB_CDB_LEN { | 4147 | SCB_CDB_LEN { |
3972 | size 1 | 4148 | size 1 |
3973 | field SCB_CDB_LEN_PTR 0x80 /* CDB in host memory */ | 4149 | field SCB_CDB_LEN_PTR 0x80 /* CDB in host memory */ |
4150 | dont_generate_debug_code | ||
3974 | } | 4151 | } |
3975 | SCB_TASK_MANAGEMENT { | 4152 | SCB_TASK_MANAGEMENT { |
3976 | size 1 | 4153 | size 1 |
4154 | dont_generate_debug_code | ||
3977 | } | 4155 | } |
3978 | SCB_DATAPTR { | 4156 | SCB_DATAPTR { |
3979 | size 8 | 4157 | size 8 |
4158 | dont_generate_debug_code | ||
3980 | } | 4159 | } |
3981 | SCB_DATACNT { | 4160 | SCB_DATACNT { |
3982 | /* | 4161 | /* |
@@ -3986,22 +4165,27 @@ scb { | |||
3986 | size 4 | 4165 | size 4 |
3987 | field SG_LAST_SEG 0x80 /* In the fourth byte */ | 4166 | field SG_LAST_SEG 0x80 /* In the fourth byte */ |
3988 | field SG_HIGH_ADDR_BITS 0x7F /* In the fourth byte */ | 4167 | field SG_HIGH_ADDR_BITS 0x7F /* In the fourth byte */ |
4168 | dont_generate_debug_code | ||
3989 | } | 4169 | } |
3990 | SCB_SGPTR { | 4170 | SCB_SGPTR { |
3991 | size 4 | 4171 | size 4 |
3992 | field SG_STATUS_VALID 0x04 /* In the first byte */ | 4172 | field SG_STATUS_VALID 0x04 /* In the first byte */ |
3993 | field SG_FULL_RESID 0x02 /* In the first byte */ | 4173 | field SG_FULL_RESID 0x02 /* In the first byte */ |
3994 | field SG_LIST_NULL 0x01 /* In the first byte */ | 4174 | field SG_LIST_NULL 0x01 /* In the first byte */ |
4175 | dont_generate_debug_code | ||
3995 | } | 4176 | } |
3996 | SCB_BUSADDR { | 4177 | SCB_BUSADDR { |
3997 | size 4 | 4178 | size 4 |
4179 | dont_generate_debug_code | ||
3998 | } | 4180 | } |
3999 | SCB_NEXT { | 4181 | SCB_NEXT { |
4000 | alias SCB_NEXT_SCB_BUSADDR | 4182 | alias SCB_NEXT_SCB_BUSADDR |
4001 | size 2 | 4183 | size 2 |
4184 | dont_generate_debug_code | ||
4002 | } | 4185 | } |
4003 | SCB_NEXT2 { | 4186 | SCB_NEXT2 { |
4004 | size 2 | 4187 | size 2 |
4188 | dont_generate_debug_code | ||
4005 | } | 4189 | } |
4006 | SCB_SPARE { | 4190 | SCB_SPARE { |
4007 | size 8 | 4191 | size 8 |
@@ -4009,6 +4193,7 @@ scb { | |||
4009 | } | 4193 | } |
4010 | SCB_DISCONNECTED_LISTS { | 4194 | SCB_DISCONNECTED_LISTS { |
4011 | size 8 | 4195 | size 8 |
4196 | dont_generate_debug_code | ||
4012 | } | 4197 | } |
4013 | } | 4198 | } |
4014 | 4199 | ||
diff --git a/drivers/scsi/aic7xxx/aic79xx_core.c b/drivers/scsi/aic7xxx/aic79xx_core.c index 55508b0fcec4..bdad54ec088c 100644 --- a/drivers/scsi/aic7xxx/aic79xx_core.c +++ b/drivers/scsi/aic7xxx/aic79xx_core.c | |||
@@ -2472,8 +2472,6 @@ ahd_handle_scsiint(struct ahd_softc *ahd, u_int intstat) | |||
2472 | if ((ahd->bugs & AHD_CLRLQO_AUTOCLR_BUG) != 0) | 2472 | if ((ahd->bugs & AHD_CLRLQO_AUTOCLR_BUG) != 0) |
2473 | ahd_outb(ahd, CLRLQOINT1, 0); | 2473 | ahd_outb(ahd, CLRLQOINT1, 0); |
2474 | } else if ((status & SELTO) != 0) { | 2474 | } else if ((status & SELTO) != 0) { |
2475 | u_int scbid; | ||
2476 | |||
2477 | /* Stop the selection */ | 2475 | /* Stop the selection */ |
2478 | ahd_outb(ahd, SCSISEQ0, 0); | 2476 | ahd_outb(ahd, SCSISEQ0, 0); |
2479 | 2477 | ||
@@ -2583,9 +2581,6 @@ ahd_handle_scsiint(struct ahd_softc *ahd, u_int intstat) | |||
2583 | case BUSFREE_DFF0: | 2581 | case BUSFREE_DFF0: |
2584 | case BUSFREE_DFF1: | 2582 | case BUSFREE_DFF1: |
2585 | { | 2583 | { |
2586 | u_int scbid; | ||
2587 | struct scb *scb; | ||
2588 | |||
2589 | mode = busfreetime == BUSFREE_DFF0 | 2584 | mode = busfreetime == BUSFREE_DFF0 |
2590 | ? AHD_MODE_DFF0 : AHD_MODE_DFF1; | 2585 | ? AHD_MODE_DFF0 : AHD_MODE_DFF1; |
2591 | ahd_set_modes(ahd, mode, mode); | 2586 | ahd_set_modes(ahd, mode, mode); |
@@ -3689,7 +3684,7 @@ ahd_free_tstate(struct ahd_softc *ahd, u_int scsi_id, char channel, int force) | |||
3689 | * by the capabilities of the bus connectivity of and sync settings for | 3684 | * by the capabilities of the bus connectivity of and sync settings for |
3690 | * the target. | 3685 | * the target. |
3691 | */ | 3686 | */ |
3692 | void | 3687 | static void |
3693 | ahd_devlimited_syncrate(struct ahd_softc *ahd, | 3688 | ahd_devlimited_syncrate(struct ahd_softc *ahd, |
3694 | struct ahd_initiator_tinfo *tinfo, | 3689 | struct ahd_initiator_tinfo *tinfo, |
3695 | u_int *period, u_int *ppr_options, role_t role) | 3690 | u_int *period, u_int *ppr_options, role_t role) |
@@ -4136,7 +4131,7 @@ ahd_update_neg_table(struct ahd_softc *ahd, struct ahd_devinfo *devinfo, | |||
4136 | 4131 | ||
4137 | /* | 4132 | /* |
4138 | * Harpoon2A assumed that there would be a | 4133 | * Harpoon2A assumed that there would be a |
4139 | * fallback rate between 160MHz and 80Mhz, | 4134 | * fallback rate between 160MHz and 80MHz, |
4140 | * so 7 is used as the period factor rather | 4135 | * so 7 is used as the period factor rather |
4141 | * than 8 for 160MHz. | 4136 | * than 8 for 160MHz. |
4142 | */ | 4137 | */ |
@@ -8708,7 +8703,7 @@ ahd_reset_current_bus(struct ahd_softc *ahd) | |||
8708 | int | 8703 | int |
8709 | ahd_reset_channel(struct ahd_softc *ahd, char channel, int initiate_reset) | 8704 | ahd_reset_channel(struct ahd_softc *ahd, char channel, int initiate_reset) |
8710 | { | 8705 | { |
8711 | struct ahd_devinfo devinfo; | 8706 | struct ahd_devinfo caminfo; |
8712 | u_int initiator; | 8707 | u_int initiator; |
8713 | u_int target; | 8708 | u_int target; |
8714 | u_int max_scsiid; | 8709 | u_int max_scsiid; |
@@ -8729,7 +8724,7 @@ ahd_reset_channel(struct ahd_softc *ahd, char channel, int initiate_reset) | |||
8729 | 8724 | ||
8730 | ahd->pending_device = NULL; | 8725 | ahd->pending_device = NULL; |
8731 | 8726 | ||
8732 | ahd_compile_devinfo(&devinfo, | 8727 | ahd_compile_devinfo(&caminfo, |
8733 | CAM_TARGET_WILDCARD, | 8728 | CAM_TARGET_WILDCARD, |
8734 | CAM_TARGET_WILDCARD, | 8729 | CAM_TARGET_WILDCARD, |
8735 | CAM_LUN_WILDCARD, | 8730 | CAM_LUN_WILDCARD, |
@@ -8868,7 +8863,7 @@ ahd_reset_channel(struct ahd_softc *ahd, char channel, int initiate_reset) | |||
8868 | } | 8863 | } |
8869 | 8864 | ||
8870 | /* Notify the XPT that a bus reset occurred */ | 8865 | /* Notify the XPT that a bus reset occurred */ |
8871 | ahd_send_async(ahd, devinfo.channel, CAM_TARGET_WILDCARD, | 8866 | ahd_send_async(ahd, caminfo.channel, CAM_TARGET_WILDCARD, |
8872 | CAM_LUN_WILDCARD, AC_BUS_RESET); | 8867 | CAM_LUN_WILDCARD, AC_BUS_RESET); |
8873 | 8868 | ||
8874 | ahd_restart(ahd); | 8869 | ahd_restart(ahd); |
diff --git a/drivers/scsi/aic7xxx/aic79xx_pci.c b/drivers/scsi/aic7xxx/aic79xx_pci.c index c25b6adffbf9..a734d77e880e 100644 --- a/drivers/scsi/aic7xxx/aic79xx_pci.c +++ b/drivers/scsi/aic7xxx/aic79xx_pci.c | |||
@@ -223,10 +223,10 @@ static const char *pci_bus_modes[] = | |||
223 | "PCI bus mode unknown", | 223 | "PCI bus mode unknown", |
224 | "PCI bus mode unknown", | 224 | "PCI bus mode unknown", |
225 | "PCI bus mode unknown", | 225 | "PCI bus mode unknown", |
226 | "PCI-X 101-133Mhz", | 226 | "PCI-X 101-133MHz", |
227 | "PCI-X 67-100Mhz", | 227 | "PCI-X 67-100MHz", |
228 | "PCI-X 50-66Mhz", | 228 | "PCI-X 50-66MHz", |
229 | "PCI 33 or 66Mhz" | 229 | "PCI 33 or 66MHz" |
230 | }; | 230 | }; |
231 | 231 | ||
232 | #define TESTMODE 0x00000800ul | 232 | #define TESTMODE 0x00000800ul |
@@ -337,8 +337,6 @@ ahd_pci_config(struct ahd_softc *ahd, const struct ahd_pci_identity *entry) | |||
337 | * 64bit bus (PCI64BIT set in devconfig). | 337 | * 64bit bus (PCI64BIT set in devconfig). |
338 | */ | 338 | */ |
339 | if ((ahd->flags & (AHD_39BIT_ADDRESSING|AHD_64BIT_ADDRESSING)) != 0) { | 339 | if ((ahd->flags & (AHD_39BIT_ADDRESSING|AHD_64BIT_ADDRESSING)) != 0) { |
340 | uint32_t devconfig; | ||
341 | |||
342 | if (bootverbose) | 340 | if (bootverbose) |
343 | printf("%s: Enabling 39Bit Addressing\n", | 341 | printf("%s: Enabling 39Bit Addressing\n", |
344 | ahd_name(ahd)); | 342 | ahd_name(ahd)); |
@@ -483,8 +481,6 @@ ahd_pci_test_register_access(struct ahd_softc *ahd) | |||
483 | goto fail; | 481 | goto fail; |
484 | 482 | ||
485 | if ((ahd_inb(ahd, INTSTAT) & PCIINT) != 0) { | 483 | if ((ahd_inb(ahd, INTSTAT) & PCIINT) != 0) { |
486 | u_int targpcistat; | ||
487 | |||
488 | ahd_set_modes(ahd, AHD_MODE_CFG, AHD_MODE_CFG); | 484 | ahd_set_modes(ahd, AHD_MODE_CFG, AHD_MODE_CFG); |
489 | targpcistat = ahd_inb(ahd, TARGPCISTAT); | 485 | targpcistat = ahd_inb(ahd, TARGPCISTAT); |
490 | if ((targpcistat & STA) != 0) | 486 | if ((targpcistat & STA) != 0) |
diff --git a/drivers/scsi/aic7xxx/aic79xx_reg.h_shipped b/drivers/scsi/aic7xxx/aic79xx_reg.h_shipped index c21ceab8e913..cdcead071ef6 100644 --- a/drivers/scsi/aic7xxx/aic79xx_reg.h_shipped +++ b/drivers/scsi/aic7xxx/aic79xx_reg.h_shipped | |||
@@ -34,13 +34,6 @@ ahd_reg_print_t ahd_seqintcode_print; | |||
34 | #endif | 34 | #endif |
35 | 35 | ||
36 | #if AIC_DEBUG_REGISTERS | 36 | #if AIC_DEBUG_REGISTERS |
37 | ahd_reg_print_t ahd_clrint_print; | ||
38 | #else | ||
39 | #define ahd_clrint_print(regvalue, cur_col, wrap) \ | ||
40 | ahd_print_register(NULL, 0, "CLRINT", 0x03, regvalue, cur_col, wrap) | ||
41 | #endif | ||
42 | |||
43 | #if AIC_DEBUG_REGISTERS | ||
44 | ahd_reg_print_t ahd_error_print; | 37 | ahd_reg_print_t ahd_error_print; |
45 | #else | 38 | #else |
46 | #define ahd_error_print(regvalue, cur_col, wrap) \ | 39 | #define ahd_error_print(regvalue, cur_col, wrap) \ |
@@ -48,20 +41,6 @@ ahd_reg_print_t ahd_error_print; | |||
48 | #endif | 41 | #endif |
49 | 42 | ||
50 | #if AIC_DEBUG_REGISTERS | 43 | #if AIC_DEBUG_REGISTERS |
51 | ahd_reg_print_t ahd_hcntrl_print; | ||
52 | #else | ||
53 | #define ahd_hcntrl_print(regvalue, cur_col, wrap) \ | ||
54 | ahd_print_register(NULL, 0, "HCNTRL", 0x05, regvalue, cur_col, wrap) | ||
55 | #endif | ||
56 | |||
57 | #if AIC_DEBUG_REGISTERS | ||
58 | ahd_reg_print_t ahd_hnscb_qoff_print; | ||
59 | #else | ||
60 | #define ahd_hnscb_qoff_print(regvalue, cur_col, wrap) \ | ||
61 | ahd_print_register(NULL, 0, "HNSCB_QOFF", 0x06, regvalue, cur_col, wrap) | ||
62 | #endif | ||
63 | |||
64 | #if AIC_DEBUG_REGISTERS | ||
65 | ahd_reg_print_t ahd_hescb_qoff_print; | 44 | ahd_reg_print_t ahd_hescb_qoff_print; |
66 | #else | 45 | #else |
67 | #define ahd_hescb_qoff_print(regvalue, cur_col, wrap) \ | 46 | #define ahd_hescb_qoff_print(regvalue, cur_col, wrap) \ |
@@ -97,13 +76,6 @@ ahd_reg_print_t ahd_swtimer_print; | |||
97 | #endif | 76 | #endif |
98 | 77 | ||
99 | #if AIC_DEBUG_REGISTERS | 78 | #if AIC_DEBUG_REGISTERS |
100 | ahd_reg_print_t ahd_snscb_qoff_print; | ||
101 | #else | ||
102 | #define ahd_snscb_qoff_print(regvalue, cur_col, wrap) \ | ||
103 | ahd_print_register(NULL, 0, "SNSCB_QOFF", 0x10, regvalue, cur_col, wrap) | ||
104 | #endif | ||
105 | |||
106 | #if AIC_DEBUG_REGISTERS | ||
107 | ahd_reg_print_t ahd_sescb_qoff_print; | 79 | ahd_reg_print_t ahd_sescb_qoff_print; |
108 | #else | 80 | #else |
109 | #define ahd_sescb_qoff_print(regvalue, cur_col, wrap) \ | 81 | #define ahd_sescb_qoff_print(regvalue, cur_col, wrap) \ |
@@ -111,20 +83,6 @@ ahd_reg_print_t ahd_sescb_qoff_print; | |||
111 | #endif | 83 | #endif |
112 | 84 | ||
113 | #if AIC_DEBUG_REGISTERS | 85 | #if AIC_DEBUG_REGISTERS |
114 | ahd_reg_print_t ahd_sdscb_qoff_print; | ||
115 | #else | ||
116 | #define ahd_sdscb_qoff_print(regvalue, cur_col, wrap) \ | ||
117 | ahd_print_register(NULL, 0, "SDSCB_QOFF", 0x14, regvalue, cur_col, wrap) | ||
118 | #endif | ||
119 | |||
120 | #if AIC_DEBUG_REGISTERS | ||
121 | ahd_reg_print_t ahd_qoff_ctlsta_print; | ||
122 | #else | ||
123 | #define ahd_qoff_ctlsta_print(regvalue, cur_col, wrap) \ | ||
124 | ahd_print_register(NULL, 0, "QOFF_CTLSTA", 0x16, regvalue, cur_col, wrap) | ||
125 | #endif | ||
126 | |||
127 | #if AIC_DEBUG_REGISTERS | ||
128 | ahd_reg_print_t ahd_intctl_print; | 86 | ahd_reg_print_t ahd_intctl_print; |
129 | #else | 87 | #else |
130 | #define ahd_intctl_print(regvalue, cur_col, wrap) \ | 88 | #define ahd_intctl_print(regvalue, cur_col, wrap) \ |
@@ -139,13 +97,6 @@ ahd_reg_print_t ahd_dfcntrl_print; | |||
139 | #endif | 97 | #endif |
140 | 98 | ||
141 | #if AIC_DEBUG_REGISTERS | 99 | #if AIC_DEBUG_REGISTERS |
142 | ahd_reg_print_t ahd_dscommand0_print; | ||
143 | #else | ||
144 | #define ahd_dscommand0_print(regvalue, cur_col, wrap) \ | ||
145 | ahd_print_register(NULL, 0, "DSCOMMAND0", 0x19, regvalue, cur_col, wrap) | ||
146 | #endif | ||
147 | |||
148 | #if AIC_DEBUG_REGISTERS | ||
149 | ahd_reg_print_t ahd_dfstatus_print; | 100 | ahd_reg_print_t ahd_dfstatus_print; |
150 | #else | 101 | #else |
151 | #define ahd_dfstatus_print(regvalue, cur_col, wrap) \ | 102 | #define ahd_dfstatus_print(regvalue, cur_col, wrap) \ |
@@ -160,13 +111,6 @@ ahd_reg_print_t ahd_sg_cache_shadow_print; | |||
160 | #endif | 111 | #endif |
161 | 112 | ||
162 | #if AIC_DEBUG_REGISTERS | 113 | #if AIC_DEBUG_REGISTERS |
163 | ahd_reg_print_t ahd_sg_cache_pre_print; | ||
164 | #else | ||
165 | #define ahd_sg_cache_pre_print(regvalue, cur_col, wrap) \ | ||
166 | ahd_print_register(NULL, 0, "SG_CACHE_PRE", 0x1b, regvalue, cur_col, wrap) | ||
167 | #endif | ||
168 | |||
169 | #if AIC_DEBUG_REGISTERS | ||
170 | ahd_reg_print_t ahd_lqin_print; | 114 | ahd_reg_print_t ahd_lqin_print; |
171 | #else | 115 | #else |
172 | #define ahd_lqin_print(regvalue, cur_col, wrap) \ | 116 | #define ahd_lqin_print(regvalue, cur_col, wrap) \ |
@@ -293,13 +237,6 @@ ahd_reg_print_t ahd_sxfrctl0_print; | |||
293 | #endif | 237 | #endif |
294 | 238 | ||
295 | #if AIC_DEBUG_REGISTERS | 239 | #if AIC_DEBUG_REGISTERS |
296 | ahd_reg_print_t ahd_sxfrctl1_print; | ||
297 | #else | ||
298 | #define ahd_sxfrctl1_print(regvalue, cur_col, wrap) \ | ||
299 | ahd_print_register(NULL, 0, "SXFRCTL1", 0x3d, regvalue, cur_col, wrap) | ||
300 | #endif | ||
301 | |||
302 | #if AIC_DEBUG_REGISTERS | ||
303 | ahd_reg_print_t ahd_dffstat_print; | 240 | ahd_reg_print_t ahd_dffstat_print; |
304 | #else | 241 | #else |
305 | #define ahd_dffstat_print(regvalue, cur_col, wrap) \ | 242 | #define ahd_dffstat_print(regvalue, cur_col, wrap) \ |
@@ -314,13 +251,6 @@ ahd_reg_print_t ahd_multargid_print; | |||
314 | #endif | 251 | #endif |
315 | 252 | ||
316 | #if AIC_DEBUG_REGISTERS | 253 | #if AIC_DEBUG_REGISTERS |
317 | ahd_reg_print_t ahd_scsisigo_print; | ||
318 | #else | ||
319 | #define ahd_scsisigo_print(regvalue, cur_col, wrap) \ | ||
320 | ahd_print_register(NULL, 0, "SCSISIGO", 0x40, regvalue, cur_col, wrap) | ||
321 | #endif | ||
322 | |||
323 | #if AIC_DEBUG_REGISTERS | ||
324 | ahd_reg_print_t ahd_scsisigi_print; | 254 | ahd_reg_print_t ahd_scsisigi_print; |
325 | #else | 255 | #else |
326 | #define ahd_scsisigi_print(regvalue, cur_col, wrap) \ | 256 | #define ahd_scsisigi_print(regvalue, cur_col, wrap) \ |
@@ -363,13 +293,6 @@ ahd_reg_print_t ahd_selid_print; | |||
363 | #endif | 293 | #endif |
364 | 294 | ||
365 | #if AIC_DEBUG_REGISTERS | 295 | #if AIC_DEBUG_REGISTERS |
366 | ahd_reg_print_t ahd_optionmode_print; | ||
367 | #else | ||
368 | #define ahd_optionmode_print(regvalue, cur_col, wrap) \ | ||
369 | ahd_print_register(NULL, 0, "OPTIONMODE", 0x4a, regvalue, cur_col, wrap) | ||
370 | #endif | ||
371 | |||
372 | #if AIC_DEBUG_REGISTERS | ||
373 | ahd_reg_print_t ahd_sblkctl_print; | 296 | ahd_reg_print_t ahd_sblkctl_print; |
374 | #else | 297 | #else |
375 | #define ahd_sblkctl_print(regvalue, cur_col, wrap) \ | 298 | #define ahd_sblkctl_print(regvalue, cur_col, wrap) \ |
@@ -391,13 +314,6 @@ ahd_reg_print_t ahd_simode0_print; | |||
391 | #endif | 314 | #endif |
392 | 315 | ||
393 | #if AIC_DEBUG_REGISTERS | 316 | #if AIC_DEBUG_REGISTERS |
394 | ahd_reg_print_t ahd_clrsint0_print; | ||
395 | #else | ||
396 | #define ahd_clrsint0_print(regvalue, cur_col, wrap) \ | ||
397 | ahd_print_register(NULL, 0, "CLRSINT0", 0x4b, regvalue, cur_col, wrap) | ||
398 | #endif | ||
399 | |||
400 | #if AIC_DEBUG_REGISTERS | ||
401 | ahd_reg_print_t ahd_sstat1_print; | 317 | ahd_reg_print_t ahd_sstat1_print; |
402 | #else | 318 | #else |
403 | #define ahd_sstat1_print(regvalue, cur_col, wrap) \ | 319 | #define ahd_sstat1_print(regvalue, cur_col, wrap) \ |
@@ -405,13 +321,6 @@ ahd_reg_print_t ahd_sstat1_print; | |||
405 | #endif | 321 | #endif |
406 | 322 | ||
407 | #if AIC_DEBUG_REGISTERS | 323 | #if AIC_DEBUG_REGISTERS |
408 | ahd_reg_print_t ahd_clrsint1_print; | ||
409 | #else | ||
410 | #define ahd_clrsint1_print(regvalue, cur_col, wrap) \ | ||
411 | ahd_print_register(NULL, 0, "CLRSINT1", 0x4c, regvalue, cur_col, wrap) | ||
412 | #endif | ||
413 | |||
414 | #if AIC_DEBUG_REGISTERS | ||
415 | ahd_reg_print_t ahd_sstat2_print; | 324 | ahd_reg_print_t ahd_sstat2_print; |
416 | #else | 325 | #else |
417 | #define ahd_sstat2_print(regvalue, cur_col, wrap) \ | 326 | #define ahd_sstat2_print(regvalue, cur_col, wrap) \ |
@@ -461,17 +370,17 @@ ahd_reg_print_t ahd_lqistat0_print; | |||
461 | #endif | 370 | #endif |
462 | 371 | ||
463 | #if AIC_DEBUG_REGISTERS | 372 | #if AIC_DEBUG_REGISTERS |
464 | ahd_reg_print_t ahd_lqimode0_print; | 373 | ahd_reg_print_t ahd_clrlqiint0_print; |
465 | #else | 374 | #else |
466 | #define ahd_lqimode0_print(regvalue, cur_col, wrap) \ | 375 | #define ahd_clrlqiint0_print(regvalue, cur_col, wrap) \ |
467 | ahd_print_register(NULL, 0, "LQIMODE0", 0x50, regvalue, cur_col, wrap) | 376 | ahd_print_register(NULL, 0, "CLRLQIINT0", 0x50, regvalue, cur_col, wrap) |
468 | #endif | 377 | #endif |
469 | 378 | ||
470 | #if AIC_DEBUG_REGISTERS | 379 | #if AIC_DEBUG_REGISTERS |
471 | ahd_reg_print_t ahd_clrlqiint0_print; | 380 | ahd_reg_print_t ahd_lqimode0_print; |
472 | #else | 381 | #else |
473 | #define ahd_clrlqiint0_print(regvalue, cur_col, wrap) \ | 382 | #define ahd_lqimode0_print(regvalue, cur_col, wrap) \ |
474 | ahd_print_register(NULL, 0, "CLRLQIINT0", 0x50, regvalue, cur_col, wrap) | 383 | ahd_print_register(NULL, 0, "LQIMODE0", 0x50, regvalue, cur_col, wrap) |
475 | #endif | 384 | #endif |
476 | 385 | ||
477 | #if AIC_DEBUG_REGISTERS | 386 | #if AIC_DEBUG_REGISTERS |
@@ -629,17 +538,17 @@ ahd_reg_print_t ahd_seqintsrc_print; | |||
629 | #endif | 538 | #endif |
630 | 539 | ||
631 | #if AIC_DEBUG_REGISTERS | 540 | #if AIC_DEBUG_REGISTERS |
632 | ahd_reg_print_t ahd_seqimode_print; | 541 | ahd_reg_print_t ahd_currscb_print; |
633 | #else | 542 | #else |
634 | #define ahd_seqimode_print(regvalue, cur_col, wrap) \ | 543 | #define ahd_currscb_print(regvalue, cur_col, wrap) \ |
635 | ahd_print_register(NULL, 0, "SEQIMODE", 0x5c, regvalue, cur_col, wrap) | 544 | ahd_print_register(NULL, 0, "CURRSCB", 0x5c, regvalue, cur_col, wrap) |
636 | #endif | 545 | #endif |
637 | 546 | ||
638 | #if AIC_DEBUG_REGISTERS | 547 | #if AIC_DEBUG_REGISTERS |
639 | ahd_reg_print_t ahd_currscb_print; | 548 | ahd_reg_print_t ahd_seqimode_print; |
640 | #else | 549 | #else |
641 | #define ahd_currscb_print(regvalue, cur_col, wrap) \ | 550 | #define ahd_seqimode_print(regvalue, cur_col, wrap) \ |
642 | ahd_print_register(NULL, 0, "CURRSCB", 0x5c, regvalue, cur_col, wrap) | 551 | ahd_print_register(NULL, 0, "SEQIMODE", 0x5c, regvalue, cur_col, wrap) |
643 | #endif | 552 | #endif |
644 | 553 | ||
645 | #if AIC_DEBUG_REGISTERS | 554 | #if AIC_DEBUG_REGISTERS |
@@ -657,13 +566,6 @@ ahd_reg_print_t ahd_lastscb_print; | |||
657 | #endif | 566 | #endif |
658 | 567 | ||
659 | #if AIC_DEBUG_REGISTERS | 568 | #if AIC_DEBUG_REGISTERS |
660 | ahd_reg_print_t ahd_shaddr_print; | ||
661 | #else | ||
662 | #define ahd_shaddr_print(regvalue, cur_col, wrap) \ | ||
663 | ahd_print_register(NULL, 0, "SHADDR", 0x60, regvalue, cur_col, wrap) | ||
664 | #endif | ||
665 | |||
666 | #if AIC_DEBUG_REGISTERS | ||
667 | ahd_reg_print_t ahd_negoaddr_print; | 569 | ahd_reg_print_t ahd_negoaddr_print; |
668 | #else | 570 | #else |
669 | #define ahd_negoaddr_print(regvalue, cur_col, wrap) \ | 571 | #define ahd_negoaddr_print(regvalue, cur_col, wrap) \ |
@@ -748,27 +650,6 @@ ahd_reg_print_t ahd_seloid_print; | |||
748 | #endif | 650 | #endif |
749 | 651 | ||
750 | #if AIC_DEBUG_REGISTERS | 652 | #if AIC_DEBUG_REGISTERS |
751 | ahd_reg_print_t ahd_haddr_print; | ||
752 | #else | ||
753 | #define ahd_haddr_print(regvalue, cur_col, wrap) \ | ||
754 | ahd_print_register(NULL, 0, "HADDR", 0x70, regvalue, cur_col, wrap) | ||
755 | #endif | ||
756 | |||
757 | #if AIC_DEBUG_REGISTERS | ||
758 | ahd_reg_print_t ahd_hcnt_print; | ||
759 | #else | ||
760 | #define ahd_hcnt_print(regvalue, cur_col, wrap) \ | ||
761 | ahd_print_register(NULL, 0, "HCNT", 0x78, regvalue, cur_col, wrap) | ||
762 | #endif | ||
763 | |||
764 | #if AIC_DEBUG_REGISTERS | ||
765 | ahd_reg_print_t ahd_sghaddr_print; | ||
766 | #else | ||
767 | #define ahd_sghaddr_print(regvalue, cur_col, wrap) \ | ||
768 | ahd_print_register(NULL, 0, "SGHADDR", 0x7c, regvalue, cur_col, wrap) | ||
769 | #endif | ||
770 | |||
771 | #if AIC_DEBUG_REGISTERS | ||
772 | ahd_reg_print_t ahd_scbhaddr_print; | 653 | ahd_reg_print_t ahd_scbhaddr_print; |
773 | #else | 654 | #else |
774 | #define ahd_scbhaddr_print(regvalue, cur_col, wrap) \ | 655 | #define ahd_scbhaddr_print(regvalue, cur_col, wrap) \ |
@@ -776,10 +657,10 @@ ahd_reg_print_t ahd_scbhaddr_print; | |||
776 | #endif | 657 | #endif |
777 | 658 | ||
778 | #if AIC_DEBUG_REGISTERS | 659 | #if AIC_DEBUG_REGISTERS |
779 | ahd_reg_print_t ahd_sghcnt_print; | 660 | ahd_reg_print_t ahd_sghaddr_print; |
780 | #else | 661 | #else |
781 | #define ahd_sghcnt_print(regvalue, cur_col, wrap) \ | 662 | #define ahd_sghaddr_print(regvalue, cur_col, wrap) \ |
782 | ahd_print_register(NULL, 0, "SGHCNT", 0x84, regvalue, cur_col, wrap) | 663 | ahd_print_register(NULL, 0, "SGHADDR", 0x7c, regvalue, cur_col, wrap) |
783 | #endif | 664 | #endif |
784 | 665 | ||
785 | #if AIC_DEBUG_REGISTERS | 666 | #if AIC_DEBUG_REGISTERS |
@@ -790,10 +671,10 @@ ahd_reg_print_t ahd_scbhcnt_print; | |||
790 | #endif | 671 | #endif |
791 | 672 | ||
792 | #if AIC_DEBUG_REGISTERS | 673 | #if AIC_DEBUG_REGISTERS |
793 | ahd_reg_print_t ahd_dff_thrsh_print; | 674 | ahd_reg_print_t ahd_sghcnt_print; |
794 | #else | 675 | #else |
795 | #define ahd_dff_thrsh_print(regvalue, cur_col, wrap) \ | 676 | #define ahd_sghcnt_print(regvalue, cur_col, wrap) \ |
796 | ahd_print_register(NULL, 0, "DFF_THRSH", 0x88, regvalue, cur_col, wrap) | 677 | ahd_print_register(NULL, 0, "SGHCNT", 0x84, regvalue, cur_col, wrap) |
797 | #endif | 678 | #endif |
798 | 679 | ||
799 | #if AIC_DEBUG_REGISTERS | 680 | #if AIC_DEBUG_REGISTERS |
@@ -867,13 +748,6 @@ ahd_reg_print_t ahd_targpcistat_print; | |||
867 | #endif | 748 | #endif |
868 | 749 | ||
869 | #if AIC_DEBUG_REGISTERS | 750 | #if AIC_DEBUG_REGISTERS |
870 | ahd_reg_print_t ahd_scbptr_print; | ||
871 | #else | ||
872 | #define ahd_scbptr_print(regvalue, cur_col, wrap) \ | ||
873 | ahd_print_register(NULL, 0, "SCBPTR", 0xa8, regvalue, cur_col, wrap) | ||
874 | #endif | ||
875 | |||
876 | #if AIC_DEBUG_REGISTERS | ||
877 | ahd_reg_print_t ahd_scbautoptr_print; | 751 | ahd_reg_print_t ahd_scbautoptr_print; |
878 | #else | 752 | #else |
879 | #define ahd_scbautoptr_print(regvalue, cur_col, wrap) \ | 753 | #define ahd_scbautoptr_print(regvalue, cur_col, wrap) \ |
@@ -881,13 +755,6 @@ ahd_reg_print_t ahd_scbautoptr_print; | |||
881 | #endif | 755 | #endif |
882 | 756 | ||
883 | #if AIC_DEBUG_REGISTERS | 757 | #if AIC_DEBUG_REGISTERS |
884 | ahd_reg_print_t ahd_ccsgaddr_print; | ||
885 | #else | ||
886 | #define ahd_ccsgaddr_print(regvalue, cur_col, wrap) \ | ||
887 | ahd_print_register(NULL, 0, "CCSGADDR", 0xac, regvalue, cur_col, wrap) | ||
888 | #endif | ||
889 | |||
890 | #if AIC_DEBUG_REGISTERS | ||
891 | ahd_reg_print_t ahd_ccscbaddr_print; | 758 | ahd_reg_print_t ahd_ccscbaddr_print; |
892 | #else | 759 | #else |
893 | #define ahd_ccscbaddr_print(regvalue, cur_col, wrap) \ | 760 | #define ahd_ccscbaddr_print(regvalue, cur_col, wrap) \ |
@@ -909,13 +776,6 @@ ahd_reg_print_t ahd_ccsgctl_print; | |||
909 | #endif | 776 | #endif |
910 | 777 | ||
911 | #if AIC_DEBUG_REGISTERS | 778 | #if AIC_DEBUG_REGISTERS |
912 | ahd_reg_print_t ahd_ccsgram_print; | ||
913 | #else | ||
914 | #define ahd_ccsgram_print(regvalue, cur_col, wrap) \ | ||
915 | ahd_print_register(NULL, 0, "CCSGRAM", 0xb0, regvalue, cur_col, wrap) | ||
916 | #endif | ||
917 | |||
918 | #if AIC_DEBUG_REGISTERS | ||
919 | ahd_reg_print_t ahd_ccscbram_print; | 779 | ahd_reg_print_t ahd_ccscbram_print; |
920 | #else | 780 | #else |
921 | #define ahd_ccscbram_print(regvalue, cur_col, wrap) \ | 781 | #define ahd_ccscbram_print(regvalue, cur_col, wrap) \ |
@@ -930,13 +790,6 @@ ahd_reg_print_t ahd_brddat_print; | |||
930 | #endif | 790 | #endif |
931 | 791 | ||
932 | #if AIC_DEBUG_REGISTERS | 792 | #if AIC_DEBUG_REGISTERS |
933 | ahd_reg_print_t ahd_brdctl_print; | ||
934 | #else | ||
935 | #define ahd_brdctl_print(regvalue, cur_col, wrap) \ | ||
936 | ahd_print_register(NULL, 0, "BRDCTL", 0xb9, regvalue, cur_col, wrap) | ||
937 | #endif | ||
938 | |||
939 | #if AIC_DEBUG_REGISTERS | ||
940 | ahd_reg_print_t ahd_seeadr_print; | 793 | ahd_reg_print_t ahd_seeadr_print; |
941 | #else | 794 | #else |
942 | #define ahd_seeadr_print(regvalue, cur_col, wrap) \ | 795 | #define ahd_seeadr_print(regvalue, cur_col, wrap) \ |
@@ -972,13 +825,6 @@ ahd_reg_print_t ahd_dspdatactl_print; | |||
972 | #endif | 825 | #endif |
973 | 826 | ||
974 | #if AIC_DEBUG_REGISTERS | 827 | #if AIC_DEBUG_REGISTERS |
975 | ahd_reg_print_t ahd_dfdat_print; | ||
976 | #else | ||
977 | #define ahd_dfdat_print(regvalue, cur_col, wrap) \ | ||
978 | ahd_print_register(NULL, 0, "DFDAT", 0xc4, regvalue, cur_col, wrap) | ||
979 | #endif | ||
980 | |||
981 | #if AIC_DEBUG_REGISTERS | ||
982 | ahd_reg_print_t ahd_dspselect_print; | 828 | ahd_reg_print_t ahd_dspselect_print; |
983 | #else | 829 | #else |
984 | #define ahd_dspselect_print(regvalue, cur_col, wrap) \ | 830 | #define ahd_dspselect_print(regvalue, cur_col, wrap) \ |
@@ -1000,13 +846,6 @@ ahd_reg_print_t ahd_seqctl0_print; | |||
1000 | #endif | 846 | #endif |
1001 | 847 | ||
1002 | #if AIC_DEBUG_REGISTERS | 848 | #if AIC_DEBUG_REGISTERS |
1003 | ahd_reg_print_t ahd_flags_print; | ||
1004 | #else | ||
1005 | #define ahd_flags_print(regvalue, cur_col, wrap) \ | ||
1006 | ahd_print_register(NULL, 0, "FLAGS", 0xd8, regvalue, cur_col, wrap) | ||
1007 | #endif | ||
1008 | |||
1009 | #if AIC_DEBUG_REGISTERS | ||
1010 | ahd_reg_print_t ahd_seqintctl_print; | 849 | ahd_reg_print_t ahd_seqintctl_print; |
1011 | #else | 850 | #else |
1012 | #define ahd_seqintctl_print(regvalue, cur_col, wrap) \ | 851 | #define ahd_seqintctl_print(regvalue, cur_col, wrap) \ |
@@ -1014,13 +853,6 @@ ahd_reg_print_t ahd_seqintctl_print; | |||
1014 | #endif | 853 | #endif |
1015 | 854 | ||
1016 | #if AIC_DEBUG_REGISTERS | 855 | #if AIC_DEBUG_REGISTERS |
1017 | ahd_reg_print_t ahd_seqram_print; | ||
1018 | #else | ||
1019 | #define ahd_seqram_print(regvalue, cur_col, wrap) \ | ||
1020 | ahd_print_register(NULL, 0, "SEQRAM", 0xda, regvalue, cur_col, wrap) | ||
1021 | #endif | ||
1022 | |||
1023 | #if AIC_DEBUG_REGISTERS | ||
1024 | ahd_reg_print_t ahd_prgmcnt_print; | 856 | ahd_reg_print_t ahd_prgmcnt_print; |
1025 | #else | 857 | #else |
1026 | #define ahd_prgmcnt_print(regvalue, cur_col, wrap) \ | 858 | #define ahd_prgmcnt_print(regvalue, cur_col, wrap) \ |
@@ -1028,41 +860,6 @@ ahd_reg_print_t ahd_prgmcnt_print; | |||
1028 | #endif | 860 | #endif |
1029 | 861 | ||
1030 | #if AIC_DEBUG_REGISTERS | 862 | #if AIC_DEBUG_REGISTERS |
1031 | ahd_reg_print_t ahd_accum_print; | ||
1032 | #else | ||
1033 | #define ahd_accum_print(regvalue, cur_col, wrap) \ | ||
1034 | ahd_print_register(NULL, 0, "ACCUM", 0xe0, regvalue, cur_col, wrap) | ||
1035 | #endif | ||
1036 | |||
1037 | #if AIC_DEBUG_REGISTERS | ||
1038 | ahd_reg_print_t ahd_sindex_print; | ||
1039 | #else | ||
1040 | #define ahd_sindex_print(regvalue, cur_col, wrap) \ | ||
1041 | ahd_print_register(NULL, 0, "SINDEX", 0xe2, regvalue, cur_col, wrap) | ||
1042 | #endif | ||
1043 | |||
1044 | #if AIC_DEBUG_REGISTERS | ||
1045 | ahd_reg_print_t ahd_dindex_print; | ||
1046 | #else | ||
1047 | #define ahd_dindex_print(regvalue, cur_col, wrap) \ | ||
1048 | ahd_print_register(NULL, 0, "DINDEX", 0xe4, regvalue, cur_col, wrap) | ||
1049 | #endif | ||
1050 | |||
1051 | #if AIC_DEBUG_REGISTERS | ||
1052 | ahd_reg_print_t ahd_allones_print; | ||
1053 | #else | ||
1054 | #define ahd_allones_print(regvalue, cur_col, wrap) \ | ||
1055 | ahd_print_register(NULL, 0, "ALLONES", 0xe8, regvalue, cur_col, wrap) | ||
1056 | #endif | ||
1057 | |||
1058 | #if AIC_DEBUG_REGISTERS | ||
1059 | ahd_reg_print_t ahd_allzeros_print; | ||
1060 | #else | ||
1061 | #define ahd_allzeros_print(regvalue, cur_col, wrap) \ | ||
1062 | ahd_print_register(NULL, 0, "ALLZEROS", 0xea, regvalue, cur_col, wrap) | ||
1063 | #endif | ||
1064 | |||
1065 | #if AIC_DEBUG_REGISTERS | ||
1066 | ahd_reg_print_t ahd_none_print; | 863 | ahd_reg_print_t ahd_none_print; |
1067 | #else | 864 | #else |
1068 | #define ahd_none_print(regvalue, cur_col, wrap) \ | 865 | #define ahd_none_print(regvalue, cur_col, wrap) \ |
@@ -1070,27 +867,6 @@ ahd_reg_print_t ahd_none_print; | |||
1070 | #endif | 867 | #endif |
1071 | 868 | ||
1072 | #if AIC_DEBUG_REGISTERS | 869 | #if AIC_DEBUG_REGISTERS |
1073 | ahd_reg_print_t ahd_sindir_print; | ||
1074 | #else | ||
1075 | #define ahd_sindir_print(regvalue, cur_col, wrap) \ | ||
1076 | ahd_print_register(NULL, 0, "SINDIR", 0xec, regvalue, cur_col, wrap) | ||
1077 | #endif | ||
1078 | |||
1079 | #if AIC_DEBUG_REGISTERS | ||
1080 | ahd_reg_print_t ahd_dindir_print; | ||
1081 | #else | ||
1082 | #define ahd_dindir_print(regvalue, cur_col, wrap) \ | ||
1083 | ahd_print_register(NULL, 0, "DINDIR", 0xed, regvalue, cur_col, wrap) | ||
1084 | #endif | ||
1085 | |||
1086 | #if AIC_DEBUG_REGISTERS | ||
1087 | ahd_reg_print_t ahd_stack_print; | ||
1088 | #else | ||
1089 | #define ahd_stack_print(regvalue, cur_col, wrap) \ | ||
1090 | ahd_print_register(NULL, 0, "STACK", 0xf2, regvalue, cur_col, wrap) | ||
1091 | #endif | ||
1092 | |||
1093 | #if AIC_DEBUG_REGISTERS | ||
1094 | ahd_reg_print_t ahd_intvec1_addr_print; | 870 | ahd_reg_print_t ahd_intvec1_addr_print; |
1095 | #else | 871 | #else |
1096 | #define ahd_intvec1_addr_print(regvalue, cur_col, wrap) \ | 872 | #define ahd_intvec1_addr_print(regvalue, cur_col, wrap) \ |
@@ -1126,17 +902,17 @@ ahd_reg_print_t ahd_accum_save_print; | |||
1126 | #endif | 902 | #endif |
1127 | 903 | ||
1128 | #if AIC_DEBUG_REGISTERS | 904 | #if AIC_DEBUG_REGISTERS |
1129 | ahd_reg_print_t ahd_sram_base_print; | 905 | ahd_reg_print_t ahd_waiting_scb_tails_print; |
1130 | #else | 906 | #else |
1131 | #define ahd_sram_base_print(regvalue, cur_col, wrap) \ | 907 | #define ahd_waiting_scb_tails_print(regvalue, cur_col, wrap) \ |
1132 | ahd_print_register(NULL, 0, "SRAM_BASE", 0x100, regvalue, cur_col, wrap) | 908 | ahd_print_register(NULL, 0, "WAITING_SCB_TAILS", 0x100, regvalue, cur_col, wrap) |
1133 | #endif | 909 | #endif |
1134 | 910 | ||
1135 | #if AIC_DEBUG_REGISTERS | 911 | #if AIC_DEBUG_REGISTERS |
1136 | ahd_reg_print_t ahd_waiting_scb_tails_print; | 912 | ahd_reg_print_t ahd_sram_base_print; |
1137 | #else | 913 | #else |
1138 | #define ahd_waiting_scb_tails_print(regvalue, cur_col, wrap) \ | 914 | #define ahd_sram_base_print(regvalue, cur_col, wrap) \ |
1139 | ahd_print_register(NULL, 0, "WAITING_SCB_TAILS", 0x100, regvalue, cur_col, wrap) | 915 | ahd_print_register(NULL, 0, "SRAM_BASE", 0x100, regvalue, cur_col, wrap) |
1140 | #endif | 916 | #endif |
1141 | 917 | ||
1142 | #if AIC_DEBUG_REGISTERS | 918 | #if AIC_DEBUG_REGISTERS |
@@ -1224,13 +1000,6 @@ ahd_reg_print_t ahd_msg_out_print; | |||
1224 | #endif | 1000 | #endif |
1225 | 1001 | ||
1226 | #if AIC_DEBUG_REGISTERS | 1002 | #if AIC_DEBUG_REGISTERS |
1227 | ahd_reg_print_t ahd_dmaparams_print; | ||
1228 | #else | ||
1229 | #define ahd_dmaparams_print(regvalue, cur_col, wrap) \ | ||
1230 | ahd_print_register(NULL, 0, "DMAPARAMS", 0x138, regvalue, cur_col, wrap) | ||
1231 | #endif | ||
1232 | |||
1233 | #if AIC_DEBUG_REGISTERS | ||
1234 | ahd_reg_print_t ahd_seq_flags_print; | 1003 | ahd_reg_print_t ahd_seq_flags_print; |
1235 | #else | 1004 | #else |
1236 | #define ahd_seq_flags_print(regvalue, cur_col, wrap) \ | 1005 | #define ahd_seq_flags_print(regvalue, cur_col, wrap) \ |
@@ -1238,20 +1007,6 @@ ahd_reg_print_t ahd_seq_flags_print; | |||
1238 | #endif | 1007 | #endif |
1239 | 1008 | ||
1240 | #if AIC_DEBUG_REGISTERS | 1009 | #if AIC_DEBUG_REGISTERS |
1241 | ahd_reg_print_t ahd_saved_scsiid_print; | ||
1242 | #else | ||
1243 | #define ahd_saved_scsiid_print(regvalue, cur_col, wrap) \ | ||
1244 | ahd_print_register(NULL, 0, "SAVED_SCSIID", 0x13a, regvalue, cur_col, wrap) | ||
1245 | #endif | ||
1246 | |||
1247 | #if AIC_DEBUG_REGISTERS | ||
1248 | ahd_reg_print_t ahd_saved_lun_print; | ||
1249 | #else | ||
1250 | #define ahd_saved_lun_print(regvalue, cur_col, wrap) \ | ||
1251 | ahd_print_register(NULL, 0, "SAVED_LUN", 0x13b, regvalue, cur_col, wrap) | ||
1252 | #endif | ||
1253 | |||
1254 | #if AIC_DEBUG_REGISTERS | ||
1255 | ahd_reg_print_t ahd_lastphase_print; | 1010 | ahd_reg_print_t ahd_lastphase_print; |
1256 | #else | 1011 | #else |
1257 | #define ahd_lastphase_print(regvalue, cur_col, wrap) \ | 1012 | #define ahd_lastphase_print(regvalue, cur_col, wrap) \ |
@@ -1273,20 +1028,6 @@ ahd_reg_print_t ahd_kernel_tqinpos_print; | |||
1273 | #endif | 1028 | #endif |
1274 | 1029 | ||
1275 | #if AIC_DEBUG_REGISTERS | 1030 | #if AIC_DEBUG_REGISTERS |
1276 | ahd_reg_print_t ahd_tqinpos_print; | ||
1277 | #else | ||
1278 | #define ahd_tqinpos_print(regvalue, cur_col, wrap) \ | ||
1279 | ahd_print_register(NULL, 0, "TQINPOS", 0x13f, regvalue, cur_col, wrap) | ||
1280 | #endif | ||
1281 | |||
1282 | #if AIC_DEBUG_REGISTERS | ||
1283 | ahd_reg_print_t ahd_shared_data_addr_print; | ||
1284 | #else | ||
1285 | #define ahd_shared_data_addr_print(regvalue, cur_col, wrap) \ | ||
1286 | ahd_print_register(NULL, 0, "SHARED_DATA_ADDR", 0x140, regvalue, cur_col, wrap) | ||
1287 | #endif | ||
1288 | |||
1289 | #if AIC_DEBUG_REGISTERS | ||
1290 | ahd_reg_print_t ahd_qoutfifo_next_addr_print; | 1031 | ahd_reg_print_t ahd_qoutfifo_next_addr_print; |
1291 | #else | 1032 | #else |
1292 | #define ahd_qoutfifo_next_addr_print(regvalue, cur_col, wrap) \ | 1033 | #define ahd_qoutfifo_next_addr_print(regvalue, cur_col, wrap) \ |
@@ -1294,20 +1035,6 @@ ahd_reg_print_t ahd_qoutfifo_next_addr_print; | |||
1294 | #endif | 1035 | #endif |
1295 | 1036 | ||
1296 | #if AIC_DEBUG_REGISTERS | 1037 | #if AIC_DEBUG_REGISTERS |
1297 | ahd_reg_print_t ahd_arg_1_print; | ||
1298 | #else | ||
1299 | #define ahd_arg_1_print(regvalue, cur_col, wrap) \ | ||
1300 | ahd_print_register(NULL, 0, "ARG_1", 0x148, regvalue, cur_col, wrap) | ||
1301 | #endif | ||
1302 | |||
1303 | #if AIC_DEBUG_REGISTERS | ||
1304 | ahd_reg_print_t ahd_arg_2_print; | ||
1305 | #else | ||
1306 | #define ahd_arg_2_print(regvalue, cur_col, wrap) \ | ||
1307 | ahd_print_register(NULL, 0, "ARG_2", 0x149, regvalue, cur_col, wrap) | ||
1308 | #endif | ||
1309 | |||
1310 | #if AIC_DEBUG_REGISTERS | ||
1311 | ahd_reg_print_t ahd_last_msg_print; | 1038 | ahd_reg_print_t ahd_last_msg_print; |
1312 | #else | 1039 | #else |
1313 | #define ahd_last_msg_print(regvalue, cur_col, wrap) \ | 1040 | #define ahd_last_msg_print(regvalue, cur_col, wrap) \ |
@@ -1406,13 +1133,6 @@ ahd_reg_print_t ahd_mk_message_scsiid_print; | |||
1406 | #endif | 1133 | #endif |
1407 | 1134 | ||
1408 | #if AIC_DEBUG_REGISTERS | 1135 | #if AIC_DEBUG_REGISTERS |
1409 | ahd_reg_print_t ahd_scb_residual_datacnt_print; | ||
1410 | #else | ||
1411 | #define ahd_scb_residual_datacnt_print(regvalue, cur_col, wrap) \ | ||
1412 | ahd_print_register(NULL, 0, "SCB_RESIDUAL_DATACNT", 0x180, regvalue, cur_col, wrap) | ||
1413 | #endif | ||
1414 | |||
1415 | #if AIC_DEBUG_REGISTERS | ||
1416 | ahd_reg_print_t ahd_scb_base_print; | 1136 | ahd_reg_print_t ahd_scb_base_print; |
1417 | #else | 1137 | #else |
1418 | #define ahd_scb_base_print(regvalue, cur_col, wrap) \ | 1138 | #define ahd_scb_base_print(regvalue, cur_col, wrap) \ |
@@ -1420,17 +1140,10 @@ ahd_reg_print_t ahd_scb_base_print; | |||
1420 | #endif | 1140 | #endif |
1421 | 1141 | ||
1422 | #if AIC_DEBUG_REGISTERS | 1142 | #if AIC_DEBUG_REGISTERS |
1423 | ahd_reg_print_t ahd_scb_residual_sgptr_print; | 1143 | ahd_reg_print_t ahd_scb_residual_datacnt_print; |
1424 | #else | ||
1425 | #define ahd_scb_residual_sgptr_print(regvalue, cur_col, wrap) \ | ||
1426 | ahd_print_register(NULL, 0, "SCB_RESIDUAL_SGPTR", 0x184, regvalue, cur_col, wrap) | ||
1427 | #endif | ||
1428 | |||
1429 | #if AIC_DEBUG_REGISTERS | ||
1430 | ahd_reg_print_t ahd_scb_scsi_status_print; | ||
1431 | #else | 1144 | #else |
1432 | #define ahd_scb_scsi_status_print(regvalue, cur_col, wrap) \ | 1145 | #define ahd_scb_residual_datacnt_print(regvalue, cur_col, wrap) \ |
1433 | ahd_print_register(NULL, 0, "SCB_SCSI_STATUS", 0x188, regvalue, cur_col, wrap) | 1146 | ahd_print_register(NULL, 0, "SCB_RESIDUAL_DATACNT", 0x180, regvalue, cur_col, wrap) |
1434 | #endif | 1147 | #endif |
1435 | 1148 | ||
1436 | #if AIC_DEBUG_REGISTERS | 1149 | #if AIC_DEBUG_REGISTERS |
@@ -1476,13 +1189,6 @@ ahd_reg_print_t ahd_scb_task_attribute_print; | |||
1476 | #endif | 1189 | #endif |
1477 | 1190 | ||
1478 | #if AIC_DEBUG_REGISTERS | 1191 | #if AIC_DEBUG_REGISTERS |
1479 | ahd_reg_print_t ahd_scb_cdb_len_print; | ||
1480 | #else | ||
1481 | #define ahd_scb_cdb_len_print(regvalue, cur_col, wrap) \ | ||
1482 | ahd_print_register(NULL, 0, "SCB_CDB_LEN", 0x196, regvalue, cur_col, wrap) | ||
1483 | #endif | ||
1484 | |||
1485 | #if AIC_DEBUG_REGISTERS | ||
1486 | ahd_reg_print_t ahd_scb_task_management_print; | 1192 | ahd_reg_print_t ahd_scb_task_management_print; |
1487 | #else | 1193 | #else |
1488 | #define ahd_scb_task_management_print(regvalue, cur_col, wrap) \ | 1194 | #define ahd_scb_task_management_print(regvalue, cur_col, wrap) \ |
@@ -1518,13 +1224,6 @@ ahd_reg_print_t ahd_scb_busaddr_print; | |||
1518 | #endif | 1224 | #endif |
1519 | 1225 | ||
1520 | #if AIC_DEBUG_REGISTERS | 1226 | #if AIC_DEBUG_REGISTERS |
1521 | ahd_reg_print_t ahd_scb_next_print; | ||
1522 | #else | ||
1523 | #define ahd_scb_next_print(regvalue, cur_col, wrap) \ | ||
1524 | ahd_print_register(NULL, 0, "SCB_NEXT", 0x1ac, regvalue, cur_col, wrap) | ||
1525 | #endif | ||
1526 | |||
1527 | #if AIC_DEBUG_REGISTERS | ||
1528 | ahd_reg_print_t ahd_scb_next2_print; | 1227 | ahd_reg_print_t ahd_scb_next2_print; |
1529 | #else | 1228 | #else |
1530 | #define ahd_scb_next2_print(regvalue, cur_col, wrap) \ | 1229 | #define ahd_scb_next2_print(regvalue, cur_col, wrap) \ |
@@ -1717,10 +1416,10 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1717 | 1416 | ||
1718 | #define SG_CACHE_PRE 0x1b | 1417 | #define SG_CACHE_PRE 0x1b |
1719 | 1418 | ||
1720 | #define TYPEPTR 0x20 | ||
1721 | |||
1722 | #define LQIN 0x20 | 1419 | #define LQIN 0x20 |
1723 | 1420 | ||
1421 | #define TYPEPTR 0x20 | ||
1422 | |||
1724 | #define TAGPTR 0x21 | 1423 | #define TAGPTR 0x21 |
1725 | 1424 | ||
1726 | #define LUNPTR 0x22 | 1425 | #define LUNPTR 0x22 |
@@ -1780,6 +1479,14 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1780 | #define SINGLECMD 0x02 | 1479 | #define SINGLECMD 0x02 |
1781 | #define ABORTPENDING 0x01 | 1480 | #define ABORTPENDING 0x01 |
1782 | 1481 | ||
1482 | #define SCSBIST0 0x39 | ||
1483 | #define GSBISTERR 0x40 | ||
1484 | #define GSBISTDONE 0x20 | ||
1485 | #define GSBISTRUN 0x10 | ||
1486 | #define OSBISTERR 0x04 | ||
1487 | #define OSBISTDONE 0x02 | ||
1488 | #define OSBISTRUN 0x01 | ||
1489 | |||
1783 | #define LQCTL2 0x39 | 1490 | #define LQCTL2 0x39 |
1784 | #define LQIRETRY 0x80 | 1491 | #define LQIRETRY 0x80 |
1785 | #define LQICONTINUE 0x40 | 1492 | #define LQICONTINUE 0x40 |
@@ -1790,13 +1497,10 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1790 | #define LQOTOIDLE 0x02 | 1497 | #define LQOTOIDLE 0x02 |
1791 | #define LQOPAUSE 0x01 | 1498 | #define LQOPAUSE 0x01 |
1792 | 1499 | ||
1793 | #define SCSBIST0 0x39 | 1500 | #define SCSBIST1 0x3a |
1794 | #define GSBISTERR 0x40 | 1501 | #define NTBISTERR 0x04 |
1795 | #define GSBISTDONE 0x20 | 1502 | #define NTBISTDONE 0x02 |
1796 | #define GSBISTRUN 0x10 | 1503 | #define NTBISTRUN 0x01 |
1797 | #define OSBISTERR 0x04 | ||
1798 | #define OSBISTDONE 0x02 | ||
1799 | #define OSBISTRUN 0x01 | ||
1800 | 1504 | ||
1801 | #define SCSISEQ0 0x3a | 1505 | #define SCSISEQ0 0x3a |
1802 | #define TEMODEO 0x80 | 1506 | #define TEMODEO 0x80 |
@@ -1805,15 +1509,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1805 | #define FORCEBUSFREE 0x10 | 1509 | #define FORCEBUSFREE 0x10 |
1806 | #define SCSIRSTO 0x01 | 1510 | #define SCSIRSTO 0x01 |
1807 | 1511 | ||
1808 | #define SCSBIST1 0x3a | ||
1809 | #define NTBISTERR 0x04 | ||
1810 | #define NTBISTDONE 0x02 | ||
1811 | #define NTBISTRUN 0x01 | ||
1812 | |||
1813 | #define SCSISEQ1 0x3b | 1512 | #define SCSISEQ1 0x3b |
1814 | 1513 | ||
1815 | #define BUSINITID 0x3c | ||
1816 | |||
1817 | #define SXFRCTL0 0x3c | 1514 | #define SXFRCTL0 0x3c |
1818 | #define DFON 0x80 | 1515 | #define DFON 0x80 |
1819 | #define DFPEXP 0x40 | 1516 | #define DFPEXP 0x40 |
@@ -1822,6 +1519,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1822 | 1519 | ||
1823 | #define DLCOUNT 0x3c | 1520 | #define DLCOUNT 0x3c |
1824 | 1521 | ||
1522 | #define BUSINITID 0x3c | ||
1523 | |||
1825 | #define SXFRCTL1 0x3d | 1524 | #define SXFRCTL1 0x3d |
1826 | #define BITBUCKET 0x80 | 1525 | #define BITBUCKET 0x80 |
1827 | #define ENSACHK 0x40 | 1526 | #define ENSACHK 0x40 |
@@ -1846,8 +1545,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1846 | #define CURRFIFO_1 0x01 | 1545 | #define CURRFIFO_1 0x01 |
1847 | #define CURRFIFO_0 0x00 | 1546 | #define CURRFIFO_0 0x00 |
1848 | 1547 | ||
1849 | #define MULTARGID 0x40 | ||
1850 | |||
1851 | #define SCSISIGO 0x40 | 1548 | #define SCSISIGO 0x40 |
1852 | #define CDO 0x80 | 1549 | #define CDO 0x80 |
1853 | #define IOO 0x40 | 1550 | #define IOO 0x40 |
@@ -1858,6 +1555,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1858 | #define REQO 0x02 | 1555 | #define REQO 0x02 |
1859 | #define ACKO 0x01 | 1556 | #define ACKO 0x01 |
1860 | 1557 | ||
1558 | #define MULTARGID 0x40 | ||
1559 | |||
1861 | #define SCSISIGI 0x41 | 1560 | #define SCSISIGI 0x41 |
1862 | #define ATNI 0x10 | 1561 | #define ATNI 0x10 |
1863 | #define SELI 0x08 | 1562 | #define SELI 0x08 |
@@ -1904,6 +1603,15 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1904 | #define ENAB20 0x04 | 1603 | #define ENAB20 0x04 |
1905 | #define SELWIDE 0x02 | 1604 | #define SELWIDE 0x02 |
1906 | 1605 | ||
1606 | #define CLRSINT0 0x4b | ||
1607 | #define CLRSELDO 0x40 | ||
1608 | #define CLRSELDI 0x20 | ||
1609 | #define CLRSELINGO 0x10 | ||
1610 | #define CLRIOERR 0x08 | ||
1611 | #define CLROVERRUN 0x04 | ||
1612 | #define CLRSPIORDY 0x02 | ||
1613 | #define CLRARBDO 0x01 | ||
1614 | |||
1907 | #define SSTAT0 0x4b | 1615 | #define SSTAT0 0x4b |
1908 | #define TARGET 0x80 | 1616 | #define TARGET 0x80 |
1909 | #define SELDO 0x40 | 1617 | #define SELDO 0x40 |
@@ -1923,14 +1631,14 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1923 | #define ENSPIORDY 0x02 | 1631 | #define ENSPIORDY 0x02 |
1924 | #define ENARBDO 0x01 | 1632 | #define ENARBDO 0x01 |
1925 | 1633 | ||
1926 | #define CLRSINT0 0x4b | 1634 | #define CLRSINT1 0x4c |
1927 | #define CLRSELDO 0x40 | 1635 | #define CLRSELTIMEO 0x80 |
1928 | #define CLRSELDI 0x20 | 1636 | #define CLRATNO 0x40 |
1929 | #define CLRSELINGO 0x10 | 1637 | #define CLRSCSIRSTI 0x20 |
1930 | #define CLRIOERR 0x08 | 1638 | #define CLRBUSFREE 0x08 |
1931 | #define CLROVERRUN 0x04 | 1639 | #define CLRSCSIPERR 0x04 |
1932 | #define CLRSPIORDY 0x02 | 1640 | #define CLRSTRB2FAST 0x02 |
1933 | #define CLRARBDO 0x01 | 1641 | #define CLRREQINIT 0x01 |
1934 | 1642 | ||
1935 | #define SSTAT1 0x4c | 1643 | #define SSTAT1 0x4c |
1936 | #define SELTO 0x80 | 1644 | #define SELTO 0x80 |
@@ -1942,15 +1650,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1942 | #define STRB2FAST 0x02 | 1650 | #define STRB2FAST 0x02 |
1943 | #define REQINIT 0x01 | 1651 | #define REQINIT 0x01 |
1944 | 1652 | ||
1945 | #define CLRSINT1 0x4c | ||
1946 | #define CLRSELTIMEO 0x80 | ||
1947 | #define CLRATNO 0x40 | ||
1948 | #define CLRSCSIRSTI 0x20 | ||
1949 | #define CLRBUSFREE 0x08 | ||
1950 | #define CLRSCSIPERR 0x04 | ||
1951 | #define CLRSTRB2FAST 0x02 | ||
1952 | #define CLRREQINIT 0x01 | ||
1953 | |||
1954 | #define SSTAT2 0x4d | 1653 | #define SSTAT2 0x4d |
1955 | #define BUSFREETIME 0xc0 | 1654 | #define BUSFREETIME 0xc0 |
1956 | #define NONPACKREQ 0x20 | 1655 | #define NONPACKREQ 0x20 |
@@ -1998,14 +1697,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
1998 | #define LQIATNLQ 0x02 | 1697 | #define LQIATNLQ 0x02 |
1999 | #define LQIATNCMD 0x01 | 1698 | #define LQIATNCMD 0x01 |
2000 | 1699 | ||
2001 | #define LQIMODE0 0x50 | ||
2002 | #define ENLQIATNQASK 0x20 | ||
2003 | #define ENLQICRCT1 0x10 | ||
2004 | #define ENLQICRCT2 0x08 | ||
2005 | #define ENLQIBADLQT 0x04 | ||
2006 | #define ENLQIATNLQ 0x02 | ||
2007 | #define ENLQIATNCMD 0x01 | ||
2008 | |||
2009 | #define CLRLQIINT0 0x50 | 1700 | #define CLRLQIINT0 0x50 |
2010 | #define CLRLQIATNQAS 0x20 | 1701 | #define CLRLQIATNQAS 0x20 |
2011 | #define CLRLQICRCT1 0x10 | 1702 | #define CLRLQICRCT1 0x10 |
@@ -2014,6 +1705,14 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2014 | #define CLRLQIATNLQ 0x02 | 1705 | #define CLRLQIATNLQ 0x02 |
2015 | #define CLRLQIATNCMD 0x01 | 1706 | #define CLRLQIATNCMD 0x01 |
2016 | 1707 | ||
1708 | #define LQIMODE0 0x50 | ||
1709 | #define ENLQIATNQASK 0x20 | ||
1710 | #define ENLQICRCT1 0x10 | ||
1711 | #define ENLQICRCT2 0x08 | ||
1712 | #define ENLQIBADLQT 0x04 | ||
1713 | #define ENLQIATNLQ 0x02 | ||
1714 | #define ENLQIATNCMD 0x01 | ||
1715 | |||
2017 | #define LQIMODE1 0x51 | 1716 | #define LQIMODE1 0x51 |
2018 | #define ENLQIPHASE_LQ 0x80 | 1717 | #define ENLQIPHASE_LQ 0x80 |
2019 | #define ENLQIPHASE_NLQ 0x40 | 1718 | #define ENLQIPHASE_NLQ 0x40 |
@@ -2160,6 +1859,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2160 | #define CFG4ICMD 0x02 | 1859 | #define CFG4ICMD 0x02 |
2161 | #define CFG4TCMD 0x01 | 1860 | #define CFG4TCMD 0x01 |
2162 | 1861 | ||
1862 | #define CURRSCB 0x5c | ||
1863 | |||
2163 | #define SEQIMODE 0x5c | 1864 | #define SEQIMODE 0x5c |
2164 | #define ENCTXTDONE 0x40 | 1865 | #define ENCTXTDONE 0x40 |
2165 | #define ENSAVEPTRS 0x20 | 1866 | #define ENSAVEPTRS 0x20 |
@@ -2169,8 +1870,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2169 | #define ENCFG4ICMD 0x02 | 1870 | #define ENCFG4ICMD 0x02 |
2170 | #define ENCFG4TCMD 0x01 | 1871 | #define ENCFG4TCMD 0x01 |
2171 | 1872 | ||
2172 | #define CURRSCB 0x5c | ||
2173 | |||
2174 | #define MDFFSTAT 0x5d | 1873 | #define MDFFSTAT 0x5d |
2175 | #define SHCNTNEGATIVE 0x40 | 1874 | #define SHCNTNEGATIVE 0x40 |
2176 | #define SHCNTMINUS1 0x20 | 1875 | #define SHCNTMINUS1 0x20 |
@@ -2185,29 +1884,29 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2185 | 1884 | ||
2186 | #define DFFTAG 0x5e | 1885 | #define DFFTAG 0x5e |
2187 | 1886 | ||
1887 | #define LASTSCB 0x5e | ||
1888 | |||
2188 | #define SCSITEST 0x5e | 1889 | #define SCSITEST 0x5e |
2189 | #define CNTRTEST 0x08 | 1890 | #define CNTRTEST 0x08 |
2190 | #define SEL_TXPLL_DEBUG 0x04 | 1891 | #define SEL_TXPLL_DEBUG 0x04 |
2191 | 1892 | ||
2192 | #define LASTSCB 0x5e | ||
2193 | |||
2194 | #define IOPDNCTL 0x5f | 1893 | #define IOPDNCTL 0x5f |
2195 | #define DISABLE_OE 0x80 | 1894 | #define DISABLE_OE 0x80 |
2196 | #define PDN_IDIST 0x04 | 1895 | #define PDN_IDIST 0x04 |
2197 | #define PDN_DIFFSENSE 0x01 | 1896 | #define PDN_DIFFSENSE 0x01 |
2198 | 1897 | ||
2199 | #define DGRPCRCI 0x60 | ||
2200 | |||
2201 | #define SHADDR 0x60 | 1898 | #define SHADDR 0x60 |
2202 | 1899 | ||
2203 | #define NEGOADDR 0x60 | 1900 | #define NEGOADDR 0x60 |
2204 | 1901 | ||
2205 | #define NEGPERIOD 0x61 | 1902 | #define DGRPCRCI 0x60 |
2206 | 1903 | ||
2207 | #define NEGOFFSET 0x62 | 1904 | #define NEGPERIOD 0x61 |
2208 | 1905 | ||
2209 | #define PACKCRCI 0x62 | 1906 | #define PACKCRCI 0x62 |
2210 | 1907 | ||
1908 | #define NEGOFFSET 0x62 | ||
1909 | |||
2211 | #define NEGPPROPTS 0x63 | 1910 | #define NEGPPROPTS 0x63 |
2212 | #define PPROPT_PACE 0x08 | 1911 | #define PPROPT_PACE 0x08 |
2213 | #define PPROPT_QAS 0x04 | 1912 | #define PPROPT_QAS 0x04 |
@@ -2253,8 +1952,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2253 | 1952 | ||
2254 | #define SELOID 0x6b | 1953 | #define SELOID 0x6b |
2255 | 1954 | ||
2256 | #define FAIRNESS 0x6c | ||
2257 | |||
2258 | #define PLL400CTL0 0x6c | 1955 | #define PLL400CTL0 0x6c |
2259 | #define PLL_VCOSEL 0x80 | 1956 | #define PLL_VCOSEL 0x80 |
2260 | #define PLL_PWDN 0x40 | 1957 | #define PLL_PWDN 0x40 |
@@ -2264,6 +1961,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2264 | #define PLL_DLPF 0x02 | 1961 | #define PLL_DLPF 0x02 |
2265 | #define PLL_ENFBM 0x01 | 1962 | #define PLL_ENFBM 0x01 |
2266 | 1963 | ||
1964 | #define FAIRNESS 0x6c | ||
1965 | |||
2267 | #define PLL400CTL1 0x6d | 1966 | #define PLL400CTL1 0x6d |
2268 | #define PLL_CNTEN 0x80 | 1967 | #define PLL_CNTEN 0x80 |
2269 | #define PLL_CNTCLR 0x40 | 1968 | #define PLL_CNTCLR 0x40 |
@@ -2275,25 +1974,25 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2275 | 1974 | ||
2276 | #define HADDR 0x70 | 1975 | #define HADDR 0x70 |
2277 | 1976 | ||
2278 | #define HODMAADR 0x70 | ||
2279 | |||
2280 | #define PLLDELAY 0x70 | 1977 | #define PLLDELAY 0x70 |
2281 | #define SPLIT_DROP_REQ 0x80 | 1978 | #define SPLIT_DROP_REQ 0x80 |
2282 | 1979 | ||
2283 | #define HCNT 0x78 | 1980 | #define HODMAADR 0x70 |
2284 | 1981 | ||
2285 | #define HODMACNT 0x78 | 1982 | #define HODMACNT 0x78 |
2286 | 1983 | ||
2287 | #define HODMAEN 0x7a | 1984 | #define HCNT 0x78 |
2288 | 1985 | ||
2289 | #define SGHADDR 0x7c | 1986 | #define HODMAEN 0x7a |
2290 | 1987 | ||
2291 | #define SCBHADDR 0x7c | 1988 | #define SCBHADDR 0x7c |
2292 | 1989 | ||
2293 | #define SGHCNT 0x84 | 1990 | #define SGHADDR 0x7c |
2294 | 1991 | ||
2295 | #define SCBHCNT 0x84 | 1992 | #define SCBHCNT 0x84 |
2296 | 1993 | ||
1994 | #define SGHCNT 0x84 | ||
1995 | |||
2297 | #define DFF_THRSH 0x88 | 1996 | #define DFF_THRSH 0x88 |
2298 | #define WR_DFTHRSH 0x70 | 1997 | #define WR_DFTHRSH 0x70 |
2299 | #define RD_DFTHRSH 0x07 | 1998 | #define RD_DFTHRSH 0x07 |
@@ -2326,10 +2025,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2326 | 2025 | ||
2327 | #define CMCRXMSG0 0x90 | 2026 | #define CMCRXMSG0 0x90 |
2328 | 2027 | ||
2329 | #define OVLYRXMSG0 0x90 | ||
2330 | |||
2331 | #define DCHRXMSG0 0x90 | ||
2332 | |||
2333 | #define ROENABLE 0x90 | 2028 | #define ROENABLE 0x90 |
2334 | #define MSIROEN 0x20 | 2029 | #define MSIROEN 0x20 |
2335 | #define OVLYROEN 0x10 | 2030 | #define OVLYROEN 0x10 |
@@ -2338,11 +2033,11 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2338 | #define DCH1ROEN 0x02 | 2033 | #define DCH1ROEN 0x02 |
2339 | #define DCH0ROEN 0x01 | 2034 | #define DCH0ROEN 0x01 |
2340 | 2035 | ||
2341 | #define OVLYRXMSG1 0x91 | 2036 | #define OVLYRXMSG0 0x90 |
2342 | 2037 | ||
2343 | #define CMCRXMSG1 0x91 | 2038 | #define DCHRXMSG0 0x90 |
2344 | 2039 | ||
2345 | #define DCHRXMSG1 0x91 | 2040 | #define OVLYRXMSG1 0x91 |
2346 | 2041 | ||
2347 | #define NSENABLE 0x91 | 2042 | #define NSENABLE 0x91 |
2348 | #define MSINSEN 0x20 | 2043 | #define MSINSEN 0x20 |
@@ -2352,6 +2047,10 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2352 | #define DCH1NSEN 0x02 | 2047 | #define DCH1NSEN 0x02 |
2353 | #define DCH0NSEN 0x01 | 2048 | #define DCH0NSEN 0x01 |
2354 | 2049 | ||
2050 | #define CMCRXMSG1 0x91 | ||
2051 | |||
2052 | #define DCHRXMSG1 0x91 | ||
2053 | |||
2355 | #define DCHRXMSG2 0x92 | 2054 | #define DCHRXMSG2 0x92 |
2356 | 2055 | ||
2357 | #define CMCRXMSG2 0x92 | 2056 | #define CMCRXMSG2 0x92 |
@@ -2375,24 +2074,24 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2375 | #define TSCSERREN 0x02 | 2074 | #define TSCSERREN 0x02 |
2376 | #define CMPABCDIS 0x01 | 2075 | #define CMPABCDIS 0x01 |
2377 | 2076 | ||
2378 | #define CMCSEQBCNT 0x94 | ||
2379 | |||
2380 | #define OVLYSEQBCNT 0x94 | 2077 | #define OVLYSEQBCNT 0x94 |
2381 | 2078 | ||
2382 | #define DCHSEQBCNT 0x94 | 2079 | #define DCHSEQBCNT 0x94 |
2383 | 2080 | ||
2081 | #define CMCSEQBCNT 0x94 | ||
2082 | |||
2083 | #define CMCSPLTSTAT0 0x96 | ||
2084 | |||
2384 | #define DCHSPLTSTAT0 0x96 | 2085 | #define DCHSPLTSTAT0 0x96 |
2385 | 2086 | ||
2386 | #define OVLYSPLTSTAT0 0x96 | 2087 | #define OVLYSPLTSTAT0 0x96 |
2387 | 2088 | ||
2388 | #define CMCSPLTSTAT0 0x96 | 2089 | #define CMCSPLTSTAT1 0x97 |
2389 | 2090 | ||
2390 | #define OVLYSPLTSTAT1 0x97 | 2091 | #define OVLYSPLTSTAT1 0x97 |
2391 | 2092 | ||
2392 | #define DCHSPLTSTAT1 0x97 | 2093 | #define DCHSPLTSTAT1 0x97 |
2393 | 2094 | ||
2394 | #define CMCSPLTSTAT1 0x97 | ||
2395 | |||
2396 | #define SGRXMSG0 0x98 | 2095 | #define SGRXMSG0 0x98 |
2397 | #define CDNUM 0xf8 | 2096 | #define CDNUM 0xf8 |
2398 | #define CFNUM 0x07 | 2097 | #define CFNUM 0x07 |
@@ -2420,15 +2119,18 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2420 | #define TAG_NUM 0x1f | 2119 | #define TAG_NUM 0x1f |
2421 | #define RLXORD 0x10 | 2120 | #define RLXORD 0x10 |
2422 | 2121 | ||
2122 | #define SGSEQBCNT 0x9c | ||
2123 | |||
2423 | #define SLVSPLTOUTATTR0 0x9c | 2124 | #define SLVSPLTOUTATTR0 0x9c |
2424 | #define LOWER_BCNT 0xff | 2125 | #define LOWER_BCNT 0xff |
2425 | 2126 | ||
2426 | #define SGSEQBCNT 0x9c | ||
2427 | |||
2428 | #define SLVSPLTOUTATTR1 0x9d | 2127 | #define SLVSPLTOUTATTR1 0x9d |
2429 | #define CMPLT_DNUM 0xf8 | 2128 | #define CMPLT_DNUM 0xf8 |
2430 | #define CMPLT_FNUM 0x07 | 2129 | #define CMPLT_FNUM 0x07 |
2431 | 2130 | ||
2131 | #define SLVSPLTOUTATTR2 0x9e | ||
2132 | #define CMPLT_BNUM 0xff | ||
2133 | |||
2432 | #define SGSPLTSTAT0 0x9e | 2134 | #define SGSPLTSTAT0 0x9e |
2433 | #define STAETERM 0x80 | 2135 | #define STAETERM 0x80 |
2434 | #define SCBCERR 0x40 | 2136 | #define SCBCERR 0x40 |
@@ -2439,9 +2141,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2439 | #define RXSCEMSG 0x02 | 2141 | #define RXSCEMSG 0x02 |
2440 | #define RXSPLTRSP 0x01 | 2142 | #define RXSPLTRSP 0x01 |
2441 | 2143 | ||
2442 | #define SLVSPLTOUTATTR2 0x9e | ||
2443 | #define CMPLT_BNUM 0xff | ||
2444 | |||
2445 | #define SGSPLTSTAT1 0x9f | 2144 | #define SGSPLTSTAT1 0x9f |
2446 | #define RXDATABUCKET 0x01 | 2145 | #define RXDATABUCKET 0x01 |
2447 | 2146 | ||
@@ -2497,10 +2196,10 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2497 | 2196 | ||
2498 | #define CCSGADDR 0xac | 2197 | #define CCSGADDR 0xac |
2499 | 2198 | ||
2500 | #define CCSCBADDR 0xac | ||
2501 | |||
2502 | #define CCSCBADR_BK 0xac | 2199 | #define CCSCBADR_BK 0xac |
2503 | 2200 | ||
2201 | #define CCSCBADDR 0xac | ||
2202 | |||
2504 | #define CMC_RAMBIST 0xad | 2203 | #define CMC_RAMBIST 0xad |
2505 | #define SG_ELEMENT_SIZE 0x80 | 2204 | #define SG_ELEMENT_SIZE 0x80 |
2506 | #define SCBRAMBIST_FAIL 0x40 | 2205 | #define SCBRAMBIST_FAIL 0x40 |
@@ -2554,9 +2253,9 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2554 | #define SEEDAT 0xbc | 2253 | #define SEEDAT 0xbc |
2555 | 2254 | ||
2556 | #define SEECTL 0xbe | 2255 | #define SEECTL 0xbe |
2557 | #define SEEOP_EWDS 0x40 | ||
2558 | #define SEEOP_WALL 0x40 | 2256 | #define SEEOP_WALL 0x40 |
2559 | #define SEEOP_EWEN 0x40 | 2257 | #define SEEOP_EWEN 0x40 |
2258 | #define SEEOP_EWDS 0x40 | ||
2560 | #define SEEOPCODE 0x70 | 2259 | #define SEEOPCODE 0x70 |
2561 | #define SEERST 0x02 | 2260 | #define SEERST 0x02 |
2562 | #define SEESTART 0x01 | 2261 | #define SEESTART 0x01 |
@@ -2573,25 +2272,25 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2573 | 2272 | ||
2574 | #define SCBCNT 0xbf | 2273 | #define SCBCNT 0xbf |
2575 | 2274 | ||
2275 | #define DFWADDR 0xc0 | ||
2276 | |||
2576 | #define DSPFLTRCTL 0xc0 | 2277 | #define DSPFLTRCTL 0xc0 |
2577 | #define FLTRDISABLE 0x20 | 2278 | #define FLTRDISABLE 0x20 |
2578 | #define EDGESENSE 0x10 | 2279 | #define EDGESENSE 0x10 |
2579 | #define DSPFCNTSEL 0x0f | 2280 | #define DSPFCNTSEL 0x0f |
2580 | 2281 | ||
2581 | #define DFWADDR 0xc0 | ||
2582 | |||
2583 | #define DSPDATACTL 0xc1 | 2282 | #define DSPDATACTL 0xc1 |
2584 | #define BYPASSENAB 0x80 | 2283 | #define BYPASSENAB 0x80 |
2585 | #define DESQDIS 0x10 | 2284 | #define DESQDIS 0x10 |
2586 | #define RCVROFFSTDIS 0x04 | 2285 | #define RCVROFFSTDIS 0x04 |
2587 | #define XMITOFFSTDIS 0x02 | 2286 | #define XMITOFFSTDIS 0x02 |
2588 | 2287 | ||
2288 | #define DFRADDR 0xc2 | ||
2289 | |||
2589 | #define DSPREQCTL 0xc2 | 2290 | #define DSPREQCTL 0xc2 |
2590 | #define MANREQCTL 0xc0 | 2291 | #define MANREQCTL 0xc0 |
2591 | #define MANREQDLY 0x3f | 2292 | #define MANREQDLY 0x3f |
2592 | 2293 | ||
2593 | #define DFRADDR 0xc2 | ||
2594 | |||
2595 | #define DSPACKCTL 0xc3 | 2294 | #define DSPACKCTL 0xc3 |
2596 | #define MANACKCTL 0xc0 | 2295 | #define MANACKCTL 0xc0 |
2597 | #define MANACKDLY 0x3f | 2296 | #define MANACKDLY 0x3f |
@@ -2612,14 +2311,14 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2612 | 2311 | ||
2613 | #define WRTBIASCALC 0xc7 | 2312 | #define WRTBIASCALC 0xc7 |
2614 | 2313 | ||
2615 | #define DFPTRS 0xc8 | ||
2616 | |||
2617 | #define RCVRBIASCALC 0xc8 | 2314 | #define RCVRBIASCALC 0xc8 |
2618 | 2315 | ||
2619 | #define DFBKPTR 0xc9 | 2316 | #define DFPTRS 0xc8 |
2620 | 2317 | ||
2621 | #define SKEWCALC 0xc9 | 2318 | #define SKEWCALC 0xc9 |
2622 | 2319 | ||
2320 | #define DFBKPTR 0xc9 | ||
2321 | |||
2623 | #define DFDBCTL 0xcb | 2322 | #define DFDBCTL 0xcb |
2624 | #define DFF_CIO_WR_RDY 0x20 | 2323 | #define DFF_CIO_WR_RDY 0x20 |
2625 | #define DFF_CIO_RD_RDY 0x10 | 2324 | #define DFF_CIO_RD_RDY 0x10 |
@@ -2704,12 +2403,12 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2704 | 2403 | ||
2705 | #define ACCUM_SAVE 0xfa | 2404 | #define ACCUM_SAVE 0xfa |
2706 | 2405 | ||
2406 | #define WAITING_SCB_TAILS 0x100 | ||
2407 | |||
2707 | #define AHD_PCI_CONFIG_BASE 0x100 | 2408 | #define AHD_PCI_CONFIG_BASE 0x100 |
2708 | 2409 | ||
2709 | #define SRAM_BASE 0x100 | 2410 | #define SRAM_BASE 0x100 |
2710 | 2411 | ||
2711 | #define WAITING_SCB_TAILS 0x100 | ||
2712 | |||
2713 | #define WAITING_TID_HEAD 0x120 | 2412 | #define WAITING_TID_HEAD 0x120 |
2714 | 2413 | ||
2715 | #define WAITING_TID_TAIL 0x122 | 2414 | #define WAITING_TID_TAIL 0x122 |
@@ -2738,8 +2437,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2738 | #define PRELOADEN 0x80 | 2437 | #define PRELOADEN 0x80 |
2739 | #define WIDEODD 0x40 | 2438 | #define WIDEODD 0x40 |
2740 | #define SCSIEN 0x20 | 2439 | #define SCSIEN 0x20 |
2741 | #define SDMAENACK 0x10 | ||
2742 | #define SDMAEN 0x10 | 2440 | #define SDMAEN 0x10 |
2441 | #define SDMAENACK 0x10 | ||
2743 | #define HDMAEN 0x08 | 2442 | #define HDMAEN 0x08 |
2744 | #define HDMAENACK 0x08 | 2443 | #define HDMAENACK 0x08 |
2745 | #define DIRECTION 0x04 | 2444 | #define DIRECTION 0x04 |
@@ -2837,12 +2536,12 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2837 | 2536 | ||
2838 | #define MK_MESSAGE_SCSIID 0x162 | 2537 | #define MK_MESSAGE_SCSIID 0x162 |
2839 | 2538 | ||
2539 | #define SCB_BASE 0x180 | ||
2540 | |||
2840 | #define SCB_RESIDUAL_DATACNT 0x180 | 2541 | #define SCB_RESIDUAL_DATACNT 0x180 |
2841 | #define SCB_CDB_STORE 0x180 | 2542 | #define SCB_CDB_STORE 0x180 |
2842 | #define SCB_HOST_CDB_PTR 0x180 | 2543 | #define SCB_HOST_CDB_PTR 0x180 |
2843 | 2544 | ||
2844 | #define SCB_BASE 0x180 | ||
2845 | |||
2846 | #define SCB_RESIDUAL_SGPTR 0x184 | 2545 | #define SCB_RESIDUAL_SGPTR 0x184 |
2847 | #define SG_ADDR_MASK 0xf8 | 2546 | #define SG_ADDR_MASK 0xf8 |
2848 | #define SG_OVERRUN_RESID 0x02 | 2547 | #define SG_OVERRUN_RESID 0x02 |
@@ -2910,17 +2609,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2910 | #define SCB_DISCONNECTED_LISTS 0x1b8 | 2609 | #define SCB_DISCONNECTED_LISTS 0x1b8 |
2911 | 2610 | ||
2912 | 2611 | ||
2913 | #define CMD_GROUP_CODE_SHIFT 0x05 | ||
2914 | #define STIMESEL_MIN 0x18 | ||
2915 | #define STIMESEL_SHIFT 0x03 | ||
2916 | #define INVALID_ADDR 0x80 | ||
2917 | #define AHD_PRECOMP_MASK 0x07 | ||
2918 | #define TARGET_DATA_IN 0x01 | ||
2919 | #define CCSCBADDR_MAX 0x80 | ||
2920 | #define NUMDSPS 0x14 | ||
2921 | #define SEEOP_EWEN_ADDR 0xc0 | ||
2922 | #define AHD_ANNEXCOL_PER_DEV0 0x04 | ||
2923 | #define DST_MODE_SHIFT 0x04 | ||
2924 | #define AHD_TIMER_MAX_US 0x18ffe7 | 2612 | #define AHD_TIMER_MAX_US 0x18ffe7 |
2925 | #define AHD_TIMER_MAX_TICKS 0xffff | 2613 | #define AHD_TIMER_MAX_TICKS 0xffff |
2926 | #define AHD_SENSE_BUFSIZE 0x100 | 2614 | #define AHD_SENSE_BUFSIZE 0x100 |
@@ -2955,32 +2643,43 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
2955 | #define LUNLEN_SINGLE_LEVEL_LUN 0x0f | 2643 | #define LUNLEN_SINGLE_LEVEL_LUN 0x0f |
2956 | #define NVRAM_SCB_OFFSET 0x2c | 2644 | #define NVRAM_SCB_OFFSET 0x2c |
2957 | #define STATUS_PKT_SENSE 0xff | 2645 | #define STATUS_PKT_SENSE 0xff |
2646 | #define CMD_GROUP_CODE_SHIFT 0x05 | ||
2958 | #define MAX_OFFSET_PACED_BUG 0x7f | 2647 | #define MAX_OFFSET_PACED_BUG 0x7f |
2959 | #define STIMESEL_BUG_ADJ 0x08 | 2648 | #define STIMESEL_BUG_ADJ 0x08 |
2649 | #define STIMESEL_MIN 0x18 | ||
2650 | #define STIMESEL_SHIFT 0x03 | ||
2960 | #define CCSGRAM_MAXSEGS 0x10 | 2651 | #define CCSGRAM_MAXSEGS 0x10 |
2652 | #define INVALID_ADDR 0x80 | ||
2961 | #define SEEOP_ERAL_ADDR 0x80 | 2653 | #define SEEOP_ERAL_ADDR 0x80 |
2962 | #define AHD_SLEWRATE_DEF_REVB 0x08 | 2654 | #define AHD_SLEWRATE_DEF_REVB 0x08 |
2963 | #define AHD_PRECOMP_CUTBACK_17 0x04 | 2655 | #define AHD_PRECOMP_CUTBACK_17 0x04 |
2656 | #define AHD_PRECOMP_MASK 0x07 | ||
2964 | #define SRC_MODE_SHIFT 0x00 | 2657 | #define SRC_MODE_SHIFT 0x00 |
2965 | #define PKT_OVERRUN_BUFSIZE 0x200 | 2658 | #define PKT_OVERRUN_BUFSIZE 0x200 |
2966 | #define SCB_TRANSFER_SIZE_1BYTE_LUN 0x30 | 2659 | #define SCB_TRANSFER_SIZE_1BYTE_LUN 0x30 |
2660 | #define TARGET_DATA_IN 0x01 | ||
2967 | #define HOST_MSG 0xff | 2661 | #define HOST_MSG 0xff |
2968 | #define MAX_OFFSET 0xfe | 2662 | #define MAX_OFFSET 0xfe |
2969 | #define BUS_16_BIT 0x01 | 2663 | #define BUS_16_BIT 0x01 |
2664 | #define CCSCBADDR_MAX 0x80 | ||
2665 | #define NUMDSPS 0x14 | ||
2666 | #define SEEOP_EWEN_ADDR 0xc0 | ||
2667 | #define AHD_ANNEXCOL_PER_DEV0 0x04 | ||
2668 | #define DST_MODE_SHIFT 0x04 | ||
2970 | 2669 | ||
2971 | 2670 | ||
2972 | /* Downloaded Constant Definitions */ | 2671 | /* Downloaded Constant Definitions */ |
2973 | #define SG_SIZEOF 0x04 | ||
2974 | #define SG_PREFETCH_ALIGN_MASK 0x02 | ||
2975 | #define SG_PREFETCH_CNT_LIMIT 0x01 | ||
2976 | #define CACHELINE_MASK 0x07 | 2672 | #define CACHELINE_MASK 0x07 |
2977 | #define SCB_TRANSFER_SIZE 0x06 | 2673 | #define SCB_TRANSFER_SIZE 0x06 |
2978 | #define PKT_OVERRUN_BUFOFFSET 0x05 | 2674 | #define PKT_OVERRUN_BUFOFFSET 0x05 |
2675 | #define SG_SIZEOF 0x04 | ||
2979 | #define SG_PREFETCH_ADDR_MASK 0x03 | 2676 | #define SG_PREFETCH_ADDR_MASK 0x03 |
2677 | #define SG_PREFETCH_ALIGN_MASK 0x02 | ||
2678 | #define SG_PREFETCH_CNT_LIMIT 0x01 | ||
2980 | #define SG_PREFETCH_CNT 0x00 | 2679 | #define SG_PREFETCH_CNT 0x00 |
2981 | #define DOWNLOAD_CONST_COUNT 0x08 | 2680 | #define DOWNLOAD_CONST_COUNT 0x08 |
2982 | 2681 | ||
2983 | 2682 | ||
2984 | /* Exported Labels */ | 2683 | /* Exported Labels */ |
2985 | #define LABEL_timer_isr 0x28b | ||
2986 | #define LABEL_seq_isr 0x28f | 2684 | #define LABEL_seq_isr 0x28f |
2685 | #define LABEL_timer_isr 0x28b | ||
diff --git a/drivers/scsi/aic7xxx/aic79xx_reg_print.c_shipped b/drivers/scsi/aic7xxx/aic79xx_reg_print.c_shipped index c4c8a96bf5a3..f5ea715d6ac3 100644 --- a/drivers/scsi/aic7xxx/aic79xx_reg_print.c_shipped +++ b/drivers/scsi/aic7xxx/aic79xx_reg_print.c_shipped | |||
@@ -8,18 +8,6 @@ | |||
8 | 8 | ||
9 | #include "aic79xx_osm.h" | 9 | #include "aic79xx_osm.h" |
10 | 10 | ||
11 | static const ahd_reg_parse_entry_t MODE_PTR_parse_table[] = { | ||
12 | { "SRC_MODE", 0x07, 0x07 }, | ||
13 | { "DST_MODE", 0x70, 0x70 } | ||
14 | }; | ||
15 | |||
16 | int | ||
17 | ahd_mode_ptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
18 | { | ||
19 | return (ahd_print_register(MODE_PTR_parse_table, 2, "MODE_PTR", | ||
20 | 0x00, regvalue, cur_col, wrap)); | ||
21 | } | ||
22 | |||
23 | static const ahd_reg_parse_entry_t INTSTAT_parse_table[] = { | 11 | static const ahd_reg_parse_entry_t INTSTAT_parse_table[] = { |
24 | { "SPLTINT", 0x01, 0x01 }, | 12 | { "SPLTINT", 0x01, 0x01 }, |
25 | { "CMDCMPLT", 0x02, 0x02 }, | 13 | { "CMDCMPLT", 0x02, 0x02 }, |
@@ -39,110 +27,6 @@ ahd_intstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
39 | 0x01, regvalue, cur_col, wrap)); | 27 | 0x01, regvalue, cur_col, wrap)); |
40 | } | 28 | } |
41 | 29 | ||
42 | static const ahd_reg_parse_entry_t SEQINTCODE_parse_table[] = { | ||
43 | { "NO_SEQINT", 0x00, 0xff }, | ||
44 | { "BAD_PHASE", 0x01, 0xff }, | ||
45 | { "SEND_REJECT", 0x02, 0xff }, | ||
46 | { "PROTO_VIOLATION", 0x03, 0xff }, | ||
47 | { "NO_MATCH", 0x04, 0xff }, | ||
48 | { "IGN_WIDE_RES", 0x05, 0xff }, | ||
49 | { "PDATA_REINIT", 0x06, 0xff }, | ||
50 | { "HOST_MSG_LOOP", 0x07, 0xff }, | ||
51 | { "BAD_STATUS", 0x08, 0xff }, | ||
52 | { "DATA_OVERRUN", 0x09, 0xff }, | ||
53 | { "MKMSG_FAILED", 0x0a, 0xff }, | ||
54 | { "MISSED_BUSFREE", 0x0b, 0xff }, | ||
55 | { "DUMP_CARD_STATE", 0x0c, 0xff }, | ||
56 | { "ILLEGAL_PHASE", 0x0d, 0xff }, | ||
57 | { "INVALID_SEQINT", 0x0e, 0xff }, | ||
58 | { "CFG4ISTAT_INTR", 0x0f, 0xff }, | ||
59 | { "STATUS_OVERRUN", 0x10, 0xff }, | ||
60 | { "CFG4OVERRUN", 0x11, 0xff }, | ||
61 | { "ENTERING_NONPACK", 0x12, 0xff }, | ||
62 | { "TASKMGMT_FUNC_COMPLETE",0x13, 0xff }, | ||
63 | { "TASKMGMT_CMD_CMPLT_OKAY",0x14, 0xff }, | ||
64 | { "TRACEPOINT0", 0x15, 0xff }, | ||
65 | { "TRACEPOINT1", 0x16, 0xff }, | ||
66 | { "TRACEPOINT2", 0x17, 0xff }, | ||
67 | { "TRACEPOINT3", 0x18, 0xff }, | ||
68 | { "SAW_HWERR", 0x19, 0xff }, | ||
69 | { "BAD_SCB_STATUS", 0x1a, 0xff } | ||
70 | }; | ||
71 | |||
72 | int | ||
73 | ahd_seqintcode_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
74 | { | ||
75 | return (ahd_print_register(SEQINTCODE_parse_table, 27, "SEQINTCODE", | ||
76 | 0x02, regvalue, cur_col, wrap)); | ||
77 | } | ||
78 | |||
79 | static const ahd_reg_parse_entry_t CLRINT_parse_table[] = { | ||
80 | { "CLRSPLTINT", 0x01, 0x01 }, | ||
81 | { "CLRCMDINT", 0x02, 0x02 }, | ||
82 | { "CLRSEQINT", 0x04, 0x04 }, | ||
83 | { "CLRSCSIINT", 0x08, 0x08 }, | ||
84 | { "CLRPCIINT", 0x10, 0x10 }, | ||
85 | { "CLRSWTMINT", 0x20, 0x20 }, | ||
86 | { "CLRBRKADRINT", 0x40, 0x40 }, | ||
87 | { "CLRHWERRINT", 0x80, 0x80 } | ||
88 | }; | ||
89 | |||
90 | int | ||
91 | ahd_clrint_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
92 | { | ||
93 | return (ahd_print_register(CLRINT_parse_table, 8, "CLRINT", | ||
94 | 0x03, regvalue, cur_col, wrap)); | ||
95 | } | ||
96 | |||
97 | static const ahd_reg_parse_entry_t ERROR_parse_table[] = { | ||
98 | { "DSCTMOUT", 0x02, 0x02 }, | ||
99 | { "ILLOPCODE", 0x04, 0x04 }, | ||
100 | { "SQPARERR", 0x08, 0x08 }, | ||
101 | { "DPARERR", 0x10, 0x10 }, | ||
102 | { "MPARERR", 0x20, 0x20 }, | ||
103 | { "CIOACCESFAIL", 0x40, 0x40 }, | ||
104 | { "CIOPARERR", 0x80, 0x80 } | ||
105 | }; | ||
106 | |||
107 | int | ||
108 | ahd_error_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
109 | { | ||
110 | return (ahd_print_register(ERROR_parse_table, 7, "ERROR", | ||
111 | 0x04, regvalue, cur_col, wrap)); | ||
112 | } | ||
113 | |||
114 | static const ahd_reg_parse_entry_t HCNTRL_parse_table[] = { | ||
115 | { "CHIPRST", 0x01, 0x01 }, | ||
116 | { "CHIPRSTACK", 0x01, 0x01 }, | ||
117 | { "INTEN", 0x02, 0x02 }, | ||
118 | { "PAUSE", 0x04, 0x04 }, | ||
119 | { "SWTIMER_START_B", 0x08, 0x08 }, | ||
120 | { "SWINT", 0x10, 0x10 }, | ||
121 | { "POWRDN", 0x40, 0x40 }, | ||
122 | { "SEQ_RESET", 0x80, 0x80 } | ||
123 | }; | ||
124 | |||
125 | int | ||
126 | ahd_hcntrl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
127 | { | ||
128 | return (ahd_print_register(HCNTRL_parse_table, 8, "HCNTRL", | ||
129 | 0x05, regvalue, cur_col, wrap)); | ||
130 | } | ||
131 | |||
132 | int | ||
133 | ahd_hnscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
134 | { | ||
135 | return (ahd_print_register(NULL, 0, "HNSCB_QOFF", | ||
136 | 0x06, regvalue, cur_col, wrap)); | ||
137 | } | ||
138 | |||
139 | int | ||
140 | ahd_hescb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
141 | { | ||
142 | return (ahd_print_register(NULL, 0, "HESCB_QOFF", | ||
143 | 0x08, regvalue, cur_col, wrap)); | ||
144 | } | ||
145 | |||
146 | static const ahd_reg_parse_entry_t HS_MAILBOX_parse_table[] = { | 30 | static const ahd_reg_parse_entry_t HS_MAILBOX_parse_table[] = { |
147 | { "ENINT_COALESCE", 0x40, 0x40 }, | 31 | { "ENINT_COALESCE", 0x40, 0x40 }, |
148 | { "HOST_TQINPOS", 0x80, 0x80 } | 32 | { "HOST_TQINPOS", 0x80, 0x80 } |
@@ -170,77 +54,6 @@ ahd_seqintstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
170 | 0x0c, regvalue, cur_col, wrap)); | 54 | 0x0c, regvalue, cur_col, wrap)); |
171 | } | 55 | } |
172 | 56 | ||
173 | static const ahd_reg_parse_entry_t CLRSEQINTSTAT_parse_table[] = { | ||
174 | { "CLRSEQ_SPLTINT", 0x01, 0x01 }, | ||
175 | { "CLRSEQ_PCIINT", 0x02, 0x02 }, | ||
176 | { "CLRSEQ_SCSIINT", 0x04, 0x04 }, | ||
177 | { "CLRSEQ_SEQINT", 0x08, 0x08 }, | ||
178 | { "CLRSEQ_SWTMRTO", 0x10, 0x10 } | ||
179 | }; | ||
180 | |||
181 | int | ||
182 | ahd_clrseqintstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
183 | { | ||
184 | return (ahd_print_register(CLRSEQINTSTAT_parse_table, 5, "CLRSEQINTSTAT", | ||
185 | 0x0c, regvalue, cur_col, wrap)); | ||
186 | } | ||
187 | |||
188 | int | ||
189 | ahd_swtimer_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
190 | { | ||
191 | return (ahd_print_register(NULL, 0, "SWTIMER", | ||
192 | 0x0e, regvalue, cur_col, wrap)); | ||
193 | } | ||
194 | |||
195 | int | ||
196 | ahd_snscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
197 | { | ||
198 | return (ahd_print_register(NULL, 0, "SNSCB_QOFF", | ||
199 | 0x10, regvalue, cur_col, wrap)); | ||
200 | } | ||
201 | |||
202 | int | ||
203 | ahd_sescb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
204 | { | ||
205 | return (ahd_print_register(NULL, 0, "SESCB_QOFF", | ||
206 | 0x12, regvalue, cur_col, wrap)); | ||
207 | } | ||
208 | |||
209 | int | ||
210 | ahd_sdscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
211 | { | ||
212 | return (ahd_print_register(NULL, 0, "SDSCB_QOFF", | ||
213 | 0x14, regvalue, cur_col, wrap)); | ||
214 | } | ||
215 | |||
216 | static const ahd_reg_parse_entry_t QOFF_CTLSTA_parse_table[] = { | ||
217 | { "SCB_QSIZE_4", 0x00, 0x0f }, | ||
218 | { "SCB_QSIZE_8", 0x01, 0x0f }, | ||
219 | { "SCB_QSIZE_16", 0x02, 0x0f }, | ||
220 | { "SCB_QSIZE_32", 0x03, 0x0f }, | ||
221 | { "SCB_QSIZE_64", 0x04, 0x0f }, | ||
222 | { "SCB_QSIZE_128", 0x05, 0x0f }, | ||
223 | { "SCB_QSIZE_256", 0x06, 0x0f }, | ||
224 | { "SCB_QSIZE_512", 0x07, 0x0f }, | ||
225 | { "SCB_QSIZE_1024", 0x08, 0x0f }, | ||
226 | { "SCB_QSIZE_2048", 0x09, 0x0f }, | ||
227 | { "SCB_QSIZE_4096", 0x0a, 0x0f }, | ||
228 | { "SCB_QSIZE_8192", 0x0b, 0x0f }, | ||
229 | { "SCB_QSIZE_16384", 0x0c, 0x0f }, | ||
230 | { "SCB_QSIZE", 0x0f, 0x0f }, | ||
231 | { "HS_MAILBOX_ACT", 0x10, 0x10 }, | ||
232 | { "SDSCB_ROLLOVR", 0x20, 0x20 }, | ||
233 | { "NEW_SCB_AVAIL", 0x40, 0x40 }, | ||
234 | { "EMPTY_SCB_AVAIL", 0x80, 0x80 } | ||
235 | }; | ||
236 | |||
237 | int | ||
238 | ahd_qoff_ctlsta_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
239 | { | ||
240 | return (ahd_print_register(QOFF_CTLSTA_parse_table, 18, "QOFF_CTLSTA", | ||
241 | 0x16, regvalue, cur_col, wrap)); | ||
242 | } | ||
243 | |||
244 | static const ahd_reg_parse_entry_t INTCTL_parse_table[] = { | 57 | static const ahd_reg_parse_entry_t INTCTL_parse_table[] = { |
245 | { "SPLTINTEN", 0x01, 0x01 }, | 58 | { "SPLTINTEN", 0x01, 0x01 }, |
246 | { "SEQINTEN", 0x02, 0x02 }, | 59 | { "SEQINTEN", 0x02, 0x02 }, |
@@ -280,22 +93,6 @@ ahd_dfcntrl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
280 | 0x19, regvalue, cur_col, wrap)); | 93 | 0x19, regvalue, cur_col, wrap)); |
281 | } | 94 | } |
282 | 95 | ||
283 | static const ahd_reg_parse_entry_t DSCOMMAND0_parse_table[] = { | ||
284 | { "CIOPARCKEN", 0x01, 0x01 }, | ||
285 | { "DISABLE_TWATE", 0x02, 0x02 }, | ||
286 | { "EXTREQLCK", 0x10, 0x10 }, | ||
287 | { "MPARCKEN", 0x20, 0x20 }, | ||
288 | { "DPARCKEN", 0x40, 0x40 }, | ||
289 | { "CACHETHEN", 0x80, 0x80 } | ||
290 | }; | ||
291 | |||
292 | int | ||
293 | ahd_dscommand0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
294 | { | ||
295 | return (ahd_print_register(DSCOMMAND0_parse_table, 6, "DSCOMMAND0", | ||
296 | 0x19, regvalue, cur_col, wrap)); | ||
297 | } | ||
298 | |||
299 | static const ahd_reg_parse_entry_t DFSTATUS_parse_table[] = { | 96 | static const ahd_reg_parse_entry_t DFSTATUS_parse_table[] = { |
300 | { "FIFOEMP", 0x01, 0x01 }, | 97 | { "FIFOEMP", 0x01, 0x01 }, |
301 | { "FIFOFULL", 0x02, 0x02 }, | 98 | { "FIFOFULL", 0x02, 0x02 }, |
@@ -327,146 +124,6 @@ ahd_sg_cache_shadow_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
327 | 0x1b, regvalue, cur_col, wrap)); | 124 | 0x1b, regvalue, cur_col, wrap)); |
328 | } | 125 | } |
329 | 126 | ||
330 | static const ahd_reg_parse_entry_t SG_CACHE_PRE_parse_table[] = { | ||
331 | { "LAST_SEG", 0x02, 0x02 }, | ||
332 | { "ODD_SEG", 0x04, 0x04 }, | ||
333 | { "SG_ADDR_MASK", 0xf8, 0xf8 } | ||
334 | }; | ||
335 | |||
336 | int | ||
337 | ahd_sg_cache_pre_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
338 | { | ||
339 | return (ahd_print_register(SG_CACHE_PRE_parse_table, 3, "SG_CACHE_PRE", | ||
340 | 0x1b, regvalue, cur_col, wrap)); | ||
341 | } | ||
342 | |||
343 | int | ||
344 | ahd_lqin_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
345 | { | ||
346 | return (ahd_print_register(NULL, 0, "LQIN", | ||
347 | 0x20, regvalue, cur_col, wrap)); | ||
348 | } | ||
349 | |||
350 | int | ||
351 | ahd_lunptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
352 | { | ||
353 | return (ahd_print_register(NULL, 0, "LUNPTR", | ||
354 | 0x22, regvalue, cur_col, wrap)); | ||
355 | } | ||
356 | |||
357 | int | ||
358 | ahd_cmdlenptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
359 | { | ||
360 | return (ahd_print_register(NULL, 0, "CMDLENPTR", | ||
361 | 0x25, regvalue, cur_col, wrap)); | ||
362 | } | ||
363 | |||
364 | int | ||
365 | ahd_attrptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
366 | { | ||
367 | return (ahd_print_register(NULL, 0, "ATTRPTR", | ||
368 | 0x26, regvalue, cur_col, wrap)); | ||
369 | } | ||
370 | |||
371 | int | ||
372 | ahd_flagptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
373 | { | ||
374 | return (ahd_print_register(NULL, 0, "FLAGPTR", | ||
375 | 0x27, regvalue, cur_col, wrap)); | ||
376 | } | ||
377 | |||
378 | int | ||
379 | ahd_cmdptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
380 | { | ||
381 | return (ahd_print_register(NULL, 0, "CMDPTR", | ||
382 | 0x28, regvalue, cur_col, wrap)); | ||
383 | } | ||
384 | |||
385 | int | ||
386 | ahd_qnextptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
387 | { | ||
388 | return (ahd_print_register(NULL, 0, "QNEXTPTR", | ||
389 | 0x29, regvalue, cur_col, wrap)); | ||
390 | } | ||
391 | |||
392 | int | ||
393 | ahd_abrtbyteptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
394 | { | ||
395 | return (ahd_print_register(NULL, 0, "ABRTBYTEPTR", | ||
396 | 0x2b, regvalue, cur_col, wrap)); | ||
397 | } | ||
398 | |||
399 | int | ||
400 | ahd_abrtbitptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
401 | { | ||
402 | return (ahd_print_register(NULL, 0, "ABRTBITPTR", | ||
403 | 0x2c, regvalue, cur_col, wrap)); | ||
404 | } | ||
405 | |||
406 | static const ahd_reg_parse_entry_t LUNLEN_parse_table[] = { | ||
407 | { "ILUNLEN", 0x0f, 0x0f }, | ||
408 | { "TLUNLEN", 0xf0, 0xf0 } | ||
409 | }; | ||
410 | |||
411 | int | ||
412 | ahd_lunlen_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
413 | { | ||
414 | return (ahd_print_register(LUNLEN_parse_table, 2, "LUNLEN", | ||
415 | 0x30, regvalue, cur_col, wrap)); | ||
416 | } | ||
417 | |||
418 | int | ||
419 | ahd_cdblimit_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
420 | { | ||
421 | return (ahd_print_register(NULL, 0, "CDBLIMIT", | ||
422 | 0x31, regvalue, cur_col, wrap)); | ||
423 | } | ||
424 | |||
425 | int | ||
426 | ahd_maxcmd_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
427 | { | ||
428 | return (ahd_print_register(NULL, 0, "MAXCMD", | ||
429 | 0x32, regvalue, cur_col, wrap)); | ||
430 | } | ||
431 | |||
432 | int | ||
433 | ahd_maxcmdcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
434 | { | ||
435 | return (ahd_print_register(NULL, 0, "MAXCMDCNT", | ||
436 | 0x33, regvalue, cur_col, wrap)); | ||
437 | } | ||
438 | |||
439 | static const ahd_reg_parse_entry_t LQCTL1_parse_table[] = { | ||
440 | { "ABORTPENDING", 0x01, 0x01 }, | ||
441 | { "SINGLECMD", 0x02, 0x02 }, | ||
442 | { "PCI2PCI", 0x04, 0x04 } | ||
443 | }; | ||
444 | |||
445 | int | ||
446 | ahd_lqctl1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
447 | { | ||
448 | return (ahd_print_register(LQCTL1_parse_table, 3, "LQCTL1", | ||
449 | 0x38, regvalue, cur_col, wrap)); | ||
450 | } | ||
451 | |||
452 | static const ahd_reg_parse_entry_t LQCTL2_parse_table[] = { | ||
453 | { "LQOPAUSE", 0x01, 0x01 }, | ||
454 | { "LQOTOIDLE", 0x02, 0x02 }, | ||
455 | { "LQOCONTINUE", 0x04, 0x04 }, | ||
456 | { "LQORETRY", 0x08, 0x08 }, | ||
457 | { "LQIPAUSE", 0x10, 0x10 }, | ||
458 | { "LQITOIDLE", 0x20, 0x20 }, | ||
459 | { "LQICONTINUE", 0x40, 0x40 }, | ||
460 | { "LQIRETRY", 0x80, 0x80 } | ||
461 | }; | ||
462 | |||
463 | int | ||
464 | ahd_lqctl2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
465 | { | ||
466 | return (ahd_print_register(LQCTL2_parse_table, 8, "LQCTL2", | ||
467 | 0x39, regvalue, cur_col, wrap)); | ||
468 | } | ||
469 | |||
470 | static const ahd_reg_parse_entry_t SCSISEQ0_parse_table[] = { | 127 | static const ahd_reg_parse_entry_t SCSISEQ0_parse_table[] = { |
471 | { "SCSIRSTO", 0x01, 0x01 }, | 128 | { "SCSIRSTO", 0x01, 0x01 }, |
472 | { "FORCEBUSFREE", 0x10, 0x10 }, | 129 | { "FORCEBUSFREE", 0x10, 0x10 }, |
@@ -498,37 +155,6 @@ ahd_scsiseq1_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
498 | 0x3b, regvalue, cur_col, wrap)); | 155 | 0x3b, regvalue, cur_col, wrap)); |
499 | } | 156 | } |
500 | 157 | ||
501 | static const ahd_reg_parse_entry_t SXFRCTL0_parse_table[] = { | ||
502 | { "SPIOEN", 0x08, 0x08 }, | ||
503 | { "BIOSCANCELEN", 0x10, 0x10 }, | ||
504 | { "DFPEXP", 0x40, 0x40 }, | ||
505 | { "DFON", 0x80, 0x80 } | ||
506 | }; | ||
507 | |||
508 | int | ||
509 | ahd_sxfrctl0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
510 | { | ||
511 | return (ahd_print_register(SXFRCTL0_parse_table, 4, "SXFRCTL0", | ||
512 | 0x3c, regvalue, cur_col, wrap)); | ||
513 | } | ||
514 | |||
515 | static const ahd_reg_parse_entry_t SXFRCTL1_parse_table[] = { | ||
516 | { "STPWEN", 0x01, 0x01 }, | ||
517 | { "ACTNEGEN", 0x02, 0x02 }, | ||
518 | { "ENSTIMER", 0x04, 0x04 }, | ||
519 | { "STIMESEL", 0x18, 0x18 }, | ||
520 | { "ENSPCHK", 0x20, 0x20 }, | ||
521 | { "ENSACHK", 0x40, 0x40 }, | ||
522 | { "BITBUCKET", 0x80, 0x80 } | ||
523 | }; | ||
524 | |||
525 | int | ||
526 | ahd_sxfrctl1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
527 | { | ||
528 | return (ahd_print_register(SXFRCTL1_parse_table, 7, "SXFRCTL1", | ||
529 | 0x3d, regvalue, cur_col, wrap)); | ||
530 | } | ||
531 | |||
532 | static const ahd_reg_parse_entry_t DFFSTAT_parse_table[] = { | 158 | static const ahd_reg_parse_entry_t DFFSTAT_parse_table[] = { |
533 | { "CURRFIFO_0", 0x00, 0x03 }, | 159 | { "CURRFIFO_0", 0x00, 0x03 }, |
534 | { "CURRFIFO_1", 0x01, 0x03 }, | 160 | { "CURRFIFO_1", 0x01, 0x03 }, |
@@ -545,40 +171,6 @@ ahd_dffstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
545 | 0x3f, regvalue, cur_col, wrap)); | 171 | 0x3f, regvalue, cur_col, wrap)); |
546 | } | 172 | } |
547 | 173 | ||
548 | int | ||
549 | ahd_multargid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
550 | { | ||
551 | return (ahd_print_register(NULL, 0, "MULTARGID", | ||
552 | 0x40, regvalue, cur_col, wrap)); | ||
553 | } | ||
554 | |||
555 | static const ahd_reg_parse_entry_t SCSISIGO_parse_table[] = { | ||
556 | { "P_DATAOUT", 0x00, 0xe0 }, | ||
557 | { "P_DATAOUT_DT", 0x20, 0xe0 }, | ||
558 | { "P_DATAIN", 0x40, 0xe0 }, | ||
559 | { "P_DATAIN_DT", 0x60, 0xe0 }, | ||
560 | { "P_COMMAND", 0x80, 0xe0 }, | ||
561 | { "P_MESGOUT", 0xa0, 0xe0 }, | ||
562 | { "P_STATUS", 0xc0, 0xe0 }, | ||
563 | { "P_MESGIN", 0xe0, 0xe0 }, | ||
564 | { "ACKO", 0x01, 0x01 }, | ||
565 | { "REQO", 0x02, 0x02 }, | ||
566 | { "BSYO", 0x04, 0x04 }, | ||
567 | { "SELO", 0x08, 0x08 }, | ||
568 | { "ATNO", 0x10, 0x10 }, | ||
569 | { "MSGO", 0x20, 0x20 }, | ||
570 | { "IOO", 0x40, 0x40 }, | ||
571 | { "CDO", 0x80, 0x80 }, | ||
572 | { "PHASE_MASK", 0xe0, 0xe0 } | ||
573 | }; | ||
574 | |||
575 | int | ||
576 | ahd_scsisigo_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
577 | { | ||
578 | return (ahd_print_register(SCSISIGO_parse_table, 17, "SCSISIGO", | ||
579 | 0x40, regvalue, cur_col, wrap)); | ||
580 | } | ||
581 | |||
582 | static const ahd_reg_parse_entry_t SCSISIGI_parse_table[] = { | 174 | static const ahd_reg_parse_entry_t SCSISIGI_parse_table[] = { |
583 | { "P_DATAOUT", 0x00, 0xe0 }, | 175 | { "P_DATAOUT", 0x00, 0xe0 }, |
584 | { "P_DATAOUT_DT", 0x20, 0xe0 }, | 176 | { "P_DATAOUT_DT", 0x20, 0xe0 }, |
@@ -624,31 +216,12 @@ ahd_scsiphase_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
624 | } | 216 | } |
625 | 217 | ||
626 | int | 218 | int |
627 | ahd_scsidat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
628 | { | ||
629 | return (ahd_print_register(NULL, 0, "SCSIDAT", | ||
630 | 0x44, regvalue, cur_col, wrap)); | ||
631 | } | ||
632 | |||
633 | int | ||
634 | ahd_scsibus_print(u_int regvalue, u_int *cur_col, u_int wrap) | 219 | ahd_scsibus_print(u_int regvalue, u_int *cur_col, u_int wrap) |
635 | { | 220 | { |
636 | return (ahd_print_register(NULL, 0, "SCSIBUS", | 221 | return (ahd_print_register(NULL, 0, "SCSIBUS", |
637 | 0x46, regvalue, cur_col, wrap)); | 222 | 0x46, regvalue, cur_col, wrap)); |
638 | } | 223 | } |
639 | 224 | ||
640 | static const ahd_reg_parse_entry_t TARGIDIN_parse_table[] = { | ||
641 | { "TARGID", 0x0f, 0x0f }, | ||
642 | { "CLKOUT", 0x80, 0x80 } | ||
643 | }; | ||
644 | |||
645 | int | ||
646 | ahd_targidin_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
647 | { | ||
648 | return (ahd_print_register(TARGIDIN_parse_table, 2, "TARGIDIN", | ||
649 | 0x48, regvalue, cur_col, wrap)); | ||
650 | } | ||
651 | |||
652 | static const ahd_reg_parse_entry_t SELID_parse_table[] = { | 225 | static const ahd_reg_parse_entry_t SELID_parse_table[] = { |
653 | { "ONEBIT", 0x08, 0x08 }, | 226 | { "ONEBIT", 0x08, 0x08 }, |
654 | { "SELID_MASK", 0xf0, 0xf0 } | 227 | { "SELID_MASK", 0xf0, 0xf0 } |
@@ -661,38 +234,6 @@ ahd_selid_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
661 | 0x49, regvalue, cur_col, wrap)); | 234 | 0x49, regvalue, cur_col, wrap)); |
662 | } | 235 | } |
663 | 236 | ||
664 | static const ahd_reg_parse_entry_t OPTIONMODE_parse_table[] = { | ||
665 | { "AUTO_MSGOUT_DE", 0x02, 0x02 }, | ||
666 | { "ENDGFORMCHK", 0x04, 0x04 }, | ||
667 | { "BUSFREEREV", 0x10, 0x10 }, | ||
668 | { "BIASCANCTL", 0x20, 0x20 }, | ||
669 | { "AUTOACKEN", 0x40, 0x40 }, | ||
670 | { "BIOSCANCTL", 0x80, 0x80 }, | ||
671 | { "OPTIONMODE_DEFAULTS",0x02, 0x02 } | ||
672 | }; | ||
673 | |||
674 | int | ||
675 | ahd_optionmode_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
676 | { | ||
677 | return (ahd_print_register(OPTIONMODE_parse_table, 7, "OPTIONMODE", | ||
678 | 0x4a, regvalue, cur_col, wrap)); | ||
679 | } | ||
680 | |||
681 | static const ahd_reg_parse_entry_t SBLKCTL_parse_table[] = { | ||
682 | { "SELWIDE", 0x02, 0x02 }, | ||
683 | { "ENAB20", 0x04, 0x04 }, | ||
684 | { "ENAB40", 0x08, 0x08 }, | ||
685 | { "DIAGLEDON", 0x40, 0x40 }, | ||
686 | { "DIAGLEDEN", 0x80, 0x80 } | ||
687 | }; | ||
688 | |||
689 | int | ||
690 | ahd_sblkctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
691 | { | ||
692 | return (ahd_print_register(SBLKCTL_parse_table, 5, "SBLKCTL", | ||
693 | 0x4a, regvalue, cur_col, wrap)); | ||
694 | } | ||
695 | |||
696 | static const ahd_reg_parse_entry_t SSTAT0_parse_table[] = { | 237 | static const ahd_reg_parse_entry_t SSTAT0_parse_table[] = { |
697 | { "ARBDO", 0x01, 0x01 }, | 238 | { "ARBDO", 0x01, 0x01 }, |
698 | { "SPIORDY", 0x02, 0x02 }, | 239 | { "SPIORDY", 0x02, 0x02 }, |
@@ -728,23 +269,6 @@ ahd_simode0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
728 | 0x4b, regvalue, cur_col, wrap)); | 269 | 0x4b, regvalue, cur_col, wrap)); |
729 | } | 270 | } |
730 | 271 | ||
731 | static const ahd_reg_parse_entry_t CLRSINT0_parse_table[] = { | ||
732 | { "CLRARBDO", 0x01, 0x01 }, | ||
733 | { "CLRSPIORDY", 0x02, 0x02 }, | ||
734 | { "CLROVERRUN", 0x04, 0x04 }, | ||
735 | { "CLRIOERR", 0x08, 0x08 }, | ||
736 | { "CLRSELINGO", 0x10, 0x10 }, | ||
737 | { "CLRSELDI", 0x20, 0x20 }, | ||
738 | { "CLRSELDO", 0x40, 0x40 } | ||
739 | }; | ||
740 | |||
741 | int | ||
742 | ahd_clrsint0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
743 | { | ||
744 | return (ahd_print_register(CLRSINT0_parse_table, 7, "CLRSINT0", | ||
745 | 0x4b, regvalue, cur_col, wrap)); | ||
746 | } | ||
747 | |||
748 | static const ahd_reg_parse_entry_t SSTAT1_parse_table[] = { | 272 | static const ahd_reg_parse_entry_t SSTAT1_parse_table[] = { |
749 | { "REQINIT", 0x01, 0x01 }, | 273 | { "REQINIT", 0x01, 0x01 }, |
750 | { "STRB2FAST", 0x02, 0x02 }, | 274 | { "STRB2FAST", 0x02, 0x02 }, |
@@ -763,23 +287,6 @@ ahd_sstat1_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
763 | 0x4c, regvalue, cur_col, wrap)); | 287 | 0x4c, regvalue, cur_col, wrap)); |
764 | } | 288 | } |
765 | 289 | ||
766 | static const ahd_reg_parse_entry_t CLRSINT1_parse_table[] = { | ||
767 | { "CLRREQINIT", 0x01, 0x01 }, | ||
768 | { "CLRSTRB2FAST", 0x02, 0x02 }, | ||
769 | { "CLRSCSIPERR", 0x04, 0x04 }, | ||
770 | { "CLRBUSFREE", 0x08, 0x08 }, | ||
771 | { "CLRSCSIRSTI", 0x20, 0x20 }, | ||
772 | { "CLRATNO", 0x40, 0x40 }, | ||
773 | { "CLRSELTIMEO", 0x80, 0x80 } | ||
774 | }; | ||
775 | |||
776 | int | ||
777 | ahd_clrsint1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
778 | { | ||
779 | return (ahd_print_register(CLRSINT1_parse_table, 7, "CLRSINT1", | ||
780 | 0x4c, regvalue, cur_col, wrap)); | ||
781 | } | ||
782 | |||
783 | static const ahd_reg_parse_entry_t SSTAT2_parse_table[] = { | 290 | static const ahd_reg_parse_entry_t SSTAT2_parse_table[] = { |
784 | { "BUSFREE_LQO", 0x40, 0xc0 }, | 291 | { "BUSFREE_LQO", 0x40, 0xc0 }, |
785 | { "BUSFREE_DFF0", 0x80, 0xc0 }, | 292 | { "BUSFREE_DFF0", 0x80, 0xc0 }, |
@@ -800,20 +307,6 @@ ahd_sstat2_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
800 | 0x4d, regvalue, cur_col, wrap)); | 307 | 0x4d, regvalue, cur_col, wrap)); |
801 | } | 308 | } |
802 | 309 | ||
803 | static const ahd_reg_parse_entry_t CLRSINT2_parse_table[] = { | ||
804 | { "CLRDMADONE", 0x01, 0x01 }, | ||
805 | { "CLRSDONE", 0x02, 0x02 }, | ||
806 | { "CLRWIDE_RES", 0x04, 0x04 }, | ||
807 | { "CLRNONPACKREQ", 0x20, 0x20 } | ||
808 | }; | ||
809 | |||
810 | int | ||
811 | ahd_clrsint2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
812 | { | ||
813 | return (ahd_print_register(CLRSINT2_parse_table, 4, "CLRSINT2", | ||
814 | 0x4d, regvalue, cur_col, wrap)); | ||
815 | } | ||
816 | |||
817 | static const ahd_reg_parse_entry_t PERRDIAG_parse_table[] = { | 310 | static const ahd_reg_parse_entry_t PERRDIAG_parse_table[] = { |
818 | { "DTERR", 0x01, 0x01 }, | 311 | { "DTERR", 0x01, 0x01 }, |
819 | { "DGFORMERR", 0x02, 0x02 }, | 312 | { "DGFORMERR", 0x02, 0x02 }, |
@@ -833,26 +326,12 @@ ahd_perrdiag_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
833 | } | 326 | } |
834 | 327 | ||
835 | int | 328 | int |
836 | ahd_lqistate_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
837 | { | ||
838 | return (ahd_print_register(NULL, 0, "LQISTATE", | ||
839 | 0x4e, regvalue, cur_col, wrap)); | ||
840 | } | ||
841 | |||
842 | int | ||
843 | ahd_soffcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | 329 | ahd_soffcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) |
844 | { | 330 | { |
845 | return (ahd_print_register(NULL, 0, "SOFFCNT", | 331 | return (ahd_print_register(NULL, 0, "SOFFCNT", |
846 | 0x4f, regvalue, cur_col, wrap)); | 332 | 0x4f, regvalue, cur_col, wrap)); |
847 | } | 333 | } |
848 | 334 | ||
849 | int | ||
850 | ahd_lqostate_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
851 | { | ||
852 | return (ahd_print_register(NULL, 0, "LQOSTATE", | ||
853 | 0x4f, regvalue, cur_col, wrap)); | ||
854 | } | ||
855 | |||
856 | static const ahd_reg_parse_entry_t LQISTAT0_parse_table[] = { | 335 | static const ahd_reg_parse_entry_t LQISTAT0_parse_table[] = { |
857 | { "LQIATNCMD", 0x01, 0x01 }, | 336 | { "LQIATNCMD", 0x01, 0x01 }, |
858 | { "LQIATNLQ", 0x02, 0x02 }, | 337 | { "LQIATNLQ", 0x02, 0x02 }, |
@@ -869,56 +348,6 @@ ahd_lqistat0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
869 | 0x50, regvalue, cur_col, wrap)); | 348 | 0x50, regvalue, cur_col, wrap)); |
870 | } | 349 | } |
871 | 350 | ||
872 | static const ahd_reg_parse_entry_t LQIMODE0_parse_table[] = { | ||
873 | { "ENLQIATNCMD", 0x01, 0x01 }, | ||
874 | { "ENLQIATNLQ", 0x02, 0x02 }, | ||
875 | { "ENLQIBADLQT", 0x04, 0x04 }, | ||
876 | { "ENLQICRCT2", 0x08, 0x08 }, | ||
877 | { "ENLQICRCT1", 0x10, 0x10 }, | ||
878 | { "ENLQIATNQASK", 0x20, 0x20 } | ||
879 | }; | ||
880 | |||
881 | int | ||
882 | ahd_lqimode0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
883 | { | ||
884 | return (ahd_print_register(LQIMODE0_parse_table, 6, "LQIMODE0", | ||
885 | 0x50, regvalue, cur_col, wrap)); | ||
886 | } | ||
887 | |||
888 | static const ahd_reg_parse_entry_t CLRLQIINT0_parse_table[] = { | ||
889 | { "CLRLQIATNCMD", 0x01, 0x01 }, | ||
890 | { "CLRLQIATNLQ", 0x02, 0x02 }, | ||
891 | { "CLRLQIBADLQT", 0x04, 0x04 }, | ||
892 | { "CLRLQICRCT2", 0x08, 0x08 }, | ||
893 | { "CLRLQICRCT1", 0x10, 0x10 }, | ||
894 | { "CLRLQIATNQAS", 0x20, 0x20 } | ||
895 | }; | ||
896 | |||
897 | int | ||
898 | ahd_clrlqiint0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
899 | { | ||
900 | return (ahd_print_register(CLRLQIINT0_parse_table, 6, "CLRLQIINT0", | ||
901 | 0x50, regvalue, cur_col, wrap)); | ||
902 | } | ||
903 | |||
904 | static const ahd_reg_parse_entry_t LQIMODE1_parse_table[] = { | ||
905 | { "ENLQIOVERI_NLQ", 0x01, 0x01 }, | ||
906 | { "ENLQIOVERI_LQ", 0x02, 0x02 }, | ||
907 | { "ENLQIBADLQI", 0x04, 0x04 }, | ||
908 | { "ENLQICRCI_NLQ", 0x08, 0x08 }, | ||
909 | { "ENLQICRCI_LQ", 0x10, 0x10 }, | ||
910 | { "ENLIQABORT", 0x20, 0x20 }, | ||
911 | { "ENLQIPHASE_NLQ", 0x40, 0x40 }, | ||
912 | { "ENLQIPHASE_LQ", 0x80, 0x80 } | ||
913 | }; | ||
914 | |||
915 | int | ||
916 | ahd_lqimode1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
917 | { | ||
918 | return (ahd_print_register(LQIMODE1_parse_table, 8, "LQIMODE1", | ||
919 | 0x51, regvalue, cur_col, wrap)); | ||
920 | } | ||
921 | |||
922 | static const ahd_reg_parse_entry_t LQISTAT1_parse_table[] = { | 351 | static const ahd_reg_parse_entry_t LQISTAT1_parse_table[] = { |
923 | { "LQIOVERI_NLQ", 0x01, 0x01 }, | 352 | { "LQIOVERI_NLQ", 0x01, 0x01 }, |
924 | { "LQIOVERI_LQ", 0x02, 0x02 }, | 353 | { "LQIOVERI_LQ", 0x02, 0x02 }, |
@@ -937,24 +366,6 @@ ahd_lqistat1_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
937 | 0x51, regvalue, cur_col, wrap)); | 366 | 0x51, regvalue, cur_col, wrap)); |
938 | } | 367 | } |
939 | 368 | ||
940 | static const ahd_reg_parse_entry_t CLRLQIINT1_parse_table[] = { | ||
941 | { "CLRLQIOVERI_NLQ", 0x01, 0x01 }, | ||
942 | { "CLRLQIOVERI_LQ", 0x02, 0x02 }, | ||
943 | { "CLRLQIBADLQI", 0x04, 0x04 }, | ||
944 | { "CLRLQICRCI_NLQ", 0x08, 0x08 }, | ||
945 | { "CLRLQICRCI_LQ", 0x10, 0x10 }, | ||
946 | { "CLRLIQABORT", 0x20, 0x20 }, | ||
947 | { "CLRLQIPHASE_NLQ", 0x40, 0x40 }, | ||
948 | { "CLRLQIPHASE_LQ", 0x80, 0x80 } | ||
949 | }; | ||
950 | |||
951 | int | ||
952 | ahd_clrlqiint1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
953 | { | ||
954 | return (ahd_print_register(CLRLQIINT1_parse_table, 8, "CLRLQIINT1", | ||
955 | 0x51, regvalue, cur_col, wrap)); | ||
956 | } | ||
957 | |||
958 | static const ahd_reg_parse_entry_t LQISTAT2_parse_table[] = { | 369 | static const ahd_reg_parse_entry_t LQISTAT2_parse_table[] = { |
959 | { "LQIGSAVAIL", 0x01, 0x01 }, | 370 | { "LQIGSAVAIL", 0x01, 0x01 }, |
960 | { "LQISTOPCMD", 0x02, 0x02 }, | 371 | { "LQISTOPCMD", 0x02, 0x02 }, |
@@ -985,30 +396,6 @@ ahd_sstat3_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
985 | 0x53, regvalue, cur_col, wrap)); | 396 | 0x53, regvalue, cur_col, wrap)); |
986 | } | 397 | } |
987 | 398 | ||
988 | static const ahd_reg_parse_entry_t SIMODE3_parse_table[] = { | ||
989 | { "ENOSRAMPERR", 0x01, 0x01 }, | ||
990 | { "ENNTRAMPERR", 0x02, 0x02 } | ||
991 | }; | ||
992 | |||
993 | int | ||
994 | ahd_simode3_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
995 | { | ||
996 | return (ahd_print_register(SIMODE3_parse_table, 2, "SIMODE3", | ||
997 | 0x53, regvalue, cur_col, wrap)); | ||
998 | } | ||
999 | |||
1000 | static const ahd_reg_parse_entry_t CLRSINT3_parse_table[] = { | ||
1001 | { "CLROSRAMPERR", 0x01, 0x01 }, | ||
1002 | { "CLRNTRAMPERR", 0x02, 0x02 } | ||
1003 | }; | ||
1004 | |||
1005 | int | ||
1006 | ahd_clrsint3_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1007 | { | ||
1008 | return (ahd_print_register(CLRSINT3_parse_table, 2, "CLRSINT3", | ||
1009 | 0x53, regvalue, cur_col, wrap)); | ||
1010 | } | ||
1011 | |||
1012 | static const ahd_reg_parse_entry_t LQOSTAT0_parse_table[] = { | 399 | static const ahd_reg_parse_entry_t LQOSTAT0_parse_table[] = { |
1013 | { "LQOTCRC", 0x01, 0x01 }, | 400 | { "LQOTCRC", 0x01, 0x01 }, |
1014 | { "LQOATNPKT", 0x02, 0x02 }, | 401 | { "LQOATNPKT", 0x02, 0x02 }, |
@@ -1024,51 +411,6 @@ ahd_lqostat0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1024 | 0x54, regvalue, cur_col, wrap)); | 411 | 0x54, regvalue, cur_col, wrap)); |
1025 | } | 412 | } |
1026 | 413 | ||
1027 | static const ahd_reg_parse_entry_t CLRLQOINT0_parse_table[] = { | ||
1028 | { "CLRLQOTCRC", 0x01, 0x01 }, | ||
1029 | { "CLRLQOATNPKT", 0x02, 0x02 }, | ||
1030 | { "CLRLQOATNLQ", 0x04, 0x04 }, | ||
1031 | { "CLRLQOSTOPT2", 0x08, 0x08 }, | ||
1032 | { "CLRLQOTARGSCBPERR", 0x10, 0x10 } | ||
1033 | }; | ||
1034 | |||
1035 | int | ||
1036 | ahd_clrlqoint0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1037 | { | ||
1038 | return (ahd_print_register(CLRLQOINT0_parse_table, 5, "CLRLQOINT0", | ||
1039 | 0x54, regvalue, cur_col, wrap)); | ||
1040 | } | ||
1041 | |||
1042 | static const ahd_reg_parse_entry_t LQOMODE0_parse_table[] = { | ||
1043 | { "ENLQOTCRC", 0x01, 0x01 }, | ||
1044 | { "ENLQOATNPKT", 0x02, 0x02 }, | ||
1045 | { "ENLQOATNLQ", 0x04, 0x04 }, | ||
1046 | { "ENLQOSTOPT2", 0x08, 0x08 }, | ||
1047 | { "ENLQOTARGSCBPERR", 0x10, 0x10 } | ||
1048 | }; | ||
1049 | |||
1050 | int | ||
1051 | ahd_lqomode0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1052 | { | ||
1053 | return (ahd_print_register(LQOMODE0_parse_table, 5, "LQOMODE0", | ||
1054 | 0x54, regvalue, cur_col, wrap)); | ||
1055 | } | ||
1056 | |||
1057 | static const ahd_reg_parse_entry_t LQOMODE1_parse_table[] = { | ||
1058 | { "ENLQOPHACHGINPKT", 0x01, 0x01 }, | ||
1059 | { "ENLQOBUSFREE", 0x02, 0x02 }, | ||
1060 | { "ENLQOBADQAS", 0x04, 0x04 }, | ||
1061 | { "ENLQOSTOPI2", 0x08, 0x08 }, | ||
1062 | { "ENLQOINITSCBPERR", 0x10, 0x10 } | ||
1063 | }; | ||
1064 | |||
1065 | int | ||
1066 | ahd_lqomode1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1067 | { | ||
1068 | return (ahd_print_register(LQOMODE1_parse_table, 5, "LQOMODE1", | ||
1069 | 0x55, regvalue, cur_col, wrap)); | ||
1070 | } | ||
1071 | |||
1072 | static const ahd_reg_parse_entry_t LQOSTAT1_parse_table[] = { | 414 | static const ahd_reg_parse_entry_t LQOSTAT1_parse_table[] = { |
1073 | { "LQOPHACHGINPKT", 0x01, 0x01 }, | 415 | { "LQOPHACHGINPKT", 0x01, 0x01 }, |
1074 | { "LQOBUSFREE", 0x02, 0x02 }, | 416 | { "LQOBUSFREE", 0x02, 0x02 }, |
@@ -1084,21 +426,6 @@ ahd_lqostat1_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1084 | 0x55, regvalue, cur_col, wrap)); | 426 | 0x55, regvalue, cur_col, wrap)); |
1085 | } | 427 | } |
1086 | 428 | ||
1087 | static const ahd_reg_parse_entry_t CLRLQOINT1_parse_table[] = { | ||
1088 | { "CLRLQOPHACHGINPKT", 0x01, 0x01 }, | ||
1089 | { "CLRLQOBUSFREE", 0x02, 0x02 }, | ||
1090 | { "CLRLQOBADQAS", 0x04, 0x04 }, | ||
1091 | { "CLRLQOSTOPI2", 0x08, 0x08 }, | ||
1092 | { "CLRLQOINITSCBPERR", 0x10, 0x10 } | ||
1093 | }; | ||
1094 | |||
1095 | int | ||
1096 | ahd_clrlqoint1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1097 | { | ||
1098 | return (ahd_print_register(CLRLQOINT1_parse_table, 5, "CLRLQOINT1", | ||
1099 | 0x55, regvalue, cur_col, wrap)); | ||
1100 | } | ||
1101 | |||
1102 | static const ahd_reg_parse_entry_t LQOSTAT2_parse_table[] = { | 429 | static const ahd_reg_parse_entry_t LQOSTAT2_parse_table[] = { |
1103 | { "LQOSTOP0", 0x01, 0x01 }, | 430 | { "LQOSTOP0", 0x01, 0x01 }, |
1104 | { "LQOPHACHGOUTPKT", 0x02, 0x02 }, | 431 | { "LQOPHACHGOUTPKT", 0x02, 0x02 }, |
@@ -1113,13 +440,6 @@ ahd_lqostat2_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1113 | 0x56, regvalue, cur_col, wrap)); | 440 | 0x56, regvalue, cur_col, wrap)); |
1114 | } | 441 | } |
1115 | 442 | ||
1116 | int | ||
1117 | ahd_os_space_cnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1118 | { | ||
1119 | return (ahd_print_register(NULL, 0, "OS_SPACE_CNT", | ||
1120 | 0x56, regvalue, cur_col, wrap)); | ||
1121 | } | ||
1122 | |||
1123 | static const ahd_reg_parse_entry_t SIMODE1_parse_table[] = { | 443 | static const ahd_reg_parse_entry_t SIMODE1_parse_table[] = { |
1124 | { "ENREQINIT", 0x01, 0x01 }, | 444 | { "ENREQINIT", 0x01, 0x01 }, |
1125 | { "ENSTRB2FAST", 0x02, 0x02 }, | 445 | { "ENSTRB2FAST", 0x02, 0x02 }, |
@@ -1138,13 +458,6 @@ ahd_simode1_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1138 | 0x57, regvalue, cur_col, wrap)); | 458 | 0x57, regvalue, cur_col, wrap)); |
1139 | } | 459 | } |
1140 | 460 | ||
1141 | int | ||
1142 | ahd_gsfifo_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1143 | { | ||
1144 | return (ahd_print_register(NULL, 0, "GSFIFO", | ||
1145 | 0x58, regvalue, cur_col, wrap)); | ||
1146 | } | ||
1147 | |||
1148 | static const ahd_reg_parse_entry_t DFFSXFRCTL_parse_table[] = { | 461 | static const ahd_reg_parse_entry_t DFFSXFRCTL_parse_table[] = { |
1149 | { "RSTCHN", 0x01, 0x01 }, | 462 | { "RSTCHN", 0x01, 0x01 }, |
1150 | { "CLRCHN", 0x02, 0x02 }, | 463 | { "CLRCHN", 0x02, 0x02 }, |
@@ -1159,44 +472,6 @@ ahd_dffsxfrctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1159 | 0x5a, regvalue, cur_col, wrap)); | 472 | 0x5a, regvalue, cur_col, wrap)); |
1160 | } | 473 | } |
1161 | 474 | ||
1162 | static const ahd_reg_parse_entry_t LQOSCSCTL_parse_table[] = { | ||
1163 | { "LQONOCHKOVER", 0x01, 0x01 }, | ||
1164 | { "LQONOHOLDLACK", 0x02, 0x02 }, | ||
1165 | { "LQOBUSETDLY", 0x40, 0x40 }, | ||
1166 | { "LQOH2A_VERSION", 0x80, 0x80 } | ||
1167 | }; | ||
1168 | |||
1169 | int | ||
1170 | ahd_lqoscsctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1171 | { | ||
1172 | return (ahd_print_register(LQOSCSCTL_parse_table, 4, "LQOSCSCTL", | ||
1173 | 0x5a, regvalue, cur_col, wrap)); | ||
1174 | } | ||
1175 | |||
1176 | int | ||
1177 | ahd_nextscb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1178 | { | ||
1179 | return (ahd_print_register(NULL, 0, "NEXTSCB", | ||
1180 | 0x5a, regvalue, cur_col, wrap)); | ||
1181 | } | ||
1182 | |||
1183 | static const ahd_reg_parse_entry_t CLRSEQINTSRC_parse_table[] = { | ||
1184 | { "CLRCFG4TCMD", 0x01, 0x01 }, | ||
1185 | { "CLRCFG4ICMD", 0x02, 0x02 }, | ||
1186 | { "CLRCFG4TSTAT", 0x04, 0x04 }, | ||
1187 | { "CLRCFG4ISTAT", 0x08, 0x08 }, | ||
1188 | { "CLRCFG4DATA", 0x10, 0x10 }, | ||
1189 | { "CLRSAVEPTRS", 0x20, 0x20 }, | ||
1190 | { "CLRCTXTDONE", 0x40, 0x40 } | ||
1191 | }; | ||
1192 | |||
1193 | int | ||
1194 | ahd_clrseqintsrc_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1195 | { | ||
1196 | return (ahd_print_register(CLRSEQINTSRC_parse_table, 7, "CLRSEQINTSRC", | ||
1197 | 0x5b, regvalue, cur_col, wrap)); | ||
1198 | } | ||
1199 | |||
1200 | static const ahd_reg_parse_entry_t SEQINTSRC_parse_table[] = { | 475 | static const ahd_reg_parse_entry_t SEQINTSRC_parse_table[] = { |
1201 | { "CFG4TCMD", 0x01, 0x01 }, | 476 | { "CFG4TCMD", 0x01, 0x01 }, |
1202 | { "CFG4ICMD", 0x02, 0x02 }, | 477 | { "CFG4ICMD", 0x02, 0x02 }, |
@@ -1231,13 +506,6 @@ ahd_seqimode_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1231 | 0x5c, regvalue, cur_col, wrap)); | 506 | 0x5c, regvalue, cur_col, wrap)); |
1232 | } | 507 | } |
1233 | 508 | ||
1234 | int | ||
1235 | ahd_currscb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1236 | { | ||
1237 | return (ahd_print_register(NULL, 0, "CURRSCB", | ||
1238 | 0x5c, regvalue, cur_col, wrap)); | ||
1239 | } | ||
1240 | |||
1241 | static const ahd_reg_parse_entry_t MDFFSTAT_parse_table[] = { | 509 | static const ahd_reg_parse_entry_t MDFFSTAT_parse_table[] = { |
1242 | { "FIFOFREE", 0x01, 0x01 }, | 510 | { "FIFOFREE", 0x01, 0x01 }, |
1243 | { "DATAINFIFO", 0x02, 0x02 }, | 511 | { "DATAINFIFO", 0x02, 0x02 }, |
@@ -1256,308 +524,12 @@ ahd_mdffstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1256 | } | 524 | } |
1257 | 525 | ||
1258 | int | 526 | int |
1259 | ahd_lastscb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1260 | { | ||
1261 | return (ahd_print_register(NULL, 0, "LASTSCB", | ||
1262 | 0x5e, regvalue, cur_col, wrap)); | ||
1263 | } | ||
1264 | |||
1265 | int | ||
1266 | ahd_shaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1267 | { | ||
1268 | return (ahd_print_register(NULL, 0, "SHADDR", | ||
1269 | 0x60, regvalue, cur_col, wrap)); | ||
1270 | } | ||
1271 | |||
1272 | int | ||
1273 | ahd_negoaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1274 | { | ||
1275 | return (ahd_print_register(NULL, 0, "NEGOADDR", | ||
1276 | 0x60, regvalue, cur_col, wrap)); | ||
1277 | } | ||
1278 | |||
1279 | int | ||
1280 | ahd_negperiod_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1281 | { | ||
1282 | return (ahd_print_register(NULL, 0, "NEGPERIOD", | ||
1283 | 0x61, regvalue, cur_col, wrap)); | ||
1284 | } | ||
1285 | |||
1286 | int | ||
1287 | ahd_negoffset_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1288 | { | ||
1289 | return (ahd_print_register(NULL, 0, "NEGOFFSET", | ||
1290 | 0x62, regvalue, cur_col, wrap)); | ||
1291 | } | ||
1292 | |||
1293 | static const ahd_reg_parse_entry_t NEGPPROPTS_parse_table[] = { | ||
1294 | { "PPROPT_IUT", 0x01, 0x01 }, | ||
1295 | { "PPROPT_DT", 0x02, 0x02 }, | ||
1296 | { "PPROPT_QAS", 0x04, 0x04 }, | ||
1297 | { "PPROPT_PACE", 0x08, 0x08 } | ||
1298 | }; | ||
1299 | |||
1300 | int | ||
1301 | ahd_negppropts_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1302 | { | ||
1303 | return (ahd_print_register(NEGPPROPTS_parse_table, 4, "NEGPPROPTS", | ||
1304 | 0x63, regvalue, cur_col, wrap)); | ||
1305 | } | ||
1306 | |||
1307 | static const ahd_reg_parse_entry_t NEGCONOPTS_parse_table[] = { | ||
1308 | { "WIDEXFER", 0x01, 0x01 }, | ||
1309 | { "ENAUTOATNO", 0x02, 0x02 }, | ||
1310 | { "ENAUTOATNI", 0x04, 0x04 }, | ||
1311 | { "ENSLOWCRC", 0x08, 0x08 }, | ||
1312 | { "RTI_OVRDTRN", 0x10, 0x10 }, | ||
1313 | { "RTI_WRTDIS", 0x20, 0x20 }, | ||
1314 | { "ENSNAPSHOT", 0x40, 0x40 } | ||
1315 | }; | ||
1316 | |||
1317 | int | ||
1318 | ahd_negconopts_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1319 | { | ||
1320 | return (ahd_print_register(NEGCONOPTS_parse_table, 7, "NEGCONOPTS", | ||
1321 | 0x64, regvalue, cur_col, wrap)); | ||
1322 | } | ||
1323 | |||
1324 | int | ||
1325 | ahd_annexcol_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1326 | { | ||
1327 | return (ahd_print_register(NULL, 0, "ANNEXCOL", | ||
1328 | 0x65, regvalue, cur_col, wrap)); | ||
1329 | } | ||
1330 | |||
1331 | int | ||
1332 | ahd_annexdat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1333 | { | ||
1334 | return (ahd_print_register(NULL, 0, "ANNEXDAT", | ||
1335 | 0x66, regvalue, cur_col, wrap)); | ||
1336 | } | ||
1337 | |||
1338 | static const ahd_reg_parse_entry_t SCSCHKN_parse_table[] = { | ||
1339 | { "LSTSGCLRDIS", 0x01, 0x01 }, | ||
1340 | { "SHVALIDSTDIS", 0x02, 0x02 }, | ||
1341 | { "DFFACTCLR", 0x04, 0x04 }, | ||
1342 | { "SDONEMSKDIS", 0x08, 0x08 }, | ||
1343 | { "WIDERESEN", 0x10, 0x10 }, | ||
1344 | { "CURRFIFODEF", 0x20, 0x20 }, | ||
1345 | { "STSELSKIDDIS", 0x40, 0x40 }, | ||
1346 | { "BIDICHKDIS", 0x80, 0x80 } | ||
1347 | }; | ||
1348 | |||
1349 | int | ||
1350 | ahd_scschkn_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1351 | { | ||
1352 | return (ahd_print_register(SCSCHKN_parse_table, 8, "SCSCHKN", | ||
1353 | 0x66, regvalue, cur_col, wrap)); | ||
1354 | } | ||
1355 | |||
1356 | int | ||
1357 | ahd_iownid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1358 | { | ||
1359 | return (ahd_print_register(NULL, 0, "IOWNID", | ||
1360 | 0x67, regvalue, cur_col, wrap)); | ||
1361 | } | ||
1362 | |||
1363 | int | ||
1364 | ahd_shcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1365 | { | ||
1366 | return (ahd_print_register(NULL, 0, "SHCNT", | ||
1367 | 0x68, regvalue, cur_col, wrap)); | ||
1368 | } | ||
1369 | |||
1370 | int | ||
1371 | ahd_townid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1372 | { | ||
1373 | return (ahd_print_register(NULL, 0, "TOWNID", | ||
1374 | 0x69, regvalue, cur_col, wrap)); | ||
1375 | } | ||
1376 | |||
1377 | int | ||
1378 | ahd_seloid_print(u_int regvalue, u_int *cur_col, u_int wrap) | 527 | ahd_seloid_print(u_int regvalue, u_int *cur_col, u_int wrap) |
1379 | { | 528 | { |
1380 | return (ahd_print_register(NULL, 0, "SELOID", | 529 | return (ahd_print_register(NULL, 0, "SELOID", |
1381 | 0x6b, regvalue, cur_col, wrap)); | 530 | 0x6b, regvalue, cur_col, wrap)); |
1382 | } | 531 | } |
1383 | 532 | ||
1384 | int | ||
1385 | ahd_haddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1386 | { | ||
1387 | return (ahd_print_register(NULL, 0, "HADDR", | ||
1388 | 0x70, regvalue, cur_col, wrap)); | ||
1389 | } | ||
1390 | |||
1391 | int | ||
1392 | ahd_hcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1393 | { | ||
1394 | return (ahd_print_register(NULL, 0, "HCNT", | ||
1395 | 0x78, regvalue, cur_col, wrap)); | ||
1396 | } | ||
1397 | |||
1398 | int | ||
1399 | ahd_sghaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1400 | { | ||
1401 | return (ahd_print_register(NULL, 0, "SGHADDR", | ||
1402 | 0x7c, regvalue, cur_col, wrap)); | ||
1403 | } | ||
1404 | |||
1405 | int | ||
1406 | ahd_scbhaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1407 | { | ||
1408 | return (ahd_print_register(NULL, 0, "SCBHADDR", | ||
1409 | 0x7c, regvalue, cur_col, wrap)); | ||
1410 | } | ||
1411 | |||
1412 | int | ||
1413 | ahd_sghcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1414 | { | ||
1415 | return (ahd_print_register(NULL, 0, "SGHCNT", | ||
1416 | 0x84, regvalue, cur_col, wrap)); | ||
1417 | } | ||
1418 | |||
1419 | int | ||
1420 | ahd_scbhcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1421 | { | ||
1422 | return (ahd_print_register(NULL, 0, "SCBHCNT", | ||
1423 | 0x84, regvalue, cur_col, wrap)); | ||
1424 | } | ||
1425 | |||
1426 | static const ahd_reg_parse_entry_t DFF_THRSH_parse_table[] = { | ||
1427 | { "WR_DFTHRSH_MIN", 0x00, 0x70 }, | ||
1428 | { "RD_DFTHRSH_MIN", 0x00, 0x07 }, | ||
1429 | { "RD_DFTHRSH_25", 0x01, 0x07 }, | ||
1430 | { "RD_DFTHRSH_50", 0x02, 0x07 }, | ||
1431 | { "RD_DFTHRSH_63", 0x03, 0x07 }, | ||
1432 | { "RD_DFTHRSH_75", 0x04, 0x07 }, | ||
1433 | { "RD_DFTHRSH_85", 0x05, 0x07 }, | ||
1434 | { "RD_DFTHRSH_90", 0x06, 0x07 }, | ||
1435 | { "RD_DFTHRSH_MAX", 0x07, 0x07 }, | ||
1436 | { "WR_DFTHRSH_25", 0x10, 0x70 }, | ||
1437 | { "WR_DFTHRSH_50", 0x20, 0x70 }, | ||
1438 | { "WR_DFTHRSH_63", 0x30, 0x70 }, | ||
1439 | { "WR_DFTHRSH_75", 0x40, 0x70 }, | ||
1440 | { "WR_DFTHRSH_85", 0x50, 0x70 }, | ||
1441 | { "WR_DFTHRSH_90", 0x60, 0x70 }, | ||
1442 | { "WR_DFTHRSH_MAX", 0x70, 0x70 }, | ||
1443 | { "RD_DFTHRSH", 0x07, 0x07 }, | ||
1444 | { "WR_DFTHRSH", 0x70, 0x70 } | ||
1445 | }; | ||
1446 | |||
1447 | int | ||
1448 | ahd_dff_thrsh_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1449 | { | ||
1450 | return (ahd_print_register(DFF_THRSH_parse_table, 18, "DFF_THRSH", | ||
1451 | 0x88, regvalue, cur_col, wrap)); | ||
1452 | } | ||
1453 | |||
1454 | static const ahd_reg_parse_entry_t PCIXCTL_parse_table[] = { | ||
1455 | { "CMPABCDIS", 0x01, 0x01 }, | ||
1456 | { "TSCSERREN", 0x02, 0x02 }, | ||
1457 | { "SRSPDPEEN", 0x04, 0x04 }, | ||
1458 | { "SPLTSTADIS", 0x08, 0x08 }, | ||
1459 | { "SPLTSMADIS", 0x10, 0x10 }, | ||
1460 | { "UNEXPSCIEN", 0x20, 0x20 }, | ||
1461 | { "SERRPULSE", 0x80, 0x80 } | ||
1462 | }; | ||
1463 | |||
1464 | int | ||
1465 | ahd_pcixctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1466 | { | ||
1467 | return (ahd_print_register(PCIXCTL_parse_table, 7, "PCIXCTL", | ||
1468 | 0x93, regvalue, cur_col, wrap)); | ||
1469 | } | ||
1470 | |||
1471 | static const ahd_reg_parse_entry_t DCHSPLTSTAT0_parse_table[] = { | ||
1472 | { "RXSPLTRSP", 0x01, 0x01 }, | ||
1473 | { "RXSCEMSG", 0x02, 0x02 }, | ||
1474 | { "RXOVRUN", 0x04, 0x04 }, | ||
1475 | { "CNTNOTCMPLT", 0x08, 0x08 }, | ||
1476 | { "SCDATBUCKET", 0x10, 0x10 }, | ||
1477 | { "SCADERR", 0x20, 0x20 }, | ||
1478 | { "SCBCERR", 0x40, 0x40 }, | ||
1479 | { "STAETERM", 0x80, 0x80 } | ||
1480 | }; | ||
1481 | |||
1482 | int | ||
1483 | ahd_dchspltstat0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1484 | { | ||
1485 | return (ahd_print_register(DCHSPLTSTAT0_parse_table, 8, "DCHSPLTSTAT0", | ||
1486 | 0x96, regvalue, cur_col, wrap)); | ||
1487 | } | ||
1488 | |||
1489 | static const ahd_reg_parse_entry_t DCHSPLTSTAT1_parse_table[] = { | ||
1490 | { "RXDATABUCKET", 0x01, 0x01 } | ||
1491 | }; | ||
1492 | |||
1493 | int | ||
1494 | ahd_dchspltstat1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1495 | { | ||
1496 | return (ahd_print_register(DCHSPLTSTAT1_parse_table, 1, "DCHSPLTSTAT1", | ||
1497 | 0x97, regvalue, cur_col, wrap)); | ||
1498 | } | ||
1499 | |||
1500 | static const ahd_reg_parse_entry_t SGSPLTSTAT0_parse_table[] = { | ||
1501 | { "RXSPLTRSP", 0x01, 0x01 }, | ||
1502 | { "RXSCEMSG", 0x02, 0x02 }, | ||
1503 | { "RXOVRUN", 0x04, 0x04 }, | ||
1504 | { "CNTNOTCMPLT", 0x08, 0x08 }, | ||
1505 | { "SCDATBUCKET", 0x10, 0x10 }, | ||
1506 | { "SCADERR", 0x20, 0x20 }, | ||
1507 | { "SCBCERR", 0x40, 0x40 }, | ||
1508 | { "STAETERM", 0x80, 0x80 } | ||
1509 | }; | ||
1510 | |||
1511 | int | ||
1512 | ahd_sgspltstat0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1513 | { | ||
1514 | return (ahd_print_register(SGSPLTSTAT0_parse_table, 8, "SGSPLTSTAT0", | ||
1515 | 0x9e, regvalue, cur_col, wrap)); | ||
1516 | } | ||
1517 | |||
1518 | static const ahd_reg_parse_entry_t SGSPLTSTAT1_parse_table[] = { | ||
1519 | { "RXDATABUCKET", 0x01, 0x01 } | ||
1520 | }; | ||
1521 | |||
1522 | int | ||
1523 | ahd_sgspltstat1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1524 | { | ||
1525 | return (ahd_print_register(SGSPLTSTAT1_parse_table, 1, "SGSPLTSTAT1", | ||
1526 | 0x9f, regvalue, cur_col, wrap)); | ||
1527 | } | ||
1528 | |||
1529 | static const ahd_reg_parse_entry_t DF0PCISTAT_parse_table[] = { | ||
1530 | { "DPR", 0x01, 0x01 }, | ||
1531 | { "TWATERR", 0x02, 0x02 }, | ||
1532 | { "RDPERR", 0x04, 0x04 }, | ||
1533 | { "SCAAPERR", 0x08, 0x08 }, | ||
1534 | { "RTA", 0x10, 0x10 }, | ||
1535 | { "RMA", 0x20, 0x20 }, | ||
1536 | { "SSE", 0x40, 0x40 }, | ||
1537 | { "DPE", 0x80, 0x80 } | ||
1538 | }; | ||
1539 | |||
1540 | int | ||
1541 | ahd_df0pcistat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1542 | { | ||
1543 | return (ahd_print_register(DF0PCISTAT_parse_table, 8, "DF0PCISTAT", | ||
1544 | 0xa0, regvalue, cur_col, wrap)); | ||
1545 | } | ||
1546 | |||
1547 | int | ||
1548 | ahd_reg0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1549 | { | ||
1550 | return (ahd_print_register(NULL, 0, "REG0", | ||
1551 | 0xa0, regvalue, cur_col, wrap)); | ||
1552 | } | ||
1553 | |||
1554 | int | ||
1555 | ahd_reg_isr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1556 | { | ||
1557 | return (ahd_print_register(NULL, 0, "REG_ISR", | ||
1558 | 0xa4, regvalue, cur_col, wrap)); | ||
1559 | } | ||
1560 | |||
1561 | static const ahd_reg_parse_entry_t SG_STATE_parse_table[] = { | 533 | static const ahd_reg_parse_entry_t SG_STATE_parse_table[] = { |
1562 | { "SEGS_AVAIL", 0x01, 0x01 }, | 534 | { "SEGS_AVAIL", 0x01, 0x01 }, |
1563 | { "LOADING_NEEDED", 0x02, 0x02 }, | 535 | { "LOADING_NEEDED", 0x02, 0x02 }, |
@@ -1571,54 +543,6 @@ ahd_sg_state_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1571 | 0xa6, regvalue, cur_col, wrap)); | 543 | 0xa6, regvalue, cur_col, wrap)); |
1572 | } | 544 | } |
1573 | 545 | ||
1574 | static const ahd_reg_parse_entry_t TARGPCISTAT_parse_table[] = { | ||
1575 | { "TWATERR", 0x02, 0x02 }, | ||
1576 | { "STA", 0x08, 0x08 }, | ||
1577 | { "SSE", 0x40, 0x40 }, | ||
1578 | { "DPE", 0x80, 0x80 } | ||
1579 | }; | ||
1580 | |||
1581 | int | ||
1582 | ahd_targpcistat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1583 | { | ||
1584 | return (ahd_print_register(TARGPCISTAT_parse_table, 4, "TARGPCISTAT", | ||
1585 | 0xa7, regvalue, cur_col, wrap)); | ||
1586 | } | ||
1587 | |||
1588 | int | ||
1589 | ahd_scbptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1590 | { | ||
1591 | return (ahd_print_register(NULL, 0, "SCBPTR", | ||
1592 | 0xa8, regvalue, cur_col, wrap)); | ||
1593 | } | ||
1594 | |||
1595 | static const ahd_reg_parse_entry_t SCBAUTOPTR_parse_table[] = { | ||
1596 | { "SCBPTR_OFF", 0x07, 0x07 }, | ||
1597 | { "SCBPTR_ADDR", 0x38, 0x38 }, | ||
1598 | { "AUSCBPTR_EN", 0x80, 0x80 } | ||
1599 | }; | ||
1600 | |||
1601 | int | ||
1602 | ahd_scbautoptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1603 | { | ||
1604 | return (ahd_print_register(SCBAUTOPTR_parse_table, 3, "SCBAUTOPTR", | ||
1605 | 0xab, regvalue, cur_col, wrap)); | ||
1606 | } | ||
1607 | |||
1608 | int | ||
1609 | ahd_ccsgaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1610 | { | ||
1611 | return (ahd_print_register(NULL, 0, "CCSGADDR", | ||
1612 | 0xac, regvalue, cur_col, wrap)); | ||
1613 | } | ||
1614 | |||
1615 | int | ||
1616 | ahd_ccscbaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1617 | { | ||
1618 | return (ahd_print_register(NULL, 0, "CCSCBADDR", | ||
1619 | 0xac, regvalue, cur_col, wrap)); | ||
1620 | } | ||
1621 | |||
1622 | static const ahd_reg_parse_entry_t CCSCBCTL_parse_table[] = { | 546 | static const ahd_reg_parse_entry_t CCSCBCTL_parse_table[] = { |
1623 | { "CCSCBRESET", 0x01, 0x01 }, | 547 | { "CCSCBRESET", 0x01, 0x01 }, |
1624 | { "CCSCBDIR", 0x04, 0x04 }, | 548 | { "CCSCBDIR", 0x04, 0x04 }, |
@@ -1651,138 +575,6 @@ ahd_ccsgctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1651 | 0xad, regvalue, cur_col, wrap)); | 575 | 0xad, regvalue, cur_col, wrap)); |
1652 | } | 576 | } |
1653 | 577 | ||
1654 | int | ||
1655 | ahd_ccsgram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1656 | { | ||
1657 | return (ahd_print_register(NULL, 0, "CCSGRAM", | ||
1658 | 0xb0, regvalue, cur_col, wrap)); | ||
1659 | } | ||
1660 | |||
1661 | int | ||
1662 | ahd_ccscbram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1663 | { | ||
1664 | return (ahd_print_register(NULL, 0, "CCSCBRAM", | ||
1665 | 0xb0, regvalue, cur_col, wrap)); | ||
1666 | } | ||
1667 | |||
1668 | int | ||
1669 | ahd_brddat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1670 | { | ||
1671 | return (ahd_print_register(NULL, 0, "BRDDAT", | ||
1672 | 0xb8, regvalue, cur_col, wrap)); | ||
1673 | } | ||
1674 | |||
1675 | static const ahd_reg_parse_entry_t BRDCTL_parse_table[] = { | ||
1676 | { "BRDSTB", 0x01, 0x01 }, | ||
1677 | { "BRDRW", 0x02, 0x02 }, | ||
1678 | { "BRDEN", 0x04, 0x04 }, | ||
1679 | { "BRDADDR", 0x38, 0x38 }, | ||
1680 | { "FLXARBREQ", 0x40, 0x40 }, | ||
1681 | { "FLXARBACK", 0x80, 0x80 } | ||
1682 | }; | ||
1683 | |||
1684 | int | ||
1685 | ahd_brdctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1686 | { | ||
1687 | return (ahd_print_register(BRDCTL_parse_table, 6, "BRDCTL", | ||
1688 | 0xb9, regvalue, cur_col, wrap)); | ||
1689 | } | ||
1690 | |||
1691 | int | ||
1692 | ahd_seeadr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1693 | { | ||
1694 | return (ahd_print_register(NULL, 0, "SEEADR", | ||
1695 | 0xba, regvalue, cur_col, wrap)); | ||
1696 | } | ||
1697 | |||
1698 | int | ||
1699 | ahd_seedat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1700 | { | ||
1701 | return (ahd_print_register(NULL, 0, "SEEDAT", | ||
1702 | 0xbc, regvalue, cur_col, wrap)); | ||
1703 | } | ||
1704 | |||
1705 | static const ahd_reg_parse_entry_t SEECTL_parse_table[] = { | ||
1706 | { "SEEOP_ERAL", 0x40, 0x70 }, | ||
1707 | { "SEEOP_WRITE", 0x50, 0x70 }, | ||
1708 | { "SEEOP_READ", 0x60, 0x70 }, | ||
1709 | { "SEEOP_ERASE", 0x70, 0x70 }, | ||
1710 | { "SEESTART", 0x01, 0x01 }, | ||
1711 | { "SEERST", 0x02, 0x02 }, | ||
1712 | { "SEEOPCODE", 0x70, 0x70 }, | ||
1713 | { "SEEOP_EWEN", 0x40, 0x40 }, | ||
1714 | { "SEEOP_WALL", 0x40, 0x40 }, | ||
1715 | { "SEEOP_EWDS", 0x40, 0x40 } | ||
1716 | }; | ||
1717 | |||
1718 | int | ||
1719 | ahd_seectl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1720 | { | ||
1721 | return (ahd_print_register(SEECTL_parse_table, 10, "SEECTL", | ||
1722 | 0xbe, regvalue, cur_col, wrap)); | ||
1723 | } | ||
1724 | |||
1725 | static const ahd_reg_parse_entry_t SEESTAT_parse_table[] = { | ||
1726 | { "SEESTART", 0x01, 0x01 }, | ||
1727 | { "SEEBUSY", 0x02, 0x02 }, | ||
1728 | { "SEEARBACK", 0x04, 0x04 }, | ||
1729 | { "LDALTID_L", 0x08, 0x08 }, | ||
1730 | { "SEEOPCODE", 0x70, 0x70 }, | ||
1731 | { "INIT_DONE", 0x80, 0x80 } | ||
1732 | }; | ||
1733 | |||
1734 | int | ||
1735 | ahd_seestat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1736 | { | ||
1737 | return (ahd_print_register(SEESTAT_parse_table, 6, "SEESTAT", | ||
1738 | 0xbe, regvalue, cur_col, wrap)); | ||
1739 | } | ||
1740 | |||
1741 | static const ahd_reg_parse_entry_t DSPDATACTL_parse_table[] = { | ||
1742 | { "XMITOFFSTDIS", 0x02, 0x02 }, | ||
1743 | { "RCVROFFSTDIS", 0x04, 0x04 }, | ||
1744 | { "DESQDIS", 0x10, 0x10 }, | ||
1745 | { "BYPASSENAB", 0x80, 0x80 } | ||
1746 | }; | ||
1747 | |||
1748 | int | ||
1749 | ahd_dspdatactl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1750 | { | ||
1751 | return (ahd_print_register(DSPDATACTL_parse_table, 4, "DSPDATACTL", | ||
1752 | 0xc1, regvalue, cur_col, wrap)); | ||
1753 | } | ||
1754 | |||
1755 | int | ||
1756 | ahd_dfdat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1757 | { | ||
1758 | return (ahd_print_register(NULL, 0, "DFDAT", | ||
1759 | 0xc4, regvalue, cur_col, wrap)); | ||
1760 | } | ||
1761 | |||
1762 | static const ahd_reg_parse_entry_t DSPSELECT_parse_table[] = { | ||
1763 | { "DSPSEL", 0x1f, 0x1f }, | ||
1764 | { "AUTOINCEN", 0x80, 0x80 } | ||
1765 | }; | ||
1766 | |||
1767 | int | ||
1768 | ahd_dspselect_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1769 | { | ||
1770 | return (ahd_print_register(DSPSELECT_parse_table, 2, "DSPSELECT", | ||
1771 | 0xc4, regvalue, cur_col, wrap)); | ||
1772 | } | ||
1773 | |||
1774 | static const ahd_reg_parse_entry_t WRTBIASCTL_parse_table[] = { | ||
1775 | { "XMITMANVAL", 0x3f, 0x3f }, | ||
1776 | { "AUTOXBCDIS", 0x80, 0x80 } | ||
1777 | }; | ||
1778 | |||
1779 | int | ||
1780 | ahd_wrtbiasctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1781 | { | ||
1782 | return (ahd_print_register(WRTBIASCTL_parse_table, 2, "WRTBIASCTL", | ||
1783 | 0xc5, regvalue, cur_col, wrap)); | ||
1784 | } | ||
1785 | |||
1786 | static const ahd_reg_parse_entry_t SEQCTL0_parse_table[] = { | 578 | static const ahd_reg_parse_entry_t SEQCTL0_parse_table[] = { |
1787 | { "LOADRAM", 0x01, 0x01 }, | 579 | { "LOADRAM", 0x01, 0x01 }, |
1788 | { "SEQRESET", 0x02, 0x02 }, | 580 | { "SEQRESET", 0x02, 0x02 }, |
@@ -1801,18 +593,6 @@ ahd_seqctl0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1801 | 0xd6, regvalue, cur_col, wrap)); | 593 | 0xd6, regvalue, cur_col, wrap)); |
1802 | } | 594 | } |
1803 | 595 | ||
1804 | static const ahd_reg_parse_entry_t FLAGS_parse_table[] = { | ||
1805 | { "CARRY", 0x01, 0x01 }, | ||
1806 | { "ZERO", 0x02, 0x02 } | ||
1807 | }; | ||
1808 | |||
1809 | int | ||
1810 | ahd_flags_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1811 | { | ||
1812 | return (ahd_print_register(FLAGS_parse_table, 2, "FLAGS", | ||
1813 | 0xd8, regvalue, cur_col, wrap)); | ||
1814 | } | ||
1815 | |||
1816 | static const ahd_reg_parse_entry_t SEQINTCTL_parse_table[] = { | 596 | static const ahd_reg_parse_entry_t SEQINTCTL_parse_table[] = { |
1817 | { "IRET", 0x01, 0x01 }, | 597 | { "IRET", 0x01, 0x01 }, |
1818 | { "INTMASK1", 0x02, 0x02 }, | 598 | { "INTMASK1", 0x02, 0x02 }, |
@@ -1831,118 +611,6 @@ ahd_seqintctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1831 | } | 611 | } |
1832 | 612 | ||
1833 | int | 613 | int |
1834 | ahd_seqram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1835 | { | ||
1836 | return (ahd_print_register(NULL, 0, "SEQRAM", | ||
1837 | 0xda, regvalue, cur_col, wrap)); | ||
1838 | } | ||
1839 | |||
1840 | int | ||
1841 | ahd_prgmcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1842 | { | ||
1843 | return (ahd_print_register(NULL, 0, "PRGMCNT", | ||
1844 | 0xde, regvalue, cur_col, wrap)); | ||
1845 | } | ||
1846 | |||
1847 | int | ||
1848 | ahd_accum_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1849 | { | ||
1850 | return (ahd_print_register(NULL, 0, "ACCUM", | ||
1851 | 0xe0, regvalue, cur_col, wrap)); | ||
1852 | } | ||
1853 | |||
1854 | int | ||
1855 | ahd_sindex_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1856 | { | ||
1857 | return (ahd_print_register(NULL, 0, "SINDEX", | ||
1858 | 0xe2, regvalue, cur_col, wrap)); | ||
1859 | } | ||
1860 | |||
1861 | int | ||
1862 | ahd_dindex_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1863 | { | ||
1864 | return (ahd_print_register(NULL, 0, "DINDEX", | ||
1865 | 0xe4, regvalue, cur_col, wrap)); | ||
1866 | } | ||
1867 | |||
1868 | int | ||
1869 | ahd_allones_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1870 | { | ||
1871 | return (ahd_print_register(NULL, 0, "ALLONES", | ||
1872 | 0xe8, regvalue, cur_col, wrap)); | ||
1873 | } | ||
1874 | |||
1875 | int | ||
1876 | ahd_allzeros_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1877 | { | ||
1878 | return (ahd_print_register(NULL, 0, "ALLZEROS", | ||
1879 | 0xea, regvalue, cur_col, wrap)); | ||
1880 | } | ||
1881 | |||
1882 | int | ||
1883 | ahd_none_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1884 | { | ||
1885 | return (ahd_print_register(NULL, 0, "NONE", | ||
1886 | 0xea, regvalue, cur_col, wrap)); | ||
1887 | } | ||
1888 | |||
1889 | int | ||
1890 | ahd_sindir_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1891 | { | ||
1892 | return (ahd_print_register(NULL, 0, "SINDIR", | ||
1893 | 0xec, regvalue, cur_col, wrap)); | ||
1894 | } | ||
1895 | |||
1896 | int | ||
1897 | ahd_dindir_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1898 | { | ||
1899 | return (ahd_print_register(NULL, 0, "DINDIR", | ||
1900 | 0xed, regvalue, cur_col, wrap)); | ||
1901 | } | ||
1902 | |||
1903 | int | ||
1904 | ahd_stack_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1905 | { | ||
1906 | return (ahd_print_register(NULL, 0, "STACK", | ||
1907 | 0xf2, regvalue, cur_col, wrap)); | ||
1908 | } | ||
1909 | |||
1910 | int | ||
1911 | ahd_intvec1_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1912 | { | ||
1913 | return (ahd_print_register(NULL, 0, "INTVEC1_ADDR", | ||
1914 | 0xf4, regvalue, cur_col, wrap)); | ||
1915 | } | ||
1916 | |||
1917 | int | ||
1918 | ahd_curaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1919 | { | ||
1920 | return (ahd_print_register(NULL, 0, "CURADDR", | ||
1921 | 0xf4, regvalue, cur_col, wrap)); | ||
1922 | } | ||
1923 | |||
1924 | int | ||
1925 | ahd_intvec2_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1926 | { | ||
1927 | return (ahd_print_register(NULL, 0, "INTVEC2_ADDR", | ||
1928 | 0xf6, regvalue, cur_col, wrap)); | ||
1929 | } | ||
1930 | |||
1931 | int | ||
1932 | ahd_longjmp_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1933 | { | ||
1934 | return (ahd_print_register(NULL, 0, "LONGJMP_ADDR", | ||
1935 | 0xf8, regvalue, cur_col, wrap)); | ||
1936 | } | ||
1937 | |||
1938 | int | ||
1939 | ahd_accum_save_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1940 | { | ||
1941 | return (ahd_print_register(NULL, 0, "ACCUM_SAVE", | ||
1942 | 0xfa, regvalue, cur_col, wrap)); | ||
1943 | } | ||
1944 | |||
1945 | int | ||
1946 | ahd_sram_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | 614 | ahd_sram_base_print(u_int regvalue, u_int *cur_col, u_int wrap) |
1947 | { | 615 | { |
1948 | return (ahd_print_register(NULL, 0, "SRAM_BASE", | 616 | return (ahd_print_register(NULL, 0, "SRAM_BASE", |
@@ -1950,69 +618,6 @@ ahd_sram_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1950 | } | 618 | } |
1951 | 619 | ||
1952 | int | 620 | int |
1953 | ahd_waiting_scb_tails_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1954 | { | ||
1955 | return (ahd_print_register(NULL, 0, "WAITING_SCB_TAILS", | ||
1956 | 0x100, regvalue, cur_col, wrap)); | ||
1957 | } | ||
1958 | |||
1959 | int | ||
1960 | ahd_waiting_tid_head_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1961 | { | ||
1962 | return (ahd_print_register(NULL, 0, "WAITING_TID_HEAD", | ||
1963 | 0x120, regvalue, cur_col, wrap)); | ||
1964 | } | ||
1965 | |||
1966 | int | ||
1967 | ahd_waiting_tid_tail_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1968 | { | ||
1969 | return (ahd_print_register(NULL, 0, "WAITING_TID_TAIL", | ||
1970 | 0x122, regvalue, cur_col, wrap)); | ||
1971 | } | ||
1972 | |||
1973 | int | ||
1974 | ahd_next_queued_scb_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1975 | { | ||
1976 | return (ahd_print_register(NULL, 0, "NEXT_QUEUED_SCB_ADDR", | ||
1977 | 0x124, regvalue, cur_col, wrap)); | ||
1978 | } | ||
1979 | |||
1980 | int | ||
1981 | ahd_complete_scb_head_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1982 | { | ||
1983 | return (ahd_print_register(NULL, 0, "COMPLETE_SCB_HEAD", | ||
1984 | 0x128, regvalue, cur_col, wrap)); | ||
1985 | } | ||
1986 | |||
1987 | int | ||
1988 | ahd_complete_scb_dmainprog_head_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1989 | { | ||
1990 | return (ahd_print_register(NULL, 0, "COMPLETE_SCB_DMAINPROG_HEAD", | ||
1991 | 0x12a, regvalue, cur_col, wrap)); | ||
1992 | } | ||
1993 | |||
1994 | int | ||
1995 | ahd_complete_dma_scb_head_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1996 | { | ||
1997 | return (ahd_print_register(NULL, 0, "COMPLETE_DMA_SCB_HEAD", | ||
1998 | 0x12c, regvalue, cur_col, wrap)); | ||
1999 | } | ||
2000 | |||
2001 | int | ||
2002 | ahd_complete_dma_scb_tail_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2003 | { | ||
2004 | return (ahd_print_register(NULL, 0, "COMPLETE_DMA_SCB_TAIL", | ||
2005 | 0x12e, regvalue, cur_col, wrap)); | ||
2006 | } | ||
2007 | |||
2008 | int | ||
2009 | ahd_complete_on_qfreeze_head_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2010 | { | ||
2011 | return (ahd_print_register(NULL, 0, "COMPLETE_ON_QFREEZE_HEAD", | ||
2012 | 0x130, regvalue, cur_col, wrap)); | ||
2013 | } | ||
2014 | |||
2015 | int | ||
2016 | ahd_qfreeze_count_print(u_int regvalue, u_int *cur_col, u_int wrap) | 621 | ahd_qfreeze_count_print(u_int regvalue, u_int *cur_col, u_int wrap) |
2017 | { | 622 | { |
2018 | return (ahd_print_register(NULL, 0, "QFREEZE_COUNT", | 623 | return (ahd_print_register(NULL, 0, "QFREEZE_COUNT", |
@@ -2033,33 +638,6 @@ ahd_saved_mode_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
2033 | 0x136, regvalue, cur_col, wrap)); | 638 | 0x136, regvalue, cur_col, wrap)); |
2034 | } | 639 | } |
2035 | 640 | ||
2036 | int | ||
2037 | ahd_msg_out_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2038 | { | ||
2039 | return (ahd_print_register(NULL, 0, "MSG_OUT", | ||
2040 | 0x137, regvalue, cur_col, wrap)); | ||
2041 | } | ||
2042 | |||
2043 | static const ahd_reg_parse_entry_t DMAPARAMS_parse_table[] = { | ||
2044 | { "FIFORESET", 0x01, 0x01 }, | ||
2045 | { "FIFOFLUSH", 0x02, 0x02 }, | ||
2046 | { "DIRECTION", 0x04, 0x04 }, | ||
2047 | { "HDMAEN", 0x08, 0x08 }, | ||
2048 | { "HDMAENACK", 0x08, 0x08 }, | ||
2049 | { "SDMAEN", 0x10, 0x10 }, | ||
2050 | { "SDMAENACK", 0x10, 0x10 }, | ||
2051 | { "SCSIEN", 0x20, 0x20 }, | ||
2052 | { "WIDEODD", 0x40, 0x40 }, | ||
2053 | { "PRELOADEN", 0x80, 0x80 } | ||
2054 | }; | ||
2055 | |||
2056 | int | ||
2057 | ahd_dmaparams_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2058 | { | ||
2059 | return (ahd_print_register(DMAPARAMS_parse_table, 10, "DMAPARAMS", | ||
2060 | 0x138, regvalue, cur_col, wrap)); | ||
2061 | } | ||
2062 | |||
2063 | static const ahd_reg_parse_entry_t SEQ_FLAGS_parse_table[] = { | 641 | static const ahd_reg_parse_entry_t SEQ_FLAGS_parse_table[] = { |
2064 | { "NO_DISCONNECT", 0x01, 0x01 }, | 642 | { "NO_DISCONNECT", 0x01, 0x01 }, |
2065 | { "SPHASE_PENDING", 0x02, 0x02 }, | 643 | { "SPHASE_PENDING", 0x02, 0x02 }, |
@@ -2079,20 +657,6 @@ ahd_seq_flags_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
2079 | 0x139, regvalue, cur_col, wrap)); | 657 | 0x139, regvalue, cur_col, wrap)); |
2080 | } | 658 | } |
2081 | 659 | ||
2082 | int | ||
2083 | ahd_saved_scsiid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2084 | { | ||
2085 | return (ahd_print_register(NULL, 0, "SAVED_SCSIID", | ||
2086 | 0x13a, regvalue, cur_col, wrap)); | ||
2087 | } | ||
2088 | |||
2089 | int | ||
2090 | ahd_saved_lun_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2091 | { | ||
2092 | return (ahd_print_register(NULL, 0, "SAVED_LUN", | ||
2093 | 0x13b, regvalue, cur_col, wrap)); | ||
2094 | } | ||
2095 | |||
2096 | static const ahd_reg_parse_entry_t LASTPHASE_parse_table[] = { | 660 | static const ahd_reg_parse_entry_t LASTPHASE_parse_table[] = { |
2097 | { "P_DATAOUT", 0x00, 0xe0 }, | 661 | { "P_DATAOUT", 0x00, 0xe0 }, |
2098 | { "P_DATAOUT_DT", 0x20, 0xe0 }, | 662 | { "P_DATAOUT_DT", 0x20, 0xe0 }, |
@@ -2116,96 +680,6 @@ ahd_lastphase_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
2116 | 0x13c, regvalue, cur_col, wrap)); | 680 | 0x13c, regvalue, cur_col, wrap)); |
2117 | } | 681 | } |
2118 | 682 | ||
2119 | int | ||
2120 | ahd_qoutfifo_entry_valid_tag_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2121 | { | ||
2122 | return (ahd_print_register(NULL, 0, "QOUTFIFO_ENTRY_VALID_TAG", | ||
2123 | 0x13d, regvalue, cur_col, wrap)); | ||
2124 | } | ||
2125 | |||
2126 | int | ||
2127 | ahd_kernel_tqinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2128 | { | ||
2129 | return (ahd_print_register(NULL, 0, "KERNEL_TQINPOS", | ||
2130 | 0x13e, regvalue, cur_col, wrap)); | ||
2131 | } | ||
2132 | |||
2133 | int | ||
2134 | ahd_tqinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2135 | { | ||
2136 | return (ahd_print_register(NULL, 0, "TQINPOS", | ||
2137 | 0x13f, regvalue, cur_col, wrap)); | ||
2138 | } | ||
2139 | |||
2140 | int | ||
2141 | ahd_shared_data_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2142 | { | ||
2143 | return (ahd_print_register(NULL, 0, "SHARED_DATA_ADDR", | ||
2144 | 0x140, regvalue, cur_col, wrap)); | ||
2145 | } | ||
2146 | |||
2147 | int | ||
2148 | ahd_qoutfifo_next_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2149 | { | ||
2150 | return (ahd_print_register(NULL, 0, "QOUTFIFO_NEXT_ADDR", | ||
2151 | 0x144, regvalue, cur_col, wrap)); | ||
2152 | } | ||
2153 | |||
2154 | static const ahd_reg_parse_entry_t ARG_1_parse_table[] = { | ||
2155 | { "CONT_MSG_LOOP_TARG", 0x02, 0x02 }, | ||
2156 | { "CONT_MSG_LOOP_READ", 0x03, 0x03 }, | ||
2157 | { "CONT_MSG_LOOP_WRITE",0x04, 0x04 }, | ||
2158 | { "EXIT_MSG_LOOP", 0x08, 0x08 }, | ||
2159 | { "MSGOUT_PHASEMIS", 0x10, 0x10 }, | ||
2160 | { "SEND_REJ", 0x20, 0x20 }, | ||
2161 | { "SEND_SENSE", 0x40, 0x40 }, | ||
2162 | { "SEND_MSG", 0x80, 0x80 } | ||
2163 | }; | ||
2164 | |||
2165 | int | ||
2166 | ahd_arg_1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2167 | { | ||
2168 | return (ahd_print_register(ARG_1_parse_table, 8, "ARG_1", | ||
2169 | 0x148, regvalue, cur_col, wrap)); | ||
2170 | } | ||
2171 | |||
2172 | int | ||
2173 | ahd_arg_2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2174 | { | ||
2175 | return (ahd_print_register(NULL, 0, "ARG_2", | ||
2176 | 0x149, regvalue, cur_col, wrap)); | ||
2177 | } | ||
2178 | |||
2179 | int | ||
2180 | ahd_last_msg_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2181 | { | ||
2182 | return (ahd_print_register(NULL, 0, "LAST_MSG", | ||
2183 | 0x14a, regvalue, cur_col, wrap)); | ||
2184 | } | ||
2185 | |||
2186 | static const ahd_reg_parse_entry_t SCSISEQ_TEMPLATE_parse_table[] = { | ||
2187 | { "ALTSTIM", 0x01, 0x01 }, | ||
2188 | { "ENAUTOATNP", 0x02, 0x02 }, | ||
2189 | { "MANUALP", 0x0c, 0x0c }, | ||
2190 | { "ENRSELI", 0x10, 0x10 }, | ||
2191 | { "ENSELI", 0x20, 0x20 }, | ||
2192 | { "MANUALCTL", 0x40, 0x40 } | ||
2193 | }; | ||
2194 | |||
2195 | int | ||
2196 | ahd_scsiseq_template_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2197 | { | ||
2198 | return (ahd_print_register(SCSISEQ_TEMPLATE_parse_table, 6, "SCSISEQ_TEMPLATE", | ||
2199 | 0x14b, regvalue, cur_col, wrap)); | ||
2200 | } | ||
2201 | |||
2202 | int | ||
2203 | ahd_initiator_tag_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2204 | { | ||
2205 | return (ahd_print_register(NULL, 0, "INITIATOR_TAG", | ||
2206 | 0x14c, regvalue, cur_col, wrap)); | ||
2207 | } | ||
2208 | |||
2209 | static const ahd_reg_parse_entry_t SEQ_FLAGS2_parse_table[] = { | 683 | static const ahd_reg_parse_entry_t SEQ_FLAGS2_parse_table[] = { |
2210 | { "PENDING_MK_MESSAGE", 0x01, 0x01 }, | 684 | { "PENDING_MK_MESSAGE", 0x01, 0x01 }, |
2211 | { "TARGET_MSG_PENDING", 0x02, 0x02 }, | 685 | { "TARGET_MSG_PENDING", 0x02, 0x02 }, |
@@ -2220,62 +694,6 @@ ahd_seq_flags2_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
2220 | } | 694 | } |
2221 | 695 | ||
2222 | int | 696 | int |
2223 | ahd_allocfifo_scbptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2224 | { | ||
2225 | return (ahd_print_register(NULL, 0, "ALLOCFIFO_SCBPTR", | ||
2226 | 0x14e, regvalue, cur_col, wrap)); | ||
2227 | } | ||
2228 | |||
2229 | int | ||
2230 | ahd_int_coalescing_timer_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2231 | { | ||
2232 | return (ahd_print_register(NULL, 0, "INT_COALESCING_TIMER", | ||
2233 | 0x150, regvalue, cur_col, wrap)); | ||
2234 | } | ||
2235 | |||
2236 | int | ||
2237 | ahd_int_coalescing_maxcmds_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2238 | { | ||
2239 | return (ahd_print_register(NULL, 0, "INT_COALESCING_MAXCMDS", | ||
2240 | 0x152, regvalue, cur_col, wrap)); | ||
2241 | } | ||
2242 | |||
2243 | int | ||
2244 | ahd_int_coalescing_mincmds_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2245 | { | ||
2246 | return (ahd_print_register(NULL, 0, "INT_COALESCING_MINCMDS", | ||
2247 | 0x153, regvalue, cur_col, wrap)); | ||
2248 | } | ||
2249 | |||
2250 | int | ||
2251 | ahd_cmds_pending_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2252 | { | ||
2253 | return (ahd_print_register(NULL, 0, "CMDS_PENDING", | ||
2254 | 0x154, regvalue, cur_col, wrap)); | ||
2255 | } | ||
2256 | |||
2257 | int | ||
2258 | ahd_int_coalescing_cmdcount_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2259 | { | ||
2260 | return (ahd_print_register(NULL, 0, "INT_COALESCING_CMDCOUNT", | ||
2261 | 0x156, regvalue, cur_col, wrap)); | ||
2262 | } | ||
2263 | |||
2264 | int | ||
2265 | ahd_local_hs_mailbox_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2266 | { | ||
2267 | return (ahd_print_register(NULL, 0, "LOCAL_HS_MAILBOX", | ||
2268 | 0x157, regvalue, cur_col, wrap)); | ||
2269 | } | ||
2270 | |||
2271 | int | ||
2272 | ahd_cmdsize_table_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2273 | { | ||
2274 | return (ahd_print_register(NULL, 0, "CMDSIZE_TABLE", | ||
2275 | 0x158, regvalue, cur_col, wrap)); | ||
2276 | } | ||
2277 | |||
2278 | int | ||
2279 | ahd_mk_message_scb_print(u_int regvalue, u_int *cur_col, u_int wrap) | 697 | ahd_mk_message_scb_print(u_int regvalue, u_int *cur_col, u_int wrap) |
2280 | { | 698 | { |
2281 | return (ahd_print_register(NULL, 0, "MK_MESSAGE_SCB", | 699 | return (ahd_print_register(NULL, 0, "MK_MESSAGE_SCB", |
@@ -2290,53 +708,12 @@ ahd_mk_message_scsiid_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
2290 | } | 708 | } |
2291 | 709 | ||
2292 | int | 710 | int |
2293 | ahd_scb_residual_datacnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2294 | { | ||
2295 | return (ahd_print_register(NULL, 0, "SCB_RESIDUAL_DATACNT", | ||
2296 | 0x180, regvalue, cur_col, wrap)); | ||
2297 | } | ||
2298 | |||
2299 | int | ||
2300 | ahd_scb_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | 711 | ahd_scb_base_print(u_int regvalue, u_int *cur_col, u_int wrap) |
2301 | { | 712 | { |
2302 | return (ahd_print_register(NULL, 0, "SCB_BASE", | 713 | return (ahd_print_register(NULL, 0, "SCB_BASE", |
2303 | 0x180, regvalue, cur_col, wrap)); | 714 | 0x180, regvalue, cur_col, wrap)); |
2304 | } | 715 | } |
2305 | 716 | ||
2306 | static const ahd_reg_parse_entry_t SCB_RESIDUAL_SGPTR_parse_table[] = { | ||
2307 | { "SG_LIST_NULL", 0x01, 0x01 }, | ||
2308 | { "SG_OVERRUN_RESID", 0x02, 0x02 }, | ||
2309 | { "SG_ADDR_MASK", 0xf8, 0xf8 } | ||
2310 | }; | ||
2311 | |||
2312 | int | ||
2313 | ahd_scb_residual_sgptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2314 | { | ||
2315 | return (ahd_print_register(SCB_RESIDUAL_SGPTR_parse_table, 3, "SCB_RESIDUAL_SGPTR", | ||
2316 | 0x184, regvalue, cur_col, wrap)); | ||
2317 | } | ||
2318 | |||
2319 | int | ||
2320 | ahd_scb_scsi_status_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2321 | { | ||
2322 | return (ahd_print_register(NULL, 0, "SCB_SCSI_STATUS", | ||
2323 | 0x188, regvalue, cur_col, wrap)); | ||
2324 | } | ||
2325 | |||
2326 | int | ||
2327 | ahd_scb_sense_busaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2328 | { | ||
2329 | return (ahd_print_register(NULL, 0, "SCB_SENSE_BUSADDR", | ||
2330 | 0x18c, regvalue, cur_col, wrap)); | ||
2331 | } | ||
2332 | |||
2333 | int | ||
2334 | ahd_scb_tag_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2335 | { | ||
2336 | return (ahd_print_register(NULL, 0, "SCB_TAG", | ||
2337 | 0x190, regvalue, cur_col, wrap)); | ||
2338 | } | ||
2339 | |||
2340 | static const ahd_reg_parse_entry_t SCB_CONTROL_parse_table[] = { | 717 | static const ahd_reg_parse_entry_t SCB_CONTROL_parse_table[] = { |
2341 | { "SCB_TAG_TYPE", 0x03, 0x03 }, | 718 | { "SCB_TAG_TYPE", 0x03, 0x03 }, |
2342 | { "DISCONNECTED", 0x04, 0x04 }, | 719 | { "DISCONNECTED", 0x04, 0x04 }, |
@@ -2366,103 +743,3 @@ ahd_scb_scsiid_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
2366 | 0x193, regvalue, cur_col, wrap)); | 743 | 0x193, regvalue, cur_col, wrap)); |
2367 | } | 744 | } |
2368 | 745 | ||
2369 | static const ahd_reg_parse_entry_t SCB_LUN_parse_table[] = { | ||
2370 | { "LID", 0xff, 0xff } | ||
2371 | }; | ||
2372 | |||
2373 | int | ||
2374 | ahd_scb_lun_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2375 | { | ||
2376 | return (ahd_print_register(SCB_LUN_parse_table, 1, "SCB_LUN", | ||
2377 | 0x194, regvalue, cur_col, wrap)); | ||
2378 | } | ||
2379 | |||
2380 | static const ahd_reg_parse_entry_t SCB_TASK_ATTRIBUTE_parse_table[] = { | ||
2381 | { "SCB_XFERLEN_ODD", 0x01, 0x01 } | ||
2382 | }; | ||
2383 | |||
2384 | int | ||
2385 | ahd_scb_task_attribute_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2386 | { | ||
2387 | return (ahd_print_register(SCB_TASK_ATTRIBUTE_parse_table, 1, "SCB_TASK_ATTRIBUTE", | ||
2388 | 0x195, regvalue, cur_col, wrap)); | ||
2389 | } | ||
2390 | |||
2391 | static const ahd_reg_parse_entry_t SCB_CDB_LEN_parse_table[] = { | ||
2392 | { "SCB_CDB_LEN_PTR", 0x80, 0x80 } | ||
2393 | }; | ||
2394 | |||
2395 | int | ||
2396 | ahd_scb_cdb_len_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2397 | { | ||
2398 | return (ahd_print_register(SCB_CDB_LEN_parse_table, 1, "SCB_CDB_LEN", | ||
2399 | 0x196, regvalue, cur_col, wrap)); | ||
2400 | } | ||
2401 | |||
2402 | int | ||
2403 | ahd_scb_task_management_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2404 | { | ||
2405 | return (ahd_print_register(NULL, 0, "SCB_TASK_MANAGEMENT", | ||
2406 | 0x197, regvalue, cur_col, wrap)); | ||
2407 | } | ||
2408 | |||
2409 | int | ||
2410 | ahd_scb_dataptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2411 | { | ||
2412 | return (ahd_print_register(NULL, 0, "SCB_DATAPTR", | ||
2413 | 0x198, regvalue, cur_col, wrap)); | ||
2414 | } | ||
2415 | |||
2416 | static const ahd_reg_parse_entry_t SCB_DATACNT_parse_table[] = { | ||
2417 | { "SG_HIGH_ADDR_BITS", 0x7f, 0x7f }, | ||
2418 | { "SG_LAST_SEG", 0x80, 0x80 } | ||
2419 | }; | ||
2420 | |||
2421 | int | ||
2422 | ahd_scb_datacnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2423 | { | ||
2424 | return (ahd_print_register(SCB_DATACNT_parse_table, 2, "SCB_DATACNT", | ||
2425 | 0x1a0, regvalue, cur_col, wrap)); | ||
2426 | } | ||
2427 | |||
2428 | static const ahd_reg_parse_entry_t SCB_SGPTR_parse_table[] = { | ||
2429 | { "SG_LIST_NULL", 0x01, 0x01 }, | ||
2430 | { "SG_FULL_RESID", 0x02, 0x02 }, | ||
2431 | { "SG_STATUS_VALID", 0x04, 0x04 } | ||
2432 | }; | ||
2433 | |||
2434 | int | ||
2435 | ahd_scb_sgptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2436 | { | ||
2437 | return (ahd_print_register(SCB_SGPTR_parse_table, 3, "SCB_SGPTR", | ||
2438 | 0x1a4, regvalue, cur_col, wrap)); | ||
2439 | } | ||
2440 | |||
2441 | int | ||
2442 | ahd_scb_busaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2443 | { | ||
2444 | return (ahd_print_register(NULL, 0, "SCB_BUSADDR", | ||
2445 | 0x1a8, regvalue, cur_col, wrap)); | ||
2446 | } | ||
2447 | |||
2448 | int | ||
2449 | ahd_scb_next_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2450 | { | ||
2451 | return (ahd_print_register(NULL, 0, "SCB_NEXT", | ||
2452 | 0x1ac, regvalue, cur_col, wrap)); | ||
2453 | } | ||
2454 | |||
2455 | int | ||
2456 | ahd_scb_next2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2457 | { | ||
2458 | return (ahd_print_register(NULL, 0, "SCB_NEXT2", | ||
2459 | 0x1ae, regvalue, cur_col, wrap)); | ||
2460 | } | ||
2461 | |||
2462 | int | ||
2463 | ahd_scb_disconnected_lists_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
2464 | { | ||
2465 | return (ahd_print_register(NULL, 0, "SCB_DISCONNECTED_LISTS", | ||
2466 | 0x1b8, regvalue, cur_col, wrap)); | ||
2467 | } | ||
2468 | |||
diff --git a/drivers/scsi/aic7xxx/aic7xxx.reg b/drivers/scsi/aic7xxx/aic7xxx.reg index 0d2f763c3427..9a96e55da39a 100644 --- a/drivers/scsi/aic7xxx/aic7xxx.reg +++ b/drivers/scsi/aic7xxx/aic7xxx.reg | |||
@@ -51,6 +51,17 @@ VERSION = "$Id: //depot/aic7xxx/aic7xxx/aic7xxx.reg#40 $" | |||
51 | */ | 51 | */ |
52 | 52 | ||
53 | /* | 53 | /* |
54 | * Registers marked "dont_generate_debug_code" are not (yet) referenced | ||
55 | * from the driver code, and this keyword inhibit generation | ||
56 | * of debug code for them. | ||
57 | * | ||
58 | * REG_PRETTY_PRINT config will complain if dont_generate_debug_code | ||
59 | * is added to the register which is referenced in the driver. | ||
60 | * Unreferenced register with no dont_generate_debug_code will result | ||
61 | * in dead code. No warning is issued. | ||
62 | */ | ||
63 | |||
64 | /* | ||
54 | * SCSI Sequence Control (p. 3-11). | 65 | * SCSI Sequence Control (p. 3-11). |
55 | * Each bit, when set starts a specific SCSI sequence on the bus | 66 | * Each bit, when set starts a specific SCSI sequence on the bus |
56 | */ | 67 | */ |
@@ -97,6 +108,7 @@ register SXFRCTL1 { | |||
97 | field ENSTIMER 0x04 | 108 | field ENSTIMER 0x04 |
98 | field ACTNEGEN 0x02 | 109 | field ACTNEGEN 0x02 |
99 | field STPWEN 0x01 /* Powered Termination */ | 110 | field STPWEN 0x01 /* Powered Termination */ |
111 | dont_generate_debug_code | ||
100 | } | 112 | } |
101 | 113 | ||
102 | /* | 114 | /* |
@@ -155,6 +167,7 @@ register SCSISIGO { | |||
155 | mask P_MESGOUT CDI|MSGI | 167 | mask P_MESGOUT CDI|MSGI |
156 | mask P_STATUS CDI|IOI | 168 | mask P_STATUS CDI|IOI |
157 | mask P_MESGIN CDI|IOI|MSGI | 169 | mask P_MESGIN CDI|IOI|MSGI |
170 | dont_generate_debug_code | ||
158 | } | 171 | } |
159 | 172 | ||
160 | /* | 173 | /* |
@@ -194,6 +207,7 @@ register SCSIID { | |||
194 | */ | 207 | */ |
195 | alias SCSIOFFSET | 208 | alias SCSIOFFSET |
196 | mask SOFS_ULTRA2 0x7f /* Sync offset U2 chips */ | 209 | mask SOFS_ULTRA2 0x7f /* Sync offset U2 chips */ |
210 | dont_generate_debug_code | ||
197 | } | 211 | } |
198 | 212 | ||
199 | /* | 213 | /* |
@@ -205,6 +219,7 @@ register SCSIID { | |||
205 | register SCSIDATL { | 219 | register SCSIDATL { |
206 | address 0x006 | 220 | address 0x006 |
207 | access_mode RW | 221 | access_mode RW |
222 | dont_generate_debug_code | ||
208 | } | 223 | } |
209 | 224 | ||
210 | register SCSIDATH { | 225 | register SCSIDATH { |
@@ -223,6 +238,7 @@ register STCNT { | |||
223 | address 0x008 | 238 | address 0x008 |
224 | size 3 | 239 | size 3 |
225 | access_mode RW | 240 | access_mode RW |
241 | dont_generate_debug_code | ||
226 | } | 242 | } |
227 | 243 | ||
228 | /* ALT_MODE registers (Ultra2 and Ultra160 chips) */ | 244 | /* ALT_MODE registers (Ultra2 and Ultra160 chips) */ |
@@ -248,6 +264,7 @@ register OPTIONMODE { | |||
248 | field AUTO_MSGOUT_DE 0x02 | 264 | field AUTO_MSGOUT_DE 0x02 |
249 | field DIS_MSGIN_DUALEDGE 0x01 | 265 | field DIS_MSGIN_DUALEDGE 0x01 |
250 | mask OPTIONMODE_DEFAULTS AUTO_MSGOUT_DE|DIS_MSGIN_DUALEDGE | 266 | mask OPTIONMODE_DEFAULTS AUTO_MSGOUT_DE|DIS_MSGIN_DUALEDGE |
267 | dont_generate_debug_code | ||
251 | } | 268 | } |
252 | 269 | ||
253 | /* ALT_MODE register on Ultra160 chips */ | 270 | /* ALT_MODE register on Ultra160 chips */ |
@@ -256,6 +273,7 @@ register TARGCRCCNT { | |||
256 | size 2 | 273 | size 2 |
257 | access_mode RW | 274 | access_mode RW |
258 | count 2 | 275 | count 2 |
276 | dont_generate_debug_code | ||
259 | } | 277 | } |
260 | 278 | ||
261 | /* | 279 | /* |
@@ -271,6 +289,7 @@ register CLRSINT0 { | |||
271 | field CLRSWRAP 0x08 | 289 | field CLRSWRAP 0x08 |
272 | field CLRIOERR 0x08 /* Ultra2 Only */ | 290 | field CLRIOERR 0x08 /* Ultra2 Only */ |
273 | field CLRSPIORDY 0x02 | 291 | field CLRSPIORDY 0x02 |
292 | dont_generate_debug_code | ||
274 | } | 293 | } |
275 | 294 | ||
276 | /* | 295 | /* |
@@ -306,6 +325,7 @@ register CLRSINT1 { | |||
306 | field CLRSCSIPERR 0x04 | 325 | field CLRSCSIPERR 0x04 |
307 | field CLRPHASECHG 0x02 | 326 | field CLRPHASECHG 0x02 |
308 | field CLRREQINIT 0x01 | 327 | field CLRREQINIT 0x01 |
328 | dont_generate_debug_code | ||
309 | } | 329 | } |
310 | 330 | ||
311 | /* | 331 | /* |
@@ -360,6 +380,7 @@ register SCSIID_ULTRA2 { | |||
360 | access_mode RW | 380 | access_mode RW |
361 | mask TID 0xf0 /* Target ID mask */ | 381 | mask TID 0xf0 /* Target ID mask */ |
362 | mask OID 0x0f /* Our ID mask */ | 382 | mask OID 0x0f /* Our ID mask */ |
383 | dont_generate_debug_code | ||
363 | } | 384 | } |
364 | 385 | ||
365 | /* | 386 | /* |
@@ -425,6 +446,7 @@ register SHADDR { | |||
425 | address 0x014 | 446 | address 0x014 |
426 | size 4 | 447 | size 4 |
427 | access_mode RO | 448 | access_mode RO |
449 | dont_generate_debug_code | ||
428 | } | 450 | } |
429 | 451 | ||
430 | /* | 452 | /* |
@@ -441,6 +463,7 @@ register SELTIMER { | |||
441 | field STAGE2 0x02 | 463 | field STAGE2 0x02 |
442 | field STAGE1 0x01 | 464 | field STAGE1 0x01 |
443 | alias TARGIDIN | 465 | alias TARGIDIN |
466 | dont_generate_debug_code | ||
444 | } | 467 | } |
445 | 468 | ||
446 | /* | 469 | /* |
@@ -453,6 +476,7 @@ register SELID { | |||
453 | access_mode RW | 476 | access_mode RW |
454 | mask SELID_MASK 0xf0 | 477 | mask SELID_MASK 0xf0 |
455 | field ONEBIT 0x08 | 478 | field ONEBIT 0x08 |
479 | dont_generate_debug_code | ||
456 | } | 480 | } |
457 | 481 | ||
458 | register SCAMCTL { | 482 | register SCAMCTL { |
@@ -473,6 +497,7 @@ register TARGID { | |||
473 | size 2 | 497 | size 2 |
474 | access_mode RW | 498 | access_mode RW |
475 | count 14 | 499 | count 14 |
500 | dont_generate_debug_code | ||
476 | } | 501 | } |
477 | 502 | ||
478 | /* | 503 | /* |
@@ -495,6 +520,7 @@ register SPIOCAP { | |||
495 | field EEPROM 0x04 /* Writable external BIOS ROM */ | 520 | field EEPROM 0x04 /* Writable external BIOS ROM */ |
496 | field ROM 0x02 /* Logic for accessing external ROM */ | 521 | field ROM 0x02 /* Logic for accessing external ROM */ |
497 | field SSPIOCPS 0x01 /* Termination and cable detection */ | 522 | field SSPIOCPS 0x01 /* Termination and cable detection */ |
523 | dont_generate_debug_code | ||
498 | } | 524 | } |
499 | 525 | ||
500 | register BRDCTL { | 526 | register BRDCTL { |
@@ -514,6 +540,7 @@ register BRDCTL { | |||
514 | field BRDDAT2 0x04 | 540 | field BRDDAT2 0x04 |
515 | field BRDRW_ULTRA2 0x02 | 541 | field BRDRW_ULTRA2 0x02 |
516 | field BRDSTB_ULTRA2 0x01 | 542 | field BRDSTB_ULTRA2 0x01 |
543 | dont_generate_debug_code | ||
517 | } | 544 | } |
518 | 545 | ||
519 | /* | 546 | /* |
@@ -551,6 +578,7 @@ register SEECTL { | |||
551 | field SEECK 0x04 | 578 | field SEECK 0x04 |
552 | field SEEDO 0x02 | 579 | field SEEDO 0x02 |
553 | field SEEDI 0x01 | 580 | field SEEDI 0x01 |
581 | dont_generate_debug_code | ||
554 | } | 582 | } |
555 | /* | 583 | /* |
556 | * SCSI Block Control (p. 3-32) | 584 | * SCSI Block Control (p. 3-32) |
@@ -601,6 +629,7 @@ register SEQRAM { | |||
601 | address 0x061 | 629 | address 0x061 |
602 | access_mode RW | 630 | access_mode RW |
603 | count 2 | 631 | count 2 |
632 | dont_generate_debug_code | ||
604 | } | 633 | } |
605 | 634 | ||
606 | /* | 635 | /* |
@@ -610,6 +639,7 @@ register SEQRAM { | |||
610 | register SEQADDR0 { | 639 | register SEQADDR0 { |
611 | address 0x062 | 640 | address 0x062 |
612 | access_mode RW | 641 | access_mode RW |
642 | dont_generate_debug_code | ||
613 | } | 643 | } |
614 | 644 | ||
615 | register SEQADDR1 { | 645 | register SEQADDR1 { |
@@ -617,6 +647,7 @@ register SEQADDR1 { | |||
617 | access_mode RW | 647 | access_mode RW |
618 | count 8 | 648 | count 8 |
619 | mask SEQADDR1_MASK 0x01 | 649 | mask SEQADDR1_MASK 0x01 |
650 | dont_generate_debug_code | ||
620 | } | 651 | } |
621 | 652 | ||
622 | /* | 653 | /* |
@@ -627,35 +658,41 @@ register ACCUM { | |||
627 | address 0x064 | 658 | address 0x064 |
628 | access_mode RW | 659 | access_mode RW |
629 | accumulator | 660 | accumulator |
661 | dont_generate_debug_code | ||
630 | } | 662 | } |
631 | 663 | ||
632 | register SINDEX { | 664 | register SINDEX { |
633 | address 0x065 | 665 | address 0x065 |
634 | access_mode RW | 666 | access_mode RW |
635 | sindex | 667 | sindex |
668 | dont_generate_debug_code | ||
636 | } | 669 | } |
637 | 670 | ||
638 | register DINDEX { | 671 | register DINDEX { |
639 | address 0x066 | 672 | address 0x066 |
640 | access_mode RW | 673 | access_mode RW |
674 | dont_generate_debug_code | ||
641 | } | 675 | } |
642 | 676 | ||
643 | register ALLONES { | 677 | register ALLONES { |
644 | address 0x069 | 678 | address 0x069 |
645 | access_mode RO | 679 | access_mode RO |
646 | allones | 680 | allones |
681 | dont_generate_debug_code | ||
647 | } | 682 | } |
648 | 683 | ||
649 | register ALLZEROS { | 684 | register ALLZEROS { |
650 | address 0x06a | 685 | address 0x06a |
651 | access_mode RO | 686 | access_mode RO |
652 | allzeros | 687 | allzeros |
688 | dont_generate_debug_code | ||
653 | } | 689 | } |
654 | 690 | ||
655 | register NONE { | 691 | register NONE { |
656 | address 0x06a | 692 | address 0x06a |
657 | access_mode WO | 693 | access_mode WO |
658 | none | 694 | none |
695 | dont_generate_debug_code | ||
659 | } | 696 | } |
660 | 697 | ||
661 | register FLAGS { | 698 | register FLAGS { |
@@ -664,16 +701,19 @@ register FLAGS { | |||
664 | count 18 | 701 | count 18 |
665 | field ZERO 0x02 | 702 | field ZERO 0x02 |
666 | field CARRY 0x01 | 703 | field CARRY 0x01 |
704 | dont_generate_debug_code | ||
667 | } | 705 | } |
668 | 706 | ||
669 | register SINDIR { | 707 | register SINDIR { |
670 | address 0x06c | 708 | address 0x06c |
671 | access_mode RO | 709 | access_mode RO |
710 | dont_generate_debug_code | ||
672 | } | 711 | } |
673 | 712 | ||
674 | register DINDIR { | 713 | register DINDIR { |
675 | address 0x06d | 714 | address 0x06d |
676 | access_mode WO | 715 | access_mode WO |
716 | dont_generate_debug_code | ||
677 | } | 717 | } |
678 | 718 | ||
679 | register FUNCTION1 { | 719 | register FUNCTION1 { |
@@ -685,6 +725,7 @@ register STACK { | |||
685 | address 0x06f | 725 | address 0x06f |
686 | access_mode RO | 726 | access_mode RO |
687 | count 5 | 727 | count 5 |
728 | dont_generate_debug_code | ||
688 | } | 729 | } |
689 | 730 | ||
690 | const STACK_SIZE 4 | 731 | const STACK_SIZE 4 |
@@ -716,6 +757,7 @@ register DSCOMMAND0 { | |||
716 | field RAMPS 0x04 /* External SCB RAM Present */ | 757 | field RAMPS 0x04 /* External SCB RAM Present */ |
717 | field USCBSIZE32 0x02 /* Use 32byte SCB Page Size */ | 758 | field USCBSIZE32 0x02 /* Use 32byte SCB Page Size */ |
718 | field CIOPARCKEN 0x01 /* Internal bus parity error enable */ | 759 | field CIOPARCKEN 0x01 /* Internal bus parity error enable */ |
760 | dont_generate_debug_code | ||
719 | } | 761 | } |
720 | 762 | ||
721 | register DSCOMMAND1 { | 763 | register DSCOMMAND1 { |
@@ -724,6 +766,7 @@ register DSCOMMAND1 { | |||
724 | mask DSLATT 0xfc /* PCI latency timer (non-ultra2) */ | 766 | mask DSLATT 0xfc /* PCI latency timer (non-ultra2) */ |
725 | field HADDLDSEL1 0x02 /* Host Address Load Select Bits */ | 767 | field HADDLDSEL1 0x02 /* Host Address Load Select Bits */ |
726 | field HADDLDSEL0 0x01 | 768 | field HADDLDSEL0 0x01 |
769 | dont_generate_debug_code | ||
727 | } | 770 | } |
728 | 771 | ||
729 | /* | 772 | /* |
@@ -735,6 +778,7 @@ register BUSTIME { | |||
735 | count 2 | 778 | count 2 |
736 | mask BOFF 0xf0 | 779 | mask BOFF 0xf0 |
737 | mask BON 0x0f | 780 | mask BON 0x0f |
781 | dont_generate_debug_code | ||
738 | } | 782 | } |
739 | 783 | ||
740 | /* | 784 | /* |
@@ -749,6 +793,7 @@ register BUSSPD { | |||
749 | mask STBON 0x07 | 793 | mask STBON 0x07 |
750 | mask DFTHRSH_100 0xc0 | 794 | mask DFTHRSH_100 0xc0 |
751 | mask DFTHRSH_75 0x80 | 795 | mask DFTHRSH_75 0x80 |
796 | dont_generate_debug_code | ||
752 | } | 797 | } |
753 | 798 | ||
754 | /* aic7850/55/60/70/80/95 only */ | 799 | /* aic7850/55/60/70/80/95 only */ |
@@ -756,6 +801,7 @@ register DSPCISTATUS { | |||
756 | address 0x086 | 801 | address 0x086 |
757 | count 4 | 802 | count 4 |
758 | mask DFTHRSH_100 0xc0 | 803 | mask DFTHRSH_100 0xc0 |
804 | dont_generate_debug_code | ||
759 | } | 805 | } |
760 | 806 | ||
761 | /* aic7890/91/96/97 only */ | 807 | /* aic7890/91/96/97 only */ |
@@ -764,6 +810,7 @@ register HS_MAILBOX { | |||
764 | mask HOST_MAILBOX 0xF0 | 810 | mask HOST_MAILBOX 0xF0 |
765 | mask SEQ_MAILBOX 0x0F | 811 | mask SEQ_MAILBOX 0x0F |
766 | mask HOST_TQINPOS 0x80 /* Boundary at either 0 or 128 */ | 812 | mask HOST_TQINPOS 0x80 /* Boundary at either 0 or 128 */ |
813 | dont_generate_debug_code | ||
767 | } | 814 | } |
768 | 815 | ||
769 | const HOST_MAILBOX_SHIFT 4 | 816 | const HOST_MAILBOX_SHIFT 4 |
@@ -784,6 +831,7 @@ register HCNTRL { | |||
784 | field INTEN 0x02 | 831 | field INTEN 0x02 |
785 | field CHIPRST 0x01 | 832 | field CHIPRST 0x01 |
786 | field CHIPRSTACK 0x01 | 833 | field CHIPRSTACK 0x01 |
834 | dont_generate_debug_code | ||
787 | } | 835 | } |
788 | 836 | ||
789 | /* | 837 | /* |
@@ -795,12 +843,14 @@ register HADDR { | |||
795 | address 0x088 | 843 | address 0x088 |
796 | size 4 | 844 | size 4 |
797 | access_mode RW | 845 | access_mode RW |
846 | dont_generate_debug_code | ||
798 | } | 847 | } |
799 | 848 | ||
800 | register HCNT { | 849 | register HCNT { |
801 | address 0x08c | 850 | address 0x08c |
802 | size 3 | 851 | size 3 |
803 | access_mode RW | 852 | access_mode RW |
853 | dont_generate_debug_code | ||
804 | } | 854 | } |
805 | 855 | ||
806 | /* | 856 | /* |
@@ -810,6 +860,7 @@ register HCNT { | |||
810 | register SCBPTR { | 860 | register SCBPTR { |
811 | address 0x090 | 861 | address 0x090 |
812 | access_mode RW | 862 | access_mode RW |
863 | dont_generate_debug_code | ||
813 | } | 864 | } |
814 | 865 | ||
815 | /* | 866 | /* |
@@ -878,6 +929,7 @@ register INTSTAT { | |||
878 | 929 | ||
879 | mask SEQINT_MASK 0xf0|SEQINT /* SEQINT Status Codes */ | 930 | mask SEQINT_MASK 0xf0|SEQINT /* SEQINT Status Codes */ |
880 | mask INT_PEND (BRKADRINT|SEQINT|SCSIINT|CMDCMPLT) | 931 | mask INT_PEND (BRKADRINT|SEQINT|SCSIINT|CMDCMPLT) |
932 | dont_generate_debug_code | ||
881 | } | 933 | } |
882 | 934 | ||
883 | /* | 935 | /* |
@@ -911,6 +963,7 @@ register CLRINT { | |||
911 | field CLRSCSIINT 0x04 | 963 | field CLRSCSIINT 0x04 |
912 | field CLRCMDINT 0x02 | 964 | field CLRCMDINT 0x02 |
913 | field CLRSEQINT 0x01 | 965 | field CLRSEQINT 0x01 |
966 | dont_generate_debug_code | ||
914 | } | 967 | } |
915 | 968 | ||
916 | register DFCNTRL { | 969 | register DFCNTRL { |
@@ -944,6 +997,7 @@ register DFSTATUS { | |||
944 | register DFWADDR { | 997 | register DFWADDR { |
945 | address 0x95 | 998 | address 0x95 |
946 | access_mode RW | 999 | access_mode RW |
1000 | dont_generate_debug_code | ||
947 | } | 1001 | } |
948 | 1002 | ||
949 | register DFRADDR { | 1003 | register DFRADDR { |
@@ -954,6 +1008,7 @@ register DFRADDR { | |||
954 | register DFDAT { | 1008 | register DFDAT { |
955 | address 0x099 | 1009 | address 0x099 |
956 | access_mode RW | 1010 | access_mode RW |
1011 | dont_generate_debug_code | ||
957 | } | 1012 | } |
958 | 1013 | ||
959 | /* | 1014 | /* |
@@ -967,6 +1022,7 @@ register SCBCNT { | |||
967 | count 1 | 1022 | count 1 |
968 | field SCBAUTO 0x80 | 1023 | field SCBAUTO 0x80 |
969 | mask SCBCNT_MASK 0x1f | 1024 | mask SCBCNT_MASK 0x1f |
1025 | dont_generate_debug_code | ||
970 | } | 1026 | } |
971 | 1027 | ||
972 | /* | 1028 | /* |
@@ -977,6 +1033,7 @@ register QINFIFO { | |||
977 | address 0x09b | 1033 | address 0x09b |
978 | access_mode RW | 1034 | access_mode RW |
979 | count 12 | 1035 | count 12 |
1036 | dont_generate_debug_code | ||
980 | } | 1037 | } |
981 | 1038 | ||
982 | /* | 1039 | /* |
@@ -996,6 +1053,7 @@ register QOUTFIFO { | |||
996 | address 0x09d | 1053 | address 0x09d |
997 | access_mode WO | 1054 | access_mode WO |
998 | count 7 | 1055 | count 7 |
1056 | dont_generate_debug_code | ||
999 | } | 1057 | } |
1000 | 1058 | ||
1001 | register CRCCONTROL1 { | 1059 | register CRCCONTROL1 { |
@@ -1008,6 +1066,7 @@ register CRCCONTROL1 { | |||
1008 | field CRCREQCHKEN 0x10 | 1066 | field CRCREQCHKEN 0x10 |
1009 | field TARGCRCENDEN 0x08 | 1067 | field TARGCRCENDEN 0x08 |
1010 | field TARGCRCCNTEN 0x04 | 1068 | field TARGCRCCNTEN 0x04 |
1069 | dont_generate_debug_code | ||
1011 | } | 1070 | } |
1012 | 1071 | ||
1013 | 1072 | ||
@@ -1040,6 +1099,7 @@ register SFUNCT { | |||
1040 | access_mode RW | 1099 | access_mode RW |
1041 | count 4 | 1100 | count 4 |
1042 | field ALT_MODE 0x80 | 1101 | field ALT_MODE 0x80 |
1102 | dont_generate_debug_code | ||
1043 | } | 1103 | } |
1044 | 1104 | ||
1045 | /* | 1105 | /* |
@@ -1053,24 +1113,31 @@ scb { | |||
1053 | size 4 | 1113 | size 4 |
1054 | alias SCB_RESIDUAL_DATACNT | 1114 | alias SCB_RESIDUAL_DATACNT |
1055 | alias SCB_CDB_STORE | 1115 | alias SCB_CDB_STORE |
1116 | dont_generate_debug_code | ||
1056 | } | 1117 | } |
1057 | SCB_RESIDUAL_SGPTR { | 1118 | SCB_RESIDUAL_SGPTR { |
1058 | size 4 | 1119 | size 4 |
1120 | dont_generate_debug_code | ||
1059 | } | 1121 | } |
1060 | SCB_SCSI_STATUS { | 1122 | SCB_SCSI_STATUS { |
1061 | size 1 | 1123 | size 1 |
1124 | dont_generate_debug_code | ||
1062 | } | 1125 | } |
1063 | SCB_TARGET_PHASES { | 1126 | SCB_TARGET_PHASES { |
1064 | size 1 | 1127 | size 1 |
1128 | dont_generate_debug_code | ||
1065 | } | 1129 | } |
1066 | SCB_TARGET_DATA_DIR { | 1130 | SCB_TARGET_DATA_DIR { |
1067 | size 1 | 1131 | size 1 |
1132 | dont_generate_debug_code | ||
1068 | } | 1133 | } |
1069 | SCB_TARGET_ITAG { | 1134 | SCB_TARGET_ITAG { |
1070 | size 1 | 1135 | size 1 |
1136 | dont_generate_debug_code | ||
1071 | } | 1137 | } |
1072 | SCB_DATAPTR { | 1138 | SCB_DATAPTR { |
1073 | size 4 | 1139 | size 4 |
1140 | dont_generate_debug_code | ||
1074 | } | 1141 | } |
1075 | SCB_DATACNT { | 1142 | SCB_DATACNT { |
1076 | /* | 1143 | /* |
@@ -1080,12 +1147,14 @@ scb { | |||
1080 | size 4 | 1147 | size 4 |
1081 | field SG_LAST_SEG 0x80 /* In the fourth byte */ | 1148 | field SG_LAST_SEG 0x80 /* In the fourth byte */ |
1082 | mask SG_HIGH_ADDR_BITS 0x7F /* In the fourth byte */ | 1149 | mask SG_HIGH_ADDR_BITS 0x7F /* In the fourth byte */ |
1150 | dont_generate_debug_code | ||
1083 | } | 1151 | } |
1084 | SCB_SGPTR { | 1152 | SCB_SGPTR { |
1085 | size 4 | 1153 | size 4 |
1086 | field SG_RESID_VALID 0x04 /* In the first byte */ | 1154 | field SG_RESID_VALID 0x04 /* In the first byte */ |
1087 | field SG_FULL_RESID 0x02 /* In the first byte */ | 1155 | field SG_FULL_RESID 0x02 /* In the first byte */ |
1088 | field SG_LIST_NULL 0x01 /* In the first byte */ | 1156 | field SG_LIST_NULL 0x01 /* In the first byte */ |
1157 | dont_generate_debug_code | ||
1089 | } | 1158 | } |
1090 | SCB_CONTROL { | 1159 | SCB_CONTROL { |
1091 | size 1 | 1160 | size 1 |
@@ -1115,22 +1184,27 @@ scb { | |||
1115 | } | 1184 | } |
1116 | SCB_CDB_LEN { | 1185 | SCB_CDB_LEN { |
1117 | size 1 | 1186 | size 1 |
1187 | dont_generate_debug_code | ||
1118 | } | 1188 | } |
1119 | SCB_SCSIRATE { | 1189 | SCB_SCSIRATE { |
1120 | size 1 | 1190 | size 1 |
1191 | dont_generate_debug_code | ||
1121 | } | 1192 | } |
1122 | SCB_SCSIOFFSET { | 1193 | SCB_SCSIOFFSET { |
1123 | size 1 | 1194 | size 1 |
1124 | count 1 | 1195 | count 1 |
1196 | dont_generate_debug_code | ||
1125 | } | 1197 | } |
1126 | SCB_NEXT { | 1198 | SCB_NEXT { |
1127 | size 1 | 1199 | size 1 |
1200 | dont_generate_debug_code | ||
1128 | } | 1201 | } |
1129 | SCB_64_SPARE { | 1202 | SCB_64_SPARE { |
1130 | size 16 | 1203 | size 16 |
1131 | } | 1204 | } |
1132 | SCB_64_BTT { | 1205 | SCB_64_BTT { |
1133 | size 16 | 1206 | size 16 |
1207 | dont_generate_debug_code | ||
1134 | } | 1208 | } |
1135 | } | 1209 | } |
1136 | 1210 | ||
@@ -1149,6 +1223,7 @@ register SEECTL_2840 { | |||
1149 | field CS_2840 0x04 | 1223 | field CS_2840 0x04 |
1150 | field CK_2840 0x02 | 1224 | field CK_2840 0x02 |
1151 | field DO_2840 0x01 | 1225 | field DO_2840 0x01 |
1226 | dont_generate_debug_code | ||
1152 | } | 1227 | } |
1153 | 1228 | ||
1154 | register STATUS_2840 { | 1229 | register STATUS_2840 { |
@@ -1159,6 +1234,7 @@ register STATUS_2840 { | |||
1159 | mask BIOS_SEL 0x60 | 1234 | mask BIOS_SEL 0x60 |
1160 | mask ADSEL 0x1e | 1235 | mask ADSEL 0x1e |
1161 | field DI_2840 0x01 | 1236 | field DI_2840 0x01 |
1237 | dont_generate_debug_code | ||
1162 | } | 1238 | } |
1163 | 1239 | ||
1164 | /* --------------------- AIC-7870-only definitions -------------------- */ | 1240 | /* --------------------- AIC-7870-only definitions -------------------- */ |
@@ -1166,18 +1242,22 @@ register STATUS_2840 { | |||
1166 | register CCHADDR { | 1242 | register CCHADDR { |
1167 | address 0x0E0 | 1243 | address 0x0E0 |
1168 | size 8 | 1244 | size 8 |
1245 | dont_generate_debug_code | ||
1169 | } | 1246 | } |
1170 | 1247 | ||
1171 | register CCHCNT { | 1248 | register CCHCNT { |
1172 | address 0x0E8 | 1249 | address 0x0E8 |
1250 | dont_generate_debug_code | ||
1173 | } | 1251 | } |
1174 | 1252 | ||
1175 | register CCSGRAM { | 1253 | register CCSGRAM { |
1176 | address 0x0E9 | 1254 | address 0x0E9 |
1255 | dont_generate_debug_code | ||
1177 | } | 1256 | } |
1178 | 1257 | ||
1179 | register CCSGADDR { | 1258 | register CCSGADDR { |
1180 | address 0x0EA | 1259 | address 0x0EA |
1260 | dont_generate_debug_code | ||
1181 | } | 1261 | } |
1182 | 1262 | ||
1183 | register CCSGCTL { | 1263 | register CCSGCTL { |
@@ -1186,11 +1266,13 @@ register CCSGCTL { | |||
1186 | field CCSGEN 0x08 | 1266 | field CCSGEN 0x08 |
1187 | field SG_FETCH_NEEDED 0x02 /* Bit used for software state */ | 1267 | field SG_FETCH_NEEDED 0x02 /* Bit used for software state */ |
1188 | field CCSGRESET 0x01 | 1268 | field CCSGRESET 0x01 |
1269 | dont_generate_debug_code | ||
1189 | } | 1270 | } |
1190 | 1271 | ||
1191 | register CCSCBCNT { | 1272 | register CCSCBCNT { |
1192 | address 0xEF | 1273 | address 0xEF |
1193 | count 1 | 1274 | count 1 |
1275 | dont_generate_debug_code | ||
1194 | } | 1276 | } |
1195 | 1277 | ||
1196 | register CCSCBCTL { | 1278 | register CCSCBCTL { |
@@ -1201,14 +1283,17 @@ register CCSCBCTL { | |||
1201 | field CCSCBEN 0x08 | 1283 | field CCSCBEN 0x08 |
1202 | field CCSCBDIR 0x04 | 1284 | field CCSCBDIR 0x04 |
1203 | field CCSCBRESET 0x01 | 1285 | field CCSCBRESET 0x01 |
1286 | dont_generate_debug_code | ||
1204 | } | 1287 | } |
1205 | 1288 | ||
1206 | register CCSCBADDR { | 1289 | register CCSCBADDR { |
1207 | address 0x0ED | 1290 | address 0x0ED |
1291 | dont_generate_debug_code | ||
1208 | } | 1292 | } |
1209 | 1293 | ||
1210 | register CCSCBRAM { | 1294 | register CCSCBRAM { |
1211 | address 0xEC | 1295 | address 0xEC |
1296 | dont_generate_debug_code | ||
1212 | } | 1297 | } |
1213 | 1298 | ||
1214 | /* | 1299 | /* |
@@ -1218,23 +1303,28 @@ register SCBBADDR { | |||
1218 | address 0x0F0 | 1303 | address 0x0F0 |
1219 | access_mode RW | 1304 | access_mode RW |
1220 | count 3 | 1305 | count 3 |
1306 | dont_generate_debug_code | ||
1221 | } | 1307 | } |
1222 | 1308 | ||
1223 | register CCSCBPTR { | 1309 | register CCSCBPTR { |
1224 | address 0x0F1 | 1310 | address 0x0F1 |
1311 | dont_generate_debug_code | ||
1225 | } | 1312 | } |
1226 | 1313 | ||
1227 | register HNSCB_QOFF { | 1314 | register HNSCB_QOFF { |
1228 | address 0x0F4 | 1315 | address 0x0F4 |
1229 | count 4 | 1316 | count 4 |
1317 | dont_generate_debug_code | ||
1230 | } | 1318 | } |
1231 | 1319 | ||
1232 | register SNSCB_QOFF { | 1320 | register SNSCB_QOFF { |
1233 | address 0x0F6 | 1321 | address 0x0F6 |
1322 | dont_generate_debug_code | ||
1234 | } | 1323 | } |
1235 | 1324 | ||
1236 | register SDSCB_QOFF { | 1325 | register SDSCB_QOFF { |
1237 | address 0x0F8 | 1326 | address 0x0F8 |
1327 | dont_generate_debug_code | ||
1238 | } | 1328 | } |
1239 | 1329 | ||
1240 | register QOFF_CTLSTA { | 1330 | register QOFF_CTLSTA { |
@@ -1244,6 +1334,7 @@ register QOFF_CTLSTA { | |||
1244 | field SDSCB_ROLLOVER 0x10 | 1334 | field SDSCB_ROLLOVER 0x10 |
1245 | mask SCB_QSIZE 0x07 | 1335 | mask SCB_QSIZE 0x07 |
1246 | mask SCB_QSIZE_256 0x06 | 1336 | mask SCB_QSIZE_256 0x06 |
1337 | dont_generate_debug_code | ||
1247 | } | 1338 | } |
1248 | 1339 | ||
1249 | register DFF_THRSH { | 1340 | register DFF_THRSH { |
@@ -1267,6 +1358,7 @@ register DFF_THRSH { | |||
1267 | mask WR_DFTHRSH_90 0x60 | 1358 | mask WR_DFTHRSH_90 0x60 |
1268 | mask WR_DFTHRSH_MAX 0x70 | 1359 | mask WR_DFTHRSH_MAX 0x70 |
1269 | count 4 | 1360 | count 4 |
1361 | dont_generate_debug_code | ||
1270 | } | 1362 | } |
1271 | 1363 | ||
1272 | register SG_CACHE_PRE { | 1364 | register SG_CACHE_PRE { |
@@ -1275,6 +1367,7 @@ register SG_CACHE_PRE { | |||
1275 | mask SG_ADDR_MASK 0xf8 | 1367 | mask SG_ADDR_MASK 0xf8 |
1276 | field LAST_SEG 0x02 | 1368 | field LAST_SEG 0x02 |
1277 | field LAST_SEG_DONE 0x01 | 1369 | field LAST_SEG_DONE 0x01 |
1370 | dont_generate_debug_code | ||
1278 | } | 1371 | } |
1279 | 1372 | ||
1280 | register SG_CACHE_SHADOW { | 1373 | register SG_CACHE_SHADOW { |
@@ -1283,6 +1376,7 @@ register SG_CACHE_SHADOW { | |||
1283 | mask SG_ADDR_MASK 0xf8 | 1376 | mask SG_ADDR_MASK 0xf8 |
1284 | field LAST_SEG 0x02 | 1377 | field LAST_SEG 0x02 |
1285 | field LAST_SEG_DONE 0x01 | 1378 | field LAST_SEG_DONE 0x01 |
1379 | dont_generate_debug_code | ||
1286 | } | 1380 | } |
1287 | /* ---------------------- Scratch RAM Offsets ------------------------- */ | 1381 | /* ---------------------- Scratch RAM Offsets ------------------------- */ |
1288 | /* These offsets are either to values that are initialized by the board's | 1382 | /* These offsets are either to values that are initialized by the board's |
@@ -1309,6 +1403,7 @@ scratch_ram { | |||
1309 | BUSY_TARGETS { | 1403 | BUSY_TARGETS { |
1310 | alias TARG_SCSIRATE | 1404 | alias TARG_SCSIRATE |
1311 | size 16 | 1405 | size 16 |
1406 | dont_generate_debug_code | ||
1312 | } | 1407 | } |
1313 | /* | 1408 | /* |
1314 | * Bit vector of targets that have ULTRA enabled as set by | 1409 | * Bit vector of targets that have ULTRA enabled as set by |
@@ -1321,6 +1416,7 @@ scratch_ram { | |||
1321 | alias CMDSIZE_TABLE | 1416 | alias CMDSIZE_TABLE |
1322 | size 2 | 1417 | size 2 |
1323 | count 2 | 1418 | count 2 |
1419 | dont_generate_debug_code | ||
1324 | } | 1420 | } |
1325 | /* | 1421 | /* |
1326 | * Bit vector of targets that have disconnection disabled as set by | 1422 | * Bit vector of targets that have disconnection disabled as set by |
@@ -1331,6 +1427,7 @@ scratch_ram { | |||
1331 | DISC_DSB { | 1427 | DISC_DSB { |
1332 | size 2 | 1428 | size 2 |
1333 | count 6 | 1429 | count 6 |
1430 | dont_generate_debug_code | ||
1334 | } | 1431 | } |
1335 | CMDSIZE_TABLE_TAIL { | 1432 | CMDSIZE_TABLE_TAIL { |
1336 | size 4 | 1433 | size 4 |
@@ -1341,12 +1438,14 @@ scratch_ram { | |||
1341 | */ | 1438 | */ |
1342 | MWI_RESIDUAL { | 1439 | MWI_RESIDUAL { |
1343 | size 1 | 1440 | size 1 |
1441 | dont_generate_debug_code | ||
1344 | } | 1442 | } |
1345 | /* | 1443 | /* |
1346 | * SCBID of the next SCB to be started by the controller. | 1444 | * SCBID of the next SCB to be started by the controller. |
1347 | */ | 1445 | */ |
1348 | NEXT_QUEUED_SCB { | 1446 | NEXT_QUEUED_SCB { |
1349 | size 1 | 1447 | size 1 |
1448 | dont_generate_debug_code | ||
1350 | } | 1449 | } |
1351 | /* | 1450 | /* |
1352 | * Single byte buffer used to designate the type or message | 1451 | * Single byte buffer used to designate the type or message |
@@ -1354,6 +1453,7 @@ scratch_ram { | |||
1354 | */ | 1453 | */ |
1355 | MSG_OUT { | 1454 | MSG_OUT { |
1356 | size 1 | 1455 | size 1 |
1456 | dont_generate_debug_code | ||
1357 | } | 1457 | } |
1358 | /* Parameters for DMA Logic */ | 1458 | /* Parameters for DMA Logic */ |
1359 | DMAPARAMS { | 1459 | DMAPARAMS { |
@@ -1369,6 +1469,7 @@ scratch_ram { | |||
1369 | field DIRECTION 0x04 /* Set indicates PCI->SCSI */ | 1469 | field DIRECTION 0x04 /* Set indicates PCI->SCSI */ |
1370 | field FIFOFLUSH 0x02 | 1470 | field FIFOFLUSH 0x02 |
1371 | field FIFORESET 0x01 | 1471 | field FIFORESET 0x01 |
1472 | dont_generate_debug_code | ||
1372 | } | 1473 | } |
1373 | SEQ_FLAGS { | 1474 | SEQ_FLAGS { |
1374 | size 1 | 1475 | size 1 |
@@ -1390,9 +1491,11 @@ scratch_ram { | |||
1390 | */ | 1491 | */ |
1391 | SAVED_SCSIID { | 1492 | SAVED_SCSIID { |
1392 | size 1 | 1493 | size 1 |
1494 | dont_generate_debug_code | ||
1393 | } | 1495 | } |
1394 | SAVED_LUN { | 1496 | SAVED_LUN { |
1395 | size 1 | 1497 | size 1 |
1498 | dont_generate_debug_code | ||
1396 | } | 1499 | } |
1397 | /* | 1500 | /* |
1398 | * The last bus phase as seen by the sequencer. | 1501 | * The last bus phase as seen by the sequencer. |
@@ -1417,6 +1520,7 @@ scratch_ram { | |||
1417 | */ | 1520 | */ |
1418 | WAITING_SCBH { | 1521 | WAITING_SCBH { |
1419 | size 1 | 1522 | size 1 |
1523 | dont_generate_debug_code | ||
1420 | } | 1524 | } |
1421 | /* | 1525 | /* |
1422 | * head of list of SCBs that are | 1526 | * head of list of SCBs that are |
@@ -1425,6 +1529,7 @@ scratch_ram { | |||
1425 | */ | 1529 | */ |
1426 | DISCONNECTED_SCBH { | 1530 | DISCONNECTED_SCBH { |
1427 | size 1 | 1531 | size 1 |
1532 | dont_generate_debug_code | ||
1428 | } | 1533 | } |
1429 | /* | 1534 | /* |
1430 | * head of list of SCBs that are | 1535 | * head of list of SCBs that are |
@@ -1432,6 +1537,7 @@ scratch_ram { | |||
1432 | */ | 1537 | */ |
1433 | FREE_SCBH { | 1538 | FREE_SCBH { |
1434 | size 1 | 1539 | size 1 |
1540 | dont_generate_debug_code | ||
1435 | } | 1541 | } |
1436 | /* | 1542 | /* |
1437 | * head of list of SCBs that have | 1543 | * head of list of SCBs that have |
@@ -1446,6 +1552,7 @@ scratch_ram { | |||
1446 | */ | 1552 | */ |
1447 | HSCB_ADDR { | 1553 | HSCB_ADDR { |
1448 | size 4 | 1554 | size 4 |
1555 | dont_generate_debug_code | ||
1449 | } | 1556 | } |
1450 | /* | 1557 | /* |
1451 | * Base address of our shared data with the kernel driver in host | 1558 | * Base address of our shared data with the kernel driver in host |
@@ -1454,15 +1561,19 @@ scratch_ram { | |||
1454 | */ | 1561 | */ |
1455 | SHARED_DATA_ADDR { | 1562 | SHARED_DATA_ADDR { |
1456 | size 4 | 1563 | size 4 |
1564 | dont_generate_debug_code | ||
1457 | } | 1565 | } |
1458 | KERNEL_QINPOS { | 1566 | KERNEL_QINPOS { |
1459 | size 1 | 1567 | size 1 |
1568 | dont_generate_debug_code | ||
1460 | } | 1569 | } |
1461 | QINPOS { | 1570 | QINPOS { |
1462 | size 1 | 1571 | size 1 |
1572 | dont_generate_debug_code | ||
1463 | } | 1573 | } |
1464 | QOUTPOS { | 1574 | QOUTPOS { |
1465 | size 1 | 1575 | size 1 |
1576 | dont_generate_debug_code | ||
1466 | } | 1577 | } |
1467 | /* | 1578 | /* |
1468 | * Kernel and sequencer offsets into the queue of | 1579 | * Kernel and sequencer offsets into the queue of |
@@ -1471,9 +1582,11 @@ scratch_ram { | |||
1471 | */ | 1582 | */ |
1472 | KERNEL_TQINPOS { | 1583 | KERNEL_TQINPOS { |
1473 | size 1 | 1584 | size 1 |
1585 | dont_generate_debug_code | ||
1474 | } | 1586 | } |
1475 | TQINPOS { | 1587 | TQINPOS { |
1476 | size 1 | 1588 | size 1 |
1589 | dont_generate_debug_code | ||
1477 | } | 1590 | } |
1478 | ARG_1 { | 1591 | ARG_1 { |
1479 | size 1 | 1592 | size 1 |
@@ -1486,10 +1599,12 @@ scratch_ram { | |||
1486 | mask CONT_MSG_LOOP 0x04 | 1599 | mask CONT_MSG_LOOP 0x04 |
1487 | mask CONT_TARG_SESSION 0x02 | 1600 | mask CONT_TARG_SESSION 0x02 |
1488 | alias RETURN_1 | 1601 | alias RETURN_1 |
1602 | dont_generate_debug_code | ||
1489 | } | 1603 | } |
1490 | ARG_2 { | 1604 | ARG_2 { |
1491 | size 1 | 1605 | size 1 |
1492 | alias RETURN_2 | 1606 | alias RETURN_2 |
1607 | dont_generate_debug_code | ||
1493 | } | 1608 | } |
1494 | 1609 | ||
1495 | /* | 1610 | /* |
@@ -1498,6 +1613,7 @@ scratch_ram { | |||
1498 | LAST_MSG { | 1613 | LAST_MSG { |
1499 | size 1 | 1614 | size 1 |
1500 | alias TARG_IMMEDIATE_SCB | 1615 | alias TARG_IMMEDIATE_SCB |
1616 | dont_generate_debug_code | ||
1501 | } | 1617 | } |
1502 | 1618 | ||
1503 | /* | 1619 | /* |
@@ -1513,6 +1629,7 @@ scratch_ram { | |||
1513 | field ENAUTOATNO 0x08 | 1629 | field ENAUTOATNO 0x08 |
1514 | field ENAUTOATNI 0x04 | 1630 | field ENAUTOATNI 0x04 |
1515 | field ENAUTOATNP 0x02 | 1631 | field ENAUTOATNP 0x02 |
1632 | dont_generate_debug_code | ||
1516 | } | 1633 | } |
1517 | } | 1634 | } |
1518 | 1635 | ||
@@ -1533,12 +1650,14 @@ scratch_ram { | |||
1533 | field HA_274_EXTENDED_TRANS 0x01 | 1650 | field HA_274_EXTENDED_TRANS 0x01 |
1534 | alias INITIATOR_TAG | 1651 | alias INITIATOR_TAG |
1535 | count 1 | 1652 | count 1 |
1653 | dont_generate_debug_code | ||
1536 | } | 1654 | } |
1537 | 1655 | ||
1538 | SEQ_FLAGS2 { | 1656 | SEQ_FLAGS2 { |
1539 | size 1 | 1657 | size 1 |
1540 | field SCB_DMA 0x01 | 1658 | field SCB_DMA 0x01 |
1541 | field TARGET_MSG_PENDING 0x02 | 1659 | field TARGET_MSG_PENDING 0x02 |
1660 | dont_generate_debug_code | ||
1542 | } | 1661 | } |
1543 | } | 1662 | } |
1544 | 1663 | ||
@@ -1562,6 +1681,7 @@ scratch_ram { | |||
1562 | field ENSPCHK 0x20 | 1681 | field ENSPCHK 0x20 |
1563 | mask HSCSIID 0x07 /* our SCSI ID */ | 1682 | mask HSCSIID 0x07 /* our SCSI ID */ |
1564 | mask HWSCSIID 0x0f /* our SCSI ID if Wide Bus */ | 1683 | mask HWSCSIID 0x0f /* our SCSI ID if Wide Bus */ |
1684 | dont_generate_debug_code | ||
1565 | } | 1685 | } |
1566 | INTDEF { | 1686 | INTDEF { |
1567 | address 0x05c | 1687 | address 0x05c |
@@ -1569,11 +1689,13 @@ scratch_ram { | |||
1569 | count 1 | 1689 | count 1 |
1570 | field EDGE_TRIG 0x80 | 1690 | field EDGE_TRIG 0x80 |
1571 | mask VECTOR 0x0f | 1691 | mask VECTOR 0x0f |
1692 | dont_generate_debug_code | ||
1572 | } | 1693 | } |
1573 | HOSTCONF { | 1694 | HOSTCONF { |
1574 | address 0x05d | 1695 | address 0x05d |
1575 | size 1 | 1696 | size 1 |
1576 | count 1 | 1697 | count 1 |
1698 | dont_generate_debug_code | ||
1577 | } | 1699 | } |
1578 | HA_274_BIOSCTRL { | 1700 | HA_274_BIOSCTRL { |
1579 | address 0x05f | 1701 | address 0x05f |
@@ -1582,6 +1704,7 @@ scratch_ram { | |||
1582 | mask BIOSMODE 0x30 | 1704 | mask BIOSMODE 0x30 |
1583 | mask BIOSDISABLED 0x30 | 1705 | mask BIOSDISABLED 0x30 |
1584 | field CHANNEL_B_PRIMARY 0x08 | 1706 | field CHANNEL_B_PRIMARY 0x08 |
1707 | dont_generate_debug_code | ||
1585 | } | 1708 | } |
1586 | } | 1709 | } |
1587 | 1710 | ||
@@ -1595,6 +1718,7 @@ scratch_ram { | |||
1595 | TARG_OFFSET { | 1718 | TARG_OFFSET { |
1596 | size 16 | 1719 | size 16 |
1597 | count 1 | 1720 | count 1 |
1721 | dont_generate_debug_code | ||
1598 | } | 1722 | } |
1599 | } | 1723 | } |
1600 | 1724 | ||
diff --git a/drivers/scsi/aic7xxx/aic7xxx_core.c b/drivers/scsi/aic7xxx/aic7xxx_core.c index 0ae2b4605d09..e6f2bb7365e6 100644 --- a/drivers/scsi/aic7xxx/aic7xxx_core.c +++ b/drivers/scsi/aic7xxx/aic7xxx_core.c | |||
@@ -814,6 +814,7 @@ ahc_intr(struct ahc_softc *ahc) | |||
814 | static void | 814 | static void |
815 | ahc_restart(struct ahc_softc *ahc) | 815 | ahc_restart(struct ahc_softc *ahc) |
816 | { | 816 | { |
817 | uint8_t sblkctl; | ||
817 | 818 | ||
818 | ahc_pause(ahc); | 819 | ahc_pause(ahc); |
819 | 820 | ||
@@ -868,6 +869,12 @@ ahc_restart(struct ahc_softc *ahc) | |||
868 | ahc_outb(ahc, SEQADDR0, 0); | 869 | ahc_outb(ahc, SEQADDR0, 0); |
869 | ahc_outb(ahc, SEQADDR1, 0); | 870 | ahc_outb(ahc, SEQADDR1, 0); |
870 | 871 | ||
872 | /* | ||
873 | * Take the LED out of diagnostic mode on PM resume, too | ||
874 | */ | ||
875 | sblkctl = ahc_inb(ahc, SBLKCTL); | ||
876 | ahc_outb(ahc, SBLKCTL, (sblkctl & ~(DIAGLEDEN|DIAGLEDON))); | ||
877 | |||
871 | ahc_unpause(ahc); | 878 | ahc_unpause(ahc); |
872 | } | 879 | } |
873 | 880 | ||
diff --git a/drivers/scsi/aic7xxx/aic7xxx_reg.h_shipped b/drivers/scsi/aic7xxx/aic7xxx_reg.h_shipped index 2ce1febca207..e821082a4f47 100644 --- a/drivers/scsi/aic7xxx/aic7xxx_reg.h_shipped +++ b/drivers/scsi/aic7xxx/aic7xxx_reg.h_shipped | |||
@@ -27,20 +27,6 @@ ahc_reg_print_t ahc_sxfrctl0_print; | |||
27 | #endif | 27 | #endif |
28 | 28 | ||
29 | #if AIC_DEBUG_REGISTERS | 29 | #if AIC_DEBUG_REGISTERS |
30 | ahc_reg_print_t ahc_sxfrctl1_print; | ||
31 | #else | ||
32 | #define ahc_sxfrctl1_print(regvalue, cur_col, wrap) \ | ||
33 | ahc_print_register(NULL, 0, "SXFRCTL1", 0x02, regvalue, cur_col, wrap) | ||
34 | #endif | ||
35 | |||
36 | #if AIC_DEBUG_REGISTERS | ||
37 | ahc_reg_print_t ahc_scsisigo_print; | ||
38 | #else | ||
39 | #define ahc_scsisigo_print(regvalue, cur_col, wrap) \ | ||
40 | ahc_print_register(NULL, 0, "SCSISIGO", 0x03, regvalue, cur_col, wrap) | ||
41 | #endif | ||
42 | |||
43 | #if AIC_DEBUG_REGISTERS | ||
44 | ahc_reg_print_t ahc_scsisigi_print; | 30 | ahc_reg_print_t ahc_scsisigi_print; |
45 | #else | 31 | #else |
46 | #define ahc_scsisigi_print(regvalue, cur_col, wrap) \ | 32 | #define ahc_scsisigi_print(regvalue, cur_col, wrap) \ |
@@ -55,55 +41,6 @@ ahc_reg_print_t ahc_scsirate_print; | |||
55 | #endif | 41 | #endif |
56 | 42 | ||
57 | #if AIC_DEBUG_REGISTERS | 43 | #if AIC_DEBUG_REGISTERS |
58 | ahc_reg_print_t ahc_scsiid_print; | ||
59 | #else | ||
60 | #define ahc_scsiid_print(regvalue, cur_col, wrap) \ | ||
61 | ahc_print_register(NULL, 0, "SCSIID", 0x05, regvalue, cur_col, wrap) | ||
62 | #endif | ||
63 | |||
64 | #if AIC_DEBUG_REGISTERS | ||
65 | ahc_reg_print_t ahc_scsidatl_print; | ||
66 | #else | ||
67 | #define ahc_scsidatl_print(regvalue, cur_col, wrap) \ | ||
68 | ahc_print_register(NULL, 0, "SCSIDATL", 0x06, regvalue, cur_col, wrap) | ||
69 | #endif | ||
70 | |||
71 | #if AIC_DEBUG_REGISTERS | ||
72 | ahc_reg_print_t ahc_scsidath_print; | ||
73 | #else | ||
74 | #define ahc_scsidath_print(regvalue, cur_col, wrap) \ | ||
75 | ahc_print_register(NULL, 0, "SCSIDATH", 0x07, regvalue, cur_col, wrap) | ||
76 | #endif | ||
77 | |||
78 | #if AIC_DEBUG_REGISTERS | ||
79 | ahc_reg_print_t ahc_stcnt_print; | ||
80 | #else | ||
81 | #define ahc_stcnt_print(regvalue, cur_col, wrap) \ | ||
82 | ahc_print_register(NULL, 0, "STCNT", 0x08, regvalue, cur_col, wrap) | ||
83 | #endif | ||
84 | |||
85 | #if AIC_DEBUG_REGISTERS | ||
86 | ahc_reg_print_t ahc_optionmode_print; | ||
87 | #else | ||
88 | #define ahc_optionmode_print(regvalue, cur_col, wrap) \ | ||
89 | ahc_print_register(NULL, 0, "OPTIONMODE", 0x08, regvalue, cur_col, wrap) | ||
90 | #endif | ||
91 | |||
92 | #if AIC_DEBUG_REGISTERS | ||
93 | ahc_reg_print_t ahc_targcrccnt_print; | ||
94 | #else | ||
95 | #define ahc_targcrccnt_print(regvalue, cur_col, wrap) \ | ||
96 | ahc_print_register(NULL, 0, "TARGCRCCNT", 0x0a, regvalue, cur_col, wrap) | ||
97 | #endif | ||
98 | |||
99 | #if AIC_DEBUG_REGISTERS | ||
100 | ahc_reg_print_t ahc_clrsint0_print; | ||
101 | #else | ||
102 | #define ahc_clrsint0_print(regvalue, cur_col, wrap) \ | ||
103 | ahc_print_register(NULL, 0, "CLRSINT0", 0x0b, regvalue, cur_col, wrap) | ||
104 | #endif | ||
105 | |||
106 | #if AIC_DEBUG_REGISTERS | ||
107 | ahc_reg_print_t ahc_sstat0_print; | 44 | ahc_reg_print_t ahc_sstat0_print; |
108 | #else | 45 | #else |
109 | #define ahc_sstat0_print(regvalue, cur_col, wrap) \ | 46 | #define ahc_sstat0_print(regvalue, cur_col, wrap) \ |
@@ -111,13 +48,6 @@ ahc_reg_print_t ahc_sstat0_print; | |||
111 | #endif | 48 | #endif |
112 | 49 | ||
113 | #if AIC_DEBUG_REGISTERS | 50 | #if AIC_DEBUG_REGISTERS |
114 | ahc_reg_print_t ahc_clrsint1_print; | ||
115 | #else | ||
116 | #define ahc_clrsint1_print(regvalue, cur_col, wrap) \ | ||
117 | ahc_print_register(NULL, 0, "CLRSINT1", 0x0c, regvalue, cur_col, wrap) | ||
118 | #endif | ||
119 | |||
120 | #if AIC_DEBUG_REGISTERS | ||
121 | ahc_reg_print_t ahc_sstat1_print; | 51 | ahc_reg_print_t ahc_sstat1_print; |
122 | #else | 52 | #else |
123 | #define ahc_sstat1_print(regvalue, cur_col, wrap) \ | 53 | #define ahc_sstat1_print(regvalue, cur_col, wrap) \ |
@@ -139,13 +69,6 @@ ahc_reg_print_t ahc_sstat3_print; | |||
139 | #endif | 69 | #endif |
140 | 70 | ||
141 | #if AIC_DEBUG_REGISTERS | 71 | #if AIC_DEBUG_REGISTERS |
142 | ahc_reg_print_t ahc_scsiid_ultra2_print; | ||
143 | #else | ||
144 | #define ahc_scsiid_ultra2_print(regvalue, cur_col, wrap) \ | ||
145 | ahc_print_register(NULL, 0, "SCSIID_ULTRA2", 0x0f, regvalue, cur_col, wrap) | ||
146 | #endif | ||
147 | |||
148 | #if AIC_DEBUG_REGISTERS | ||
149 | ahc_reg_print_t ahc_simode0_print; | 72 | ahc_reg_print_t ahc_simode0_print; |
150 | #else | 73 | #else |
151 | #define ahc_simode0_print(regvalue, cur_col, wrap) \ | 74 | #define ahc_simode0_print(regvalue, cur_col, wrap) \ |
@@ -167,76 +90,6 @@ ahc_reg_print_t ahc_scsibusl_print; | |||
167 | #endif | 90 | #endif |
168 | 91 | ||
169 | #if AIC_DEBUG_REGISTERS | 92 | #if AIC_DEBUG_REGISTERS |
170 | ahc_reg_print_t ahc_scsibush_print; | ||
171 | #else | ||
172 | #define ahc_scsibush_print(regvalue, cur_col, wrap) \ | ||
173 | ahc_print_register(NULL, 0, "SCSIBUSH", 0x13, regvalue, cur_col, wrap) | ||
174 | #endif | ||
175 | |||
176 | #if AIC_DEBUG_REGISTERS | ||
177 | ahc_reg_print_t ahc_sxfrctl2_print; | ||
178 | #else | ||
179 | #define ahc_sxfrctl2_print(regvalue, cur_col, wrap) \ | ||
180 | ahc_print_register(NULL, 0, "SXFRCTL2", 0x13, regvalue, cur_col, wrap) | ||
181 | #endif | ||
182 | |||
183 | #if AIC_DEBUG_REGISTERS | ||
184 | ahc_reg_print_t ahc_shaddr_print; | ||
185 | #else | ||
186 | #define ahc_shaddr_print(regvalue, cur_col, wrap) \ | ||
187 | ahc_print_register(NULL, 0, "SHADDR", 0x14, regvalue, cur_col, wrap) | ||
188 | #endif | ||
189 | |||
190 | #if AIC_DEBUG_REGISTERS | ||
191 | ahc_reg_print_t ahc_seltimer_print; | ||
192 | #else | ||
193 | #define ahc_seltimer_print(regvalue, cur_col, wrap) \ | ||
194 | ahc_print_register(NULL, 0, "SELTIMER", 0x18, regvalue, cur_col, wrap) | ||
195 | #endif | ||
196 | |||
197 | #if AIC_DEBUG_REGISTERS | ||
198 | ahc_reg_print_t ahc_selid_print; | ||
199 | #else | ||
200 | #define ahc_selid_print(regvalue, cur_col, wrap) \ | ||
201 | ahc_print_register(NULL, 0, "SELID", 0x19, regvalue, cur_col, wrap) | ||
202 | #endif | ||
203 | |||
204 | #if AIC_DEBUG_REGISTERS | ||
205 | ahc_reg_print_t ahc_scamctl_print; | ||
206 | #else | ||
207 | #define ahc_scamctl_print(regvalue, cur_col, wrap) \ | ||
208 | ahc_print_register(NULL, 0, "SCAMCTL", 0x1a, regvalue, cur_col, wrap) | ||
209 | #endif | ||
210 | |||
211 | #if AIC_DEBUG_REGISTERS | ||
212 | ahc_reg_print_t ahc_targid_print; | ||
213 | #else | ||
214 | #define ahc_targid_print(regvalue, cur_col, wrap) \ | ||
215 | ahc_print_register(NULL, 0, "TARGID", 0x1b, regvalue, cur_col, wrap) | ||
216 | #endif | ||
217 | |||
218 | #if AIC_DEBUG_REGISTERS | ||
219 | ahc_reg_print_t ahc_spiocap_print; | ||
220 | #else | ||
221 | #define ahc_spiocap_print(regvalue, cur_col, wrap) \ | ||
222 | ahc_print_register(NULL, 0, "SPIOCAP", 0x1b, regvalue, cur_col, wrap) | ||
223 | #endif | ||
224 | |||
225 | #if AIC_DEBUG_REGISTERS | ||
226 | ahc_reg_print_t ahc_brdctl_print; | ||
227 | #else | ||
228 | #define ahc_brdctl_print(regvalue, cur_col, wrap) \ | ||
229 | ahc_print_register(NULL, 0, "BRDCTL", 0x1d, regvalue, cur_col, wrap) | ||
230 | #endif | ||
231 | |||
232 | #if AIC_DEBUG_REGISTERS | ||
233 | ahc_reg_print_t ahc_seectl_print; | ||
234 | #else | ||
235 | #define ahc_seectl_print(regvalue, cur_col, wrap) \ | ||
236 | ahc_print_register(NULL, 0, "SEECTL", 0x1e, regvalue, cur_col, wrap) | ||
237 | #endif | ||
238 | |||
239 | #if AIC_DEBUG_REGISTERS | ||
240 | ahc_reg_print_t ahc_sblkctl_print; | 93 | ahc_reg_print_t ahc_sblkctl_print; |
241 | #else | 94 | #else |
242 | #define ahc_sblkctl_print(regvalue, cur_col, wrap) \ | 95 | #define ahc_sblkctl_print(regvalue, cur_col, wrap) \ |
@@ -244,62 +97,6 @@ ahc_reg_print_t ahc_sblkctl_print; | |||
244 | #endif | 97 | #endif |
245 | 98 | ||
246 | #if AIC_DEBUG_REGISTERS | 99 | #if AIC_DEBUG_REGISTERS |
247 | ahc_reg_print_t ahc_busy_targets_print; | ||
248 | #else | ||
249 | #define ahc_busy_targets_print(regvalue, cur_col, wrap) \ | ||
250 | ahc_print_register(NULL, 0, "BUSY_TARGETS", 0x20, regvalue, cur_col, wrap) | ||
251 | #endif | ||
252 | |||
253 | #if AIC_DEBUG_REGISTERS | ||
254 | ahc_reg_print_t ahc_ultra_enb_print; | ||
255 | #else | ||
256 | #define ahc_ultra_enb_print(regvalue, cur_col, wrap) \ | ||
257 | ahc_print_register(NULL, 0, "ULTRA_ENB", 0x30, regvalue, cur_col, wrap) | ||
258 | #endif | ||
259 | |||
260 | #if AIC_DEBUG_REGISTERS | ||
261 | ahc_reg_print_t ahc_disc_dsb_print; | ||
262 | #else | ||
263 | #define ahc_disc_dsb_print(regvalue, cur_col, wrap) \ | ||
264 | ahc_print_register(NULL, 0, "DISC_DSB", 0x32, regvalue, cur_col, wrap) | ||
265 | #endif | ||
266 | |||
267 | #if AIC_DEBUG_REGISTERS | ||
268 | ahc_reg_print_t ahc_cmdsize_table_tail_print; | ||
269 | #else | ||
270 | #define ahc_cmdsize_table_tail_print(regvalue, cur_col, wrap) \ | ||
271 | ahc_print_register(NULL, 0, "CMDSIZE_TABLE_TAIL", 0x34, regvalue, cur_col, wrap) | ||
272 | #endif | ||
273 | |||
274 | #if AIC_DEBUG_REGISTERS | ||
275 | ahc_reg_print_t ahc_mwi_residual_print; | ||
276 | #else | ||
277 | #define ahc_mwi_residual_print(regvalue, cur_col, wrap) \ | ||
278 | ahc_print_register(NULL, 0, "MWI_RESIDUAL", 0x38, regvalue, cur_col, wrap) | ||
279 | #endif | ||
280 | |||
281 | #if AIC_DEBUG_REGISTERS | ||
282 | ahc_reg_print_t ahc_next_queued_scb_print; | ||
283 | #else | ||
284 | #define ahc_next_queued_scb_print(regvalue, cur_col, wrap) \ | ||
285 | ahc_print_register(NULL, 0, "NEXT_QUEUED_SCB", 0x39, regvalue, cur_col, wrap) | ||
286 | #endif | ||
287 | |||
288 | #if AIC_DEBUG_REGISTERS | ||
289 | ahc_reg_print_t ahc_msg_out_print; | ||
290 | #else | ||
291 | #define ahc_msg_out_print(regvalue, cur_col, wrap) \ | ||
292 | ahc_print_register(NULL, 0, "MSG_OUT", 0x3a, regvalue, cur_col, wrap) | ||
293 | #endif | ||
294 | |||
295 | #if AIC_DEBUG_REGISTERS | ||
296 | ahc_reg_print_t ahc_dmaparams_print; | ||
297 | #else | ||
298 | #define ahc_dmaparams_print(regvalue, cur_col, wrap) \ | ||
299 | ahc_print_register(NULL, 0, "DMAPARAMS", 0x3b, regvalue, cur_col, wrap) | ||
300 | #endif | ||
301 | |||
302 | #if AIC_DEBUG_REGISTERS | ||
303 | ahc_reg_print_t ahc_seq_flags_print; | 100 | ahc_reg_print_t ahc_seq_flags_print; |
304 | #else | 101 | #else |
305 | #define ahc_seq_flags_print(regvalue, cur_col, wrap) \ | 102 | #define ahc_seq_flags_print(regvalue, cur_col, wrap) \ |
@@ -307,20 +104,6 @@ ahc_reg_print_t ahc_seq_flags_print; | |||
307 | #endif | 104 | #endif |
308 | 105 | ||
309 | #if AIC_DEBUG_REGISTERS | 106 | #if AIC_DEBUG_REGISTERS |
310 | ahc_reg_print_t ahc_saved_scsiid_print; | ||
311 | #else | ||
312 | #define ahc_saved_scsiid_print(regvalue, cur_col, wrap) \ | ||
313 | ahc_print_register(NULL, 0, "SAVED_SCSIID", 0x3d, regvalue, cur_col, wrap) | ||
314 | #endif | ||
315 | |||
316 | #if AIC_DEBUG_REGISTERS | ||
317 | ahc_reg_print_t ahc_saved_lun_print; | ||
318 | #else | ||
319 | #define ahc_saved_lun_print(regvalue, cur_col, wrap) \ | ||
320 | ahc_print_register(NULL, 0, "SAVED_LUN", 0x3e, regvalue, cur_col, wrap) | ||
321 | #endif | ||
322 | |||
323 | #if AIC_DEBUG_REGISTERS | ||
324 | ahc_reg_print_t ahc_lastphase_print; | 107 | ahc_reg_print_t ahc_lastphase_print; |
325 | #else | 108 | #else |
326 | #define ahc_lastphase_print(regvalue, cur_col, wrap) \ | 109 | #define ahc_lastphase_print(regvalue, cur_col, wrap) \ |
@@ -328,153 +111,6 @@ ahc_reg_print_t ahc_lastphase_print; | |||
328 | #endif | 111 | #endif |
329 | 112 | ||
330 | #if AIC_DEBUG_REGISTERS | 113 | #if AIC_DEBUG_REGISTERS |
331 | ahc_reg_print_t ahc_waiting_scbh_print; | ||
332 | #else | ||
333 | #define ahc_waiting_scbh_print(regvalue, cur_col, wrap) \ | ||
334 | ahc_print_register(NULL, 0, "WAITING_SCBH", 0x40, regvalue, cur_col, wrap) | ||
335 | #endif | ||
336 | |||
337 | #if AIC_DEBUG_REGISTERS | ||
338 | ahc_reg_print_t ahc_disconnected_scbh_print; | ||
339 | #else | ||
340 | #define ahc_disconnected_scbh_print(regvalue, cur_col, wrap) \ | ||
341 | ahc_print_register(NULL, 0, "DISCONNECTED_SCBH", 0x41, regvalue, cur_col, wrap) | ||
342 | #endif | ||
343 | |||
344 | #if AIC_DEBUG_REGISTERS | ||
345 | ahc_reg_print_t ahc_free_scbh_print; | ||
346 | #else | ||
347 | #define ahc_free_scbh_print(regvalue, cur_col, wrap) \ | ||
348 | ahc_print_register(NULL, 0, "FREE_SCBH", 0x42, regvalue, cur_col, wrap) | ||
349 | #endif | ||
350 | |||
351 | #if AIC_DEBUG_REGISTERS | ||
352 | ahc_reg_print_t ahc_complete_scbh_print; | ||
353 | #else | ||
354 | #define ahc_complete_scbh_print(regvalue, cur_col, wrap) \ | ||
355 | ahc_print_register(NULL, 0, "COMPLETE_SCBH", 0x43, regvalue, cur_col, wrap) | ||
356 | #endif | ||
357 | |||
358 | #if AIC_DEBUG_REGISTERS | ||
359 | ahc_reg_print_t ahc_hscb_addr_print; | ||
360 | #else | ||
361 | #define ahc_hscb_addr_print(regvalue, cur_col, wrap) \ | ||
362 | ahc_print_register(NULL, 0, "HSCB_ADDR", 0x44, regvalue, cur_col, wrap) | ||
363 | #endif | ||
364 | |||
365 | #if AIC_DEBUG_REGISTERS | ||
366 | ahc_reg_print_t ahc_shared_data_addr_print; | ||
367 | #else | ||
368 | #define ahc_shared_data_addr_print(regvalue, cur_col, wrap) \ | ||
369 | ahc_print_register(NULL, 0, "SHARED_DATA_ADDR", 0x48, regvalue, cur_col, wrap) | ||
370 | #endif | ||
371 | |||
372 | #if AIC_DEBUG_REGISTERS | ||
373 | ahc_reg_print_t ahc_kernel_qinpos_print; | ||
374 | #else | ||
375 | #define ahc_kernel_qinpos_print(regvalue, cur_col, wrap) \ | ||
376 | ahc_print_register(NULL, 0, "KERNEL_QINPOS", 0x4c, regvalue, cur_col, wrap) | ||
377 | #endif | ||
378 | |||
379 | #if AIC_DEBUG_REGISTERS | ||
380 | ahc_reg_print_t ahc_qinpos_print; | ||
381 | #else | ||
382 | #define ahc_qinpos_print(regvalue, cur_col, wrap) \ | ||
383 | ahc_print_register(NULL, 0, "QINPOS", 0x4d, regvalue, cur_col, wrap) | ||
384 | #endif | ||
385 | |||
386 | #if AIC_DEBUG_REGISTERS | ||
387 | ahc_reg_print_t ahc_qoutpos_print; | ||
388 | #else | ||
389 | #define ahc_qoutpos_print(regvalue, cur_col, wrap) \ | ||
390 | ahc_print_register(NULL, 0, "QOUTPOS", 0x4e, regvalue, cur_col, wrap) | ||
391 | #endif | ||
392 | |||
393 | #if AIC_DEBUG_REGISTERS | ||
394 | ahc_reg_print_t ahc_kernel_tqinpos_print; | ||
395 | #else | ||
396 | #define ahc_kernel_tqinpos_print(regvalue, cur_col, wrap) \ | ||
397 | ahc_print_register(NULL, 0, "KERNEL_TQINPOS", 0x4f, regvalue, cur_col, wrap) | ||
398 | #endif | ||
399 | |||
400 | #if AIC_DEBUG_REGISTERS | ||
401 | ahc_reg_print_t ahc_tqinpos_print; | ||
402 | #else | ||
403 | #define ahc_tqinpos_print(regvalue, cur_col, wrap) \ | ||
404 | ahc_print_register(NULL, 0, "TQINPOS", 0x50, regvalue, cur_col, wrap) | ||
405 | #endif | ||
406 | |||
407 | #if AIC_DEBUG_REGISTERS | ||
408 | ahc_reg_print_t ahc_arg_1_print; | ||
409 | #else | ||
410 | #define ahc_arg_1_print(regvalue, cur_col, wrap) \ | ||
411 | ahc_print_register(NULL, 0, "ARG_1", 0x51, regvalue, cur_col, wrap) | ||
412 | #endif | ||
413 | |||
414 | #if AIC_DEBUG_REGISTERS | ||
415 | ahc_reg_print_t ahc_arg_2_print; | ||
416 | #else | ||
417 | #define ahc_arg_2_print(regvalue, cur_col, wrap) \ | ||
418 | ahc_print_register(NULL, 0, "ARG_2", 0x52, regvalue, cur_col, wrap) | ||
419 | #endif | ||
420 | |||
421 | #if AIC_DEBUG_REGISTERS | ||
422 | ahc_reg_print_t ahc_last_msg_print; | ||
423 | #else | ||
424 | #define ahc_last_msg_print(regvalue, cur_col, wrap) \ | ||
425 | ahc_print_register(NULL, 0, "LAST_MSG", 0x53, regvalue, cur_col, wrap) | ||
426 | #endif | ||
427 | |||
428 | #if AIC_DEBUG_REGISTERS | ||
429 | ahc_reg_print_t ahc_scsiseq_template_print; | ||
430 | #else | ||
431 | #define ahc_scsiseq_template_print(regvalue, cur_col, wrap) \ | ||
432 | ahc_print_register(NULL, 0, "SCSISEQ_TEMPLATE", 0x54, regvalue, cur_col, wrap) | ||
433 | #endif | ||
434 | |||
435 | #if AIC_DEBUG_REGISTERS | ||
436 | ahc_reg_print_t ahc_ha_274_biosglobal_print; | ||
437 | #else | ||
438 | #define ahc_ha_274_biosglobal_print(regvalue, cur_col, wrap) \ | ||
439 | ahc_print_register(NULL, 0, "HA_274_BIOSGLOBAL", 0x56, regvalue, cur_col, wrap) | ||
440 | #endif | ||
441 | |||
442 | #if AIC_DEBUG_REGISTERS | ||
443 | ahc_reg_print_t ahc_seq_flags2_print; | ||
444 | #else | ||
445 | #define ahc_seq_flags2_print(regvalue, cur_col, wrap) \ | ||
446 | ahc_print_register(NULL, 0, "SEQ_FLAGS2", 0x57, regvalue, cur_col, wrap) | ||
447 | #endif | ||
448 | |||
449 | #if AIC_DEBUG_REGISTERS | ||
450 | ahc_reg_print_t ahc_scsiconf_print; | ||
451 | #else | ||
452 | #define ahc_scsiconf_print(regvalue, cur_col, wrap) \ | ||
453 | ahc_print_register(NULL, 0, "SCSICONF", 0x5a, regvalue, cur_col, wrap) | ||
454 | #endif | ||
455 | |||
456 | #if AIC_DEBUG_REGISTERS | ||
457 | ahc_reg_print_t ahc_intdef_print; | ||
458 | #else | ||
459 | #define ahc_intdef_print(regvalue, cur_col, wrap) \ | ||
460 | ahc_print_register(NULL, 0, "INTDEF", 0x5c, regvalue, cur_col, wrap) | ||
461 | #endif | ||
462 | |||
463 | #if AIC_DEBUG_REGISTERS | ||
464 | ahc_reg_print_t ahc_hostconf_print; | ||
465 | #else | ||
466 | #define ahc_hostconf_print(regvalue, cur_col, wrap) \ | ||
467 | ahc_print_register(NULL, 0, "HOSTCONF", 0x5d, regvalue, cur_col, wrap) | ||
468 | #endif | ||
469 | |||
470 | #if AIC_DEBUG_REGISTERS | ||
471 | ahc_reg_print_t ahc_ha_274_biosctrl_print; | ||
472 | #else | ||
473 | #define ahc_ha_274_biosctrl_print(regvalue, cur_col, wrap) \ | ||
474 | ahc_print_register(NULL, 0, "HA_274_BIOSCTRL", 0x5f, regvalue, cur_col, wrap) | ||
475 | #endif | ||
476 | |||
477 | #if AIC_DEBUG_REGISTERS | ||
478 | ahc_reg_print_t ahc_seqctl_print; | 114 | ahc_reg_print_t ahc_seqctl_print; |
479 | #else | 115 | #else |
480 | #define ahc_seqctl_print(regvalue, cur_col, wrap) \ | 116 | #define ahc_seqctl_print(regvalue, cur_col, wrap) \ |
@@ -482,111 +118,6 @@ ahc_reg_print_t ahc_seqctl_print; | |||
482 | #endif | 118 | #endif |
483 | 119 | ||
484 | #if AIC_DEBUG_REGISTERS | 120 | #if AIC_DEBUG_REGISTERS |
485 | ahc_reg_print_t ahc_seqram_print; | ||
486 | #else | ||
487 | #define ahc_seqram_print(regvalue, cur_col, wrap) \ | ||
488 | ahc_print_register(NULL, 0, "SEQRAM", 0x61, regvalue, cur_col, wrap) | ||
489 | #endif | ||
490 | |||
491 | #if AIC_DEBUG_REGISTERS | ||
492 | ahc_reg_print_t ahc_seqaddr0_print; | ||
493 | #else | ||
494 | #define ahc_seqaddr0_print(regvalue, cur_col, wrap) \ | ||
495 | ahc_print_register(NULL, 0, "SEQADDR0", 0x62, regvalue, cur_col, wrap) | ||
496 | #endif | ||
497 | |||
498 | #if AIC_DEBUG_REGISTERS | ||
499 | ahc_reg_print_t ahc_seqaddr1_print; | ||
500 | #else | ||
501 | #define ahc_seqaddr1_print(regvalue, cur_col, wrap) \ | ||
502 | ahc_print_register(NULL, 0, "SEQADDR1", 0x63, regvalue, cur_col, wrap) | ||
503 | #endif | ||
504 | |||
505 | #if AIC_DEBUG_REGISTERS | ||
506 | ahc_reg_print_t ahc_accum_print; | ||
507 | #else | ||
508 | #define ahc_accum_print(regvalue, cur_col, wrap) \ | ||
509 | ahc_print_register(NULL, 0, "ACCUM", 0x64, regvalue, cur_col, wrap) | ||
510 | #endif | ||
511 | |||
512 | #if AIC_DEBUG_REGISTERS | ||
513 | ahc_reg_print_t ahc_sindex_print; | ||
514 | #else | ||
515 | #define ahc_sindex_print(regvalue, cur_col, wrap) \ | ||
516 | ahc_print_register(NULL, 0, "SINDEX", 0x65, regvalue, cur_col, wrap) | ||
517 | #endif | ||
518 | |||
519 | #if AIC_DEBUG_REGISTERS | ||
520 | ahc_reg_print_t ahc_dindex_print; | ||
521 | #else | ||
522 | #define ahc_dindex_print(regvalue, cur_col, wrap) \ | ||
523 | ahc_print_register(NULL, 0, "DINDEX", 0x66, regvalue, cur_col, wrap) | ||
524 | #endif | ||
525 | |||
526 | #if AIC_DEBUG_REGISTERS | ||
527 | ahc_reg_print_t ahc_allones_print; | ||
528 | #else | ||
529 | #define ahc_allones_print(regvalue, cur_col, wrap) \ | ||
530 | ahc_print_register(NULL, 0, "ALLONES", 0x69, regvalue, cur_col, wrap) | ||
531 | #endif | ||
532 | |||
533 | #if AIC_DEBUG_REGISTERS | ||
534 | ahc_reg_print_t ahc_allzeros_print; | ||
535 | #else | ||
536 | #define ahc_allzeros_print(regvalue, cur_col, wrap) \ | ||
537 | ahc_print_register(NULL, 0, "ALLZEROS", 0x6a, regvalue, cur_col, wrap) | ||
538 | #endif | ||
539 | |||
540 | #if AIC_DEBUG_REGISTERS | ||
541 | ahc_reg_print_t ahc_none_print; | ||
542 | #else | ||
543 | #define ahc_none_print(regvalue, cur_col, wrap) \ | ||
544 | ahc_print_register(NULL, 0, "NONE", 0x6a, regvalue, cur_col, wrap) | ||
545 | #endif | ||
546 | |||
547 | #if AIC_DEBUG_REGISTERS | ||
548 | ahc_reg_print_t ahc_flags_print; | ||
549 | #else | ||
550 | #define ahc_flags_print(regvalue, cur_col, wrap) \ | ||
551 | ahc_print_register(NULL, 0, "FLAGS", 0x6b, regvalue, cur_col, wrap) | ||
552 | #endif | ||
553 | |||
554 | #if AIC_DEBUG_REGISTERS | ||
555 | ahc_reg_print_t ahc_sindir_print; | ||
556 | #else | ||
557 | #define ahc_sindir_print(regvalue, cur_col, wrap) \ | ||
558 | ahc_print_register(NULL, 0, "SINDIR", 0x6c, regvalue, cur_col, wrap) | ||
559 | #endif | ||
560 | |||
561 | #if AIC_DEBUG_REGISTERS | ||
562 | ahc_reg_print_t ahc_dindir_print; | ||
563 | #else | ||
564 | #define ahc_dindir_print(regvalue, cur_col, wrap) \ | ||
565 | ahc_print_register(NULL, 0, "DINDIR", 0x6d, regvalue, cur_col, wrap) | ||
566 | #endif | ||
567 | |||
568 | #if AIC_DEBUG_REGISTERS | ||
569 | ahc_reg_print_t ahc_function1_print; | ||
570 | #else | ||
571 | #define ahc_function1_print(regvalue, cur_col, wrap) \ | ||
572 | ahc_print_register(NULL, 0, "FUNCTION1", 0x6e, regvalue, cur_col, wrap) | ||
573 | #endif | ||
574 | |||
575 | #if AIC_DEBUG_REGISTERS | ||
576 | ahc_reg_print_t ahc_stack_print; | ||
577 | #else | ||
578 | #define ahc_stack_print(regvalue, cur_col, wrap) \ | ||
579 | ahc_print_register(NULL, 0, "STACK", 0x6f, regvalue, cur_col, wrap) | ||
580 | #endif | ||
581 | |||
582 | #if AIC_DEBUG_REGISTERS | ||
583 | ahc_reg_print_t ahc_targ_offset_print; | ||
584 | #else | ||
585 | #define ahc_targ_offset_print(regvalue, cur_col, wrap) \ | ||
586 | ahc_print_register(NULL, 0, "TARG_OFFSET", 0x70, regvalue, cur_col, wrap) | ||
587 | #endif | ||
588 | |||
589 | #if AIC_DEBUG_REGISTERS | ||
590 | ahc_reg_print_t ahc_sram_base_print; | 121 | ahc_reg_print_t ahc_sram_base_print; |
591 | #else | 122 | #else |
592 | #define ahc_sram_base_print(regvalue, cur_col, wrap) \ | 123 | #define ahc_sram_base_print(regvalue, cur_col, wrap) \ |
@@ -594,97 +125,6 @@ ahc_reg_print_t ahc_sram_base_print; | |||
594 | #endif | 125 | #endif |
595 | 126 | ||
596 | #if AIC_DEBUG_REGISTERS | 127 | #if AIC_DEBUG_REGISTERS |
597 | ahc_reg_print_t ahc_bctl_print; | ||
598 | #else | ||
599 | #define ahc_bctl_print(regvalue, cur_col, wrap) \ | ||
600 | ahc_print_register(NULL, 0, "BCTL", 0x84, regvalue, cur_col, wrap) | ||
601 | #endif | ||
602 | |||
603 | #if AIC_DEBUG_REGISTERS | ||
604 | ahc_reg_print_t ahc_dscommand0_print; | ||
605 | #else | ||
606 | #define ahc_dscommand0_print(regvalue, cur_col, wrap) \ | ||
607 | ahc_print_register(NULL, 0, "DSCOMMAND0", 0x84, regvalue, cur_col, wrap) | ||
608 | #endif | ||
609 | |||
610 | #if AIC_DEBUG_REGISTERS | ||
611 | ahc_reg_print_t ahc_bustime_print; | ||
612 | #else | ||
613 | #define ahc_bustime_print(regvalue, cur_col, wrap) \ | ||
614 | ahc_print_register(NULL, 0, "BUSTIME", 0x85, regvalue, cur_col, wrap) | ||
615 | #endif | ||
616 | |||
617 | #if AIC_DEBUG_REGISTERS | ||
618 | ahc_reg_print_t ahc_dscommand1_print; | ||
619 | #else | ||
620 | #define ahc_dscommand1_print(regvalue, cur_col, wrap) \ | ||
621 | ahc_print_register(NULL, 0, "DSCOMMAND1", 0x85, regvalue, cur_col, wrap) | ||
622 | #endif | ||
623 | |||
624 | #if AIC_DEBUG_REGISTERS | ||
625 | ahc_reg_print_t ahc_busspd_print; | ||
626 | #else | ||
627 | #define ahc_busspd_print(regvalue, cur_col, wrap) \ | ||
628 | ahc_print_register(NULL, 0, "BUSSPD", 0x86, regvalue, cur_col, wrap) | ||
629 | #endif | ||
630 | |||
631 | #if AIC_DEBUG_REGISTERS | ||
632 | ahc_reg_print_t ahc_hs_mailbox_print; | ||
633 | #else | ||
634 | #define ahc_hs_mailbox_print(regvalue, cur_col, wrap) \ | ||
635 | ahc_print_register(NULL, 0, "HS_MAILBOX", 0x86, regvalue, cur_col, wrap) | ||
636 | #endif | ||
637 | |||
638 | #if AIC_DEBUG_REGISTERS | ||
639 | ahc_reg_print_t ahc_dspcistatus_print; | ||
640 | #else | ||
641 | #define ahc_dspcistatus_print(regvalue, cur_col, wrap) \ | ||
642 | ahc_print_register(NULL, 0, "DSPCISTATUS", 0x86, regvalue, cur_col, wrap) | ||
643 | #endif | ||
644 | |||
645 | #if AIC_DEBUG_REGISTERS | ||
646 | ahc_reg_print_t ahc_hcntrl_print; | ||
647 | #else | ||
648 | #define ahc_hcntrl_print(regvalue, cur_col, wrap) \ | ||
649 | ahc_print_register(NULL, 0, "HCNTRL", 0x87, regvalue, cur_col, wrap) | ||
650 | #endif | ||
651 | |||
652 | #if AIC_DEBUG_REGISTERS | ||
653 | ahc_reg_print_t ahc_haddr_print; | ||
654 | #else | ||
655 | #define ahc_haddr_print(regvalue, cur_col, wrap) \ | ||
656 | ahc_print_register(NULL, 0, "HADDR", 0x88, regvalue, cur_col, wrap) | ||
657 | #endif | ||
658 | |||
659 | #if AIC_DEBUG_REGISTERS | ||
660 | ahc_reg_print_t ahc_hcnt_print; | ||
661 | #else | ||
662 | #define ahc_hcnt_print(regvalue, cur_col, wrap) \ | ||
663 | ahc_print_register(NULL, 0, "HCNT", 0x8c, regvalue, cur_col, wrap) | ||
664 | #endif | ||
665 | |||
666 | #if AIC_DEBUG_REGISTERS | ||
667 | ahc_reg_print_t ahc_scbptr_print; | ||
668 | #else | ||
669 | #define ahc_scbptr_print(regvalue, cur_col, wrap) \ | ||
670 | ahc_print_register(NULL, 0, "SCBPTR", 0x90, regvalue, cur_col, wrap) | ||
671 | #endif | ||
672 | |||
673 | #if AIC_DEBUG_REGISTERS | ||
674 | ahc_reg_print_t ahc_intstat_print; | ||
675 | #else | ||
676 | #define ahc_intstat_print(regvalue, cur_col, wrap) \ | ||
677 | ahc_print_register(NULL, 0, "INTSTAT", 0x91, regvalue, cur_col, wrap) | ||
678 | #endif | ||
679 | |||
680 | #if AIC_DEBUG_REGISTERS | ||
681 | ahc_reg_print_t ahc_clrint_print; | ||
682 | #else | ||
683 | #define ahc_clrint_print(regvalue, cur_col, wrap) \ | ||
684 | ahc_print_register(NULL, 0, "CLRINT", 0x92, regvalue, cur_col, wrap) | ||
685 | #endif | ||
686 | |||
687 | #if AIC_DEBUG_REGISTERS | ||
688 | ahc_reg_print_t ahc_error_print; | 128 | ahc_reg_print_t ahc_error_print; |
689 | #else | 129 | #else |
690 | #define ahc_error_print(regvalue, cur_col, wrap) \ | 130 | #define ahc_error_print(regvalue, cur_col, wrap) \ |
@@ -706,69 +146,6 @@ ahc_reg_print_t ahc_dfstatus_print; | |||
706 | #endif | 146 | #endif |
707 | 147 | ||
708 | #if AIC_DEBUG_REGISTERS | 148 | #if AIC_DEBUG_REGISTERS |
709 | ahc_reg_print_t ahc_dfwaddr_print; | ||
710 | #else | ||
711 | #define ahc_dfwaddr_print(regvalue, cur_col, wrap) \ | ||
712 | ahc_print_register(NULL, 0, "DFWADDR", 0x95, regvalue, cur_col, wrap) | ||
713 | #endif | ||
714 | |||
715 | #if AIC_DEBUG_REGISTERS | ||
716 | ahc_reg_print_t ahc_dfraddr_print; | ||
717 | #else | ||
718 | #define ahc_dfraddr_print(regvalue, cur_col, wrap) \ | ||
719 | ahc_print_register(NULL, 0, "DFRADDR", 0x97, regvalue, cur_col, wrap) | ||
720 | #endif | ||
721 | |||
722 | #if AIC_DEBUG_REGISTERS | ||
723 | ahc_reg_print_t ahc_dfdat_print; | ||
724 | #else | ||
725 | #define ahc_dfdat_print(regvalue, cur_col, wrap) \ | ||
726 | ahc_print_register(NULL, 0, "DFDAT", 0x99, regvalue, cur_col, wrap) | ||
727 | #endif | ||
728 | |||
729 | #if AIC_DEBUG_REGISTERS | ||
730 | ahc_reg_print_t ahc_scbcnt_print; | ||
731 | #else | ||
732 | #define ahc_scbcnt_print(regvalue, cur_col, wrap) \ | ||
733 | ahc_print_register(NULL, 0, "SCBCNT", 0x9a, regvalue, cur_col, wrap) | ||
734 | #endif | ||
735 | |||
736 | #if AIC_DEBUG_REGISTERS | ||
737 | ahc_reg_print_t ahc_qinfifo_print; | ||
738 | #else | ||
739 | #define ahc_qinfifo_print(regvalue, cur_col, wrap) \ | ||
740 | ahc_print_register(NULL, 0, "QINFIFO", 0x9b, regvalue, cur_col, wrap) | ||
741 | #endif | ||
742 | |||
743 | #if AIC_DEBUG_REGISTERS | ||
744 | ahc_reg_print_t ahc_qincnt_print; | ||
745 | #else | ||
746 | #define ahc_qincnt_print(regvalue, cur_col, wrap) \ | ||
747 | ahc_print_register(NULL, 0, "QINCNT", 0x9c, regvalue, cur_col, wrap) | ||
748 | #endif | ||
749 | |||
750 | #if AIC_DEBUG_REGISTERS | ||
751 | ahc_reg_print_t ahc_qoutfifo_print; | ||
752 | #else | ||
753 | #define ahc_qoutfifo_print(regvalue, cur_col, wrap) \ | ||
754 | ahc_print_register(NULL, 0, "QOUTFIFO", 0x9d, regvalue, cur_col, wrap) | ||
755 | #endif | ||
756 | |||
757 | #if AIC_DEBUG_REGISTERS | ||
758 | ahc_reg_print_t ahc_crccontrol1_print; | ||
759 | #else | ||
760 | #define ahc_crccontrol1_print(regvalue, cur_col, wrap) \ | ||
761 | ahc_print_register(NULL, 0, "CRCCONTROL1", 0x9d, regvalue, cur_col, wrap) | ||
762 | #endif | ||
763 | |||
764 | #if AIC_DEBUG_REGISTERS | ||
765 | ahc_reg_print_t ahc_qoutcnt_print; | ||
766 | #else | ||
767 | #define ahc_qoutcnt_print(regvalue, cur_col, wrap) \ | ||
768 | ahc_print_register(NULL, 0, "QOUTCNT", 0x9e, regvalue, cur_col, wrap) | ||
769 | #endif | ||
770 | |||
771 | #if AIC_DEBUG_REGISTERS | ||
772 | ahc_reg_print_t ahc_scsiphase_print; | 149 | ahc_reg_print_t ahc_scsiphase_print; |
773 | #else | 150 | #else |
774 | #define ahc_scsiphase_print(regvalue, cur_col, wrap) \ | 151 | #define ahc_scsiphase_print(regvalue, cur_col, wrap) \ |
@@ -776,13 +153,6 @@ ahc_reg_print_t ahc_scsiphase_print; | |||
776 | #endif | 153 | #endif |
777 | 154 | ||
778 | #if AIC_DEBUG_REGISTERS | 155 | #if AIC_DEBUG_REGISTERS |
779 | ahc_reg_print_t ahc_sfunct_print; | ||
780 | #else | ||
781 | #define ahc_sfunct_print(regvalue, cur_col, wrap) \ | ||
782 | ahc_print_register(NULL, 0, "SFUNCT", 0x9f, regvalue, cur_col, wrap) | ||
783 | #endif | ||
784 | |||
785 | #if AIC_DEBUG_REGISTERS | ||
786 | ahc_reg_print_t ahc_scb_base_print; | 156 | ahc_reg_print_t ahc_scb_base_print; |
787 | #else | 157 | #else |
788 | #define ahc_scb_base_print(regvalue, cur_col, wrap) \ | 158 | #define ahc_scb_base_print(regvalue, cur_col, wrap) \ |
@@ -790,69 +160,6 @@ ahc_reg_print_t ahc_scb_base_print; | |||
790 | #endif | 160 | #endif |
791 | 161 | ||
792 | #if AIC_DEBUG_REGISTERS | 162 | #if AIC_DEBUG_REGISTERS |
793 | ahc_reg_print_t ahc_scb_cdb_ptr_print; | ||
794 | #else | ||
795 | #define ahc_scb_cdb_ptr_print(regvalue, cur_col, wrap) \ | ||
796 | ahc_print_register(NULL, 0, "SCB_CDB_PTR", 0xa0, regvalue, cur_col, wrap) | ||
797 | #endif | ||
798 | |||
799 | #if AIC_DEBUG_REGISTERS | ||
800 | ahc_reg_print_t ahc_scb_residual_sgptr_print; | ||
801 | #else | ||
802 | #define ahc_scb_residual_sgptr_print(regvalue, cur_col, wrap) \ | ||
803 | ahc_print_register(NULL, 0, "SCB_RESIDUAL_SGPTR", 0xa4, regvalue, cur_col, wrap) | ||
804 | #endif | ||
805 | |||
806 | #if AIC_DEBUG_REGISTERS | ||
807 | ahc_reg_print_t ahc_scb_scsi_status_print; | ||
808 | #else | ||
809 | #define ahc_scb_scsi_status_print(regvalue, cur_col, wrap) \ | ||
810 | ahc_print_register(NULL, 0, "SCB_SCSI_STATUS", 0xa8, regvalue, cur_col, wrap) | ||
811 | #endif | ||
812 | |||
813 | #if AIC_DEBUG_REGISTERS | ||
814 | ahc_reg_print_t ahc_scb_target_phases_print; | ||
815 | #else | ||
816 | #define ahc_scb_target_phases_print(regvalue, cur_col, wrap) \ | ||
817 | ahc_print_register(NULL, 0, "SCB_TARGET_PHASES", 0xa9, regvalue, cur_col, wrap) | ||
818 | #endif | ||
819 | |||
820 | #if AIC_DEBUG_REGISTERS | ||
821 | ahc_reg_print_t ahc_scb_target_data_dir_print; | ||
822 | #else | ||
823 | #define ahc_scb_target_data_dir_print(regvalue, cur_col, wrap) \ | ||
824 | ahc_print_register(NULL, 0, "SCB_TARGET_DATA_DIR", 0xaa, regvalue, cur_col, wrap) | ||
825 | #endif | ||
826 | |||
827 | #if AIC_DEBUG_REGISTERS | ||
828 | ahc_reg_print_t ahc_scb_target_itag_print; | ||
829 | #else | ||
830 | #define ahc_scb_target_itag_print(regvalue, cur_col, wrap) \ | ||
831 | ahc_print_register(NULL, 0, "SCB_TARGET_ITAG", 0xab, regvalue, cur_col, wrap) | ||
832 | #endif | ||
833 | |||
834 | #if AIC_DEBUG_REGISTERS | ||
835 | ahc_reg_print_t ahc_scb_dataptr_print; | ||
836 | #else | ||
837 | #define ahc_scb_dataptr_print(regvalue, cur_col, wrap) \ | ||
838 | ahc_print_register(NULL, 0, "SCB_DATAPTR", 0xac, regvalue, cur_col, wrap) | ||
839 | #endif | ||
840 | |||
841 | #if AIC_DEBUG_REGISTERS | ||
842 | ahc_reg_print_t ahc_scb_datacnt_print; | ||
843 | #else | ||
844 | #define ahc_scb_datacnt_print(regvalue, cur_col, wrap) \ | ||
845 | ahc_print_register(NULL, 0, "SCB_DATACNT", 0xb0, regvalue, cur_col, wrap) | ||
846 | #endif | ||
847 | |||
848 | #if AIC_DEBUG_REGISTERS | ||
849 | ahc_reg_print_t ahc_scb_sgptr_print; | ||
850 | #else | ||
851 | #define ahc_scb_sgptr_print(regvalue, cur_col, wrap) \ | ||
852 | ahc_print_register(NULL, 0, "SCB_SGPTR", 0xb4, regvalue, cur_col, wrap) | ||
853 | #endif | ||
854 | |||
855 | #if AIC_DEBUG_REGISTERS | ||
856 | ahc_reg_print_t ahc_scb_control_print; | 163 | ahc_reg_print_t ahc_scb_control_print; |
857 | #else | 164 | #else |
858 | #define ahc_scb_control_print(regvalue, cur_col, wrap) \ | 165 | #define ahc_scb_control_print(regvalue, cur_col, wrap) \ |
@@ -880,188 +187,6 @@ ahc_reg_print_t ahc_scb_tag_print; | |||
880 | ahc_print_register(NULL, 0, "SCB_TAG", 0xbb, regvalue, cur_col, wrap) | 187 | ahc_print_register(NULL, 0, "SCB_TAG", 0xbb, regvalue, cur_col, wrap) |
881 | #endif | 188 | #endif |
882 | 189 | ||
883 | #if AIC_DEBUG_REGISTERS | ||
884 | ahc_reg_print_t ahc_scb_cdb_len_print; | ||
885 | #else | ||
886 | #define ahc_scb_cdb_len_print(regvalue, cur_col, wrap) \ | ||
887 | ahc_print_register(NULL, 0, "SCB_CDB_LEN", 0xbc, regvalue, cur_col, wrap) | ||
888 | #endif | ||
889 | |||
890 | #if AIC_DEBUG_REGISTERS | ||
891 | ahc_reg_print_t ahc_scb_scsirate_print; | ||
892 | #else | ||
893 | #define ahc_scb_scsirate_print(regvalue, cur_col, wrap) \ | ||
894 | ahc_print_register(NULL, 0, "SCB_SCSIRATE", 0xbd, regvalue, cur_col, wrap) | ||
895 | #endif | ||
896 | |||
897 | #if AIC_DEBUG_REGISTERS | ||
898 | ahc_reg_print_t ahc_scb_scsioffset_print; | ||
899 | #else | ||
900 | #define ahc_scb_scsioffset_print(regvalue, cur_col, wrap) \ | ||
901 | ahc_print_register(NULL, 0, "SCB_SCSIOFFSET", 0xbe, regvalue, cur_col, wrap) | ||
902 | #endif | ||
903 | |||
904 | #if AIC_DEBUG_REGISTERS | ||
905 | ahc_reg_print_t ahc_scb_next_print; | ||
906 | #else | ||
907 | #define ahc_scb_next_print(regvalue, cur_col, wrap) \ | ||
908 | ahc_print_register(NULL, 0, "SCB_NEXT", 0xbf, regvalue, cur_col, wrap) | ||
909 | #endif | ||
910 | |||
911 | #if AIC_DEBUG_REGISTERS | ||
912 | ahc_reg_print_t ahc_scb_64_spare_print; | ||
913 | #else | ||
914 | #define ahc_scb_64_spare_print(regvalue, cur_col, wrap) \ | ||
915 | ahc_print_register(NULL, 0, "SCB_64_SPARE", 0xc0, regvalue, cur_col, wrap) | ||
916 | #endif | ||
917 | |||
918 | #if AIC_DEBUG_REGISTERS | ||
919 | ahc_reg_print_t ahc_seectl_2840_print; | ||
920 | #else | ||
921 | #define ahc_seectl_2840_print(regvalue, cur_col, wrap) \ | ||
922 | ahc_print_register(NULL, 0, "SEECTL_2840", 0xc0, regvalue, cur_col, wrap) | ||
923 | #endif | ||
924 | |||
925 | #if AIC_DEBUG_REGISTERS | ||
926 | ahc_reg_print_t ahc_status_2840_print; | ||
927 | #else | ||
928 | #define ahc_status_2840_print(regvalue, cur_col, wrap) \ | ||
929 | ahc_print_register(NULL, 0, "STATUS_2840", 0xc1, regvalue, cur_col, wrap) | ||
930 | #endif | ||
931 | |||
932 | #if AIC_DEBUG_REGISTERS | ||
933 | ahc_reg_print_t ahc_scb_64_btt_print; | ||
934 | #else | ||
935 | #define ahc_scb_64_btt_print(regvalue, cur_col, wrap) \ | ||
936 | ahc_print_register(NULL, 0, "SCB_64_BTT", 0xd0, regvalue, cur_col, wrap) | ||
937 | #endif | ||
938 | |||
939 | #if AIC_DEBUG_REGISTERS | ||
940 | ahc_reg_print_t ahc_cchaddr_print; | ||
941 | #else | ||
942 | #define ahc_cchaddr_print(regvalue, cur_col, wrap) \ | ||
943 | ahc_print_register(NULL, 0, "CCHADDR", 0xe0, regvalue, cur_col, wrap) | ||
944 | #endif | ||
945 | |||
946 | #if AIC_DEBUG_REGISTERS | ||
947 | ahc_reg_print_t ahc_cchcnt_print; | ||
948 | #else | ||
949 | #define ahc_cchcnt_print(regvalue, cur_col, wrap) \ | ||
950 | ahc_print_register(NULL, 0, "CCHCNT", 0xe8, regvalue, cur_col, wrap) | ||
951 | #endif | ||
952 | |||
953 | #if AIC_DEBUG_REGISTERS | ||
954 | ahc_reg_print_t ahc_ccsgram_print; | ||
955 | #else | ||
956 | #define ahc_ccsgram_print(regvalue, cur_col, wrap) \ | ||
957 | ahc_print_register(NULL, 0, "CCSGRAM", 0xe9, regvalue, cur_col, wrap) | ||
958 | #endif | ||
959 | |||
960 | #if AIC_DEBUG_REGISTERS | ||
961 | ahc_reg_print_t ahc_ccsgaddr_print; | ||
962 | #else | ||
963 | #define ahc_ccsgaddr_print(regvalue, cur_col, wrap) \ | ||
964 | ahc_print_register(NULL, 0, "CCSGADDR", 0xea, regvalue, cur_col, wrap) | ||
965 | #endif | ||
966 | |||
967 | #if AIC_DEBUG_REGISTERS | ||
968 | ahc_reg_print_t ahc_ccsgctl_print; | ||
969 | #else | ||
970 | #define ahc_ccsgctl_print(regvalue, cur_col, wrap) \ | ||
971 | ahc_print_register(NULL, 0, "CCSGCTL", 0xeb, regvalue, cur_col, wrap) | ||
972 | #endif | ||
973 | |||
974 | #if AIC_DEBUG_REGISTERS | ||
975 | ahc_reg_print_t ahc_ccscbram_print; | ||
976 | #else | ||
977 | #define ahc_ccscbram_print(regvalue, cur_col, wrap) \ | ||
978 | ahc_print_register(NULL, 0, "CCSCBRAM", 0xec, regvalue, cur_col, wrap) | ||
979 | #endif | ||
980 | |||
981 | #if AIC_DEBUG_REGISTERS | ||
982 | ahc_reg_print_t ahc_ccscbaddr_print; | ||
983 | #else | ||
984 | #define ahc_ccscbaddr_print(regvalue, cur_col, wrap) \ | ||
985 | ahc_print_register(NULL, 0, "CCSCBADDR", 0xed, regvalue, cur_col, wrap) | ||
986 | #endif | ||
987 | |||
988 | #if AIC_DEBUG_REGISTERS | ||
989 | ahc_reg_print_t ahc_ccscbctl_print; | ||
990 | #else | ||
991 | #define ahc_ccscbctl_print(regvalue, cur_col, wrap) \ | ||
992 | ahc_print_register(NULL, 0, "CCSCBCTL", 0xee, regvalue, cur_col, wrap) | ||
993 | #endif | ||
994 | |||
995 | #if AIC_DEBUG_REGISTERS | ||
996 | ahc_reg_print_t ahc_ccscbcnt_print; | ||
997 | #else | ||
998 | #define ahc_ccscbcnt_print(regvalue, cur_col, wrap) \ | ||
999 | ahc_print_register(NULL, 0, "CCSCBCNT", 0xef, regvalue, cur_col, wrap) | ||
1000 | #endif | ||
1001 | |||
1002 | #if AIC_DEBUG_REGISTERS | ||
1003 | ahc_reg_print_t ahc_scbbaddr_print; | ||
1004 | #else | ||
1005 | #define ahc_scbbaddr_print(regvalue, cur_col, wrap) \ | ||
1006 | ahc_print_register(NULL, 0, "SCBBADDR", 0xf0, regvalue, cur_col, wrap) | ||
1007 | #endif | ||
1008 | |||
1009 | #if AIC_DEBUG_REGISTERS | ||
1010 | ahc_reg_print_t ahc_ccscbptr_print; | ||
1011 | #else | ||
1012 | #define ahc_ccscbptr_print(regvalue, cur_col, wrap) \ | ||
1013 | ahc_print_register(NULL, 0, "CCSCBPTR", 0xf1, regvalue, cur_col, wrap) | ||
1014 | #endif | ||
1015 | |||
1016 | #if AIC_DEBUG_REGISTERS | ||
1017 | ahc_reg_print_t ahc_hnscb_qoff_print; | ||
1018 | #else | ||
1019 | #define ahc_hnscb_qoff_print(regvalue, cur_col, wrap) \ | ||
1020 | ahc_print_register(NULL, 0, "HNSCB_QOFF", 0xf4, regvalue, cur_col, wrap) | ||
1021 | #endif | ||
1022 | |||
1023 | #if AIC_DEBUG_REGISTERS | ||
1024 | ahc_reg_print_t ahc_snscb_qoff_print; | ||
1025 | #else | ||
1026 | #define ahc_snscb_qoff_print(regvalue, cur_col, wrap) \ | ||
1027 | ahc_print_register(NULL, 0, "SNSCB_QOFF", 0xf6, regvalue, cur_col, wrap) | ||
1028 | #endif | ||
1029 | |||
1030 | #if AIC_DEBUG_REGISTERS | ||
1031 | ahc_reg_print_t ahc_sdscb_qoff_print; | ||
1032 | #else | ||
1033 | #define ahc_sdscb_qoff_print(regvalue, cur_col, wrap) \ | ||
1034 | ahc_print_register(NULL, 0, "SDSCB_QOFF", 0xf8, regvalue, cur_col, wrap) | ||
1035 | #endif | ||
1036 | |||
1037 | #if AIC_DEBUG_REGISTERS | ||
1038 | ahc_reg_print_t ahc_qoff_ctlsta_print; | ||
1039 | #else | ||
1040 | #define ahc_qoff_ctlsta_print(regvalue, cur_col, wrap) \ | ||
1041 | ahc_print_register(NULL, 0, "QOFF_CTLSTA", 0xfa, regvalue, cur_col, wrap) | ||
1042 | #endif | ||
1043 | |||
1044 | #if AIC_DEBUG_REGISTERS | ||
1045 | ahc_reg_print_t ahc_dff_thrsh_print; | ||
1046 | #else | ||
1047 | #define ahc_dff_thrsh_print(regvalue, cur_col, wrap) \ | ||
1048 | ahc_print_register(NULL, 0, "DFF_THRSH", 0xfb, regvalue, cur_col, wrap) | ||
1049 | #endif | ||
1050 | |||
1051 | #if AIC_DEBUG_REGISTERS | ||
1052 | ahc_reg_print_t ahc_sg_cache_shadow_print; | ||
1053 | #else | ||
1054 | #define ahc_sg_cache_shadow_print(regvalue, cur_col, wrap) \ | ||
1055 | ahc_print_register(NULL, 0, "SG_CACHE_SHADOW", 0xfc, regvalue, cur_col, wrap) | ||
1056 | #endif | ||
1057 | |||
1058 | #if AIC_DEBUG_REGISTERS | ||
1059 | ahc_reg_print_t ahc_sg_cache_pre_print; | ||
1060 | #else | ||
1061 | #define ahc_sg_cache_pre_print(regvalue, cur_col, wrap) \ | ||
1062 | ahc_print_register(NULL, 0, "SG_CACHE_PRE", 0xfc, regvalue, cur_col, wrap) | ||
1063 | #endif | ||
1064 | |||
1065 | 190 | ||
1066 | #define SCSISEQ 0x00 | 191 | #define SCSISEQ 0x00 |
1067 | #define TEMODE 0x80 | 192 | #define TEMODE 0x80 |
diff --git a/drivers/scsi/aic7xxx/aic7xxx_reg_print.c_shipped b/drivers/scsi/aic7xxx/aic7xxx_reg_print.c_shipped index 309a562b009e..9f9b88047d0c 100644 --- a/drivers/scsi/aic7xxx/aic7xxx_reg_print.c_shipped +++ b/drivers/scsi/aic7xxx/aic7xxx_reg_print.c_shipped | |||
@@ -43,48 +43,6 @@ ahc_sxfrctl0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
43 | 0x01, regvalue, cur_col, wrap)); | 43 | 0x01, regvalue, cur_col, wrap)); |
44 | } | 44 | } |
45 | 45 | ||
46 | static const ahc_reg_parse_entry_t SXFRCTL1_parse_table[] = { | ||
47 | { "STPWEN", 0x01, 0x01 }, | ||
48 | { "ACTNEGEN", 0x02, 0x02 }, | ||
49 | { "ENSTIMER", 0x04, 0x04 }, | ||
50 | { "ENSPCHK", 0x20, 0x20 }, | ||
51 | { "SWRAPEN", 0x40, 0x40 }, | ||
52 | { "BITBUCKET", 0x80, 0x80 }, | ||
53 | { "STIMESEL", 0x18, 0x18 } | ||
54 | }; | ||
55 | |||
56 | int | ||
57 | ahc_sxfrctl1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
58 | { | ||
59 | return (ahc_print_register(SXFRCTL1_parse_table, 7, "SXFRCTL1", | ||
60 | 0x02, regvalue, cur_col, wrap)); | ||
61 | } | ||
62 | |||
63 | static const ahc_reg_parse_entry_t SCSISIGO_parse_table[] = { | ||
64 | { "ACKO", 0x01, 0x01 }, | ||
65 | { "REQO", 0x02, 0x02 }, | ||
66 | { "BSYO", 0x04, 0x04 }, | ||
67 | { "SELO", 0x08, 0x08 }, | ||
68 | { "ATNO", 0x10, 0x10 }, | ||
69 | { "MSGO", 0x20, 0x20 }, | ||
70 | { "IOO", 0x40, 0x40 }, | ||
71 | { "CDO", 0x80, 0x80 }, | ||
72 | { "P_DATAOUT", 0x00, 0x00 }, | ||
73 | { "P_DATAIN", 0x40, 0x40 }, | ||
74 | { "P_COMMAND", 0x80, 0x80 }, | ||
75 | { "P_MESGOUT", 0xa0, 0xa0 }, | ||
76 | { "P_STATUS", 0xc0, 0xc0 }, | ||
77 | { "PHASE_MASK", 0xe0, 0xe0 }, | ||
78 | { "P_MESGIN", 0xe0, 0xe0 } | ||
79 | }; | ||
80 | |||
81 | int | ||
82 | ahc_scsisigo_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
83 | { | ||
84 | return (ahc_print_register(SCSISIGO_parse_table, 15, "SCSISIGO", | ||
85 | 0x03, regvalue, cur_col, wrap)); | ||
86 | } | ||
87 | |||
88 | static const ahc_reg_parse_entry_t SCSISIGI_parse_table[] = { | 46 | static const ahc_reg_parse_entry_t SCSISIGI_parse_table[] = { |
89 | { "ACKI", 0x01, 0x01 }, | 47 | { "ACKI", 0x01, 0x01 }, |
90 | { "REQI", 0x02, 0x02 }, | 48 | { "REQI", 0x02, 0x02 }, |
@@ -128,77 +86,6 @@ ahc_scsirate_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
128 | 0x04, regvalue, cur_col, wrap)); | 86 | 0x04, regvalue, cur_col, wrap)); |
129 | } | 87 | } |
130 | 88 | ||
131 | static const ahc_reg_parse_entry_t SCSIID_parse_table[] = { | ||
132 | { "TWIN_CHNLB", 0x80, 0x80 }, | ||
133 | { "OID", 0x0f, 0x0f }, | ||
134 | { "TWIN_TID", 0x70, 0x70 }, | ||
135 | { "SOFS_ULTRA2", 0x7f, 0x7f }, | ||
136 | { "TID", 0xf0, 0xf0 } | ||
137 | }; | ||
138 | |||
139 | int | ||
140 | ahc_scsiid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
141 | { | ||
142 | return (ahc_print_register(SCSIID_parse_table, 5, "SCSIID", | ||
143 | 0x05, regvalue, cur_col, wrap)); | ||
144 | } | ||
145 | |||
146 | int | ||
147 | ahc_scsidatl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
148 | { | ||
149 | return (ahc_print_register(NULL, 0, "SCSIDATL", | ||
150 | 0x06, regvalue, cur_col, wrap)); | ||
151 | } | ||
152 | |||
153 | int | ||
154 | ahc_stcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
155 | { | ||
156 | return (ahc_print_register(NULL, 0, "STCNT", | ||
157 | 0x08, regvalue, cur_col, wrap)); | ||
158 | } | ||
159 | |||
160 | static const ahc_reg_parse_entry_t OPTIONMODE_parse_table[] = { | ||
161 | { "DIS_MSGIN_DUALEDGE", 0x01, 0x01 }, | ||
162 | { "AUTO_MSGOUT_DE", 0x02, 0x02 }, | ||
163 | { "SCSIDATL_IMGEN", 0x04, 0x04 }, | ||
164 | { "EXPPHASEDIS", 0x08, 0x08 }, | ||
165 | { "BUSFREEREV", 0x10, 0x10 }, | ||
166 | { "ATNMGMNTEN", 0x20, 0x20 }, | ||
167 | { "AUTOACKEN", 0x40, 0x40 }, | ||
168 | { "AUTORATEEN", 0x80, 0x80 }, | ||
169 | { "OPTIONMODE_DEFAULTS",0x03, 0x03 } | ||
170 | }; | ||
171 | |||
172 | int | ||
173 | ahc_optionmode_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
174 | { | ||
175 | return (ahc_print_register(OPTIONMODE_parse_table, 9, "OPTIONMODE", | ||
176 | 0x08, regvalue, cur_col, wrap)); | ||
177 | } | ||
178 | |||
179 | int | ||
180 | ahc_targcrccnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
181 | { | ||
182 | return (ahc_print_register(NULL, 0, "TARGCRCCNT", | ||
183 | 0x0a, regvalue, cur_col, wrap)); | ||
184 | } | ||
185 | |||
186 | static const ahc_reg_parse_entry_t CLRSINT0_parse_table[] = { | ||
187 | { "CLRSPIORDY", 0x02, 0x02 }, | ||
188 | { "CLRSWRAP", 0x08, 0x08 }, | ||
189 | { "CLRIOERR", 0x08, 0x08 }, | ||
190 | { "CLRSELINGO", 0x10, 0x10 }, | ||
191 | { "CLRSELDI", 0x20, 0x20 }, | ||
192 | { "CLRSELDO", 0x40, 0x40 } | ||
193 | }; | ||
194 | |||
195 | int | ||
196 | ahc_clrsint0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
197 | { | ||
198 | return (ahc_print_register(CLRSINT0_parse_table, 6, "CLRSINT0", | ||
199 | 0x0b, regvalue, cur_col, wrap)); | ||
200 | } | ||
201 | |||
202 | static const ahc_reg_parse_entry_t SSTAT0_parse_table[] = { | 89 | static const ahc_reg_parse_entry_t SSTAT0_parse_table[] = { |
203 | { "DMADONE", 0x01, 0x01 }, | 90 | { "DMADONE", 0x01, 0x01 }, |
204 | { "SPIORDY", 0x02, 0x02 }, | 91 | { "SPIORDY", 0x02, 0x02 }, |
@@ -218,23 +105,6 @@ ahc_sstat0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
218 | 0x0b, regvalue, cur_col, wrap)); | 105 | 0x0b, regvalue, cur_col, wrap)); |
219 | } | 106 | } |
220 | 107 | ||
221 | static const ahc_reg_parse_entry_t CLRSINT1_parse_table[] = { | ||
222 | { "CLRREQINIT", 0x01, 0x01 }, | ||
223 | { "CLRPHASECHG", 0x02, 0x02 }, | ||
224 | { "CLRSCSIPERR", 0x04, 0x04 }, | ||
225 | { "CLRBUSFREE", 0x08, 0x08 }, | ||
226 | { "CLRSCSIRSTI", 0x20, 0x20 }, | ||
227 | { "CLRATNO", 0x40, 0x40 }, | ||
228 | { "CLRSELTIMEO", 0x80, 0x80 } | ||
229 | }; | ||
230 | |||
231 | int | ||
232 | ahc_clrsint1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
233 | { | ||
234 | return (ahc_print_register(CLRSINT1_parse_table, 7, "CLRSINT1", | ||
235 | 0x0c, regvalue, cur_col, wrap)); | ||
236 | } | ||
237 | |||
238 | static const ahc_reg_parse_entry_t SSTAT1_parse_table[] = { | 108 | static const ahc_reg_parse_entry_t SSTAT1_parse_table[] = { |
239 | { "REQINIT", 0x01, 0x01 }, | 109 | { "REQINIT", 0x01, 0x01 }, |
240 | { "PHASECHG", 0x02, 0x02 }, | 110 | { "PHASECHG", 0x02, 0x02 }, |
@@ -284,18 +154,6 @@ ahc_sstat3_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
284 | 0x0e, regvalue, cur_col, wrap)); | 154 | 0x0e, regvalue, cur_col, wrap)); |
285 | } | 155 | } |
286 | 156 | ||
287 | static const ahc_reg_parse_entry_t SCSIID_ULTRA2_parse_table[] = { | ||
288 | { "OID", 0x0f, 0x0f }, | ||
289 | { "TID", 0xf0, 0xf0 } | ||
290 | }; | ||
291 | |||
292 | int | ||
293 | ahc_scsiid_ultra2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
294 | { | ||
295 | return (ahc_print_register(SCSIID_ULTRA2_parse_table, 2, "SCSIID_ULTRA2", | ||
296 | 0x0f, regvalue, cur_col, wrap)); | ||
297 | } | ||
298 | |||
299 | static const ahc_reg_parse_entry_t SIMODE0_parse_table[] = { | 157 | static const ahc_reg_parse_entry_t SIMODE0_parse_table[] = { |
300 | { "ENDMADONE", 0x01, 0x01 }, | 158 | { "ENDMADONE", 0x01, 0x01 }, |
301 | { "ENSPIORDY", 0x02, 0x02 }, | 159 | { "ENSPIORDY", 0x02, 0x02 }, |
@@ -339,107 +197,6 @@ ahc_scsibusl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
339 | 0x12, regvalue, cur_col, wrap)); | 197 | 0x12, regvalue, cur_col, wrap)); |
340 | } | 198 | } |
341 | 199 | ||
342 | int | ||
343 | ahc_shaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
344 | { | ||
345 | return (ahc_print_register(NULL, 0, "SHADDR", | ||
346 | 0x14, regvalue, cur_col, wrap)); | ||
347 | } | ||
348 | |||
349 | static const ahc_reg_parse_entry_t SELTIMER_parse_table[] = { | ||
350 | { "STAGE1", 0x01, 0x01 }, | ||
351 | { "STAGE2", 0x02, 0x02 }, | ||
352 | { "STAGE3", 0x04, 0x04 }, | ||
353 | { "STAGE4", 0x08, 0x08 }, | ||
354 | { "STAGE5", 0x10, 0x10 }, | ||
355 | { "STAGE6", 0x20, 0x20 } | ||
356 | }; | ||
357 | |||
358 | int | ||
359 | ahc_seltimer_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
360 | { | ||
361 | return (ahc_print_register(SELTIMER_parse_table, 6, "SELTIMER", | ||
362 | 0x18, regvalue, cur_col, wrap)); | ||
363 | } | ||
364 | |||
365 | static const ahc_reg_parse_entry_t SELID_parse_table[] = { | ||
366 | { "ONEBIT", 0x08, 0x08 }, | ||
367 | { "SELID_MASK", 0xf0, 0xf0 } | ||
368 | }; | ||
369 | |||
370 | int | ||
371 | ahc_selid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
372 | { | ||
373 | return (ahc_print_register(SELID_parse_table, 2, "SELID", | ||
374 | 0x19, regvalue, cur_col, wrap)); | ||
375 | } | ||
376 | |||
377 | int | ||
378 | ahc_targid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
379 | { | ||
380 | return (ahc_print_register(NULL, 0, "TARGID", | ||
381 | 0x1b, regvalue, cur_col, wrap)); | ||
382 | } | ||
383 | |||
384 | static const ahc_reg_parse_entry_t SPIOCAP_parse_table[] = { | ||
385 | { "SSPIOCPS", 0x01, 0x01 }, | ||
386 | { "ROM", 0x02, 0x02 }, | ||
387 | { "EEPROM", 0x04, 0x04 }, | ||
388 | { "SEEPROM", 0x08, 0x08 }, | ||
389 | { "EXT_BRDCTL", 0x10, 0x10 }, | ||
390 | { "SOFTCMDEN", 0x20, 0x20 }, | ||
391 | { "SOFT0", 0x40, 0x40 }, | ||
392 | { "SOFT1", 0x80, 0x80 } | ||
393 | }; | ||
394 | |||
395 | int | ||
396 | ahc_spiocap_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
397 | { | ||
398 | return (ahc_print_register(SPIOCAP_parse_table, 8, "SPIOCAP", | ||
399 | 0x1b, regvalue, cur_col, wrap)); | ||
400 | } | ||
401 | |||
402 | static const ahc_reg_parse_entry_t BRDCTL_parse_table[] = { | ||
403 | { "BRDCTL0", 0x01, 0x01 }, | ||
404 | { "BRDSTB_ULTRA2", 0x01, 0x01 }, | ||
405 | { "BRDCTL1", 0x02, 0x02 }, | ||
406 | { "BRDRW_ULTRA2", 0x02, 0x02 }, | ||
407 | { "BRDRW", 0x04, 0x04 }, | ||
408 | { "BRDDAT2", 0x04, 0x04 }, | ||
409 | { "BRDCS", 0x08, 0x08 }, | ||
410 | { "BRDDAT3", 0x08, 0x08 }, | ||
411 | { "BRDSTB", 0x10, 0x10 }, | ||
412 | { "BRDDAT4", 0x10, 0x10 }, | ||
413 | { "BRDDAT5", 0x20, 0x20 }, | ||
414 | { "BRDDAT6", 0x40, 0x40 }, | ||
415 | { "BRDDAT7", 0x80, 0x80 } | ||
416 | }; | ||
417 | |||
418 | int | ||
419 | ahc_brdctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
420 | { | ||
421 | return (ahc_print_register(BRDCTL_parse_table, 13, "BRDCTL", | ||
422 | 0x1d, regvalue, cur_col, wrap)); | ||
423 | } | ||
424 | |||
425 | static const ahc_reg_parse_entry_t SEECTL_parse_table[] = { | ||
426 | { "SEEDI", 0x01, 0x01 }, | ||
427 | { "SEEDO", 0x02, 0x02 }, | ||
428 | { "SEECK", 0x04, 0x04 }, | ||
429 | { "SEECS", 0x08, 0x08 }, | ||
430 | { "SEERDY", 0x10, 0x10 }, | ||
431 | { "SEEMS", 0x20, 0x20 }, | ||
432 | { "EXTARBREQ", 0x40, 0x40 }, | ||
433 | { "EXTARBACK", 0x80, 0x80 } | ||
434 | }; | ||
435 | |||
436 | int | ||
437 | ahc_seectl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
438 | { | ||
439 | return (ahc_print_register(SEECTL_parse_table, 8, "SEECTL", | ||
440 | 0x1e, regvalue, cur_col, wrap)); | ||
441 | } | ||
442 | |||
443 | static const ahc_reg_parse_entry_t SBLKCTL_parse_table[] = { | 200 | static const ahc_reg_parse_entry_t SBLKCTL_parse_table[] = { |
444 | { "XCVR", 0x01, 0x01 }, | 201 | { "XCVR", 0x01, 0x01 }, |
445 | { "SELWIDE", 0x02, 0x02 }, | 202 | { "SELWIDE", 0x02, 0x02 }, |
@@ -458,68 +215,6 @@ ahc_sblkctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
458 | 0x1f, regvalue, cur_col, wrap)); | 215 | 0x1f, regvalue, cur_col, wrap)); |
459 | } | 216 | } |
460 | 217 | ||
461 | int | ||
462 | ahc_busy_targets_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
463 | { | ||
464 | return (ahc_print_register(NULL, 0, "BUSY_TARGETS", | ||
465 | 0x20, regvalue, cur_col, wrap)); | ||
466 | } | ||
467 | |||
468 | int | ||
469 | ahc_ultra_enb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
470 | { | ||
471 | return (ahc_print_register(NULL, 0, "ULTRA_ENB", | ||
472 | 0x30, regvalue, cur_col, wrap)); | ||
473 | } | ||
474 | |||
475 | int | ||
476 | ahc_disc_dsb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
477 | { | ||
478 | return (ahc_print_register(NULL, 0, "DISC_DSB", | ||
479 | 0x32, regvalue, cur_col, wrap)); | ||
480 | } | ||
481 | |||
482 | int | ||
483 | ahc_mwi_residual_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
484 | { | ||
485 | return (ahc_print_register(NULL, 0, "MWI_RESIDUAL", | ||
486 | 0x38, regvalue, cur_col, wrap)); | ||
487 | } | ||
488 | |||
489 | int | ||
490 | ahc_next_queued_scb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
491 | { | ||
492 | return (ahc_print_register(NULL, 0, "NEXT_QUEUED_SCB", | ||
493 | 0x39, regvalue, cur_col, wrap)); | ||
494 | } | ||
495 | |||
496 | int | ||
497 | ahc_msg_out_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
498 | { | ||
499 | return (ahc_print_register(NULL, 0, "MSG_OUT", | ||
500 | 0x3a, regvalue, cur_col, wrap)); | ||
501 | } | ||
502 | |||
503 | static const ahc_reg_parse_entry_t DMAPARAMS_parse_table[] = { | ||
504 | { "FIFORESET", 0x01, 0x01 }, | ||
505 | { "FIFOFLUSH", 0x02, 0x02 }, | ||
506 | { "DIRECTION", 0x04, 0x04 }, | ||
507 | { "HDMAEN", 0x08, 0x08 }, | ||
508 | { "HDMAENACK", 0x08, 0x08 }, | ||
509 | { "SDMAEN", 0x10, 0x10 }, | ||
510 | { "SDMAENACK", 0x10, 0x10 }, | ||
511 | { "SCSIEN", 0x20, 0x20 }, | ||
512 | { "WIDEODD", 0x40, 0x40 }, | ||
513 | { "PRELOADEN", 0x80, 0x80 } | ||
514 | }; | ||
515 | |||
516 | int | ||
517 | ahc_dmaparams_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
518 | { | ||
519 | return (ahc_print_register(DMAPARAMS_parse_table, 10, "DMAPARAMS", | ||
520 | 0x3b, regvalue, cur_col, wrap)); | ||
521 | } | ||
522 | |||
523 | static const ahc_reg_parse_entry_t SEQ_FLAGS_parse_table[] = { | 218 | static const ahc_reg_parse_entry_t SEQ_FLAGS_parse_table[] = { |
524 | { "NO_DISCONNECT", 0x01, 0x01 }, | 219 | { "NO_DISCONNECT", 0x01, 0x01 }, |
525 | { "SPHASE_PENDING", 0x02, 0x02 }, | 220 | { "SPHASE_PENDING", 0x02, 0x02 }, |
@@ -539,20 +234,6 @@ ahc_seq_flags_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
539 | 0x3c, regvalue, cur_col, wrap)); | 234 | 0x3c, regvalue, cur_col, wrap)); |
540 | } | 235 | } |
541 | 236 | ||
542 | int | ||
543 | ahc_saved_scsiid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
544 | { | ||
545 | return (ahc_print_register(NULL, 0, "SAVED_SCSIID", | ||
546 | 0x3d, regvalue, cur_col, wrap)); | ||
547 | } | ||
548 | |||
549 | int | ||
550 | ahc_saved_lun_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
551 | { | ||
552 | return (ahc_print_register(NULL, 0, "SAVED_LUN", | ||
553 | 0x3e, regvalue, cur_col, wrap)); | ||
554 | } | ||
555 | |||
556 | static const ahc_reg_parse_entry_t LASTPHASE_parse_table[] = { | 237 | static const ahc_reg_parse_entry_t LASTPHASE_parse_table[] = { |
557 | { "MSGI", 0x20, 0x20 }, | 238 | { "MSGI", 0x20, 0x20 }, |
558 | { "IOI", 0x40, 0x40 }, | 239 | { "IOI", 0x40, 0x40 }, |
@@ -574,193 +255,6 @@ ahc_lastphase_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
574 | 0x3f, regvalue, cur_col, wrap)); | 255 | 0x3f, regvalue, cur_col, wrap)); |
575 | } | 256 | } |
576 | 257 | ||
577 | int | ||
578 | ahc_waiting_scbh_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
579 | { | ||
580 | return (ahc_print_register(NULL, 0, "WAITING_SCBH", | ||
581 | 0x40, regvalue, cur_col, wrap)); | ||
582 | } | ||
583 | |||
584 | int | ||
585 | ahc_disconnected_scbh_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
586 | { | ||
587 | return (ahc_print_register(NULL, 0, "DISCONNECTED_SCBH", | ||
588 | 0x41, regvalue, cur_col, wrap)); | ||
589 | } | ||
590 | |||
591 | int | ||
592 | ahc_free_scbh_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
593 | { | ||
594 | return (ahc_print_register(NULL, 0, "FREE_SCBH", | ||
595 | 0x42, regvalue, cur_col, wrap)); | ||
596 | } | ||
597 | |||
598 | int | ||
599 | ahc_hscb_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
600 | { | ||
601 | return (ahc_print_register(NULL, 0, "HSCB_ADDR", | ||
602 | 0x44, regvalue, cur_col, wrap)); | ||
603 | } | ||
604 | |||
605 | int | ||
606 | ahc_shared_data_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
607 | { | ||
608 | return (ahc_print_register(NULL, 0, "SHARED_DATA_ADDR", | ||
609 | 0x48, regvalue, cur_col, wrap)); | ||
610 | } | ||
611 | |||
612 | int | ||
613 | ahc_kernel_qinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
614 | { | ||
615 | return (ahc_print_register(NULL, 0, "KERNEL_QINPOS", | ||
616 | 0x4c, regvalue, cur_col, wrap)); | ||
617 | } | ||
618 | |||
619 | int | ||
620 | ahc_qinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
621 | { | ||
622 | return (ahc_print_register(NULL, 0, "QINPOS", | ||
623 | 0x4d, regvalue, cur_col, wrap)); | ||
624 | } | ||
625 | |||
626 | int | ||
627 | ahc_qoutpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
628 | { | ||
629 | return (ahc_print_register(NULL, 0, "QOUTPOS", | ||
630 | 0x4e, regvalue, cur_col, wrap)); | ||
631 | } | ||
632 | |||
633 | int | ||
634 | ahc_kernel_tqinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
635 | { | ||
636 | return (ahc_print_register(NULL, 0, "KERNEL_TQINPOS", | ||
637 | 0x4f, regvalue, cur_col, wrap)); | ||
638 | } | ||
639 | |||
640 | int | ||
641 | ahc_tqinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
642 | { | ||
643 | return (ahc_print_register(NULL, 0, "TQINPOS", | ||
644 | 0x50, regvalue, cur_col, wrap)); | ||
645 | } | ||
646 | |||
647 | static const ahc_reg_parse_entry_t ARG_1_parse_table[] = { | ||
648 | { "CONT_TARG_SESSION", 0x02, 0x02 }, | ||
649 | { "CONT_MSG_LOOP", 0x04, 0x04 }, | ||
650 | { "EXIT_MSG_LOOP", 0x08, 0x08 }, | ||
651 | { "MSGOUT_PHASEMIS", 0x10, 0x10 }, | ||
652 | { "SEND_REJ", 0x20, 0x20 }, | ||
653 | { "SEND_SENSE", 0x40, 0x40 }, | ||
654 | { "SEND_MSG", 0x80, 0x80 } | ||
655 | }; | ||
656 | |||
657 | int | ||
658 | ahc_arg_1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
659 | { | ||
660 | return (ahc_print_register(ARG_1_parse_table, 7, "ARG_1", | ||
661 | 0x51, regvalue, cur_col, wrap)); | ||
662 | } | ||
663 | |||
664 | int | ||
665 | ahc_arg_2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
666 | { | ||
667 | return (ahc_print_register(NULL, 0, "ARG_2", | ||
668 | 0x52, regvalue, cur_col, wrap)); | ||
669 | } | ||
670 | |||
671 | int | ||
672 | ahc_last_msg_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
673 | { | ||
674 | return (ahc_print_register(NULL, 0, "LAST_MSG", | ||
675 | 0x53, regvalue, cur_col, wrap)); | ||
676 | } | ||
677 | |||
678 | static const ahc_reg_parse_entry_t SCSISEQ_TEMPLATE_parse_table[] = { | ||
679 | { "ENAUTOATNP", 0x02, 0x02 }, | ||
680 | { "ENAUTOATNI", 0x04, 0x04 }, | ||
681 | { "ENAUTOATNO", 0x08, 0x08 }, | ||
682 | { "ENRSELI", 0x10, 0x10 }, | ||
683 | { "ENSELI", 0x20, 0x20 }, | ||
684 | { "ENSELO", 0x40, 0x40 } | ||
685 | }; | ||
686 | |||
687 | int | ||
688 | ahc_scsiseq_template_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
689 | { | ||
690 | return (ahc_print_register(SCSISEQ_TEMPLATE_parse_table, 6, "SCSISEQ_TEMPLATE", | ||
691 | 0x54, regvalue, cur_col, wrap)); | ||
692 | } | ||
693 | |||
694 | static const ahc_reg_parse_entry_t HA_274_BIOSGLOBAL_parse_table[] = { | ||
695 | { "HA_274_EXTENDED_TRANS",0x01, 0x01 } | ||
696 | }; | ||
697 | |||
698 | int | ||
699 | ahc_ha_274_biosglobal_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
700 | { | ||
701 | return (ahc_print_register(HA_274_BIOSGLOBAL_parse_table, 1, "HA_274_BIOSGLOBAL", | ||
702 | 0x56, regvalue, cur_col, wrap)); | ||
703 | } | ||
704 | |||
705 | static const ahc_reg_parse_entry_t SEQ_FLAGS2_parse_table[] = { | ||
706 | { "SCB_DMA", 0x01, 0x01 }, | ||
707 | { "TARGET_MSG_PENDING", 0x02, 0x02 } | ||
708 | }; | ||
709 | |||
710 | int | ||
711 | ahc_seq_flags2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
712 | { | ||
713 | return (ahc_print_register(SEQ_FLAGS2_parse_table, 2, "SEQ_FLAGS2", | ||
714 | 0x57, regvalue, cur_col, wrap)); | ||
715 | } | ||
716 | |||
717 | static const ahc_reg_parse_entry_t SCSICONF_parse_table[] = { | ||
718 | { "ENSPCHK", 0x20, 0x20 }, | ||
719 | { "RESET_SCSI", 0x40, 0x40 }, | ||
720 | { "TERM_ENB", 0x80, 0x80 }, | ||
721 | { "HSCSIID", 0x07, 0x07 }, | ||
722 | { "HWSCSIID", 0x0f, 0x0f } | ||
723 | }; | ||
724 | |||
725 | int | ||
726 | ahc_scsiconf_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
727 | { | ||
728 | return (ahc_print_register(SCSICONF_parse_table, 5, "SCSICONF", | ||
729 | 0x5a, regvalue, cur_col, wrap)); | ||
730 | } | ||
731 | |||
732 | static const ahc_reg_parse_entry_t INTDEF_parse_table[] = { | ||
733 | { "EDGE_TRIG", 0x80, 0x80 }, | ||
734 | { "VECTOR", 0x0f, 0x0f } | ||
735 | }; | ||
736 | |||
737 | int | ||
738 | ahc_intdef_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
739 | { | ||
740 | return (ahc_print_register(INTDEF_parse_table, 2, "INTDEF", | ||
741 | 0x5c, regvalue, cur_col, wrap)); | ||
742 | } | ||
743 | |||
744 | int | ||
745 | ahc_hostconf_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
746 | { | ||
747 | return (ahc_print_register(NULL, 0, "HOSTCONF", | ||
748 | 0x5d, regvalue, cur_col, wrap)); | ||
749 | } | ||
750 | |||
751 | static const ahc_reg_parse_entry_t HA_274_BIOSCTRL_parse_table[] = { | ||
752 | { "CHANNEL_B_PRIMARY", 0x08, 0x08 }, | ||
753 | { "BIOSMODE", 0x30, 0x30 }, | ||
754 | { "BIOSDISABLED", 0x30, 0x30 } | ||
755 | }; | ||
756 | |||
757 | int | ||
758 | ahc_ha_274_biosctrl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
759 | { | ||
760 | return (ahc_print_register(HA_274_BIOSCTRL_parse_table, 3, "HA_274_BIOSCTRL", | ||
761 | 0x5f, regvalue, cur_col, wrap)); | ||
762 | } | ||
763 | |||
764 | static const ahc_reg_parse_entry_t SEQCTL_parse_table[] = { | 258 | static const ahc_reg_parse_entry_t SEQCTL_parse_table[] = { |
765 | { "LOADRAM", 0x01, 0x01 }, | 259 | { "LOADRAM", 0x01, 0x01 }, |
766 | { "SEQRESET", 0x02, 0x02 }, | 260 | { "SEQRESET", 0x02, 0x02 }, |
@@ -780,285 +274,12 @@ ahc_seqctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
780 | } | 274 | } |
781 | 275 | ||
782 | int | 276 | int |
783 | ahc_seqram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
784 | { | ||
785 | return (ahc_print_register(NULL, 0, "SEQRAM", | ||
786 | 0x61, regvalue, cur_col, wrap)); | ||
787 | } | ||
788 | |||
789 | int | ||
790 | ahc_seqaddr0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
791 | { | ||
792 | return (ahc_print_register(NULL, 0, "SEQADDR0", | ||
793 | 0x62, regvalue, cur_col, wrap)); | ||
794 | } | ||
795 | |||
796 | static const ahc_reg_parse_entry_t SEQADDR1_parse_table[] = { | ||
797 | { "SEQADDR1_MASK", 0x01, 0x01 } | ||
798 | }; | ||
799 | |||
800 | int | ||
801 | ahc_seqaddr1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
802 | { | ||
803 | return (ahc_print_register(SEQADDR1_parse_table, 1, "SEQADDR1", | ||
804 | 0x63, regvalue, cur_col, wrap)); | ||
805 | } | ||
806 | |||
807 | int | ||
808 | ahc_accum_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
809 | { | ||
810 | return (ahc_print_register(NULL, 0, "ACCUM", | ||
811 | 0x64, regvalue, cur_col, wrap)); | ||
812 | } | ||
813 | |||
814 | int | ||
815 | ahc_sindex_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
816 | { | ||
817 | return (ahc_print_register(NULL, 0, "SINDEX", | ||
818 | 0x65, regvalue, cur_col, wrap)); | ||
819 | } | ||
820 | |||
821 | int | ||
822 | ahc_dindex_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
823 | { | ||
824 | return (ahc_print_register(NULL, 0, "DINDEX", | ||
825 | 0x66, regvalue, cur_col, wrap)); | ||
826 | } | ||
827 | |||
828 | int | ||
829 | ahc_allones_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
830 | { | ||
831 | return (ahc_print_register(NULL, 0, "ALLONES", | ||
832 | 0x69, regvalue, cur_col, wrap)); | ||
833 | } | ||
834 | |||
835 | int | ||
836 | ahc_allzeros_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
837 | { | ||
838 | return (ahc_print_register(NULL, 0, "ALLZEROS", | ||
839 | 0x6a, regvalue, cur_col, wrap)); | ||
840 | } | ||
841 | |||
842 | int | ||
843 | ahc_none_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
844 | { | ||
845 | return (ahc_print_register(NULL, 0, "NONE", | ||
846 | 0x6a, regvalue, cur_col, wrap)); | ||
847 | } | ||
848 | |||
849 | static const ahc_reg_parse_entry_t FLAGS_parse_table[] = { | ||
850 | { "CARRY", 0x01, 0x01 }, | ||
851 | { "ZERO", 0x02, 0x02 } | ||
852 | }; | ||
853 | |||
854 | int | ||
855 | ahc_flags_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
856 | { | ||
857 | return (ahc_print_register(FLAGS_parse_table, 2, "FLAGS", | ||
858 | 0x6b, regvalue, cur_col, wrap)); | ||
859 | } | ||
860 | |||
861 | int | ||
862 | ahc_sindir_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
863 | { | ||
864 | return (ahc_print_register(NULL, 0, "SINDIR", | ||
865 | 0x6c, regvalue, cur_col, wrap)); | ||
866 | } | ||
867 | |||
868 | int | ||
869 | ahc_dindir_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
870 | { | ||
871 | return (ahc_print_register(NULL, 0, "DINDIR", | ||
872 | 0x6d, regvalue, cur_col, wrap)); | ||
873 | } | ||
874 | |||
875 | int | ||
876 | ahc_stack_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
877 | { | ||
878 | return (ahc_print_register(NULL, 0, "STACK", | ||
879 | 0x6f, regvalue, cur_col, wrap)); | ||
880 | } | ||
881 | |||
882 | int | ||
883 | ahc_targ_offset_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
884 | { | ||
885 | return (ahc_print_register(NULL, 0, "TARG_OFFSET", | ||
886 | 0x70, regvalue, cur_col, wrap)); | ||
887 | } | ||
888 | |||
889 | int | ||
890 | ahc_sram_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | 277 | ahc_sram_base_print(u_int regvalue, u_int *cur_col, u_int wrap) |
891 | { | 278 | { |
892 | return (ahc_print_register(NULL, 0, "SRAM_BASE", | 279 | return (ahc_print_register(NULL, 0, "SRAM_BASE", |
893 | 0x70, regvalue, cur_col, wrap)); | 280 | 0x70, regvalue, cur_col, wrap)); |
894 | } | 281 | } |
895 | 282 | ||
896 | static const ahc_reg_parse_entry_t DSCOMMAND0_parse_table[] = { | ||
897 | { "CIOPARCKEN", 0x01, 0x01 }, | ||
898 | { "USCBSIZE32", 0x02, 0x02 }, | ||
899 | { "RAMPS", 0x04, 0x04 }, | ||
900 | { "INTSCBRAMSEL", 0x08, 0x08 }, | ||
901 | { "EXTREQLCK", 0x10, 0x10 }, | ||
902 | { "MPARCKEN", 0x20, 0x20 }, | ||
903 | { "DPARCKEN", 0x40, 0x40 }, | ||
904 | { "CACHETHEN", 0x80, 0x80 } | ||
905 | }; | ||
906 | |||
907 | int | ||
908 | ahc_dscommand0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
909 | { | ||
910 | return (ahc_print_register(DSCOMMAND0_parse_table, 8, "DSCOMMAND0", | ||
911 | 0x84, regvalue, cur_col, wrap)); | ||
912 | } | ||
913 | |||
914 | static const ahc_reg_parse_entry_t BUSTIME_parse_table[] = { | ||
915 | { "BON", 0x0f, 0x0f }, | ||
916 | { "BOFF", 0xf0, 0xf0 } | ||
917 | }; | ||
918 | |||
919 | int | ||
920 | ahc_bustime_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
921 | { | ||
922 | return (ahc_print_register(BUSTIME_parse_table, 2, "BUSTIME", | ||
923 | 0x85, regvalue, cur_col, wrap)); | ||
924 | } | ||
925 | |||
926 | static const ahc_reg_parse_entry_t DSCOMMAND1_parse_table[] = { | ||
927 | { "HADDLDSEL0", 0x01, 0x01 }, | ||
928 | { "HADDLDSEL1", 0x02, 0x02 }, | ||
929 | { "DSLATT", 0xfc, 0xfc } | ||
930 | }; | ||
931 | |||
932 | int | ||
933 | ahc_dscommand1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
934 | { | ||
935 | return (ahc_print_register(DSCOMMAND1_parse_table, 3, "DSCOMMAND1", | ||
936 | 0x85, regvalue, cur_col, wrap)); | ||
937 | } | ||
938 | |||
939 | static const ahc_reg_parse_entry_t BUSSPD_parse_table[] = { | ||
940 | { "STBON", 0x07, 0x07 }, | ||
941 | { "STBOFF", 0x38, 0x38 }, | ||
942 | { "DFTHRSH_75", 0x80, 0x80 }, | ||
943 | { "DFTHRSH", 0xc0, 0xc0 }, | ||
944 | { "DFTHRSH_100", 0xc0, 0xc0 } | ||
945 | }; | ||
946 | |||
947 | int | ||
948 | ahc_busspd_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
949 | { | ||
950 | return (ahc_print_register(BUSSPD_parse_table, 5, "BUSSPD", | ||
951 | 0x86, regvalue, cur_col, wrap)); | ||
952 | } | ||
953 | |||
954 | static const ahc_reg_parse_entry_t HS_MAILBOX_parse_table[] = { | ||
955 | { "SEQ_MAILBOX", 0x0f, 0x0f }, | ||
956 | { "HOST_TQINPOS", 0x80, 0x80 }, | ||
957 | { "HOST_MAILBOX", 0xf0, 0xf0 } | ||
958 | }; | ||
959 | |||
960 | int | ||
961 | ahc_hs_mailbox_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
962 | { | ||
963 | return (ahc_print_register(HS_MAILBOX_parse_table, 3, "HS_MAILBOX", | ||
964 | 0x86, regvalue, cur_col, wrap)); | ||
965 | } | ||
966 | |||
967 | static const ahc_reg_parse_entry_t DSPCISTATUS_parse_table[] = { | ||
968 | { "DFTHRSH_100", 0xc0, 0xc0 } | ||
969 | }; | ||
970 | |||
971 | int | ||
972 | ahc_dspcistatus_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
973 | { | ||
974 | return (ahc_print_register(DSPCISTATUS_parse_table, 1, "DSPCISTATUS", | ||
975 | 0x86, regvalue, cur_col, wrap)); | ||
976 | } | ||
977 | |||
978 | static const ahc_reg_parse_entry_t HCNTRL_parse_table[] = { | ||
979 | { "CHIPRST", 0x01, 0x01 }, | ||
980 | { "CHIPRSTACK", 0x01, 0x01 }, | ||
981 | { "INTEN", 0x02, 0x02 }, | ||
982 | { "PAUSE", 0x04, 0x04 }, | ||
983 | { "IRQMS", 0x08, 0x08 }, | ||
984 | { "SWINT", 0x10, 0x10 }, | ||
985 | { "POWRDN", 0x40, 0x40 } | ||
986 | }; | ||
987 | |||
988 | int | ||
989 | ahc_hcntrl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
990 | { | ||
991 | return (ahc_print_register(HCNTRL_parse_table, 7, "HCNTRL", | ||
992 | 0x87, regvalue, cur_col, wrap)); | ||
993 | } | ||
994 | |||
995 | int | ||
996 | ahc_haddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
997 | { | ||
998 | return (ahc_print_register(NULL, 0, "HADDR", | ||
999 | 0x88, regvalue, cur_col, wrap)); | ||
1000 | } | ||
1001 | |||
1002 | int | ||
1003 | ahc_hcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1004 | { | ||
1005 | return (ahc_print_register(NULL, 0, "HCNT", | ||
1006 | 0x8c, regvalue, cur_col, wrap)); | ||
1007 | } | ||
1008 | |||
1009 | int | ||
1010 | ahc_scbptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1011 | { | ||
1012 | return (ahc_print_register(NULL, 0, "SCBPTR", | ||
1013 | 0x90, regvalue, cur_col, wrap)); | ||
1014 | } | ||
1015 | |||
1016 | static const ahc_reg_parse_entry_t INTSTAT_parse_table[] = { | ||
1017 | { "SEQINT", 0x01, 0x01 }, | ||
1018 | { "CMDCMPLT", 0x02, 0x02 }, | ||
1019 | { "SCSIINT", 0x04, 0x04 }, | ||
1020 | { "BRKADRINT", 0x08, 0x08 }, | ||
1021 | { "BAD_PHASE", 0x01, 0x01 }, | ||
1022 | { "INT_PEND", 0x0f, 0x0f }, | ||
1023 | { "SEND_REJECT", 0x11, 0x11 }, | ||
1024 | { "PROTO_VIOLATION", 0x21, 0x21 }, | ||
1025 | { "NO_MATCH", 0x31, 0x31 }, | ||
1026 | { "IGN_WIDE_RES", 0x41, 0x41 }, | ||
1027 | { "PDATA_REINIT", 0x51, 0x51 }, | ||
1028 | { "HOST_MSG_LOOP", 0x61, 0x61 }, | ||
1029 | { "BAD_STATUS", 0x71, 0x71 }, | ||
1030 | { "PERR_DETECTED", 0x81, 0x81 }, | ||
1031 | { "DATA_OVERRUN", 0x91, 0x91 }, | ||
1032 | { "MKMSG_FAILED", 0xa1, 0xa1 }, | ||
1033 | { "MISSED_BUSFREE", 0xb1, 0xb1 }, | ||
1034 | { "SCB_MISMATCH", 0xc1, 0xc1 }, | ||
1035 | { "NO_FREE_SCB", 0xd1, 0xd1 }, | ||
1036 | { "OUT_OF_RANGE", 0xe1, 0xe1 }, | ||
1037 | { "SEQINT_MASK", 0xf1, 0xf1 } | ||
1038 | }; | ||
1039 | |||
1040 | int | ||
1041 | ahc_intstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1042 | { | ||
1043 | return (ahc_print_register(INTSTAT_parse_table, 21, "INTSTAT", | ||
1044 | 0x91, regvalue, cur_col, wrap)); | ||
1045 | } | ||
1046 | |||
1047 | static const ahc_reg_parse_entry_t CLRINT_parse_table[] = { | ||
1048 | { "CLRSEQINT", 0x01, 0x01 }, | ||
1049 | { "CLRCMDINT", 0x02, 0x02 }, | ||
1050 | { "CLRSCSIINT", 0x04, 0x04 }, | ||
1051 | { "CLRBRKADRINT", 0x08, 0x08 }, | ||
1052 | { "CLRPARERR", 0x10, 0x10 } | ||
1053 | }; | ||
1054 | |||
1055 | int | ||
1056 | ahc_clrint_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1057 | { | ||
1058 | return (ahc_print_register(CLRINT_parse_table, 5, "CLRINT", | ||
1059 | 0x92, regvalue, cur_col, wrap)); | ||
1060 | } | ||
1061 | |||
1062 | static const ahc_reg_parse_entry_t ERROR_parse_table[] = { | 283 | static const ahc_reg_parse_entry_t ERROR_parse_table[] = { |
1063 | { "ILLHADDR", 0x01, 0x01 }, | 284 | { "ILLHADDR", 0x01, 0x01 }, |
1064 | { "ILLSADDR", 0x02, 0x02 }, | 285 | { "ILLSADDR", 0x02, 0x02 }, |
@@ -1115,62 +336,6 @@ ahc_dfstatus_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1115 | 0x94, regvalue, cur_col, wrap)); | 336 | 0x94, regvalue, cur_col, wrap)); |
1116 | } | 337 | } |
1117 | 338 | ||
1118 | int | ||
1119 | ahc_dfwaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1120 | { | ||
1121 | return (ahc_print_register(NULL, 0, "DFWADDR", | ||
1122 | 0x95, regvalue, cur_col, wrap)); | ||
1123 | } | ||
1124 | |||
1125 | int | ||
1126 | ahc_dfdat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1127 | { | ||
1128 | return (ahc_print_register(NULL, 0, "DFDAT", | ||
1129 | 0x99, regvalue, cur_col, wrap)); | ||
1130 | } | ||
1131 | |||
1132 | static const ahc_reg_parse_entry_t SCBCNT_parse_table[] = { | ||
1133 | { "SCBAUTO", 0x80, 0x80 }, | ||
1134 | { "SCBCNT_MASK", 0x1f, 0x1f } | ||
1135 | }; | ||
1136 | |||
1137 | int | ||
1138 | ahc_scbcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1139 | { | ||
1140 | return (ahc_print_register(SCBCNT_parse_table, 2, "SCBCNT", | ||
1141 | 0x9a, regvalue, cur_col, wrap)); | ||
1142 | } | ||
1143 | |||
1144 | int | ||
1145 | ahc_qinfifo_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1146 | { | ||
1147 | return (ahc_print_register(NULL, 0, "QINFIFO", | ||
1148 | 0x9b, regvalue, cur_col, wrap)); | ||
1149 | } | ||
1150 | |||
1151 | int | ||
1152 | ahc_qoutfifo_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1153 | { | ||
1154 | return (ahc_print_register(NULL, 0, "QOUTFIFO", | ||
1155 | 0x9d, regvalue, cur_col, wrap)); | ||
1156 | } | ||
1157 | |||
1158 | static const ahc_reg_parse_entry_t CRCCONTROL1_parse_table[] = { | ||
1159 | { "TARGCRCCNTEN", 0x04, 0x04 }, | ||
1160 | { "TARGCRCENDEN", 0x08, 0x08 }, | ||
1161 | { "CRCREQCHKEN", 0x10, 0x10 }, | ||
1162 | { "CRCENDCHKEN", 0x20, 0x20 }, | ||
1163 | { "CRCVALCHKEN", 0x40, 0x40 }, | ||
1164 | { "CRCONSEEN", 0x80, 0x80 } | ||
1165 | }; | ||
1166 | |||
1167 | int | ||
1168 | ahc_crccontrol1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1169 | { | ||
1170 | return (ahc_print_register(CRCCONTROL1_parse_table, 6, "CRCCONTROL1", | ||
1171 | 0x9d, regvalue, cur_col, wrap)); | ||
1172 | } | ||
1173 | |||
1174 | static const ahc_reg_parse_entry_t SCSIPHASE_parse_table[] = { | 339 | static const ahc_reg_parse_entry_t SCSIPHASE_parse_table[] = { |
1175 | { "DATA_OUT_PHASE", 0x01, 0x01 }, | 340 | { "DATA_OUT_PHASE", 0x01, 0x01 }, |
1176 | { "DATA_IN_PHASE", 0x02, 0x02 }, | 341 | { "DATA_IN_PHASE", 0x02, 0x02 }, |
@@ -1188,17 +353,6 @@ ahc_scsiphase_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1188 | 0x9e, regvalue, cur_col, wrap)); | 353 | 0x9e, regvalue, cur_col, wrap)); |
1189 | } | 354 | } |
1190 | 355 | ||
1191 | static const ahc_reg_parse_entry_t SFUNCT_parse_table[] = { | ||
1192 | { "ALT_MODE", 0x80, 0x80 } | ||
1193 | }; | ||
1194 | |||
1195 | int | ||
1196 | ahc_sfunct_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1197 | { | ||
1198 | return (ahc_print_register(SFUNCT_parse_table, 1, "SFUNCT", | ||
1199 | 0x9f, regvalue, cur_col, wrap)); | ||
1200 | } | ||
1201 | |||
1202 | int | 356 | int |
1203 | ahc_scb_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | 357 | ahc_scb_base_print(u_int regvalue, u_int *cur_col, u_int wrap) |
1204 | { | 358 | { |
@@ -1206,80 +360,6 @@ ahc_scb_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1206 | 0xa0, regvalue, cur_col, wrap)); | 360 | 0xa0, regvalue, cur_col, wrap)); |
1207 | } | 361 | } |
1208 | 362 | ||
1209 | int | ||
1210 | ahc_scb_cdb_ptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1211 | { | ||
1212 | return (ahc_print_register(NULL, 0, "SCB_CDB_PTR", | ||
1213 | 0xa0, regvalue, cur_col, wrap)); | ||
1214 | } | ||
1215 | |||
1216 | int | ||
1217 | ahc_scb_residual_sgptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1218 | { | ||
1219 | return (ahc_print_register(NULL, 0, "SCB_RESIDUAL_SGPTR", | ||
1220 | 0xa4, regvalue, cur_col, wrap)); | ||
1221 | } | ||
1222 | |||
1223 | int | ||
1224 | ahc_scb_scsi_status_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1225 | { | ||
1226 | return (ahc_print_register(NULL, 0, "SCB_SCSI_STATUS", | ||
1227 | 0xa8, regvalue, cur_col, wrap)); | ||
1228 | } | ||
1229 | |||
1230 | int | ||
1231 | ahc_scb_target_phases_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1232 | { | ||
1233 | return (ahc_print_register(NULL, 0, "SCB_TARGET_PHASES", | ||
1234 | 0xa9, regvalue, cur_col, wrap)); | ||
1235 | } | ||
1236 | |||
1237 | int | ||
1238 | ahc_scb_target_data_dir_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1239 | { | ||
1240 | return (ahc_print_register(NULL, 0, "SCB_TARGET_DATA_DIR", | ||
1241 | 0xaa, regvalue, cur_col, wrap)); | ||
1242 | } | ||
1243 | |||
1244 | int | ||
1245 | ahc_scb_target_itag_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1246 | { | ||
1247 | return (ahc_print_register(NULL, 0, "SCB_TARGET_ITAG", | ||
1248 | 0xab, regvalue, cur_col, wrap)); | ||
1249 | } | ||
1250 | |||
1251 | int | ||
1252 | ahc_scb_dataptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1253 | { | ||
1254 | return (ahc_print_register(NULL, 0, "SCB_DATAPTR", | ||
1255 | 0xac, regvalue, cur_col, wrap)); | ||
1256 | } | ||
1257 | |||
1258 | static const ahc_reg_parse_entry_t SCB_DATACNT_parse_table[] = { | ||
1259 | { "SG_LAST_SEG", 0x80, 0x80 }, | ||
1260 | { "SG_HIGH_ADDR_BITS", 0x7f, 0x7f } | ||
1261 | }; | ||
1262 | |||
1263 | int | ||
1264 | ahc_scb_datacnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1265 | { | ||
1266 | return (ahc_print_register(SCB_DATACNT_parse_table, 2, "SCB_DATACNT", | ||
1267 | 0xb0, regvalue, cur_col, wrap)); | ||
1268 | } | ||
1269 | |||
1270 | static const ahc_reg_parse_entry_t SCB_SGPTR_parse_table[] = { | ||
1271 | { "SG_LIST_NULL", 0x01, 0x01 }, | ||
1272 | { "SG_FULL_RESID", 0x02, 0x02 }, | ||
1273 | { "SG_RESID_VALID", 0x04, 0x04 } | ||
1274 | }; | ||
1275 | |||
1276 | int | ||
1277 | ahc_scb_sgptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1278 | { | ||
1279 | return (ahc_print_register(SCB_SGPTR_parse_table, 3, "SCB_SGPTR", | ||
1280 | 0xb4, regvalue, cur_col, wrap)); | ||
1281 | } | ||
1282 | |||
1283 | static const ahc_reg_parse_entry_t SCB_CONTROL_parse_table[] = { | 363 | static const ahc_reg_parse_entry_t SCB_CONTROL_parse_table[] = { |
1284 | { "DISCONNECTED", 0x04, 0x04 }, | 364 | { "DISCONNECTED", 0x04, 0x04 }, |
1285 | { "ULTRAENB", 0x08, 0x08 }, | 365 | { "ULTRAENB", 0x08, 0x08 }, |
@@ -1331,248 +411,3 @@ ahc_scb_tag_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
1331 | 0xbb, regvalue, cur_col, wrap)); | 411 | 0xbb, regvalue, cur_col, wrap)); |
1332 | } | 412 | } |
1333 | 413 | ||
1334 | int | ||
1335 | ahc_scb_cdb_len_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1336 | { | ||
1337 | return (ahc_print_register(NULL, 0, "SCB_CDB_LEN", | ||
1338 | 0xbc, regvalue, cur_col, wrap)); | ||
1339 | } | ||
1340 | |||
1341 | int | ||
1342 | ahc_scb_scsirate_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1343 | { | ||
1344 | return (ahc_print_register(NULL, 0, "SCB_SCSIRATE", | ||
1345 | 0xbd, regvalue, cur_col, wrap)); | ||
1346 | } | ||
1347 | |||
1348 | int | ||
1349 | ahc_scb_scsioffset_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1350 | { | ||
1351 | return (ahc_print_register(NULL, 0, "SCB_SCSIOFFSET", | ||
1352 | 0xbe, regvalue, cur_col, wrap)); | ||
1353 | } | ||
1354 | |||
1355 | int | ||
1356 | ahc_scb_next_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1357 | { | ||
1358 | return (ahc_print_register(NULL, 0, "SCB_NEXT", | ||
1359 | 0xbf, regvalue, cur_col, wrap)); | ||
1360 | } | ||
1361 | |||
1362 | static const ahc_reg_parse_entry_t SEECTL_2840_parse_table[] = { | ||
1363 | { "DO_2840", 0x01, 0x01 }, | ||
1364 | { "CK_2840", 0x02, 0x02 }, | ||
1365 | { "CS_2840", 0x04, 0x04 } | ||
1366 | }; | ||
1367 | |||
1368 | int | ||
1369 | ahc_seectl_2840_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1370 | { | ||
1371 | return (ahc_print_register(SEECTL_2840_parse_table, 3, "SEECTL_2840", | ||
1372 | 0xc0, regvalue, cur_col, wrap)); | ||
1373 | } | ||
1374 | |||
1375 | static const ahc_reg_parse_entry_t STATUS_2840_parse_table[] = { | ||
1376 | { "DI_2840", 0x01, 0x01 }, | ||
1377 | { "EEPROM_TF", 0x80, 0x80 }, | ||
1378 | { "ADSEL", 0x1e, 0x1e }, | ||
1379 | { "BIOS_SEL", 0x60, 0x60 } | ||
1380 | }; | ||
1381 | |||
1382 | int | ||
1383 | ahc_status_2840_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1384 | { | ||
1385 | return (ahc_print_register(STATUS_2840_parse_table, 4, "STATUS_2840", | ||
1386 | 0xc1, regvalue, cur_col, wrap)); | ||
1387 | } | ||
1388 | |||
1389 | int | ||
1390 | ahc_scb_64_btt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1391 | { | ||
1392 | return (ahc_print_register(NULL, 0, "SCB_64_BTT", | ||
1393 | 0xd0, regvalue, cur_col, wrap)); | ||
1394 | } | ||
1395 | |||
1396 | int | ||
1397 | ahc_cchaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1398 | { | ||
1399 | return (ahc_print_register(NULL, 0, "CCHADDR", | ||
1400 | 0xe0, regvalue, cur_col, wrap)); | ||
1401 | } | ||
1402 | |||
1403 | int | ||
1404 | ahc_cchcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1405 | { | ||
1406 | return (ahc_print_register(NULL, 0, "CCHCNT", | ||
1407 | 0xe8, regvalue, cur_col, wrap)); | ||
1408 | } | ||
1409 | |||
1410 | int | ||
1411 | ahc_ccsgram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1412 | { | ||
1413 | return (ahc_print_register(NULL, 0, "CCSGRAM", | ||
1414 | 0xe9, regvalue, cur_col, wrap)); | ||
1415 | } | ||
1416 | |||
1417 | int | ||
1418 | ahc_ccsgaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1419 | { | ||
1420 | return (ahc_print_register(NULL, 0, "CCSGADDR", | ||
1421 | 0xea, regvalue, cur_col, wrap)); | ||
1422 | } | ||
1423 | |||
1424 | static const ahc_reg_parse_entry_t CCSGCTL_parse_table[] = { | ||
1425 | { "CCSGRESET", 0x01, 0x01 }, | ||
1426 | { "SG_FETCH_NEEDED", 0x02, 0x02 }, | ||
1427 | { "CCSGEN", 0x08, 0x08 }, | ||
1428 | { "CCSGDONE", 0x80, 0x80 } | ||
1429 | }; | ||
1430 | |||
1431 | int | ||
1432 | ahc_ccsgctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1433 | { | ||
1434 | return (ahc_print_register(CCSGCTL_parse_table, 4, "CCSGCTL", | ||
1435 | 0xeb, regvalue, cur_col, wrap)); | ||
1436 | } | ||
1437 | |||
1438 | int | ||
1439 | ahc_ccscbram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1440 | { | ||
1441 | return (ahc_print_register(NULL, 0, "CCSCBRAM", | ||
1442 | 0xec, regvalue, cur_col, wrap)); | ||
1443 | } | ||
1444 | |||
1445 | int | ||
1446 | ahc_ccscbaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1447 | { | ||
1448 | return (ahc_print_register(NULL, 0, "CCSCBADDR", | ||
1449 | 0xed, regvalue, cur_col, wrap)); | ||
1450 | } | ||
1451 | |||
1452 | static const ahc_reg_parse_entry_t CCSCBCTL_parse_table[] = { | ||
1453 | { "CCSCBRESET", 0x01, 0x01 }, | ||
1454 | { "CCSCBDIR", 0x04, 0x04 }, | ||
1455 | { "CCSCBEN", 0x08, 0x08 }, | ||
1456 | { "CCARREN", 0x10, 0x10 }, | ||
1457 | { "ARRDONE", 0x40, 0x40 }, | ||
1458 | { "CCSCBDONE", 0x80, 0x80 } | ||
1459 | }; | ||
1460 | |||
1461 | int | ||
1462 | ahc_ccscbctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1463 | { | ||
1464 | return (ahc_print_register(CCSCBCTL_parse_table, 6, "CCSCBCTL", | ||
1465 | 0xee, regvalue, cur_col, wrap)); | ||
1466 | } | ||
1467 | |||
1468 | int | ||
1469 | ahc_ccscbcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1470 | { | ||
1471 | return (ahc_print_register(NULL, 0, "CCSCBCNT", | ||
1472 | 0xef, regvalue, cur_col, wrap)); | ||
1473 | } | ||
1474 | |||
1475 | int | ||
1476 | ahc_scbbaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1477 | { | ||
1478 | return (ahc_print_register(NULL, 0, "SCBBADDR", | ||
1479 | 0xf0, regvalue, cur_col, wrap)); | ||
1480 | } | ||
1481 | |||
1482 | int | ||
1483 | ahc_ccscbptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1484 | { | ||
1485 | return (ahc_print_register(NULL, 0, "CCSCBPTR", | ||
1486 | 0xf1, regvalue, cur_col, wrap)); | ||
1487 | } | ||
1488 | |||
1489 | int | ||
1490 | ahc_hnscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1491 | { | ||
1492 | return (ahc_print_register(NULL, 0, "HNSCB_QOFF", | ||
1493 | 0xf4, regvalue, cur_col, wrap)); | ||
1494 | } | ||
1495 | |||
1496 | int | ||
1497 | ahc_snscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1498 | { | ||
1499 | return (ahc_print_register(NULL, 0, "SNSCB_QOFF", | ||
1500 | 0xf6, regvalue, cur_col, wrap)); | ||
1501 | } | ||
1502 | |||
1503 | int | ||
1504 | ahc_sdscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1505 | { | ||
1506 | return (ahc_print_register(NULL, 0, "SDSCB_QOFF", | ||
1507 | 0xf8, regvalue, cur_col, wrap)); | ||
1508 | } | ||
1509 | |||
1510 | static const ahc_reg_parse_entry_t QOFF_CTLSTA_parse_table[] = { | ||
1511 | { "SDSCB_ROLLOVER", 0x10, 0x10 }, | ||
1512 | { "SNSCB_ROLLOVER", 0x20, 0x20 }, | ||
1513 | { "SCB_AVAIL", 0x40, 0x40 }, | ||
1514 | { "SCB_QSIZE_256", 0x06, 0x06 }, | ||
1515 | { "SCB_QSIZE", 0x07, 0x07 } | ||
1516 | }; | ||
1517 | |||
1518 | int | ||
1519 | ahc_qoff_ctlsta_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1520 | { | ||
1521 | return (ahc_print_register(QOFF_CTLSTA_parse_table, 5, "QOFF_CTLSTA", | ||
1522 | 0xfa, regvalue, cur_col, wrap)); | ||
1523 | } | ||
1524 | |||
1525 | static const ahc_reg_parse_entry_t DFF_THRSH_parse_table[] = { | ||
1526 | { "RD_DFTHRSH_MIN", 0x00, 0x00 }, | ||
1527 | { "WR_DFTHRSH_MIN", 0x00, 0x00 }, | ||
1528 | { "RD_DFTHRSH_25", 0x01, 0x01 }, | ||
1529 | { "RD_DFTHRSH_50", 0x02, 0x02 }, | ||
1530 | { "RD_DFTHRSH_63", 0x03, 0x03 }, | ||
1531 | { "RD_DFTHRSH_75", 0x04, 0x04 }, | ||
1532 | { "RD_DFTHRSH_85", 0x05, 0x05 }, | ||
1533 | { "RD_DFTHRSH_90", 0x06, 0x06 }, | ||
1534 | { "RD_DFTHRSH", 0x07, 0x07 }, | ||
1535 | { "RD_DFTHRSH_MAX", 0x07, 0x07 }, | ||
1536 | { "WR_DFTHRSH_25", 0x10, 0x10 }, | ||
1537 | { "WR_DFTHRSH_50", 0x20, 0x20 }, | ||
1538 | { "WR_DFTHRSH_63", 0x30, 0x30 }, | ||
1539 | { "WR_DFTHRSH_75", 0x40, 0x40 }, | ||
1540 | { "WR_DFTHRSH_85", 0x50, 0x50 }, | ||
1541 | { "WR_DFTHRSH_90", 0x60, 0x60 }, | ||
1542 | { "WR_DFTHRSH", 0x70, 0x70 }, | ||
1543 | { "WR_DFTHRSH_MAX", 0x70, 0x70 } | ||
1544 | }; | ||
1545 | |||
1546 | int | ||
1547 | ahc_dff_thrsh_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1548 | { | ||
1549 | return (ahc_print_register(DFF_THRSH_parse_table, 18, "DFF_THRSH", | ||
1550 | 0xfb, regvalue, cur_col, wrap)); | ||
1551 | } | ||
1552 | |||
1553 | static const ahc_reg_parse_entry_t SG_CACHE_SHADOW_parse_table[] = { | ||
1554 | { "LAST_SEG_DONE", 0x01, 0x01 }, | ||
1555 | { "LAST_SEG", 0x02, 0x02 }, | ||
1556 | { "SG_ADDR_MASK", 0xf8, 0xf8 } | ||
1557 | }; | ||
1558 | |||
1559 | int | ||
1560 | ahc_sg_cache_shadow_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1561 | { | ||
1562 | return (ahc_print_register(SG_CACHE_SHADOW_parse_table, 3, "SG_CACHE_SHADOW", | ||
1563 | 0xfc, regvalue, cur_col, wrap)); | ||
1564 | } | ||
1565 | |||
1566 | static const ahc_reg_parse_entry_t SG_CACHE_PRE_parse_table[] = { | ||
1567 | { "LAST_SEG_DONE", 0x01, 0x01 }, | ||
1568 | { "LAST_SEG", 0x02, 0x02 }, | ||
1569 | { "SG_ADDR_MASK", 0xf8, 0xf8 } | ||
1570 | }; | ||
1571 | |||
1572 | int | ||
1573 | ahc_sg_cache_pre_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
1574 | { | ||
1575 | return (ahc_print_register(SG_CACHE_PRE_parse_table, 3, "SG_CACHE_PRE", | ||
1576 | 0xfc, regvalue, cur_col, wrap)); | ||
1577 | } | ||
1578 | |||
diff --git a/drivers/scsi/aic7xxx/aicasm/aicasm_gram.y b/drivers/scsi/aic7xxx/aicasm/aicasm_gram.y index 81be6a261cc8..e4064433842e 100644 --- a/drivers/scsi/aic7xxx/aicasm/aicasm_gram.y +++ b/drivers/scsi/aic7xxx/aicasm/aicasm_gram.y | |||
@@ -147,6 +147,8 @@ void yyerror(const char *string); | |||
147 | 147 | ||
148 | %token T_ACCESS_MODE | 148 | %token T_ACCESS_MODE |
149 | 149 | ||
150 | %token T_DONT_GENERATE_DEBUG_CODE | ||
151 | |||
150 | %token T_MODES | 152 | %token T_MODES |
151 | 153 | ||
152 | %token T_DEFINE | 154 | %token T_DEFINE |
@@ -357,6 +359,7 @@ reg_attribute: | |||
357 | | size | 359 | | size |
358 | | count | 360 | | count |
359 | | access_mode | 361 | | access_mode |
362 | | dont_generate_debug_code | ||
360 | | modes | 363 | | modes |
361 | | field_defn | 364 | | field_defn |
362 | | enum_defn | 365 | | enum_defn |
@@ -410,6 +413,13 @@ access_mode: | |||
410 | } | 413 | } |
411 | ; | 414 | ; |
412 | 415 | ||
416 | dont_generate_debug_code: | ||
417 | T_DONT_GENERATE_DEBUG_CODE | ||
418 | { | ||
419 | cur_symbol->dont_generate_debug_code = 1; | ||
420 | } | ||
421 | ; | ||
422 | |||
413 | modes: | 423 | modes: |
414 | T_MODES mode_list | 424 | T_MODES mode_list |
415 | { | 425 | { |
diff --git a/drivers/scsi/aic7xxx/aicasm/aicasm_scan.l b/drivers/scsi/aic7xxx/aicasm/aicasm_scan.l index 2c7f02daf88d..93c8667cd704 100644 --- a/drivers/scsi/aic7xxx/aicasm/aicasm_scan.l +++ b/drivers/scsi/aic7xxx/aicasm/aicasm_scan.l | |||
@@ -164,6 +164,7 @@ download { return T_DOWNLOAD; } | |||
164 | address { return T_ADDRESS; } | 164 | address { return T_ADDRESS; } |
165 | count { return T_COUNT; } | 165 | count { return T_COUNT; } |
166 | access_mode { return T_ACCESS_MODE; } | 166 | access_mode { return T_ACCESS_MODE; } |
167 | dont_generate_debug_code { return T_DONT_GENERATE_DEBUG_CODE; } | ||
167 | modes { return T_MODES; } | 168 | modes { return T_MODES; } |
168 | RW|RO|WO { | 169 | RW|RO|WO { |
169 | if (strcmp(yytext, "RW") == 0) | 170 | if (strcmp(yytext, "RW") == 0) |
diff --git a/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.c b/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.c index fcd357872b43..078ed600f47a 100644 --- a/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.c +++ b/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.c | |||
@@ -539,6 +539,9 @@ symtable_dump(FILE *ofile, FILE *dfile) | |||
539 | aic_print_include(dfile, stock_include_file); | 539 | aic_print_include(dfile, stock_include_file); |
540 | SLIST_FOREACH(curnode, ®isters, links) { | 540 | SLIST_FOREACH(curnode, ®isters, links) { |
541 | 541 | ||
542 | if (curnode->symbol->dont_generate_debug_code) | ||
543 | continue; | ||
544 | |||
542 | switch(curnode->symbol->type) { | 545 | switch(curnode->symbol->type) { |
543 | case REGISTER: | 546 | case REGISTER: |
544 | case SCBLOC: | 547 | case SCBLOC: |
diff --git a/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.h b/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.h index 05190c1a2fb7..2ba73ae7c777 100644 --- a/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.h +++ b/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.h | |||
@@ -137,7 +137,8 @@ typedef struct symbol { | |||
137 | struct label_info *linfo; | 137 | struct label_info *linfo; |
138 | struct cond_info *condinfo; | 138 | struct cond_info *condinfo; |
139 | struct macro_info *macroinfo; | 139 | struct macro_info *macroinfo; |
140 | }info; | 140 | } info; |
141 | int dont_generate_debug_code; | ||
141 | } symbol_t; | 142 | } symbol_t; |
142 | 143 | ||
143 | typedef struct symbol_ref { | 144 | typedef struct symbol_ref { |
diff --git a/drivers/scsi/device_handler/scsi_dh_rdac.c b/drivers/scsi/device_handler/scsi_dh_rdac.c index a43c3ed4df28..3d50cabca7ee 100644 --- a/drivers/scsi/device_handler/scsi_dh_rdac.c +++ b/drivers/scsi/device_handler/scsi_dh_rdac.c | |||
@@ -401,6 +401,9 @@ static int check_ownership(struct scsi_device *sdev, struct rdac_dh_data *h) | |||
401 | } | 401 | } |
402 | } | 402 | } |
403 | 403 | ||
404 | if (h->lun_state == RDAC_LUN_UNOWNED) | ||
405 | h->state = RDAC_STATE_PASSIVE; | ||
406 | |||
404 | return err; | 407 | return err; |
405 | } | 408 | } |
406 | 409 | ||
diff --git a/drivers/scsi/ipr.c b/drivers/scsi/ipr.c index 098739deb02e..ded854a6dd35 100644 --- a/drivers/scsi/ipr.c +++ b/drivers/scsi/ipr.c | |||
@@ -2456,20 +2456,14 @@ static ssize_t ipr_read_trace(struct kobject *kobj, | |||
2456 | struct Scsi_Host *shost = class_to_shost(dev); | 2456 | struct Scsi_Host *shost = class_to_shost(dev); |
2457 | struct ipr_ioa_cfg *ioa_cfg = (struct ipr_ioa_cfg *)shost->hostdata; | 2457 | struct ipr_ioa_cfg *ioa_cfg = (struct ipr_ioa_cfg *)shost->hostdata; |
2458 | unsigned long lock_flags = 0; | 2458 | unsigned long lock_flags = 0; |
2459 | int size = IPR_TRACE_SIZE; | 2459 | ssize_t ret; |
2460 | char *src = (char *)ioa_cfg->trace; | ||
2461 | |||
2462 | if (off > size) | ||
2463 | return 0; | ||
2464 | if (off + count > size) { | ||
2465 | size -= off; | ||
2466 | count = size; | ||
2467 | } | ||
2468 | 2460 | ||
2469 | spin_lock_irqsave(ioa_cfg->host->host_lock, lock_flags); | 2461 | spin_lock_irqsave(ioa_cfg->host->host_lock, lock_flags); |
2470 | memcpy(buf, &src[off], count); | 2462 | ret = memory_read_from_buffer(buf, count, &off, ioa_cfg->trace, |
2463 | IPR_TRACE_SIZE); | ||
2471 | spin_unlock_irqrestore(ioa_cfg->host->host_lock, lock_flags); | 2464 | spin_unlock_irqrestore(ioa_cfg->host->host_lock, lock_flags); |
2472 | return count; | 2465 | |
2466 | return ret; | ||
2473 | } | 2467 | } |
2474 | 2468 | ||
2475 | static struct bin_attribute ipr_trace_attr = { | 2469 | static struct bin_attribute ipr_trace_attr = { |
diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c index e5a9526d2037..f5d3b96890dc 100644 --- a/drivers/scsi/scsi_lib.c +++ b/drivers/scsi/scsi_lib.c | |||
@@ -529,6 +529,14 @@ static void scsi_single_lun_run(struct scsi_device *current_sdev) | |||
529 | spin_unlock_irqrestore(shost->host_lock, flags); | 529 | spin_unlock_irqrestore(shost->host_lock, flags); |
530 | } | 530 | } |
531 | 531 | ||
532 | static inline int scsi_device_is_busy(struct scsi_device *sdev) | ||
533 | { | ||
534 | if (sdev->device_busy >= sdev->queue_depth || sdev->device_blocked) | ||
535 | return 1; | ||
536 | |||
537 | return 0; | ||
538 | } | ||
539 | |||
532 | static inline int scsi_target_is_busy(struct scsi_target *starget) | 540 | static inline int scsi_target_is_busy(struct scsi_target *starget) |
533 | { | 541 | { |
534 | return ((starget->can_queue > 0 && | 542 | return ((starget->can_queue > 0 && |
@@ -536,6 +544,15 @@ static inline int scsi_target_is_busy(struct scsi_target *starget) | |||
536 | starget->target_blocked); | 544 | starget->target_blocked); |
537 | } | 545 | } |
538 | 546 | ||
547 | static inline int scsi_host_is_busy(struct Scsi_Host *shost) | ||
548 | { | ||
549 | if ((shost->can_queue > 0 && shost->host_busy >= shost->can_queue) || | ||
550 | shost->host_blocked || shost->host_self_blocked) | ||
551 | return 1; | ||
552 | |||
553 | return 0; | ||
554 | } | ||
555 | |||
539 | /* | 556 | /* |
540 | * Function: scsi_run_queue() | 557 | * Function: scsi_run_queue() |
541 | * | 558 | * |
@@ -558,11 +575,7 @@ static void scsi_run_queue(struct request_queue *q) | |||
558 | scsi_single_lun_run(sdev); | 575 | scsi_single_lun_run(sdev); |
559 | 576 | ||
560 | spin_lock_irqsave(shost->host_lock, flags); | 577 | spin_lock_irqsave(shost->host_lock, flags); |
561 | while (!list_empty(&shost->starved_list) && | 578 | while (!list_empty(&shost->starved_list) && !scsi_host_is_busy(shost)) { |
562 | !shost->host_blocked && !shost->host_self_blocked && | ||
563 | !((shost->can_queue > 0) && | ||
564 | (shost->host_busy >= shost->can_queue))) { | ||
565 | |||
566 | int flagset; | 579 | int flagset; |
567 | 580 | ||
568 | /* | 581 | /* |
@@ -1348,8 +1361,6 @@ int scsi_prep_fn(struct request_queue *q, struct request *req) | |||
1348 | static inline int scsi_dev_queue_ready(struct request_queue *q, | 1361 | static inline int scsi_dev_queue_ready(struct request_queue *q, |
1349 | struct scsi_device *sdev) | 1362 | struct scsi_device *sdev) |
1350 | { | 1363 | { |
1351 | if (sdev->device_busy >= sdev->queue_depth) | ||
1352 | return 0; | ||
1353 | if (sdev->device_busy == 0 && sdev->device_blocked) { | 1364 | if (sdev->device_busy == 0 && sdev->device_blocked) { |
1354 | /* | 1365 | /* |
1355 | * unblock after device_blocked iterates to zero | 1366 | * unblock after device_blocked iterates to zero |
@@ -1363,7 +1374,7 @@ static inline int scsi_dev_queue_ready(struct request_queue *q, | |||
1363 | return 0; | 1374 | return 0; |
1364 | } | 1375 | } |
1365 | } | 1376 | } |
1366 | if (sdev->device_blocked) | 1377 | if (scsi_device_is_busy(sdev)) |
1367 | return 0; | 1378 | return 0; |
1368 | 1379 | ||
1369 | return 1; | 1380 | return 1; |
@@ -1440,8 +1451,7 @@ static inline int scsi_host_queue_ready(struct request_queue *q, | |||
1440 | return 0; | 1451 | return 0; |
1441 | } | 1452 | } |
1442 | } | 1453 | } |
1443 | if ((shost->can_queue > 0 && shost->host_busy >= shost->can_queue) || | 1454 | if (scsi_host_is_busy(shost)) { |
1444 | shost->host_blocked || shost->host_self_blocked) { | ||
1445 | if (list_empty(&sdev->starved_entry)) | 1455 | if (list_empty(&sdev->starved_entry)) |
1446 | list_add_tail(&sdev->starved_entry, &shost->starved_list); | 1456 | list_add_tail(&sdev->starved_entry, &shost->starved_list); |
1447 | return 0; | 1457 | return 0; |
@@ -1455,6 +1465,37 @@ static inline int scsi_host_queue_ready(struct request_queue *q, | |||
1455 | } | 1465 | } |
1456 | 1466 | ||
1457 | /* | 1467 | /* |
1468 | * Busy state exporting function for request stacking drivers. | ||
1469 | * | ||
1470 | * For efficiency, no lock is taken to check the busy state of | ||
1471 | * shost/starget/sdev, since the returned value is not guaranteed and | ||
1472 | * may be changed after request stacking drivers call the function, | ||
1473 | * regardless of taking lock or not. | ||
1474 | * | ||
1475 | * When scsi can't dispatch I/Os anymore and needs to kill I/Os | ||
1476 | * (e.g. !sdev), scsi needs to return 'not busy'. | ||
1477 | * Otherwise, request stacking drivers may hold requests forever. | ||
1478 | */ | ||
1479 | static int scsi_lld_busy(struct request_queue *q) | ||
1480 | { | ||
1481 | struct scsi_device *sdev = q->queuedata; | ||
1482 | struct Scsi_Host *shost; | ||
1483 | struct scsi_target *starget; | ||
1484 | |||
1485 | if (!sdev) | ||
1486 | return 0; | ||
1487 | |||
1488 | shost = sdev->host; | ||
1489 | starget = scsi_target(sdev); | ||
1490 | |||
1491 | if (scsi_host_in_recovery(shost) || scsi_host_is_busy(shost) || | ||
1492 | scsi_target_is_busy(starget) || scsi_device_is_busy(sdev)) | ||
1493 | return 1; | ||
1494 | |||
1495 | return 0; | ||
1496 | } | ||
1497 | |||
1498 | /* | ||
1458 | * Kill a request for a dead device | 1499 | * Kill a request for a dead device |
1459 | */ | 1500 | */ |
1460 | static void scsi_kill_request(struct request *req, struct request_queue *q) | 1501 | static void scsi_kill_request(struct request *req, struct request_queue *q) |
@@ -1757,6 +1798,7 @@ struct request_queue *scsi_alloc_queue(struct scsi_device *sdev) | |||
1757 | blk_queue_prep_rq(q, scsi_prep_fn); | 1798 | blk_queue_prep_rq(q, scsi_prep_fn); |
1758 | blk_queue_softirq_done(q, scsi_softirq_done); | 1799 | blk_queue_softirq_done(q, scsi_softirq_done); |
1759 | blk_queue_rq_timed_out(q, scsi_times_out); | 1800 | blk_queue_rq_timed_out(q, scsi_times_out); |
1801 | blk_queue_lld_busy(q, scsi_lld_busy); | ||
1760 | return q; | 1802 | return q; |
1761 | } | 1803 | } |
1762 | 1804 | ||
@@ -2105,22 +2147,21 @@ scsi_test_unit_ready(struct scsi_device *sdev, int timeout, int retries, | |||
2105 | do { | 2147 | do { |
2106 | result = scsi_execute_req(sdev, cmd, DMA_NONE, NULL, 0, sshdr, | 2148 | result = scsi_execute_req(sdev, cmd, DMA_NONE, NULL, 0, sshdr, |
2107 | timeout, retries); | 2149 | timeout, retries); |
2108 | } while ((driver_byte(result) & DRIVER_SENSE) && | 2150 | if (sdev->removable && scsi_sense_valid(sshdr) && |
2109 | sshdr && sshdr->sense_key == UNIT_ATTENTION && | 2151 | sshdr->sense_key == UNIT_ATTENTION) |
2110 | --retries); | 2152 | sdev->changed = 1; |
2153 | } while (scsi_sense_valid(sshdr) && | ||
2154 | sshdr->sense_key == UNIT_ATTENTION && --retries); | ||
2111 | 2155 | ||
2112 | if (!sshdr) | 2156 | if (!sshdr) |
2113 | /* could not allocate sense buffer, so can't process it */ | 2157 | /* could not allocate sense buffer, so can't process it */ |
2114 | return result; | 2158 | return result; |
2115 | 2159 | ||
2116 | if ((driver_byte(result) & DRIVER_SENSE) && sdev->removable) { | 2160 | if (sdev->removable && scsi_sense_valid(sshdr) && |
2117 | 2161 | (sshdr->sense_key == UNIT_ATTENTION || | |
2118 | if ((scsi_sense_valid(sshdr)) && | 2162 | sshdr->sense_key == NOT_READY)) { |
2119 | ((sshdr->sense_key == UNIT_ATTENTION) || | 2163 | sdev->changed = 1; |
2120 | (sshdr->sense_key == NOT_READY))) { | 2164 | result = 0; |
2121 | sdev->changed = 1; | ||
2122 | result = 0; | ||
2123 | } | ||
2124 | } | 2165 | } |
2125 | if (!sshdr_external) | 2166 | if (!sshdr_external) |
2126 | kfree(sshdr); | 2167 | kfree(sshdr); |
diff --git a/drivers/scsi/scsi_netlink.c b/drivers/scsi/scsi_netlink.c index b37e133de805..723fdecd91bd 100644 --- a/drivers/scsi/scsi_netlink.c +++ b/drivers/scsi/scsi_netlink.c | |||
@@ -205,16 +205,13 @@ static struct notifier_block scsi_netlink_notifier = { | |||
205 | }; | 205 | }; |
206 | 206 | ||
207 | 207 | ||
208 | /** | 208 | /* |
209 | * GENERIC SCSI transport receive and event handlers | 209 | * GENERIC SCSI transport receive and event handlers |
210 | **/ | 210 | */ |
211 | 211 | ||
212 | /** | 212 | /** |
213 | * scsi_generic_msg_handler - receive message handler for GENERIC transport | 213 | * scsi_generic_msg_handler - receive message handler for GENERIC transport messages |
214 | * messages | ||
215 | * | ||
216 | * @skb: socket receive buffer | 214 | * @skb: socket receive buffer |
217 | * | ||
218 | **/ | 215 | **/ |
219 | static int | 216 | static int |
220 | scsi_generic_msg_handler(struct sk_buff *skb) | 217 | scsi_generic_msg_handler(struct sk_buff *skb) |
diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c index 43f34c73df12..c9e1242eaf25 100644 --- a/drivers/scsi/sd.c +++ b/drivers/scsi/sd.c | |||
@@ -1049,7 +1049,6 @@ static int sd_done(struct scsi_cmnd *SCpnt) | |||
1049 | good_bytes = sd_completed_bytes(SCpnt); | 1049 | good_bytes = sd_completed_bytes(SCpnt); |
1050 | break; | 1050 | break; |
1051 | case RECOVERED_ERROR: | 1051 | case RECOVERED_ERROR: |
1052 | case NO_SENSE: | ||
1053 | /* Inform the user, but make sure that it's not treated | 1052 | /* Inform the user, but make sure that it's not treated |
1054 | * as a hard error. | 1053 | * as a hard error. |
1055 | */ | 1054 | */ |
@@ -1058,6 +1057,15 @@ static int sd_done(struct scsi_cmnd *SCpnt) | |||
1058 | memset(SCpnt->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); | 1057 | memset(SCpnt->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); |
1059 | good_bytes = scsi_bufflen(SCpnt); | 1058 | good_bytes = scsi_bufflen(SCpnt); |
1060 | break; | 1059 | break; |
1060 | case NO_SENSE: | ||
1061 | /* This indicates a false check condition, so ignore it. An | ||
1062 | * unknown amount of data was transferred so treat it as an | ||
1063 | * error. | ||
1064 | */ | ||
1065 | scsi_print_sense("sd", SCpnt); | ||
1066 | SCpnt->result = 0; | ||
1067 | memset(SCpnt->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); | ||
1068 | break; | ||
1061 | case ABORTED_COMMAND: | 1069 | case ABORTED_COMMAND: |
1062 | if (sshdr.asc == 0x10) { /* DIF: Disk detected corruption */ | 1070 | if (sshdr.asc == 0x10) { /* DIF: Disk detected corruption */ |
1063 | scsi_print_result(SCpnt); | 1071 | scsi_print_result(SCpnt); |
@@ -1071,15 +1079,6 @@ static int sd_done(struct scsi_cmnd *SCpnt) | |||
1071 | scsi_print_sense("sd", SCpnt); | 1079 | scsi_print_sense("sd", SCpnt); |
1072 | good_bytes = sd_completed_bytes(SCpnt); | 1080 | good_bytes = sd_completed_bytes(SCpnt); |
1073 | } | 1081 | } |
1074 | if (!scsi_device_protection(SCpnt->device) && | ||
1075 | SCpnt->device->use_10_for_rw && | ||
1076 | (SCpnt->cmnd[0] == READ_10 || | ||
1077 | SCpnt->cmnd[0] == WRITE_10)) | ||
1078 | SCpnt->device->use_10_for_rw = 0; | ||
1079 | if (SCpnt->device->use_10_for_ms && | ||
1080 | (SCpnt->cmnd[0] == MODE_SENSE_10 || | ||
1081 | SCpnt->cmnd[0] == MODE_SELECT_10)) | ||
1082 | SCpnt->device->use_10_for_ms = 0; | ||
1083 | break; | 1082 | break; |
1084 | default: | 1083 | default: |
1085 | break; | 1084 | break; |
@@ -1432,7 +1431,7 @@ got_data: | |||
1432 | 1431 | ||
1433 | { | 1432 | { |
1434 | char cap_str_2[10], cap_str_10[10]; | 1433 | char cap_str_2[10], cap_str_10[10]; |
1435 | u64 sz = sdkp->capacity << ffz(~sector_size); | 1434 | u64 sz = (u64)sdkp->capacity << ilog2(sector_size); |
1436 | 1435 | ||
1437 | string_get_size(sz, STRING_UNITS_2, cap_str_2, | 1436 | string_get_size(sz, STRING_UNITS_2, cap_str_2, |
1438 | sizeof(cap_str_2)); | 1437 | sizeof(cap_str_2)); |
diff --git a/drivers/scsi/sun3x_esp.c b/drivers/scsi/sun3x_esp.c index 7514b3a0390e..34a99620e5bd 100644 --- a/drivers/scsi/sun3x_esp.c +++ b/drivers/scsi/sun3x_esp.c | |||
@@ -213,7 +213,7 @@ static int __devinit esp_sun3x_probe(struct platform_device *dev) | |||
213 | esp->ops = &sun3x_esp_ops; | 213 | esp->ops = &sun3x_esp_ops; |
214 | 214 | ||
215 | res = platform_get_resource(dev, IORESOURCE_MEM, 0); | 215 | res = platform_get_resource(dev, IORESOURCE_MEM, 0); |
216 | if (!res && !res->start) | 216 | if (!res || !res->start) |
217 | goto fail_unlink; | 217 | goto fail_unlink; |
218 | 218 | ||
219 | esp->regs = ioremap_nocache(res->start, 0x20); | 219 | esp->regs = ioremap_nocache(res->start, 0x20); |
@@ -221,7 +221,7 @@ static int __devinit esp_sun3x_probe(struct platform_device *dev) | |||
221 | goto fail_unmap_regs; | 221 | goto fail_unmap_regs; |
222 | 222 | ||
223 | res = platform_get_resource(dev, IORESOURCE_MEM, 1); | 223 | res = platform_get_resource(dev, IORESOURCE_MEM, 1); |
224 | if (!res && !res->start) | 224 | if (!res || !res->start) |
225 | goto fail_unmap_regs; | 225 | goto fail_unmap_regs; |
226 | 226 | ||
227 | esp->dma_regs = ioremap_nocache(res->start, 0x10); | 227 | esp->dma_regs = ioremap_nocache(res->start, 0x10); |
diff --git a/drivers/staging/Kconfig b/drivers/staging/Kconfig index c4eff44c9f27..e1654f59eb70 100644 --- a/drivers/staging/Kconfig +++ b/drivers/staging/Kconfig | |||
@@ -43,8 +43,6 @@ source "drivers/staging/echo/Kconfig" | |||
43 | 43 | ||
44 | source "drivers/staging/at76_usb/Kconfig" | 44 | source "drivers/staging/at76_usb/Kconfig" |
45 | 45 | ||
46 | source "drivers/staging/pcc-acpi/Kconfig" | ||
47 | |||
48 | source "drivers/staging/poch/Kconfig" | 46 | source "drivers/staging/poch/Kconfig" |
49 | 47 | ||
50 | endif # STAGING | 48 | endif # STAGING |
diff --git a/drivers/staging/Makefile b/drivers/staging/Makefile index 7cb8701d96d4..71c4d53760b8 100644 --- a/drivers/staging/Makefile +++ b/drivers/staging/Makefile | |||
@@ -13,5 +13,4 @@ obj-$(CONFIG_W35UND) += winbond/ | |||
13 | obj-$(CONFIG_PRISM2_USB) += wlan-ng/ | 13 | obj-$(CONFIG_PRISM2_USB) += wlan-ng/ |
14 | obj-$(CONFIG_ECHO) += echo/ | 14 | obj-$(CONFIG_ECHO) += echo/ |
15 | obj-$(CONFIG_USB_ATMEL) += at76_usb/ | 15 | obj-$(CONFIG_USB_ATMEL) += at76_usb/ |
16 | obj-$(CONFIG_PCC_ACPI) += pcc-acpi/ | ||
17 | obj-$(CONFIG_POCH) += poch/ | 16 | obj-$(CONFIG_POCH) += poch/ |
diff --git a/drivers/staging/pcc-acpi/Kconfig b/drivers/staging/pcc-acpi/Kconfig deleted file mode 100644 index 6720d4086baf..000000000000 --- a/drivers/staging/pcc-acpi/Kconfig +++ /dev/null | |||
@@ -1,11 +0,0 @@ | |||
1 | config PCC_ACPI | ||
2 | tristate "Panasonic ACPI Hotkey support" | ||
3 | depends on ACPI | ||
4 | default n | ||
5 | ---help--- | ||
6 | This driver provides support for Panasonic hotkeys through the | ||
7 | ACPI interface. This works for the Panasonic R1 (N variant), | ||
8 | R2, R3, T2, W2, and Y2 laptops. | ||
9 | |||
10 | To compile this driver as a module, choose M here. The module | ||
11 | will be called pcc-acpi. | ||
diff --git a/drivers/staging/pcc-acpi/Makefile b/drivers/staging/pcc-acpi/Makefile deleted file mode 100644 index f93b29edf61e..000000000000 --- a/drivers/staging/pcc-acpi/Makefile +++ /dev/null | |||
@@ -1 +0,0 @@ | |||
1 | obj-$(CONFIG_PCC_ACPI) += pcc-acpi.o | ||
diff --git a/drivers/staging/pcc-acpi/TODO b/drivers/staging/pcc-acpi/TODO deleted file mode 100644 index fab240982286..000000000000 --- a/drivers/staging/pcc-acpi/TODO +++ /dev/null | |||
@@ -1,7 +0,0 @@ | |||
1 | TODO: | ||
2 | - Lindent fixes | ||
3 | - checkpatch.pl fixes | ||
4 | - verify that the acpi interface is correct | ||
5 | - remove /proc dependancy if needed (not sure yet.) | ||
6 | |||
7 | Please send any patches for this driver to Greg Kroah-Hartman <greg@kroah.com> | ||
diff --git a/drivers/staging/pcc-acpi/pcc-acpi.c b/drivers/staging/pcc-acpi/pcc-acpi.c deleted file mode 100644 index 3b34a3e4885a..000000000000 --- a/drivers/staging/pcc-acpi/pcc-acpi.c +++ /dev/null | |||
@@ -1,1111 +0,0 @@ | |||
1 | /* | ||
2 | * Panasonic HotKey and lcd brightness control Extra driver | ||
3 | * (C) 2004 Hiroshi Miura <miura@da-cha.org> | ||
4 | * (C) 2004 NTT DATA Intellilink Co. http://www.intellilink.co.jp/ | ||
5 | * (C) YOKOTA Hiroshi <yokota (at) netlab. is. tsukuba. ac. jp> | ||
6 | * (C) 2004 David Bronaugh <dbronaugh> | ||
7 | * | ||
8 | * derived from toshiba_acpi.c, Copyright (C) 2002-2004 John Belmonte | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License version 2 as | ||
12 | * publicshed by the Free Software Foundation. | ||
13 | * | ||
14 | * This program is distributed in the hope that it will be useful, | ||
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
17 | * GNU General Public License for more details. | ||
18 | * | ||
19 | * You should have received a copy of the GNU General Public License | ||
20 | * along with this program; if not, write to the Free Software | ||
21 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
22 | * | ||
23 | *--------------------------------------------------------------------------- | ||
24 | * | ||
25 | * ChangeLog: | ||
26 | * | ||
27 | * Nov.04, 2006 Hiroshi Miura <miura@da-cha.org> | ||
28 | * -v0.9 remove warning about section reference. | ||
29 | * remove acpi_os_free | ||
30 | * add /proc/acpi/pcc/brightness interface to | ||
31 | * allow HAL to access. | ||
32 | * merge dbronaugh's enhancement | ||
33 | * Aug.17, 2004 David Bronaugh (dbronaugh) | ||
34 | * - Added screen brightness setting interface | ||
35 | * Thanks to the FreeBSD crew | ||
36 | * (acpi_panasonic.c authors) | ||
37 | * for the ideas I needed to accomplish it | ||
38 | * | ||
39 | * May.29, 2006 Hiroshi Miura <miura@da-cha.org> | ||
40 | * -v0.8.4 follow to change keyinput structure | ||
41 | * thanks Fabian Yamaguchi <fabs@cs.tu-berlin.de>, | ||
42 | * Jacob Bower <jacob.bower@ic.ac.uk> and | ||
43 | * Hiroshi Yokota for providing solutions. | ||
44 | * | ||
45 | * Oct.02, 2004 Hiroshi Miura <miura@da-cha.org> | ||
46 | * -v0.8.2 merge code of YOKOTA Hiroshi | ||
47 | * <yokota@netlab.is.tsukuba.ac.jp>. | ||
48 | * Add sticky key mode interface. | ||
49 | * Refactoring acpi_pcc_generete_keyinput(). | ||
50 | * | ||
51 | * Sep.15, 2004 Hiroshi Miura <miura@da-cha.org> | ||
52 | * -v0.8 Generate key input event on input subsystem. | ||
53 | * This is based on yet another driver | ||
54 | * written by Ryuta Nakanishi. | ||
55 | * | ||
56 | * Sep.10, 2004 Hiroshi Miura <miura@da-cha.org> | ||
57 | * -v0.7 Change proc interface functions using seq_file | ||
58 | * facility as same as other ACPI drivers. | ||
59 | * | ||
60 | * Aug.28, 2004 Hiroshi Miura <miura@da-cha.org> | ||
61 | * -v0.6.4 Fix a silly error with status checking | ||
62 | * | ||
63 | * Aug.25, 2004 Hiroshi Miura <miura@da-cha.org> | ||
64 | * -v0.6.3 replace read_acpi_int by standard | ||
65 | * function acpi_evaluate_integer | ||
66 | * some clean up and make smart copyright notice. | ||
67 | * fix return value of pcc_acpi_get_key() | ||
68 | * fix checking return value of acpi_bus_register_driver() | ||
69 | * | ||
70 | * Aug.22, 2004 David Bronaugh <dbronaugh@linuxboxen.org> | ||
71 | * -v0.6.2 Add check on ACPI data (num_sifr) | ||
72 | * Coding style cleanups, better error messages/handling | ||
73 | * Fixed an off-by-one error in memory allocation | ||
74 | * | ||
75 | * Aug.21, 2004 David Bronaugh <dbronaugh@linuxboxen.org> | ||
76 | * -v0.6.1 Fix a silly error with status checking | ||
77 | * | ||
78 | * Aug.20, 2004 David Bronaugh <dbronaugh@linuxboxen.org> | ||
79 | * - v0.6 Correct brightness controls to reflect reality | ||
80 | * based on information gleaned by Hiroshi Miura | ||
81 | * and discussions with Hiroshi Miura | ||
82 | * | ||
83 | * Aug.10, 2004 Hiroshi Miura <miura@da-cha.org> | ||
84 | * - v0.5 support LCD brightness control | ||
85 | * based on the disclosed information by MEI. | ||
86 | * | ||
87 | * Jul.25, 2004 Hiroshi Miura <miura@da-cha.org> | ||
88 | * - v0.4 first post version | ||
89 | * add function to retrive SIFR | ||
90 | * | ||
91 | * Jul.24, 2004 Hiroshi Miura <miura@da-cha.org> | ||
92 | * - v0.3 get proper status of hotkey | ||
93 | * | ||
94 | * Jul.22, 2004 Hiroshi Miura <miura@da-cha.org> | ||
95 | * - v0.2 add HotKey handler | ||
96 | * | ||
97 | * Jul.17, 2004 Hiroshi Miura <miura@da-cha.org> | ||
98 | * - v0.1 start from toshiba_acpi driver written by John Belmonte | ||
99 | * | ||
100 | */ | ||
101 | |||
102 | #define ACPI_PCC_VERSION "0.9+hy" | ||
103 | |||
104 | #include <linux/kernel.h> | ||
105 | #include <linux/module.h> | ||
106 | #include <linux/types.h> | ||
107 | #include <linux/ctype.h> | ||
108 | #include <linux/init.h> | ||
109 | #include <linux/input.h> | ||
110 | #include <linux/proc_fs.h> | ||
111 | #include <linux/seq_file.h> | ||
112 | #include <linux/slab.h> | ||
113 | #include <linux/uaccess.h> | ||
114 | #include <acpi/acpi_bus.h> | ||
115 | #include <acpi/acpi_drivers.h> | ||
116 | |||
117 | |||
118 | /************************************************************************* | ||
119 | * "seq" file template definition. | ||
120 | */ | ||
121 | /* "seq" initializer */ | ||
122 | #define SEQ_OPEN_FS(_open_func_name_, _show_func_name_) \ | ||
123 | static int _open_func_name_(struct inode *inode, struct file *file) \ | ||
124 | { \ | ||
125 | return single_open(file, _show_func_name_, PDE(inode)->data); \ | ||
126 | } | ||
127 | |||
128 | /*------------------------------------------------------------------------- | ||
129 | * "seq" fops template for read-only files. | ||
130 | */ | ||
131 | #define SEQ_FILEOPS_R(_open_func_name_) \ | ||
132 | { \ | ||
133 | .open = _open_func_name_, \ | ||
134 | .read = seq_read, \ | ||
135 | .llseek = seq_lseek, \ | ||
136 | .release = single_release, \ | ||
137 | } | ||
138 | |||
139 | /*------------------------------------------------------------------------ | ||
140 | * "seq" fops template for read-write files. | ||
141 | */ | ||
142 | #define SEQ_FILEOPS_RW(_open_func_name_, _write_func_name_) \ | ||
143 | { \ | ||
144 | .open = _open_func_name_ , \ | ||
145 | .read = seq_read, \ | ||
146 | .write = _write_func_name_, \ | ||
147 | .llseek = seq_lseek, \ | ||
148 | .release = single_release, \ | ||
149 | } | ||
150 | |||
151 | /* | ||
152 | * "seq" file template definition ended. | ||
153 | *************************************************************************** | ||
154 | */ | ||
155 | #ifndef ACPI_HOTKEY_COMPONENT | ||
156 | #define ACPI_HOTKEY_COMPONENT 0x10000000 | ||
157 | #endif | ||
158 | |||
159 | #define _COMPONENT ACPI_HOTKEY_COMPONENT | ||
160 | ACPI_MODULE_NAME("pcc_acpi"); | ||
161 | |||
162 | MODULE_AUTHOR("Hiroshi Miura, Hiroshi Yokota"); | ||
163 | MODULE_DESCRIPTION("ACPI HotKey driver for Panasonic Let's Note laptops"); | ||
164 | MODULE_LICENSE("GPL"); | ||
165 | |||
166 | #define LOGPREFIX "pcc_acpi: " | ||
167 | |||
168 | /**************************************************** | ||
169 | * Define ACPI PATHs | ||
170 | ****************************************************/ | ||
171 | /* Lets note hotkeys */ | ||
172 | #define METHOD_HKEY_QUERY "HINF" | ||
173 | #define METHOD_HKEY_SQTY "SQTY" | ||
174 | #define METHOD_HKEY_SINF "SINF" | ||
175 | #define METHOD_HKEY_SSET "SSET" | ||
176 | #define HKEY_NOTIFY 0x80 | ||
177 | |||
178 | /* for brightness control */ | ||
179 | #define LCD_MAX_BRIGHTNESS 255 | ||
180 | /* This may be magical -- beware */ | ||
181 | #define LCD_BRIGHTNESS_INCREMENT 17 | ||
182 | /* Registers of SINF */ | ||
183 | #define SINF_LCD_BRIGHTNESS 4 | ||
184 | |||
185 | /******************************************************************* | ||
186 | * | ||
187 | * definitions for /proc/ interface | ||
188 | * | ||
189 | *******************************************************************/ | ||
190 | #define ACPI_PCC_DRIVER_NAME "pcc_acpi" | ||
191 | #define ACPI_PCC_DEVICE_NAME "PCCExtra" | ||
192 | #define ACPI_PCC_CLASS "pcc" | ||
193 | #define PROC_PCC ACPI_PCC_CLASS | ||
194 | |||
195 | #define ACPI_PCC_INPUT_PHYS "panasonic/hkey0" | ||
196 | |||
197 | /* This is transitional definition */ | ||
198 | #ifndef KEY_BATT | ||
199 | # define KEY_BATT 227 | ||
200 | #endif | ||
201 | |||
202 | #define PROC_STR_MAX_LEN 8 | ||
203 | |||
204 | #define BUS_PCC_HOTKEY BUS_I8042 /*0x1a*/ /* FIXME: BUS_I8042? */ | ||
205 | |||
206 | /* Fn+F4/F5 confricts with Shift+F1/F2 */ | ||
207 | /* This hack avoids key number confrict */ | ||
208 | #define PCC_KEYINPUT_MODE (0) | ||
209 | |||
210 | /* LCD_TYPEs: 0 = Normal, 1 = Semi-transparent | ||
211 | ENV_STATEs: Normal temp=0x01, High temp=0x81, N/A=0x00 | ||
212 | */ | ||
213 | enum SINF_BITS { SINF_NUM_BATTERIES = 0, | ||
214 | SINF_LCD_TYPE, | ||
215 | SINF_AC_MAX_BRIGHT, | ||
216 | SINF_AC_MIN_BRIGHT, | ||
217 | SINF_AC_CUR_BRIGHT, | ||
218 | /* 4 = R1 only handle SINF_AC_CUR_BRIGHT | ||
219 | * as SINF_CUR_BRIGHT and don't know AC state */ | ||
220 | SINF_DC_MAX_BRIGHT, | ||
221 | SINF_DC_MIN_BRIGHT, | ||
222 | SINF_DC_CUR_BRIGHT, | ||
223 | SINF_MUTE, | ||
224 | SINF_RESERVED, | ||
225 | SINF_ENV_STATE, /* 10 */ | ||
226 | SINF_STICKY_KEY = 0x80, | ||
227 | }; | ||
228 | |||
229 | static struct acpi_device_id pcc_device_ids[] = { | ||
230 | {"MAT0012", 0}, | ||
231 | {"MAT0013", 0}, | ||
232 | {"MAT0018", 0}, | ||
233 | {"MAT0019", 0}, | ||
234 | {"", 0}, | ||
235 | }; | ||
236 | MODULE_DEVICE_TABLE(acpi, pcc_device_ids); | ||
237 | |||
238 | |||
239 | static int __devinit acpi_pcc_hotkey_add(struct acpi_device *device); | ||
240 | static int __devexit acpi_pcc_hotkey_remove(struct acpi_device *device, | ||
241 | int type); | ||
242 | static int acpi_pcc_hotkey_resume(struct acpi_device *device); | ||
243 | |||
244 | |||
245 | static struct acpi_driver acpi_pcc_driver = { | ||
246 | .name = ACPI_PCC_DRIVER_NAME, | ||
247 | .class = ACPI_PCC_CLASS, | ||
248 | .ids = pcc_device_ids, | ||
249 | .ops = { | ||
250 | .add = acpi_pcc_hotkey_add, | ||
251 | .remove = __devexit_p(acpi_pcc_hotkey_remove), | ||
252 | #ifdef CONFIG_PM | ||
253 | /*.suspend = acpi_pcc_hotkey_suspend,*/ | ||
254 | .resume = acpi_pcc_hotkey_resume, | ||
255 | #endif | ||
256 | }, | ||
257 | }; | ||
258 | |||
259 | struct acpi_hotkey { | ||
260 | acpi_handle handle; | ||
261 | struct acpi_device *device; | ||
262 | struct proc_dir_entry *proc_dir_entry; | ||
263 | unsigned long num_sifr; | ||
264 | unsigned long status; | ||
265 | struct input_dev *input_dev; | ||
266 | int sticky_mode; | ||
267 | }; | ||
268 | |||
269 | struct pcc_keyinput { | ||
270 | struct acpi_hotkey *hotkey; | ||
271 | int key_mode; | ||
272 | }; | ||
273 | |||
274 | /* ************************************************************************* | ||
275 | Hotkey driver core | ||
276 | ************************************************************************* */ | ||
277 | /* ------------------------------------------------------------------------- | ||
278 | method access functions | ||
279 | ------------------------------------------------------------------------- */ | ||
280 | static int acpi_pcc_write_sset(struct acpi_hotkey *hotkey, int func, int val) | ||
281 | { | ||
282 | union acpi_object in_objs[] = { | ||
283 | { .integer.type = ACPI_TYPE_INTEGER, | ||
284 | .integer.value = func, }, | ||
285 | { .integer.type = ACPI_TYPE_INTEGER, | ||
286 | .integer.value = val, }, | ||
287 | }; | ||
288 | struct acpi_object_list params = { | ||
289 | .count = ARRAY_SIZE(in_objs), | ||
290 | .pointer = in_objs, | ||
291 | }; | ||
292 | acpi_status status; | ||
293 | |||
294 | ACPI_FUNCTION_TRACE("acpi_pcc_write_sset"); | ||
295 | |||
296 | status = acpi_evaluate_object(hotkey->handle, METHOD_HKEY_SSET, | ||
297 | ¶ms, NULL); | ||
298 | |||
299 | return_VALUE(status == AE_OK ? AE_OK : AE_ERROR); | ||
300 | } | ||
301 | |||
302 | static inline int acpi_pcc_get_sqty(struct acpi_device *device) | ||
303 | { | ||
304 | unsigned long s; | ||
305 | acpi_status status; | ||
306 | |||
307 | ACPI_FUNCTION_TRACE("acpi_pcc_get_sqty"); | ||
308 | |||
309 | status = acpi_evaluate_integer(device->handle, METHOD_HKEY_SQTY, | ||
310 | NULL, &s); | ||
311 | if (ACPI_SUCCESS(status)) { | ||
312 | return_VALUE(s); | ||
313 | } else { | ||
314 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
315 | "evaluation error HKEY.SQTY\n")); | ||
316 | return_VALUE(-EINVAL); | ||
317 | } | ||
318 | } | ||
319 | |||
320 | static int acpi_pcc_retrieve_biosdata(struct acpi_hotkey *hotkey, u32 *sinf) | ||
321 | { | ||
322 | acpi_status status; | ||
323 | struct acpi_buffer buffer = {ACPI_ALLOCATE_BUFFER, NULL}; | ||
324 | union acpi_object *hkey = NULL; | ||
325 | int i; | ||
326 | |||
327 | ACPI_FUNCTION_TRACE("acpi_pcc_retrieve_biosdata"); | ||
328 | |||
329 | status = acpi_evaluate_object(hotkey->handle, METHOD_HKEY_SINF, 0, | ||
330 | &buffer); | ||
331 | if (ACPI_FAILURE(status)) { | ||
332 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
333 | "evaluation error HKEY.SINF\n")); | ||
334 | status = AE_ERROR; | ||
335 | return_VALUE(status); | ||
336 | } | ||
337 | |||
338 | hkey = buffer.pointer; | ||
339 | if (!hkey || (hkey->type != ACPI_TYPE_PACKAGE)) { | ||
340 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Invalid HKEY.SINF\n")); | ||
341 | goto free_buffer; | ||
342 | } | ||
343 | |||
344 | if (hotkey->num_sifr < hkey->package.count) { | ||
345 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
346 | "SQTY reports bad SINF length\n")); | ||
347 | status = AE_ERROR; | ||
348 | goto free_buffer; | ||
349 | } | ||
350 | |||
351 | for (i = 0; i < hkey->package.count; i++) { | ||
352 | union acpi_object *element = &(hkey->package.elements[i]); | ||
353 | if (likely(element->type == ACPI_TYPE_INTEGER)) { | ||
354 | sinf[i] = element->integer.value; | ||
355 | } else { | ||
356 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
357 | "Invalid HKEY.SINF data\n")); | ||
358 | status = AE_ERROR; | ||
359 | break; | ||
360 | } | ||
361 | } | ||
362 | sinf[hkey->package.count] = -1; | ||
363 | |||
364 | free_buffer: | ||
365 | kfree(buffer.pointer); | ||
366 | return_VALUE(status == AE_OK ? AE_OK : AE_ERROR); | ||
367 | } | ||
368 | |||
369 | static int acpi_pcc_read_sinf_field(struct seq_file *seq, int field) | ||
370 | { | ||
371 | struct acpi_hotkey *hotkey = (struct acpi_hotkey *) seq->private; | ||
372 | u32 sinf[hotkey->num_sifr + 1]; | ||
373 | |||
374 | ACPI_FUNCTION_TRACE("acpi_pcc_read_sinf_field"); | ||
375 | |||
376 | if (ACPI_SUCCESS(acpi_pcc_retrieve_biosdata(hotkey, sinf))) | ||
377 | seq_printf(seq, "%u\n", sinf[field]); | ||
378 | else | ||
379 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
380 | "Couldn't retrieve BIOS data\n")); | ||
381 | |||
382 | return_VALUE(AE_OK); | ||
383 | } | ||
384 | |||
385 | /* ------------------------------------------------------------------------- | ||
386 | user interface functions | ||
387 | ------------------------------------------------------------------------- */ | ||
388 | /* read methods */ | ||
389 | /* Sinf read methods */ | ||
390 | #define PCC_SINF_READ_F(_name_, FUNC) \ | ||
391 | static int _name_(struct seq_file *seq, void *offset) \ | ||
392 | { \ | ||
393 | return_VALUE(ACPI_SUCCESS(acpi_pcc_read_sinf_field(seq, \ | ||
394 | (FUNC))) \ | ||
395 | ? 0 : -EINVAL); \ | ||
396 | } | ||
397 | |||
398 | PCC_SINF_READ_F(acpi_pcc_numbatteries_show, SINF_NUM_BATTERIES); | ||
399 | PCC_SINF_READ_F(acpi_pcc_lcdtype_show, SINF_LCD_TYPE); | ||
400 | PCC_SINF_READ_F(acpi_pcc_ac_brightness_max_show, SINF_AC_MAX_BRIGHT); | ||
401 | PCC_SINF_READ_F(acpi_pcc_ac_brightness_min_show, SINF_AC_MIN_BRIGHT); | ||
402 | PCC_SINF_READ_F(acpi_pcc_ac_brightness_show, SINF_AC_CUR_BRIGHT); | ||
403 | PCC_SINF_READ_F(acpi_pcc_dc_brightness_max_show, SINF_DC_MAX_BRIGHT); | ||
404 | PCC_SINF_READ_F(acpi_pcc_dc_brightness_min_show, SINF_DC_MIN_BRIGHT); | ||
405 | PCC_SINF_READ_F(acpi_pcc_dc_brightness_show, SINF_DC_CUR_BRIGHT); | ||
406 | PCC_SINF_READ_F(acpi_pcc_brightness_show, SINF_AC_CUR_BRIGHT); | ||
407 | PCC_SINF_READ_F(acpi_pcc_mute_show, SINF_MUTE); | ||
408 | |||
409 | static int acpi_pcc_sticky_key_show(struct seq_file *seq, void *offset) | ||
410 | { | ||
411 | struct acpi_hotkey *hotkey = seq->private; | ||
412 | |||
413 | ACPI_FUNCTION_TRACE("acpi_pcc_sticky_key_show"); | ||
414 | |||
415 | if (!hotkey || !hotkey->device) | ||
416 | return_VALUE(-EINVAL); | ||
417 | |||
418 | seq_printf(seq, "%d\n", hotkey->sticky_mode); | ||
419 | |||
420 | return_VALUE(0); | ||
421 | } | ||
422 | |||
423 | static int acpi_pcc_keyinput_show(struct seq_file *seq, void *offset) | ||
424 | { | ||
425 | struct acpi_hotkey *hotkey = seq->private; | ||
426 | struct input_dev *hotk_input_dev = hotkey->input_dev; | ||
427 | struct pcc_keyinput *keyinput = input_get_drvdata(hotk_input_dev); | ||
428 | |||
429 | ACPI_FUNCTION_TRACE("acpi_pcc_keyinput_show"); | ||
430 | |||
431 | seq_printf(seq, "%d\n", keyinput->key_mode); | ||
432 | |||
433 | return_VALUE(0); | ||
434 | } | ||
435 | |||
436 | static int acpi_pcc_version_show(struct seq_file *seq, void *offset) | ||
437 | { | ||
438 | struct acpi_hotkey *hotkey = seq->private; | ||
439 | |||
440 | ACPI_FUNCTION_TRACE("acpi_pcc_version_show"); | ||
441 | |||
442 | if (!hotkey || !hotkey->device) | ||
443 | return_VALUE(-EINVAL); | ||
444 | |||
445 | seq_printf(seq, "%s version %s\n", ACPI_PCC_DRIVER_NAME, | ||
446 | ACPI_PCC_VERSION); | ||
447 | seq_printf(seq, "%li functions\n", hotkey->num_sifr); | ||
448 | |||
449 | return_VALUE(0); | ||
450 | } | ||
451 | |||
452 | /* write methods */ | ||
453 | static ssize_t acpi_pcc_write_single_flag(struct file *file, | ||
454 | const char __user *buffer, | ||
455 | size_t count, | ||
456 | int sinf_func) | ||
457 | { | ||
458 | struct seq_file *seq = file->private_data; | ||
459 | struct acpi_hotkey *hotkey = seq->private; | ||
460 | char write_string[PROC_STR_MAX_LEN]; | ||
461 | u32 val; | ||
462 | |||
463 | ACPI_FUNCTION_TRACE("acpi_pcc_write_single_flag"); | ||
464 | |||
465 | if (!hotkey || (count > sizeof(write_string) - 1)) | ||
466 | return_VALUE(-EINVAL); | ||
467 | |||
468 | if (copy_from_user(write_string, buffer, count)) | ||
469 | return_VALUE(-EFAULT); | ||
470 | |||
471 | write_string[count] = '\0'; | ||
472 | |||
473 | if ((sscanf(write_string, "%3i", &val) == 1) && | ||
474 | (val == 0 || val == 1)) | ||
475 | acpi_pcc_write_sset(hotkey, sinf_func, val); | ||
476 | |||
477 | return_VALUE(count); | ||
478 | } | ||
479 | |||
480 | static unsigned long acpi_pcc_write_brightness(struct file *file, | ||
481 | const char __user *buffer, | ||
482 | size_t count, | ||
483 | int min_index, int max_index, | ||
484 | int cur_index) | ||
485 | { | ||
486 | struct seq_file *seq = (struct seq_file *)file->private_data; | ||
487 | struct acpi_hotkey *hotkey = (struct acpi_hotkey *)seq->private; | ||
488 | char write_string[PROC_STR_MAX_LEN]; | ||
489 | u32 bright; | ||
490 | u32 sinf[hotkey->num_sifr + 1]; | ||
491 | |||
492 | ACPI_FUNCTION_TRACE("acpi_pcc_write_brightness"); | ||
493 | |||
494 | if (!hotkey || (count > sizeof(write_string) - 1)) | ||
495 | return_VALUE(-EINVAL); | ||
496 | |||
497 | if (copy_from_user(write_string, buffer, count)) | ||
498 | return_VALUE(-EFAULT); | ||
499 | |||
500 | write_string[count] = '\0'; | ||
501 | |||
502 | if (ACPI_FAILURE(acpi_pcc_retrieve_biosdata(hotkey, sinf))) { | ||
503 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
504 | "Couldn't retrieve BIOS data\n")); | ||
505 | goto end; | ||
506 | } | ||
507 | |||
508 | if ((sscanf(write_string, "%4i", &bright) == 1) && | ||
509 | (bright >= sinf[min_index]) && | ||
510 | (bright <= sinf[max_index])) | ||
511 | acpi_pcc_write_sset(hotkey, cur_index, bright); | ||
512 | |||
513 | end: | ||
514 | return_VALUE(count); | ||
515 | } | ||
516 | |||
517 | static ssize_t acpi_pcc_write_ac_brightness(struct file *file, | ||
518 | const char __user *buffer, | ||
519 | size_t count, loff_t *ppos) | ||
520 | { | ||
521 | return_VALUE(acpi_pcc_write_brightness(file, buffer, count, | ||
522 | SINF_AC_MIN_BRIGHT, | ||
523 | SINF_AC_MAX_BRIGHT, | ||
524 | SINF_AC_CUR_BRIGHT)); | ||
525 | } | ||
526 | |||
527 | static ssize_t acpi_pcc_write_dc_brightness(struct file *file, | ||
528 | const char __user *buffer, | ||
529 | size_t count, loff_t *ppos) | ||
530 | { | ||
531 | return_VALUE(acpi_pcc_write_brightness(file, buffer, count, | ||
532 | SINF_DC_MIN_BRIGHT, | ||
533 | SINF_DC_MAX_BRIGHT, | ||
534 | SINF_DC_CUR_BRIGHT)); | ||
535 | } | ||
536 | |||
537 | static ssize_t acpi_pcc_write_no_brightness(struct file *file, | ||
538 | const char __user *buffer, | ||
539 | size_t count, loff_t *ppos) | ||
540 | { | ||
541 | return acpi_pcc_write_brightness(file, buffer, count, | ||
542 | SINF_AC_MIN_BRIGHT, | ||
543 | SINF_AC_MAX_BRIGHT, | ||
544 | SINF_AC_CUR_BRIGHT); | ||
545 | } | ||
546 | |||
547 | static ssize_t acpi_pcc_write_mute(struct file *file, | ||
548 | const char __user *buffer, | ||
549 | size_t count, loff_t *ppos) | ||
550 | { | ||
551 | return_VALUE(acpi_pcc_write_single_flag(file, buffer, count, | ||
552 | SINF_MUTE)); | ||
553 | } | ||
554 | |||
555 | static ssize_t acpi_pcc_write_sticky_key(struct file *file, | ||
556 | const char __user *buffer, | ||
557 | size_t count, loff_t *ppos) | ||
558 | { | ||
559 | struct seq_file *seq = (struct seq_file *)file->private_data; | ||
560 | struct acpi_hotkey *hotkey = (struct acpi_hotkey *)seq->private; | ||
561 | char write_string[PROC_STR_MAX_LEN]; | ||
562 | int mode; | ||
563 | |||
564 | ACPI_FUNCTION_TRACE("acpi_pcc_write_sticky_key"); | ||
565 | |||
566 | if (!hotkey || (count > sizeof(write_string) - 1)) | ||
567 | return_VALUE(-EINVAL); | ||
568 | |||
569 | if (copy_from_user(write_string, buffer, count)) | ||
570 | return_VALUE(-EFAULT); | ||
571 | |||
572 | write_string[count] = '\0'; | ||
573 | |||
574 | if ((sscanf(write_string, "%3i", &mode) == 1) && | ||
575 | (mode == 0 || mode == 1)) { | ||
576 | acpi_pcc_write_sset(hotkey, SINF_STICKY_KEY, mode); | ||
577 | hotkey->sticky_mode = mode; | ||
578 | } | ||
579 | |||
580 | return_VALUE(count); | ||
581 | } | ||
582 | |||
583 | static ssize_t acpi_pcc_write_keyinput(struct file *file, | ||
584 | const char __user *buffer, | ||
585 | size_t count, loff_t *ppos) | ||
586 | { | ||
587 | struct seq_file *seq = (struct seq_file *)file->private_data; | ||
588 | struct acpi_hotkey *hotkey = (struct acpi_hotkey *)seq->private; | ||
589 | struct pcc_keyinput *keyinput; | ||
590 | char write_string[PROC_STR_MAX_LEN]; | ||
591 | int key_mode; | ||
592 | |||
593 | ACPI_FUNCTION_TRACE("acpi_pcc_write_keyinput"); | ||
594 | |||
595 | if (!hotkey || (count > (sizeof(write_string) - 1))) | ||
596 | return_VALUE(-EINVAL); | ||
597 | |||
598 | if (copy_from_user(write_string, buffer, count)) | ||
599 | return_VALUE(-EFAULT); | ||
600 | |||
601 | write_string[count] = '\0'; | ||
602 | |||
603 | if ((sscanf(write_string, "%4i", &key_mode) == 1) && | ||
604 | (key_mode == 0 || key_mode == 1)) { | ||
605 | keyinput = input_get_drvdata(hotkey->input_dev); | ||
606 | keyinput->key_mode = key_mode; | ||
607 | } | ||
608 | |||
609 | return_VALUE(count); | ||
610 | } | ||
611 | |||
612 | /* ------------------------------------------------------------------------- | ||
613 | hotkey driver | ||
614 | ------------------------------------------------------------------------- */ | ||
615 | static void acpi_pcc_generete_keyinput(struct acpi_hotkey *hotkey) | ||
616 | { | ||
617 | struct input_dev *hotk_input_dev = hotkey->input_dev; | ||
618 | struct pcc_keyinput *keyinput = input_get_drvdata(hotk_input_dev); | ||
619 | int hinf = hotkey->status; | ||
620 | int key_code, hkey_num; | ||
621 | const int key_map[] = { | ||
622 | /* 0 */ -1, | ||
623 | /* 1 */ KEY_BRIGHTNESSDOWN, | ||
624 | /* 2 */ KEY_BRIGHTNESSUP, | ||
625 | /* 3 */ -1, /* vga/lcd switch event is not occur on | ||
626 | hotkey driver. */ | ||
627 | /* 4 */ KEY_MUTE, | ||
628 | /* 5 */ KEY_VOLUMEDOWN, | ||
629 | /* 6 */ KEY_VOLUMEUP, | ||
630 | /* 7 */ KEY_SLEEP, | ||
631 | /* 8 */ -1, /* Change CPU boost: do nothing */ | ||
632 | /* 9 */ KEY_BATT, | ||
633 | /* 10 */ KEY_SUSPEND, | ||
634 | }; | ||
635 | |||
636 | ACPI_FUNCTION_TRACE("acpi_pcc_generete_keyinput"); | ||
637 | |||
638 | if (keyinput->key_mode == 0) | ||
639 | return_VOID; | ||
640 | |||
641 | hkey_num = hinf & 0xf; | ||
642 | |||
643 | if ((0 > hkey_num) || | ||
644 | (hkey_num > ARRAY_SIZE(key_map))) { | ||
645 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
646 | "hotkey number out of range: %d\n", | ||
647 | hkey_num)); | ||
648 | return_VOID; | ||
649 | } | ||
650 | |||
651 | key_code = key_map[hkey_num]; | ||
652 | |||
653 | if (key_code != -1) { | ||
654 | int pushed = (hinf & 0x80) ? TRUE : FALSE; | ||
655 | |||
656 | input_report_key(hotk_input_dev, key_code, pushed); | ||
657 | input_sync(hotk_input_dev); | ||
658 | } | ||
659 | } | ||
660 | |||
661 | static int acpi_pcc_hotkey_get_key(struct acpi_hotkey *hotkey) | ||
662 | { | ||
663 | unsigned long result; | ||
664 | acpi_status status = AE_OK; | ||
665 | |||
666 | ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_get_key"); | ||
667 | |||
668 | status = acpi_evaluate_integer(hotkey->handle, METHOD_HKEY_QUERY, | ||
669 | NULL, &result); | ||
670 | if (likely(ACPI_SUCCESS(status))) | ||
671 | hotkey->status = result; | ||
672 | else | ||
673 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
674 | "error getting hotkey status\n")); | ||
675 | |||
676 | return_VALUE(status == AE_OK); | ||
677 | } | ||
678 | |||
679 | void acpi_pcc_hotkey_notify(acpi_handle handle, u32 event, void *data) | ||
680 | { | ||
681 | struct acpi_hotkey *hotkey = (struct acpi_hotkey *) data; | ||
682 | |||
683 | ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_notify"); | ||
684 | |||
685 | switch (event) { | ||
686 | case HKEY_NOTIFY: | ||
687 | if (acpi_pcc_hotkey_get_key(hotkey)) { | ||
688 | /* generate event like '"pcc HKEY 00000080 00000084"' | ||
689 | * when Fn+F4 pressed */ | ||
690 | acpi_bus_generate_proc_event(hotkey->device, event, | ||
691 | hotkey->status); | ||
692 | } | ||
693 | acpi_pcc_generete_keyinput(hotkey); | ||
694 | break; | ||
695 | default: | ||
696 | /* nothing to do */ | ||
697 | break; | ||
698 | } | ||
699 | return_VOID; | ||
700 | } | ||
701 | |||
702 | /* ************************************************************************* | ||
703 | FS Interface (/proc) | ||
704 | ************************************************************************* */ | ||
705 | /* oepn proc file fs*/ | ||
706 | SEQ_OPEN_FS(acpi_pcc_dc_brightness_open_fs, acpi_pcc_dc_brightness_show); | ||
707 | SEQ_OPEN_FS(acpi_pcc_numbatteries_open_fs, acpi_pcc_numbatteries_show); | ||
708 | SEQ_OPEN_FS(acpi_pcc_lcdtype_open_fs, acpi_pcc_lcdtype_show); | ||
709 | SEQ_OPEN_FS(acpi_pcc_ac_brightness_max_open_fs, | ||
710 | acpi_pcc_ac_brightness_max_show); | ||
711 | SEQ_OPEN_FS(acpi_pcc_ac_brightness_min_open_fs, | ||
712 | acpi_pcc_ac_brightness_min_show); | ||
713 | SEQ_OPEN_FS(acpi_pcc_ac_brightness_open_fs, acpi_pcc_ac_brightness_show); | ||
714 | SEQ_OPEN_FS(acpi_pcc_dc_brightness_max_open_fs, | ||
715 | acpi_pcc_dc_brightness_max_show); | ||
716 | SEQ_OPEN_FS(acpi_pcc_dc_brightness_min_open_fs, | ||
717 | acpi_pcc_dc_brightness_min_show); | ||
718 | SEQ_OPEN_FS(acpi_pcc_brightness_open_fs, acpi_pcc_brightness_show); | ||
719 | SEQ_OPEN_FS(acpi_pcc_mute_open_fs, acpi_pcc_mute_show); | ||
720 | SEQ_OPEN_FS(acpi_pcc_version_open_fs, acpi_pcc_version_show); | ||
721 | SEQ_OPEN_FS(acpi_pcc_keyinput_open_fs, acpi_pcc_keyinput_show); | ||
722 | SEQ_OPEN_FS(acpi_pcc_sticky_key_open_fs, acpi_pcc_sticky_key_show); | ||
723 | |||
724 | static struct file_operations acpi_pcc_numbatteries_fops = | ||
725 | SEQ_FILEOPS_R(acpi_pcc_numbatteries_open_fs); | ||
726 | static struct file_operations acpi_pcc_lcdtype_fops = | ||
727 | SEQ_FILEOPS_R(acpi_pcc_lcdtype_open_fs); | ||
728 | static struct file_operations acpi_pcc_mute_fops = | ||
729 | SEQ_FILEOPS_RW(acpi_pcc_mute_open_fs, acpi_pcc_write_mute); | ||
730 | static struct file_operations acpi_pcc_ac_brightness_fops = | ||
731 | SEQ_FILEOPS_RW(acpi_pcc_ac_brightness_open_fs, | ||
732 | acpi_pcc_write_ac_brightness); | ||
733 | static struct file_operations acpi_pcc_ac_brightness_max_fops = | ||
734 | SEQ_FILEOPS_R(acpi_pcc_ac_brightness_max_open_fs); | ||
735 | static struct file_operations acpi_pcc_ac_brightness_min_fops = | ||
736 | SEQ_FILEOPS_R(acpi_pcc_ac_brightness_min_open_fs); | ||
737 | static struct file_operations acpi_pcc_dc_brightness_fops = | ||
738 | SEQ_FILEOPS_RW(acpi_pcc_dc_brightness_open_fs, | ||
739 | acpi_pcc_write_dc_brightness); | ||
740 | static struct file_operations acpi_pcc_dc_brightness_max_fops = | ||
741 | SEQ_FILEOPS_R(acpi_pcc_dc_brightness_max_open_fs); | ||
742 | static struct file_operations acpi_pcc_dc_brightness_min_fops = | ||
743 | SEQ_FILEOPS_R(acpi_pcc_dc_brightness_min_open_fs); | ||
744 | static struct file_operations acpi_pcc_brightness_fops = | ||
745 | SEQ_FILEOPS_RW(acpi_pcc_brightness_open_fs, | ||
746 | acpi_pcc_write_no_brightness); | ||
747 | static struct file_operations acpi_pcc_sticky_key_fops = | ||
748 | SEQ_FILEOPS_RW(acpi_pcc_sticky_key_open_fs, acpi_pcc_write_sticky_key); | ||
749 | static struct file_operations acpi_pcc_keyinput_fops = | ||
750 | SEQ_FILEOPS_RW(acpi_pcc_keyinput_open_fs, acpi_pcc_write_keyinput); | ||
751 | static struct file_operations acpi_pcc_version_fops = | ||
752 | SEQ_FILEOPS_R(acpi_pcc_version_open_fs); | ||
753 | |||
754 | struct proc_item { | ||
755 | const char *name; | ||
756 | struct file_operations *fops; | ||
757 | mode_t flag; | ||
758 | }; | ||
759 | |||
760 | /* Note: These functions map *exactly* to the SINF/SSET functions */ | ||
761 | struct proc_item acpi_pcc_proc_items_sifr[] = { | ||
762 | { "num_batteries", &acpi_pcc_numbatteries_fops, S_IRUGO }, | ||
763 | { "lcd_type", &acpi_pcc_lcdtype_fops, S_IRUGO }, | ||
764 | { "ac_brightness_max", &acpi_pcc_ac_brightness_max_fops, S_IRUGO }, | ||
765 | { "ac_brightness_min", &acpi_pcc_ac_brightness_min_fops, S_IRUGO }, | ||
766 | { "ac_brightness", &acpi_pcc_ac_brightness_fops, | ||
767 | S_IFREG | S_IRUGO | S_IWUSR }, | ||
768 | { "dc_brightness_max", &acpi_pcc_dc_brightness_max_fops, S_IRUGO }, | ||
769 | { "dc_brightness_min", &acpi_pcc_dc_brightness_min_fops, S_IRUGO }, | ||
770 | { "dc_brightness", &acpi_pcc_dc_brightness_fops, | ||
771 | S_IFREG | S_IRUGO | S_IWUSR }, | ||
772 | { "brightness", &acpi_pcc_brightness_fops, S_IFREG | S_IRUGO | S_IWUSR}, | ||
773 | { "mute", &acpi_pcc_mute_fops, S_IFREG | S_IRUGO | S_IWUSR }, | ||
774 | { NULL, NULL, 0 }, | ||
775 | }; | ||
776 | |||
777 | struct proc_item acpi_pcc_proc_items[] = { | ||
778 | { "sticky_key", &acpi_pcc_sticky_key_fops, S_IFREG | S_IRUGO | S_IWUSR}, | ||
779 | { "keyinput", &acpi_pcc_keyinput_fops, S_IFREG | S_IRUGO | S_IWUSR }, | ||
780 | { "version", &acpi_pcc_version_fops, S_IRUGO }, | ||
781 | { NULL, NULL, 0 }, | ||
782 | }; | ||
783 | |||
784 | static int __devinit acpi_pcc_add_device(struct acpi_device *device, | ||
785 | struct proc_item *proc_items, | ||
786 | int num) | ||
787 | { | ||
788 | struct acpi_hotkey *hotkey = acpi_driver_data(device); | ||
789 | struct proc_dir_entry *proc; | ||
790 | struct proc_item *item; | ||
791 | int i; | ||
792 | |||
793 | for (item = proc_items, i = 0; item->name && i < num; ++item, ++i) { | ||
794 | proc = create_proc_entry(item->name, item->flag, | ||
795 | hotkey->proc_dir_entry); | ||
796 | if (likely(proc)) { | ||
797 | proc->proc_fops = item->fops; | ||
798 | proc->data = hotkey; | ||
799 | proc->owner = THIS_MODULE; | ||
800 | } else { | ||
801 | while (i-- > 0) { | ||
802 | item--; | ||
803 | remove_proc_entry(item->name, | ||
804 | hotkey->proc_dir_entry); | ||
805 | } | ||
806 | return_VALUE(-ENODEV); | ||
807 | } | ||
808 | } | ||
809 | return_VALUE(0); | ||
810 | } | ||
811 | |||
812 | static int __devinit acpi_pcc_proc_init(struct acpi_device *device) | ||
813 | { | ||
814 | struct proc_dir_entry *acpi_pcc_dir; | ||
815 | struct acpi_hotkey *hotkey = acpi_driver_data(device); | ||
816 | acpi_status status; | ||
817 | |||
818 | ACPI_FUNCTION_TRACE("acpi_pcc_proc_init"); | ||
819 | |||
820 | acpi_pcc_dir = proc_mkdir(PROC_PCC, acpi_root_dir); | ||
821 | |||
822 | if (unlikely(!acpi_pcc_dir)) { | ||
823 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
824 | "Couldn't create dir in /proc\n")); | ||
825 | return_VALUE(-ENODEV); | ||
826 | } | ||
827 | |||
828 | acpi_pcc_dir->owner = THIS_MODULE; | ||
829 | hotkey->proc_dir_entry = acpi_pcc_dir; | ||
830 | |||
831 | status = acpi_pcc_add_device(device, acpi_pcc_proc_items_sifr, | ||
832 | hotkey->num_sifr); | ||
833 | status |= acpi_pcc_add_device(device, acpi_pcc_proc_items, | ||
834 | ARRAY_SIZE(acpi_pcc_proc_items)); | ||
835 | if (unlikely(status)) { | ||
836 | remove_proc_entry(PROC_PCC, acpi_root_dir); | ||
837 | hotkey->proc_dir_entry = NULL; | ||
838 | return_VALUE(-ENODEV); | ||
839 | } | ||
840 | |||
841 | return_VALUE(status); | ||
842 | } | ||
843 | |||
844 | static void __devexit acpi_pcc_remove_device(struct acpi_device *device, | ||
845 | struct proc_item *proc_items, | ||
846 | int num) | ||
847 | { | ||
848 | struct acpi_hotkey *hotkey = acpi_driver_data(device); | ||
849 | struct proc_item *item; | ||
850 | int i; | ||
851 | |||
852 | for (item = proc_items, i = 0; | ||
853 | item->name != NULL && i < num; | ||
854 | ++item, ++i) { | ||
855 | remove_proc_entry(item->name, hotkey->proc_dir_entry); | ||
856 | } | ||
857 | |||
858 | return_VOID; | ||
859 | } | ||
860 | |||
861 | /* ************************************************************************* | ||
862 | Power Management | ||
863 | ************************************************************************* */ | ||
864 | #ifdef CONFIG_PM | ||
865 | static int acpi_pcc_hotkey_resume(struct acpi_device *device) | ||
866 | { | ||
867 | struct acpi_hotkey *hotkey = acpi_driver_data(device); | ||
868 | acpi_status status = AE_OK; | ||
869 | |||
870 | ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_resume"); | ||
871 | |||
872 | if (device == NULL || hotkey == NULL) | ||
873 | return_VALUE(-EINVAL); | ||
874 | |||
875 | if (hotkey->num_sifr != 0) { | ||
876 | ACPI_DEBUG_PRINT((ACPI_DB_INFO, "Sticky mode restore: %d\n", | ||
877 | hotkey->sticky_mode)); | ||
878 | |||
879 | status = acpi_pcc_write_sset(hotkey, SINF_STICKY_KEY, | ||
880 | hotkey->sticky_mode); | ||
881 | } | ||
882 | if (status != AE_OK) | ||
883 | return_VALUE(-EINVAL); | ||
884 | |||
885 | return_VALUE(0); | ||
886 | } | ||
887 | #endif | ||
888 | |||
889 | /* ************************************************************************* | ||
890 | Module init/remove | ||
891 | ************************************************************************* */ | ||
892 | /* ------------------------------------------------------------------------- | ||
893 | input | ||
894 | ------------------------------------------------------------------------- */ | ||
895 | static int __devinit acpi_pcc_init_input(struct acpi_hotkey *hotkey) | ||
896 | { | ||
897 | struct input_dev *hotk_input_dev; | ||
898 | struct pcc_keyinput *pcc_keyinput; | ||
899 | int error; | ||
900 | |||
901 | ACPI_FUNCTION_TRACE("acpi_pcc_init_input"); | ||
902 | |||
903 | hotk_input_dev = input_allocate_device(); | ||
904 | if (hotk_input_dev == NULL) { | ||
905 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
906 | "Couldn't allocate input device for hotkey")); | ||
907 | goto err_input; | ||
908 | } | ||
909 | |||
910 | pcc_keyinput = kcalloc(1, sizeof(struct pcc_keyinput), GFP_KERNEL); | ||
911 | |||
912 | if (pcc_keyinput == NULL) { | ||
913 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
914 | "Couldn't allocate mem for private data")); | ||
915 | goto err_pcc; | ||
916 | } | ||
917 | |||
918 | hotk_input_dev->evbit[0] = BIT(EV_KEY); | ||
919 | |||
920 | set_bit(KEY_BRIGHTNESSDOWN, hotk_input_dev->keybit); | ||
921 | set_bit(KEY_BRIGHTNESSUP, hotk_input_dev->keybit); | ||
922 | set_bit(KEY_MUTE, hotk_input_dev->keybit); | ||
923 | set_bit(KEY_VOLUMEDOWN, hotk_input_dev->keybit); | ||
924 | set_bit(KEY_VOLUMEUP, hotk_input_dev->keybit); | ||
925 | set_bit(KEY_SLEEP, hotk_input_dev->keybit); | ||
926 | set_bit(KEY_BATT, hotk_input_dev->keybit); | ||
927 | set_bit(KEY_SUSPEND, hotk_input_dev->keybit); | ||
928 | |||
929 | hotk_input_dev->name = ACPI_PCC_DRIVER_NAME; | ||
930 | hotk_input_dev->phys = ACPI_PCC_INPUT_PHYS; | ||
931 | hotk_input_dev->id.bustype = BUS_PCC_HOTKEY; | ||
932 | hotk_input_dev->id.vendor = 0x0001; | ||
933 | hotk_input_dev->id.product = 0x0001; | ||
934 | hotk_input_dev->id.version = 0x0100; | ||
935 | |||
936 | pcc_keyinput->key_mode = PCC_KEYINPUT_MODE; | ||
937 | pcc_keyinput->hotkey = hotkey; | ||
938 | |||
939 | input_set_drvdata(hotk_input_dev, pcc_keyinput); | ||
940 | |||
941 | hotkey->input_dev = hotk_input_dev; | ||
942 | |||
943 | error = input_register_device(hotk_input_dev); | ||
944 | |||
945 | if (error) | ||
946 | goto err_pcc; | ||
947 | |||
948 | return_VALUE(0); | ||
949 | |||
950 | err_pcc: | ||
951 | input_unregister_device(hotk_input_dev); | ||
952 | err_input: | ||
953 | return_VALUE(-ENOMEM); | ||
954 | } | ||
955 | |||
956 | static void __devexit acpi_pcc_remove_input(struct acpi_hotkey *hotkey) | ||
957 | { | ||
958 | struct input_dev *hotk_input_dev; | ||
959 | struct pcc_keyinput *pcc_keyinput; | ||
960 | |||
961 | ACPI_FUNCTION_TRACE("acpi_pcc_remove_input"); | ||
962 | |||
963 | if (hotkey == NULL) { | ||
964 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Can't free memory")); | ||
965 | return_VOID; | ||
966 | } | ||
967 | |||
968 | hotk_input_dev = hotkey->input_dev; | ||
969 | pcc_keyinput = input_get_drvdata(hotk_input_dev); | ||
970 | |||
971 | input_unregister_device(hotk_input_dev); | ||
972 | |||
973 | kfree(pcc_keyinput); | ||
974 | } | ||
975 | |||
976 | /* ------------------------------------------------------------------------- | ||
977 | ACPI | ||
978 | ------------------------------------------------------------------------- */ | ||
979 | static int __devinit acpi_pcc_hotkey_add(struct acpi_device *device) | ||
980 | { | ||
981 | acpi_status status = AE_OK; | ||
982 | struct acpi_hotkey *hotkey = NULL; | ||
983 | int sifr_status, num_sifr, result; | ||
984 | |||
985 | ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_add"); | ||
986 | |||
987 | if (device == NULL) | ||
988 | return_VALUE(-EINVAL); | ||
989 | |||
990 | sifr_status = acpi_pcc_get_sqty(device); | ||
991 | |||
992 | if (sifr_status > 255) { | ||
993 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "num_sifr too large")); | ||
994 | return_VALUE(-ENODEV); | ||
995 | } | ||
996 | |||
997 | if (sifr_status < 0) { | ||
998 | ACPI_DEBUG_PRINT((ACPI_DB_INFO, "not support SQTY")); | ||
999 | num_sifr = 0; | ||
1000 | } else { | ||
1001 | num_sifr = sifr_status; | ||
1002 | } | ||
1003 | |||
1004 | hotkey = kcalloc(1, sizeof(struct acpi_hotkey), GFP_KERNEL); | ||
1005 | if (hotkey == NULL) { | ||
1006 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
1007 | "Couldn't allocate mem for hotkey")); | ||
1008 | return_VALUE(-ENOMEM); | ||
1009 | } | ||
1010 | |||
1011 | hotkey->device = device; | ||
1012 | hotkey->handle = device->handle; | ||
1013 | hotkey->num_sifr = num_sifr; | ||
1014 | device->driver_data = hotkey; | ||
1015 | strcpy(acpi_device_name(device), ACPI_PCC_DEVICE_NAME); | ||
1016 | strcpy(acpi_device_class(device), ACPI_PCC_CLASS); | ||
1017 | |||
1018 | status = acpi_install_notify_handler(hotkey->handle, | ||
1019 | ACPI_DEVICE_NOTIFY, | ||
1020 | acpi_pcc_hotkey_notify, | ||
1021 | hotkey); | ||
1022 | |||
1023 | if (ACPI_FAILURE(status)) { | ||
1024 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
1025 | "Error installing notify handler\n")); | ||
1026 | kfree(hotkey); | ||
1027 | return_VALUE(-ENODEV); | ||
1028 | } | ||
1029 | |||
1030 | result = acpi_pcc_init_input(hotkey); | ||
1031 | if (result != 0) { | ||
1032 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
1033 | "Error installing keyinput handler\n")); | ||
1034 | kfree(hotkey); | ||
1035 | return_VALUE(result); | ||
1036 | } | ||
1037 | |||
1038 | return_VALUE(acpi_pcc_proc_init(device)); | ||
1039 | } | ||
1040 | |||
1041 | static int __devexit acpi_pcc_hotkey_remove(struct acpi_device *device, | ||
1042 | int type) | ||
1043 | { | ||
1044 | acpi_status status = AE_OK; | ||
1045 | struct acpi_hotkey *hotkey = acpi_driver_data(device); | ||
1046 | |||
1047 | ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_remove"); | ||
1048 | |||
1049 | if (!device || !hotkey) | ||
1050 | return_VALUE(-EINVAL); | ||
1051 | |||
1052 | if (hotkey->proc_dir_entry) { | ||
1053 | acpi_pcc_remove_device(device, acpi_pcc_proc_items_sifr, | ||
1054 | hotkey->num_sifr); | ||
1055 | acpi_pcc_remove_device(device, acpi_pcc_proc_items, | ||
1056 | ARRAY_SIZE(acpi_pcc_proc_items)); | ||
1057 | remove_proc_entry(PROC_PCC, acpi_root_dir); | ||
1058 | } | ||
1059 | |||
1060 | status = acpi_remove_notify_handler(hotkey->handle, | ||
1061 | ACPI_DEVICE_NOTIFY, acpi_pcc_hotkey_notify); | ||
1062 | |||
1063 | if (ACPI_FAILURE(status)) { | ||
1064 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
1065 | "Error removing notify handler\n")); | ||
1066 | } | ||
1067 | |||
1068 | acpi_pcc_remove_input(hotkey); | ||
1069 | kfree(hotkey); | ||
1070 | return_VALUE(status == AE_OK); | ||
1071 | } | ||
1072 | |||
1073 | /* ********************************************************************* | ||
1074 | Module entry point | ||
1075 | ********************************************************************* */ | ||
1076 | static int __init acpi_pcc_init(void) | ||
1077 | { | ||
1078 | int result; | ||
1079 | |||
1080 | ACPI_FUNCTION_TRACE("acpi_pcc_init"); | ||
1081 | |||
1082 | printk(KERN_INFO LOGPREFIX "loading...\n"); | ||
1083 | |||
1084 | if (acpi_disabled) { | ||
1085 | printk(KERN_INFO LOGPREFIX "ACPI disabled.\n"); | ||
1086 | return_VALUE(-ENODEV); | ||
1087 | } | ||
1088 | |||
1089 | result = acpi_bus_register_driver(&acpi_pcc_driver); | ||
1090 | if (result < 0) { | ||
1091 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
1092 | "Error registering hotkey driver\n")); | ||
1093 | return_VALUE(-ENODEV); | ||
1094 | } | ||
1095 | |||
1096 | return_VALUE(result); | ||
1097 | } | ||
1098 | |||
1099 | static void __exit acpi_pcc_exit(void) | ||
1100 | { | ||
1101 | ACPI_FUNCTION_TRACE("acpi_pcc_exit"); | ||
1102 | |||
1103 | printk(KERN_INFO LOGPREFIX "unloading...\n"); | ||
1104 | |||
1105 | acpi_bus_unregister_driver(&acpi_pcc_driver); | ||
1106 | |||
1107 | return_VOID; | ||
1108 | } | ||
1109 | |||
1110 | module_init(acpi_pcc_init); | ||
1111 | module_exit(acpi_pcc_exit); | ||
diff --git a/drivers/video/backlight/Kconfig b/drivers/video/backlight/Kconfig index c72a13562954..4a4dd9adc328 100644 --- a/drivers/video/backlight/Kconfig +++ b/drivers/video/backlight/Kconfig | |||
@@ -75,6 +75,15 @@ config LCD_PLATFORM | |||
75 | This driver provides a platform-device registered LCD power | 75 | This driver provides a platform-device registered LCD power |
76 | control interface. | 76 | control interface. |
77 | 77 | ||
78 | config LCD_TOSA | ||
79 | tristate "Sharp SL-6000 LCD Driver" | ||
80 | depends on LCD_CLASS_DEVICE && SPI | ||
81 | depends on MACH_TOSA | ||
82 | default n | ||
83 | help | ||
84 | If you have an Sharp SL-6000 Zaurus say Y to enable a driver | ||
85 | for its LCD. | ||
86 | |||
78 | # | 87 | # |
79 | # Backlight | 88 | # Backlight |
80 | # | 89 | # |
@@ -115,7 +124,7 @@ config BACKLIGHT_ATMEL_PWM | |||
115 | called atmel-pwm-bl. | 124 | called atmel-pwm-bl. |
116 | 125 | ||
117 | config BACKLIGHT_CORGI | 126 | config BACKLIGHT_CORGI |
118 | tristate "Generic (aka Sharp Corgi) Backlight Driver" | 127 | tristate "Generic (aka Sharp Corgi) Backlight Driver (DEPRECATED)" |
119 | depends on BACKLIGHT_CLASS_DEVICE | 128 | depends on BACKLIGHT_CLASS_DEVICE |
120 | default n | 129 | default n |
121 | help | 130 | help |
@@ -123,6 +132,9 @@ config BACKLIGHT_CORGI | |||
123 | known as the Corgi backlight driver. If you have a Sharp Zaurus | 132 | known as the Corgi backlight driver. If you have a Sharp Zaurus |
124 | SL-C7xx, SL-Cxx00 or SL-6000x say y. Most users can say n. | 133 | SL-C7xx, SL-Cxx00 or SL-6000x say y. Most users can say n. |
125 | 134 | ||
135 | Note: this driver is marked as deprecated, try enable SPI and | ||
136 | use the new corgi_lcd driver with integrated backlight control | ||
137 | |||
126 | config BACKLIGHT_LOCOMO | 138 | config BACKLIGHT_LOCOMO |
127 | tristate "Sharp LOCOMO LCD/Backlight Driver" | 139 | tristate "Sharp LOCOMO LCD/Backlight Driver" |
128 | depends on BACKLIGHT_CLASS_DEVICE && SHARP_LOCOMO | 140 | depends on BACKLIGHT_CLASS_DEVICE && SHARP_LOCOMO |
@@ -171,6 +183,13 @@ config BACKLIGHT_PWM | |||
171 | If you have a LCD backlight adjustable by PWM, say Y to enable | 183 | If you have a LCD backlight adjustable by PWM, say Y to enable |
172 | this driver. | 184 | this driver. |
173 | 185 | ||
186 | config BACKLIGHT_DA903X | ||
187 | tristate "Backlight Driver for DA9030/DA9034 using WLED" | ||
188 | depends on BACKLIGHT_CLASS_DEVICE && PMIC_DA903X | ||
189 | help | ||
190 | If you have a LCD backlight connected to the WLED output of DA9030 | ||
191 | or DA9034 WLED output, say Y here to enable this driver. | ||
192 | |||
174 | config BACKLIGHT_MBP_NVIDIA | 193 | config BACKLIGHT_MBP_NVIDIA |
175 | tristate "MacBook Pro Nvidia Backlight Driver" | 194 | tristate "MacBook Pro Nvidia Backlight Driver" |
176 | depends on BACKLIGHT_CLASS_DEVICE && X86 | 195 | depends on BACKLIGHT_CLASS_DEVICE && X86 |
@@ -179,3 +198,19 @@ config BACKLIGHT_MBP_NVIDIA | |||
179 | If you have an Apple Macbook Pro with Nvidia graphics hardware say Y | 198 | If you have an Apple Macbook Pro with Nvidia graphics hardware say Y |
180 | to enable a driver for its backlight | 199 | to enable a driver for its backlight |
181 | 200 | ||
201 | config BACKLIGHT_TOSA | ||
202 | tristate "Sharp SL-6000 Backlight Driver" | ||
203 | depends on BACKLIGHT_CLASS_DEVICE && I2C | ||
204 | depends on MACH_TOSA && LCD_TOSA | ||
205 | default n | ||
206 | help | ||
207 | If you have an Sharp SL-6000 Zaurus say Y to enable a driver | ||
208 | for its backlight | ||
209 | |||
210 | config BACKLIGHT_SAHARA | ||
211 | tristate "Tabletkiosk Sahara Touch-iT Backlight Driver" | ||
212 | depends on BACKLIGHT_CLASS_DEVICE && X86 | ||
213 | default n | ||
214 | help | ||
215 | If you have a Tabletkiosk Sahara Touch-iT, say y to enable the | ||
216 | backlight driver. | ||
diff --git a/drivers/video/backlight/Makefile b/drivers/video/backlight/Makefile index 3ec551eb472c..103427de6703 100644 --- a/drivers/video/backlight/Makefile +++ b/drivers/video/backlight/Makefile | |||
@@ -7,6 +7,7 @@ obj-$(CONFIG_LCD_ILI9320) += ili9320.o | |||
7 | obj-$(CONFIG_LCD_PLATFORM) += platform_lcd.o | 7 | obj-$(CONFIG_LCD_PLATFORM) += platform_lcd.o |
8 | obj-$(CONFIG_LCD_VGG2432A4) += vgg2432a4.o | 8 | obj-$(CONFIG_LCD_VGG2432A4) += vgg2432a4.o |
9 | obj-$(CONFIG_LCD_TDO24M) += tdo24m.o | 9 | obj-$(CONFIG_LCD_TDO24M) += tdo24m.o |
10 | obj-$(CONFIG_LCD_TOSA) += tosa_lcd.o | ||
10 | 11 | ||
11 | obj-$(CONFIG_BACKLIGHT_CLASS_DEVICE) += backlight.o | 12 | obj-$(CONFIG_BACKLIGHT_CLASS_DEVICE) += backlight.o |
12 | obj-$(CONFIG_BACKLIGHT_ATMEL_PWM) += atmel-pwm-bl.o | 13 | obj-$(CONFIG_BACKLIGHT_ATMEL_PWM) += atmel-pwm-bl.o |
@@ -17,5 +18,8 @@ obj-$(CONFIG_BACKLIGHT_OMAP1) += omap1_bl.o | |||
17 | obj-$(CONFIG_BACKLIGHT_PROGEAR) += progear_bl.o | 18 | obj-$(CONFIG_BACKLIGHT_PROGEAR) += progear_bl.o |
18 | obj-$(CONFIG_BACKLIGHT_CARILLO_RANCH) += cr_bllcd.o | 19 | obj-$(CONFIG_BACKLIGHT_CARILLO_RANCH) += cr_bllcd.o |
19 | obj-$(CONFIG_BACKLIGHT_PWM) += pwm_bl.o | 20 | obj-$(CONFIG_BACKLIGHT_PWM) += pwm_bl.o |
21 | obj-$(CONFIG_BACKLIGHT_DA903X) += da903x.o | ||
20 | obj-$(CONFIG_BACKLIGHT_MBP_NVIDIA) += mbp_nvidia_bl.o | 22 | obj-$(CONFIG_BACKLIGHT_MBP_NVIDIA) += mbp_nvidia_bl.o |
23 | obj-$(CONFIG_BACKLIGHT_TOSA) += tosa_bl.o | ||
24 | obj-$(CONFIG_BACKLIGHT_SAHARA) += kb3886_bl.o | ||
21 | 25 | ||
diff --git a/drivers/video/backlight/da903x.c b/drivers/video/backlight/da903x.c new file mode 100644 index 000000000000..242c38250166 --- /dev/null +++ b/drivers/video/backlight/da903x.c | |||
@@ -0,0 +1,201 @@ | |||
1 | /* | ||
2 | * Backlight driver for Dialog Semiconductor DA9030/DA9034 | ||
3 | * | ||
4 | * Copyright (C) 2008 Compulab, Ltd. | ||
5 | * Mike Rapoport <mike@compulab.co.il> | ||
6 | * | ||
7 | * Copyright (C) 2006-2008 Marvell International Ltd. | ||
8 | * Eric Miao <eric.miao@marvell.com> | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License version 2 as | ||
12 | * published by the Free Software Foundation. | ||
13 | */ | ||
14 | |||
15 | #include <linux/kernel.h> | ||
16 | #include <linux/init.h> | ||
17 | #include <linux/platform_device.h> | ||
18 | #include <linux/fb.h> | ||
19 | #include <linux/backlight.h> | ||
20 | #include <linux/mfd/da903x.h> | ||
21 | |||
22 | #define DA9030_WLED_CONTROL 0x25 | ||
23 | #define DA9030_WLED_CP_EN (1 << 6) | ||
24 | #define DA9030_WLED_TRIM(x) ((x) & 0x7) | ||
25 | |||
26 | #define DA9034_WLED_CONTROL1 0x3C | ||
27 | #define DA9034_WLED_CONTROL2 0x3D | ||
28 | |||
29 | #define DA9034_WLED_BOOST_EN (1 << 5) | ||
30 | |||
31 | #define DA9030_MAX_BRIGHTNESS 7 | ||
32 | #define DA9034_MAX_BRIGHTNESS 0x7f | ||
33 | |||
34 | struct da903x_backlight_data { | ||
35 | struct device *da903x_dev; | ||
36 | int id; | ||
37 | int current_brightness; | ||
38 | }; | ||
39 | |||
40 | static int da903x_backlight_set(struct backlight_device *bl, int brightness) | ||
41 | { | ||
42 | struct da903x_backlight_data *data = bl_get_data(bl); | ||
43 | struct device *dev = data->da903x_dev; | ||
44 | uint8_t val; | ||
45 | int ret = 0; | ||
46 | |||
47 | switch (data->id) { | ||
48 | case DA9034_ID_WLED: | ||
49 | ret = da903x_update(dev, DA9034_WLED_CONTROL1, | ||
50 | brightness, 0x7f); | ||
51 | if (ret) | ||
52 | return ret; | ||
53 | |||
54 | if (data->current_brightness && brightness == 0) | ||
55 | ret = da903x_clr_bits(dev, | ||
56 | DA9034_WLED_CONTROL2, | ||
57 | DA9034_WLED_BOOST_EN); | ||
58 | |||
59 | if (data->current_brightness == 0 && brightness) | ||
60 | ret = da903x_set_bits(dev, | ||
61 | DA9034_WLED_CONTROL2, | ||
62 | DA9034_WLED_BOOST_EN); | ||
63 | break; | ||
64 | case DA9030_ID_WLED: | ||
65 | val = DA9030_WLED_TRIM(brightness); | ||
66 | val |= brightness ? DA9030_WLED_CP_EN : 0; | ||
67 | ret = da903x_write(dev, DA9030_WLED_CONTROL, val); | ||
68 | break; | ||
69 | } | ||
70 | |||
71 | if (ret) | ||
72 | return ret; | ||
73 | |||
74 | data->current_brightness = brightness; | ||
75 | return 0; | ||
76 | } | ||
77 | |||
78 | static int da903x_backlight_update_status(struct backlight_device *bl) | ||
79 | { | ||
80 | int brightness = bl->props.brightness; | ||
81 | |||
82 | if (bl->props.power != FB_BLANK_UNBLANK) | ||
83 | brightness = 0; | ||
84 | |||
85 | if (bl->props.fb_blank != FB_BLANK_UNBLANK) | ||
86 | brightness = 0; | ||
87 | |||
88 | return da903x_backlight_set(bl, brightness); | ||
89 | } | ||
90 | |||
91 | static int da903x_backlight_get_brightness(struct backlight_device *bl) | ||
92 | { | ||
93 | struct da903x_backlight_data *data = bl_get_data(bl); | ||
94 | return data->current_brightness; | ||
95 | } | ||
96 | |||
97 | static struct backlight_ops da903x_backlight_ops = { | ||
98 | .update_status = da903x_backlight_update_status, | ||
99 | .get_brightness = da903x_backlight_get_brightness, | ||
100 | }; | ||
101 | |||
102 | static int da903x_backlight_probe(struct platform_device *pdev) | ||
103 | { | ||
104 | struct da903x_backlight_data *data; | ||
105 | struct backlight_device *bl; | ||
106 | int max_brightness; | ||
107 | |||
108 | data = kzalloc(sizeof(*data), GFP_KERNEL); | ||
109 | if (data == NULL) | ||
110 | return -ENOMEM; | ||
111 | |||
112 | switch (pdev->id) { | ||
113 | case DA9030_ID_WLED: | ||
114 | max_brightness = DA9030_MAX_BRIGHTNESS; | ||
115 | break; | ||
116 | case DA9034_ID_WLED: | ||
117 | max_brightness = DA9034_MAX_BRIGHTNESS; | ||
118 | break; | ||
119 | default: | ||
120 | dev_err(&pdev->dev, "invalid backlight device ID(%d)\n", | ||
121 | pdev->id); | ||
122 | return -EINVAL; | ||
123 | } | ||
124 | |||
125 | data->id = pdev->id; | ||
126 | data->da903x_dev = pdev->dev.parent; | ||
127 | data->current_brightness = 0; | ||
128 | |||
129 | bl = backlight_device_register(pdev->name, data->da903x_dev, | ||
130 | data, &da903x_backlight_ops); | ||
131 | if (IS_ERR(bl)) { | ||
132 | dev_err(&pdev->dev, "failed to register backlight\n"); | ||
133 | return PTR_ERR(bl); | ||
134 | } | ||
135 | |||
136 | bl->props.max_brightness = max_brightness; | ||
137 | bl->props.brightness = max_brightness; | ||
138 | |||
139 | platform_set_drvdata(pdev, bl); | ||
140 | backlight_update_status(bl); | ||
141 | return 0; | ||
142 | } | ||
143 | |||
144 | static int da903x_backlight_remove(struct platform_device *pdev) | ||
145 | { | ||
146 | struct backlight_device *bl = platform_get_drvdata(pdev); | ||
147 | struct da903x_backlight_data *data = bl_get_data(bl); | ||
148 | |||
149 | backlight_device_unregister(bl); | ||
150 | kfree(data); | ||
151 | return 0; | ||
152 | } | ||
153 | |||
154 | #ifdef CONFIG_PM | ||
155 | static int da903x_backlight_suspend(struct platform_device *pdev, | ||
156 | pm_message_t state) | ||
157 | { | ||
158 | struct backlight_device *bl = platform_get_drvdata(pdev); | ||
159 | return da903x_backlight_set(bl, 0); | ||
160 | } | ||
161 | |||
162 | static int da903x_backlight_resume(struct platform_device *pdev) | ||
163 | { | ||
164 | struct backlight_device *bl = platform_get_drvdata(pdev); | ||
165 | |||
166 | backlight_update_status(bl); | ||
167 | return 0; | ||
168 | } | ||
169 | #else | ||
170 | #define da903x_backlight_suspend NULL | ||
171 | #define da903x_backlight_resume NULL | ||
172 | #endif | ||
173 | |||
174 | static struct platform_driver da903x_backlight_driver = { | ||
175 | .driver = { | ||
176 | .name = "da903x-backlight", | ||
177 | .owner = THIS_MODULE, | ||
178 | }, | ||
179 | .probe = da903x_backlight_probe, | ||
180 | .remove = da903x_backlight_remove, | ||
181 | .suspend = da903x_backlight_suspend, | ||
182 | .resume = da903x_backlight_resume, | ||
183 | }; | ||
184 | |||
185 | static int __init da903x_backlight_init(void) | ||
186 | { | ||
187 | return platform_driver_register(&da903x_backlight_driver); | ||
188 | } | ||
189 | module_init(da903x_backlight_init); | ||
190 | |||
191 | static void __exit da903x_backlight_exit(void) | ||
192 | { | ||
193 | platform_driver_unregister(&da903x_backlight_driver); | ||
194 | } | ||
195 | module_exit(da903x_backlight_exit); | ||
196 | |||
197 | MODULE_DESCRIPTION("Backlight Driver for Dialog Semiconductor DA9030/DA9034"); | ||
198 | MODULE_AUTHOR("Eric Miao <eric.miao@marvell.com>" | ||
199 | "Mike Rapoport <mike@compulab.co.il>"); | ||
200 | MODULE_LICENSE("GPL"); | ||
201 | MODULE_ALIAS("platform:da903x-backlight"); | ||
diff --git a/drivers/video/backlight/kb3886_bl.c b/drivers/video/backlight/kb3886_bl.c new file mode 100644 index 000000000000..a38fda1742dd --- /dev/null +++ b/drivers/video/backlight/kb3886_bl.c | |||
@@ -0,0 +1,204 @@ | |||
1 | /* | ||
2 | * Backlight Driver for the KB3886 Backlight | ||
3 | * | ||
4 | * Copyright (c) 2007-2008 Claudio Nieder | ||
5 | * | ||
6 | * Based on corgi_bl.c by Richard Purdie and kb3886 driver by Robert Woerle | ||
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 version 2 as | ||
10 | * published by the Free Software Foundation. | ||
11 | * | ||
12 | */ | ||
13 | |||
14 | #include <linux/module.h> | ||
15 | #include <linux/kernel.h> | ||
16 | #include <linux/init.h> | ||
17 | #include <linux/platform_device.h> | ||
18 | #include <linux/mutex.h> | ||
19 | #include <linux/fb.h> | ||
20 | #include <linux/backlight.h> | ||
21 | #include <linux/delay.h> | ||
22 | #include <linux/dmi.h> | ||
23 | |||
24 | #define KB3886_PARENT 0x64 | ||
25 | #define KB3886_IO 0x60 | ||
26 | #define KB3886_ADC_DAC_PWM 0xC4 | ||
27 | #define KB3886_PWM0_WRITE 0x81 | ||
28 | #define KB3886_PWM0_READ 0x41 | ||
29 | |||
30 | static DEFINE_MUTEX(bl_mutex); | ||
31 | |||
32 | static void kb3886_bl_set_intensity(int intensity) | ||
33 | { | ||
34 | mutex_lock(&bl_mutex); | ||
35 | intensity = intensity&0xff; | ||
36 | outb(KB3886_ADC_DAC_PWM, KB3886_PARENT); | ||
37 | msleep(10); | ||
38 | outb(KB3886_PWM0_WRITE, KB3886_IO); | ||
39 | msleep(10); | ||
40 | outb(intensity, KB3886_IO); | ||
41 | mutex_unlock(&bl_mutex); | ||
42 | } | ||
43 | |||
44 | struct kb3886bl_machinfo { | ||
45 | int max_intensity; | ||
46 | int default_intensity; | ||
47 | int limit_mask; | ||
48 | void (*set_bl_intensity)(int intensity); | ||
49 | }; | ||
50 | |||
51 | static struct kb3886bl_machinfo kb3886_bl_machinfo = { | ||
52 | .max_intensity = 0xff, | ||
53 | .default_intensity = 0xa0, | ||
54 | .limit_mask = 0x7f, | ||
55 | .set_bl_intensity = kb3886_bl_set_intensity, | ||
56 | }; | ||
57 | |||
58 | static struct platform_device kb3886bl_device = { | ||
59 | .name = "kb3886-bl", | ||
60 | .dev = { | ||
61 | .platform_data = &kb3886_bl_machinfo, | ||
62 | }, | ||
63 | .id = -1, | ||
64 | }; | ||
65 | |||
66 | static struct platform_device *devices[] __initdata = { | ||
67 | &kb3886bl_device, | ||
68 | }; | ||
69 | |||
70 | /* | ||
71 | * Back to driver | ||
72 | */ | ||
73 | |||
74 | static int kb3886bl_intensity; | ||
75 | static struct backlight_device *kb3886_backlight_device; | ||
76 | static struct kb3886bl_machinfo *bl_machinfo; | ||
77 | |||
78 | static unsigned long kb3886bl_flags; | ||
79 | #define KB3886BL_SUSPENDED 0x01 | ||
80 | |||
81 | static struct dmi_system_id __initdata kb3886bl_device_table[] = { | ||
82 | { | ||
83 | .ident = "Sahara Touch-iT", | ||
84 | .matches = { | ||
85 | DMI_MATCH(DMI_SYS_VENDOR, "SDV"), | ||
86 | DMI_MATCH(DMI_PRODUCT_NAME, "iTouch T201"), | ||
87 | }, | ||
88 | }, | ||
89 | { } | ||
90 | }; | ||
91 | |||
92 | static int kb3886bl_send_intensity(struct backlight_device *bd) | ||
93 | { | ||
94 | int intensity = bd->props.brightness; | ||
95 | |||
96 | if (bd->props.power != FB_BLANK_UNBLANK) | ||
97 | intensity = 0; | ||
98 | if (bd->props.fb_blank != FB_BLANK_UNBLANK) | ||
99 | intensity = 0; | ||
100 | if (kb3886bl_flags & KB3886BL_SUSPENDED) | ||
101 | intensity = 0; | ||
102 | |||
103 | bl_machinfo->set_bl_intensity(intensity); | ||
104 | |||
105 | kb3886bl_intensity = intensity; | ||
106 | return 0; | ||
107 | } | ||
108 | |||
109 | #ifdef CONFIG_PM | ||
110 | static int kb3886bl_suspend(struct platform_device *pdev, pm_message_t state) | ||
111 | { | ||
112 | struct backlight_device *bd = platform_get_drvdata(pdev); | ||
113 | |||
114 | kb3886bl_flags |= KB3886BL_SUSPENDED; | ||
115 | backlight_update_status(bd); | ||
116 | return 0; | ||
117 | } | ||
118 | |||
119 | static int kb3886bl_resume(struct platform_device *pdev) | ||
120 | { | ||
121 | struct backlight_device *bd = platform_get_drvdata(pdev); | ||
122 | |||
123 | kb3886bl_flags &= ~KB3886BL_SUSPENDED; | ||
124 | backlight_update_status(bd); | ||
125 | return 0; | ||
126 | } | ||
127 | #else | ||
128 | #define kb3886bl_suspend NULL | ||
129 | #define kb3886bl_resume NULL | ||
130 | #endif | ||
131 | |||
132 | static int kb3886bl_get_intensity(struct backlight_device *bd) | ||
133 | { | ||
134 | return kb3886bl_intensity; | ||
135 | } | ||
136 | |||
137 | static struct backlight_ops kb3886bl_ops = { | ||
138 | .get_brightness = kb3886bl_get_intensity, | ||
139 | .update_status = kb3886bl_send_intensity, | ||
140 | }; | ||
141 | |||
142 | static int kb3886bl_probe(struct platform_device *pdev) | ||
143 | { | ||
144 | struct kb3886bl_machinfo *machinfo = pdev->dev.platform_data; | ||
145 | |||
146 | bl_machinfo = machinfo; | ||
147 | if (!machinfo->limit_mask) | ||
148 | machinfo->limit_mask = -1; | ||
149 | |||
150 | kb3886_backlight_device = backlight_device_register("kb3886-bl", | ||
151 | &pdev->dev, NULL, &kb3886bl_ops); | ||
152 | if (IS_ERR(kb3886_backlight_device)) | ||
153 | return PTR_ERR(kb3886_backlight_device); | ||
154 | |||
155 | platform_set_drvdata(pdev, kb3886_backlight_device); | ||
156 | |||
157 | kb3886_backlight_device->props.max_brightness = machinfo->max_intensity; | ||
158 | kb3886_backlight_device->props.power = FB_BLANK_UNBLANK; | ||
159 | kb3886_backlight_device->props.brightness = machinfo->default_intensity; | ||
160 | backlight_update_status(kb3886_backlight_device); | ||
161 | |||
162 | return 0; | ||
163 | } | ||
164 | |||
165 | static int kb3886bl_remove(struct platform_device *pdev) | ||
166 | { | ||
167 | struct backlight_device *bd = platform_get_drvdata(pdev); | ||
168 | |||
169 | backlight_device_unregister(bd); | ||
170 | |||
171 | return 0; | ||
172 | } | ||
173 | |||
174 | static struct platform_driver kb3886bl_driver = { | ||
175 | .probe = kb3886bl_probe, | ||
176 | .remove = kb3886bl_remove, | ||
177 | .suspend = kb3886bl_suspend, | ||
178 | .resume = kb3886bl_resume, | ||
179 | .driver = { | ||
180 | .name = "kb3886-bl", | ||
181 | }, | ||
182 | }; | ||
183 | |||
184 | static int __init kb3886_init(void) | ||
185 | { | ||
186 | if (!dmi_check_system(kb3886bl_device_table)) | ||
187 | return -ENODEV; | ||
188 | |||
189 | platform_add_devices(devices, ARRAY_SIZE(devices)); | ||
190 | return platform_driver_register(&kb3886bl_driver); | ||
191 | } | ||
192 | |||
193 | static void __exit kb3886_exit(void) | ||
194 | { | ||
195 | platform_driver_unregister(&kb3886bl_driver); | ||
196 | } | ||
197 | |||
198 | module_init(kb3886_init); | ||
199 | module_exit(kb3886_exit); | ||
200 | |||
201 | MODULE_AUTHOR("Claudio Nieder <private@claudio.ch>"); | ||
202 | MODULE_DESCRIPTION("Tabletkiosk Sahara Touch-iT Backlight Driver"); | ||
203 | MODULE_LICENSE("GPL"); | ||
204 | MODULE_ALIAS("dmi:*:svnSDV:pniTouchT201:*"); | ||
diff --git a/drivers/video/backlight/tosa_bl.c b/drivers/video/backlight/tosa_bl.c new file mode 100644 index 000000000000..43edbada12d1 --- /dev/null +++ b/drivers/video/backlight/tosa_bl.c | |||
@@ -0,0 +1,198 @@ | |||
1 | /* | ||
2 | * LCD / Backlight control code for Sharp SL-6000x (tosa) | ||
3 | * | ||
4 | * Copyright (c) 2005 Dirk Opfer | ||
5 | * Copyright (c) 2007,2008 Dmitry Baryshkov | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License version 2 as | ||
9 | * published by the Free Software Foundation. | ||
10 | * | ||
11 | */ | ||
12 | |||
13 | #include <linux/kernel.h> | ||
14 | #include <linux/module.h> | ||
15 | #include <linux/device.h> | ||
16 | #include <linux/spi/spi.h> | ||
17 | #include <linux/i2c.h> | ||
18 | #include <linux/gpio.h> | ||
19 | #include <linux/fb.h> | ||
20 | #include <linux/backlight.h> | ||
21 | |||
22 | #include <asm/mach/sharpsl_param.h> | ||
23 | |||
24 | #include <mach/tosa.h> | ||
25 | |||
26 | #define COMADJ_DEFAULT 97 | ||
27 | |||
28 | #define DAC_CH1 0 | ||
29 | #define DAC_CH2 1 | ||
30 | |||
31 | struct tosa_bl_data { | ||
32 | struct i2c_client *i2c; | ||
33 | struct backlight_device *bl; | ||
34 | |||
35 | int comadj; | ||
36 | }; | ||
37 | |||
38 | static void tosa_bl_set_backlight(struct tosa_bl_data *data, int brightness) | ||
39 | { | ||
40 | struct spi_device *spi = data->i2c->dev.platform_data; | ||
41 | |||
42 | i2c_smbus_write_byte_data(data->i2c, DAC_CH1, data->comadj); | ||
43 | |||
44 | /* SetBacklightDuty */ | ||
45 | i2c_smbus_write_byte_data(data->i2c, DAC_CH2, (u8)(brightness & 0xff)); | ||
46 | |||
47 | /* SetBacklightVR */ | ||
48 | gpio_set_value(TOSA_GPIO_BL_C20MA, brightness & 0x100); | ||
49 | |||
50 | tosa_bl_enable(spi, brightness); | ||
51 | } | ||
52 | |||
53 | static int tosa_bl_update_status(struct backlight_device *dev) | ||
54 | { | ||
55 | struct backlight_properties *props = &dev->props; | ||
56 | struct tosa_bl_data *data = dev_get_drvdata(&dev->dev); | ||
57 | int power = max(props->power, props->fb_blank); | ||
58 | int brightness = props->brightness; | ||
59 | |||
60 | if (power) | ||
61 | brightness = 0; | ||
62 | |||
63 | tosa_bl_set_backlight(data, brightness); | ||
64 | |||
65 | return 0; | ||
66 | } | ||
67 | |||
68 | static int tosa_bl_get_brightness(struct backlight_device *dev) | ||
69 | { | ||
70 | struct backlight_properties *props = &dev->props; | ||
71 | |||
72 | return props->brightness; | ||
73 | } | ||
74 | |||
75 | static struct backlight_ops bl_ops = { | ||
76 | .get_brightness = tosa_bl_get_brightness, | ||
77 | .update_status = tosa_bl_update_status, | ||
78 | }; | ||
79 | |||
80 | static int __devinit tosa_bl_probe(struct i2c_client *client, | ||
81 | const struct i2c_device_id *id) | ||
82 | { | ||
83 | struct tosa_bl_data *data = kzalloc(sizeof(struct tosa_bl_data), GFP_KERNEL); | ||
84 | int ret = 0; | ||
85 | if (!data) | ||
86 | return -ENOMEM; | ||
87 | |||
88 | data->comadj = sharpsl_param.comadj == -1 ? COMADJ_DEFAULT : sharpsl_param.comadj; | ||
89 | |||
90 | ret = gpio_request(TOSA_GPIO_BL_C20MA, "backlight"); | ||
91 | if (ret) { | ||
92 | dev_dbg(&data->bl->dev, "Unable to request gpio!\n"); | ||
93 | goto err_gpio_bl; | ||
94 | } | ||
95 | ret = gpio_direction_output(TOSA_GPIO_BL_C20MA, 0); | ||
96 | if (ret) | ||
97 | goto err_gpio_dir; | ||
98 | |||
99 | i2c_set_clientdata(client, data); | ||
100 | data->i2c = client; | ||
101 | |||
102 | data->bl = backlight_device_register("tosa-bl", &client->dev, | ||
103 | data, &bl_ops); | ||
104 | if (IS_ERR(data->bl)) { | ||
105 | ret = PTR_ERR(data->bl); | ||
106 | goto err_reg; | ||
107 | } | ||
108 | |||
109 | data->bl->props.brightness = 69; | ||
110 | data->bl->props.max_brightness = 512 - 1; | ||
111 | data->bl->props.power = FB_BLANK_UNBLANK; | ||
112 | |||
113 | backlight_update_status(data->bl); | ||
114 | |||
115 | return 0; | ||
116 | |||
117 | err_reg: | ||
118 | data->bl = NULL; | ||
119 | i2c_set_clientdata(client, NULL); | ||
120 | err_gpio_dir: | ||
121 | gpio_free(TOSA_GPIO_BL_C20MA); | ||
122 | err_gpio_bl: | ||
123 | kfree(data); | ||
124 | return ret; | ||
125 | } | ||
126 | |||
127 | static int __devexit tosa_bl_remove(struct i2c_client *client) | ||
128 | { | ||
129 | struct tosa_bl_data *data = i2c_get_clientdata(client); | ||
130 | |||
131 | backlight_device_unregister(data->bl); | ||
132 | data->bl = NULL; | ||
133 | i2c_set_clientdata(client, NULL); | ||
134 | |||
135 | gpio_free(TOSA_GPIO_BL_C20MA); | ||
136 | |||
137 | kfree(data); | ||
138 | |||
139 | return 0; | ||
140 | } | ||
141 | |||
142 | #ifdef CONFIG_PM | ||
143 | static int tosa_bl_suspend(struct i2c_client *client, pm_message_t pm) | ||
144 | { | ||
145 | struct tosa_bl_data *data = i2c_get_clientdata(client); | ||
146 | |||
147 | tosa_bl_set_backlight(data, 0); | ||
148 | |||
149 | return 0; | ||
150 | } | ||
151 | |||
152 | static int tosa_bl_resume(struct i2c_client *client) | ||
153 | { | ||
154 | struct tosa_bl_data *data = i2c_get_clientdata(client); | ||
155 | |||
156 | backlight_update_status(data->bl); | ||
157 | return 0; | ||
158 | } | ||
159 | #else | ||
160 | #define tosa_bl_suspend NULL | ||
161 | #define tosa_bl_resume NULL | ||
162 | #endif | ||
163 | |||
164 | static const struct i2c_device_id tosa_bl_id[] = { | ||
165 | { "tosa-bl", 0 }, | ||
166 | { }, | ||
167 | }; | ||
168 | |||
169 | |||
170 | static struct i2c_driver tosa_bl_driver = { | ||
171 | .driver = { | ||
172 | .name = "tosa-bl", | ||
173 | .owner = THIS_MODULE, | ||
174 | }, | ||
175 | .probe = tosa_bl_probe, | ||
176 | .remove = __devexit_p(tosa_bl_remove), | ||
177 | .suspend = tosa_bl_suspend, | ||
178 | .resume = tosa_bl_resume, | ||
179 | .id_table = tosa_bl_id, | ||
180 | }; | ||
181 | |||
182 | static int __init tosa_bl_init(void) | ||
183 | { | ||
184 | return i2c_add_driver(&tosa_bl_driver); | ||
185 | } | ||
186 | |||
187 | static void __exit tosa_bl_exit(void) | ||
188 | { | ||
189 | i2c_del_driver(&tosa_bl_driver); | ||
190 | } | ||
191 | |||
192 | module_init(tosa_bl_init); | ||
193 | module_exit(tosa_bl_exit); | ||
194 | |||
195 | MODULE_AUTHOR("Dmitry Baryshkov"); | ||
196 | MODULE_LICENSE("GPL v2"); | ||
197 | MODULE_DESCRIPTION("LCD/Backlight control for Sharp SL-6000 PDA"); | ||
198 | |||
diff --git a/drivers/video/backlight/tosa_lcd.c b/drivers/video/backlight/tosa_lcd.c new file mode 100644 index 000000000000..57a26649f1a5 --- /dev/null +++ b/drivers/video/backlight/tosa_lcd.c | |||
@@ -0,0 +1,280 @@ | |||
1 | /* | ||
2 | * LCD / Backlight control code for Sharp SL-6000x (tosa) | ||
3 | * | ||
4 | * Copyright (c) 2005 Dirk Opfer | ||
5 | * Copyright (c) 2007,2008 Dmitry Baryshkov | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License version 2 as | ||
9 | * published by the Free Software Foundation. | ||
10 | * | ||
11 | */ | ||
12 | |||
13 | #include <linux/kernel.h> | ||
14 | #include <linux/module.h> | ||
15 | #include <linux/device.h> | ||
16 | #include <linux/spi/spi.h> | ||
17 | #include <linux/i2c.h> | ||
18 | #include <linux/gpio.h> | ||
19 | #include <linux/delay.h> | ||
20 | #include <linux/lcd.h> | ||
21 | #include <linux/fb.h> | ||
22 | |||
23 | #include <asm/mach/sharpsl_param.h> | ||
24 | |||
25 | #include <mach/tosa.h> | ||
26 | |||
27 | #define POWER_IS_ON(pwr) ((pwr) <= FB_BLANK_NORMAL) | ||
28 | |||
29 | #define TG_REG0_VQV 0x0001 | ||
30 | #define TG_REG0_COLOR 0x0002 | ||
31 | #define TG_REG0_UD 0x0004 | ||
32 | #define TG_REG0_LR 0x0008 | ||
33 | |||
34 | #define DAC_BASE 0x4e | ||
35 | |||
36 | struct tosa_lcd_data { | ||
37 | struct spi_device *spi; | ||
38 | struct lcd_device *lcd; | ||
39 | struct i2c_client *i2c; | ||
40 | |||
41 | int lcd_power; | ||
42 | }; | ||
43 | |||
44 | static int tosa_tg_send(struct spi_device *spi, int adrs, uint8_t data) | ||
45 | { | ||
46 | u8 buf[1]; | ||
47 | struct spi_message msg; | ||
48 | struct spi_transfer xfer = { | ||
49 | .len = 1, | ||
50 | .cs_change = 1, | ||
51 | .tx_buf = buf, | ||
52 | }; | ||
53 | |||
54 | buf[0] = ((adrs & 0x07) << 5) | (data & 0x1f); | ||
55 | spi_message_init(&msg); | ||
56 | spi_message_add_tail(&xfer, &msg); | ||
57 | |||
58 | return spi_sync(spi, &msg); | ||
59 | } | ||
60 | |||
61 | int tosa_bl_enable(struct spi_device *spi, int enable) | ||
62 | { | ||
63 | /* bl_enable GP04=1 otherwise GP04=0*/ | ||
64 | return tosa_tg_send(spi, TG_GPODR2, enable? 0x01 : 0x00); | ||
65 | } | ||
66 | EXPORT_SYMBOL(tosa_bl_enable); | ||
67 | |||
68 | static void tosa_lcd_tg_init(struct tosa_lcd_data *data) | ||
69 | { | ||
70 | /* TG on */ | ||
71 | gpio_set_value(TOSA_GPIO_TG_ON, 0); | ||
72 | |||
73 | mdelay(60); | ||
74 | |||
75 | /* delayed 0clk TCTL signal for VGA */ | ||
76 | tosa_tg_send(data->spi, TG_TPOSCTL, 0x00); | ||
77 | /* GPOS0=powercontrol, GPOS1=GPIO, GPOS2=TCTL */ | ||
78 | tosa_tg_send(data->spi, TG_GPOSR, 0x02); | ||
79 | } | ||
80 | |||
81 | static void tosa_lcd_tg_on(struct tosa_lcd_data *data) | ||
82 | { | ||
83 | struct spi_device *spi = data->spi; | ||
84 | const int value = TG_REG0_COLOR | TG_REG0_UD | TG_REG0_LR; | ||
85 | tosa_tg_send(spi, TG_PNLCTL, value | TG_REG0_VQV); /* this depends on mode */ | ||
86 | |||
87 | /* TG LCD pannel power up */ | ||
88 | tosa_tg_send(spi, TG_PINICTL,0x4); | ||
89 | mdelay(50); | ||
90 | |||
91 | /* TG LCD GVSS */ | ||
92 | tosa_tg_send(spi, TG_PINICTL,0x0); | ||
93 | |||
94 | if (!data->i2c) { | ||
95 | /* after the pannel is powered up the first time, we can access the i2c bus */ | ||
96 | /* so probe for the DAC */ | ||
97 | struct i2c_adapter *adap = i2c_get_adapter(0); | ||
98 | struct i2c_board_info info = { | ||
99 | .type = "tosa-bl", | ||
100 | .addr = DAC_BASE, | ||
101 | .platform_data = data->spi, | ||
102 | }; | ||
103 | data->i2c = i2c_new_device(adap, &info); | ||
104 | } | ||
105 | } | ||
106 | |||
107 | static void tosa_lcd_tg_off(struct tosa_lcd_data *data) | ||
108 | { | ||
109 | struct spi_device *spi = data->spi; | ||
110 | |||
111 | /* TG LCD VHSA off */ | ||
112 | tosa_tg_send(spi, TG_PINICTL,0x4); | ||
113 | mdelay(50); | ||
114 | |||
115 | /* TG LCD signal off */ | ||
116 | tosa_tg_send(spi, TG_PINICTL,0x6); | ||
117 | mdelay(50); | ||
118 | |||
119 | /* TG Off */ | ||
120 | gpio_set_value(TOSA_GPIO_TG_ON, 1); | ||
121 | mdelay(100); | ||
122 | } | ||
123 | |||
124 | int tosa_lcd_set_power(struct lcd_device *lcd, int power) | ||
125 | { | ||
126 | struct tosa_lcd_data *data = lcd_get_data(lcd); | ||
127 | |||
128 | if (POWER_IS_ON(power) && !POWER_IS_ON(data->lcd_power)) | ||
129 | tosa_lcd_tg_on(data); | ||
130 | |||
131 | if (!POWER_IS_ON(power) && POWER_IS_ON(data->lcd_power)) | ||
132 | tosa_lcd_tg_off(data); | ||
133 | |||
134 | data->lcd_power = power; | ||
135 | return 0; | ||
136 | } | ||
137 | |||
138 | static int tosa_lcd_get_power(struct lcd_device *lcd) | ||
139 | { | ||
140 | struct tosa_lcd_data *data = lcd_get_data(lcd); | ||
141 | |||
142 | return data->lcd_power; | ||
143 | } | ||
144 | |||
145 | static struct lcd_ops tosa_lcd_ops = { | ||
146 | .set_power = tosa_lcd_set_power, | ||
147 | .get_power = tosa_lcd_get_power, | ||
148 | }; | ||
149 | |||
150 | static int __devinit tosa_lcd_probe(struct spi_device *spi) | ||
151 | { | ||
152 | int ret; | ||
153 | struct tosa_lcd_data *data; | ||
154 | |||
155 | data = kzalloc(sizeof(struct tosa_lcd_data), GFP_KERNEL); | ||
156 | if (!data) | ||
157 | return -ENOMEM; | ||
158 | |||
159 | /* | ||
160 | * bits_per_word cannot be configured in platform data | ||
161 | */ | ||
162 | spi->bits_per_word = 8; | ||
163 | |||
164 | ret = spi_setup(spi); | ||
165 | if (ret < 0) | ||
166 | goto err_spi; | ||
167 | |||
168 | data->spi = spi; | ||
169 | dev_set_drvdata(&spi->dev, data); | ||
170 | |||
171 | ret = gpio_request(TOSA_GPIO_TG_ON, "tg #pwr"); | ||
172 | if (ret < 0) | ||
173 | goto err_gpio_tg; | ||
174 | |||
175 | mdelay(60); | ||
176 | |||
177 | ret = gpio_direction_output(TOSA_GPIO_TG_ON, 0); | ||
178 | if (ret < 0) | ||
179 | goto err_gpio_dir; | ||
180 | |||
181 | mdelay(60); | ||
182 | tosa_lcd_tg_init(data); | ||
183 | |||
184 | tosa_lcd_tg_on(data); | ||
185 | |||
186 | data->lcd = lcd_device_register("tosa-lcd", &spi->dev, data, | ||
187 | &tosa_lcd_ops); | ||
188 | |||
189 | if (IS_ERR(data->lcd)) { | ||
190 | ret = PTR_ERR(data->lcd); | ||
191 | data->lcd = NULL; | ||
192 | goto err_register; | ||
193 | } | ||
194 | |||
195 | return 0; | ||
196 | |||
197 | err_register: | ||
198 | tosa_lcd_tg_off(data); | ||
199 | err_gpio_dir: | ||
200 | gpio_free(TOSA_GPIO_TG_ON); | ||
201 | err_gpio_tg: | ||
202 | dev_set_drvdata(&spi->dev, NULL); | ||
203 | err_spi: | ||
204 | kfree(data); | ||
205 | return ret; | ||
206 | } | ||
207 | |||
208 | static int __devexit tosa_lcd_remove(struct spi_device *spi) | ||
209 | { | ||
210 | struct tosa_lcd_data *data = dev_get_drvdata(&spi->dev); | ||
211 | |||
212 | lcd_device_unregister(data->lcd); | ||
213 | |||
214 | if (data->i2c) | ||
215 | i2c_unregister_device(data->i2c); | ||
216 | |||
217 | tosa_lcd_tg_off(data); | ||
218 | |||
219 | gpio_free(TOSA_GPIO_TG_ON); | ||
220 | dev_set_drvdata(&spi->dev, NULL); | ||
221 | kfree(data); | ||
222 | |||
223 | return 0; | ||
224 | } | ||
225 | |||
226 | #ifdef CONFIG_PM | ||
227 | static int tosa_lcd_suspend(struct spi_device *spi, pm_message_t state) | ||
228 | { | ||
229 | struct tosa_lcd_data *data = dev_get_drvdata(&spi->dev); | ||
230 | |||
231 | tosa_lcd_tg_off(data); | ||
232 | |||
233 | return 0; | ||
234 | } | ||
235 | |||
236 | static int tosa_lcd_resume(struct spi_device *spi) | ||
237 | { | ||
238 | struct tosa_lcd_data *data = dev_get_drvdata(&spi->dev); | ||
239 | |||
240 | tosa_lcd_tg_init(data); | ||
241 | if (POWER_IS_ON(data->lcd_power)) | ||
242 | tosa_lcd_tg_on(data); | ||
243 | else | ||
244 | tosa_lcd_tg_off(data); | ||
245 | |||
246 | return 0; | ||
247 | } | ||
248 | #else | ||
249 | #define tosa_lcd_suspend NULL | ||
250 | #define tosa_lcd_reume NULL | ||
251 | #endif | ||
252 | |||
253 | static struct spi_driver tosa_lcd_driver = { | ||
254 | .driver = { | ||
255 | .name = "tosa-lcd", | ||
256 | .owner = THIS_MODULE, | ||
257 | }, | ||
258 | .probe = tosa_lcd_probe, | ||
259 | .remove = __devexit_p(tosa_lcd_remove), | ||
260 | .suspend = tosa_lcd_suspend, | ||
261 | .resume = tosa_lcd_resume, | ||
262 | }; | ||
263 | |||
264 | static int __init tosa_lcd_init(void) | ||
265 | { | ||
266 | return spi_register_driver(&tosa_lcd_driver); | ||
267 | } | ||
268 | |||
269 | static void __exit tosa_lcd_exit(void) | ||
270 | { | ||
271 | spi_unregister_driver(&tosa_lcd_driver); | ||
272 | } | ||
273 | |||
274 | module_init(tosa_lcd_init); | ||
275 | module_exit(tosa_lcd_exit); | ||
276 | |||
277 | MODULE_AUTHOR("Dmitry Baryshkov"); | ||
278 | MODULE_LICENSE("GPL v2"); | ||
279 | MODULE_DESCRIPTION("LCD/Backlight control for Sharp SL-6000 PDA"); | ||
280 | |||
diff --git a/fs/coda/psdev.c b/fs/coda/psdev.c index cfd29da714d1..0376ac66c44a 100644 --- a/fs/coda/psdev.c +++ b/fs/coda/psdev.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * An implementation of a loadable kernel mode driver providing | 2 | * An implementation of a loadable kernel mode driver providing |
3 | * multiple kernel/user space bidirectional communications links. | 3 | * multiple kernel/user space bidirectional communications links. |
4 | * | 4 | * |
5 | * Author: Alan Cox <alan@redhat.com> | 5 | * Author: Alan Cox <alan@lxorguk.ukuu.org.uk> |
6 | * | 6 | * |
7 | * This program is free software; you can redistribute it and/or | 7 | * This program is free software; you can redistribute it and/or |
8 | * modify it under the terms of the GNU General Public License | 8 | * modify it under the terms of the GNU General Public License |
diff --git a/fs/compat.c b/fs/compat.c index fe3c9bf87608..e5f49f538502 100644 --- a/fs/compat.c +++ b/fs/compat.c | |||
@@ -1684,8 +1684,9 @@ asmlinkage long compat_sys_select(int n, compat_ulong_t __user *inp, | |||
1684 | return -EFAULT; | 1684 | return -EFAULT; |
1685 | 1685 | ||
1686 | to = &end_time; | 1686 | to = &end_time; |
1687 | if (poll_select_set_timeout(to, tv.tv_sec, | 1687 | if (poll_select_set_timeout(to, |
1688 | tv.tv_usec * NSEC_PER_USEC)) | 1688 | tv.tv_sec + (tv.tv_usec / USEC_PER_SEC), |
1689 | (tv.tv_usec % USEC_PER_SEC) * NSEC_PER_USEC)) | ||
1689 | return -EINVAL; | 1690 | return -EINVAL; |
1690 | } | 1691 | } |
1691 | 1692 | ||
diff --git a/fs/eventpoll.c b/fs/eventpoll.c index 99368bda0261..aec5c13f6341 100644 --- a/fs/eventpoll.c +++ b/fs/eventpoll.c | |||
@@ -930,8 +930,15 @@ errxit: | |||
930 | * inside the main ready-list here. | 930 | * inside the main ready-list here. |
931 | */ | 931 | */ |
932 | for (nepi = ep->ovflist; (epi = nepi) != NULL; | 932 | for (nepi = ep->ovflist; (epi = nepi) != NULL; |
933 | nepi = epi->next, epi->next = EP_UNACTIVE_PTR) | 933 | nepi = epi->next, epi->next = EP_UNACTIVE_PTR) { |
934 | list_add_tail(&epi->rdllink, &ep->rdllist); | 934 | /* |
935 | * If the above loop quit with errors, the epoll item might still | ||
936 | * be linked to "txlist", and the list_splice() done below will | ||
937 | * take care of those cases. | ||
938 | */ | ||
939 | if (!ep_is_linked(&epi->rdllink)) | ||
940 | list_add_tail(&epi->rdllink, &ep->rdllist); | ||
941 | } | ||
935 | /* | 942 | /* |
936 | * We need to set back ep->ovflist to EP_UNACTIVE_PTR, so that after | 943 | * We need to set back ep->ovflist to EP_UNACTIVE_PTR, so that after |
937 | * releasing the lock, events will be queued in the normal way inside | 944 | * releasing the lock, events will be queued in the normal way inside |
diff --git a/fs/ext3/dir.c b/fs/ext3/dir.c index 4c82531ea0a8..5853f4440af4 100644 --- a/fs/ext3/dir.c +++ b/fs/ext3/dir.c | |||
@@ -456,17 +456,8 @@ static int ext3_dx_readdir(struct file * filp, | |||
456 | if (info->extra_fname) { | 456 | if (info->extra_fname) { |
457 | if (call_filldir(filp, dirent, filldir, info->extra_fname)) | 457 | if (call_filldir(filp, dirent, filldir, info->extra_fname)) |
458 | goto finished; | 458 | goto finished; |
459 | |||
460 | info->extra_fname = NULL; | 459 | info->extra_fname = NULL; |
461 | info->curr_node = rb_next(info->curr_node); | 460 | goto next_node; |
462 | if (!info->curr_node) { | ||
463 | if (info->next_hash == ~0) { | ||
464 | filp->f_pos = EXT3_HTREE_EOF; | ||
465 | goto finished; | ||
466 | } | ||
467 | info->curr_hash = info->next_hash; | ||
468 | info->curr_minor_hash = 0; | ||
469 | } | ||
470 | } else if (!info->curr_node) | 461 | } else if (!info->curr_node) |
471 | info->curr_node = rb_first(&info->root); | 462 | info->curr_node = rb_first(&info->root); |
472 | 463 | ||
@@ -498,9 +489,14 @@ static int ext3_dx_readdir(struct file * filp, | |||
498 | info->curr_minor_hash = fname->minor_hash; | 489 | info->curr_minor_hash = fname->minor_hash; |
499 | if (call_filldir(filp, dirent, filldir, fname)) | 490 | if (call_filldir(filp, dirent, filldir, fname)) |
500 | break; | 491 | break; |
501 | 492 | next_node: | |
502 | info->curr_node = rb_next(info->curr_node); | 493 | info->curr_node = rb_next(info->curr_node); |
503 | if (!info->curr_node) { | 494 | if (info->curr_node) { |
495 | fname = rb_entry(info->curr_node, struct fname, | ||
496 | rb_hash); | ||
497 | info->curr_hash = fname->hash; | ||
498 | info->curr_minor_hash = fname->minor_hash; | ||
499 | } else { | ||
504 | if (info->next_hash == ~0) { | 500 | if (info->next_hash == ~0) { |
505 | filp->f_pos = EXT3_HTREE_EOF; | 501 | filp->f_pos = EXT3_HTREE_EOF; |
506 | break; | 502 | break; |
diff --git a/fs/ext4/dir.c b/fs/ext4/dir.c index 3ca6a2b7632d..fed5b610df5a 100644 --- a/fs/ext4/dir.c +++ b/fs/ext4/dir.c | |||
@@ -459,17 +459,8 @@ static int ext4_dx_readdir(struct file *filp, | |||
459 | if (info->extra_fname) { | 459 | if (info->extra_fname) { |
460 | if (call_filldir(filp, dirent, filldir, info->extra_fname)) | 460 | if (call_filldir(filp, dirent, filldir, info->extra_fname)) |
461 | goto finished; | 461 | goto finished; |
462 | |||
463 | info->extra_fname = NULL; | 462 | info->extra_fname = NULL; |
464 | info->curr_node = rb_next(info->curr_node); | 463 | goto next_node; |
465 | if (!info->curr_node) { | ||
466 | if (info->next_hash == ~0) { | ||
467 | filp->f_pos = EXT4_HTREE_EOF; | ||
468 | goto finished; | ||
469 | } | ||
470 | info->curr_hash = info->next_hash; | ||
471 | info->curr_minor_hash = 0; | ||
472 | } | ||
473 | } else if (!info->curr_node) | 464 | } else if (!info->curr_node) |
474 | info->curr_node = rb_first(&info->root); | 465 | info->curr_node = rb_first(&info->root); |
475 | 466 | ||
@@ -501,9 +492,14 @@ static int ext4_dx_readdir(struct file *filp, | |||
501 | info->curr_minor_hash = fname->minor_hash; | 492 | info->curr_minor_hash = fname->minor_hash; |
502 | if (call_filldir(filp, dirent, filldir, fname)) | 493 | if (call_filldir(filp, dirent, filldir, fname)) |
503 | break; | 494 | break; |
504 | 495 | next_node: | |
505 | info->curr_node = rb_next(info->curr_node); | 496 | info->curr_node = rb_next(info->curr_node); |
506 | if (!info->curr_node) { | 497 | if (info->curr_node) { |
498 | fname = rb_entry(info->curr_node, struct fname, | ||
499 | rb_hash); | ||
500 | info->curr_hash = fname->hash; | ||
501 | info->curr_minor_hash = fname->minor_hash; | ||
502 | } else { | ||
507 | if (info->next_hash == ~0) { | 503 | if (info->next_hash == ~0) { |
508 | filp->f_pos = EXT4_HTREE_EOF; | 504 | filp->f_pos = EXT4_HTREE_EOF; |
509 | break; | 505 | break; |
diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c index b9195c02a863..dc52793ff8f8 100644 --- a/fs/nfs/inode.c +++ b/fs/nfs/inode.c | |||
@@ -5,7 +5,7 @@ | |||
5 | * | 5 | * |
6 | * nfs inode and superblock handling functions | 6 | * nfs inode and superblock handling functions |
7 | * | 7 | * |
8 | * Modularised by Alan Cox <Alan.Cox@linux.org>, while hacking some | 8 | * Modularised by Alan Cox <alan@lxorguk.ukuu.org.uk>, while hacking some |
9 | * experimental NFS changes. Modularisation taken straight from SYS5 fs. | 9 | * experimental NFS changes. Modularisation taken straight from SYS5 fs. |
10 | * | 10 | * |
11 | * Change to nfs_read_super() to permit NFS mounts to multi-homed hosts. | 11 | * Change to nfs_read_super() to permit NFS mounts to multi-homed hosts. |
diff --git a/fs/nfs/super.c b/fs/nfs/super.c index a3b0061dfd45..f48db679a1c6 100644 --- a/fs/nfs/super.c +++ b/fs/nfs/super.c | |||
@@ -5,7 +5,7 @@ | |||
5 | * | 5 | * |
6 | * nfs superblock handling functions | 6 | * nfs superblock handling functions |
7 | * | 7 | * |
8 | * Modularised by Alan Cox <Alan.Cox@linux.org>, while hacking some | 8 | * Modularised by Alan Cox <alan@lxorguk.ukuu.org.uk>, while hacking some |
9 | * experimental NFS changes. Modularisation taken straight from SYS5 fs. | 9 | * experimental NFS changes. Modularisation taken straight from SYS5 fs. |
10 | * | 10 | * |
11 | * Change to nfs_read_super() to permit NFS mounts to multi-homed hosts. | 11 | * Change to nfs_read_super() to permit NFS mounts to multi-homed hosts. |
diff --git a/fs/proc/array.c b/fs/proc/array.c index bb9f4b05703d..6af7fba7abb1 100644 --- a/fs/proc/array.c +++ b/fs/proc/array.c | |||
@@ -40,7 +40,7 @@ | |||
40 | * | 40 | * |
41 | * | 41 | * |
42 | * Alan Cox : security fixes. | 42 | * Alan Cox : security fixes. |
43 | * <Alan.Cox@linux.org> | 43 | * <alan@lxorguk.ukuu.org.uk> |
44 | * | 44 | * |
45 | * Al Viro : safe handling of mm_struct | 45 | * Al Viro : safe handling of mm_struct |
46 | * | 46 | * |
diff --git a/fs/select.c b/fs/select.c index 448e44001286..87df51eadcf2 100644 --- a/fs/select.c +++ b/fs/select.c | |||
@@ -519,8 +519,9 @@ asmlinkage long sys_select(int n, fd_set __user *inp, fd_set __user *outp, | |||
519 | return -EFAULT; | 519 | return -EFAULT; |
520 | 520 | ||
521 | to = &end_time; | 521 | to = &end_time; |
522 | if (poll_select_set_timeout(to, tv.tv_sec, | 522 | if (poll_select_set_timeout(to, |
523 | tv.tv_usec * NSEC_PER_USEC)) | 523 | tv.tv_sec + (tv.tv_usec / USEC_PER_SEC), |
524 | (tv.tv_usec % USEC_PER_SEC) * NSEC_PER_USEC)) | ||
524 | return -EINVAL; | 525 | return -EINVAL; |
525 | } | 526 | } |
526 | 527 | ||
diff --git a/include/linux/hid.h b/include/linux/hid.h index f13bca2dd53b..5355ca4b939e 100644 --- a/include/linux/hid.h +++ b/include/linux/hid.h | |||
@@ -417,6 +417,11 @@ struct hid_input { | |||
417 | struct input_dev *input; | 417 | struct input_dev *input; |
418 | }; | 418 | }; |
419 | 419 | ||
420 | enum hid_type { | ||
421 | HID_TYPE_OTHER = 0, | ||
422 | HID_TYPE_USBMOUSE | ||
423 | }; | ||
424 | |||
420 | struct hid_driver; | 425 | struct hid_driver; |
421 | struct hid_ll_driver; | 426 | struct hid_ll_driver; |
422 | 427 | ||
@@ -431,6 +436,7 @@ struct hid_device { /* device report descriptor */ | |||
431 | __u32 vendor; /* Vendor ID */ | 436 | __u32 vendor; /* Vendor ID */ |
432 | __u32 product; /* Product ID */ | 437 | __u32 product; /* Product ID */ |
433 | __u32 version; /* HID version */ | 438 | __u32 version; /* HID version */ |
439 | enum hid_type type; /* device type (mouse, kbd, ...) */ | ||
434 | unsigned country; /* HID country */ | 440 | unsigned country; /* HID country */ |
435 | struct hid_report_enum report_enum[HID_REPORT_TYPES]; | 441 | struct hid_report_enum report_enum[HID_REPORT_TYPES]; |
436 | 442 | ||
diff --git a/include/linux/i7300_idle.h b/include/linux/i7300_idle.h new file mode 100644 index 000000000000..05a80c44513c --- /dev/null +++ b/include/linux/i7300_idle.h | |||
@@ -0,0 +1,83 @@ | |||
1 | |||
2 | #ifndef I7300_IDLE_H | ||
3 | #define I7300_IDLE_H | ||
4 | |||
5 | #include <linux/pci.h> | ||
6 | |||
7 | /* | ||
8 | * I/O AT controls (PCI bus 0 device 8 function 0) | ||
9 | * DIMM controls (PCI bus 0 device 16 function 1) | ||
10 | */ | ||
11 | #define IOAT_BUS 0 | ||
12 | #define IOAT_DEVFN PCI_DEVFN(8, 0) | ||
13 | #define MEMCTL_BUS 0 | ||
14 | #define MEMCTL_DEVFN PCI_DEVFN(16, 1) | ||
15 | |||
16 | struct fbd_ioat { | ||
17 | unsigned int vendor; | ||
18 | unsigned int ioat_dev; | ||
19 | }; | ||
20 | |||
21 | /* | ||
22 | * The i5000 chip-set has the same hooks as the i7300 | ||
23 | * but support is disabled by default because this driver | ||
24 | * has not been validated on that platform. | ||
25 | */ | ||
26 | #define SUPPORT_I5000 0 | ||
27 | |||
28 | static const struct fbd_ioat fbd_ioat_list[] = { | ||
29 | {PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_IOAT_CNB}, | ||
30 | #if SUPPORT_I5000 | ||
31 | {PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_IOAT}, | ||
32 | #endif | ||
33 | {0, 0} | ||
34 | }; | ||
35 | |||
36 | /* table of devices that work with this driver */ | ||
37 | static const struct pci_device_id pci_tbl[] = { | ||
38 | { PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_FBD_CNB) }, | ||
39 | #if SUPPORT_I5000 | ||
40 | { PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_5000_ERR) }, | ||
41 | #endif | ||
42 | { } /* Terminating entry */ | ||
43 | }; | ||
44 | |||
45 | /* Check for known platforms with I/O-AT */ | ||
46 | static inline int i7300_idle_platform_probe(struct pci_dev **fbd_dev, | ||
47 | struct pci_dev **ioat_dev) | ||
48 | { | ||
49 | int i; | ||
50 | struct pci_dev *memdev, *dmadev; | ||
51 | |||
52 | memdev = pci_get_bus_and_slot(MEMCTL_BUS, MEMCTL_DEVFN); | ||
53 | if (!memdev) | ||
54 | return -ENODEV; | ||
55 | |||
56 | for (i = 0; pci_tbl[i].vendor != 0; i++) { | ||
57 | if (memdev->vendor == pci_tbl[i].vendor && | ||
58 | memdev->device == pci_tbl[i].device) { | ||
59 | break; | ||
60 | } | ||
61 | } | ||
62 | if (pci_tbl[i].vendor == 0) | ||
63 | return -ENODEV; | ||
64 | |||
65 | dmadev = pci_get_bus_and_slot(IOAT_BUS, IOAT_DEVFN); | ||
66 | if (!dmadev) | ||
67 | return -ENODEV; | ||
68 | |||
69 | for (i = 0; fbd_ioat_list[i].vendor != 0; i++) { | ||
70 | if (dmadev->vendor == fbd_ioat_list[i].vendor && | ||
71 | dmadev->device == fbd_ioat_list[i].ioat_dev) { | ||
72 | if (fbd_dev) | ||
73 | *fbd_dev = memdev; | ||
74 | if (ioat_dev) | ||
75 | *ioat_dev = dmadev; | ||
76 | |||
77 | return 0; | ||
78 | } | ||
79 | } | ||
80 | return -ENODEV; | ||
81 | } | ||
82 | |||
83 | #endif | ||
diff --git a/include/linux/leds.h b/include/linux/leds.h index d41ccb56146a..d3a73f5a48c3 100644 --- a/include/linux/leds.h +++ b/include/linux/leds.h | |||
@@ -123,7 +123,7 @@ extern void ledtrig_ide_activity(void); | |||
123 | */ | 123 | */ |
124 | struct led_info { | 124 | struct led_info { |
125 | const char *name; | 125 | const char *name; |
126 | char *default_trigger; | 126 | const char *default_trigger; |
127 | int flags; | 127 | int flags; |
128 | }; | 128 | }; |
129 | 129 | ||
@@ -135,7 +135,7 @@ struct led_platform_data { | |||
135 | /* For the leds-gpio driver */ | 135 | /* For the leds-gpio driver */ |
136 | struct gpio_led { | 136 | struct gpio_led { |
137 | const char *name; | 137 | const char *name; |
138 | char *default_trigger; | 138 | const char *default_trigger; |
139 | unsigned gpio; | 139 | unsigned gpio; |
140 | u8 active_low; | 140 | u8 active_low; |
141 | }; | 141 | }; |
diff --git a/include/linux/libata.h b/include/linux/libata.h index c261aa0584b1..507f53ef8038 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h | |||
@@ -695,7 +695,6 @@ struct ata_port { | |||
695 | unsigned int cbl; /* cable type; ATA_CBL_xxx */ | 695 | unsigned int cbl; /* cable type; ATA_CBL_xxx */ |
696 | 696 | ||
697 | struct ata_queued_cmd qcmd[ATA_MAX_QUEUE]; | 697 | struct ata_queued_cmd qcmd[ATA_MAX_QUEUE]; |
698 | unsigned long qc_allocated; | ||
699 | unsigned int qc_active; | 698 | unsigned int qc_active; |
700 | int nr_active_links; /* #links with active qcs */ | 699 | int nr_active_links; /* #links with active qcs */ |
701 | 700 | ||
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 64875859d654..c8bcb59adfdf 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
@@ -541,6 +541,14 @@ struct net_device | |||
541 | #define NETIF_F_V6_CSUM (NETIF_F_GEN_CSUM | NETIF_F_IPV6_CSUM) | 541 | #define NETIF_F_V6_CSUM (NETIF_F_GEN_CSUM | NETIF_F_IPV6_CSUM) |
542 | #define NETIF_F_ALL_CSUM (NETIF_F_V4_CSUM | NETIF_F_V6_CSUM) | 542 | #define NETIF_F_ALL_CSUM (NETIF_F_V4_CSUM | NETIF_F_V6_CSUM) |
543 | 543 | ||
544 | /* | ||
545 | * If one device supports one of these features, then enable them | ||
546 | * for all in netdev_increment_features. | ||
547 | */ | ||
548 | #define NETIF_F_ONE_FOR_ALL (NETIF_F_GSO_SOFTWARE | NETIF_F_GSO_ROBUST | \ | ||
549 | NETIF_F_SG | NETIF_F_HIGHDMA | \ | ||
550 | NETIF_F_FRAGLIST) | ||
551 | |||
544 | /* Interface index. Unique device identifier */ | 552 | /* Interface index. Unique device identifier */ |
545 | int ifindex; | 553 | int ifindex; |
546 | int iflink; | 554 | int iflink; |
@@ -1698,7 +1706,9 @@ extern char *netdev_drivername(const struct net_device *dev, char *buffer, int l | |||
1698 | 1706 | ||
1699 | extern void linkwatch_run_queue(void); | 1707 | extern void linkwatch_run_queue(void); |
1700 | 1708 | ||
1701 | extern int netdev_compute_features(unsigned long all, unsigned long one); | 1709 | unsigned long netdev_increment_features(unsigned long all, unsigned long one, |
1710 | unsigned long mask); | ||
1711 | unsigned long netdev_fix_features(unsigned long features, const char *name); | ||
1702 | 1712 | ||
1703 | static inline int net_gso_ok(int features, int gso_type) | 1713 | static inline int net_gso_ok(int features, int gso_type) |
1704 | { | 1714 | { |
diff --git a/include/linux/pci.h b/include/linux/pci.h index 752def8a2ef4..c75b82bda327 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -546,6 +546,13 @@ struct pci_dev __deprecated *pci_find_slot(unsigned int bus, | |||
546 | unsigned int devfn); | 546 | unsigned int devfn); |
547 | #endif /* CONFIG_PCI_LEGACY */ | 547 | #endif /* CONFIG_PCI_LEGACY */ |
548 | 548 | ||
549 | enum pci_lost_interrupt_reason { | ||
550 | PCI_LOST_IRQ_NO_INFORMATION = 0, | ||
551 | PCI_LOST_IRQ_DISABLE_MSI, | ||
552 | PCI_LOST_IRQ_DISABLE_MSIX, | ||
553 | PCI_LOST_IRQ_DISABLE_ACPI, | ||
554 | }; | ||
555 | enum pci_lost_interrupt_reason pci_lost_interrupt(struct pci_dev *dev); | ||
549 | int pci_find_capability(struct pci_dev *dev, int cap); | 556 | int pci_find_capability(struct pci_dev *dev, int cap); |
550 | int pci_find_next_capability(struct pci_dev *dev, u8 pos, int cap); | 557 | int pci_find_next_capability(struct pci_dev *dev, u8 pos, int cap); |
551 | int pci_find_ext_capability(struct pci_dev *dev, int cap); | 558 | int pci_find_ext_capability(struct pci_dev *dev, int cap); |
diff --git a/include/linux/phonet.h b/include/linux/phonet.h index c9609f9aedac..4157faa857b6 100644 --- a/include/linux/phonet.h +++ b/include/linux/phonet.h | |||
@@ -72,6 +72,7 @@ struct phonetmsg { | |||
72 | } pn_msg_u; | 72 | } pn_msg_u; |
73 | }; | 73 | }; |
74 | #define PN_COMMON_MESSAGE 0xF0 | 74 | #define PN_COMMON_MESSAGE 0xF0 |
75 | #define PN_COMMGR 0x10 | ||
75 | #define PN_PREFIX 0xE0 /* resource for extended messages */ | 76 | #define PN_PREFIX 0xE0 /* resource for extended messages */ |
76 | #define pn_submsg_id pn_msg_u.base.pn_submsg_id | 77 | #define pn_submsg_id pn_msg_u.base.pn_submsg_id |
77 | #define pn_e_submsg_id pn_msg_u.ext.pn_e_submsg_id | 78 | #define pn_e_submsg_id pn_msg_u.ext.pn_e_submsg_id |
diff --git a/include/linux/raid/md_k.h b/include/linux/raid/md_k.h index c200b9a34aff..8fc909ef6787 100644 --- a/include/linux/raid/md_k.h +++ b/include/linux/raid/md_k.h | |||
@@ -115,6 +115,9 @@ struct mdk_rdev_s | |||
115 | * in superblock. | 115 | * in superblock. |
116 | */ | 116 | */ |
117 | struct work_struct del_work; /* used for delayed sysfs removal */ | 117 | struct work_struct del_work; /* used for delayed sysfs removal */ |
118 | |||
119 | struct sysfs_dirent *sysfs_state; /* handle for 'state' | ||
120 | * sysfs entry */ | ||
118 | }; | 121 | }; |
119 | 122 | ||
120 | struct mddev_s | 123 | struct mddev_s |
@@ -128,7 +131,6 @@ struct mddev_s | |||
128 | #define MD_CHANGE_DEVS 0 /* Some device status has changed */ | 131 | #define MD_CHANGE_DEVS 0 /* Some device status has changed */ |
129 | #define MD_CHANGE_CLEAN 1 /* transition to or from 'clean' */ | 132 | #define MD_CHANGE_CLEAN 1 /* transition to or from 'clean' */ |
130 | #define MD_CHANGE_PENDING 2 /* superblock update in progress */ | 133 | #define MD_CHANGE_PENDING 2 /* superblock update in progress */ |
131 | #define MD_NOTIFY_ARRAY_STATE 3 /* atomic context wants to notify userspace */ | ||
132 | 134 | ||
133 | int ro; | 135 | int ro; |
134 | 136 | ||
@@ -239,6 +241,10 @@ struct mddev_s | |||
239 | sector_t resync_max; /* resync should pause | 241 | sector_t resync_max; /* resync should pause |
240 | * when it gets here */ | 242 | * when it gets here */ |
241 | 243 | ||
244 | struct sysfs_dirent *sysfs_state; /* handle for 'array_state' | ||
245 | * file in sysfs. | ||
246 | */ | ||
247 | |||
242 | spinlock_t write_lock; | 248 | spinlock_t write_lock; |
243 | wait_queue_head_t sb_wait; /* for waiting on superblock updates */ | 249 | wait_queue_head_t sb_wait; /* for waiting on superblock updates */ |
244 | atomic_t pending_writes; /* number of active superblock writes */ | 250 | atomic_t pending_writes; /* number of active superblock writes */ |
diff --git a/include/linux/sched.h b/include/linux/sched.h index 8478f334d732..b483f39a7112 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -936,7 +936,6 @@ struct sched_class { | |||
936 | void (*enqueue_task) (struct rq *rq, struct task_struct *p, int wakeup); | 936 | void (*enqueue_task) (struct rq *rq, struct task_struct *p, int wakeup); |
937 | void (*dequeue_task) (struct rq *rq, struct task_struct *p, int sleep); | 937 | void (*dequeue_task) (struct rq *rq, struct task_struct *p, int sleep); |
938 | void (*yield_task) (struct rq *rq); | 938 | void (*yield_task) (struct rq *rq); |
939 | int (*select_task_rq)(struct task_struct *p, int sync); | ||
940 | 939 | ||
941 | void (*check_preempt_curr) (struct rq *rq, struct task_struct *p, int sync); | 940 | void (*check_preempt_curr) (struct rq *rq, struct task_struct *p, int sync); |
942 | 941 | ||
@@ -944,6 +943,8 @@ struct sched_class { | |||
944 | void (*put_prev_task) (struct rq *rq, struct task_struct *p); | 943 | void (*put_prev_task) (struct rq *rq, struct task_struct *p); |
945 | 944 | ||
946 | #ifdef CONFIG_SMP | 945 | #ifdef CONFIG_SMP |
946 | int (*select_task_rq)(struct task_struct *p, int sync); | ||
947 | |||
947 | unsigned long (*load_balance) (struct rq *this_rq, int this_cpu, | 948 | unsigned long (*load_balance) (struct rq *this_rq, int this_cpu, |
948 | struct rq *busiest, unsigned long max_load_move, | 949 | struct rq *busiest, unsigned long max_load_move, |
949 | struct sched_domain *sd, enum cpu_idle_type idle, | 950 | struct sched_domain *sd, enum cpu_idle_type idle, |
@@ -955,16 +956,17 @@ struct sched_class { | |||
955 | void (*pre_schedule) (struct rq *this_rq, struct task_struct *task); | 956 | void (*pre_schedule) (struct rq *this_rq, struct task_struct *task); |
956 | void (*post_schedule) (struct rq *this_rq); | 957 | void (*post_schedule) (struct rq *this_rq); |
957 | void (*task_wake_up) (struct rq *this_rq, struct task_struct *task); | 958 | void (*task_wake_up) (struct rq *this_rq, struct task_struct *task); |
958 | #endif | ||
959 | 959 | ||
960 | void (*set_curr_task) (struct rq *rq); | ||
961 | void (*task_tick) (struct rq *rq, struct task_struct *p, int queued); | ||
962 | void (*task_new) (struct rq *rq, struct task_struct *p); | ||
963 | void (*set_cpus_allowed)(struct task_struct *p, | 960 | void (*set_cpus_allowed)(struct task_struct *p, |
964 | const cpumask_t *newmask); | 961 | const cpumask_t *newmask); |
965 | 962 | ||
966 | void (*rq_online)(struct rq *rq); | 963 | void (*rq_online)(struct rq *rq); |
967 | void (*rq_offline)(struct rq *rq); | 964 | void (*rq_offline)(struct rq *rq); |
965 | #endif | ||
966 | |||
967 | void (*set_curr_task) (struct rq *rq); | ||
968 | void (*task_tick) (struct rq *rq, struct task_struct *p, int queued); | ||
969 | void (*task_new) (struct rq *rq, struct task_struct *p); | ||
968 | 970 | ||
969 | void (*switched_from) (struct rq *this_rq, struct task_struct *task, | 971 | void (*switched_from) (struct rq *this_rq, struct task_struct *task, |
970 | int running); | 972 | int running); |
diff --git a/include/linux/smc911x.h b/include/linux/smc911x.h index b58f54c24183..521f37143fae 100644 --- a/include/linux/smc911x.h +++ b/include/linux/smc911x.h | |||
@@ -7,6 +7,7 @@ | |||
7 | struct smc911x_platdata { | 7 | struct smc911x_platdata { |
8 | unsigned long flags; | 8 | unsigned long flags; |
9 | unsigned long irq_flags; /* IRQF_... */ | 9 | unsigned long irq_flags; /* IRQF_... */ |
10 | int irq_polarity; | ||
10 | }; | 11 | }; |
11 | 12 | ||
12 | #endif /* __SMC911X_H__ */ | 13 | #endif /* __SMC911X_H__ */ |
diff --git a/include/math-emu/op-common.h b/include/math-emu/op-common.h index cc1ec396f8d6..f456534dcaf9 100644 --- a/include/math-emu/op-common.h +++ b/include/math-emu/op-common.h | |||
@@ -139,18 +139,27 @@ do { \ | |||
139 | if (X##_e <= _FP_WFRACBITS_##fs) \ | 139 | if (X##_e <= _FP_WFRACBITS_##fs) \ |
140 | { \ | 140 | { \ |
141 | _FP_FRAC_SRS_##wc(X, X##_e, _FP_WFRACBITS_##fs); \ | 141 | _FP_FRAC_SRS_##wc(X, X##_e, _FP_WFRACBITS_##fs); \ |
142 | _FP_ROUND(wc, X); \ | ||
143 | if (_FP_FRAC_HIGH_##fs(X) \ | 142 | if (_FP_FRAC_HIGH_##fs(X) \ |
144 | & (_FP_OVERFLOW_##fs >> 1)) \ | 143 | & (_FP_OVERFLOW_##fs >> 1)) \ |
145 | { \ | 144 | { \ |
146 | X##_e = 1; \ | 145 | X##_e = 1; \ |
147 | _FP_FRAC_SET_##wc(X, _FP_ZEROFRAC_##wc); \ | 146 | _FP_FRAC_SET_##wc(X, _FP_ZEROFRAC_##wc); \ |
148 | FP_SET_EXCEPTION(FP_EX_INEXACT); \ | ||
149 | } \ | 147 | } \ |
150 | else \ | 148 | else \ |
151 | { \ | 149 | { \ |
152 | X##_e = 0; \ | 150 | _FP_ROUND(wc, X); \ |
153 | _FP_FRAC_SRL_##wc(X, _FP_WORKBITS); \ | 151 | if (_FP_FRAC_HIGH_##fs(X) \ |
152 | & (_FP_OVERFLOW_##fs >> 1)) \ | ||
153 | { \ | ||
154 | X##_e = 1; \ | ||
155 | _FP_FRAC_SET_##wc(X, _FP_ZEROFRAC_##wc); \ | ||
156 | FP_SET_EXCEPTION(FP_EX_INEXACT); \ | ||
157 | } \ | ||
158 | else \ | ||
159 | { \ | ||
160 | X##_e = 0; \ | ||
161 | _FP_FRAC_SRL_##wc(X, _FP_WORKBITS); \ | ||
162 | } \ | ||
154 | } \ | 163 | } \ |
155 | if ((FP_CUR_EXCEPTIONS & FP_EX_INEXACT) || \ | 164 | if ((FP_CUR_EXCEPTIONS & FP_EX_INEXACT) || \ |
156 | (FP_TRAPPING_EXCEPTIONS & FP_EX_UNDERFLOW)) \ | 165 | (FP_TRAPPING_EXCEPTIONS & FP_EX_UNDERFLOW)) \ |
@@ -494,6 +503,8 @@ do { \ | |||
494 | R##_c = FP_CLS_NAN; \ | 503 | R##_c = FP_CLS_NAN; \ |
495 | _FP_FRAC_SET_##wc(R, _FP_NANFRAC_##fs); \ | 504 | _FP_FRAC_SET_##wc(R, _FP_NANFRAC_##fs); \ |
496 | FP_SET_EXCEPTION(FP_EX_INVALID | FP_EX_INVALID_IDI);\ | 505 | FP_SET_EXCEPTION(FP_EX_INVALID | FP_EX_INVALID_IDI);\ |
506 | break; \ | ||
507 | \ | ||
497 | case _FP_CLS_COMBINE(FP_CLS_ZERO,FP_CLS_ZERO): \ | 508 | case _FP_CLS_COMBINE(FP_CLS_ZERO,FP_CLS_ZERO): \ |
498 | R##_s = _FP_NANSIGN_##fs; \ | 509 | R##_s = _FP_NANSIGN_##fs; \ |
499 | R##_c = FP_CLS_NAN; \ | 510 | R##_c = FP_CLS_NAN; \ |
diff --git a/include/net/phonet/phonet.h b/include/net/phonet/phonet.h index d4e72508e145..c6a245184460 100644 --- a/include/net/phonet/phonet.h +++ b/include/net/phonet/phonet.h | |||
@@ -27,7 +27,7 @@ | |||
27 | * The lower layers may not require more space, ever. Make sure it's | 27 | * The lower layers may not require more space, ever. Make sure it's |
28 | * enough. | 28 | * enough. |
29 | */ | 29 | */ |
30 | #define MAX_PHONET_HEADER 8 | 30 | #define MAX_PHONET_HEADER (8 + MAX_HEADER) |
31 | 31 | ||
32 | /* | 32 | /* |
33 | * Every Phonet* socket has this structure first in its | 33 | * Every Phonet* socket has this structure first in its |
diff --git a/include/net/sctp/sm.h b/include/net/sctp/sm.h index 029a54a02396..c1dd89365833 100644 --- a/include/net/sctp/sm.h +++ b/include/net/sctp/sm.h | |||
@@ -125,6 +125,7 @@ sctp_state_fn_t sctp_sf_beat_8_3; | |||
125 | sctp_state_fn_t sctp_sf_backbeat_8_3; | 125 | sctp_state_fn_t sctp_sf_backbeat_8_3; |
126 | sctp_state_fn_t sctp_sf_do_9_2_final; | 126 | sctp_state_fn_t sctp_sf_do_9_2_final; |
127 | sctp_state_fn_t sctp_sf_do_9_2_shutdown; | 127 | sctp_state_fn_t sctp_sf_do_9_2_shutdown; |
128 | sctp_state_fn_t sctp_sf_do_9_2_shut_ctsn; | ||
128 | sctp_state_fn_t sctp_sf_do_ecn_cwr; | 129 | sctp_state_fn_t sctp_sf_do_ecn_cwr; |
129 | sctp_state_fn_t sctp_sf_do_ecne; | 130 | sctp_state_fn_t sctp_sf_do_ecne; |
130 | sctp_state_fn_t sctp_sf_ootb; | 131 | sctp_state_fn_t sctp_sf_ootb; |
diff --git a/include/scsi/scsi_tcq.h b/include/scsi/scsi_tcq.h index cf4c219c0b5c..17231385cb37 100644 --- a/include/scsi/scsi_tcq.h +++ b/include/scsi/scsi_tcq.h | |||
@@ -140,8 +140,18 @@ static inline struct scsi_cmnd *scsi_find_tag(struct scsi_device *sdev, int tag) | |||
140 | */ | 140 | */ |
141 | static inline int scsi_init_shared_tag_map(struct Scsi_Host *shost, int depth) | 141 | static inline int scsi_init_shared_tag_map(struct Scsi_Host *shost, int depth) |
142 | { | 142 | { |
143 | shost->bqt = blk_init_tags(depth); | 143 | /* |
144 | return shost->bqt ? 0 : -ENOMEM; | 144 | * If the shared tag map isn't already initialized, do it now. |
145 | * This saves callers from having to check ->bqt when setting up | ||
146 | * devices on the shared host (for libata) | ||
147 | */ | ||
148 | if (!shost->bqt) { | ||
149 | shost->bqt = blk_init_tags(depth); | ||
150 | if (!shost->bqt) | ||
151 | return -ENOMEM; | ||
152 | } | ||
153 | |||
154 | return 0; | ||
145 | } | 155 | } |
146 | 156 | ||
147 | /** | 157 | /** |
diff --git a/init/main.c b/init/main.c index 130d1a0eef11..7e117a231af1 100644 --- a/init/main.c +++ b/init/main.c | |||
@@ -768,6 +768,7 @@ static void __init do_initcalls(void) | |||
768 | static void __init do_basic_setup(void) | 768 | static void __init do_basic_setup(void) |
769 | { | 769 | { |
770 | rcu_init_sched(); /* needed by module_init stage. */ | 770 | rcu_init_sched(); /* needed by module_init stage. */ |
771 | init_workqueues(); | ||
771 | usermodehelper_init(); | 772 | usermodehelper_init(); |
772 | driver_init(); | 773 | driver_init(); |
773 | init_irq_proc(); | 774 | init_irq_proc(); |
@@ -851,8 +852,6 @@ static int __init kernel_init(void * unused) | |||
851 | 852 | ||
852 | cad_pid = task_pid(current); | 853 | cad_pid = task_pid(current); |
853 | 854 | ||
854 | init_workqueues(); | ||
855 | |||
856 | smp_prepare_cpus(setup_max_cpus); | 855 | smp_prepare_cpus(setup_max_cpus); |
857 | 856 | ||
858 | do_pre_smp_initcalls(); | 857 | do_pre_smp_initcalls(); |
diff --git a/kernel/cgroup.c b/kernel/cgroup.c index 046c1609606b..35eebd5510c2 100644 --- a/kernel/cgroup.c +++ b/kernel/cgroup.c | |||
@@ -2104,7 +2104,7 @@ static void *cgroup_tasks_start(struct seq_file *s, loff_t *pos) | |||
2104 | down_read(&cgrp->pids_mutex); | 2104 | down_read(&cgrp->pids_mutex); |
2105 | if (pid) { | 2105 | if (pid) { |
2106 | int end = cgrp->pids_length; | 2106 | int end = cgrp->pids_length; |
2107 | int i; | 2107 | |
2108 | while (index < end) { | 2108 | while (index < end) { |
2109 | int mid = (index + end) / 2; | 2109 | int mid = (index + end) / 2; |
2110 | if (cgrp->tasks_pids[mid] == pid) { | 2110 | if (cgrp->tasks_pids[mid] == pid) { |
diff --git a/kernel/irq/proc.c b/kernel/irq/proc.c index fac014a81b24..4d161c70ba55 100644 --- a/kernel/irq/proc.c +++ b/kernel/irq/proc.c | |||
@@ -220,7 +220,7 @@ void unregister_handler_proc(unsigned int irq, struct irqaction *action) | |||
220 | } | 220 | } |
221 | } | 221 | } |
222 | 222 | ||
223 | void register_default_affinity_proc(void) | 223 | static void register_default_affinity_proc(void) |
224 | { | 224 | { |
225 | #ifdef CONFIG_SMP | 225 | #ifdef CONFIG_SMP |
226 | proc_create("irq/default_smp_affinity", 0600, NULL, | 226 | proc_create("irq/default_smp_affinity", 0600, NULL, |
diff --git a/kernel/sched.c b/kernel/sched.c index 6625c3c4b10d..e8819bc6f462 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -386,7 +386,6 @@ struct cfs_rq { | |||
386 | 386 | ||
387 | u64 exec_clock; | 387 | u64 exec_clock; |
388 | u64 min_vruntime; | 388 | u64 min_vruntime; |
389 | u64 pair_start; | ||
390 | 389 | ||
391 | struct rb_root tasks_timeline; | 390 | struct rb_root tasks_timeline; |
392 | struct rb_node *rb_leftmost; | 391 | struct rb_node *rb_leftmost; |
@@ -3344,7 +3343,7 @@ small_imbalance: | |||
3344 | } else | 3343 | } else |
3345 | this_load_per_task = cpu_avg_load_per_task(this_cpu); | 3344 | this_load_per_task = cpu_avg_load_per_task(this_cpu); |
3346 | 3345 | ||
3347 | if (max_load - this_load + 2*busiest_load_per_task >= | 3346 | if (max_load - this_load + busiest_load_per_task >= |
3348 | busiest_load_per_task * imbn) { | 3347 | busiest_load_per_task * imbn) { |
3349 | *imbalance = busiest_load_per_task; | 3348 | *imbalance = busiest_load_per_task; |
3350 | return busiest; | 3349 | return busiest; |
diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c index 9573c33688b8..ce514afd78ff 100644 --- a/kernel/sched_fair.c +++ b/kernel/sched_fair.c | |||
@@ -143,6 +143,49 @@ static inline struct sched_entity *parent_entity(struct sched_entity *se) | |||
143 | return se->parent; | 143 | return se->parent; |
144 | } | 144 | } |
145 | 145 | ||
146 | /* return depth at which a sched entity is present in the hierarchy */ | ||
147 | static inline int depth_se(struct sched_entity *se) | ||
148 | { | ||
149 | int depth = 0; | ||
150 | |||
151 | for_each_sched_entity(se) | ||
152 | depth++; | ||
153 | |||
154 | return depth; | ||
155 | } | ||
156 | |||
157 | static void | ||
158 | find_matching_se(struct sched_entity **se, struct sched_entity **pse) | ||
159 | { | ||
160 | int se_depth, pse_depth; | ||
161 | |||
162 | /* | ||
163 | * preemption test can be made between sibling entities who are in the | ||
164 | * same cfs_rq i.e who have a common parent. Walk up the hierarchy of | ||
165 | * both tasks until we find their ancestors who are siblings of common | ||
166 | * parent. | ||
167 | */ | ||
168 | |||
169 | /* First walk up until both entities are at same depth */ | ||
170 | se_depth = depth_se(*se); | ||
171 | pse_depth = depth_se(*pse); | ||
172 | |||
173 | while (se_depth > pse_depth) { | ||
174 | se_depth--; | ||
175 | *se = parent_entity(*se); | ||
176 | } | ||
177 | |||
178 | while (pse_depth > se_depth) { | ||
179 | pse_depth--; | ||
180 | *pse = parent_entity(*pse); | ||
181 | } | ||
182 | |||
183 | while (!is_same_group(*se, *pse)) { | ||
184 | *se = parent_entity(*se); | ||
185 | *pse = parent_entity(*pse); | ||
186 | } | ||
187 | } | ||
188 | |||
146 | #else /* CONFIG_FAIR_GROUP_SCHED */ | 189 | #else /* CONFIG_FAIR_GROUP_SCHED */ |
147 | 190 | ||
148 | static inline struct rq *rq_of(struct cfs_rq *cfs_rq) | 191 | static inline struct rq *rq_of(struct cfs_rq *cfs_rq) |
@@ -193,6 +236,11 @@ static inline struct sched_entity *parent_entity(struct sched_entity *se) | |||
193 | return NULL; | 236 | return NULL; |
194 | } | 237 | } |
195 | 238 | ||
239 | static inline void | ||
240 | find_matching_se(struct sched_entity **se, struct sched_entity **pse) | ||
241 | { | ||
242 | } | ||
243 | |||
196 | #endif /* CONFIG_FAIR_GROUP_SCHED */ | 244 | #endif /* CONFIG_FAIR_GROUP_SCHED */ |
197 | 245 | ||
198 | 246 | ||
@@ -223,6 +271,27 @@ static inline s64 entity_key(struct cfs_rq *cfs_rq, struct sched_entity *se) | |||
223 | return se->vruntime - cfs_rq->min_vruntime; | 271 | return se->vruntime - cfs_rq->min_vruntime; |
224 | } | 272 | } |
225 | 273 | ||
274 | static void update_min_vruntime(struct cfs_rq *cfs_rq) | ||
275 | { | ||
276 | u64 vruntime = cfs_rq->min_vruntime; | ||
277 | |||
278 | if (cfs_rq->curr) | ||
279 | vruntime = cfs_rq->curr->vruntime; | ||
280 | |||
281 | if (cfs_rq->rb_leftmost) { | ||
282 | struct sched_entity *se = rb_entry(cfs_rq->rb_leftmost, | ||
283 | struct sched_entity, | ||
284 | run_node); | ||
285 | |||
286 | if (vruntime == cfs_rq->min_vruntime) | ||
287 | vruntime = se->vruntime; | ||
288 | else | ||
289 | vruntime = min_vruntime(vruntime, se->vruntime); | ||
290 | } | ||
291 | |||
292 | cfs_rq->min_vruntime = max_vruntime(cfs_rq->min_vruntime, vruntime); | ||
293 | } | ||
294 | |||
226 | /* | 295 | /* |
227 | * Enqueue an entity into the rb-tree: | 296 | * Enqueue an entity into the rb-tree: |
228 | */ | 297 | */ |
@@ -256,15 +325,8 @@ static void __enqueue_entity(struct cfs_rq *cfs_rq, struct sched_entity *se) | |||
256 | * Maintain a cache of leftmost tree entries (it is frequently | 325 | * Maintain a cache of leftmost tree entries (it is frequently |
257 | * used): | 326 | * used): |
258 | */ | 327 | */ |
259 | if (leftmost) { | 328 | if (leftmost) |
260 | cfs_rq->rb_leftmost = &se->run_node; | 329 | cfs_rq->rb_leftmost = &se->run_node; |
261 | /* | ||
262 | * maintain cfs_rq->min_vruntime to be a monotonic increasing | ||
263 | * value tracking the leftmost vruntime in the tree. | ||
264 | */ | ||
265 | cfs_rq->min_vruntime = | ||
266 | max_vruntime(cfs_rq->min_vruntime, se->vruntime); | ||
267 | } | ||
268 | 330 | ||
269 | rb_link_node(&se->run_node, parent, link); | 331 | rb_link_node(&se->run_node, parent, link); |
270 | rb_insert_color(&se->run_node, &cfs_rq->tasks_timeline); | 332 | rb_insert_color(&se->run_node, &cfs_rq->tasks_timeline); |
@@ -274,18 +336,9 @@ static void __dequeue_entity(struct cfs_rq *cfs_rq, struct sched_entity *se) | |||
274 | { | 336 | { |
275 | if (cfs_rq->rb_leftmost == &se->run_node) { | 337 | if (cfs_rq->rb_leftmost == &se->run_node) { |
276 | struct rb_node *next_node; | 338 | struct rb_node *next_node; |
277 | struct sched_entity *next; | ||
278 | 339 | ||
279 | next_node = rb_next(&se->run_node); | 340 | next_node = rb_next(&se->run_node); |
280 | cfs_rq->rb_leftmost = next_node; | 341 | cfs_rq->rb_leftmost = next_node; |
281 | |||
282 | if (next_node) { | ||
283 | next = rb_entry(next_node, | ||
284 | struct sched_entity, run_node); | ||
285 | cfs_rq->min_vruntime = | ||
286 | max_vruntime(cfs_rq->min_vruntime, | ||
287 | next->vruntime); | ||
288 | } | ||
289 | } | 342 | } |
290 | 343 | ||
291 | if (cfs_rq->next == se) | 344 | if (cfs_rq->next == se) |
@@ -424,6 +477,7 @@ __update_curr(struct cfs_rq *cfs_rq, struct sched_entity *curr, | |||
424 | schedstat_add(cfs_rq, exec_clock, delta_exec); | 477 | schedstat_add(cfs_rq, exec_clock, delta_exec); |
425 | delta_exec_weighted = calc_delta_fair(delta_exec, curr); | 478 | delta_exec_weighted = calc_delta_fair(delta_exec, curr); |
426 | curr->vruntime += delta_exec_weighted; | 479 | curr->vruntime += delta_exec_weighted; |
480 | update_min_vruntime(cfs_rq); | ||
427 | } | 481 | } |
428 | 482 | ||
429 | static void update_curr(struct cfs_rq *cfs_rq) | 483 | static void update_curr(struct cfs_rq *cfs_rq) |
@@ -613,13 +667,7 @@ static void check_spread(struct cfs_rq *cfs_rq, struct sched_entity *se) | |||
613 | static void | 667 | static void |
614 | place_entity(struct cfs_rq *cfs_rq, struct sched_entity *se, int initial) | 668 | place_entity(struct cfs_rq *cfs_rq, struct sched_entity *se, int initial) |
615 | { | 669 | { |
616 | u64 vruntime; | 670 | u64 vruntime = cfs_rq->min_vruntime; |
617 | |||
618 | if (first_fair(cfs_rq)) { | ||
619 | vruntime = min_vruntime(cfs_rq->min_vruntime, | ||
620 | __pick_next_entity(cfs_rq)->vruntime); | ||
621 | } else | ||
622 | vruntime = cfs_rq->min_vruntime; | ||
623 | 671 | ||
624 | /* | 672 | /* |
625 | * The 'current' period is already promised to the current tasks, | 673 | * The 'current' period is already promised to the current tasks, |
@@ -696,6 +744,7 @@ dequeue_entity(struct cfs_rq *cfs_rq, struct sched_entity *se, int sleep) | |||
696 | if (se != cfs_rq->curr) | 744 | if (se != cfs_rq->curr) |
697 | __dequeue_entity(cfs_rq, se); | 745 | __dequeue_entity(cfs_rq, se); |
698 | account_entity_dequeue(cfs_rq, se); | 746 | account_entity_dequeue(cfs_rq, se); |
747 | update_min_vruntime(cfs_rq); | ||
699 | } | 748 | } |
700 | 749 | ||
701 | /* | 750 | /* |
@@ -742,16 +791,14 @@ set_next_entity(struct cfs_rq *cfs_rq, struct sched_entity *se) | |||
742 | se->prev_sum_exec_runtime = se->sum_exec_runtime; | 791 | se->prev_sum_exec_runtime = se->sum_exec_runtime; |
743 | } | 792 | } |
744 | 793 | ||
794 | static int | ||
795 | wakeup_preempt_entity(struct sched_entity *curr, struct sched_entity *se); | ||
796 | |||
745 | static struct sched_entity * | 797 | static struct sched_entity * |
746 | pick_next(struct cfs_rq *cfs_rq, struct sched_entity *se) | 798 | pick_next(struct cfs_rq *cfs_rq, struct sched_entity *se) |
747 | { | 799 | { |
748 | struct rq *rq = rq_of(cfs_rq); | 800 | if (!cfs_rq->next || wakeup_preempt_entity(cfs_rq->next, se) == 1) |
749 | u64 pair_slice = rq->clock - cfs_rq->pair_start; | ||
750 | |||
751 | if (!cfs_rq->next || pair_slice > sysctl_sched_min_granularity) { | ||
752 | cfs_rq->pair_start = rq->clock; | ||
753 | return se; | 801 | return se; |
754 | } | ||
755 | 802 | ||
756 | return cfs_rq->next; | 803 | return cfs_rq->next; |
757 | } | 804 | } |
@@ -1122,10 +1169,9 @@ wake_affine(struct sched_domain *this_sd, struct rq *this_rq, | |||
1122 | if (!(this_sd->flags & SD_WAKE_AFFINE) || !sched_feat(AFFINE_WAKEUPS)) | 1169 | if (!(this_sd->flags & SD_WAKE_AFFINE) || !sched_feat(AFFINE_WAKEUPS)) |
1123 | return 0; | 1170 | return 0; |
1124 | 1171 | ||
1125 | if (!sync && sched_feat(SYNC_WAKEUPS) && | 1172 | if (sync && (curr->se.avg_overlap > sysctl_sched_migration_cost || |
1126 | curr->se.avg_overlap < sysctl_sched_migration_cost && | 1173 | p->se.avg_overlap > sysctl_sched_migration_cost)) |
1127 | p->se.avg_overlap < sysctl_sched_migration_cost) | 1174 | sync = 0; |
1128 | sync = 1; | ||
1129 | 1175 | ||
1130 | /* | 1176 | /* |
1131 | * If sync wakeup then subtract the (maximum possible) | 1177 | * If sync wakeup then subtract the (maximum possible) |
@@ -1244,13 +1290,42 @@ static unsigned long wakeup_gran(struct sched_entity *se) | |||
1244 | * More easily preempt - nice tasks, while not making it harder for | 1290 | * More easily preempt - nice tasks, while not making it harder for |
1245 | * + nice tasks. | 1291 | * + nice tasks. |
1246 | */ | 1292 | */ |
1247 | if (sched_feat(ASYM_GRAN)) | 1293 | if (!sched_feat(ASYM_GRAN) || se->load.weight > NICE_0_LOAD) |
1248 | gran = calc_delta_mine(gran, NICE_0_LOAD, &se->load); | 1294 | gran = calc_delta_fair(sysctl_sched_wakeup_granularity, se); |
1249 | 1295 | ||
1250 | return gran; | 1296 | return gran; |
1251 | } | 1297 | } |
1252 | 1298 | ||
1253 | /* | 1299 | /* |
1300 | * Should 'se' preempt 'curr'. | ||
1301 | * | ||
1302 | * |s1 | ||
1303 | * |s2 | ||
1304 | * |s3 | ||
1305 | * g | ||
1306 | * |<--->|c | ||
1307 | * | ||
1308 | * w(c, s1) = -1 | ||
1309 | * w(c, s2) = 0 | ||
1310 | * w(c, s3) = 1 | ||
1311 | * | ||
1312 | */ | ||
1313 | static int | ||
1314 | wakeup_preempt_entity(struct sched_entity *curr, struct sched_entity *se) | ||
1315 | { | ||
1316 | s64 gran, vdiff = curr->vruntime - se->vruntime; | ||
1317 | |||
1318 | if (vdiff <= 0) | ||
1319 | return -1; | ||
1320 | |||
1321 | gran = wakeup_gran(curr); | ||
1322 | if (vdiff > gran) | ||
1323 | return 1; | ||
1324 | |||
1325 | return 0; | ||
1326 | } | ||
1327 | |||
1328 | /* | ||
1254 | * Preempt the current task with a newly woken task if needed: | 1329 | * Preempt the current task with a newly woken task if needed: |
1255 | */ | 1330 | */ |
1256 | static void check_preempt_wakeup(struct rq *rq, struct task_struct *p, int sync) | 1331 | static void check_preempt_wakeup(struct rq *rq, struct task_struct *p, int sync) |
@@ -1258,7 +1333,6 @@ static void check_preempt_wakeup(struct rq *rq, struct task_struct *p, int sync) | |||
1258 | struct task_struct *curr = rq->curr; | 1333 | struct task_struct *curr = rq->curr; |
1259 | struct cfs_rq *cfs_rq = task_cfs_rq(curr); | 1334 | struct cfs_rq *cfs_rq = task_cfs_rq(curr); |
1260 | struct sched_entity *se = &curr->se, *pse = &p->se; | 1335 | struct sched_entity *se = &curr->se, *pse = &p->se; |
1261 | s64 delta_exec; | ||
1262 | 1336 | ||
1263 | if (unlikely(rt_prio(p->prio))) { | 1337 | if (unlikely(rt_prio(p->prio))) { |
1264 | update_rq_clock(rq); | 1338 | update_rq_clock(rq); |
@@ -1296,9 +1370,19 @@ static void check_preempt_wakeup(struct rq *rq, struct task_struct *p, int sync) | |||
1296 | return; | 1370 | return; |
1297 | } | 1371 | } |
1298 | 1372 | ||
1299 | delta_exec = se->sum_exec_runtime - se->prev_sum_exec_runtime; | 1373 | find_matching_se(&se, &pse); |
1300 | if (delta_exec > wakeup_gran(pse)) | 1374 | |
1301 | resched_task(curr); | 1375 | while (se) { |
1376 | BUG_ON(!pse); | ||
1377 | |||
1378 | if (wakeup_preempt_entity(se, pse) == 1) { | ||
1379 | resched_task(curr); | ||
1380 | break; | ||
1381 | } | ||
1382 | |||
1383 | se = parent_entity(se); | ||
1384 | pse = parent_entity(pse); | ||
1385 | } | ||
1302 | } | 1386 | } |
1303 | 1387 | ||
1304 | static struct task_struct *pick_next_task_fair(struct rq *rq) | 1388 | static struct task_struct *pick_next_task_fair(struct rq *rq) |
@@ -1594,9 +1678,6 @@ static const struct sched_class fair_sched_class = { | |||
1594 | .enqueue_task = enqueue_task_fair, | 1678 | .enqueue_task = enqueue_task_fair, |
1595 | .dequeue_task = dequeue_task_fair, | 1679 | .dequeue_task = dequeue_task_fair, |
1596 | .yield_task = yield_task_fair, | 1680 | .yield_task = yield_task_fair, |
1597 | #ifdef CONFIG_SMP | ||
1598 | .select_task_rq = select_task_rq_fair, | ||
1599 | #endif /* CONFIG_SMP */ | ||
1600 | 1681 | ||
1601 | .check_preempt_curr = check_preempt_wakeup, | 1682 | .check_preempt_curr = check_preempt_wakeup, |
1602 | 1683 | ||
@@ -1604,6 +1685,8 @@ static const struct sched_class fair_sched_class = { | |||
1604 | .put_prev_task = put_prev_task_fair, | 1685 | .put_prev_task = put_prev_task_fair, |
1605 | 1686 | ||
1606 | #ifdef CONFIG_SMP | 1687 | #ifdef CONFIG_SMP |
1688 | .select_task_rq = select_task_rq_fair, | ||
1689 | |||
1607 | .load_balance = load_balance_fair, | 1690 | .load_balance = load_balance_fair, |
1608 | .move_one_task = move_one_task_fair, | 1691 | .move_one_task = move_one_task_fair, |
1609 | #endif | 1692 | #endif |
diff --git a/kernel/sched_idletask.c b/kernel/sched_idletask.c index dec4ccabe2f5..8a21a2e28c13 100644 --- a/kernel/sched_idletask.c +++ b/kernel/sched_idletask.c | |||
@@ -105,9 +105,6 @@ static const struct sched_class idle_sched_class = { | |||
105 | 105 | ||
106 | /* dequeue is not valid, we print a debug message there: */ | 106 | /* dequeue is not valid, we print a debug message there: */ |
107 | .dequeue_task = dequeue_task_idle, | 107 | .dequeue_task = dequeue_task_idle, |
108 | #ifdef CONFIG_SMP | ||
109 | .select_task_rq = select_task_rq_idle, | ||
110 | #endif /* CONFIG_SMP */ | ||
111 | 108 | ||
112 | .check_preempt_curr = check_preempt_curr_idle, | 109 | .check_preempt_curr = check_preempt_curr_idle, |
113 | 110 | ||
@@ -115,6 +112,8 @@ static const struct sched_class idle_sched_class = { | |||
115 | .put_prev_task = put_prev_task_idle, | 112 | .put_prev_task = put_prev_task_idle, |
116 | 113 | ||
117 | #ifdef CONFIG_SMP | 114 | #ifdef CONFIG_SMP |
115 | .select_task_rq = select_task_rq_idle, | ||
116 | |||
118 | .load_balance = load_balance_idle, | 117 | .load_balance = load_balance_idle, |
119 | .move_one_task = move_one_task_idle, | 118 | .move_one_task = move_one_task_idle, |
120 | #endif | 119 | #endif |
diff --git a/kernel/sched_rt.c b/kernel/sched_rt.c index b446dc87494f..d9ba9d5f99d6 100644 --- a/kernel/sched_rt.c +++ b/kernel/sched_rt.c | |||
@@ -1504,9 +1504,6 @@ static const struct sched_class rt_sched_class = { | |||
1504 | .enqueue_task = enqueue_task_rt, | 1504 | .enqueue_task = enqueue_task_rt, |
1505 | .dequeue_task = dequeue_task_rt, | 1505 | .dequeue_task = dequeue_task_rt, |
1506 | .yield_task = yield_task_rt, | 1506 | .yield_task = yield_task_rt, |
1507 | #ifdef CONFIG_SMP | ||
1508 | .select_task_rq = select_task_rq_rt, | ||
1509 | #endif /* CONFIG_SMP */ | ||
1510 | 1507 | ||
1511 | .check_preempt_curr = check_preempt_curr_rt, | 1508 | .check_preempt_curr = check_preempt_curr_rt, |
1512 | 1509 | ||
@@ -1514,6 +1511,8 @@ static const struct sched_class rt_sched_class = { | |||
1514 | .put_prev_task = put_prev_task_rt, | 1511 | .put_prev_task = put_prev_task_rt, |
1515 | 1512 | ||
1516 | #ifdef CONFIG_SMP | 1513 | #ifdef CONFIG_SMP |
1514 | .select_task_rq = select_task_rq_rt, | ||
1515 | |||
1517 | .load_balance = load_balance_rt, | 1516 | .load_balance = load_balance_rt, |
1518 | .move_one_task = move_one_task_rt, | 1517 | .move_one_task = move_one_task_rt, |
1519 | .set_cpus_allowed = set_cpus_allowed_rt, | 1518 | .set_cpus_allowed = set_cpus_allowed_rt, |
diff --git a/kernel/stop_machine.c b/kernel/stop_machine.c index 8aff79d90ddc..9bc4c00872c9 100644 --- a/kernel/stop_machine.c +++ b/kernel/stop_machine.c | |||
@@ -160,4 +160,4 @@ static int __init stop_machine_init(void) | |||
160 | stop_machine_work = alloc_percpu(struct work_struct); | 160 | stop_machine_work = alloc_percpu(struct work_struct); |
161 | return 0; | 161 | return 0; |
162 | } | 162 | } |
163 | early_initcall(stop_machine_init); | 163 | core_initcall(stop_machine_init); |
diff --git a/lib/string_helpers.c b/lib/string_helpers.c index 8347925030ff..ab431d4cc970 100644 --- a/lib/string_helpers.c +++ b/lib/string_helpers.c | |||
@@ -23,7 +23,7 @@ | |||
23 | int string_get_size(u64 size, const enum string_size_units units, | 23 | int string_get_size(u64 size, const enum string_size_units units, |
24 | char *buf, int len) | 24 | char *buf, int len) |
25 | { | 25 | { |
26 | const char *units_10[] = { "B", "KB", "MB", "GB", "TB", "PB", | 26 | const char *units_10[] = { "B", "kB", "MB", "GB", "TB", "PB", |
27 | "EB", "ZB", "YB", NULL}; | 27 | "EB", "ZB", "YB", NULL}; |
28 | const char *units_2[] = {"B", "KiB", "MiB", "GiB", "TiB", "PiB", | 28 | const char *units_2[] = {"B", "KiB", "MiB", "GiB", "TiB", "PiB", |
29 | "EiB", "ZiB", "YiB", NULL }; | 29 | "EiB", "ZiB", "YiB", NULL }; |
@@ -31,7 +31,7 @@ int string_get_size(u64 size, const enum string_size_units units, | |||
31 | [STRING_UNITS_10] = units_10, | 31 | [STRING_UNITS_10] = units_10, |
32 | [STRING_UNITS_2] = units_2, | 32 | [STRING_UNITS_2] = units_2, |
33 | }; | 33 | }; |
34 | const int divisor[] = { | 34 | const unsigned int divisor[] = { |
35 | [STRING_UNITS_10] = 1000, | 35 | [STRING_UNITS_10] = 1000, |
36 | [STRING_UNITS_2] = 1024, | 36 | [STRING_UNITS_2] = 1024, |
37 | }; | 37 | }; |
@@ -40,23 +40,27 @@ int string_get_size(u64 size, const enum string_size_units units, | |||
40 | char tmp[8]; | 40 | char tmp[8]; |
41 | 41 | ||
42 | tmp[0] = '\0'; | 42 | tmp[0] = '\0'; |
43 | i = 0; | ||
44 | if (size >= divisor[units]) { | ||
45 | while (size >= divisor[units] && units_str[units][i]) { | ||
46 | remainder = do_div(size, divisor[units]); | ||
47 | i++; | ||
48 | } | ||
43 | 49 | ||
44 | for (i = 0; size > divisor[units] && units_str[units][i]; i++) | 50 | sf_cap = size; |
45 | remainder = do_div(size, divisor[units]); | 51 | for (j = 0; sf_cap*10 < 1000; j++) |
52 | sf_cap *= 10; | ||
46 | 53 | ||
47 | sf_cap = size; | 54 | if (j) { |
48 | for (j = 0; sf_cap*10 < 1000; j++) | 55 | remainder *= 1000; |
49 | sf_cap *= 10; | 56 | do_div(remainder, divisor[units]); |
50 | 57 | snprintf(tmp, sizeof(tmp), ".%03lld", | |
51 | if (j) { | 58 | (unsigned long long)remainder); |
52 | remainder *= 1000; | 59 | tmp[j+1] = '\0'; |
53 | do_div(remainder, divisor[units]); | 60 | } |
54 | snprintf(tmp, sizeof(tmp), ".%03lld", | ||
55 | (unsigned long long)remainder); | ||
56 | tmp[j+1] = '\0'; | ||
57 | } | 61 | } |
58 | 62 | ||
59 | snprintf(buf, len, "%lld%s%s", (unsigned long long)size, | 63 | snprintf(buf, len, "%lld%s %s", (unsigned long long)size, |
60 | tmp, units_str[units][i]); | 64 | tmp, units_str[units][i]); |
61 | 65 | ||
62 | return 0; | 66 | return 0; |
diff --git a/net/bridge/br_device.c b/net/bridge/br_device.c index 22ba8632196f..6c023f0f8252 100644 --- a/net/bridge/br_device.c +++ b/net/bridge/br_device.c | |||
@@ -179,5 +179,5 @@ void br_dev_setup(struct net_device *dev) | |||
179 | 179 | ||
180 | dev->features = NETIF_F_SG | NETIF_F_FRAGLIST | NETIF_F_HIGHDMA | | 180 | dev->features = NETIF_F_SG | NETIF_F_FRAGLIST | NETIF_F_HIGHDMA | |
181 | NETIF_F_GSO_MASK | NETIF_F_NO_CSUM | NETIF_F_LLTX | | 181 | NETIF_F_GSO_MASK | NETIF_F_NO_CSUM | NETIF_F_LLTX | |
182 | NETIF_F_NETNS_LOCAL; | 182 | NETIF_F_NETNS_LOCAL | NETIF_F_GSO; |
183 | } | 183 | } |
diff --git a/net/bridge/br_if.c b/net/bridge/br_if.c index 573e20f7dba4..0a09ccf68c1c 100644 --- a/net/bridge/br_if.c +++ b/net/bridge/br_if.c | |||
@@ -347,15 +347,21 @@ int br_min_mtu(const struct net_bridge *br) | |||
347 | void br_features_recompute(struct net_bridge *br) | 347 | void br_features_recompute(struct net_bridge *br) |
348 | { | 348 | { |
349 | struct net_bridge_port *p; | 349 | struct net_bridge_port *p; |
350 | unsigned long features; | 350 | unsigned long features, mask; |
351 | 351 | ||
352 | features = br->feature_mask; | 352 | features = mask = br->feature_mask; |
353 | if (list_empty(&br->port_list)) | ||
354 | goto done; | ||
355 | |||
356 | features &= ~NETIF_F_ONE_FOR_ALL; | ||
353 | 357 | ||
354 | list_for_each_entry(p, &br->port_list, list) { | 358 | list_for_each_entry(p, &br->port_list, list) { |
355 | features = netdev_compute_features(features, p->dev->features); | 359 | features = netdev_increment_features(features, |
360 | p->dev->features, mask); | ||
356 | } | 361 | } |
357 | 362 | ||
358 | br->dev->features = features; | 363 | done: |
364 | br->dev->features = netdev_fix_features(features, NULL); | ||
359 | } | 365 | } |
360 | 366 | ||
361 | /* called with RTNL */ | 367 | /* called with RTNL */ |
diff --git a/net/core/dev.c b/net/core/dev.c index b8a4fd0806af..d9038e328cc1 100644 --- a/net/core/dev.c +++ b/net/core/dev.c | |||
@@ -3947,6 +3947,46 @@ static void netdev_init_queue_locks(struct net_device *dev) | |||
3947 | __netdev_init_queue_locks_one(dev, &dev->rx_queue, NULL); | 3947 | __netdev_init_queue_locks_one(dev, &dev->rx_queue, NULL); |
3948 | } | 3948 | } |
3949 | 3949 | ||
3950 | unsigned long netdev_fix_features(unsigned long features, const char *name) | ||
3951 | { | ||
3952 | /* Fix illegal SG+CSUM combinations. */ | ||
3953 | if ((features & NETIF_F_SG) && | ||
3954 | !(features & NETIF_F_ALL_CSUM)) { | ||
3955 | if (name) | ||
3956 | printk(KERN_NOTICE "%s: Dropping NETIF_F_SG since no " | ||
3957 | "checksum feature.\n", name); | ||
3958 | features &= ~NETIF_F_SG; | ||
3959 | } | ||
3960 | |||
3961 | /* TSO requires that SG is present as well. */ | ||
3962 | if ((features & NETIF_F_TSO) && !(features & NETIF_F_SG)) { | ||
3963 | if (name) | ||
3964 | printk(KERN_NOTICE "%s: Dropping NETIF_F_TSO since no " | ||
3965 | "SG feature.\n", name); | ||
3966 | features &= ~NETIF_F_TSO; | ||
3967 | } | ||
3968 | |||
3969 | if (features & NETIF_F_UFO) { | ||
3970 | if (!(features & NETIF_F_GEN_CSUM)) { | ||
3971 | if (name) | ||
3972 | printk(KERN_ERR "%s: Dropping NETIF_F_UFO " | ||
3973 | "since no NETIF_F_HW_CSUM feature.\n", | ||
3974 | name); | ||
3975 | features &= ~NETIF_F_UFO; | ||
3976 | } | ||
3977 | |||
3978 | if (!(features & NETIF_F_SG)) { | ||
3979 | if (name) | ||
3980 | printk(KERN_ERR "%s: Dropping NETIF_F_UFO " | ||
3981 | "since no NETIF_F_SG feature.\n", name); | ||
3982 | features &= ~NETIF_F_UFO; | ||
3983 | } | ||
3984 | } | ||
3985 | |||
3986 | return features; | ||
3987 | } | ||
3988 | EXPORT_SYMBOL(netdev_fix_features); | ||
3989 | |||
3950 | /** | 3990 | /** |
3951 | * register_netdevice - register a network device | 3991 | * register_netdevice - register a network device |
3952 | * @dev: device to register | 3992 | * @dev: device to register |
@@ -4032,36 +4072,7 @@ int register_netdevice(struct net_device *dev) | |||
4032 | dev->features &= ~(NETIF_F_IP_CSUM|NETIF_F_IPV6_CSUM|NETIF_F_HW_CSUM); | 4072 | dev->features &= ~(NETIF_F_IP_CSUM|NETIF_F_IPV6_CSUM|NETIF_F_HW_CSUM); |
4033 | } | 4073 | } |
4034 | 4074 | ||
4035 | 4075 | dev->features = netdev_fix_features(dev->features, dev->name); | |
4036 | /* Fix illegal SG+CSUM combinations. */ | ||
4037 | if ((dev->features & NETIF_F_SG) && | ||
4038 | !(dev->features & NETIF_F_ALL_CSUM)) { | ||
4039 | printk(KERN_NOTICE "%s: Dropping NETIF_F_SG since no checksum feature.\n", | ||
4040 | dev->name); | ||
4041 | dev->features &= ~NETIF_F_SG; | ||
4042 | } | ||
4043 | |||
4044 | /* TSO requires that SG is present as well. */ | ||
4045 | if ((dev->features & NETIF_F_TSO) && | ||
4046 | !(dev->features & NETIF_F_SG)) { | ||
4047 | printk(KERN_NOTICE "%s: Dropping NETIF_F_TSO since no SG feature.\n", | ||
4048 | dev->name); | ||
4049 | dev->features &= ~NETIF_F_TSO; | ||
4050 | } | ||
4051 | if (dev->features & NETIF_F_UFO) { | ||
4052 | if (!(dev->features & NETIF_F_HW_CSUM)) { | ||
4053 | printk(KERN_ERR "%s: Dropping NETIF_F_UFO since no " | ||
4054 | "NETIF_F_HW_CSUM feature.\n", | ||
4055 | dev->name); | ||
4056 | dev->features &= ~NETIF_F_UFO; | ||
4057 | } | ||
4058 | if (!(dev->features & NETIF_F_SG)) { | ||
4059 | printk(KERN_ERR "%s: Dropping NETIF_F_UFO since no " | ||
4060 | "NETIF_F_SG feature.\n", | ||
4061 | dev->name); | ||
4062 | dev->features &= ~NETIF_F_UFO; | ||
4063 | } | ||
4064 | } | ||
4065 | 4076 | ||
4066 | /* Enable software GSO if SG is supported. */ | 4077 | /* Enable software GSO if SG is supported. */ |
4067 | if (dev->features & NETIF_F_SG) | 4078 | if (dev->features & NETIF_F_SG) |
@@ -4700,49 +4711,45 @@ static int __init netdev_dma_register(void) { return -ENODEV; } | |||
4700 | #endif /* CONFIG_NET_DMA */ | 4711 | #endif /* CONFIG_NET_DMA */ |
4701 | 4712 | ||
4702 | /** | 4713 | /** |
4703 | * netdev_compute_feature - compute conjunction of two feature sets | 4714 | * netdev_increment_features - increment feature set by one |
4704 | * @all: first feature set | 4715 | * @all: current feature set |
4705 | * @one: second feature set | 4716 | * @one: new feature set |
4717 | * @mask: mask feature set | ||
4706 | * | 4718 | * |
4707 | * Computes a new feature set after adding a device with feature set | 4719 | * Computes a new feature set after adding a device with feature set |
4708 | * @one to the master device with current feature set @all. Returns | 4720 | * @one to the master device with current feature set @all. Will not |
4709 | * the new feature set. | 4721 | * enable anything that is off in @mask. Returns the new feature set. |
4710 | */ | 4722 | */ |
4711 | int netdev_compute_features(unsigned long all, unsigned long one) | 4723 | unsigned long netdev_increment_features(unsigned long all, unsigned long one, |
4712 | { | 4724 | unsigned long mask) |
4713 | /* if device needs checksumming, downgrade to hw checksumming */ | 4725 | { |
4714 | if (all & NETIF_F_NO_CSUM && !(one & NETIF_F_NO_CSUM)) | 4726 | /* If device needs checksumming, downgrade to it. */ |
4715 | all ^= NETIF_F_NO_CSUM | NETIF_F_HW_CSUM; | 4727 | if (all & NETIF_F_NO_CSUM && !(one & NETIF_F_NO_CSUM)) |
4716 | 4728 | all ^= NETIF_F_NO_CSUM | (one & NETIF_F_ALL_CSUM); | |
4717 | /* if device can't do all checksum, downgrade to ipv4/ipv6 */ | 4729 | else if (mask & NETIF_F_ALL_CSUM) { |
4718 | if (all & NETIF_F_HW_CSUM && !(one & NETIF_F_HW_CSUM)) | 4730 | /* If one device supports v4/v6 checksumming, set for all. */ |
4719 | all ^= NETIF_F_HW_CSUM | 4731 | if (one & (NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM) && |
4720 | | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM; | 4732 | !(all & NETIF_F_GEN_CSUM)) { |
4721 | 4733 | all &= ~NETIF_F_ALL_CSUM; | |
4722 | if (one & NETIF_F_GSO) | 4734 | all |= one & (NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM); |
4723 | one |= NETIF_F_GSO_SOFTWARE; | 4735 | } |
4724 | one |= NETIF_F_GSO; | ||
4725 | |||
4726 | /* | ||
4727 | * If even one device supports a GSO protocol with software fallback, | ||
4728 | * enable it for all. | ||
4729 | */ | ||
4730 | all |= one & NETIF_F_GSO_SOFTWARE; | ||
4731 | 4736 | ||
4732 | /* If even one device supports robust GSO, enable it for all. */ | 4737 | /* If one device supports hw checksumming, set for all. */ |
4733 | if (one & NETIF_F_GSO_ROBUST) | 4738 | if (one & NETIF_F_GEN_CSUM && !(all & NETIF_F_GEN_CSUM)) { |
4734 | all |= NETIF_F_GSO_ROBUST; | 4739 | all &= ~NETIF_F_ALL_CSUM; |
4740 | all |= NETIF_F_HW_CSUM; | ||
4741 | } | ||
4742 | } | ||
4735 | 4743 | ||
4736 | all &= one | NETIF_F_LLTX; | 4744 | one |= NETIF_F_ALL_CSUM; |
4737 | 4745 | ||
4738 | if (!(all & NETIF_F_ALL_CSUM)) | 4746 | one |= all & NETIF_F_ONE_FOR_ALL; |
4739 | all &= ~NETIF_F_SG; | 4747 | all &= one | NETIF_F_LLTX | NETIF_F_GSO; |
4740 | if (!(all & NETIF_F_SG)) | 4748 | all |= one & mask & NETIF_F_ONE_FOR_ALL; |
4741 | all &= ~NETIF_F_GSO_MASK; | ||
4742 | 4749 | ||
4743 | return all; | 4750 | return all; |
4744 | } | 4751 | } |
4745 | EXPORT_SYMBOL(netdev_compute_features); | 4752 | EXPORT_SYMBOL(netdev_increment_features); |
4746 | 4753 | ||
4747 | static struct hlist_head *netdev_create_hash(void) | 4754 | static struct hlist_head *netdev_create_hash(void) |
4748 | { | 4755 | { |
diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c index 990a58493235..ba85d8831893 100644 --- a/net/ipv4/tcp_output.c +++ b/net/ipv4/tcp_output.c | |||
@@ -362,6 +362,17 @@ struct tcp_out_options { | |||
362 | __u32 tsval, tsecr; /* need to include OPTION_TS */ | 362 | __u32 tsval, tsecr; /* need to include OPTION_TS */ |
363 | }; | 363 | }; |
364 | 364 | ||
365 | /* Beware: Something in the Internet is very sensitive to the ordering of | ||
366 | * TCP options, we learned this through the hard way, so be careful here. | ||
367 | * Luckily we can at least blame others for their non-compliance but from | ||
368 | * inter-operatibility perspective it seems that we're somewhat stuck with | ||
369 | * the ordering which we have been using if we want to keep working with | ||
370 | * those broken things (not that it currently hurts anybody as there isn't | ||
371 | * particular reason why the ordering would need to be changed). | ||
372 | * | ||
373 | * At least SACK_PERM as the first option is known to lead to a disaster | ||
374 | * (but it may well be that other scenarios fail similarly). | ||
375 | */ | ||
365 | static void tcp_options_write(__be32 *ptr, struct tcp_sock *tp, | 376 | static void tcp_options_write(__be32 *ptr, struct tcp_sock *tp, |
366 | const struct tcp_out_options *opts, | 377 | const struct tcp_out_options *opts, |
367 | __u8 **md5_hash) { | 378 | __u8 **md5_hash) { |
@@ -376,6 +387,12 @@ static void tcp_options_write(__be32 *ptr, struct tcp_sock *tp, | |||
376 | *md5_hash = NULL; | 387 | *md5_hash = NULL; |
377 | } | 388 | } |
378 | 389 | ||
390 | if (unlikely(opts->mss)) { | ||
391 | *ptr++ = htonl((TCPOPT_MSS << 24) | | ||
392 | (TCPOLEN_MSS << 16) | | ||
393 | opts->mss); | ||
394 | } | ||
395 | |||
379 | if (likely(OPTION_TS & opts->options)) { | 396 | if (likely(OPTION_TS & opts->options)) { |
380 | if (unlikely(OPTION_SACK_ADVERTISE & opts->options)) { | 397 | if (unlikely(OPTION_SACK_ADVERTISE & opts->options)) { |
381 | *ptr++ = htonl((TCPOPT_SACK_PERM << 24) | | 398 | *ptr++ = htonl((TCPOPT_SACK_PERM << 24) | |
@@ -392,12 +409,6 @@ static void tcp_options_write(__be32 *ptr, struct tcp_sock *tp, | |||
392 | *ptr++ = htonl(opts->tsecr); | 409 | *ptr++ = htonl(opts->tsecr); |
393 | } | 410 | } |
394 | 411 | ||
395 | if (unlikely(opts->mss)) { | ||
396 | *ptr++ = htonl((TCPOPT_MSS << 24) | | ||
397 | (TCPOLEN_MSS << 16) | | ||
398 | opts->mss); | ||
399 | } | ||
400 | |||
401 | if (unlikely(OPTION_SACK_ADVERTISE & opts->options && | 412 | if (unlikely(OPTION_SACK_ADVERTISE & opts->options && |
402 | !(OPTION_TS & opts->options))) { | 413 | !(OPTION_TS & opts->options))) { |
403 | *ptr++ = htonl((TCPOPT_NOP << 24) | | 414 | *ptr++ = htonl((TCPOPT_NOP << 24) | |
@@ -432,7 +443,7 @@ static void tcp_options_write(__be32 *ptr, struct tcp_sock *tp, | |||
432 | 443 | ||
433 | if (tp->rx_opt.dsack) { | 444 | if (tp->rx_opt.dsack) { |
434 | tp->rx_opt.dsack = 0; | 445 | tp->rx_opt.dsack = 0; |
435 | tp->rx_opt.eff_sacks--; | 446 | tp->rx_opt.eff_sacks = tp->rx_opt.num_sacks; |
436 | } | 447 | } |
437 | } | 448 | } |
438 | } | 449 | } |
@@ -2268,6 +2279,11 @@ struct sk_buff *tcp_make_synack(struct sock *sk, struct dst_entry *dst, | |||
2268 | } | 2279 | } |
2269 | 2280 | ||
2270 | memset(&opts, 0, sizeof(opts)); | 2281 | memset(&opts, 0, sizeof(opts)); |
2282 | #ifdef CONFIG_SYN_COOKIES | ||
2283 | if (unlikely(req->cookie_ts)) | ||
2284 | TCP_SKB_CB(skb)->when = cookie_init_timestamp(req); | ||
2285 | else | ||
2286 | #endif | ||
2271 | TCP_SKB_CB(skb)->when = tcp_time_stamp; | 2287 | TCP_SKB_CB(skb)->when = tcp_time_stamp; |
2272 | tcp_header_size = tcp_synack_options(sk, req, mss, | 2288 | tcp_header_size = tcp_synack_options(sk, req, mss, |
2273 | skb, &opts, &md5) + | 2289 | skb, &opts, &md5) + |
@@ -2293,11 +2309,6 @@ struct sk_buff *tcp_make_synack(struct sock *sk, struct dst_entry *dst, | |||
2293 | 2309 | ||
2294 | /* RFC1323: The window in SYN & SYN/ACK segments is never scaled. */ | 2310 | /* RFC1323: The window in SYN & SYN/ACK segments is never scaled. */ |
2295 | th->window = htons(min(req->rcv_wnd, 65535U)); | 2311 | th->window = htons(min(req->rcv_wnd, 65535U)); |
2296 | #ifdef CONFIG_SYN_COOKIES | ||
2297 | if (unlikely(req->cookie_ts)) | ||
2298 | TCP_SKB_CB(skb)->when = cookie_init_timestamp(req); | ||
2299 | else | ||
2300 | #endif | ||
2301 | tcp_options_write((__be32 *)(th + 1), tp, &opts, &md5_hash_location); | 2312 | tcp_options_write((__be32 *)(th + 1), tp, &opts, &md5_hash_location); |
2302 | th->doff = (tcp_header_size >> 2); | 2313 | th->doff = (tcp_header_size >> 2); |
2303 | TCP_INC_STATS(sock_net(sk), TCP_MIB_OUTSEGS); | 2314 | TCP_INC_STATS(sock_net(sk), TCP_MIB_OUTSEGS); |
diff --git a/net/phonet/af_phonet.c b/net/phonet/af_phonet.c index b9d97effebe3..defeb7a0d502 100644 --- a/net/phonet/af_phonet.c +++ b/net/phonet/af_phonet.c | |||
@@ -261,6 +261,8 @@ static inline int can_respond(struct sk_buff *skb) | |||
261 | return 0; /* we are not the destination */ | 261 | return 0; /* we are not the destination */ |
262 | if (ph->pn_res == PN_PREFIX && !pskb_may_pull(skb, 5)) | 262 | if (ph->pn_res == PN_PREFIX && !pskb_may_pull(skb, 5)) |
263 | return 0; | 263 | return 0; |
264 | if (ph->pn_res == PN_COMMGR) /* indications */ | ||
265 | return 0; | ||
264 | 266 | ||
265 | ph = pn_hdr(skb); /* re-acquires the pointer */ | 267 | ph = pn_hdr(skb); /* re-acquires the pointer */ |
266 | pm = pn_msg(skb); | 268 | pm = pn_msg(skb); |
@@ -309,7 +311,8 @@ static int send_reset_indications(struct sk_buff *rskb) | |||
309 | 311 | ||
310 | return pn_raw_send(data, sizeof(data), rskb->dev, | 312 | return pn_raw_send(data, sizeof(data), rskb->dev, |
311 | pn_object(oph->pn_sdev, 0x00), | 313 | pn_object(oph->pn_sdev, 0x00), |
312 | pn_object(oph->pn_rdev, oph->pn_robj), 0x10); | 314 | pn_object(oph->pn_rdev, oph->pn_robj), |
315 | PN_COMMGR); | ||
313 | } | 316 | } |
314 | 317 | ||
315 | 318 | ||
diff --git a/net/sctp/input.c b/net/sctp/input.c index a49fa80b57b9..bf612d954d41 100644 --- a/net/sctp/input.c +++ b/net/sctp/input.c | |||
@@ -369,7 +369,7 @@ static void sctp_add_backlog(struct sock *sk, struct sk_buff *skb) | |||
369 | void sctp_icmp_frag_needed(struct sock *sk, struct sctp_association *asoc, | 369 | void sctp_icmp_frag_needed(struct sock *sk, struct sctp_association *asoc, |
370 | struct sctp_transport *t, __u32 pmtu) | 370 | struct sctp_transport *t, __u32 pmtu) |
371 | { | 371 | { |
372 | if (!t || (t->pathmtu == pmtu)) | 372 | if (!t || (t->pathmtu <= pmtu)) |
373 | return; | 373 | return; |
374 | 374 | ||
375 | if (sock_owned_by_user(sk)) { | 375 | if (sock_owned_by_user(sk)) { |
diff --git a/net/sctp/sm_statefuns.c b/net/sctp/sm_statefuns.c index d4c3fbc4671e..a6a0ea71ae93 100644 --- a/net/sctp/sm_statefuns.c +++ b/net/sctp/sm_statefuns.c | |||
@@ -2544,6 +2544,7 @@ sctp_disposition_t sctp_sf_do_9_2_shutdown(const struct sctp_endpoint *ep, | |||
2544 | sctp_shutdownhdr_t *sdh; | 2544 | sctp_shutdownhdr_t *sdh; |
2545 | sctp_disposition_t disposition; | 2545 | sctp_disposition_t disposition; |
2546 | struct sctp_ulpevent *ev; | 2546 | struct sctp_ulpevent *ev; |
2547 | __u32 ctsn; | ||
2547 | 2548 | ||
2548 | if (!sctp_vtag_verify(chunk, asoc)) | 2549 | if (!sctp_vtag_verify(chunk, asoc)) |
2549 | return sctp_sf_pdiscard(ep, asoc, type, arg, commands); | 2550 | return sctp_sf_pdiscard(ep, asoc, type, arg, commands); |
@@ -2558,6 +2559,14 @@ sctp_disposition_t sctp_sf_do_9_2_shutdown(const struct sctp_endpoint *ep, | |||
2558 | sdh = (sctp_shutdownhdr_t *)chunk->skb->data; | 2559 | sdh = (sctp_shutdownhdr_t *)chunk->skb->data; |
2559 | skb_pull(chunk->skb, sizeof(sctp_shutdownhdr_t)); | 2560 | skb_pull(chunk->skb, sizeof(sctp_shutdownhdr_t)); |
2560 | chunk->subh.shutdown_hdr = sdh; | 2561 | chunk->subh.shutdown_hdr = sdh; |
2562 | ctsn = ntohl(sdh->cum_tsn_ack); | ||
2563 | |||
2564 | /* If Cumulative TSN Ack beyond the max tsn currently | ||
2565 | * send, terminating the association and respond to the | ||
2566 | * sender with an ABORT. | ||
2567 | */ | ||
2568 | if (!TSN_lt(ctsn, asoc->next_tsn)) | ||
2569 | return sctp_sf_violation_ctsn(ep, asoc, type, arg, commands); | ||
2561 | 2570 | ||
2562 | /* API 5.3.1.5 SCTP_SHUTDOWN_EVENT | 2571 | /* API 5.3.1.5 SCTP_SHUTDOWN_EVENT |
2563 | * When a peer sends a SHUTDOWN, SCTP delivers this notification to | 2572 | * When a peer sends a SHUTDOWN, SCTP delivers this notification to |
@@ -2599,6 +2608,51 @@ out: | |||
2599 | return disposition; | 2608 | return disposition; |
2600 | } | 2609 | } |
2601 | 2610 | ||
2611 | /* | ||
2612 | * sctp_sf_do_9_2_shut_ctsn | ||
2613 | * | ||
2614 | * Once an endpoint has reached the SHUTDOWN-RECEIVED state, | ||
2615 | * it MUST NOT send a SHUTDOWN in response to a ULP request. | ||
2616 | * The Cumulative TSN Ack of the received SHUTDOWN chunk | ||
2617 | * MUST be processed. | ||
2618 | */ | ||
2619 | sctp_disposition_t sctp_sf_do_9_2_shut_ctsn(const struct sctp_endpoint *ep, | ||
2620 | const struct sctp_association *asoc, | ||
2621 | const sctp_subtype_t type, | ||
2622 | void *arg, | ||
2623 | sctp_cmd_seq_t *commands) | ||
2624 | { | ||
2625 | struct sctp_chunk *chunk = arg; | ||
2626 | sctp_shutdownhdr_t *sdh; | ||
2627 | |||
2628 | if (!sctp_vtag_verify(chunk, asoc)) | ||
2629 | return sctp_sf_pdiscard(ep, asoc, type, arg, commands); | ||
2630 | |||
2631 | /* Make sure that the SHUTDOWN chunk has a valid length. */ | ||
2632 | if (!sctp_chunk_length_valid(chunk, | ||
2633 | sizeof(struct sctp_shutdown_chunk_t))) | ||
2634 | return sctp_sf_violation_chunklen(ep, asoc, type, arg, | ||
2635 | commands); | ||
2636 | |||
2637 | sdh = (sctp_shutdownhdr_t *)chunk->skb->data; | ||
2638 | |||
2639 | /* If Cumulative TSN Ack beyond the max tsn currently | ||
2640 | * send, terminating the association and respond to the | ||
2641 | * sender with an ABORT. | ||
2642 | */ | ||
2643 | if (!TSN_lt(ntohl(sdh->cum_tsn_ack), asoc->next_tsn)) | ||
2644 | return sctp_sf_violation_ctsn(ep, asoc, type, arg, commands); | ||
2645 | |||
2646 | /* verify, by checking the Cumulative TSN Ack field of the | ||
2647 | * chunk, that all its outstanding DATA chunks have been | ||
2648 | * received by the SHUTDOWN sender. | ||
2649 | */ | ||
2650 | sctp_add_cmd_sf(commands, SCTP_CMD_PROCESS_CTSN, | ||
2651 | SCTP_BE32(sdh->cum_tsn_ack)); | ||
2652 | |||
2653 | return SCTP_DISPOSITION_CONSUME; | ||
2654 | } | ||
2655 | |||
2602 | /* RFC 2960 9.2 | 2656 | /* RFC 2960 9.2 |
2603 | * If an endpoint is in SHUTDOWN-ACK-SENT state and receives an INIT chunk | 2657 | * If an endpoint is in SHUTDOWN-ACK-SENT state and receives an INIT chunk |
2604 | * (e.g., if the SHUTDOWN COMPLETE was lost) with source and destination | 2658 | * (e.g., if the SHUTDOWN COMPLETE was lost) with source and destination |
diff --git a/net/sctp/sm_statetable.c b/net/sctp/sm_statetable.c index dd4ddc40c0ad..5c8186d88c61 100644 --- a/net/sctp/sm_statetable.c +++ b/net/sctp/sm_statetable.c | |||
@@ -266,11 +266,11 @@ const sctp_sm_table_entry_t *sctp_sm_lookup_event(sctp_event_t event_type, | |||
266 | /* SCTP_STATE_ESTABLISHED */ \ | 266 | /* SCTP_STATE_ESTABLISHED */ \ |
267 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shutdown), \ | 267 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shutdown), \ |
268 | /* SCTP_STATE_SHUTDOWN_PENDING */ \ | 268 | /* SCTP_STATE_SHUTDOWN_PENDING */ \ |
269 | TYPE_SCTP_FUNC(sctp_sf_discard_chunk), \ | 269 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shutdown), \ |
270 | /* SCTP_STATE_SHUTDOWN_SENT */ \ | 270 | /* SCTP_STATE_SHUTDOWN_SENT */ \ |
271 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shutdown_ack), \ | 271 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shutdown_ack), \ |
272 | /* SCTP_STATE_SHUTDOWN_RECEIVED */ \ | 272 | /* SCTP_STATE_SHUTDOWN_RECEIVED */ \ |
273 | TYPE_SCTP_FUNC(sctp_sf_discard_chunk), \ | 273 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shut_ctsn), \ |
274 | /* SCTP_STATE_SHUTDOWN_ACK_SENT */ \ | 274 | /* SCTP_STATE_SHUTDOWN_ACK_SENT */ \ |
275 | TYPE_SCTP_FUNC(sctp_sf_discard_chunk), \ | 275 | TYPE_SCTP_FUNC(sctp_sf_discard_chunk), \ |
276 | } /* TYPE_SCTP_SHUTDOWN */ | 276 | } /* TYPE_SCTP_SHUTDOWN */ |
diff --git a/net/wireless/Kconfig b/net/wireless/Kconfig index 7d82be07fa1d..646c7121dbc0 100644 --- a/net/wireless/Kconfig +++ b/net/wireless/Kconfig | |||
@@ -16,7 +16,7 @@ config NL80211 | |||
16 | 16 | ||
17 | config WIRELESS_OLD_REGULATORY | 17 | config WIRELESS_OLD_REGULATORY |
18 | bool "Old wireless static regulatory definitions" | 18 | bool "Old wireless static regulatory definitions" |
19 | default n | 19 | default y |
20 | ---help--- | 20 | ---help--- |
21 | This option enables the old static regulatory information | 21 | This option enables the old static regulatory information |
22 | and uses it within the new framework. This is available | 22 | and uses it within the new framework. This is available |
@@ -40,11 +40,10 @@ config WIRELESS_OLD_REGULATORY | |||
40 | ieee80211_regdom module parameter. This is being phased out and you | 40 | ieee80211_regdom module parameter. This is being phased out and you |
41 | should stop using them ASAP. | 41 | should stop using them ASAP. |
42 | 42 | ||
43 | Say N unless you cannot install a new userspace application | 43 | Say Y unless you have installed a new userspace application. |
44 | or have one currently depending on the ieee80211_regdom module | 44 | Also say Y if have one currently depending on the ieee80211_regdom |
45 | parameter and cannot port it to use the new userspace interfaces. | 45 | module parameter and cannot port it to use the new userspace |
46 | 46 | interfaces. | |
47 | This is scheduled for removal for 2.6.29. | ||
48 | 47 | ||
49 | config WIRELESS_EXT | 48 | config WIRELESS_EXT |
50 | bool "Wireless extensions" | 49 | bool "Wireless extensions" |
diff --git a/scripts/checkstack.pl b/scripts/checkstack.pl index f7e8e93ff30d..14ee68e991dd 100755 --- a/scripts/checkstack.pl +++ b/scripts/checkstack.pl | |||
@@ -14,6 +14,7 @@ | |||
14 | # M68k port by Geert Uytterhoeven and Andreas Schwab | 14 | # M68k port by Geert Uytterhoeven and Andreas Schwab |
15 | # AVR32 port by Haavard Skinnemoen <hskinnemoen@atmel.com> | 15 | # AVR32 port by Haavard Skinnemoen <hskinnemoen@atmel.com> |
16 | # PARISC port by Kyle McMartin <kyle@parisc-linux.org> | 16 | # PARISC port by Kyle McMartin <kyle@parisc-linux.org> |
17 | # sparc port by Martin Habets <errandir_news@mph.eclipse.co.uk> | ||
17 | # | 18 | # |
18 | # Usage: | 19 | # Usage: |
19 | # objdump -d vmlinux | scripts/checkstack.pl [arch] | 20 | # objdump -d vmlinux | scripts/checkstack.pl [arch] |
@@ -94,6 +95,9 @@ my (@stack, $re, $dre, $x, $xs); | |||
94 | } elsif ($arch =~ /^blackfin$/) { | 95 | } elsif ($arch =~ /^blackfin$/) { |
95 | # 0: 00 e8 38 01 LINK 0x4e0; | 96 | # 0: 00 e8 38 01 LINK 0x4e0; |
96 | $re = qr/.*[[:space:]]LINK[[:space:]]*(0x$x{1,8})/o; | 97 | $re = qr/.*[[:space:]]LINK[[:space:]]*(0x$x{1,8})/o; |
98 | } elsif ($arch eq 'sparc' || $arch eq 'sparc64') { | ||
99 | # f0019d10: 9d e3 bf 90 save %sp, -112, %sp | ||
100 | $re = qr/.*save.*%sp, -(([0-9]{2}|[3-9])[0-9]{2}), %sp/o; | ||
97 | } else { | 101 | } else { |
98 | print("wrong or unknown architecture \"$arch\"\n"); | 102 | print("wrong or unknown architecture \"$arch\"\n"); |
99 | exit | 103 | exit |
diff --git a/scripts/kconfig/confdata.c b/scripts/kconfig/confdata.c index b91cf241a539..830d9eae11f9 100644 --- a/scripts/kconfig/confdata.c +++ b/scripts/kconfig/confdata.c | |||
@@ -852,8 +852,7 @@ void conf_set_all_new_symbols(enum conf_def_mode mode) | |||
852 | 852 | ||
853 | } | 853 | } |
854 | 854 | ||
855 | if (modules_sym) | 855 | sym_clear_all_valid(); |
856 | sym_calc_value(modules_sym); | ||
857 | 856 | ||
858 | if (mode != def_random) | 857 | if (mode != def_random) |
859 | return; | 858 | return; |
diff --git a/scripts/kernel-doc b/scripts/kernel-doc index 44ee94d2ab76..a53e2fc8dfb5 100755 --- a/scripts/kernel-doc +++ b/scripts/kernel-doc | |||
@@ -1648,7 +1648,7 @@ sub dump_function($$) { | |||
1648 | $prototype =~ s/^noinline +//; | 1648 | $prototype =~ s/^noinline +//; |
1649 | $prototype =~ s/__devinit +//; | 1649 | $prototype =~ s/__devinit +//; |
1650 | $prototype =~ s/__init +//; | 1650 | $prototype =~ s/__init +//; |
1651 | $prototype =~ s/^#define\s+//; #ak added | 1651 | $prototype =~ s/^#\s*define\s+//; #ak added |
1652 | $prototype =~ s/__attribute__\s*\(\([a-z,]*\)\)//; | 1652 | $prototype =~ s/__attribute__\s*\(\([a-z,]*\)\)//; |
1653 | 1653 | ||
1654 | # Yes, this truly is vile. We are looking for: | 1654 | # Yes, this truly is vile. We are looking for: |
@@ -1764,13 +1764,13 @@ sub process_state3_function($$) { | |||
1764 | 1764 | ||
1765 | $x =~ s@\/\/.*$@@gos; # strip C99-style comments to end of line | 1765 | $x =~ s@\/\/.*$@@gos; # strip C99-style comments to end of line |
1766 | 1766 | ||
1767 | if ($x =~ m#\s*/\*\s+MACDOC\s*#io || ($x =~ /^#/ && $x !~ /^#define/)) { | 1767 | if ($x =~ m#\s*/\*\s+MACDOC\s*#io || ($x =~ /^#/ && $x !~ /^#\s*define/)) { |
1768 | # do nothing | 1768 | # do nothing |
1769 | } | 1769 | } |
1770 | elsif ($x =~ /([^\{]*)/) { | 1770 | elsif ($x =~ /([^\{]*)/) { |
1771 | $prototype .= $1; | 1771 | $prototype .= $1; |
1772 | } | 1772 | } |
1773 | if (($x =~ /\{/) || ($x =~ /\#define/) || ($x =~ /;/)) { | 1773 | if (($x =~ /\{/) || ($x =~ /\#\s*define/) || ($x =~ /;/)) { |
1774 | $prototype =~ s@/\*.*?\*/@@gos; # strip comments. | 1774 | $prototype =~ s@/\*.*?\*/@@gos; # strip comments. |
1775 | $prototype =~ s@[\r\n]+@ @gos; # strip newlines/cr's. | 1775 | $prototype =~ s@[\r\n]+@ @gos; # strip newlines/cr's. |
1776 | $prototype =~ s@^\s+@@gos; # strip leading spaces | 1776 | $prototype =~ s@^\s+@@gos; # strip leading spaces |
diff --git a/sound/oss/kahlua.c b/sound/oss/kahlua.c index eb9bc365530d..c180598f1710 100644 --- a/sound/oss/kahlua.c +++ b/sound/oss/kahlua.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * Initialisation code for Cyrix/NatSemi VSA1 softaudio | 2 | * Initialisation code for Cyrix/NatSemi VSA1 softaudio |
3 | * | 3 | * |
4 | * (C) Copyright 2003 Red Hat Inc <alan@redhat.com> | 4 | * (C) Copyright 2003 Red Hat Inc <alan@lxorguk.ukuu.org.uk> |
5 | * | 5 | * |
6 | * XpressAudio(tm) is used on the Cyrix MediaGX (now NatSemi Geode) systems. | 6 | * XpressAudio(tm) is used on the Cyrix MediaGX (now NatSemi Geode) systems. |
7 | * The older version (VSA1) provides fairly good soundblaster emulation | 7 | * The older version (VSA1) provides fairly good soundblaster emulation |
diff --git a/sound/pci/ad1889.c b/sound/pci/ad1889.c index 92f3a976ef2e..a7f38e63303f 100644 --- a/sound/pci/ad1889.c +++ b/sound/pci/ad1889.c | |||
@@ -932,7 +932,7 @@ snd_ad1889_create(struct snd_card *card, | |||
932 | goto free_and_ret; | 932 | goto free_and_ret; |
933 | 933 | ||
934 | chip->bar = pci_resource_start(pci, 0); | 934 | chip->bar = pci_resource_start(pci, 0); |
935 | chip->iobase = ioremap_nocache(chip->bar, pci_resource_len(pci, 0)); | 935 | chip->iobase = pci_ioremap_bar(pci, 0); |
936 | if (chip->iobase == NULL) { | 936 | if (chip->iobase == NULL) { |
937 | printk(KERN_ERR PFX "unable to reserve region.\n"); | 937 | printk(KERN_ERR PFX "unable to reserve region.\n"); |
938 | err = -EBUSY; | 938 | err = -EBUSY; |
diff --git a/sound/pci/atiixp.c b/sound/pci/atiixp.c index 085a52b8c807..226fe8237d31 100644 --- a/sound/pci/atiixp.c +++ b/sound/pci/atiixp.c | |||
@@ -1609,7 +1609,7 @@ static int __devinit snd_atiixp_create(struct snd_card *card, | |||
1609 | return err; | 1609 | return err; |
1610 | } | 1610 | } |
1611 | chip->addr = pci_resource_start(pci, 0); | 1611 | chip->addr = pci_resource_start(pci, 0); |
1612 | chip->remap_addr = ioremap_nocache(chip->addr, pci_resource_len(pci, 0)); | 1612 | chip->remap_addr = pci_ioremap_bar(pci, 0); |
1613 | if (chip->remap_addr == NULL) { | 1613 | if (chip->remap_addr == NULL) { |
1614 | snd_printk(KERN_ERR "AC'97 space ioremap problem\n"); | 1614 | snd_printk(KERN_ERR "AC'97 space ioremap problem\n"); |
1615 | snd_atiixp_free(chip); | 1615 | snd_atiixp_free(chip); |
diff --git a/sound/pci/atiixp_modem.c b/sound/pci/atiixp_modem.c index 2f106306c7fe..0e6e5cc1c501 100644 --- a/sound/pci/atiixp_modem.c +++ b/sound/pci/atiixp_modem.c | |||
@@ -1252,7 +1252,7 @@ static int __devinit snd_atiixp_create(struct snd_card *card, | |||
1252 | return err; | 1252 | return err; |
1253 | } | 1253 | } |
1254 | chip->addr = pci_resource_start(pci, 0); | 1254 | chip->addr = pci_resource_start(pci, 0); |
1255 | chip->remap_addr = ioremap_nocache(chip->addr, pci_resource_len(pci, 0)); | 1255 | chip->remap_addr = pci_ioremap_bar(pci, 0); |
1256 | if (chip->remap_addr == NULL) { | 1256 | if (chip->remap_addr == NULL) { |
1257 | snd_printk(KERN_ERR "AC'97 space ioremap problem\n"); | 1257 | snd_printk(KERN_ERR "AC'97 space ioremap problem\n"); |
1258 | snd_atiixp_free(chip); | 1258 | snd_atiixp_free(chip); |
diff --git a/sound/pci/au88x0/au88x0.c b/sound/pci/au88x0/au88x0.c index 68368e490074..a36d4d1fd419 100644 --- a/sound/pci/au88x0/au88x0.c +++ b/sound/pci/au88x0/au88x0.c | |||
@@ -180,8 +180,7 @@ snd_vortex_create(struct snd_card *card, struct pci_dev *pci, vortex_t ** rchip) | |||
180 | if ((err = pci_request_regions(pci, CARD_NAME_SHORT)) != 0) | 180 | if ((err = pci_request_regions(pci, CARD_NAME_SHORT)) != 0) |
181 | goto regions_out; | 181 | goto regions_out; |
182 | 182 | ||
183 | chip->mmio = ioremap_nocache(pci_resource_start(pci, 0), | 183 | chip->mmio = pci_ioremap_bar(pci, 0); |
184 | pci_resource_len(pci, 0)); | ||
185 | if (!chip->mmio) { | 184 | if (!chip->mmio) { |
186 | printk(KERN_ERR "MMIO area remap failed.\n"); | 185 | printk(KERN_ERR "MMIO area remap failed.\n"); |
187 | err = -ENOMEM; | 186 | err = -ENOMEM; |
diff --git a/sound/pci/bt87x.c b/sound/pci/bt87x.c index 3aa8d973540a..1aa1c0402540 100644 --- a/sound/pci/bt87x.c +++ b/sound/pci/bt87x.c | |||
@@ -749,8 +749,7 @@ static int __devinit snd_bt87x_create(struct snd_card *card, | |||
749 | pci_disable_device(pci); | 749 | pci_disable_device(pci); |
750 | return err; | 750 | return err; |
751 | } | 751 | } |
752 | chip->mmio = ioremap_nocache(pci_resource_start(pci, 0), | 752 | chip->mmio = pci_ioremap_bar(pci, 0); |
753 | pci_resource_len(pci, 0)); | ||
754 | if (!chip->mmio) { | 753 | if (!chip->mmio) { |
755 | snd_printk(KERN_ERR "cannot remap io memory\n"); | 754 | snd_printk(KERN_ERR "cannot remap io memory\n"); |
756 | err = -ENOMEM; | 755 | err = -ENOMEM; |
diff --git a/sound/pci/cs4281.c b/sound/pci/cs4281.c index ef9308f7c45b..192e7842e181 100644 --- a/sound/pci/cs4281.c +++ b/sound/pci/cs4281.c | |||
@@ -1382,8 +1382,8 @@ static int __devinit snd_cs4281_create(struct snd_card *card, | |||
1382 | chip->ba0_addr = pci_resource_start(pci, 0); | 1382 | chip->ba0_addr = pci_resource_start(pci, 0); |
1383 | chip->ba1_addr = pci_resource_start(pci, 1); | 1383 | chip->ba1_addr = pci_resource_start(pci, 1); |
1384 | 1384 | ||
1385 | chip->ba0 = ioremap_nocache(chip->ba0_addr, pci_resource_len(pci, 0)); | 1385 | chip->ba0 = pci_ioremap_bar(pci, 0); |
1386 | chip->ba1 = ioremap_nocache(chip->ba1_addr, pci_resource_len(pci, 1)); | 1386 | chip->ba1 = pci_ioremap_bar(pci, 1); |
1387 | if (!chip->ba0 || !chip->ba1) { | 1387 | if (!chip->ba0 || !chip->ba1) { |
1388 | snd_cs4281_free(chip); | 1388 | snd_cs4281_free(chip); |
1389 | return -ENOMEM; | 1389 | return -ENOMEM; |
diff --git a/sound/pci/cs5530.c b/sound/pci/cs5530.c index 7ff8b68e997e..6dea5b5cc774 100644 --- a/sound/pci/cs5530.c +++ b/sound/pci/cs5530.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * cs5530.c - Initialisation code for Cyrix/NatSemi VSA1 softaudio | 2 | * cs5530.c - Initialisation code for Cyrix/NatSemi VSA1 softaudio |
3 | * | 3 | * |
4 | * (C) Copyright 2007 Ash Willis <ashwillis@programmer.net> | 4 | * (C) Copyright 2007 Ash Willis <ashwillis@programmer.net> |
5 | * (C) Copyright 2003 Red Hat Inc <alan@redhat.com> | 5 | * (C) Copyright 2003 Red Hat Inc <alan@lxorguk.ukuu.org.uk> |
6 | * | 6 | * |
7 | * This driver was ported (shamelessly ripped ;) from oss/kahlua.c but I did | 7 | * This driver was ported (shamelessly ripped ;) from oss/kahlua.c but I did |
8 | * mess with it a bit. The chip seems to have to have trouble with full duplex | 8 | * mess with it a bit. The chip seems to have to have trouble with full duplex |
@@ -132,7 +132,7 @@ static int __devinit snd_cs5530_create(struct snd_card *card, | |||
132 | } | 132 | } |
133 | chip->pci_base = pci_resource_start(pci, 0); | 133 | chip->pci_base = pci_resource_start(pci, 0); |
134 | 134 | ||
135 | mem = ioremap_nocache(chip->pci_base, pci_resource_len(pci, 0)); | 135 | mem = pci_ioremap_bar(pci, 0); |
136 | if (mem == NULL) { | 136 | if (mem == NULL) { |
137 | kfree(chip); | 137 | kfree(chip); |
138 | pci_disable_device(pci); | 138 | pci_disable_device(pci); |
diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c index 9f316c1b2790..f080f8ce0ecb 100644 --- a/sound/pci/hda/hda_intel.c +++ b/sound/pci/hda/hda_intel.c | |||
@@ -2158,7 +2158,7 @@ static int __devinit azx_create(struct snd_card *card, struct pci_dev *pci, | |||
2158 | } | 2158 | } |
2159 | 2159 | ||
2160 | chip->addr = pci_resource_start(pci, 0); | 2160 | chip->addr = pci_resource_start(pci, 0); |
2161 | chip->remap_addr = ioremap_nocache(chip->addr, pci_resource_len(pci,0)); | 2161 | chip->remap_addr = pci_ioremap_bar(pci, 0); |
2162 | if (chip->remap_addr == NULL) { | 2162 | if (chip->remap_addr == NULL) { |
2163 | snd_printk(KERN_ERR SFX "ioremap error\n"); | 2163 | snd_printk(KERN_ERR SFX "ioremap error\n"); |
2164 | err = -ENXIO; | 2164 | err = -ENXIO; |
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index ef4955c73c88..4eceab9bd109 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c | |||
@@ -307,6 +307,13 @@ struct alc_spec { | |||
307 | /* for PLL fix */ | 307 | /* for PLL fix */ |
308 | hda_nid_t pll_nid; | 308 | hda_nid_t pll_nid; |
309 | unsigned int pll_coef_idx, pll_coef_bit; | 309 | unsigned int pll_coef_idx, pll_coef_bit; |
310 | |||
311 | #ifdef SND_HDA_NEEDS_RESUME | ||
312 | #define ALC_MAX_PINS 16 | ||
313 | unsigned int num_pins; | ||
314 | hda_nid_t pin_nids[ALC_MAX_PINS]; | ||
315 | unsigned int pin_cfgs[ALC_MAX_PINS]; | ||
316 | #endif | ||
310 | }; | 317 | }; |
311 | 318 | ||
312 | /* | 319 | /* |
@@ -2778,6 +2785,64 @@ static void alc_free(struct hda_codec *codec) | |||
2778 | codec->spec = NULL; /* to be sure */ | 2785 | codec->spec = NULL; /* to be sure */ |
2779 | } | 2786 | } |
2780 | 2787 | ||
2788 | #ifdef SND_HDA_NEEDS_RESUME | ||
2789 | static void store_pin_configs(struct hda_codec *codec) | ||
2790 | { | ||
2791 | struct alc_spec *spec = codec->spec; | ||
2792 | hda_nid_t nid, end_nid; | ||
2793 | |||
2794 | end_nid = codec->start_nid + codec->num_nodes; | ||
2795 | for (nid = codec->start_nid; nid < end_nid; nid++) { | ||
2796 | unsigned int wid_caps = get_wcaps(codec, nid); | ||
2797 | unsigned int wid_type = | ||
2798 | (wid_caps & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT; | ||
2799 | if (wid_type != AC_WID_PIN) | ||
2800 | continue; | ||
2801 | if (spec->num_pins >= ARRAY_SIZE(spec->pin_nids)) | ||
2802 | break; | ||
2803 | spec->pin_nids[spec->num_pins] = nid; | ||
2804 | spec->pin_cfgs[spec->num_pins] = | ||
2805 | snd_hda_codec_read(codec, nid, 0, | ||
2806 | AC_VERB_GET_CONFIG_DEFAULT, 0); | ||
2807 | spec->num_pins++; | ||
2808 | } | ||
2809 | } | ||
2810 | |||
2811 | static void resume_pin_configs(struct hda_codec *codec) | ||
2812 | { | ||
2813 | struct alc_spec *spec = codec->spec; | ||
2814 | int i; | ||
2815 | |||
2816 | for (i = 0; i < spec->num_pins; i++) { | ||
2817 | hda_nid_t pin_nid = spec->pin_nids[i]; | ||
2818 | unsigned int pin_config = spec->pin_cfgs[i]; | ||
2819 | snd_hda_codec_write(codec, pin_nid, 0, | ||
2820 | AC_VERB_SET_CONFIG_DEFAULT_BYTES_0, | ||
2821 | pin_config & 0x000000ff); | ||
2822 | snd_hda_codec_write(codec, pin_nid, 0, | ||
2823 | AC_VERB_SET_CONFIG_DEFAULT_BYTES_1, | ||
2824 | (pin_config & 0x0000ff00) >> 8); | ||
2825 | snd_hda_codec_write(codec, pin_nid, 0, | ||
2826 | AC_VERB_SET_CONFIG_DEFAULT_BYTES_2, | ||
2827 | (pin_config & 0x00ff0000) >> 16); | ||
2828 | snd_hda_codec_write(codec, pin_nid, 0, | ||
2829 | AC_VERB_SET_CONFIG_DEFAULT_BYTES_3, | ||
2830 | pin_config >> 24); | ||
2831 | } | ||
2832 | } | ||
2833 | |||
2834 | static int alc_resume(struct hda_codec *codec) | ||
2835 | { | ||
2836 | resume_pin_configs(codec); | ||
2837 | codec->patch_ops.init(codec); | ||
2838 | snd_hda_codec_resume_amp(codec); | ||
2839 | snd_hda_codec_resume_cache(codec); | ||
2840 | return 0; | ||
2841 | } | ||
2842 | #else | ||
2843 | #define store_pin_configs(codec) | ||
2844 | #endif | ||
2845 | |||
2781 | /* | 2846 | /* |
2782 | */ | 2847 | */ |
2783 | static struct hda_codec_ops alc_patch_ops = { | 2848 | static struct hda_codec_ops alc_patch_ops = { |
@@ -2786,6 +2851,9 @@ static struct hda_codec_ops alc_patch_ops = { | |||
2786 | .init = alc_init, | 2851 | .init = alc_init, |
2787 | .free = alc_free, | 2852 | .free = alc_free, |
2788 | .unsol_event = alc_unsol_event, | 2853 | .unsol_event = alc_unsol_event, |
2854 | #ifdef SND_HDA_NEEDS_RESUME | ||
2855 | .resume = alc_resume, | ||
2856 | #endif | ||
2789 | #ifdef CONFIG_SND_HDA_POWER_SAVE | 2857 | #ifdef CONFIG_SND_HDA_POWER_SAVE |
2790 | .check_power_status = alc_check_power_status, | 2858 | .check_power_status = alc_check_power_status, |
2791 | #endif | 2859 | #endif |
@@ -3832,6 +3900,7 @@ static int alc880_parse_auto_config(struct hda_codec *codec) | |||
3832 | spec->num_mux_defs = 1; | 3900 | spec->num_mux_defs = 1; |
3833 | spec->input_mux = &spec->private_imux; | 3901 | spec->input_mux = &spec->private_imux; |
3834 | 3902 | ||
3903 | store_pin_configs(codec); | ||
3835 | return 1; | 3904 | return 1; |
3836 | } | 3905 | } |
3837 | 3906 | ||
@@ -5250,6 +5319,7 @@ static int alc260_parse_auto_config(struct hda_codec *codec) | |||
5250 | } | 5319 | } |
5251 | spec->num_mixers++; | 5320 | spec->num_mixers++; |
5252 | 5321 | ||
5322 | store_pin_configs(codec); | ||
5253 | return 1; | 5323 | return 1; |
5254 | } | 5324 | } |
5255 | 5325 | ||
@@ -10313,6 +10383,7 @@ static int alc262_parse_auto_config(struct hda_codec *codec) | |||
10313 | if (err < 0) | 10383 | if (err < 0) |
10314 | return err; | 10384 | return err; |
10315 | 10385 | ||
10386 | store_pin_configs(codec); | ||
10316 | return 1; | 10387 | return 1; |
10317 | } | 10388 | } |
10318 | 10389 | ||
@@ -11447,6 +11518,7 @@ static int alc268_parse_auto_config(struct hda_codec *codec) | |||
11447 | if (err < 0) | 11518 | if (err < 0) |
11448 | return err; | 11519 | return err; |
11449 | 11520 | ||
11521 | store_pin_configs(codec); | ||
11450 | return 1; | 11522 | return 1; |
11451 | } | 11523 | } |
11452 | 11524 | ||
@@ -12230,6 +12302,7 @@ static int alc269_parse_auto_config(struct hda_codec *codec) | |||
12230 | spec->mixers[spec->num_mixers] = alc269_capture_mixer; | 12302 | spec->mixers[spec->num_mixers] = alc269_capture_mixer; |
12231 | spec->num_mixers++; | 12303 | spec->num_mixers++; |
12232 | 12304 | ||
12305 | store_pin_configs(codec); | ||
12233 | return 1; | 12306 | return 1; |
12234 | } | 12307 | } |
12235 | 12308 | ||
@@ -13316,6 +13389,7 @@ static int alc861_parse_auto_config(struct hda_codec *codec) | |||
13316 | spec->mixers[spec->num_mixers] = alc861_capture_mixer; | 13389 | spec->mixers[spec->num_mixers] = alc861_capture_mixer; |
13317 | spec->num_mixers++; | 13390 | spec->num_mixers++; |
13318 | 13391 | ||
13392 | store_pin_configs(codec); | ||
13319 | return 1; | 13393 | return 1; |
13320 | } | 13394 | } |
13321 | 13395 | ||
@@ -14427,6 +14501,7 @@ static int alc861vd_parse_auto_config(struct hda_codec *codec) | |||
14427 | if (err < 0) | 14501 | if (err < 0) |
14428 | return err; | 14502 | return err; |
14429 | 14503 | ||
14504 | store_pin_configs(codec); | ||
14430 | return 1; | 14505 | return 1; |
14431 | } | 14506 | } |
14432 | 14507 | ||
@@ -16258,6 +16333,8 @@ static int alc662_parse_auto_config(struct hda_codec *codec) | |||
16258 | 16333 | ||
16259 | spec->mixers[spec->num_mixers] = alc662_capture_mixer; | 16334 | spec->mixers[spec->num_mixers] = alc662_capture_mixer; |
16260 | spec->num_mixers++; | 16335 | spec->num_mixers++; |
16336 | |||
16337 | store_pin_configs(codec); | ||
16261 | return 1; | 16338 | return 1; |
16262 | } | 16339 | } |
16263 | 16340 | ||
diff --git a/sound/pci/mixart/mixart.c b/sound/pci/mixart/mixart.c index 2d0dce649a64..ae7601f353a7 100644 --- a/sound/pci/mixart/mixart.c +++ b/sound/pci/mixart/mixart.c | |||
@@ -1314,8 +1314,7 @@ static int __devinit snd_mixart_probe(struct pci_dev *pci, | |||
1314 | } | 1314 | } |
1315 | for (i = 0; i < 2; i++) { | 1315 | for (i = 0; i < 2; i++) { |
1316 | mgr->mem[i].phys = pci_resource_start(pci, i); | 1316 | mgr->mem[i].phys = pci_resource_start(pci, i); |
1317 | mgr->mem[i].virt = ioremap_nocache(mgr->mem[i].phys, | 1317 | mgr->mem[i].virt = pci_ioremap_bar(pci, i); |
1318 | pci_resource_len(pci, i)); | ||
1319 | if (!mgr->mem[i].virt) { | 1318 | if (!mgr->mem[i].virt) { |
1320 | printk(KERN_ERR "unable to remap resource 0x%lx\n", | 1319 | printk(KERN_ERR "unable to remap resource 0x%lx\n", |
1321 | mgr->mem[i].phys); | 1320 | mgr->mem[i].phys); |
diff --git a/sound/soc/blackfin/bf5xx-i2s.c b/sound/soc/blackfin/bf5xx-i2s.c index 827587f08180..e020c160ee44 100644 --- a/sound/soc/blackfin/bf5xx-i2s.c +++ b/sound/soc/blackfin/bf5xx-i2s.c | |||
@@ -70,12 +70,24 @@ static struct sport_param sport_params[2] = { | |||
70 | } | 70 | } |
71 | }; | 71 | }; |
72 | 72 | ||
73 | static u16 sport_req[][7] = { | 73 | /* |
74 | { P_SPORT0_DTPRI, P_SPORT0_TSCLK, P_SPORT0_RFS, | 74 | * Setting the TFS pin selector for SPORT 0 based on whether the selected |
75 | P_SPORT0_DRPRI, P_SPORT0_RSCLK, 0}, | 75 | * port id F or G. If the port is F then no conflict should exist for the |
76 | { P_SPORT1_DTPRI, P_SPORT1_TSCLK, P_SPORT1_RFS, | 76 | * TFS. When Port G is selected and EMAC then there is a conflict between |
77 | P_SPORT1_DRPRI, P_SPORT1_RSCLK, 0}, | 77 | * the PHY interrupt line and TFS. Current settings prevent the conflict |
78 | }; | 78 | * by ignoring the TFS pin when Port G is selected. This allows both |
79 | * ssm2602 using Port G and EMAC concurrently. | ||
80 | */ | ||
81 | #ifdef CONFIG_BF527_SPORT0_PORTF | ||
82 | #define LOCAL_SPORT0_TFS (P_SPORT0_TFS) | ||
83 | #else | ||
84 | #define LOCAL_SPORT0_TFS (0) | ||
85 | #endif | ||
86 | |||
87 | static u16 sport_req[][7] = { {P_SPORT0_DTPRI, P_SPORT0_TSCLK, P_SPORT0_RFS, | ||
88 | P_SPORT0_DRPRI, P_SPORT0_RSCLK, LOCAL_SPORT0_TFS, 0}, | ||
89 | {P_SPORT1_DTPRI, P_SPORT1_TSCLK, P_SPORT1_RFS, P_SPORT1_DRPRI, | ||
90 | P_SPORT1_RSCLK, P_SPORT1_TFS, 0} }; | ||
79 | 91 | ||
80 | static int bf5xx_i2s_set_dai_fmt(struct snd_soc_dai *cpu_dai, | 92 | static int bf5xx_i2s_set_dai_fmt(struct snd_soc_dai *cpu_dai, |
81 | unsigned int fmt) | 93 | unsigned int fmt) |
@@ -98,23 +110,21 @@ static int bf5xx_i2s_set_dai_fmt(struct snd_soc_dai *cpu_dai, | |||
98 | ret = -EINVAL; | 110 | ret = -EINVAL; |
99 | break; | 111 | break; |
100 | default: | 112 | default: |
113 | printk(KERN_ERR "%s: Unknown DAI format type\n", __func__); | ||
101 | ret = -EINVAL; | 114 | ret = -EINVAL; |
102 | break; | 115 | break; |
103 | } | 116 | } |
104 | 117 | ||
105 | switch (fmt & SND_SOC_DAIFMT_MASTER_MASK) { | 118 | switch (fmt & SND_SOC_DAIFMT_MASTER_MASK) { |
106 | case SND_SOC_DAIFMT_CBS_CFS: | ||
107 | ret = -EINVAL; | ||
108 | break; | ||
109 | case SND_SOC_DAIFMT_CBM_CFS: | ||
110 | ret = -EINVAL; | ||
111 | break; | ||
112 | case SND_SOC_DAIFMT_CBM_CFM: | 119 | case SND_SOC_DAIFMT_CBM_CFM: |
113 | break; | 120 | break; |
121 | case SND_SOC_DAIFMT_CBS_CFS: | ||
122 | case SND_SOC_DAIFMT_CBM_CFS: | ||
114 | case SND_SOC_DAIFMT_CBS_CFM: | 123 | case SND_SOC_DAIFMT_CBS_CFM: |
115 | ret = -EINVAL; | 124 | ret = -EINVAL; |
116 | break; | 125 | break; |
117 | default: | 126 | default: |
127 | printk(KERN_ERR "%s: Unknown DAI master type\n", __func__); | ||
118 | ret = -EINVAL; | 128 | ret = -EINVAL; |
119 | break; | 129 | break; |
120 | } | 130 | } |
diff --git a/sound/sound_core.c b/sound/sound_core.c index faef87a9bc3f..a75b289a5d78 100644 --- a/sound/sound_core.c +++ b/sound/sound_core.c | |||
@@ -57,7 +57,7 @@ module_exit(cleanup_soundcore); | |||
57 | /* | 57 | /* |
58 | * OSS sound core handling. Breaks out sound functions to submodules | 58 | * OSS sound core handling. Breaks out sound functions to submodules |
59 | * | 59 | * |
60 | * Author: Alan Cox <alan.cox@linux.org> | 60 | * Author: Alan Cox <alan@lxorguk.ukuu.org.uk> |
61 | * | 61 | * |
62 | * Fixes: | 62 | * Fixes: |
63 | * | 63 | * |