diff options
196 files changed, 1972 insertions, 2052 deletions
diff --git a/Documentation/SubmittingPatches b/Documentation/SubmittingPatches index 08a1ed1cb5d8..47a539c7642d 100644 --- a/Documentation/SubmittingPatches +++ b/Documentation/SubmittingPatches | |||
@@ -512,7 +512,7 @@ They provide type safety, have no length limitations, no formatting | |||
512 | limitations, and under gcc they are as cheap as macros. | 512 | limitations, and under gcc they are as cheap as macros. |
513 | 513 | ||
514 | Macros should only be used for cases where a static inline is clearly | 514 | Macros should only be used for cases where a static inline is clearly |
515 | suboptimal [there a few, isolated cases of this in fast paths], | 515 | suboptimal [there are a few, isolated cases of this in fast paths], |
516 | or where it is impossible to use a static inline function [such as | 516 | or where it is impossible to use a static inline function [such as |
517 | string-izing]. | 517 | string-izing]. |
518 | 518 | ||
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt index 508e2a2c9864..4cd1a5da80a4 100644 --- a/Documentation/kernel-parameters.txt +++ b/Documentation/kernel-parameters.txt | |||
@@ -170,11 +170,6 @@ and is between 256 and 4096 characters. It is defined in the file | |||
170 | acpi_irq_isa= [HW,ACPI] If irq_balance, mark listed IRQs used by ISA | 170 | acpi_irq_isa= [HW,ACPI] If irq_balance, mark listed IRQs used by ISA |
171 | Format: <irq>,<irq>... | 171 | Format: <irq>,<irq>... |
172 | 172 | ||
173 | acpi_new_pts_ordering [HW,ACPI] | ||
174 | Enforce the ACPI 2.0 ordering of the _PTS control | ||
175 | method wrt putting devices into low power states | ||
176 | default: pre ACPI 2.0 ordering of _PTS | ||
177 | |||
178 | acpi_no_auto_ssdt [HW,ACPI] Disable automatic loading of SSDT | 173 | acpi_no_auto_ssdt [HW,ACPI] Disable automatic loading of SSDT |
179 | 174 | ||
180 | acpi_os_name= [HW,ACPI] Tell ACPI BIOS the name of the OS | 175 | acpi_os_name= [HW,ACPI] Tell ACPI BIOS the name of the OS |
diff --git a/Documentation/networking/00-INDEX b/Documentation/networking/00-INDEX index 02e56d447a8f..c485ee028bd9 100644 --- a/Documentation/networking/00-INDEX +++ b/Documentation/networking/00-INDEX | |||
@@ -84,9 +84,6 @@ policy-routing.txt | |||
84 | - IP policy-based routing | 84 | - IP policy-based routing |
85 | ray_cs.txt | 85 | ray_cs.txt |
86 | - Raylink Wireless LAN card driver info. | 86 | - Raylink Wireless LAN card driver info. |
87 | sk98lin.txt | ||
88 | - Marvell Yukon Chipset / SysKonnect SK-98xx compliant Gigabit | ||
89 | Ethernet Adapter family driver info | ||
90 | skfp.txt | 87 | skfp.txt |
91 | - SysKonnect FDDI (SK-5xxx, Compaq Netelligent) driver info. | 88 | - SysKonnect FDDI (SK-5xxx, Compaq Netelligent) driver info. |
92 | smc9.txt | 89 | smc9.txt |
diff --git a/Documentation/networking/sk98lin.txt b/Documentation/networking/sk98lin.txt deleted file mode 100644 index 8590a954df1d..000000000000 --- a/Documentation/networking/sk98lin.txt +++ /dev/null | |||
@@ -1,568 +0,0 @@ | |||
1 | (C)Copyright 1999-2004 Marvell(R). | ||
2 | All rights reserved | ||
3 | =========================================================================== | ||
4 | |||
5 | sk98lin.txt created 13-Feb-2004 | ||
6 | |||
7 | Readme File for sk98lin v6.23 | ||
8 | Marvell Yukon/SysKonnect SK-98xx Gigabit Ethernet Adapter family driver for LINUX | ||
9 | |||
10 | This file contains | ||
11 | 1 Overview | ||
12 | 2 Required Files | ||
13 | 3 Installation | ||
14 | 3.1 Driver Installation | ||
15 | 3.2 Inclusion of adapter at system start | ||
16 | 4 Driver Parameters | ||
17 | 4.1 Per-Port Parameters | ||
18 | 4.2 Adapter Parameters | ||
19 | 5 Large Frame Support | ||
20 | 6 VLAN and Link Aggregation Support (IEEE 802.1, 802.1q, 802.3ad) | ||
21 | 7 Troubleshooting | ||
22 | |||
23 | =========================================================================== | ||
24 | |||
25 | |||
26 | 1 Overview | ||
27 | =========== | ||
28 | |||
29 | The sk98lin driver supports the Marvell Yukon and SysKonnect | ||
30 | SK-98xx/SK-95xx compliant Gigabit Ethernet Adapter on Linux. It has | ||
31 | been tested with Linux on Intel/x86 machines. | ||
32 | *** | ||
33 | |||
34 | |||
35 | 2 Required Files | ||
36 | ================= | ||
37 | |||
38 | The linux kernel source. | ||
39 | No additional files required. | ||
40 | *** | ||
41 | |||
42 | |||
43 | 3 Installation | ||
44 | =============== | ||
45 | |||
46 | It is recommended to download the latest version of the driver from the | ||
47 | SysKonnect web site www.syskonnect.com. If you have downloaded the latest | ||
48 | driver, the Linux kernel has to be patched before the driver can be | ||
49 | installed. For details on how to patch a Linux kernel, refer to the | ||
50 | patch.txt file. | ||
51 | |||
52 | 3.1 Driver Installation | ||
53 | ------------------------ | ||
54 | |||
55 | The following steps describe the actions that are required to install | ||
56 | the driver and to start it manually. These steps should be carried | ||
57 | out for the initial driver setup. Once confirmed to be ok, they can | ||
58 | be included in the system start. | ||
59 | |||
60 | NOTE 1: To perform the following tasks you need 'root' access. | ||
61 | |||
62 | NOTE 2: In case of problems, please read the section "Troubleshooting" | ||
63 | below. | ||
64 | |||
65 | The driver can either be integrated into the kernel or it can be compiled | ||
66 | as a module. Select the appropriate option during the kernel | ||
67 | configuration. | ||
68 | |||
69 | Compile/use the driver as a module | ||
70 | ---------------------------------- | ||
71 | To compile the driver, go to the directory /usr/src/linux and | ||
72 | execute the command "make menuconfig" or "make xconfig" and proceed as | ||
73 | follows: | ||
74 | |||
75 | To integrate the driver permanently into the kernel, proceed as follows: | ||
76 | |||
77 | 1. Select the menu "Network device support" and then "Ethernet(1000Mbit)" | ||
78 | 2. Mark "Marvell Yukon Chipset / SysKonnect SK-98xx family support" | ||
79 | with (*) | ||
80 | 3. Build a new kernel when the configuration of the above options is | ||
81 | finished. | ||
82 | 4. Install the new kernel. | ||
83 | 5. Reboot your system. | ||
84 | |||
85 | To use the driver as a module, proceed as follows: | ||
86 | |||
87 | 1. Enable 'loadable module support' in the kernel. | ||
88 | 2. For automatic driver start, enable the 'Kernel module loader'. | ||
89 | 3. Select the menu "Network device support" and then "Ethernet(1000Mbit)" | ||
90 | 4. Mark "Marvell Yukon Chipset / SysKonnect SK-98xx family support" | ||
91 | with (M) | ||
92 | 5. Execute the command "make modules". | ||
93 | 6. Execute the command "make modules_install". | ||
94 | The appropriate modules will be installed. | ||
95 | 7. Reboot your system. | ||
96 | |||
97 | |||
98 | Load the module manually | ||
99 | ------------------------ | ||
100 | To load the module manually, proceed as follows: | ||
101 | |||
102 | 1. Enter "modprobe sk98lin". | ||
103 | 2. If a Marvell Yukon or SysKonnect SK-98xx adapter is installed in | ||
104 | your computer and you have a /proc file system, execute the command: | ||
105 | "ls /proc/net/sk98lin/" | ||
106 | This should produce an output containing a line with the following | ||
107 | format: | ||
108 | eth0 eth1 ... | ||
109 | which indicates that your adapter has been found and initialized. | ||
110 | |||
111 | NOTE 1: If you have more than one Marvell Yukon or SysKonnect SK-98xx | ||
112 | adapter installed, the adapters will be listed as 'eth0', | ||
113 | 'eth1', 'eth2', etc. | ||
114 | For each adapter, repeat steps 3 and 4 below. | ||
115 | |||
116 | NOTE 2: If you have other Ethernet adapters installed, your Marvell | ||
117 | Yukon or SysKonnect SK-98xx adapter will be mapped to the | ||
118 | next available number, e.g. 'eth1'. The mapping is executed | ||
119 | automatically. | ||
120 | The module installation message (displayed either in a system | ||
121 | log file or on the console) prints a line for each adapter | ||
122 | found containing the corresponding 'ethX'. | ||
123 | |||
124 | 3. Select an IP address and assign it to the respective adapter by | ||
125 | entering: | ||
126 | ifconfig eth0 <ip-address> | ||
127 | With this command, the adapter is connected to the Ethernet. | ||
128 | |||
129 | SK-98xx Gigabit Ethernet Server Adapters: The yellow LED on the adapter | ||
130 | is now active, the link status LED of the primary port is active and | ||
131 | the link status LED of the secondary port (on dual port adapters) is | ||
132 | blinking (if the ports are connected to a switch or hub). | ||
133 | SK-98xx V2.0 Gigabit Ethernet Adapters: The link status LED is active. | ||
134 | In addition, you will receive a status message on the console stating | ||
135 | "ethX: network connection up using port Y" and showing the selected | ||
136 | connection parameters (x stands for the ethernet device number | ||
137 | (0,1,2, etc), y stands for the port name (A or B)). | ||
138 | |||
139 | NOTE: If you are in doubt about IP addresses, ask your network | ||
140 | administrator for assistance. | ||
141 | |||
142 | 4. Your adapter should now be fully operational. | ||
143 | Use 'ping <otherstation>' to verify the connection to other computers | ||
144 | on your network. | ||
145 | 5. To check the adapter configuration view /proc/net/sk98lin/[devicename]. | ||
146 | For example by executing: | ||
147 | "cat /proc/net/sk98lin/eth0" | ||
148 | |||
149 | Unload the module | ||
150 | ----------------- | ||
151 | To stop and unload the driver modules, proceed as follows: | ||
152 | |||
153 | 1. Execute the command "ifconfig eth0 down". | ||
154 | 2. Execute the command "rmmod sk98lin". | ||
155 | |||
156 | 3.2 Inclusion of adapter at system start | ||
157 | ----------------------------------------- | ||
158 | |||
159 | Since a large number of different Linux distributions are | ||
160 | available, we are unable to describe a general installation procedure | ||
161 | for the driver module. | ||
162 | Because the driver is now integrated in the kernel, installation should | ||
163 | be easy, using the standard mechanism of your distribution. | ||
164 | Refer to the distribution's manual for installation of ethernet adapters. | ||
165 | |||
166 | *** | ||
167 | |||
168 | 4 Driver Parameters | ||
169 | ==================== | ||
170 | |||
171 | Parameters can be set at the command line after the module has been | ||
172 | loaded with the command 'modprobe'. | ||
173 | In some distributions, the configuration tools are able to pass parameters | ||
174 | to the driver module. | ||
175 | |||
176 | If you use the kernel module loader, you can set driver parameters | ||
177 | in the file /etc/modprobe.conf (or /etc/modules.conf in 2.4 or earlier). | ||
178 | To set the driver parameters in this file, proceed as follows: | ||
179 | |||
180 | 1. Insert a line of the form : | ||
181 | options sk98lin ... | ||
182 | For "...", the same syntax is required as described for the command | ||
183 | line parameters of modprobe below. | ||
184 | 2. To activate the new parameters, either reboot your computer | ||
185 | or | ||
186 | unload and reload the driver. | ||
187 | The syntax of the driver parameters is: | ||
188 | |||
189 | modprobe sk98lin parameter=value1[,value2[,value3...]] | ||
190 | |||
191 | where value1 refers to the first adapter, value2 to the second etc. | ||
192 | |||
193 | NOTE: All parameters are case sensitive. Write them exactly as shown | ||
194 | below. | ||
195 | |||
196 | Example: | ||
197 | Suppose you have two adapters. You want to set auto-negotiation | ||
198 | on the first adapter to ON and on the second adapter to OFF. | ||
199 | You also want to set DuplexCapabilities on the first adapter | ||
200 | to FULL, and on the second adapter to HALF. | ||
201 | Then, you must enter: | ||
202 | |||
203 | modprobe sk98lin AutoNeg_A=On,Off DupCap_A=Full,Half | ||
204 | |||
205 | NOTE: The number of adapters that can be configured this way is | ||
206 | limited in the driver (file skge.c, constant SK_MAX_CARD_PARAM). | ||
207 | The current limit is 16. If you happen to install | ||
208 | more adapters, adjust this and recompile. | ||
209 | |||
210 | |||
211 | 4.1 Per-Port Parameters | ||
212 | ------------------------ | ||
213 | |||
214 | These settings are available for each port on the adapter. | ||
215 | In the following description, '?' stands for the port for | ||
216 | which you set the parameter (A or B). | ||
217 | |||
218 | Speed | ||
219 | ----- | ||
220 | Parameter: Speed_? | ||
221 | Values: 10, 100, 1000, Auto | ||
222 | Default: Auto | ||
223 | |||
224 | This parameter is used to set the speed capabilities. It is only valid | ||
225 | for the SK-98xx V2.0 copper adapters. | ||
226 | Usually, the speed is negotiated between the two ports during link | ||
227 | establishment. If this fails, a port can be forced to a specific setting | ||
228 | with this parameter. | ||
229 | |||
230 | Auto-Negotiation | ||
231 | ---------------- | ||
232 | Parameter: AutoNeg_? | ||
233 | Values: On, Off, Sense | ||
234 | Default: On | ||
235 | |||
236 | The "Sense"-mode automatically detects whether the link partner supports | ||
237 | auto-negotiation or not. | ||
238 | |||
239 | Duplex Capabilities | ||
240 | ------------------- | ||
241 | Parameter: DupCap_? | ||
242 | Values: Half, Full, Both | ||
243 | Default: Both | ||
244 | |||
245 | This parameters is only relevant if auto-negotiation for this port is | ||
246 | not set to "Sense". If auto-negotiation is set to "On", all three values | ||
247 | are possible. If it is set to "Off", only "Full" and "Half" are allowed. | ||
248 | This parameter is useful if your link partner does not support all | ||
249 | possible combinations. | ||
250 | |||
251 | Flow Control | ||
252 | ------------ | ||
253 | Parameter: FlowCtrl_? | ||
254 | Values: Sym, SymOrRem, LocSend, None | ||
255 | Default: SymOrRem | ||
256 | |||
257 | This parameter can be used to set the flow control capabilities the | ||
258 | port reports during auto-negotiation. It can be set for each port | ||
259 | individually. | ||
260 | Possible modes: | ||
261 | -- Sym = Symmetric: both link partners are allowed to send | ||
262 | PAUSE frames | ||
263 | -- SymOrRem = SymmetricOrRemote: both or only remote partner | ||
264 | are allowed to send PAUSE frames | ||
265 | -- LocSend = LocalSend: only local link partner is allowed | ||
266 | to send PAUSE frames | ||
267 | -- None = no link partner is allowed to send PAUSE frames | ||
268 | |||
269 | NOTE: This parameter is ignored if auto-negotiation is set to "Off". | ||
270 | |||
271 | Role in Master-Slave-Negotiation (1000Base-T only) | ||
272 | -------------------------------------------------- | ||
273 | Parameter: Role_? | ||
274 | Values: Auto, Master, Slave | ||
275 | Default: Auto | ||
276 | |||
277 | This parameter is only valid for the SK-9821 and SK-9822 adapters. | ||
278 | For two 1000Base-T ports to communicate, one must take the role of the | ||
279 | master (providing timing information), while the other must be the | ||
280 | slave. Usually, this is negotiated between the two ports during link | ||
281 | establishment. If this fails, a port can be forced to a specific setting | ||
282 | with this parameter. | ||
283 | |||
284 | |||
285 | 4.2 Adapter Parameters | ||
286 | ----------------------- | ||
287 | |||
288 | Connection Type (SK-98xx V2.0 copper adapters only) | ||
289 | --------------- | ||
290 | Parameter: ConType | ||
291 | Values: Auto, 100FD, 100HD, 10FD, 10HD | ||
292 | Default: Auto | ||
293 | |||
294 | The parameter 'ConType' is a combination of all five per-port parameters | ||
295 | within one single parameter. This simplifies the configuration of both ports | ||
296 | of an adapter card! The different values of this variable reflect the most | ||
297 | meaningful combinations of port parameters. | ||
298 | |||
299 | The following table shows the values of 'ConType' and the corresponding | ||
300 | combinations of the per-port parameters: | ||
301 | |||
302 | ConType | DupCap AutoNeg FlowCtrl Role Speed | ||
303 | ----------+------------------------------------------------------ | ||
304 | Auto | Both On SymOrRem Auto Auto | ||
305 | 100FD | Full Off None Auto (ignored) 100 | ||
306 | 100HD | Half Off None Auto (ignored) 100 | ||
307 | 10FD | Full Off None Auto (ignored) 10 | ||
308 | 10HD | Half Off None Auto (ignored) 10 | ||
309 | |||
310 | Stating any other port parameter together with this 'ConType' variable | ||
311 | will result in a merged configuration of those settings. This due to | ||
312 | the fact, that the per-port parameters (e.g. Speed_? ) have a higher | ||
313 | priority than the combined variable 'ConType'. | ||
314 | |||
315 | NOTE: This parameter is always used on both ports of the adapter card. | ||
316 | |||
317 | Interrupt Moderation | ||
318 | -------------------- | ||
319 | Parameter: Moderation | ||
320 | Values: None, Static, Dynamic | ||
321 | Default: None | ||
322 | |||
323 | Interrupt moderation is employed to limit the maximum number of interrupts | ||
324 | the driver has to serve. That is, one or more interrupts (which indicate any | ||
325 | transmit or receive packet to be processed) are queued until the driver | ||
326 | processes them. When queued interrupts are to be served, is determined by the | ||
327 | 'IntsPerSec' parameter, which is explained later below. | ||
328 | |||
329 | Possible modes: | ||
330 | |||
331 | -- None - No interrupt moderation is applied on the adapter card. | ||
332 | Therefore, each transmit or receive interrupt is served immediately | ||
333 | as soon as it appears on the interrupt line of the adapter card. | ||
334 | |||
335 | -- Static - Interrupt moderation is applied on the adapter card. | ||
336 | All transmit and receive interrupts are queued until a complete | ||
337 | moderation interval ends. If such a moderation interval ends, all | ||
338 | queued interrupts are processed in one big bunch without any delay. | ||
339 | The term 'static' reflects the fact, that interrupt moderation is | ||
340 | always enabled, regardless how much network load is currently | ||
341 | passing via a particular interface. In addition, the duration of | ||
342 | the moderation interval has a fixed length that never changes while | ||
343 | the driver is operational. | ||
344 | |||
345 | -- Dynamic - Interrupt moderation might be applied on the adapter card, | ||
346 | depending on the load of the system. If the driver detects that the | ||
347 | system load is too high, the driver tries to shield the system against | ||
348 | too much network load by enabling interrupt moderation. If - at a later | ||
349 | time - the CPU utilization decreases again (or if the network load is | ||
350 | negligible) the interrupt moderation will automatically be disabled. | ||
351 | |||
352 | Interrupt moderation should be used when the driver has to handle one or more | ||
353 | interfaces with a high network load, which - as a consequence - leads also to a | ||
354 | high CPU utilization. When moderation is applied in such high network load | ||
355 | situations, CPU load might be reduced by 20-30%. | ||
356 | |||
357 | NOTE: The drawback of using interrupt moderation is an increase of the round- | ||
358 | trip-time (RTT), due to the queueing and serving of interrupts at dedicated | ||
359 | moderation times. | ||
360 | |||
361 | Interrupts per second | ||
362 | --------------------- | ||
363 | Parameter: IntsPerSec | ||
364 | Values: 30...40000 (interrupts per second) | ||
365 | Default: 2000 | ||
366 | |||
367 | This parameter is only used if either static or dynamic interrupt moderation | ||
368 | is used on a network adapter card. Using this parameter if no moderation is | ||
369 | applied will lead to no action performed. | ||
370 | |||
371 | This parameter determines the length of any interrupt moderation interval. | ||
372 | Assuming that static interrupt moderation is to be used, an 'IntsPerSec' | ||
373 | parameter value of 2000 will lead to an interrupt moderation interval of | ||
374 | 500 microseconds. | ||
375 | |||
376 | NOTE: The duration of the moderation interval is to be chosen with care. | ||
377 | At first glance, selecting a very long duration (e.g. only 100 interrupts per | ||
378 | second) seems to be meaningful, but the increase of packet-processing delay | ||
379 | is tremendous. On the other hand, selecting a very short moderation time might | ||
380 | compensate the use of any moderation being applied. | ||
381 | |||
382 | |||
383 | Preferred Port | ||
384 | -------------- | ||
385 | Parameter: PrefPort | ||
386 | Values: A, B | ||
387 | Default: A | ||
388 | |||
389 | This is used to force the preferred port to A or B (on dual-port network | ||
390 | adapters). The preferred port is the one that is used if both are detected | ||
391 | as fully functional. | ||
392 | |||
393 | RLMT Mode (Redundant Link Management Technology) | ||
394 | ------------------------------------------------ | ||
395 | Parameter: RlmtMode | ||
396 | Values: CheckLinkState,CheckLocalPort, CheckSeg, DualNet | ||
397 | Default: CheckLinkState | ||
398 | |||
399 | RLMT monitors the status of the port. If the link of the active port | ||
400 | fails, RLMT switches immediately to the standby link. The virtual link is | ||
401 | maintained as long as at least one 'physical' link is up. | ||
402 | |||
403 | Possible modes: | ||
404 | |||
405 | -- CheckLinkState - Check link state only: RLMT uses the link state | ||
406 | reported by the adapter hardware for each individual port to | ||
407 | determine whether a port can be used for all network traffic or | ||
408 | not. | ||
409 | |||
410 | -- CheckLocalPort - In this mode, RLMT monitors the network path | ||
411 | between the two ports of an adapter by regularly exchanging packets | ||
412 | between them. This mode requires a network configuration in which | ||
413 | the two ports are able to "see" each other (i.e. there must not be | ||
414 | any router between the ports). | ||
415 | |||
416 | -- CheckSeg - Check local port and segmentation: This mode supports the | ||
417 | same functions as the CheckLocalPort mode and additionally checks | ||
418 | network segmentation between the ports. Therefore, this mode is only | ||
419 | to be used if Gigabit Ethernet switches are installed on the network | ||
420 | that have been configured to use the Spanning Tree protocol. | ||
421 | |||
422 | -- DualNet - In this mode, ports A and B are used as separate devices. | ||
423 | If you have a dual port adapter, port A will be configured as eth0 | ||
424 | and port B as eth1. Both ports can be used independently with | ||
425 | distinct IP addresses. The preferred port setting is not used. | ||
426 | RLMT is turned off. | ||
427 | |||
428 | NOTE: RLMT modes CLP and CLPSS are designed to operate in configurations | ||
429 | where a network path between the ports on one adapter exists. | ||
430 | Moreover, they are not designed to work where adapters are connected | ||
431 | back-to-back. | ||
432 | *** | ||
433 | |||
434 | |||
435 | 5 Large Frame Support | ||
436 | ====================== | ||
437 | |||
438 | The driver supports large frames (also called jumbo frames). Using large | ||
439 | frames can result in an improved throughput if transferring large amounts | ||
440 | of data. | ||
441 | To enable large frames, set the MTU (maximum transfer unit) of the | ||
442 | interface to the desired value (up to 9000), execute the following | ||
443 | command: | ||
444 | ifconfig eth0 mtu 9000 | ||
445 | This will only work if you have two adapters connected back-to-back | ||
446 | or if you use a switch that supports large frames. When using a switch, | ||
447 | it should be configured to allow large frames and auto-negotiation should | ||
448 | be set to OFF. The setting must be configured on all adapters that can be | ||
449 | reached by the large frames. If one adapter is not set to receive large | ||
450 | frames, it will simply drop them. | ||
451 | |||
452 | You can switch back to the standard ethernet frame size by executing the | ||
453 | following command: | ||
454 | ifconfig eth0 mtu 1500 | ||
455 | |||
456 | To permanently configure this setting, add a script with the 'ifconfig' | ||
457 | line to the system startup sequence (named something like "S99sk98lin" | ||
458 | in /etc/rc.d/rc2.d). | ||
459 | *** | ||
460 | |||
461 | |||
462 | 6 VLAN and Link Aggregation Support (IEEE 802.1, 802.1q, 802.3ad) | ||
463 | ================================================================== | ||
464 | |||
465 | The Marvell Yukon/SysKonnect Linux drivers are able to support VLAN and | ||
466 | Link Aggregation according to IEEE standards 802.1, 802.1q, and 802.3ad. | ||
467 | These features are only available after installation of open source | ||
468 | modules available on the Internet: | ||
469 | For VLAN go to: http://www.candelatech.com/~greear/vlan.html | ||
470 | For Link Aggregation go to: http://www.st.rim.or.jp/~yumo | ||
471 | |||
472 | NOTE: SysKonnect GmbH does not offer any support for these open source | ||
473 | modules and does not take the responsibility for any kind of | ||
474 | failures or problems arising in connection with these modules. | ||
475 | |||
476 | NOTE: Configuring Link Aggregation on a SysKonnect dual link adapter may | ||
477 | cause problems when unloading the driver. | ||
478 | |||
479 | |||
480 | 7 Troubleshooting | ||
481 | ================== | ||
482 | |||
483 | If any problems occur during the installation process, check the | ||
484 | following list: | ||
485 | |||
486 | |||
487 | Problem: The SK-98xx adapter cannot be found by the driver. | ||
488 | Solution: In /proc/pci search for the following entry: | ||
489 | 'Ethernet controller: SysKonnect SK-98xx ...' | ||
490 | If this entry exists, the SK-98xx or SK-98xx V2.0 adapter has | ||
491 | been found by the system and should be operational. | ||
492 | If this entry does not exist or if the file '/proc/pci' is not | ||
493 | found, there may be a hardware problem or the PCI support may | ||
494 | not be enabled in your kernel. | ||
495 | The adapter can be checked using the diagnostics program which | ||
496 | is available on the SysKonnect web site: | ||
497 | www.syskonnect.com | ||
498 | |||
499 | Some COMPAQ machines have problems dealing with PCI under Linux. | ||
500 | This problem is described in the 'PCI howto' document | ||
501 | (included in some distributions or available from the | ||
502 | web, e.g. at 'www.linux.org'). | ||
503 | |||
504 | |||
505 | Problem: Programs such as 'ifconfig' or 'route' cannot be found or the | ||
506 | error message 'Operation not permitted' is displayed. | ||
507 | Reason: You are not logged in as user 'root'. | ||
508 | Solution: Logout and login as 'root' or change to 'root' via 'su'. | ||
509 | |||
510 | |||
511 | Problem: Upon use of the command 'ping <address>' the message | ||
512 | "ping: sendto: Network is unreachable" is displayed. | ||
513 | Reason: Your route is not set correctly. | ||
514 | Solution: If you are using RedHat, you probably forgot to set up the | ||
515 | route in the 'network configuration'. | ||
516 | Check the existing routes with the 'route' command and check | ||
517 | if an entry for 'eth0' exists, and if so, if it is set correctly. | ||
518 | |||
519 | |||
520 | Problem: The driver can be started, the adapter is connected to the | ||
521 | network, but you cannot receive or transmit any packets; | ||
522 | e.g. 'ping' does not work. | ||
523 | Reason: There is an incorrect route in your routing table. | ||
524 | Solution: Check the routing table with the command 'route' and read the | ||
525 | manual help pages dealing with routes (enter 'man route'). | ||
526 | |||
527 | NOTE: Although the 2.2.x kernel versions generate the routing entry | ||
528 | automatically, problems of this kind may occur here as well. We've | ||
529 | come across a situation in which the driver started correctly at | ||
530 | system start, but after the driver has been removed and reloaded, | ||
531 | the route of the adapter's network pointed to the 'dummy0'device | ||
532 | and had to be corrected manually. | ||
533 | |||
534 | |||
535 | Problem: Your computer should act as a router between multiple | ||
536 | IP subnetworks (using multiple adapters), but computers in | ||
537 | other subnetworks cannot be reached. | ||
538 | Reason: Either the router's kernel is not configured for IP forwarding | ||
539 | or the routing table and gateway configuration of at least one | ||
540 | computer is not working. | ||
541 | |||
542 | Problem: Upon driver start, the following error message is displayed: | ||
543 | "eth0: -- ERROR -- | ||
544 | Class: internal Software error | ||
545 | Nr: 0xcc | ||
546 | Msg: SkGeInitPort() cannot init running ports" | ||
547 | Reason: You are using a driver compiled for single processor machines | ||
548 | on a multiprocessor machine with SMP (Symmetric MultiProcessor) | ||
549 | kernel. | ||
550 | Solution: Configure your kernel appropriately and recompile the kernel or | ||
551 | the modules. | ||
552 | |||
553 | |||
554 | |||
555 | If your problem is not listed here, please contact SysKonnect's technical | ||
556 | support for help (linux@syskonnect.de). | ||
557 | When contacting our technical support, please ensure that the following | ||
558 | information is available: | ||
559 | - System Manufacturer and HW Informations (CPU, Memory... ) | ||
560 | - PCI-Boards in your system | ||
561 | - Distribution | ||
562 | - Kernel version | ||
563 | - Driver version | ||
564 | *** | ||
565 | |||
566 | |||
567 | |||
568 | ***End of Readme File*** | ||
diff --git a/Documentation/unaligned-memory-access.txt b/Documentation/unaligned-memory-access.txt index 6223eace3c09..b0472ac5226a 100644 --- a/Documentation/unaligned-memory-access.txt +++ b/Documentation/unaligned-memory-access.txt | |||
@@ -57,7 +57,7 @@ here; a summary of the common scenarios is presented below: | |||
57 | unaligned access to be corrected. | 57 | unaligned access to be corrected. |
58 | - Some architectures are not capable of unaligned memory access, but will | 58 | - Some architectures are not capable of unaligned memory access, but will |
59 | silently perform a different memory access to the one that was requested, | 59 | silently perform a different memory access to the one that was requested, |
60 | resulting a a subtle code bug that is hard to detect! | 60 | resulting in a subtle code bug that is hard to detect! |
61 | 61 | ||
62 | It should be obvious from the above that if your code causes unaligned | 62 | It should be obvious from the above that if your code causes unaligned |
63 | memory accesses to happen, your code will not work correctly on certain | 63 | memory accesses to happen, your code will not work correctly on certain |
@@ -209,7 +209,7 @@ memory and you wish to avoid unaligned access, its usage is as follows: | |||
209 | 209 | ||
210 | u32 value = get_unaligned((u32 *) data); | 210 | u32 value = get_unaligned((u32 *) data); |
211 | 211 | ||
212 | These macros work work for memory accesses of any length (not just 32 bits as | 212 | These macros work for memory accesses of any length (not just 32 bits as |
213 | in the examples above). Be aware that when compared to standard access of | 213 | in the examples above). Be aware that when compared to standard access of |
214 | aligned memory, using these macros to access unaligned memory can be costly in | 214 | aligned memory, using these macros to access unaligned memory can be costly in |
215 | terms of performance. | 215 | terms of performance. |
@@ -1,7 +1,7 @@ | |||
1 | VERSION = 2 | 1 | VERSION = 2 |
2 | PATCHLEVEL = 6 | 2 | PATCHLEVEL = 6 |
3 | SUBLEVEL = 25 | 3 | SUBLEVEL = 25 |
4 | EXTRAVERSION = -rc7 | 4 | EXTRAVERSION = -rc8 |
5 | NAME = Funky Weasel is Jiggy wit it | 5 | NAME = Funky Weasel is Jiggy wit it |
6 | 6 | ||
7 | # *DOCUMENTATION* | 7 | # *DOCUMENTATION* |
diff --git a/arch/alpha/kernel/pci_iommu.c b/arch/alpha/kernel/pci_iommu.c index 4e1c08636edd..dd6e334ab9e1 100644 --- a/arch/alpha/kernel/pci_iommu.c +++ b/arch/alpha/kernel/pci_iommu.c | |||
@@ -424,11 +424,13 @@ EXPORT_SYMBOL(pci_unmap_page); | |||
424 | else DMA_ADDRP is undefined. */ | 424 | else DMA_ADDRP is undefined. */ |
425 | 425 | ||
426 | void * | 426 | void * |
427 | pci_alloc_consistent(struct pci_dev *pdev, size_t size, dma_addr_t *dma_addrp) | 427 | __pci_alloc_consistent(struct pci_dev *pdev, size_t size, |
428 | dma_addr_t *dma_addrp, gfp_t gfp) | ||
428 | { | 429 | { |
429 | void *cpu_addr; | 430 | void *cpu_addr; |
430 | long order = get_order(size); | 431 | long order = get_order(size); |
431 | gfp_t gfp = GFP_ATOMIC; | 432 | |
433 | gfp &= ~GFP_DMA; | ||
432 | 434 | ||
433 | try_again: | 435 | try_again: |
434 | cpu_addr = (void *)__get_free_pages(gfp, order); | 436 | cpu_addr = (void *)__get_free_pages(gfp, order); |
@@ -458,7 +460,7 @@ try_again: | |||
458 | 460 | ||
459 | return cpu_addr; | 461 | return cpu_addr; |
460 | } | 462 | } |
461 | EXPORT_SYMBOL(pci_alloc_consistent); | 463 | EXPORT_SYMBOL(__pci_alloc_consistent); |
462 | 464 | ||
463 | /* Free and unmap a consistent DMA buffer. CPU_ADDR and DMA_ADDR must | 465 | /* Free and unmap a consistent DMA buffer. CPU_ADDR and DMA_ADDR must |
464 | be values that were returned from pci_alloc_consistent. SIZE must | 466 | be values that were returned from pci_alloc_consistent. SIZE must |
diff --git a/arch/arm/common/it8152.c b/arch/arm/common/it8152.c index 538262241483..5fe9588db077 100644 --- a/arch/arm/common/it8152.c +++ b/arch/arm/common/it8152.c | |||
@@ -120,6 +120,7 @@ void it8152_irq_demux(unsigned int irq, struct irq_desc *desc) | |||
120 | time, when they all three were 0. */ | 120 | time, when they all three were 0. */ |
121 | bits_pd = __raw_readl(IT8152_INTC_PDCNIRR); | 121 | bits_pd = __raw_readl(IT8152_INTC_PDCNIRR); |
122 | bits_lp = __raw_readl(IT8152_INTC_LPCNIRR); | 122 | bits_lp = __raw_readl(IT8152_INTC_LPCNIRR); |
123 | bits_ld = __raw_readl(IT8152_INTC_LDCNIRR); | ||
123 | if (!(bits_ld | bits_lp | bits_pd)) | 124 | if (!(bits_ld | bits_lp | bits_pd)) |
124 | return; | 125 | return; |
125 | } | 126 | } |
@@ -133,14 +134,14 @@ void it8152_irq_demux(unsigned int irq, struct irq_desc *desc) | |||
133 | 134 | ||
134 | bits_lp &= ((1 << IT8152_LP_IRQ_COUNT) - 1); | 135 | bits_lp &= ((1 << IT8152_LP_IRQ_COUNT) - 1); |
135 | while (bits_lp) { | 136 | while (bits_lp) { |
136 | i = __ffs(bits_pd); | 137 | i = __ffs(bits_lp); |
137 | it8152_irq(IT8152_LP_IRQ(i)); | 138 | it8152_irq(IT8152_LP_IRQ(i)); |
138 | bits_lp &= ~(1 << i); | 139 | bits_lp &= ~(1 << i); |
139 | } | 140 | } |
140 | 141 | ||
141 | bits_ld &= ((1 << IT8152_LD_IRQ_COUNT) - 1); | 142 | bits_ld &= ((1 << IT8152_LD_IRQ_COUNT) - 1); |
142 | while (bits_ld) { | 143 | while (bits_ld) { |
143 | i = __ffs(bits_pd); | 144 | i = __ffs(bits_ld); |
144 | it8152_irq(IT8152_LD_IRQ(i)); | 145 | it8152_irq(IT8152_LD_IRQ(i)); |
145 | bits_ld &= ~(1 << i); | 146 | bits_ld &= ~(1 << i); |
146 | } | 147 | } |
diff --git a/arch/arm/kernel/calls.S b/arch/arm/kernel/calls.S index 283e14fff993..7e97b7376563 100644 --- a/arch/arm/kernel/calls.S +++ b/arch/arm/kernel/calls.S | |||
@@ -336,7 +336,7 @@ | |||
336 | CALL(sys_mknodat) | 336 | CALL(sys_mknodat) |
337 | /* 325 */ CALL(sys_fchownat) | 337 | /* 325 */ CALL(sys_fchownat) |
338 | CALL(sys_futimesat) | 338 | CALL(sys_futimesat) |
339 | CALL(sys_fstatat64) | 339 | CALL(ABI(sys_fstatat64, sys_oabi_fstatat64)) |
340 | CALL(sys_unlinkat) | 340 | CALL(sys_unlinkat) |
341 | CALL(sys_renameat) | 341 | CALL(sys_renameat) |
342 | /* 330 */ CALL(sys_linkat) | 342 | /* 330 */ CALL(sys_linkat) |
diff --git a/arch/arm/kernel/sys_oabi-compat.c b/arch/arm/kernel/sys_oabi-compat.c index e8b98046895b..96ab5f52949c 100644 --- a/arch/arm/kernel/sys_oabi-compat.c +++ b/arch/arm/kernel/sys_oabi-compat.c | |||
@@ -25,6 +25,7 @@ | |||
25 | * sys_stat64: | 25 | * sys_stat64: |
26 | * sys_lstat64: | 26 | * sys_lstat64: |
27 | * sys_fstat64: | 27 | * sys_fstat64: |
28 | * sys_fstatat64: | ||
28 | * | 29 | * |
29 | * struct stat64 has different sizes and some members are shifted | 30 | * struct stat64 has different sizes and some members are shifted |
30 | * Compatibility wrappers are needed for them and provided below. | 31 | * Compatibility wrappers are needed for them and provided below. |
@@ -169,6 +170,29 @@ asmlinkage long sys_oabi_fstat64(unsigned long fd, | |||
169 | return error; | 170 | return error; |
170 | } | 171 | } |
171 | 172 | ||
173 | asmlinkage long sys_oabi_fstatat64(int dfd, | ||
174 | char __user *filename, | ||
175 | struct oldabi_stat64 __user *statbuf, | ||
176 | int flag) | ||
177 | { | ||
178 | struct kstat stat; | ||
179 | int error = -EINVAL; | ||
180 | |||
181 | if ((flag & ~AT_SYMLINK_NOFOLLOW) != 0) | ||
182 | goto out; | ||
183 | |||
184 | if (flag & AT_SYMLINK_NOFOLLOW) | ||
185 | error = vfs_lstat_fd(dfd, filename, &stat); | ||
186 | else | ||
187 | error = vfs_stat_fd(dfd, filename, &stat); | ||
188 | |||
189 | if (!error) | ||
190 | error = cp_oldabi_stat64(&stat, statbuf); | ||
191 | |||
192 | out: | ||
193 | return error; | ||
194 | } | ||
195 | |||
172 | struct oabi_flock64 { | 196 | struct oabi_flock64 { |
173 | short l_type; | 197 | short l_type; |
174 | short l_whence; | 198 | short l_whence; |
diff --git a/arch/mips/Makefile b/arch/mips/Makefile index 72097dacabd3..1c62381f5c23 100644 --- a/arch/mips/Makefile +++ b/arch/mips/Makefile | |||
@@ -482,10 +482,13 @@ endif | |||
482 | # be 16kb aligned or the handling of the current variable will break. | 482 | # be 16kb aligned or the handling of the current variable will break. |
483 | # Simplified: what IP22 does at 128MB+ in ksegN, IP28 does at 512MB+ in xkphys | 483 | # Simplified: what IP22 does at 128MB+ in ksegN, IP28 does at 512MB+ in xkphys |
484 | # | 484 | # |
485 | #core-$(CONFIG_SGI_IP28) += arch/mips/sgi-ip22/ arch/mips/arc/arc_con.o | 485 | ifdef CONFIG_SGI_IP28 |
486 | ifeq ($(call cc-option-yn,-mr10k-cache-barrier=1), n) | ||
487 | $(error gcc doesn't support needed option -mr10k-cache-barrier=1) | ||
488 | endif | ||
489 | endif | ||
486 | core-$(CONFIG_SGI_IP28) += arch/mips/sgi-ip22/ | 490 | core-$(CONFIG_SGI_IP28) += arch/mips/sgi-ip22/ |
487 | cflags-$(CONFIG_SGI_IP28) += -mr10k-cache-barrier=1 -Iinclude/asm-mips/mach-ip28 | 491 | cflags-$(CONFIG_SGI_IP28) += -mr10k-cache-barrier=1 -Iinclude/asm-mips/mach-ip28 |
488 | #cflags-$(CONFIG_SGI_IP28) += -Iinclude/asm-mips/mach-ip28 | ||
489 | load-$(CONFIG_SGI_IP28) += 0xa800000020004000 | 492 | load-$(CONFIG_SGI_IP28) += 0xa800000020004000 |
490 | 493 | ||
491 | # | 494 | # |
diff --git a/arch/mips/au1000/common/cputable.c b/arch/mips/au1000/common/cputable.c index d8df5fdb045f..5c0d35d6e22a 100644 --- a/arch/mips/au1000/common/cputable.c +++ b/arch/mips/au1000/common/cputable.c | |||
@@ -22,24 +22,24 @@ struct cpu_spec* cur_cpu_spec[NR_CPUS]; | |||
22 | /* With some thought, we can probably use the mask to reduce the | 22 | /* With some thought, we can probably use the mask to reduce the |
23 | * size of the table. | 23 | * size of the table. |
24 | */ | 24 | */ |
25 | struct cpu_spec cpu_specs[] = { | 25 | struct cpu_spec cpu_specs[] = { |
26 | { 0xffffffff, 0x00030100, "Au1000 DA", 1, 0 }, | 26 | { 0xffffffff, 0x00030100, "Au1000 DA", 1, 0, 1 }, |
27 | { 0xffffffff, 0x00030201, "Au1000 HA", 1, 0 }, | 27 | { 0xffffffff, 0x00030201, "Au1000 HA", 1, 0, 1 }, |
28 | { 0xffffffff, 0x00030202, "Au1000 HB", 1, 0 }, | 28 | { 0xffffffff, 0x00030202, "Au1000 HB", 1, 0, 1 }, |
29 | { 0xffffffff, 0x00030203, "Au1000 HC", 1, 1 }, | 29 | { 0xffffffff, 0x00030203, "Au1000 HC", 1, 1, 0 }, |
30 | { 0xffffffff, 0x00030204, "Au1000 HD", 1, 1 }, | 30 | { 0xffffffff, 0x00030204, "Au1000 HD", 1, 1, 0 }, |
31 | { 0xffffffff, 0x01030200, "Au1500 AB", 1, 1 }, | 31 | { 0xffffffff, 0x01030200, "Au1500 AB", 1, 1, 0 }, |
32 | { 0xffffffff, 0x01030201, "Au1500 AC", 0, 1 }, | 32 | { 0xffffffff, 0x01030201, "Au1500 AC", 0, 1, 0 }, |
33 | { 0xffffffff, 0x01030202, "Au1500 AD", 0, 1 }, | 33 | { 0xffffffff, 0x01030202, "Au1500 AD", 0, 1, 0 }, |
34 | { 0xffffffff, 0x02030200, "Au1100 AB", 1, 1 }, | 34 | { 0xffffffff, 0x02030200, "Au1100 AB", 1, 1, 0 }, |
35 | { 0xffffffff, 0x02030201, "Au1100 BA", 1, 1 }, | 35 | { 0xffffffff, 0x02030201, "Au1100 BA", 1, 1, 0 }, |
36 | { 0xffffffff, 0x02030202, "Au1100 BC", 1, 1 }, | 36 | { 0xffffffff, 0x02030202, "Au1100 BC", 1, 1, 0 }, |
37 | { 0xffffffff, 0x02030203, "Au1100 BD", 0, 1 }, | 37 | { 0xffffffff, 0x02030203, "Au1100 BD", 0, 1, 0 }, |
38 | { 0xffffffff, 0x02030204, "Au1100 BE", 0, 1 }, | 38 | { 0xffffffff, 0x02030204, "Au1100 BE", 0, 1, 0 }, |
39 | { 0xffffffff, 0x03030200, "Au1550 AA", 0, 1 }, | 39 | { 0xffffffff, 0x03030200, "Au1550 AA", 0, 1, 0 }, |
40 | { 0xffffffff, 0x04030200, "Au1200 AB", 0, 0 }, | 40 | { 0xffffffff, 0x04030200, "Au1200 AB", 0, 0, 0 }, |
41 | { 0xffffffff, 0x04030201, "Au1200 AC", 1, 0 }, | 41 | { 0xffffffff, 0x04030201, "Au1200 AC", 1, 0, 0 }, |
42 | { 0x00000000, 0x00000000, "Unknown Au1xxx", 1, 0 }, | 42 | { 0x00000000, 0x00000000, "Unknown Au1xxx", 1, 0, 0 } |
43 | }; | 43 | }; |
44 | 44 | ||
45 | void | 45 | void |
diff --git a/arch/mips/au1000/common/setup.c b/arch/mips/au1000/common/setup.c index d885e3848ec6..9e4ab80caab6 100644 --- a/arch/mips/au1000/common/setup.c +++ b/arch/mips/au1000/common/setup.c | |||
@@ -57,7 +57,7 @@ void __init plat_mem_setup(void) | |||
57 | { | 57 | { |
58 | struct cpu_spec *sp; | 58 | struct cpu_spec *sp; |
59 | char *argptr; | 59 | char *argptr; |
60 | unsigned long prid, cpupll, bclk = 1; | 60 | unsigned long prid, cpufreq, bclk = 1; |
61 | 61 | ||
62 | set_cpuspec(); | 62 | set_cpuspec(); |
63 | sp = cur_cpu_spec[0]; | 63 | sp = cur_cpu_spec[0]; |
@@ -65,8 +65,15 @@ void __init plat_mem_setup(void) | |||
65 | board_setup(); /* board specific setup */ | 65 | board_setup(); /* board specific setup */ |
66 | 66 | ||
67 | prid = read_c0_prid(); | 67 | prid = read_c0_prid(); |
68 | cpupll = (au_readl(0xB1900060) & 0x3F) * 12; | 68 | if (sp->cpu_pll_wo) |
69 | printk("(PRId %08lx) @ %ldMHZ\n", prid, cpupll); | 69 | #ifdef CONFIG_SOC_AU1000_FREQUENCY |
70 | cpufreq = CONFIG_SOC_AU1000_FREQUENCY / 1000000; | ||
71 | #else | ||
72 | cpufreq = 396; | ||
73 | #endif | ||
74 | else | ||
75 | cpufreq = (au_readl(SYS_CPUPLL) & 0x3F) * 12; | ||
76 | printk(KERN_INFO "(PRID %08lx) @ %ld MHz\n", prid, cpufreq); | ||
70 | 77 | ||
71 | bclk = sp->cpu_bclk; | 78 | bclk = sp->cpu_bclk; |
72 | if (bclk) | 79 | if (bclk) |
diff --git a/arch/mips/au1000/common/time.c b/arch/mips/au1000/common/time.c index f113b512d7b1..e122bbc6cd88 100644 --- a/arch/mips/au1000/common/time.c +++ b/arch/mips/au1000/common/time.c | |||
@@ -209,18 +209,22 @@ unsigned long cal_r4koff(void) | |||
209 | while (au_readl(SYS_COUNTER_CNTRL) & SYS_CNTRL_C1S); | 209 | while (au_readl(SYS_COUNTER_CNTRL) & SYS_CNTRL_C1S); |
210 | au_writel(0, SYS_TOYWRITE); | 210 | au_writel(0, SYS_TOYWRITE); |
211 | while (au_readl(SYS_COUNTER_CNTRL) & SYS_CNTRL_C1S); | 211 | while (au_readl(SYS_COUNTER_CNTRL) & SYS_CNTRL_C1S); |
212 | } else | ||
213 | no_au1xxx_32khz = 1; | ||
212 | 214 | ||
213 | cpu_speed = (au_readl(SYS_CPUPLL) & 0x0000003f) * | 215 | /* |
214 | AU1000_SRC_CLK; | 216 | * On early Au1000, sys_cpupll was write-only. Since these |
215 | } | 217 | * silicon versions of Au1000 are not sold by AMD, we don't bend |
216 | else { | 218 | * over backwards trying to determine the frequency. |
217 | /* The 32KHz oscillator isn't running, so assume there | 219 | */ |
218 | * isn't one and grab the processor speed from the PLL. | 220 | if (cur_cpu_spec[0]->cpu_pll_wo) |
219 | * NOTE: some old silicon doesn't allow reading the PLL. | 221 | #ifdef CONFIG_SOC_AU1000_FREQUENCY |
220 | */ | 222 | cpu_speed = CONFIG_SOC_AU1000_FREQUENCY; |
223 | #else | ||
224 | cpu_speed = 396000000; | ||
225 | #endif | ||
226 | else | ||
221 | cpu_speed = (au_readl(SYS_CPUPLL) & 0x0000003f) * AU1000_SRC_CLK; | 227 | cpu_speed = (au_readl(SYS_CPUPLL) & 0x0000003f) * AU1000_SRC_CLK; |
222 | no_au1xxx_32khz = 1; | ||
223 | } | ||
224 | mips_hpt_frequency = cpu_speed; | 228 | mips_hpt_frequency = cpu_speed; |
225 | // Equation: Baudrate = CPU / (SD * 2 * CLKDIV * 16) | 229 | // Equation: Baudrate = CPU / (SD * 2 * CLKDIV * 16) |
226 | set_au1x00_uart_baud_base(cpu_speed / (2 * ((int)(au_readl(SYS_POWERCTRL)&0x03) + 2) * 16)); | 230 | set_au1x00_uart_baud_base(cpu_speed / (2 * ((int)(au_readl(SYS_POWERCTRL)&0x03) + 2) * 16)); |
diff --git a/arch/mips/au1000/xxs1500/board_setup.c b/arch/mips/au1000/xxs1500/board_setup.c index a9237f41933d..b2e413e597a8 100644 --- a/arch/mips/au1000/xxs1500/board_setup.c +++ b/arch/mips/au1000/xxs1500/board_setup.c | |||
@@ -33,11 +33,10 @@ | |||
33 | #include <asm/cpu.h> | 33 | #include <asm/cpu.h> |
34 | #include <asm/bootinfo.h> | 34 | #include <asm/bootinfo.h> |
35 | #include <asm/irq.h> | 35 | #include <asm/irq.h> |
36 | #include <asm/keyboard.h> | ||
37 | #include <asm/mipsregs.h> | 36 | #include <asm/mipsregs.h> |
38 | #include <asm/reboot.h> | 37 | #include <asm/reboot.h> |
39 | #include <asm/pgtable.h> | 38 | #include <asm/pgtable.h> |
40 | #include <asm/au1000.h> | 39 | #include <asm/mach-au1x00/au1000.h> |
41 | 40 | ||
42 | void board_reset(void) | 41 | void board_reset(void) |
43 | { | 42 | { |
diff --git a/arch/mips/au1000/xxs1500/irqmap.c b/arch/mips/au1000/xxs1500/irqmap.c index 389349295d70..a343da134334 100644 --- a/arch/mips/au1000/xxs1500/irqmap.c +++ b/arch/mips/au1000/xxs1500/irqmap.c | |||
@@ -45,7 +45,7 @@ | |||
45 | #include <asm/io.h> | 45 | #include <asm/io.h> |
46 | #include <asm/mipsregs.h> | 46 | #include <asm/mipsregs.h> |
47 | #include <asm/system.h> | 47 | #include <asm/system.h> |
48 | #include <asm/au1000.h> | 48 | #include <asm/mach-au1x00/au1000.h> |
49 | 49 | ||
50 | struct au1xxx_irqmap __initdata au1xxx_irq_map[] = { | 50 | struct au1xxx_irqmap __initdata au1xxx_irq_map[] = { |
51 | { AU1500_GPIO_204, INTC_INT_HIGH_LEVEL, 0}, | 51 | { AU1500_GPIO_204, INTC_INT_HIGH_LEVEL, 0}, |
diff --git a/arch/mips/configs/bigsur_defconfig b/arch/mips/configs/bigsur_defconfig index abf70d74e9d7..3b42cea2e402 100644 --- a/arch/mips/configs/bigsur_defconfig +++ b/arch/mips/configs/bigsur_defconfig | |||
@@ -1,58 +1,48 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.20 | 3 | # Linux kernel version: 2.6.25-rc7 |
4 | # Tue Feb 20 21:47:22 2007 | 4 | # Mon Mar 31 08:11:19 2008 |
5 | # | 5 | # |
6 | CONFIG_MIPS=y | 6 | CONFIG_MIPS=y |
7 | 7 | ||
8 | # | 8 | # |
9 | # Machine selection | 9 | # Machine selection |
10 | # | 10 | # |
11 | CONFIG_ZONE_DMA=y | 11 | # CONFIG_MACH_ALCHEMY is not set |
12 | # CONFIG_MIPS_MTX1 is not set | ||
13 | # CONFIG_MIPS_BOSPORUS is not set | ||
14 | # CONFIG_MIPS_PB1000 is not set | ||
15 | # CONFIG_MIPS_PB1100 is not set | ||
16 | # CONFIG_MIPS_PB1500 is not set | ||
17 | # CONFIG_MIPS_PB1550 is not set | ||
18 | # CONFIG_MIPS_PB1200 is not set | ||
19 | # CONFIG_MIPS_DB1000 is not set | ||
20 | # CONFIG_MIPS_DB1100 is not set | ||
21 | # CONFIG_MIPS_DB1500 is not set | ||
22 | # CONFIG_MIPS_DB1550 is not set | ||
23 | # CONFIG_MIPS_DB1200 is not set | ||
24 | # CONFIG_MIPS_MIRAGE is not set | ||
25 | # CONFIG_BASLER_EXCITE is not set | 12 | # CONFIG_BASLER_EXCITE is not set |
13 | # CONFIG_BCM47XX is not set | ||
26 | # CONFIG_MIPS_COBALT is not set | 14 | # CONFIG_MIPS_COBALT is not set |
27 | # CONFIG_MACH_DECSTATION is not set | 15 | # CONFIG_MACH_DECSTATION is not set |
28 | # CONFIG_MACH_JAZZ is not set | 16 | # CONFIG_MACH_JAZZ is not set |
17 | # CONFIG_LASAT is not set | ||
18 | # CONFIG_LEMOTE_FULONG is not set | ||
29 | # CONFIG_MIPS_ATLAS is not set | 19 | # CONFIG_MIPS_ATLAS is not set |
30 | # CONFIG_MIPS_MALTA is not set | 20 | # CONFIG_MIPS_MALTA is not set |
31 | # CONFIG_MIPS_SEAD is not set | 21 | # CONFIG_MIPS_SEAD is not set |
32 | # CONFIG_WR_PPMC is not set | ||
33 | # CONFIG_MIPS_SIM is not set | 22 | # CONFIG_MIPS_SIM is not set |
34 | # CONFIG_MOMENCO_JAGUAR_ATX is not set | 23 | # CONFIG_MARKEINS is not set |
35 | # CONFIG_MIPS_XXS1500 is not set | 24 | # CONFIG_MACH_VR41XX is not set |
36 | # CONFIG_PNX8550_JBS is not set | 25 | # CONFIG_PNX8550_JBS is not set |
37 | # CONFIG_PNX8550_STB810 is not set | 26 | # CONFIG_PNX8550_STB810 is not set |
38 | # CONFIG_MACH_VR41XX is not set | 27 | # CONFIG_PMC_MSP is not set |
39 | # CONFIG_PMC_YOSEMITE is not set | 28 | # CONFIG_PMC_YOSEMITE is not set |
40 | # CONFIG_MARKEINS is not set | ||
41 | # CONFIG_SGI_IP22 is not set | 29 | # CONFIG_SGI_IP22 is not set |
42 | # CONFIG_SGI_IP27 is not set | 30 | # CONFIG_SGI_IP27 is not set |
31 | # CONFIG_SGI_IP28 is not set | ||
43 | # CONFIG_SGI_IP32 is not set | 32 | # CONFIG_SGI_IP32 is not set |
44 | CONFIG_SIBYTE_BIGSUR=y | ||
45 | # CONFIG_SIBYTE_SWARM is not set | ||
46 | # CONFIG_SIBYTE_SENTOSA is not set | ||
47 | # CONFIG_SIBYTE_RHONE is not set | ||
48 | # CONFIG_SIBYTE_CARMEL is not set | ||
49 | # CONFIG_SIBYTE_LITTLESUR is not set | ||
50 | # CONFIG_SIBYTE_CRHINE is not set | 33 | # CONFIG_SIBYTE_CRHINE is not set |
34 | # CONFIG_SIBYTE_CARMEL is not set | ||
51 | # CONFIG_SIBYTE_CRHONE 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=y | ||
52 | # CONFIG_SNI_RM is not set | 41 | # CONFIG_SNI_RM is not set |
53 | # CONFIG_TOSHIBA_JMR3927 is not set | 42 | # CONFIG_TOSHIBA_JMR3927 is not set |
54 | # CONFIG_TOSHIBA_RBTX4927 is not set | 43 | # CONFIG_TOSHIBA_RBTX4927 is not set |
55 | # CONFIG_TOSHIBA_RBTX4938 is not set | 44 | # CONFIG_TOSHIBA_RBTX4938 is not set |
45 | # CONFIG_WR_PPMC is not set | ||
56 | CONFIG_SIBYTE_BCM1x80=y | 46 | CONFIG_SIBYTE_BCM1x80=y |
57 | CONFIG_SIBYTE_SB1xxx_SOC=y | 47 | CONFIG_SIBYTE_SB1xxx_SOC=y |
58 | # CONFIG_CPU_SB1_PASS_1 is not set | 48 | # CONFIG_CPU_SB1_PASS_1 is not set |
@@ -68,9 +58,11 @@ CONFIG_SIBYTE_CFE=y | |||
68 | # CONFIG_SIBYTE_CFE_CONSOLE is not set | 58 | # CONFIG_SIBYTE_CFE_CONSOLE is not set |
69 | # CONFIG_SIBYTE_BUS_WATCHER is not set | 59 | # CONFIG_SIBYTE_BUS_WATCHER is not set |
70 | # CONFIG_SIBYTE_TBPROF is not set | 60 | # CONFIG_SIBYTE_TBPROF is not set |
61 | CONFIG_SIBYTE_HAS_ZBUS_PROFILING=y | ||
71 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | 62 | CONFIG_RWSEM_GENERIC_SPINLOCK=y |
72 | # CONFIG_ARCH_HAS_ILOG2_U32 is not set | 63 | # CONFIG_ARCH_HAS_ILOG2_U32 is not set |
73 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set | 64 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set |
65 | CONFIG_ARCH_SUPPORTS_OPROFILE=y | ||
74 | CONFIG_GENERIC_FIND_NEXT_BIT=y | 66 | CONFIG_GENERIC_FIND_NEXT_BIT=y |
75 | CONFIG_GENERIC_HWEIGHT=y | 67 | CONFIG_GENERIC_HWEIGHT=y |
76 | CONFIG_GENERIC_CALIBRATE_DELAY=y | 68 | CONFIG_GENERIC_CALIBRATE_DELAY=y |
@@ -81,11 +73,17 @@ CONFIG_SCHED_NO_NO_OMIT_FRAME_POINTER=y | |||
81 | # CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ is not set | 73 | # CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ is not set |
82 | CONFIG_CEVT_BCM1480=y | 74 | CONFIG_CEVT_BCM1480=y |
83 | CONFIG_CSRC_BCM1480=y | 75 | CONFIG_CSRC_BCM1480=y |
76 | CONFIG_CFE=y | ||
84 | CONFIG_DMA_COHERENT=y | 77 | CONFIG_DMA_COHERENT=y |
78 | CONFIG_EARLY_PRINTK=y | ||
79 | CONFIG_SYS_HAS_EARLY_PRINTK=y | ||
80 | # CONFIG_HOTPLUG_CPU is not set | ||
81 | # CONFIG_NO_IOPORT is not set | ||
85 | CONFIG_CPU_BIG_ENDIAN=y | 82 | CONFIG_CPU_BIG_ENDIAN=y |
86 | # CONFIG_CPU_LITTLE_ENDIAN is not set | 83 | # CONFIG_CPU_LITTLE_ENDIAN is not set |
87 | CONFIG_SYS_SUPPORTS_BIG_ENDIAN=y | 84 | CONFIG_SYS_SUPPORTS_BIG_ENDIAN=y |
88 | CONFIG_SYS_SUPPORTS_LITTLE_ENDIAN=y | 85 | CONFIG_SYS_SUPPORTS_LITTLE_ENDIAN=y |
86 | CONFIG_IRQ_CPU=y | ||
89 | CONFIG_SWAP_IO_SPACE=y | 87 | CONFIG_SWAP_IO_SPACE=y |
90 | CONFIG_BOOT_ELF32=y | 88 | CONFIG_BOOT_ELF32=y |
91 | CONFIG_MIPS_L1_CACHE_SHIFT=5 | 89 | CONFIG_MIPS_L1_CACHE_SHIFT=5 |
@@ -93,10 +91,6 @@ CONFIG_MIPS_L1_CACHE_SHIFT=5 | |||
93 | # | 91 | # |
94 | # CPU selection | 92 | # CPU selection |
95 | # | 93 | # |
96 | CONFIG_TICK_ONESHOT=y | ||
97 | CONFIG_NO_HZ=y | ||
98 | CONFIG_HIGH_RES_TIMERS=y | ||
99 | CONFIG_GENERIC_CLOCKEVENTS_BUILD=y | ||
100 | # CONFIG_CPU_LOONGSON2 is not set | 94 | # CONFIG_CPU_LOONGSON2 is not set |
101 | # CONFIG_CPU_MIPS32_R1 is not set | 95 | # CONFIG_CPU_MIPS32_R1 is not set |
102 | # CONFIG_CPU_MIPS32_R2 is not set | 96 | # CONFIG_CPU_MIPS32_R2 is not set |
@@ -137,14 +131,15 @@ CONFIG_PAGE_SIZE_4KB=y | |||
137 | CONFIG_MIPS_MT_DISABLED=y | 131 | CONFIG_MIPS_MT_DISABLED=y |
138 | # CONFIG_MIPS_MT_SMP is not set | 132 | # CONFIG_MIPS_MT_SMP is not set |
139 | # CONFIG_MIPS_MT_SMTC is not set | 133 | # CONFIG_MIPS_MT_SMTC is not set |
140 | # CONFIG_MIPS_VPE_LOADER is not set | ||
141 | CONFIG_CPU_HAS_LLSC=y | 134 | CONFIG_CPU_HAS_LLSC=y |
142 | CONFIG_CPU_HAS_SYNC=y | 135 | CONFIG_CPU_HAS_SYNC=y |
143 | CONFIG_GENERIC_HARDIRQS=y | 136 | CONFIG_GENERIC_HARDIRQS=y |
144 | CONFIG_GENERIC_IRQ_PROBE=y | 137 | CONFIG_GENERIC_IRQ_PROBE=y |
145 | CONFIG_IRQ_PER_CPU=y | 138 | CONFIG_IRQ_PER_CPU=y |
146 | CONFIG_CPU_SUPPORTS_HIGHMEM=y | 139 | CONFIG_CPU_SUPPORTS_HIGHMEM=y |
140 | CONFIG_SYS_SUPPORTS_HIGHMEM=y | ||
147 | CONFIG_ARCH_FLATMEM_ENABLE=y | 141 | CONFIG_ARCH_FLATMEM_ENABLE=y |
142 | CONFIG_ARCH_POPULATES_NODE_MAP=y | ||
148 | CONFIG_SELECT_MEMORY_MODEL=y | 143 | CONFIG_SELECT_MEMORY_MODEL=y |
149 | CONFIG_FLATMEM_MANUAL=y | 144 | CONFIG_FLATMEM_MANUAL=y |
150 | # CONFIG_DISCONTIGMEM_MANUAL is not set | 145 | # CONFIG_DISCONTIGMEM_MANUAL is not set |
@@ -152,13 +147,19 @@ CONFIG_FLATMEM_MANUAL=y | |||
152 | CONFIG_FLATMEM=y | 147 | CONFIG_FLATMEM=y |
153 | CONFIG_FLAT_NODE_MEM_MAP=y | 148 | CONFIG_FLAT_NODE_MEM_MAP=y |
154 | # CONFIG_SPARSEMEM_STATIC is not set | 149 | # CONFIG_SPARSEMEM_STATIC is not set |
150 | # CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set | ||
155 | CONFIG_SPLIT_PTLOCK_CPUS=4 | 151 | CONFIG_SPLIT_PTLOCK_CPUS=4 |
156 | CONFIG_RESOURCES_64BIT=y | 152 | CONFIG_RESOURCES_64BIT=y |
157 | CONFIG_ZONE_DMA_FLAG=1 | 153 | CONFIG_ZONE_DMA_FLAG=0 |
154 | CONFIG_VIRT_TO_BUS=y | ||
158 | CONFIG_SMP=y | 155 | CONFIG_SMP=y |
159 | CONFIG_SYS_SUPPORTS_SMP=y | 156 | CONFIG_SYS_SUPPORTS_SMP=y |
160 | CONFIG_NR_CPUS_DEFAULT_4=y | 157 | CONFIG_NR_CPUS_DEFAULT_4=y |
161 | CONFIG_NR_CPUS=4 | 158 | CONFIG_NR_CPUS=4 |
159 | CONFIG_TICK_ONESHOT=y | ||
160 | CONFIG_NO_HZ=y | ||
161 | CONFIG_HIGH_RES_TIMERS=y | ||
162 | CONFIG_GENERIC_CLOCKEVENTS_BUILD=y | ||
162 | # CONFIG_HZ_48 is not set | 163 | # CONFIG_HZ_48 is not set |
163 | # CONFIG_HZ_100 is not set | 164 | # CONFIG_HZ_100 is not set |
164 | # CONFIG_HZ_128 is not set | 165 | # CONFIG_HZ_128 is not set |
@@ -171,38 +172,45 @@ CONFIG_HZ=1000 | |||
171 | CONFIG_PREEMPT_NONE=y | 172 | CONFIG_PREEMPT_NONE=y |
172 | # CONFIG_PREEMPT_VOLUNTARY is not set | 173 | # CONFIG_PREEMPT_VOLUNTARY is not set |
173 | # CONFIG_PREEMPT is not set | 174 | # CONFIG_PREEMPT is not set |
174 | # CONFIG_PREEMPT_BKL is not set | ||
175 | # CONFIG_KEXEC is not set | 175 | # CONFIG_KEXEC is not set |
176 | CONFIG_SECCOMP=y | ||
176 | CONFIG_LOCKDEP_SUPPORT=y | 177 | CONFIG_LOCKDEP_SUPPORT=y |
177 | CONFIG_STACKTRACE_SUPPORT=y | 178 | CONFIG_STACKTRACE_SUPPORT=y |
178 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | 179 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" |
179 | 180 | ||
180 | # | 181 | # |
181 | # Code maturity level options | 182 | # General setup |
182 | # | 183 | # |
183 | CONFIG_EXPERIMENTAL=y | 184 | CONFIG_EXPERIMENTAL=y |
184 | CONFIG_LOCK_KERNEL=y | 185 | CONFIG_LOCK_KERNEL=y |
185 | CONFIG_INIT_ENV_ARG_LIMIT=32 | 186 | CONFIG_INIT_ENV_ARG_LIMIT=32 |
186 | |||
187 | # | ||
188 | # General setup | ||
189 | # | ||
190 | CONFIG_LOCALVERSION="" | 187 | CONFIG_LOCALVERSION="" |
191 | CONFIG_LOCALVERSION_AUTO=y | 188 | CONFIG_LOCALVERSION_AUTO=y |
192 | CONFIG_SWAP=y | 189 | CONFIG_SWAP=y |
193 | CONFIG_SYSVIPC=y | 190 | CONFIG_SYSVIPC=y |
194 | # CONFIG_IPC_NS is not set | ||
195 | CONFIG_SYSVIPC_SYSCTL=y | 191 | CONFIG_SYSVIPC_SYSCTL=y |
196 | # CONFIG_POSIX_MQUEUE is not set | 192 | CONFIG_POSIX_MQUEUE=y |
197 | # CONFIG_BSD_PROCESS_ACCT is not set | 193 | CONFIG_BSD_PROCESS_ACCT=y |
198 | # CONFIG_TASKSTATS is not set | 194 | CONFIG_BSD_PROCESS_ACCT_V3=y |
199 | # CONFIG_UTS_NS is not set | 195 | CONFIG_TASKSTATS=y |
200 | # CONFIG_AUDIT is not set | 196 | CONFIG_TASK_DELAY_ACCT=y |
197 | CONFIG_TASK_XACCT=y | ||
198 | CONFIG_TASK_IO_ACCOUNTING=y | ||
199 | CONFIG_AUDIT=y | ||
201 | CONFIG_IKCONFIG=y | 200 | CONFIG_IKCONFIG=y |
202 | CONFIG_IKCONFIG_PROC=y | 201 | CONFIG_IKCONFIG_PROC=y |
203 | # CONFIG_CPUSETS is not set | 202 | CONFIG_LOG_BUF_SHIFT=16 |
203 | # CONFIG_CGROUPS is not set | ||
204 | CONFIG_GROUP_SCHED=y | ||
205 | CONFIG_FAIR_GROUP_SCHED=y | ||
206 | # CONFIG_RT_GROUP_SCHED is not set | ||
207 | CONFIG_USER_SCHED=y | ||
208 | # CONFIG_CGROUP_SCHED is not set | ||
204 | CONFIG_SYSFS_DEPRECATED=y | 209 | CONFIG_SYSFS_DEPRECATED=y |
205 | # CONFIG_RELAY is not set | 210 | CONFIG_SYSFS_DEPRECATED_V2=y |
211 | CONFIG_RELAY=y | ||
212 | # CONFIG_NAMESPACES is not set | ||
213 | CONFIG_BLK_DEV_INITRD=y | ||
206 | CONFIG_INITRAMFS_SOURCE="" | 214 | CONFIG_INITRAMFS_SOURCE="" |
207 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | 215 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set |
208 | CONFIG_SYSCTL=y | 216 | CONFIG_SYSCTL=y |
@@ -211,24 +219,33 @@ CONFIG_EMBEDDED=y | |||
211 | CONFIG_KALLSYMS=y | 219 | CONFIG_KALLSYMS=y |
212 | # CONFIG_KALLSYMS_ALL is not set | 220 | # CONFIG_KALLSYMS_ALL is not set |
213 | # CONFIG_KALLSYMS_EXTRA_PASS is not set | 221 | # CONFIG_KALLSYMS_EXTRA_PASS is not set |
214 | # CONFIG_HOTPLUG is not set | 222 | CONFIG_HOTPLUG=y |
215 | CONFIG_PRINTK=y | 223 | CONFIG_PRINTK=y |
216 | CONFIG_BUG=y | 224 | CONFIG_BUG=y |
217 | CONFIG_ELF_CORE=y | 225 | CONFIG_ELF_CORE=y |
226 | CONFIG_COMPAT_BRK=y | ||
218 | CONFIG_BASE_FULL=y | 227 | CONFIG_BASE_FULL=y |
219 | CONFIG_FUTEX=y | 228 | CONFIG_FUTEX=y |
229 | CONFIG_ANON_INODES=y | ||
220 | CONFIG_EPOLL=y | 230 | CONFIG_EPOLL=y |
231 | CONFIG_SIGNALFD=y | ||
232 | CONFIG_TIMERFD=y | ||
233 | CONFIG_EVENTFD=y | ||
221 | CONFIG_SHMEM=y | 234 | CONFIG_SHMEM=y |
222 | CONFIG_SLAB=y | ||
223 | CONFIG_VM_EVENT_COUNTERS=y | 235 | CONFIG_VM_EVENT_COUNTERS=y |
236 | CONFIG_SLAB=y | ||
237 | # CONFIG_SLUB is not set | ||
238 | # CONFIG_SLOB is not set | ||
239 | # CONFIG_PROFILING is not set | ||
240 | # CONFIG_MARKERS is not set | ||
241 | CONFIG_HAVE_OPROFILE=y | ||
242 | # CONFIG_HAVE_KPROBES is not set | ||
243 | # CONFIG_HAVE_KRETPROBES is not set | ||
244 | CONFIG_PROC_PAGE_MONITOR=y | ||
245 | CONFIG_SLABINFO=y | ||
224 | CONFIG_RT_MUTEXES=y | 246 | CONFIG_RT_MUTEXES=y |
225 | # CONFIG_TINY_SHMEM is not set | 247 | # CONFIG_TINY_SHMEM is not set |
226 | CONFIG_BASE_SMALL=0 | 248 | CONFIG_BASE_SMALL=0 |
227 | # CONFIG_SLOB is not set | ||
228 | |||
229 | # | ||
230 | # Loadable module support | ||
231 | # | ||
232 | CONFIG_MODULES=y | 249 | CONFIG_MODULES=y |
233 | CONFIG_MODULE_UNLOAD=y | 250 | CONFIG_MODULE_UNLOAD=y |
234 | # CONFIG_MODULE_FORCE_UNLOAD is not set | 251 | # CONFIG_MODULE_FORCE_UNLOAD is not set |
@@ -236,12 +253,10 @@ CONFIG_MODVERSIONS=y | |||
236 | CONFIG_MODULE_SRCVERSION_ALL=y | 253 | CONFIG_MODULE_SRCVERSION_ALL=y |
237 | CONFIG_KMOD=y | 254 | CONFIG_KMOD=y |
238 | CONFIG_STOP_MACHINE=y | 255 | CONFIG_STOP_MACHINE=y |
239 | |||
240 | # | ||
241 | # Block layer | ||
242 | # | ||
243 | CONFIG_BLOCK=y | 256 | CONFIG_BLOCK=y |
244 | # CONFIG_BLK_DEV_IO_TRACE is not set | 257 | # CONFIG_BLK_DEV_IO_TRACE is not set |
258 | # CONFIG_BLK_DEV_BSG is not set | ||
259 | CONFIG_BLOCK_COMPAT=y | ||
245 | 260 | ||
246 | # | 261 | # |
247 | # IO Schedulers | 262 | # IO Schedulers |
@@ -255,6 +270,7 @@ CONFIG_DEFAULT_AS=y | |||
255 | # CONFIG_DEFAULT_CFQ is not set | 270 | # CONFIG_DEFAULT_CFQ is not set |
256 | # CONFIG_DEFAULT_NOOP is not set | 271 | # CONFIG_DEFAULT_NOOP is not set |
257 | CONFIG_DEFAULT_IOSCHED="anticipatory" | 272 | CONFIG_DEFAULT_IOSCHED="anticipatory" |
273 | CONFIG_CLASSIC_RCU=y | ||
258 | 274 | ||
259 | # | 275 | # |
260 | # Bus options (PCI, PCMCIA, EISA, ISA, TC) | 276 | # Bus options (PCI, PCMCIA, EISA, ISA, TC) |
@@ -262,23 +278,19 @@ CONFIG_DEFAULT_IOSCHED="anticipatory" | |||
262 | CONFIG_HW_HAS_PCI=y | 278 | CONFIG_HW_HAS_PCI=y |
263 | CONFIG_PCI=y | 279 | CONFIG_PCI=y |
264 | CONFIG_PCI_DOMAINS=y | 280 | CONFIG_PCI_DOMAINS=y |
281 | # CONFIG_ARCH_SUPPORTS_MSI is not set | ||
282 | CONFIG_PCI_LEGACY=y | ||
265 | CONFIG_PCI_DEBUG=y | 283 | CONFIG_PCI_DEBUG=y |
266 | CONFIG_MMU=y | 284 | CONFIG_MMU=y |
267 | 285 | CONFIG_ZONE_DMA32=y | |
268 | # | 286 | # CONFIG_PCCARD is not set |
269 | # PCCARD (PCMCIA/CardBus) support | 287 | # CONFIG_HOTPLUG_PCI is not set |
270 | # | ||
271 | |||
272 | # | ||
273 | # PCI Hotplug Support | ||
274 | # | ||
275 | 288 | ||
276 | # | 289 | # |
277 | # Executable file formats | 290 | # Executable file formats |
278 | # | 291 | # |
279 | CONFIG_BINFMT_ELF=y | 292 | CONFIG_BINFMT_ELF=y |
280 | # CONFIG_BINFMT_MISC is not set | 293 | # CONFIG_BINFMT_MISC is not set |
281 | # CONFIG_BUILD_ELF64 is not set | ||
282 | CONFIG_MIPS32_COMPAT=y | 294 | CONFIG_MIPS32_COMPAT=y |
283 | CONFIG_COMPAT=y | 295 | CONFIG_COMPAT=y |
284 | CONFIG_SYSVIPC_COMPAT=y | 296 | CONFIG_SYSVIPC_COMPAT=y |
@@ -292,7 +304,6 @@ CONFIG_BINFMT_ELF32=y | |||
292 | CONFIG_PM=y | 304 | CONFIG_PM=y |
293 | # CONFIG_PM_LEGACY is not set | 305 | # CONFIG_PM_LEGACY is not set |
294 | # CONFIG_PM_DEBUG is not set | 306 | # CONFIG_PM_DEBUG is not set |
295 | # CONFIG_PM_SYSFS_DEPRECATED is not set | ||
296 | 307 | ||
297 | # | 308 | # |
298 | # Networking | 309 | # Networking |
@@ -302,7 +313,6 @@ CONFIG_NET=y | |||
302 | # | 313 | # |
303 | # Networking options | 314 | # Networking options |
304 | # | 315 | # |
305 | # CONFIG_NETDEBUG is not set | ||
306 | CONFIG_PACKET=y | 316 | CONFIG_PACKET=y |
307 | CONFIG_PACKET_MMAP=y | 317 | CONFIG_PACKET_MMAP=y |
308 | CONFIG_UNIX=y | 318 | CONFIG_UNIX=y |
@@ -310,10 +320,11 @@ CONFIG_XFRM=y | |||
310 | CONFIG_XFRM_USER=m | 320 | CONFIG_XFRM_USER=m |
311 | # CONFIG_XFRM_SUB_POLICY is not set | 321 | # CONFIG_XFRM_SUB_POLICY is not set |
312 | CONFIG_XFRM_MIGRATE=y | 322 | CONFIG_XFRM_MIGRATE=y |
323 | # CONFIG_XFRM_STATISTICS is not set | ||
313 | CONFIG_NET_KEY=y | 324 | CONFIG_NET_KEY=y |
314 | CONFIG_NET_KEY_MIGRATE=y | 325 | CONFIG_NET_KEY_MIGRATE=y |
315 | CONFIG_INET=y | 326 | CONFIG_INET=y |
316 | # CONFIG_IP_MULTICAST is not set | 327 | CONFIG_IP_MULTICAST=y |
317 | # CONFIG_IP_ADVANCED_ROUTER is not set | 328 | # CONFIG_IP_ADVANCED_ROUTER is not set |
318 | CONFIG_IP_FIB_HASH=y | 329 | CONFIG_IP_FIB_HASH=y |
319 | CONFIG_IP_PNP=y | 330 | CONFIG_IP_PNP=y |
@@ -322,41 +333,141 @@ CONFIG_IP_PNP_BOOTP=y | |||
322 | # CONFIG_IP_PNP_RARP is not set | 333 | # CONFIG_IP_PNP_RARP is not set |
323 | # CONFIG_NET_IPIP is not set | 334 | # CONFIG_NET_IPIP is not set |
324 | # CONFIG_NET_IPGRE is not set | 335 | # CONFIG_NET_IPGRE is not set |
336 | CONFIG_IP_MROUTE=y | ||
337 | CONFIG_IP_PIMSM_V1=y | ||
338 | CONFIG_IP_PIMSM_V2=y | ||
325 | # CONFIG_ARPD is not set | 339 | # CONFIG_ARPD is not set |
326 | # CONFIG_SYN_COOKIES is not set | 340 | # CONFIG_SYN_COOKIES is not set |
327 | # CONFIG_INET_AH is not set | 341 | CONFIG_INET_AH=m |
328 | # CONFIG_INET_ESP is not set | 342 | CONFIG_INET_ESP=m |
329 | # CONFIG_INET_IPCOMP is not set | 343 | CONFIG_INET_IPCOMP=m |
330 | # CONFIG_INET_XFRM_TUNNEL is not set | 344 | CONFIG_INET_XFRM_TUNNEL=m |
331 | # CONFIG_INET_TUNNEL is not set | 345 | CONFIG_INET_TUNNEL=m |
332 | CONFIG_INET_XFRM_MODE_TRANSPORT=m | 346 | CONFIG_INET_XFRM_MODE_TRANSPORT=m |
333 | CONFIG_INET_XFRM_MODE_TUNNEL=m | 347 | CONFIG_INET_XFRM_MODE_TUNNEL=m |
334 | CONFIG_INET_XFRM_MODE_BEET=y | 348 | CONFIG_INET_XFRM_MODE_BEET=y |
349 | # CONFIG_INET_LRO is not set | ||
335 | CONFIG_INET_DIAG=y | 350 | CONFIG_INET_DIAG=y |
336 | CONFIG_INET_TCP_DIAG=y | 351 | CONFIG_INET_TCP_DIAG=y |
337 | # CONFIG_TCP_CONG_ADVANCED is not set | 352 | # CONFIG_TCP_CONG_ADVANCED is not set |
338 | CONFIG_TCP_CONG_CUBIC=y | 353 | CONFIG_TCP_CONG_CUBIC=y |
339 | CONFIG_DEFAULT_TCP_CONG="cubic" | 354 | CONFIG_DEFAULT_TCP_CONG="cubic" |
340 | CONFIG_TCP_MD5SIG=y | 355 | CONFIG_TCP_MD5SIG=y |
341 | # CONFIG_IPV6 is not set | 356 | CONFIG_IP_VS=m |
342 | # CONFIG_INET6_XFRM_TUNNEL is not set | 357 | # CONFIG_IP_VS_DEBUG is not set |
343 | # CONFIG_INET6_TUNNEL is not set | 358 | CONFIG_IP_VS_TAB_BITS=12 |
359 | |||
360 | # | ||
361 | # IPVS transport protocol load balancing support | ||
362 | # | ||
363 | CONFIG_IP_VS_PROTO_TCP=y | ||
364 | CONFIG_IP_VS_PROTO_UDP=y | ||
365 | CONFIG_IP_VS_PROTO_ESP=y | ||
366 | CONFIG_IP_VS_PROTO_AH=y | ||
367 | |||
368 | # | ||
369 | # IPVS scheduler | ||
370 | # | ||
371 | CONFIG_IP_VS_RR=m | ||
372 | CONFIG_IP_VS_WRR=m | ||
373 | CONFIG_IP_VS_LC=m | ||
374 | CONFIG_IP_VS_WLC=m | ||
375 | CONFIG_IP_VS_LBLC=m | ||
376 | CONFIG_IP_VS_LBLCR=m | ||
377 | CONFIG_IP_VS_DH=m | ||
378 | CONFIG_IP_VS_SH=m | ||
379 | CONFIG_IP_VS_SED=m | ||
380 | CONFIG_IP_VS_NQ=m | ||
381 | |||
382 | # | ||
383 | # IPVS application helper | ||
384 | # | ||
385 | CONFIG_IP_VS_FTP=m | ||
386 | CONFIG_IPV6=m | ||
387 | CONFIG_IPV6_PRIVACY=y | ||
388 | CONFIG_IPV6_ROUTER_PREF=y | ||
389 | CONFIG_IPV6_ROUTE_INFO=y | ||
390 | CONFIG_IPV6_OPTIMISTIC_DAD=y | ||
391 | CONFIG_INET6_AH=m | ||
392 | CONFIG_INET6_ESP=m | ||
393 | CONFIG_INET6_IPCOMP=m | ||
394 | CONFIG_IPV6_MIP6=m | ||
395 | CONFIG_INET6_XFRM_TUNNEL=m | ||
396 | CONFIG_INET6_TUNNEL=m | ||
397 | CONFIG_INET6_XFRM_MODE_TRANSPORT=m | ||
398 | CONFIG_INET6_XFRM_MODE_TUNNEL=m | ||
399 | CONFIG_INET6_XFRM_MODE_BEET=m | ||
400 | CONFIG_INET6_XFRM_MODE_ROUTEOPTIMIZATION=m | ||
401 | CONFIG_IPV6_SIT=m | ||
402 | CONFIG_IPV6_TUNNEL=m | ||
403 | CONFIG_IPV6_MULTIPLE_TABLES=y | ||
404 | CONFIG_IPV6_SUBTREES=y | ||
344 | CONFIG_NETWORK_SECMARK=y | 405 | CONFIG_NETWORK_SECMARK=y |
345 | # CONFIG_NETFILTER is not set | 406 | CONFIG_NETFILTER=y |
346 | 407 | # CONFIG_NETFILTER_DEBUG is not set | |
347 | # | 408 | # CONFIG_NETFILTER_ADVANCED is not set |
348 | # DCCP Configuration (EXPERIMENTAL) | 409 | |
349 | # | 410 | # |
411 | # Core Netfilter Configuration | ||
412 | # | ||
413 | CONFIG_NETFILTER_NETLINK=m | ||
414 | CONFIG_NETFILTER_NETLINK_LOG=m | ||
415 | CONFIG_NF_CONNTRACK=m | ||
416 | CONFIG_NF_CONNTRACK_SECMARK=y | ||
417 | CONFIG_NF_CONNTRACK_FTP=m | ||
418 | CONFIG_NF_CONNTRACK_IRC=m | ||
419 | CONFIG_NF_CONNTRACK_SIP=m | ||
420 | CONFIG_NF_CT_NETLINK=m | ||
421 | CONFIG_NETFILTER_XTABLES=m | ||
422 | CONFIG_NETFILTER_XT_TARGET_MARK=m | ||
423 | CONFIG_NETFILTER_XT_TARGET_NFLOG=m | ||
424 | CONFIG_NETFILTER_XT_TARGET_SECMARK=m | ||
425 | CONFIG_NETFILTER_XT_TARGET_CONNSECMARK=m | ||
426 | CONFIG_NETFILTER_XT_TARGET_TCPMSS=m | ||
427 | CONFIG_NETFILTER_XT_MATCH_CONNTRACK=m | ||
428 | CONFIG_NETFILTER_XT_MATCH_MARK=m | ||
429 | CONFIG_NETFILTER_XT_MATCH_POLICY=m | ||
430 | CONFIG_NETFILTER_XT_MATCH_STATE=m | ||
431 | |||
432 | # | ||
433 | # IP: Netfilter Configuration | ||
434 | # | ||
435 | CONFIG_NF_CONNTRACK_IPV4=m | ||
436 | CONFIG_NF_CONNTRACK_PROC_COMPAT=y | ||
437 | CONFIG_IP_NF_IPTABLES=m | ||
438 | CONFIG_IP_NF_FILTER=m | ||
439 | CONFIG_IP_NF_TARGET_REJECT=m | ||
440 | CONFIG_IP_NF_TARGET_LOG=m | ||
441 | CONFIG_IP_NF_TARGET_ULOG=m | ||
442 | CONFIG_NF_NAT=m | ||
443 | CONFIG_NF_NAT_NEEDED=y | ||
444 | CONFIG_IP_NF_TARGET_MASQUERADE=m | ||
445 | CONFIG_NF_NAT_FTP=m | ||
446 | CONFIG_NF_NAT_IRC=m | ||
447 | # CONFIG_NF_NAT_TFTP is not set | ||
448 | # CONFIG_NF_NAT_AMANDA is not set | ||
449 | # CONFIG_NF_NAT_PPTP is not set | ||
450 | # CONFIG_NF_NAT_H323 is not set | ||
451 | CONFIG_NF_NAT_SIP=m | ||
452 | CONFIG_IP_NF_MANGLE=m | ||
453 | |||
454 | # | ||
455 | # IPv6: Netfilter Configuration | ||
456 | # | ||
457 | CONFIG_NF_CONNTRACK_IPV6=m | ||
458 | CONFIG_IP6_NF_IPTABLES=m | ||
459 | CONFIG_IP6_NF_MATCH_IPV6HEADER=m | ||
460 | CONFIG_IP6_NF_FILTER=m | ||
461 | CONFIG_IP6_NF_TARGET_LOG=m | ||
462 | CONFIG_IP6_NF_TARGET_REJECT=m | ||
463 | CONFIG_IP6_NF_MANGLE=m | ||
350 | # CONFIG_IP_DCCP is not set | 464 | # CONFIG_IP_DCCP is not set |
351 | 465 | CONFIG_IP_SCTP=m | |
352 | # | 466 | # CONFIG_SCTP_DBG_MSG is not set |
353 | # SCTP Configuration (EXPERIMENTAL) | 467 | # CONFIG_SCTP_DBG_OBJCNT is not set |
354 | # | 468 | # CONFIG_SCTP_HMAC_NONE is not set |
355 | # CONFIG_IP_SCTP is not set | 469 | # CONFIG_SCTP_HMAC_SHA1 is not set |
356 | 470 | CONFIG_SCTP_HMAC_MD5=y | |
357 | # | ||
358 | # TIPC Configuration (EXPERIMENTAL) | ||
359 | # | ||
360 | # CONFIG_TIPC is not set | 471 | # CONFIG_TIPC is not set |
361 | # CONFIG_ATM is not set | 472 | # CONFIG_ATM is not set |
362 | # CONFIG_BRIDGE is not set | 473 | # CONFIG_BRIDGE is not set |
@@ -369,10 +480,6 @@ CONFIG_NETWORK_SECMARK=y | |||
369 | # CONFIG_LAPB is not set | 480 | # CONFIG_LAPB is not set |
370 | # CONFIG_ECONET is not set | 481 | # CONFIG_ECONET is not set |
371 | # CONFIG_WAN_ROUTER is not set | 482 | # CONFIG_WAN_ROUTER is not set |
372 | |||
373 | # | ||
374 | # QoS and/or fair queueing | ||
375 | # | ||
376 | # CONFIG_NET_SCHED is not set | 483 | # CONFIG_NET_SCHED is not set |
377 | 484 | ||
378 | # | 485 | # |
@@ -380,9 +487,21 @@ CONFIG_NETWORK_SECMARK=y | |||
380 | # | 487 | # |
381 | # CONFIG_NET_PKTGEN is not set | 488 | # CONFIG_NET_PKTGEN is not set |
382 | # CONFIG_HAMRADIO is not set | 489 | # CONFIG_HAMRADIO is not set |
490 | # CONFIG_CAN is not set | ||
383 | # CONFIG_IRDA is not set | 491 | # CONFIG_IRDA is not set |
384 | # CONFIG_BT is not set | 492 | # CONFIG_BT is not set |
493 | # CONFIG_AF_RXRPC is not set | ||
494 | CONFIG_FIB_RULES=y | ||
495 | |||
496 | # | ||
497 | # Wireless | ||
498 | # | ||
499 | # CONFIG_CFG80211 is not set | ||
500 | # CONFIG_WIRELESS_EXT is not set | ||
501 | # CONFIG_MAC80211 is not set | ||
385 | # CONFIG_IEEE80211 is not set | 502 | # CONFIG_IEEE80211 is not set |
503 | # CONFIG_RFKILL is not set | ||
504 | # CONFIG_NET_9P is not set | ||
386 | 505 | ||
387 | # | 506 | # |
388 | # Device Drivers | 507 | # Device Drivers |
@@ -391,85 +510,70 @@ CONFIG_NETWORK_SECMARK=y | |||
391 | # | 510 | # |
392 | # Generic Driver Options | 511 | # Generic Driver Options |
393 | # | 512 | # |
513 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | ||
394 | CONFIG_STANDALONE=y | 514 | CONFIG_STANDALONE=y |
395 | CONFIG_PREVENT_FIRMWARE_BUILD=y | 515 | CONFIG_PREVENT_FIRMWARE_BUILD=y |
516 | CONFIG_FW_LOADER=m | ||
396 | # CONFIG_DEBUG_DRIVER is not set | 517 | # CONFIG_DEBUG_DRIVER is not set |
397 | # CONFIG_DEBUG_DEVRES is not set | 518 | # CONFIG_DEBUG_DEVRES is not set |
398 | # CONFIG_SYS_HYPERVISOR is not set | 519 | # CONFIG_SYS_HYPERVISOR is not set |
399 | |||
400 | # | ||
401 | # Connector - unified userspace <-> kernelspace linker | ||
402 | # | ||
403 | # CONFIG_CONNECTOR is not set | 520 | # CONFIG_CONNECTOR is not set |
404 | |||
405 | # | ||
406 | # Memory Technology Devices (MTD) | ||
407 | # | ||
408 | # CONFIG_MTD is not set | 521 | # CONFIG_MTD is not set |
409 | |||
410 | # | ||
411 | # Parallel port support | ||
412 | # | ||
413 | # CONFIG_PARPORT is not set | 522 | # CONFIG_PARPORT is not set |
414 | 523 | CONFIG_BLK_DEV=y | |
415 | # | ||
416 | # Plug and Play support | ||
417 | # | ||
418 | # CONFIG_PNPACPI is not set | ||
419 | |||
420 | # | ||
421 | # Block devices | ||
422 | # | ||
423 | # CONFIG_BLK_CPQ_DA is not set | 524 | # CONFIG_BLK_CPQ_DA is not set |
424 | # CONFIG_BLK_CPQ_CISS_DA is not set | 525 | # CONFIG_BLK_CPQ_CISS_DA is not set |
425 | # CONFIG_BLK_DEV_DAC960 is not set | 526 | # CONFIG_BLK_DEV_DAC960 is not set |
426 | # CONFIG_BLK_DEV_UMEM is not set | 527 | # CONFIG_BLK_DEV_UMEM is not set |
427 | # CONFIG_BLK_DEV_COW_COMMON is not set | 528 | # CONFIG_BLK_DEV_COW_COMMON is not set |
428 | CONFIG_BLK_DEV_LOOP=m | 529 | CONFIG_BLK_DEV_LOOP=m |
429 | # CONFIG_BLK_DEV_CRYPTOLOOP is not set | 530 | CONFIG_BLK_DEV_CRYPTOLOOP=m |
430 | CONFIG_BLK_DEV_NBD=m | 531 | CONFIG_BLK_DEV_NBD=m |
431 | # CONFIG_BLK_DEV_SX8 is not set | 532 | # CONFIG_BLK_DEV_SX8 is not set |
432 | # CONFIG_BLK_DEV_RAM is not set | 533 | # CONFIG_BLK_DEV_RAM is not set |
433 | CONFIG_BLK_DEV_INITRD=y | ||
434 | # CONFIG_CDROM_PKTCDVD is not set | 534 | # CONFIG_CDROM_PKTCDVD is not set |
435 | # CONFIG_ATA_OVER_ETH is not set | 535 | # CONFIG_ATA_OVER_ETH is not set |
436 | 536 | CONFIG_MISC_DEVICES=y | |
437 | # | 537 | # CONFIG_PHANTOM is not set |
438 | # Misc devices | 538 | # CONFIG_EEPROM_93CX6 is not set |
439 | # | ||
440 | CONFIG_SGI_IOC4=m | 539 | CONFIG_SGI_IOC4=m |
441 | # CONFIG_TIFM_CORE is not set | 540 | # CONFIG_TIFM_CORE is not set |
442 | 541 | # CONFIG_ENCLOSURE_SERVICES is not set | |
443 | # | 542 | CONFIG_HAVE_IDE=y |
444 | # ATA/ATAPI/MFM/RLL support | ||
445 | # | ||
446 | CONFIG_IDE=y | 543 | CONFIG_IDE=y |
447 | CONFIG_IDE_MAX_HWIFS=4 | 544 | CONFIG_IDE_MAX_HWIFS=4 |
448 | CONFIG_BLK_DEV_IDE=y | 545 | CONFIG_BLK_DEV_IDE=y |
449 | 546 | ||
450 | # | 547 | # |
451 | # Please see Documentation/ide.txt for help/info on IDE drives | 548 | # Please see Documentation/ide/ide.txt for help/info on IDE drives |
452 | # | 549 | # |
453 | # CONFIG_BLK_DEV_IDE_SATA is not set | 550 | # CONFIG_BLK_DEV_IDE_SATA is not set |
454 | CONFIG_BLK_DEV_IDEDISK=y | 551 | CONFIG_BLK_DEV_IDEDISK=y |
455 | # CONFIG_IDEDISK_MULTI_MODE is not set | 552 | # CONFIG_IDEDISK_MULTI_MODE is not set |
456 | CONFIG_BLK_DEV_IDECD=y | 553 | CONFIG_BLK_DEV_IDECD=y |
554 | CONFIG_BLK_DEV_IDECD_VERBOSE_ERRORS=y | ||
457 | CONFIG_BLK_DEV_IDETAPE=y | 555 | CONFIG_BLK_DEV_IDETAPE=y |
458 | CONFIG_BLK_DEV_IDEFLOPPY=y | 556 | CONFIG_BLK_DEV_IDEFLOPPY=y |
557 | # CONFIG_BLK_DEV_IDESCSI is not set | ||
459 | # CONFIG_IDE_TASK_IOCTL is not set | 558 | # CONFIG_IDE_TASK_IOCTL is not set |
559 | CONFIG_IDE_PROC_FS=y | ||
460 | 560 | ||
461 | # | 561 | # |
462 | # IDE chipset support/bugfixes | 562 | # IDE chipset support/bugfixes |
463 | # | 563 | # |
464 | CONFIG_IDE_GENERIC=y | 564 | CONFIG_IDE_GENERIC=y |
565 | # CONFIG_BLK_DEV_PLATFORM is not set | ||
566 | CONFIG_BLK_DEV_IDEDMA_SFF=y | ||
567 | |||
568 | # | ||
569 | # PCI IDE chipsets support | ||
570 | # | ||
465 | CONFIG_BLK_DEV_IDEPCI=y | 571 | CONFIG_BLK_DEV_IDEPCI=y |
466 | # CONFIG_IDEPCI_SHARE_IRQ is not set | 572 | CONFIG_IDEPCI_PCIBUS_ORDER=y |
467 | # CONFIG_BLK_DEV_OFFBOARD is not set | 573 | # CONFIG_BLK_DEV_OFFBOARD is not set |
468 | CONFIG_BLK_DEV_GENERIC=y | 574 | CONFIG_BLK_DEV_GENERIC=y |
469 | # CONFIG_BLK_DEV_OPTI621 is not set | 575 | # CONFIG_BLK_DEV_OPTI621 is not set |
470 | CONFIG_BLK_DEV_IDEDMA_PCI=y | 576 | CONFIG_BLK_DEV_IDEDMA_PCI=y |
471 | # CONFIG_BLK_DEV_IDEDMA_FORCED is not set | ||
472 | # CONFIG_IDEDMA_PCI_AUTO is not set | ||
473 | # CONFIG_BLK_DEV_AEC62XX is not set | 577 | # CONFIG_BLK_DEV_AEC62XX is not set |
474 | # CONFIG_BLK_DEV_ALI15X3 is not set | 578 | # CONFIG_BLK_DEV_ALI15X3 is not set |
475 | # CONFIG_BLK_DEV_AMD74XX is not set | 579 | # CONFIG_BLK_DEV_AMD74XX is not set |
@@ -495,87 +599,196 @@ CONFIG_BLK_DEV_IT8213=m | |||
495 | # CONFIG_BLK_DEV_VIA82CXXX is not set | 599 | # CONFIG_BLK_DEV_VIA82CXXX is not set |
496 | CONFIG_BLK_DEV_TC86C001=m | 600 | CONFIG_BLK_DEV_TC86C001=m |
497 | # CONFIG_BLK_DEV_IDE_SWARM is not set | 601 | # CONFIG_BLK_DEV_IDE_SWARM is not set |
498 | # CONFIG_IDE_ARM is not set | ||
499 | CONFIG_BLK_DEV_IDEDMA=y | 602 | CONFIG_BLK_DEV_IDEDMA=y |
500 | # CONFIG_IDEDMA_IVB is not set | 603 | CONFIG_IDE_ARCH_OBSOLETE_INIT=y |
501 | # CONFIG_IDEDMA_AUTO is not set | ||
502 | # CONFIG_BLK_DEV_HD is not set | 604 | # CONFIG_BLK_DEV_HD is not set |
503 | 605 | ||
504 | # | 606 | # |
505 | # SCSI device support | 607 | # SCSI device support |
506 | # | 608 | # |
507 | # CONFIG_RAID_ATTRS is not set | 609 | # CONFIG_RAID_ATTRS is not set |
508 | # CONFIG_SCSI is not set | 610 | CONFIG_SCSI=y |
611 | CONFIG_SCSI_DMA=y | ||
612 | # CONFIG_SCSI_TGT is not set | ||
509 | # CONFIG_SCSI_NETLINK is not set | 613 | # CONFIG_SCSI_NETLINK is not set |
510 | 614 | CONFIG_SCSI_PROC_FS=y | |
511 | # | 615 | |
512 | # Serial ATA (prod) and Parallel ATA (experimental) drivers | 616 | # |
513 | # | 617 | # SCSI support type (disk, tape, CD-ROM) |
514 | # CONFIG_ATA is not set | 618 | # |
515 | 619 | CONFIG_BLK_DEV_SD=y | |
516 | # | 620 | # CONFIG_CHR_DEV_ST is not set |
517 | # Multi-device support (RAID and LVM) | 621 | # CONFIG_CHR_DEV_OSST is not set |
518 | # | 622 | # CONFIG_BLK_DEV_SR is not set |
623 | # CONFIG_CHR_DEV_SG is not set | ||
624 | # CONFIG_CHR_DEV_SCH is not set | ||
625 | |||
626 | # | ||
627 | # Some SCSI devices (e.g. CD jukebox) support multiple LUNs | ||
628 | # | ||
629 | # CONFIG_SCSI_MULTI_LUN is not set | ||
630 | # CONFIG_SCSI_CONSTANTS is not set | ||
631 | # CONFIG_SCSI_LOGGING is not set | ||
632 | # CONFIG_SCSI_SCAN_ASYNC is not set | ||
633 | CONFIG_SCSI_WAIT_SCAN=m | ||
634 | |||
635 | # | ||
636 | # SCSI Transports | ||
637 | # | ||
638 | # CONFIG_SCSI_SPI_ATTRS is not set | ||
639 | # CONFIG_SCSI_FC_ATTRS is not set | ||
640 | # CONFIG_SCSI_ISCSI_ATTRS is not set | ||
641 | # CONFIG_SCSI_SAS_LIBSAS is not set | ||
642 | # CONFIG_SCSI_SRP_ATTRS is not set | ||
643 | CONFIG_SCSI_LOWLEVEL=y | ||
644 | # CONFIG_ISCSI_TCP is not set | ||
645 | # CONFIG_BLK_DEV_3W_XXXX_RAID is not set | ||
646 | # CONFIG_SCSI_3W_9XXX is not set | ||
647 | # CONFIG_SCSI_ACARD is not set | ||
648 | # CONFIG_SCSI_AACRAID is not set | ||
649 | # CONFIG_SCSI_AIC7XXX is not set | ||
650 | # CONFIG_SCSI_AIC7XXX_OLD is not set | ||
651 | # CONFIG_SCSI_AIC79XX is not set | ||
652 | # CONFIG_SCSI_AIC94XX is not set | ||
653 | # CONFIG_SCSI_ADVANSYS is not set | ||
654 | # CONFIG_SCSI_ARCMSR is not set | ||
655 | # CONFIG_MEGARAID_NEWGEN is not set | ||
656 | # CONFIG_MEGARAID_LEGACY is not set | ||
657 | # CONFIG_MEGARAID_SAS is not set | ||
658 | # CONFIG_SCSI_HPTIOP is not set | ||
659 | # CONFIG_SCSI_DMX3191D is not set | ||
660 | # CONFIG_SCSI_FUTURE_DOMAIN is not set | ||
661 | # CONFIG_SCSI_IPS is not set | ||
662 | # CONFIG_SCSI_INITIO is not set | ||
663 | # CONFIG_SCSI_INIA100 is not set | ||
664 | # CONFIG_SCSI_MVSAS is not set | ||
665 | # CONFIG_SCSI_STEX is not set | ||
666 | # CONFIG_SCSI_SYM53C8XX_2 is not set | ||
667 | # CONFIG_SCSI_IPR is not set | ||
668 | # CONFIG_SCSI_QLOGIC_1280 is not set | ||
669 | # CONFIG_SCSI_QLA_FC is not set | ||
670 | # CONFIG_SCSI_QLA_ISCSI is not set | ||
671 | # CONFIG_SCSI_LPFC is not set | ||
672 | # CONFIG_SCSI_DC395x is not set | ||
673 | # CONFIG_SCSI_DC390T is not set | ||
674 | # CONFIG_SCSI_DEBUG is not set | ||
675 | # CONFIG_SCSI_SRP is not set | ||
676 | CONFIG_ATA=y | ||
677 | # CONFIG_ATA_NONSTANDARD is not set | ||
678 | # CONFIG_SATA_AHCI is not set | ||
679 | # CONFIG_SATA_SVW is not set | ||
680 | # CONFIG_ATA_PIIX is not set | ||
681 | # CONFIG_SATA_MV is not set | ||
682 | # CONFIG_SATA_NV is not set | ||
683 | # CONFIG_PDC_ADMA is not set | ||
684 | # CONFIG_SATA_QSTOR is not set | ||
685 | # CONFIG_SATA_PROMISE is not set | ||
686 | # CONFIG_SATA_SX4 is not set | ||
687 | # CONFIG_SATA_SIL is not set | ||
688 | CONFIG_SATA_SIL24=y | ||
689 | # CONFIG_SATA_SIS is not set | ||
690 | # CONFIG_SATA_ULI is not set | ||
691 | # CONFIG_SATA_VIA is not set | ||
692 | # CONFIG_SATA_VITESSE is not set | ||
693 | # CONFIG_SATA_INIC162X is not set | ||
694 | # CONFIG_PATA_ALI is not set | ||
695 | # CONFIG_PATA_AMD is not set | ||
696 | # CONFIG_PATA_ARTOP is not set | ||
697 | # CONFIG_PATA_ATIIXP is not set | ||
698 | # CONFIG_PATA_CMD640_PCI is not set | ||
699 | # CONFIG_PATA_CMD64X is not set | ||
700 | # CONFIG_PATA_CS5520 is not set | ||
701 | # CONFIG_PATA_CS5530 is not set | ||
702 | # CONFIG_PATA_CYPRESS is not set | ||
703 | # CONFIG_PATA_EFAR is not set | ||
704 | # CONFIG_ATA_GENERIC is not set | ||
705 | # CONFIG_PATA_HPT366 is not set | ||
706 | # CONFIG_PATA_HPT37X is not set | ||
707 | # CONFIG_PATA_HPT3X2N is not set | ||
708 | # CONFIG_PATA_HPT3X3 is not set | ||
709 | # CONFIG_PATA_IT821X is not set | ||
710 | # CONFIG_PATA_IT8213 is not set | ||
711 | # CONFIG_PATA_JMICRON is not set | ||
712 | # CONFIG_PATA_TRIFLEX is not set | ||
713 | # CONFIG_PATA_MARVELL is not set | ||
714 | # CONFIG_PATA_MPIIX is not set | ||
715 | # CONFIG_PATA_OLDPIIX is not set | ||
716 | # CONFIG_PATA_NETCELL is not set | ||
717 | # CONFIG_PATA_NINJA32 is not set | ||
718 | # CONFIG_PATA_NS87410 is not set | ||
719 | # CONFIG_PATA_NS87415 is not set | ||
720 | # CONFIG_PATA_OPTI is not set | ||
721 | # CONFIG_PATA_OPTIDMA is not set | ||
722 | # CONFIG_PATA_PDC_OLD is not set | ||
723 | # CONFIG_PATA_RADISYS is not set | ||
724 | # CONFIG_PATA_RZ1000 is not set | ||
725 | # CONFIG_PATA_SC1200 is not set | ||
726 | # CONFIG_PATA_SERVERWORKS is not set | ||
727 | # CONFIG_PATA_PDC2027X is not set | ||
728 | CONFIG_PATA_SIL680=y | ||
729 | # CONFIG_PATA_SIS is not set | ||
730 | # CONFIG_PATA_VIA is not set | ||
731 | # CONFIG_PATA_WINBOND is not set | ||
732 | # CONFIG_PATA_PLATFORM is not set | ||
519 | # CONFIG_MD is not set | 733 | # CONFIG_MD is not set |
520 | |||
521 | # | ||
522 | # Fusion MPT device support | ||
523 | # | ||
524 | # CONFIG_FUSION is not set | 734 | # CONFIG_FUSION is not set |
525 | 735 | ||
526 | # | 736 | # |
527 | # IEEE 1394 (FireWire) support | 737 | # IEEE 1394 (FireWire) support |
528 | # | 738 | # |
739 | # CONFIG_FIREWIRE is not set | ||
529 | # CONFIG_IEEE1394 is not set | 740 | # CONFIG_IEEE1394 is not set |
530 | |||
531 | # | ||
532 | # I2O device support | ||
533 | # | ||
534 | # CONFIG_I2O is not set | 741 | # CONFIG_I2O is not set |
535 | |||
536 | # | ||
537 | # Network device support | ||
538 | # | ||
539 | CONFIG_NETDEVICES=y | 742 | CONFIG_NETDEVICES=y |
743 | # CONFIG_NETDEVICES_MULTIQUEUE is not set | ||
540 | # CONFIG_DUMMY is not set | 744 | # CONFIG_DUMMY is not set |
541 | # CONFIG_BONDING is not set | 745 | # CONFIG_BONDING is not set |
746 | # CONFIG_MACVLAN is not set | ||
542 | # CONFIG_EQUALIZER is not set | 747 | # CONFIG_EQUALIZER is not set |
543 | # CONFIG_TUN is not set | 748 | # CONFIG_TUN is not set |
544 | 749 | # CONFIG_VETH is not set | |
545 | # | ||
546 | # ARCnet devices | ||
547 | # | ||
548 | # CONFIG_ARCNET is not set | 750 | # CONFIG_ARCNET is not set |
549 | 751 | CONFIG_PHYLIB=y | |
550 | # | 752 | |
551 | # PHY device support | 753 | # |
552 | # | 754 | # MII PHY device drivers |
553 | # CONFIG_PHYLIB is not set | 755 | # |
554 | 756 | # CONFIG_MARVELL_PHY is not set | |
555 | # | 757 | # CONFIG_DAVICOM_PHY is not set |
556 | # Ethernet (10 or 100Mbit) | 758 | # CONFIG_QSEMI_PHY is not set |
557 | # | 759 | # CONFIG_LXT_PHY is not set |
760 | # CONFIG_CICADA_PHY is not set | ||
761 | # CONFIG_VITESSE_PHY is not set | ||
762 | # CONFIG_SMSC_PHY is not set | ||
763 | # CONFIG_BROADCOM_PHY is not set | ||
764 | # CONFIG_ICPLUS_PHY is not set | ||
765 | # CONFIG_REALTEK_PHY is not set | ||
766 | # CONFIG_FIXED_PHY is not set | ||
767 | # CONFIG_MDIO_BITBANG is not set | ||
558 | CONFIG_NET_ETHERNET=y | 768 | CONFIG_NET_ETHERNET=y |
559 | CONFIG_MII=y | 769 | CONFIG_MII=y |
770 | # CONFIG_AX88796 is not set | ||
560 | # CONFIG_HAPPYMEAL is not set | 771 | # CONFIG_HAPPYMEAL is not set |
561 | # CONFIG_SUNGEM is not set | 772 | # CONFIG_SUNGEM is not set |
562 | # CONFIG_CASSINI is not set | 773 | # CONFIG_CASSINI is not set |
563 | # CONFIG_NET_VENDOR_3COM is not set | 774 | # CONFIG_NET_VENDOR_3COM is not set |
564 | # CONFIG_DM9000 is not set | 775 | # CONFIG_DM9000 is not set |
565 | |||
566 | # | ||
567 | # Tulip family network device support | ||
568 | # | ||
569 | # CONFIG_NET_TULIP is not set | 776 | # CONFIG_NET_TULIP is not set |
570 | # CONFIG_HP100 is not set | 777 | # CONFIG_HP100 is not set |
778 | # CONFIG_IBM_NEW_EMAC_ZMII is not set | ||
779 | # CONFIG_IBM_NEW_EMAC_RGMII is not set | ||
780 | # CONFIG_IBM_NEW_EMAC_TAH is not set | ||
781 | # CONFIG_IBM_NEW_EMAC_EMAC4 is not set | ||
571 | # CONFIG_NET_PCI is not set | 782 | # CONFIG_NET_PCI is not set |
572 | 783 | # CONFIG_B44 is not set | |
573 | # | 784 | CONFIG_NETDEV_1000=y |
574 | # Ethernet (1000 Mbit) | ||
575 | # | ||
576 | # CONFIG_ACENIC is not set | 785 | # CONFIG_ACENIC is not set |
577 | # CONFIG_DL2K is not set | 786 | # CONFIG_DL2K is not set |
578 | # CONFIG_E1000 is not set | 787 | # CONFIG_E1000 is not set |
788 | # CONFIG_E1000E is not set | ||
789 | # CONFIG_E1000E_ENABLED is not set | ||
790 | # CONFIG_IP1000 is not set | ||
791 | # CONFIG_IGB is not set | ||
579 | # CONFIG_NS83820 is not set | 792 | # CONFIG_NS83820 is not set |
580 | # CONFIG_HAMACHI is not set | 793 | # CONFIG_HAMACHI is not set |
581 | # CONFIG_YELLOWFIN is not set | 794 | # CONFIG_YELLOWFIN is not set |
@@ -585,52 +798,53 @@ CONFIG_SB1250_MAC=y | |||
585 | # CONFIG_SKGE is not set | 798 | # CONFIG_SKGE is not set |
586 | # CONFIG_SKY2 is not set | 799 | # CONFIG_SKY2 is not set |
587 | # CONFIG_SK98LIN is not set | 800 | # CONFIG_SK98LIN is not set |
801 | # CONFIG_VIA_VELOCITY is not set | ||
588 | # CONFIG_TIGON3 is not set | 802 | # CONFIG_TIGON3 is not set |
589 | # CONFIG_BNX2 is not set | 803 | # CONFIG_BNX2 is not set |
590 | # CONFIG_QLA3XXX is not set | 804 | # CONFIG_QLA3XXX is not set |
591 | # CONFIG_ATL1 is not set | 805 | # CONFIG_ATL1 is not set |
592 | 806 | CONFIG_NETDEV_10000=y | |
593 | # | ||
594 | # Ethernet (10000 Mbit) | ||
595 | # | ||
596 | # CONFIG_CHELSIO_T1 is not set | 807 | # CONFIG_CHELSIO_T1 is not set |
597 | CONFIG_CHELSIO_T3=m | 808 | CONFIG_CHELSIO_T3=m |
809 | # CONFIG_IXGBE is not set | ||
598 | # CONFIG_IXGB is not set | 810 | # CONFIG_IXGB is not set |
599 | # CONFIG_S2IO is not set | 811 | # CONFIG_S2IO is not set |
600 | # CONFIG_MYRI10GE is not set | 812 | # CONFIG_MYRI10GE is not set |
601 | CONFIG_NETXEN_NIC=m | 813 | CONFIG_NETXEN_NIC=m |
602 | 814 | # CONFIG_NIU is not set | |
603 | # | 815 | # CONFIG_MLX4_CORE is not set |
604 | # Token Ring devices | 816 | # CONFIG_TEHUTI is not set |
605 | # | 817 | # CONFIG_BNX2X is not set |
606 | # CONFIG_TR is not set | 818 | # CONFIG_TR is not set |
607 | 819 | ||
608 | # | 820 | # |
609 | # Wireless LAN (non-hamradio) | 821 | # Wireless LAN |
610 | # | ||
611 | # CONFIG_NET_RADIO is not set | ||
612 | |||
613 | # | ||
614 | # Wan interfaces | ||
615 | # | 822 | # |
823 | # CONFIG_WLAN_PRE80211 is not set | ||
824 | # CONFIG_WLAN_80211 is not set | ||
616 | # CONFIG_WAN is not set | 825 | # CONFIG_WAN is not set |
617 | # CONFIG_FDDI is not set | 826 | # CONFIG_FDDI is not set |
618 | # CONFIG_HIPPI is not set | 827 | # CONFIG_HIPPI is not set |
619 | # CONFIG_PPP is not set | 828 | CONFIG_PPP=m |
620 | # CONFIG_SLIP is not set | 829 | CONFIG_PPP_MULTILINK=y |
621 | # CONFIG_SHAPER is not set | 830 | CONFIG_PPP_FILTER=y |
831 | CONFIG_PPP_ASYNC=m | ||
832 | CONFIG_PPP_SYNC_TTY=m | ||
833 | CONFIG_PPP_DEFLATE=m | ||
834 | CONFIG_PPP_BSDCOMP=m | ||
835 | CONFIG_PPP_MPPE=m | ||
836 | CONFIG_PPPOE=m | ||
837 | CONFIG_PPPOL2TP=m | ||
838 | CONFIG_SLIP=m | ||
839 | CONFIG_SLIP_COMPRESSED=y | ||
840 | CONFIG_SLHC=m | ||
841 | CONFIG_SLIP_SMART=y | ||
842 | CONFIG_SLIP_MODE_SLIP6=y | ||
843 | # CONFIG_NET_FC is not set | ||
622 | # CONFIG_NETCONSOLE is not set | 844 | # CONFIG_NETCONSOLE is not set |
623 | # CONFIG_NETPOLL is not set | 845 | # CONFIG_NETPOLL is not set |
624 | # CONFIG_NET_POLL_CONTROLLER is not set | 846 | # CONFIG_NET_POLL_CONTROLLER is not set |
625 | |||
626 | # | ||
627 | # ISDN subsystem | ||
628 | # | ||
629 | # CONFIG_ISDN is not set | 847 | # CONFIG_ISDN is not set |
630 | |||
631 | # | ||
632 | # Telephony Support | ||
633 | # | ||
634 | # CONFIG_PHONE is not set | 848 | # CONFIG_PHONE is not set |
635 | 849 | ||
636 | # | 850 | # |
@@ -660,17 +874,16 @@ CONFIG_SERIAL_NONSTANDARD=y | |||
660 | # CONFIG_DIGIEPCA is not set | 874 | # CONFIG_DIGIEPCA is not set |
661 | # CONFIG_MOXA_INTELLIO is not set | 875 | # CONFIG_MOXA_INTELLIO is not set |
662 | # CONFIG_MOXA_SMARTIO is not set | 876 | # CONFIG_MOXA_SMARTIO is not set |
663 | CONFIG_MOXA_SMARTIO_NEW=m | ||
664 | # CONFIG_ISI is not set | 877 | # CONFIG_ISI is not set |
665 | # CONFIG_SYNCLINKMP is not set | 878 | # CONFIG_SYNCLINKMP is not set |
666 | # CONFIG_SYNCLINK_GT is not set | 879 | # CONFIG_SYNCLINK_GT is not set |
667 | # CONFIG_N_HDLC is not set | 880 | # CONFIG_N_HDLC is not set |
881 | # CONFIG_RISCOM8 is not set | ||
668 | # CONFIG_SPECIALIX is not set | 882 | # CONFIG_SPECIALIX is not set |
669 | # CONFIG_SX is not set | 883 | # CONFIG_SX is not set |
670 | # CONFIG_RIO is not set | 884 | # CONFIG_RIO is not set |
671 | # CONFIG_STALDRV is not set | 885 | # CONFIG_STALDRV is not set |
672 | CONFIG_SERIAL_SB1250_DUART=y | 886 | # CONFIG_NOZOMI is not set |
673 | CONFIG_SERIAL_SB1250_DUART_CONSOLE=y | ||
674 | 887 | ||
675 | # | 888 | # |
676 | # Serial drivers | 889 | # Serial drivers |
@@ -680,39 +893,24 @@ CONFIG_SERIAL_SB1250_DUART_CONSOLE=y | |||
680 | # | 893 | # |
681 | # Non-8250 serial port support | 894 | # Non-8250 serial port support |
682 | # | 895 | # |
896 | CONFIG_SERIAL_SB1250_DUART=y | ||
897 | CONFIG_SERIAL_SB1250_DUART_CONSOLE=y | ||
898 | CONFIG_SERIAL_CORE=y | ||
899 | CONFIG_SERIAL_CORE_CONSOLE=y | ||
683 | # CONFIG_SERIAL_JSM is not set | 900 | # CONFIG_SERIAL_JSM is not set |
684 | CONFIG_UNIX98_PTYS=y | 901 | CONFIG_UNIX98_PTYS=y |
685 | CONFIG_LEGACY_PTYS=y | 902 | CONFIG_LEGACY_PTYS=y |
686 | CONFIG_LEGACY_PTY_COUNT=256 | 903 | CONFIG_LEGACY_PTY_COUNT=256 |
687 | |||
688 | # | ||
689 | # IPMI | ||
690 | # | ||
691 | # CONFIG_IPMI_HANDLER is not set | 904 | # CONFIG_IPMI_HANDLER is not set |
692 | |||
693 | # | ||
694 | # Watchdog Cards | ||
695 | # | ||
696 | # CONFIG_WATCHDOG is not set | ||
697 | # CONFIG_HW_RANDOM is not set | 905 | # CONFIG_HW_RANDOM is not set |
698 | # CONFIG_RTC is not set | 906 | # CONFIG_RTC is not set |
699 | CONFIG_GEN_RTC=y | ||
700 | # CONFIG_GEN_RTC_X is not set | ||
701 | # CONFIG_DTLK is not set | ||
702 | # CONFIG_R3964 is not set | 907 | # CONFIG_R3964 is not set |
703 | # CONFIG_APPLICOM is not set | 908 | # CONFIG_APPLICOM is not set |
704 | # CONFIG_DRM is not set | ||
705 | # CONFIG_RAW_DRIVER is not set | 909 | # CONFIG_RAW_DRIVER is not set |
706 | |||
707 | # | ||
708 | # TPM devices | ||
709 | # | ||
710 | # CONFIG_TCG_TPM is not set | 910 | # CONFIG_TCG_TPM is not set |
711 | 911 | CONFIG_DEVPORT=y | |
712 | # | ||
713 | # I2C support | ||
714 | # | ||
715 | CONFIG_I2C=y | 912 | CONFIG_I2C=y |
913 | CONFIG_I2C_BOARDINFO=y | ||
716 | CONFIG_I2C_CHARDEV=y | 914 | CONFIG_I2C_CHARDEV=y |
717 | 915 | ||
718 | # | 916 | # |
@@ -736,29 +934,30 @@ CONFIG_I2C_CHARDEV=y | |||
736 | # CONFIG_I2C_NFORCE2 is not set | 934 | # CONFIG_I2C_NFORCE2 is not set |
737 | # CONFIG_I2C_OCORES is not set | 935 | # CONFIG_I2C_OCORES is not set |
738 | # CONFIG_I2C_PARPORT_LIGHT is not set | 936 | # CONFIG_I2C_PARPORT_LIGHT is not set |
739 | # CONFIG_I2C_PASEMI is not set | ||
740 | # CONFIG_I2C_PROSAVAGE is not set | 937 | # CONFIG_I2C_PROSAVAGE is not set |
741 | # CONFIG_I2C_SAVAGE4 is not set | 938 | # CONFIG_I2C_SAVAGE4 is not set |
742 | CONFIG_I2C_SIBYTE=y | 939 | CONFIG_I2C_SIBYTE=y |
940 | # CONFIG_I2C_SIMTEC is not set | ||
743 | # CONFIG_I2C_SIS5595 is not set | 941 | # CONFIG_I2C_SIS5595 is not set |
744 | # CONFIG_I2C_SIS630 is not set | 942 | # CONFIG_I2C_SIS630 is not set |
745 | # CONFIG_I2C_SIS96X is not set | 943 | # CONFIG_I2C_SIS96X is not set |
944 | # CONFIG_I2C_TAOS_EVM is not set | ||
746 | # CONFIG_I2C_STUB is not set | 945 | # CONFIG_I2C_STUB is not set |
747 | # CONFIG_I2C_VIA is not set | 946 | # CONFIG_I2C_VIA is not set |
748 | # CONFIG_I2C_VIAPRO is not set | 947 | # CONFIG_I2C_VIAPRO is not set |
749 | # CONFIG_I2C_VOODOO3 is not set | 948 | # CONFIG_I2C_VOODOO3 is not set |
750 | # CONFIG_I2C_PCA_ISA is not set | ||
751 | 949 | ||
752 | # | 950 | # |
753 | # Miscellaneous I2C Chip support | 951 | # Miscellaneous I2C Chip support |
754 | # | 952 | # |
755 | CONFIG_SENSORS_DS1337=y | 953 | # CONFIG_DS1682 is not set |
756 | CONFIG_SENSORS_DS1374=y | ||
757 | CONFIG_SENSORS_EEPROM=y | 954 | CONFIG_SENSORS_EEPROM=y |
758 | CONFIG_SENSORS_PCF8574=y | 955 | CONFIG_SENSORS_PCF8574=y |
759 | CONFIG_SENSORS_PCA9539=y | 956 | # CONFIG_PCF8575 is not set |
760 | CONFIG_SENSORS_PCF8591=y | 957 | CONFIG_SENSORS_PCF8591=y |
958 | # CONFIG_TPS65010 is not set | ||
761 | CONFIG_SENSORS_MAX6875=y | 959 | CONFIG_SENSORS_MAX6875=y |
960 | # CONFIG_SENSORS_TSL2550 is not set | ||
762 | CONFIG_I2C_DEBUG_CORE=y | 961 | CONFIG_I2C_DEBUG_CORE=y |
763 | CONFIG_I2C_DEBUG_ALGO=y | 962 | CONFIG_I2C_DEBUG_ALGO=y |
764 | CONFIG_I2C_DEBUG_BUS=y | 963 | CONFIG_I2C_DEBUG_BUS=y |
@@ -769,43 +968,49 @@ CONFIG_I2C_DEBUG_CHIP=y | |||
769 | # | 968 | # |
770 | # CONFIG_SPI is not set | 969 | # CONFIG_SPI is not set |
771 | # CONFIG_SPI_MASTER is not set | 970 | # CONFIG_SPI_MASTER is not set |
971 | # CONFIG_W1 is not set | ||
972 | # CONFIG_POWER_SUPPLY is not set | ||
973 | # CONFIG_HWMON is not set | ||
974 | # CONFIG_THERMAL is not set | ||
975 | # CONFIG_WATCHDOG is not set | ||
772 | 976 | ||
773 | # | 977 | # |
774 | # Dallas's 1-wire bus | 978 | # Sonics Silicon Backplane |
775 | # | 979 | # |
776 | # CONFIG_W1 is not set | 980 | CONFIG_SSB_POSSIBLE=y |
981 | # CONFIG_SSB is not set | ||
777 | 982 | ||
778 | # | 983 | # |
779 | # Hardware Monitoring support | 984 | # Multifunction device drivers |
780 | # | 985 | # |
781 | # CONFIG_HWMON is not set | 986 | # CONFIG_MFD_SM501 is not set |
782 | # CONFIG_HWMON_VID is not set | ||
783 | 987 | ||
784 | # | 988 | # |
785 | # Multimedia devices | 989 | # Multimedia devices |
786 | # | 990 | # |
787 | # CONFIG_VIDEO_DEV is not set | 991 | # CONFIG_VIDEO_DEV is not set |
788 | 992 | # CONFIG_DVB_CORE is not set | |
789 | # | 993 | # CONFIG_DAB is not set |
790 | # Digital Video Broadcasting Devices | ||
791 | # | ||
792 | # CONFIG_DVB is not set | ||
793 | 994 | ||
794 | # | 995 | # |
795 | # Graphics support | 996 | # Graphics support |
796 | # | 997 | # |
797 | # CONFIG_FIRMWARE_EDID is not set | 998 | # CONFIG_DRM is not set |
999 | # CONFIG_VGASTATE is not set | ||
1000 | # CONFIG_VIDEO_OUTPUT_CONTROL is not set | ||
798 | # CONFIG_FB is not set | 1001 | # CONFIG_FB is not set |
799 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set | 1002 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set |
800 | 1003 | ||
801 | # | 1004 | # |
802 | # Sound | 1005 | # Display device support |
803 | # | 1006 | # |
804 | # CONFIG_SOUND is not set | 1007 | # CONFIG_DISPLAY_SUPPORT is not set |
805 | 1008 | ||
806 | # | 1009 | # |
807 | # USB support | 1010 | # Sound |
808 | # | 1011 | # |
1012 | # CONFIG_SOUND is not set | ||
1013 | CONFIG_USB_SUPPORT=y | ||
809 | CONFIG_USB_ARCH_HAS_HCD=y | 1014 | CONFIG_USB_ARCH_HAS_HCD=y |
810 | CONFIG_USB_ARCH_HAS_OHCI=y | 1015 | CONFIG_USB_ARCH_HAS_OHCI=y |
811 | CONFIG_USB_ARCH_HAS_EHCI=y | 1016 | CONFIG_USB_ARCH_HAS_EHCI=y |
@@ -814,104 +1019,73 @@ CONFIG_USB_ARCH_HAS_EHCI=y | |||
814 | # | 1019 | # |
815 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' | 1020 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' |
816 | # | 1021 | # |
817 | |||
818 | # | ||
819 | # USB Gadget Support | ||
820 | # | ||
821 | # CONFIG_USB_GADGET is not set | 1022 | # CONFIG_USB_GADGET is not set |
822 | |||
823 | # | ||
824 | # MMC/SD Card support | ||
825 | # | ||
826 | # CONFIG_MMC is not set | 1023 | # CONFIG_MMC is not set |
827 | 1024 | # CONFIG_MEMSTICK is not set | |
828 | # | ||
829 | # LED devices | ||
830 | # | ||
831 | # CONFIG_NEW_LEDS is not set | 1025 | # CONFIG_NEW_LEDS is not set |
832 | |||
833 | # | ||
834 | # LED drivers | ||
835 | # | ||
836 | |||
837 | # | ||
838 | # LED Triggers | ||
839 | # | ||
840 | |||
841 | # | ||
842 | # InfiniBand support | ||
843 | # | ||
844 | # CONFIG_INFINIBAND is not set | 1026 | # CONFIG_INFINIBAND is not set |
845 | 1027 | CONFIG_RTC_LIB=y | |
846 | # | ||
847 | # EDAC - error detection and reporting (RAS) (EXPERIMENTAL) | ||
848 | # | ||
849 | |||
850 | # | ||
851 | # Real Time Clock | ||
852 | # | ||
853 | # CONFIG_RTC_CLASS is not set | 1028 | # CONFIG_RTC_CLASS is not set |
854 | 1029 | ||
855 | # | 1030 | # |
856 | # DMA Engine support | 1031 | # Userspace I/O |
857 | # | ||
858 | # CONFIG_DMA_ENGINE is not set | ||
859 | |||
860 | # | ||
861 | # DMA Clients | ||
862 | # | ||
863 | |||
864 | # | ||
865 | # DMA Devices | ||
866 | # | ||
867 | |||
868 | # | ||
869 | # Auxiliary Display support | ||
870 | # | ||
871 | |||
872 | # | ||
873 | # Virtualization | ||
874 | # | 1032 | # |
1033 | # CONFIG_UIO is not set | ||
875 | 1034 | ||
876 | # | 1035 | # |
877 | # File systems | 1036 | # File systems |
878 | # | 1037 | # |
879 | CONFIG_EXT2_FS=y | 1038 | CONFIG_EXT2_FS=m |
880 | CONFIG_EXT2_FS_XATTR=y | 1039 | CONFIG_EXT2_FS_XATTR=y |
881 | CONFIG_EXT2_FS_POSIX_ACL=y | 1040 | # CONFIG_EXT2_FS_POSIX_ACL is not set |
882 | CONFIG_EXT2_FS_SECURITY=y | 1041 | # CONFIG_EXT2_FS_SECURITY is not set |
883 | # CONFIG_EXT2_FS_XIP is not set | 1042 | # CONFIG_EXT2_FS_XIP is not set |
884 | # CONFIG_EXT3_FS is not set | 1043 | CONFIG_EXT3_FS=y |
1044 | CONFIG_EXT3_FS_XATTR=y | ||
1045 | # CONFIG_EXT3_FS_POSIX_ACL is not set | ||
1046 | # CONFIG_EXT3_FS_SECURITY is not set | ||
885 | # CONFIG_EXT4DEV_FS is not set | 1047 | # CONFIG_EXT4DEV_FS is not set |
1048 | CONFIG_JBD=y | ||
886 | CONFIG_FS_MBCACHE=y | 1049 | CONFIG_FS_MBCACHE=y |
887 | # CONFIG_REISERFS_FS is not set | 1050 | # CONFIG_REISERFS_FS is not set |
888 | # CONFIG_JFS_FS is not set | 1051 | # CONFIG_JFS_FS is not set |
889 | CONFIG_FS_POSIX_ACL=y | 1052 | # CONFIG_FS_POSIX_ACL is not set |
890 | # CONFIG_XFS_FS is not set | 1053 | # CONFIG_XFS_FS is not set |
891 | # CONFIG_GFS2_FS is not set | 1054 | # CONFIG_GFS2_FS is not set |
892 | # CONFIG_OCFS2_FS is not set | 1055 | # CONFIG_OCFS2_FS is not set |
893 | # CONFIG_MINIX_FS is not set | 1056 | CONFIG_DNOTIFY=y |
894 | # CONFIG_ROMFS_FS is not set | ||
895 | CONFIG_INOTIFY=y | 1057 | CONFIG_INOTIFY=y |
896 | CONFIG_INOTIFY_USER=y | 1058 | CONFIG_INOTIFY_USER=y |
897 | # CONFIG_QUOTA is not set | 1059 | CONFIG_QUOTA=y |
898 | CONFIG_DNOTIFY=y | 1060 | CONFIG_QUOTA_NETLINK_INTERFACE=y |
899 | # CONFIG_AUTOFS_FS is not set | 1061 | # CONFIG_PRINT_QUOTA_WARNING is not set |
900 | # CONFIG_AUTOFS4_FS is not set | 1062 | # CONFIG_QFMT_V1 is not set |
901 | # CONFIG_FUSE_FS is not set | 1063 | CONFIG_QFMT_V2=m |
1064 | CONFIG_QUOTACTL=y | ||
1065 | CONFIG_AUTOFS_FS=m | ||
1066 | CONFIG_AUTOFS4_FS=m | ||
1067 | CONFIG_FUSE_FS=m | ||
902 | 1068 | ||
903 | # | 1069 | # |
904 | # CD-ROM/DVD Filesystems | 1070 | # CD-ROM/DVD Filesystems |
905 | # | 1071 | # |
906 | # CONFIG_ISO9660_FS is not set | 1072 | CONFIG_ISO9660_FS=m |
907 | # CONFIG_UDF_FS is not set | 1073 | CONFIG_JOLIET=y |
1074 | CONFIG_ZISOFS=y | ||
1075 | CONFIG_UDF_FS=m | ||
1076 | CONFIG_UDF_NLS=y | ||
908 | 1077 | ||
909 | # | 1078 | # |
910 | # DOS/FAT/NT Filesystems | 1079 | # DOS/FAT/NT Filesystems |
911 | # | 1080 | # |
912 | # CONFIG_MSDOS_FS is not set | 1081 | CONFIG_FAT_FS=m |
913 | # CONFIG_VFAT_FS is not set | 1082 | CONFIG_MSDOS_FS=m |
914 | # CONFIG_NTFS_FS is not set | 1083 | CONFIG_VFAT_FS=m |
1084 | CONFIG_FAT_DEFAULT_CODEPAGE=437 | ||
1085 | CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" | ||
1086 | CONFIG_NTFS_FS=m | ||
1087 | # CONFIG_NTFS_DEBUG is not set | ||
1088 | CONFIG_NTFS_RW=y | ||
915 | 1089 | ||
916 | # | 1090 | # |
917 | # Pseudo filesystems | 1091 | # Pseudo filesystems |
@@ -923,7 +1097,6 @@ CONFIG_SYSFS=y | |||
923 | CONFIG_TMPFS=y | 1097 | CONFIG_TMPFS=y |
924 | # CONFIG_TMPFS_POSIX_ACL is not set | 1098 | # CONFIG_TMPFS_POSIX_ACL is not set |
925 | # CONFIG_HUGETLB_PAGE is not set | 1099 | # CONFIG_HUGETLB_PAGE is not set |
926 | CONFIG_RAMFS=y | ||
927 | CONFIG_CONFIGFS_FS=m | 1100 | CONFIG_CONFIGFS_FS=m |
928 | 1101 | ||
929 | # | 1102 | # |
@@ -939,14 +1112,13 @@ CONFIG_CONFIGFS_FS=m | |||
939 | # CONFIG_EFS_FS is not set | 1112 | # CONFIG_EFS_FS is not set |
940 | # CONFIG_CRAMFS is not set | 1113 | # CONFIG_CRAMFS is not set |
941 | # CONFIG_VXFS_FS is not set | 1114 | # CONFIG_VXFS_FS is not set |
1115 | # CONFIG_MINIX_FS is not set | ||
942 | # CONFIG_HPFS_FS is not set | 1116 | # CONFIG_HPFS_FS is not set |
943 | # CONFIG_QNX4FS_FS is not set | 1117 | # CONFIG_QNX4FS_FS is not set |
1118 | # CONFIG_ROMFS_FS is not set | ||
944 | # CONFIG_SYSV_FS is not set | 1119 | # CONFIG_SYSV_FS is not set |
945 | # CONFIG_UFS_FS is not set | 1120 | # CONFIG_UFS_FS is not set |
946 | 1121 | CONFIG_NETWORK_FILESYSTEMS=y | |
947 | # | ||
948 | # Network File Systems | ||
949 | # | ||
950 | CONFIG_NFS_FS=y | 1122 | CONFIG_NFS_FS=y |
951 | CONFIG_NFS_V3=y | 1123 | CONFIG_NFS_V3=y |
952 | # CONFIG_NFS_V3_ACL is not set | 1124 | # CONFIG_NFS_V3_ACL is not set |
@@ -958,6 +1130,7 @@ CONFIG_LOCKD=y | |||
958 | CONFIG_LOCKD_V4=y | 1130 | CONFIG_LOCKD_V4=y |
959 | CONFIG_NFS_COMMON=y | 1131 | CONFIG_NFS_COMMON=y |
960 | CONFIG_SUNRPC=y | 1132 | CONFIG_SUNRPC=y |
1133 | # CONFIG_SUNRPC_BIND34 is not set | ||
961 | # CONFIG_RPCSEC_GSS_KRB5 is not set | 1134 | # CONFIG_RPCSEC_GSS_KRB5 is not set |
962 | # CONFIG_RPCSEC_GSS_SPKM3 is not set | 1135 | # CONFIG_RPCSEC_GSS_SPKM3 is not set |
963 | # CONFIG_SMB_FS is not set | 1136 | # CONFIG_SMB_FS is not set |
@@ -965,37 +1138,61 @@ CONFIG_SUNRPC=y | |||
965 | # CONFIG_NCP_FS is not set | 1138 | # CONFIG_NCP_FS is not set |
966 | # CONFIG_CODA_FS is not set | 1139 | # CONFIG_CODA_FS is not set |
967 | # CONFIG_AFS_FS is not set | 1140 | # CONFIG_AFS_FS is not set |
968 | # CONFIG_9P_FS is not set | ||
969 | 1141 | ||
970 | # | 1142 | # |
971 | # Partition Types | 1143 | # Partition Types |
972 | # | 1144 | # |
973 | # CONFIG_PARTITION_ADVANCED is not set | 1145 | # CONFIG_PARTITION_ADVANCED is not set |
974 | CONFIG_MSDOS_PARTITION=y | 1146 | CONFIG_MSDOS_PARTITION=y |
975 | 1147 | CONFIG_NLS=m | |
976 | # | 1148 | CONFIG_NLS_DEFAULT="iso8859-1" |
977 | # Native Language Support | 1149 | CONFIG_NLS_CODEPAGE_437=m |
978 | # | 1150 | CONFIG_NLS_CODEPAGE_737=m |
979 | # CONFIG_NLS is not set | 1151 | CONFIG_NLS_CODEPAGE_775=m |
980 | 1152 | CONFIG_NLS_CODEPAGE_850=m | |
981 | # | 1153 | CONFIG_NLS_CODEPAGE_852=m |
982 | # Distributed Lock Manager | 1154 | CONFIG_NLS_CODEPAGE_855=m |
983 | # | 1155 | CONFIG_NLS_CODEPAGE_857=m |
1156 | CONFIG_NLS_CODEPAGE_860=m | ||
1157 | CONFIG_NLS_CODEPAGE_861=m | ||
1158 | CONFIG_NLS_CODEPAGE_862=m | ||
1159 | CONFIG_NLS_CODEPAGE_863=m | ||
1160 | CONFIG_NLS_CODEPAGE_864=m | ||
1161 | CONFIG_NLS_CODEPAGE_865=m | ||
1162 | CONFIG_NLS_CODEPAGE_866=m | ||
1163 | CONFIG_NLS_CODEPAGE_869=m | ||
1164 | CONFIG_NLS_CODEPAGE_936=m | ||
1165 | CONFIG_NLS_CODEPAGE_950=m | ||
1166 | CONFIG_NLS_CODEPAGE_932=m | ||
1167 | CONFIG_NLS_CODEPAGE_949=m | ||
1168 | CONFIG_NLS_CODEPAGE_874=m | ||
1169 | CONFIG_NLS_ISO8859_8=m | ||
1170 | CONFIG_NLS_CODEPAGE_1250=m | ||
1171 | CONFIG_NLS_CODEPAGE_1251=m | ||
1172 | CONFIG_NLS_ASCII=m | ||
1173 | CONFIG_NLS_ISO8859_1=m | ||
1174 | CONFIG_NLS_ISO8859_2=m | ||
1175 | CONFIG_NLS_ISO8859_3=m | ||
1176 | CONFIG_NLS_ISO8859_4=m | ||
1177 | CONFIG_NLS_ISO8859_5=m | ||
1178 | CONFIG_NLS_ISO8859_6=m | ||
1179 | CONFIG_NLS_ISO8859_7=m | ||
1180 | CONFIG_NLS_ISO8859_9=m | ||
1181 | CONFIG_NLS_ISO8859_13=m | ||
1182 | CONFIG_NLS_ISO8859_14=m | ||
1183 | CONFIG_NLS_ISO8859_15=m | ||
1184 | CONFIG_NLS_KOI8_R=m | ||
1185 | CONFIG_NLS_KOI8_U=m | ||
1186 | CONFIG_NLS_UTF8=m | ||
984 | CONFIG_DLM=m | 1187 | CONFIG_DLM=m |
985 | CONFIG_DLM_TCP=y | ||
986 | # CONFIG_DLM_SCTP is not set | ||
987 | # CONFIG_DLM_DEBUG is not set | 1188 | # CONFIG_DLM_DEBUG is not set |
988 | 1189 | ||
989 | # | 1190 | # |
990 | # Profiling support | ||
991 | # | ||
992 | # CONFIG_PROFILING is not set | ||
993 | |||
994 | # | ||
995 | # Kernel hacking | 1191 | # Kernel hacking |
996 | # | 1192 | # |
997 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | 1193 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y |
998 | # CONFIG_PRINTK_TIME is not set | 1194 | # CONFIG_PRINTK_TIME is not set |
1195 | CONFIG_ENABLE_WARN_DEPRECATED=y | ||
999 | CONFIG_ENABLE_MUST_CHECK=y | 1196 | CONFIG_ENABLE_MUST_CHECK=y |
1000 | CONFIG_MAGIC_SYSRQ=y | 1197 | CONFIG_MAGIC_SYSRQ=y |
1001 | # CONFIG_UNUSED_SYMBOLS is not set | 1198 | # CONFIG_UNUSED_SYMBOLS is not set |
@@ -1003,8 +1200,8 @@ CONFIG_MAGIC_SYSRQ=y | |||
1003 | # CONFIG_HEADERS_CHECK is not set | 1200 | # CONFIG_HEADERS_CHECK is not set |
1004 | CONFIG_DEBUG_KERNEL=y | 1201 | CONFIG_DEBUG_KERNEL=y |
1005 | # CONFIG_DEBUG_SHIRQ is not set | 1202 | # CONFIG_DEBUG_SHIRQ is not set |
1006 | CONFIG_LOG_BUF_SHIFT=16 | ||
1007 | CONFIG_DETECT_SOFTLOCKUP=y | 1203 | CONFIG_DETECT_SOFTLOCKUP=y |
1204 | CONFIG_SCHED_DEBUG=y | ||
1008 | # CONFIG_SCHEDSTATS is not set | 1205 | # CONFIG_SCHEDSTATS is not set |
1009 | # CONFIG_TIMER_STATS is not set | 1206 | # CONFIG_TIMER_STATS is not set |
1010 | # CONFIG_DEBUG_SLAB is not set | 1207 | # CONFIG_DEBUG_SLAB is not set |
@@ -1014,15 +1211,19 @@ CONFIG_DETECT_SOFTLOCKUP=y | |||
1014 | CONFIG_DEBUG_MUTEXES=y | 1211 | CONFIG_DEBUG_MUTEXES=y |
1015 | # CONFIG_DEBUG_LOCK_ALLOC is not set | 1212 | # CONFIG_DEBUG_LOCK_ALLOC is not set |
1016 | # CONFIG_PROVE_LOCKING is not set | 1213 | # CONFIG_PROVE_LOCKING is not set |
1214 | # CONFIG_LOCK_STAT is not set | ||
1017 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set | 1215 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set |
1018 | # CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set | 1216 | # CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set |
1019 | # CONFIG_DEBUG_KOBJECT is not set | 1217 | # CONFIG_DEBUG_KOBJECT is not set |
1020 | # CONFIG_DEBUG_INFO is not set | 1218 | # CONFIG_DEBUG_INFO is not set |
1021 | # CONFIG_DEBUG_VM is not set | 1219 | # CONFIG_DEBUG_VM is not set |
1022 | # CONFIG_DEBUG_LIST is not set | 1220 | # CONFIG_DEBUG_LIST is not set |
1023 | CONFIG_FORCED_INLINING=y | 1221 | # CONFIG_DEBUG_SG is not set |
1222 | # CONFIG_BOOT_PRINTK_DELAY is not set | ||
1024 | # CONFIG_RCU_TORTURE_TEST is not set | 1223 | # CONFIG_RCU_TORTURE_TEST is not set |
1025 | CONFIG_CROSSCOMPILE=y | 1224 | # CONFIG_BACKTRACE_SELF_TEST is not set |
1225 | # CONFIG_FAULT_INJECTION is not set | ||
1226 | # CONFIG_SAMPLES is not set | ||
1026 | CONFIG_CMDLINE="" | 1227 | CONFIG_CMDLINE="" |
1027 | # CONFIG_DEBUG_STACK_USAGE is not set | 1228 | # CONFIG_DEBUG_STACK_USAGE is not set |
1028 | # CONFIG_SB1XXX_CORELIS is not set | 1229 | # CONFIG_SB1XXX_CORELIS is not set |
@@ -1034,23 +1235,22 @@ CONFIG_CMDLINE="" | |||
1034 | CONFIG_KEYS=y | 1235 | CONFIG_KEYS=y |
1035 | CONFIG_KEYS_DEBUG_PROC_KEYS=y | 1236 | CONFIG_KEYS_DEBUG_PROC_KEYS=y |
1036 | # CONFIG_SECURITY is not set | 1237 | # CONFIG_SECURITY is not set |
1037 | 1238 | # CONFIG_SECURITY_FILE_CAPABILITIES is not set | |
1038 | # | ||
1039 | # Cryptographic options | ||
1040 | # | ||
1041 | CONFIG_CRYPTO=y | 1239 | CONFIG_CRYPTO=y |
1042 | CONFIG_CRYPTO_ALGAPI=y | 1240 | CONFIG_CRYPTO_ALGAPI=y |
1043 | CONFIG_CRYPTO_BLKCIPHER=m | 1241 | CONFIG_CRYPTO_AEAD=m |
1242 | CONFIG_CRYPTO_BLKCIPHER=y | ||
1243 | CONFIG_CRYPTO_SEQIV=m | ||
1044 | CONFIG_CRYPTO_HASH=y | 1244 | CONFIG_CRYPTO_HASH=y |
1045 | CONFIG_CRYPTO_MANAGER=y | 1245 | CONFIG_CRYPTO_MANAGER=y |
1046 | CONFIG_CRYPTO_HMAC=y | 1246 | CONFIG_CRYPTO_HMAC=y |
1047 | CONFIG_CRYPTO_XCBC=m | 1247 | CONFIG_CRYPTO_XCBC=m |
1048 | CONFIG_CRYPTO_NULL=y | 1248 | CONFIG_CRYPTO_NULL=y |
1049 | CONFIG_CRYPTO_MD4=y | 1249 | CONFIG_CRYPTO_MD4=m |
1050 | CONFIG_CRYPTO_MD5=y | 1250 | CONFIG_CRYPTO_MD5=y |
1051 | CONFIG_CRYPTO_SHA1=y | 1251 | CONFIG_CRYPTO_SHA1=m |
1052 | CONFIG_CRYPTO_SHA256=y | 1252 | CONFIG_CRYPTO_SHA256=m |
1053 | CONFIG_CRYPTO_SHA512=y | 1253 | CONFIG_CRYPTO_SHA512=m |
1054 | CONFIG_CRYPTO_WP512=m | 1254 | CONFIG_CRYPTO_WP512=m |
1055 | CONFIG_CRYPTO_TGR192=m | 1255 | CONFIG_CRYPTO_TGR192=m |
1056 | CONFIG_CRYPTO_GF128MUL=m | 1256 | CONFIG_CRYPTO_GF128MUL=m |
@@ -1058,39 +1258,50 @@ CONFIG_CRYPTO_ECB=m | |||
1058 | CONFIG_CRYPTO_CBC=m | 1258 | CONFIG_CRYPTO_CBC=m |
1059 | CONFIG_CRYPTO_PCBC=m | 1259 | CONFIG_CRYPTO_PCBC=m |
1060 | CONFIG_CRYPTO_LRW=m | 1260 | CONFIG_CRYPTO_LRW=m |
1061 | CONFIG_CRYPTO_DES=y | 1261 | CONFIG_CRYPTO_XTS=m |
1262 | CONFIG_CRYPTO_CTR=m | ||
1263 | CONFIG_CRYPTO_GCM=m | ||
1264 | CONFIG_CRYPTO_CCM=m | ||
1265 | # CONFIG_CRYPTO_CRYPTD is not set | ||
1266 | CONFIG_CRYPTO_DES=m | ||
1062 | CONFIG_CRYPTO_FCRYPT=m | 1267 | CONFIG_CRYPTO_FCRYPT=m |
1063 | CONFIG_CRYPTO_BLOWFISH=y | 1268 | CONFIG_CRYPTO_BLOWFISH=m |
1064 | CONFIG_CRYPTO_TWOFISH=y | 1269 | CONFIG_CRYPTO_TWOFISH=m |
1065 | CONFIG_CRYPTO_TWOFISH_COMMON=y | 1270 | CONFIG_CRYPTO_TWOFISH_COMMON=m |
1066 | CONFIG_CRYPTO_SERPENT=y | 1271 | CONFIG_CRYPTO_SERPENT=m |
1067 | CONFIG_CRYPTO_AES=m | 1272 | CONFIG_CRYPTO_AES=m |
1068 | # CONFIG_CRYPTO_CAST5 is not set | 1273 | CONFIG_CRYPTO_CAST5=m |
1069 | # CONFIG_CRYPTO_CAST6 is not set | 1274 | CONFIG_CRYPTO_CAST6=m |
1070 | CONFIG_CRYPTO_TEA=m | 1275 | CONFIG_CRYPTO_TEA=m |
1071 | # CONFIG_CRYPTO_ARC4 is not set | 1276 | CONFIG_CRYPTO_ARC4=m |
1072 | CONFIG_CRYPTO_KHAZAD=m | 1277 | CONFIG_CRYPTO_KHAZAD=m |
1073 | CONFIG_CRYPTO_ANUBIS=m | 1278 | CONFIG_CRYPTO_ANUBIS=m |
1074 | CONFIG_CRYPTO_DEFLATE=y | 1279 | CONFIG_CRYPTO_SEED=m |
1075 | CONFIG_CRYPTO_MICHAEL_MIC=y | 1280 | CONFIG_CRYPTO_SALSA20=m |
1281 | CONFIG_CRYPTO_DEFLATE=m | ||
1282 | CONFIG_CRYPTO_MICHAEL_MIC=m | ||
1076 | # CONFIG_CRYPTO_CRC32C is not set | 1283 | # CONFIG_CRYPTO_CRC32C is not set |
1077 | CONFIG_CRYPTO_CAMELLIA=m | 1284 | CONFIG_CRYPTO_CAMELLIA=m |
1078 | # CONFIG_CRYPTO_TEST is not set | 1285 | # CONFIG_CRYPTO_TEST is not set |
1079 | 1286 | CONFIG_CRYPTO_AUTHENC=m | |
1080 | # | 1287 | # CONFIG_CRYPTO_LZO is not set |
1081 | # Hardware crypto devices | 1288 | CONFIG_CRYPTO_HW=y |
1082 | # | 1289 | # CONFIG_CRYPTO_DEV_HIFN_795X is not set |
1083 | 1290 | ||
1084 | # | 1291 | # |
1085 | # Library routines | 1292 | # Library routines |
1086 | # | 1293 | # |
1087 | CONFIG_BITREVERSE=y | 1294 | CONFIG_BITREVERSE=y |
1088 | # CONFIG_CRC_CCITT is not set | 1295 | CONFIG_CRC_CCITT=m |
1089 | # CONFIG_CRC16 is not set | 1296 | # CONFIG_CRC16 is not set |
1297 | # CONFIG_CRC_ITU_T is not set | ||
1090 | CONFIG_CRC32=y | 1298 | CONFIG_CRC32=y |
1091 | # CONFIG_LIBCRC32C is not set | 1299 | # CONFIG_CRC7 is not set |
1092 | CONFIG_ZLIB_INFLATE=y | 1300 | CONFIG_LIBCRC32C=m |
1093 | CONFIG_ZLIB_DEFLATE=y | 1301 | CONFIG_AUDIT_GENERIC=y |
1302 | CONFIG_ZLIB_INFLATE=m | ||
1303 | CONFIG_ZLIB_DEFLATE=m | ||
1094 | CONFIG_PLIST=y | 1304 | CONFIG_PLIST=y |
1095 | CONFIG_HAS_IOMEM=y | 1305 | CONFIG_HAS_IOMEM=y |
1096 | CONFIG_HAS_IOPORT=y | 1306 | CONFIG_HAS_IOPORT=y |
1307 | CONFIG_HAS_DMA=y | ||
diff --git a/arch/mips/kernel/i8253.c b/arch/mips/kernel/i8253.c index fc4aa07b6d35..38fa1a194bf4 100644 --- a/arch/mips/kernel/i8253.c +++ b/arch/mips/kernel/i8253.c | |||
@@ -15,6 +15,7 @@ | |||
15 | #include <asm/time.h> | 15 | #include <asm/time.h> |
16 | 16 | ||
17 | DEFINE_SPINLOCK(i8253_lock); | 17 | DEFINE_SPINLOCK(i8253_lock); |
18 | EXPORT_SYMBOL(i8253_lock); | ||
18 | 19 | ||
19 | /* | 20 | /* |
20 | * Initialize the PIT timer. | 21 | * Initialize the PIT timer. |
diff --git a/arch/mips/kernel/time.c b/arch/mips/kernel/time.c index 9f85d4cecc5b..b45a7093ca2d 100644 --- a/arch/mips/kernel/time.c +++ b/arch/mips/kernel/time.c | |||
@@ -157,6 +157,6 @@ void __init time_init(void) | |||
157 | { | 157 | { |
158 | plat_time_init(); | 158 | plat_time_init(); |
159 | 159 | ||
160 | if (mips_clockevent_init() || !cpu_has_mfc0_count_bug()) | 160 | if (!mips_clockevent_init() || !cpu_has_mfc0_count_bug()) |
161 | init_mips_clocksource(); | 161 | init_mips_clocksource(); |
162 | } | 162 | } |
diff --git a/arch/mips/kernel/vpe.c b/arch/mips/kernel/vpe.c index eed2dc4273e0..39804c584edd 100644 --- a/arch/mips/kernel/vpe.c +++ b/arch/mips/kernel/vpe.c | |||
@@ -262,13 +262,21 @@ void dump_mtregs(void) | |||
262 | /* Find some VPE program space */ | 262 | /* Find some VPE program space */ |
263 | static void *alloc_progmem(unsigned long len) | 263 | static void *alloc_progmem(unsigned long len) |
264 | { | 264 | { |
265 | void *addr; | ||
266 | |||
265 | #ifdef CONFIG_MIPS_VPE_LOADER_TOM | 267 | #ifdef CONFIG_MIPS_VPE_LOADER_TOM |
266 | /* this means you must tell linux to use less memory than you physically have */ | 268 | /* |
267 | return pfn_to_kaddr(max_pfn); | 269 | * This means you must tell Linux to use less memory than you |
270 | * physically have, for example by passing a mem= boot argument. | ||
271 | */ | ||
272 | addr = pfn_to_kaddr(max_pfn); | ||
273 | memset(addr, 0, len); | ||
268 | #else | 274 | #else |
269 | // simple grab some mem for now | 275 | /* simple grab some mem for now */ |
270 | return kmalloc(len, GFP_KERNEL); | 276 | addr = kzalloc(len, GFP_KERNEL); |
271 | #endif | 277 | #endif |
278 | |||
279 | return addr; | ||
272 | } | 280 | } |
273 | 281 | ||
274 | static void release_progmem(void *ptr) | 282 | static void release_progmem(void *ptr) |
@@ -884,9 +892,10 @@ static int vpe_elfload(struct vpe * v) | |||
884 | } | 892 | } |
885 | 893 | ||
886 | v->load_addr = alloc_progmem(mod.core_size); | 894 | v->load_addr = alloc_progmem(mod.core_size); |
887 | memset(v->load_addr, 0, mod.core_size); | 895 | if (!v->load_addr) |
896 | return -ENOMEM; | ||
888 | 897 | ||
889 | printk("VPE loader: loading to %p\n", v->load_addr); | 898 | pr_info("VPE loader: loading to %p\n", v->load_addr); |
890 | 899 | ||
891 | if (relocate) { | 900 | if (relocate) { |
892 | for (i = 0; i < hdr->e_shnum; i++) { | 901 | for (i = 0; i < hdr->e_shnum; i++) { |
diff --git a/arch/mips/mm/tlbex.c b/arch/mips/mm/tlbex.c index 3a93d4ce2703..382738ca8a0b 100644 --- a/arch/mips/mm/tlbex.c +++ b/arch/mips/mm/tlbex.c | |||
@@ -307,6 +307,7 @@ static void __cpuinit build_tlb_write_entry(u32 **p, struct uasm_label **l, | |||
307 | case CPU_R12000: | 307 | case CPU_R12000: |
308 | case CPU_R14000: | 308 | case CPU_R14000: |
309 | case CPU_4KC: | 309 | case CPU_4KC: |
310 | case CPU_4KEC: | ||
310 | case CPU_SB1: | 311 | case CPU_SB1: |
311 | case CPU_SB1A: | 312 | case CPU_SB1A: |
312 | case CPU_4KSC: | 313 | case CPU_4KSC: |
diff --git a/arch/mips/pci/pci-bcm1480.c b/arch/mips/pci/pci-bcm1480.c index ab68c4318a30..87e2c8f54e2d 100644 --- a/arch/mips/pci/pci-bcm1480.c +++ b/arch/mips/pci/pci-bcm1480.c | |||
@@ -185,8 +185,8 @@ static struct resource bcm1480_mem_resource = { | |||
185 | 185 | ||
186 | static struct resource bcm1480_io_resource = { | 186 | static struct resource bcm1480_io_resource = { |
187 | .name = "BCM1480 PCI I/O", | 187 | .name = "BCM1480 PCI I/O", |
188 | .start = 0x2c000000UL, | 188 | .start = A_BCM1480_PHYS_PCI_IO_MATCH_BYTES, |
189 | .end = 0x2dffffffUL, | 189 | .end = A_BCM1480_PHYS_PCI_IO_MATCH_BYTES + 0x1ffffffUL, |
190 | .flags = IORESOURCE_IO, | 190 | .flags = IORESOURCE_IO, |
191 | }; | 191 | }; |
192 | 192 | ||
@@ -194,6 +194,7 @@ struct pci_controller bcm1480_controller = { | |||
194 | .pci_ops = &bcm1480_pci_ops, | 194 | .pci_ops = &bcm1480_pci_ops, |
195 | .mem_resource = &bcm1480_mem_resource, | 195 | .mem_resource = &bcm1480_mem_resource, |
196 | .io_resource = &bcm1480_io_resource, | 196 | .io_resource = &bcm1480_io_resource, |
197 | .io_offset = A_BCM1480_PHYS_PCI_IO_MATCH_BYTES, | ||
197 | }; | 198 | }; |
198 | 199 | ||
199 | 200 | ||
@@ -251,6 +252,7 @@ static int __init bcm1480_pcibios_init(void) | |||
251 | 252 | ||
252 | bcm1480_controller.io_map_base = (unsigned long) | 253 | bcm1480_controller.io_map_base = (unsigned long) |
253 | ioremap(A_BCM1480_PHYS_PCI_IO_MATCH_BYTES, 65536); | 254 | ioremap(A_BCM1480_PHYS_PCI_IO_MATCH_BYTES, 65536); |
255 | bcm1480_controller.io_map_base -= bcm1480_controller.io_offset; | ||
254 | set_io_port_base(bcm1480_controller.io_map_base); | 256 | set_io_port_base(bcm1480_controller.io_map_base); |
255 | isa_slot_offset = (unsigned long) | 257 | isa_slot_offset = (unsigned long) |
256 | ioremap(A_BCM1480_PHYS_PCI_MEM_MATCH_BYTES, 1024*1024); | 258 | ioremap(A_BCM1480_PHYS_PCI_MEM_MATCH_BYTES, 1024*1024); |
diff --git a/arch/mips/pci/pci-bcm1480ht.c b/arch/mips/pci/pci-bcm1480ht.c index 005e7fecab08..f54f45412b0b 100644 --- a/arch/mips/pci/pci-bcm1480ht.c +++ b/arch/mips/pci/pci-bcm1480ht.c | |||
@@ -180,8 +180,8 @@ static struct resource bcm1480ht_mem_resource = { | |||
180 | 180 | ||
181 | static struct resource bcm1480ht_io_resource = { | 181 | static struct resource bcm1480ht_io_resource = { |
182 | .name = "BCM1480 HT I/O", | 182 | .name = "BCM1480 HT I/O", |
183 | .start = 0x00000000UL, | 183 | .start = A_BCM1480_PHYS_HT_IO_MATCH_BYTES, |
184 | .end = 0x01ffffffUL, | 184 | .end = A_BCM1480_PHYS_HT_IO_MATCH_BYTES + 0x01ffffffUL, |
185 | .flags = IORESOURCE_IO, | 185 | .flags = IORESOURCE_IO, |
186 | }; | 186 | }; |
187 | 187 | ||
@@ -191,29 +191,22 @@ struct pci_controller bcm1480ht_controller = { | |||
191 | .io_resource = &bcm1480ht_io_resource, | 191 | .io_resource = &bcm1480ht_io_resource, |
192 | .index = 1, | 192 | .index = 1, |
193 | .get_busno = bcm1480ht_pcibios_get_busno, | 193 | .get_busno = bcm1480ht_pcibios_get_busno, |
194 | .io_offset = A_BCM1480_PHYS_HT_IO_MATCH_BYTES, | ||
194 | }; | 195 | }; |
195 | 196 | ||
196 | static int __init bcm1480ht_pcibios_init(void) | 197 | static int __init bcm1480ht_pcibios_init(void) |
197 | { | 198 | { |
198 | uint32_t cmdreg; | ||
199 | |||
200 | ht_cfg_space = ioremap(A_BCM1480_PHYS_HT_CFG_MATCH_BITS, 16*1024*1024); | 199 | ht_cfg_space = ioremap(A_BCM1480_PHYS_HT_CFG_MATCH_BITS, 16*1024*1024); |
201 | 200 | ||
202 | /* | 201 | /* CFE doesn't always init all HT paths, so we always scan */ |
203 | * See if the PCI bus has been configured by the firmware. | ||
204 | */ | ||
205 | cmdreg = READCFG32(CFGOFFSET(0, PCI_DEVFN(PCI_BRIDGE_DEVICE, 0), | ||
206 | PCI_COMMAND)); | ||
207 | if (!(cmdreg & PCI_COMMAND_MASTER)) { | ||
208 | printk("HT: Skipping HT probe. Bus is not initialized.\n"); | ||
209 | iounmap(ht_cfg_space); | ||
210 | return 1; /* XXX */ | ||
211 | } | ||
212 | bcm1480ht_bus_status |= PCI_BUS_ENABLED; | 202 | bcm1480ht_bus_status |= PCI_BUS_ENABLED; |
213 | 203 | ||
214 | ht_eoi_space = (unsigned long) | 204 | ht_eoi_space = (unsigned long) |
215 | ioremap(A_BCM1480_PHYS_HT_SPECIAL_MATCH_BYTES, | 205 | ioremap(A_BCM1480_PHYS_HT_SPECIAL_MATCH_BYTES, |
216 | 4 * 1024 * 1024); | 206 | 4 * 1024 * 1024); |
207 | bcm1480ht_controller.io_map_base = (unsigned long) | ||
208 | ioremap(A_BCM1480_PHYS_HT_IO_MATCH_BYTES, 65536); | ||
209 | bcm1480ht_controller.io_map_base -= bcm1480ht_controller.io_offset; | ||
217 | 210 | ||
218 | register_pci_controller(&bcm1480ht_controller); | 211 | register_pci_controller(&bcm1480ht_controller); |
219 | 212 | ||
diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index 12720489e458..8d2cd1de5726 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig | |||
@@ -72,9 +72,6 @@ config SYS_SUPPORTS_NUMA | |||
72 | config SYS_SUPPORTS_PCI | 72 | config SYS_SUPPORTS_PCI |
73 | bool | 73 | bool |
74 | 74 | ||
75 | config ARCH_MAY_HAVE_PC_FDC | ||
76 | bool | ||
77 | |||
78 | config STACKTRACE_SUPPORT | 75 | config STACKTRACE_SUPPORT |
79 | def_bool y | 76 | def_bool y |
80 | 77 | ||
diff --git a/arch/sh/boot/Makefile b/arch/sh/boot/Makefile index 3dda24daa0a8..89b408620dcb 100644 --- a/arch/sh/boot/Makefile +++ b/arch/sh/boot/Makefile | |||
@@ -44,7 +44,7 @@ KERNEL_ENTRY := $(shell /bin/bash -c 'printf "0x%08x" \ | |||
44 | 44 | ||
45 | quiet_cmd_uimage = UIMAGE $@ | 45 | quiet_cmd_uimage = UIMAGE $@ |
46 | cmd_uimage = $(CONFIG_SHELL) $(MKIMAGE) -A sh -O linux -T kernel \ | 46 | cmd_uimage = $(CONFIG_SHELL) $(MKIMAGE) -A sh -O linux -T kernel \ |
47 | -C none -a $(KERNEL_LOAD) -e $(KERNEL_ENTRY) \ | 47 | -C gzip -a $(KERNEL_LOAD) -e $(KERNEL_ENTRY) \ |
48 | -n 'Linux-$(KERNELRELEASE)' -d $< $@ | 48 | -n 'Linux-$(KERNELRELEASE)' -d $< $@ |
49 | 49 | ||
50 | $(obj)/uImage: $(obj)/vmlinux.bin.gz FORCE | 50 | $(obj)/uImage: $(obj)/vmlinux.bin.gz FORCE |
diff --git a/arch/sh/kernel/cpu/sh2a/fpu.c b/arch/sh/kernel/cpu/sh2a/fpu.c index ff99562456fb..5627c0b3ffa8 100644 --- a/arch/sh/kernel/cpu/sh2a/fpu.c +++ b/arch/sh/kernel/cpu/sh2a/fpu.c | |||
@@ -13,6 +13,7 @@ | |||
13 | #include <linux/signal.h> | 13 | #include <linux/signal.h> |
14 | #include <asm/processor.h> | 14 | #include <asm/processor.h> |
15 | #include <asm/io.h> | 15 | #include <asm/io.h> |
16 | #include <asm/fpu.h> | ||
16 | 17 | ||
17 | /* The PR (precision) bit in the FP Status Register must be clear when | 18 | /* The PR (precision) bit in the FP Status Register must be clear when |
18 | * an frchg instruction is executed, otherwise the instruction is undefined. | 19 | * an frchg instruction is executed, otherwise the instruction is undefined. |
diff --git a/arch/sh/kernel/cpu/sh4/fpu.c b/arch/sh/kernel/cpu/sh4/fpu.c index 817f9939cda6..8020796139f1 100644 --- a/arch/sh/kernel/cpu/sh4/fpu.c +++ b/arch/sh/kernel/cpu/sh4/fpu.c | |||
@@ -16,6 +16,7 @@ | |||
16 | #include <asm/cpu/fpu.h> | 16 | #include <asm/cpu/fpu.h> |
17 | #include <asm/processor.h> | 17 | #include <asm/processor.h> |
18 | #include <asm/system.h> | 18 | #include <asm/system.h> |
19 | #include <asm/fpu.h> | ||
19 | 20 | ||
20 | /* The PR (precision) bit in the FP Status Register must be clear when | 21 | /* The PR (precision) bit in the FP Status Register must be clear when |
21 | * an frchg instruction is executed, otherwise the instruction is undefined. | 22 | * an frchg instruction is executed, otherwise the instruction is undefined. |
diff --git a/arch/sh/kernel/cpu/sh5/fpu.c b/arch/sh/kernel/cpu/sh5/fpu.c index 30b76a94abf2..dd4f51ffb50e 100644 --- a/arch/sh/kernel/cpu/sh5/fpu.c +++ b/arch/sh/kernel/cpu/sh5/fpu.c | |||
@@ -17,6 +17,7 @@ | |||
17 | #include <asm/processor.h> | 17 | #include <asm/processor.h> |
18 | #include <asm/user.h> | 18 | #include <asm/user.h> |
19 | #include <asm/io.h> | 19 | #include <asm/io.h> |
20 | #include <asm/fpu.h> | ||
20 | 21 | ||
21 | /* | 22 | /* |
22 | * Initially load the FPU with signalling NANS. This bit pattern | 23 | * Initially load the FPU with signalling NANS. This bit pattern |
diff --git a/arch/sh/kernel/dump_task.c b/arch/sh/kernel/dump_task.c index 4a8a4083ff0b..1db7ce0f25d4 100644 --- a/arch/sh/kernel/dump_task.c +++ b/arch/sh/kernel/dump_task.c | |||
@@ -1,5 +1,6 @@ | |||
1 | #include <linux/elfcore.h> | 1 | #include <linux/elfcore.h> |
2 | #include <linux/sched.h> | 2 | #include <linux/sched.h> |
3 | #include <asm/fpu.h> | ||
3 | 4 | ||
4 | /* | 5 | /* |
5 | * Capture the user space registers if the task is not running (in user space) | 6 | * Capture the user space registers if the task is not running (in user space) |
diff --git a/arch/sh/kernel/process_32.c b/arch/sh/kernel/process_32.c index 9ab1926b9d10..b98e37a1f54c 100644 --- a/arch/sh/kernel/process_32.c +++ b/arch/sh/kernel/process_32.c | |||
@@ -25,6 +25,7 @@ | |||
25 | #include <asm/pgalloc.h> | 25 | #include <asm/pgalloc.h> |
26 | #include <asm/system.h> | 26 | #include <asm/system.h> |
27 | #include <asm/ubc.h> | 27 | #include <asm/ubc.h> |
28 | #include <asm/fpu.h> | ||
28 | 29 | ||
29 | static int hlt_counter; | 30 | static int hlt_counter; |
30 | int ubc_usercnt = 0; | 31 | int ubc_usercnt = 0; |
diff --git a/arch/sh/kernel/signal_32.c b/arch/sh/kernel/signal_32.c index f6b5fbfe75c4..f311551d9a05 100644 --- a/arch/sh/kernel/signal_32.c +++ b/arch/sh/kernel/signal_32.c | |||
@@ -29,6 +29,7 @@ | |||
29 | #include <asm/uaccess.h> | 29 | #include <asm/uaccess.h> |
30 | #include <asm/pgtable.h> | 30 | #include <asm/pgtable.h> |
31 | #include <asm/cacheflush.h> | 31 | #include <asm/cacheflush.h> |
32 | #include <asm/fpu.h> | ||
32 | 33 | ||
33 | #define _BLOCKABLE (~(sigmask(SIGKILL) | sigmask(SIGSTOP))) | 34 | #define _BLOCKABLE (~(sigmask(SIGKILL) | sigmask(SIGSTOP))) |
34 | 35 | ||
diff --git a/arch/sparc64/kernel/iommu.c b/arch/sparc64/kernel/iommu.c index b781d3d54fb8..756fa24eeefa 100644 --- a/arch/sparc64/kernel/iommu.c +++ b/arch/sparc64/kernel/iommu.c | |||
@@ -516,9 +516,11 @@ static int dma_4u_map_sg(struct device *dev, struct scatterlist *sglist, | |||
516 | unsigned long flags, handle, prot, ctx; | 516 | unsigned long flags, handle, prot, ctx; |
517 | dma_addr_t dma_next = 0, dma_addr; | 517 | dma_addr_t dma_next = 0, dma_addr; |
518 | unsigned int max_seg_size; | 518 | unsigned int max_seg_size; |
519 | unsigned long seg_boundary_size; | ||
519 | int outcount, incount, i; | 520 | int outcount, incount, i; |
520 | struct strbuf *strbuf; | 521 | struct strbuf *strbuf; |
521 | struct iommu *iommu; | 522 | struct iommu *iommu; |
523 | unsigned long base_shift; | ||
522 | 524 | ||
523 | BUG_ON(direction == DMA_NONE); | 525 | BUG_ON(direction == DMA_NONE); |
524 | 526 | ||
@@ -549,8 +551,11 @@ static int dma_4u_map_sg(struct device *dev, struct scatterlist *sglist, | |||
549 | outs->dma_length = 0; | 551 | outs->dma_length = 0; |
550 | 552 | ||
551 | max_seg_size = dma_get_max_seg_size(dev); | 553 | max_seg_size = dma_get_max_seg_size(dev); |
554 | seg_boundary_size = ALIGN(dma_get_seg_boundary(dev) + 1, | ||
555 | IO_PAGE_SIZE) >> IO_PAGE_SHIFT; | ||
556 | base_shift = iommu->page_table_map_base >> IO_PAGE_SHIFT; | ||
552 | for_each_sg(sglist, s, nelems, i) { | 557 | for_each_sg(sglist, s, nelems, i) { |
553 | unsigned long paddr, npages, entry, slen; | 558 | unsigned long paddr, npages, entry, out_entry = 0, slen; |
554 | iopte_t *base; | 559 | iopte_t *base; |
555 | 560 | ||
556 | slen = s->length; | 561 | slen = s->length; |
@@ -593,7 +598,9 @@ static int dma_4u_map_sg(struct device *dev, struct scatterlist *sglist, | |||
593 | * - allocated dma_addr isn't contiguous to previous allocation | 598 | * - allocated dma_addr isn't contiguous to previous allocation |
594 | */ | 599 | */ |
595 | if ((dma_addr != dma_next) || | 600 | if ((dma_addr != dma_next) || |
596 | (outs->dma_length + s->length > max_seg_size)) { | 601 | (outs->dma_length + s->length > max_seg_size) || |
602 | (is_span_boundary(out_entry, base_shift, | ||
603 | seg_boundary_size, outs, s))) { | ||
597 | /* Can't merge: create a new segment */ | 604 | /* Can't merge: create a new segment */ |
598 | segstart = s; | 605 | segstart = s; |
599 | outcount++; | 606 | outcount++; |
@@ -607,6 +614,7 @@ static int dma_4u_map_sg(struct device *dev, struct scatterlist *sglist, | |||
607 | /* This is a new segment, fill entries */ | 614 | /* This is a new segment, fill entries */ |
608 | outs->dma_address = dma_addr; | 615 | outs->dma_address = dma_addr; |
609 | outs->dma_length = slen; | 616 | outs->dma_length = slen; |
617 | out_entry = entry; | ||
610 | } | 618 | } |
611 | 619 | ||
612 | /* Calculate next page pointer for contiguous check */ | 620 | /* Calculate next page pointer for contiguous check */ |
diff --git a/arch/sparc64/kernel/iommu_common.h b/arch/sparc64/kernel/iommu_common.h index 0713bd58499c..f3575a614fa2 100644 --- a/arch/sparc64/kernel/iommu_common.h +++ b/arch/sparc64/kernel/iommu_common.h | |||
@@ -12,6 +12,7 @@ | |||
12 | #include <linux/mm.h> | 12 | #include <linux/mm.h> |
13 | #include <linux/scatterlist.h> | 13 | #include <linux/scatterlist.h> |
14 | #include <linux/device.h> | 14 | #include <linux/device.h> |
15 | #include <linux/iommu-helper.h> | ||
15 | 16 | ||
16 | #include <asm/iommu.h> | 17 | #include <asm/iommu.h> |
17 | #include <asm/scatterlist.h> | 18 | #include <asm/scatterlist.h> |
@@ -45,17 +46,16 @@ static inline unsigned long iommu_num_pages(unsigned long vaddr, | |||
45 | return npages; | 46 | return npages; |
46 | } | 47 | } |
47 | 48 | ||
48 | static inline unsigned long calc_npages(struct scatterlist *sglist, int nelems) | 49 | static inline int is_span_boundary(unsigned long entry, |
50 | unsigned long shift, | ||
51 | unsigned long boundary_size, | ||
52 | struct scatterlist *outs, | ||
53 | struct scatterlist *sg) | ||
49 | { | 54 | { |
50 | unsigned long i, npages = 0; | 55 | unsigned long paddr = SG_ENT_PHYS_ADDRESS(outs); |
51 | struct scatterlist *sg; | 56 | int nr = iommu_num_pages(paddr, outs->dma_length + sg->length); |
52 | 57 | ||
53 | for_each_sg(sglist, sg, nelems, i) { | 58 | return iommu_is_span_boundary(entry, nr, shift, boundary_size); |
54 | unsigned long paddr = SG_ENT_PHYS_ADDRESS(sg); | ||
55 | npages += iommu_num_pages(paddr, sg->length); | ||
56 | } | ||
57 | |||
58 | return npages; | ||
59 | } | 59 | } |
60 | 60 | ||
61 | extern unsigned long iommu_range_alloc(struct device *dev, | 61 | extern unsigned long iommu_range_alloc(struct device *dev, |
diff --git a/arch/sparc64/kernel/pci_sun4v.c b/arch/sparc64/kernel/pci_sun4v.c index ddca6c6c0b49..01839706bd52 100644 --- a/arch/sparc64/kernel/pci_sun4v.c +++ b/arch/sparc64/kernel/pci_sun4v.c | |||
@@ -335,8 +335,10 @@ static int dma_4v_map_sg(struct device *dev, struct scatterlist *sglist, | |||
335 | unsigned long flags, handle, prot; | 335 | unsigned long flags, handle, prot; |
336 | dma_addr_t dma_next = 0, dma_addr; | 336 | dma_addr_t dma_next = 0, dma_addr; |
337 | unsigned int max_seg_size; | 337 | unsigned int max_seg_size; |
338 | unsigned long seg_boundary_size; | ||
338 | int outcount, incount, i; | 339 | int outcount, incount, i; |
339 | struct iommu *iommu; | 340 | struct iommu *iommu; |
341 | unsigned long base_shift; | ||
340 | long err; | 342 | long err; |
341 | 343 | ||
342 | BUG_ON(direction == DMA_NONE); | 344 | BUG_ON(direction == DMA_NONE); |
@@ -362,8 +364,11 @@ static int dma_4v_map_sg(struct device *dev, struct scatterlist *sglist, | |||
362 | iommu_batch_start(dev, prot, ~0UL); | 364 | iommu_batch_start(dev, prot, ~0UL); |
363 | 365 | ||
364 | max_seg_size = dma_get_max_seg_size(dev); | 366 | max_seg_size = dma_get_max_seg_size(dev); |
367 | seg_boundary_size = ALIGN(dma_get_seg_boundary(dev) + 1, | ||
368 | IO_PAGE_SIZE) >> IO_PAGE_SHIFT; | ||
369 | base_shift = iommu->page_table_map_base >> IO_PAGE_SHIFT; | ||
365 | for_each_sg(sglist, s, nelems, i) { | 370 | for_each_sg(sglist, s, nelems, i) { |
366 | unsigned long paddr, npages, entry, slen; | 371 | unsigned long paddr, npages, entry, out_entry = 0, slen; |
367 | 372 | ||
368 | slen = s->length; | 373 | slen = s->length; |
369 | /* Sanity check */ | 374 | /* Sanity check */ |
@@ -406,7 +411,9 @@ static int dma_4v_map_sg(struct device *dev, struct scatterlist *sglist, | |||
406 | * - allocated dma_addr isn't contiguous to previous allocation | 411 | * - allocated dma_addr isn't contiguous to previous allocation |
407 | */ | 412 | */ |
408 | if ((dma_addr != dma_next) || | 413 | if ((dma_addr != dma_next) || |
409 | (outs->dma_length + s->length > max_seg_size)) { | 414 | (outs->dma_length + s->length > max_seg_size) || |
415 | (is_span_boundary(out_entry, base_shift, | ||
416 | seg_boundary_size, outs, s))) { | ||
410 | /* Can't merge: create a new segment */ | 417 | /* Can't merge: create a new segment */ |
411 | segstart = s; | 418 | segstart = s; |
412 | outcount++; | 419 | outcount++; |
@@ -420,6 +427,7 @@ static int dma_4v_map_sg(struct device *dev, struct scatterlist *sglist, | |||
420 | /* This is a new segment, fill entries */ | 427 | /* This is a new segment, fill entries */ |
421 | outs->dma_address = dma_addr; | 428 | outs->dma_address = dma_addr; |
422 | outs->dma_length = slen; | 429 | outs->dma_length = slen; |
430 | out_entry = entry; | ||
423 | } | 431 | } |
424 | 432 | ||
425 | /* Calculate next page pointer for contiguous check */ | 433 | /* Calculate next page pointer for contiguous check */ |
diff --git a/arch/sparc64/mm/tlb.c b/arch/sparc64/mm/tlb.c index a0f000b293de..ae24919cba7c 100644 --- a/arch/sparc64/mm/tlb.c +++ b/arch/sparc64/mm/tlb.c | |||
@@ -23,11 +23,8 @@ DEFINE_PER_CPU(struct mmu_gather, mmu_gathers) = { 0, }; | |||
23 | 23 | ||
24 | void flush_tlb_pending(void) | 24 | void flush_tlb_pending(void) |
25 | { | 25 | { |
26 | struct mmu_gather *mp; | 26 | struct mmu_gather *mp = &get_cpu_var(mmu_gathers); |
27 | 27 | ||
28 | preempt_disable(); | ||
29 | |||
30 | mp = &__get_cpu_var(mmu_gathers); | ||
31 | if (mp->tlb_nr) { | 28 | if (mp->tlb_nr) { |
32 | flush_tsb_user(mp); | 29 | flush_tsb_user(mp); |
33 | 30 | ||
@@ -43,7 +40,7 @@ void flush_tlb_pending(void) | |||
43 | mp->tlb_nr = 0; | 40 | mp->tlb_nr = 0; |
44 | } | 41 | } |
45 | 42 | ||
46 | preempt_enable(); | 43 | put_cpu_var(mmu_gathers); |
47 | } | 44 | } |
48 | 45 | ||
49 | void tlb_batch_add(struct mm_struct *mm, unsigned long vaddr, pte_t *ptep, pte_t orig) | 46 | void tlb_batch_add(struct mm_struct *mm, unsigned long vaddr, pte_t *ptep, pte_t orig) |
diff --git a/arch/x86/kernel/machine_kexec_64.c b/arch/x86/kernel/machine_kexec_64.c index 236d2f8f7ddc..576a03db4511 100644 --- a/arch/x86/kernel/machine_kexec_64.c +++ b/arch/x86/kernel/machine_kexec_64.c | |||
@@ -233,6 +233,7 @@ NORET_TYPE void machine_kexec(struct kimage *image) | |||
233 | 233 | ||
234 | void arch_crash_save_vmcoreinfo(void) | 234 | void arch_crash_save_vmcoreinfo(void) |
235 | { | 235 | { |
236 | VMCOREINFO_SYMBOL(phys_base); | ||
236 | VMCOREINFO_SYMBOL(init_level4_pgt); | 237 | VMCOREINFO_SYMBOL(init_level4_pgt); |
237 | 238 | ||
238 | #ifdef CONFIG_NUMA | 239 | #ifdef CONFIG_NUMA |
diff --git a/block/blk-settings.c b/block/blk-settings.c index 1344a0ea5cc6..5713f7e5cbd2 100644 --- a/block/blk-settings.c +++ b/block/blk-settings.c | |||
@@ -140,7 +140,7 @@ void blk_queue_bounce_limit(struct request_queue *q, u64 dma_addr) | |||
140 | /* Assume anything <= 4GB can be handled by IOMMU. | 140 | /* Assume anything <= 4GB can be handled by IOMMU. |
141 | Actually some IOMMUs can handle everything, but I don't | 141 | Actually some IOMMUs can handle everything, but I don't |
142 | know of a way to test this here. */ | 142 | know of a way to test this here. */ |
143 | if (b_pfn <= (min_t(u64, 0xffffffff, BLK_BOUNCE_HIGH) >> PAGE_SHIFT)) | 143 | if (b_pfn < (min_t(u64, 0x100000000UL, BLK_BOUNCE_HIGH) >> PAGE_SHIFT)) |
144 | dma = 1; | 144 | dma = 1; |
145 | q->bounce_pfn = max_low_pfn; | 145 | q->bounce_pfn = max_low_pfn; |
146 | #else | 146 | #else |
diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c index 0f962ecae91f..f26da2bfcc15 100644 --- a/block/cfq-iosched.c +++ b/block/cfq-iosched.c | |||
@@ -1143,24 +1143,37 @@ static void cfq_put_queue(struct cfq_queue *cfqq) | |||
1143 | } | 1143 | } |
1144 | 1144 | ||
1145 | /* | 1145 | /* |
1146 | * Call func for each cic attached to this ioc. Returns number of cic's seen. | 1146 | * Call func for each cic attached to this ioc. |
1147 | */ | 1147 | */ |
1148 | static unsigned int | 1148 | static void |
1149 | call_for_each_cic(struct io_context *ioc, | 1149 | call_for_each_cic(struct io_context *ioc, |
1150 | void (*func)(struct io_context *, struct cfq_io_context *)) | 1150 | void (*func)(struct io_context *, struct cfq_io_context *)) |
1151 | { | 1151 | { |
1152 | struct cfq_io_context *cic; | 1152 | struct cfq_io_context *cic; |
1153 | struct hlist_node *n; | 1153 | struct hlist_node *n; |
1154 | int called = 0; | ||
1155 | 1154 | ||
1156 | rcu_read_lock(); | 1155 | rcu_read_lock(); |
1157 | hlist_for_each_entry_rcu(cic, n, &ioc->cic_list, cic_list) { | 1156 | hlist_for_each_entry_rcu(cic, n, &ioc->cic_list, cic_list) |
1158 | func(ioc, cic); | 1157 | func(ioc, cic); |
1159 | called++; | ||
1160 | } | ||
1161 | rcu_read_unlock(); | 1158 | rcu_read_unlock(); |
1159 | } | ||
1160 | |||
1161 | static void cfq_cic_free_rcu(struct rcu_head *head) | ||
1162 | { | ||
1163 | struct cfq_io_context *cic; | ||
1164 | |||
1165 | cic = container_of(head, struct cfq_io_context, rcu_head); | ||
1166 | |||
1167 | kmem_cache_free(cfq_ioc_pool, cic); | ||
1168 | elv_ioc_count_dec(ioc_count); | ||
1169 | |||
1170 | if (ioc_gone && !elv_ioc_count_read(ioc_count)) | ||
1171 | complete(ioc_gone); | ||
1172 | } | ||
1162 | 1173 | ||
1163 | return called; | 1174 | static void cfq_cic_free(struct cfq_io_context *cic) |
1175 | { | ||
1176 | call_rcu(&cic->rcu_head, cfq_cic_free_rcu); | ||
1164 | } | 1177 | } |
1165 | 1178 | ||
1166 | static void cic_free_func(struct io_context *ioc, struct cfq_io_context *cic) | 1179 | static void cic_free_func(struct io_context *ioc, struct cfq_io_context *cic) |
@@ -1174,24 +1187,18 @@ static void cic_free_func(struct io_context *ioc, struct cfq_io_context *cic) | |||
1174 | hlist_del_rcu(&cic->cic_list); | 1187 | hlist_del_rcu(&cic->cic_list); |
1175 | spin_unlock_irqrestore(&ioc->lock, flags); | 1188 | spin_unlock_irqrestore(&ioc->lock, flags); |
1176 | 1189 | ||
1177 | kmem_cache_free(cfq_ioc_pool, cic); | 1190 | cfq_cic_free(cic); |
1178 | } | 1191 | } |
1179 | 1192 | ||
1180 | static void cfq_free_io_context(struct io_context *ioc) | 1193 | static void cfq_free_io_context(struct io_context *ioc) |
1181 | { | 1194 | { |
1182 | int freed; | ||
1183 | |||
1184 | /* | 1195 | /* |
1185 | * ioc->refcount is zero here, so no more cic's are allowed to be | 1196 | * ioc->refcount is zero here, or we are called from elv_unregister(), |
1186 | * linked into this ioc. So it should be ok to iterate over the known | 1197 | * so no more cic's are allowed to be linked into this ioc. So it |
1187 | * list, we will see all cic's since no new ones are added. | 1198 | * should be ok to iterate over the known list, we will see all cic's |
1199 | * since no new ones are added. | ||
1188 | */ | 1200 | */ |
1189 | freed = call_for_each_cic(ioc, cic_free_func); | 1201 | call_for_each_cic(ioc, cic_free_func); |
1190 | |||
1191 | elv_ioc_count_mod(ioc_count, -freed); | ||
1192 | |||
1193 | if (ioc_gone && !elv_ioc_count_read(ioc_count)) | ||
1194 | complete(ioc_gone); | ||
1195 | } | 1202 | } |
1196 | 1203 | ||
1197 | static void cfq_exit_cfqq(struct cfq_data *cfqd, struct cfq_queue *cfqq) | 1204 | static void cfq_exit_cfqq(struct cfq_data *cfqd, struct cfq_queue *cfqq) |
@@ -1458,15 +1465,6 @@ cfq_get_queue(struct cfq_data *cfqd, int is_sync, struct io_context *ioc, | |||
1458 | return cfqq; | 1465 | return cfqq; |
1459 | } | 1466 | } |
1460 | 1467 | ||
1461 | static void cfq_cic_free(struct cfq_io_context *cic) | ||
1462 | { | ||
1463 | kmem_cache_free(cfq_ioc_pool, cic); | ||
1464 | elv_ioc_count_dec(ioc_count); | ||
1465 | |||
1466 | if (ioc_gone && !elv_ioc_count_read(ioc_count)) | ||
1467 | complete(ioc_gone); | ||
1468 | } | ||
1469 | |||
1470 | /* | 1468 | /* |
1471 | * We drop cfq io contexts lazily, so we may find a dead one. | 1469 | * We drop cfq io contexts lazily, so we may find a dead one. |
1472 | */ | 1470 | */ |
@@ -2138,7 +2136,7 @@ static int __init cfq_slab_setup(void) | |||
2138 | if (!cfq_pool) | 2136 | if (!cfq_pool) |
2139 | goto fail; | 2137 | goto fail; |
2140 | 2138 | ||
2141 | cfq_ioc_pool = KMEM_CACHE(cfq_io_context, SLAB_DESTROY_BY_RCU); | 2139 | cfq_ioc_pool = KMEM_CACHE(cfq_io_context, 0); |
2142 | if (!cfq_ioc_pool) | 2140 | if (!cfq_ioc_pool) |
2143 | goto fail; | 2141 | goto fail; |
2144 | 2142 | ||
@@ -2286,7 +2284,6 @@ static void __exit cfq_exit(void) | |||
2286 | smp_wmb(); | 2284 | smp_wmb(); |
2287 | if (elv_ioc_count_read(ioc_count)) | 2285 | if (elv_ioc_count_read(ioc_count)) |
2288 | wait_for_completion(ioc_gone); | 2286 | wait_for_completion(ioc_gone); |
2289 | synchronize_rcu(); | ||
2290 | cfq_slab_kill(); | 2287 | cfq_slab_kill(); |
2291 | } | 2288 | } |
2292 | 2289 | ||
diff --git a/crypto/xcbc.c b/crypto/xcbc.c index 2feb0f239c38..b63b633e549c 100644 --- a/crypto/xcbc.c +++ b/crypto/xcbc.c | |||
@@ -116,13 +116,11 @@ static int crypto_xcbc_digest_update2(struct hash_desc *pdesc, | |||
116 | struct crypto_xcbc_ctx *ctx = crypto_hash_ctx_aligned(parent); | 116 | struct crypto_xcbc_ctx *ctx = crypto_hash_ctx_aligned(parent); |
117 | struct crypto_cipher *tfm = ctx->child; | 117 | struct crypto_cipher *tfm = ctx->child; |
118 | int bs = crypto_hash_blocksize(parent); | 118 | int bs = crypto_hash_blocksize(parent); |
119 | unsigned int i = 0; | ||
120 | 119 | ||
121 | do { | 120 | for (;;) { |
122 | 121 | struct page *pg = sg_page(sg); | |
123 | struct page *pg = sg_page(&sg[i]); | 122 | unsigned int offset = sg->offset; |
124 | unsigned int offset = sg[i].offset; | 123 | unsigned int slen = sg->length; |
125 | unsigned int slen = sg[i].length; | ||
126 | 124 | ||
127 | if (unlikely(slen > nbytes)) | 125 | if (unlikely(slen > nbytes)) |
128 | slen = nbytes; | 126 | slen = nbytes; |
@@ -182,8 +180,11 @@ static int crypto_xcbc_digest_update2(struct hash_desc *pdesc, | |||
182 | offset = 0; | 180 | offset = 0; |
183 | pg++; | 181 | pg++; |
184 | } | 182 | } |
185 | i++; | 183 | |
186 | } while (nbytes>0); | 184 | if (!nbytes) |
185 | break; | ||
186 | sg = scatterwalk_sg_next(sg); | ||
187 | } | ||
187 | 188 | ||
188 | return 0; | 189 | return 0; |
189 | } | 190 | } |
diff --git a/drivers/acpi/sleep/main.c b/drivers/acpi/sleep/main.c index d2f71a54726c..71183eea7906 100644 --- a/drivers/acpi/sleep/main.c +++ b/drivers/acpi/sleep/main.c | |||
@@ -26,21 +26,6 @@ u8 sleep_states[ACPI_S_STATE_COUNT]; | |||
26 | 26 | ||
27 | #ifdef CONFIG_PM_SLEEP | 27 | #ifdef CONFIG_PM_SLEEP |
28 | static u32 acpi_target_sleep_state = ACPI_STATE_S0; | 28 | static u32 acpi_target_sleep_state = ACPI_STATE_S0; |
29 | static bool acpi_sleep_finish_wake_up; | ||
30 | |||
31 | /* | ||
32 | * ACPI 2.0 and later want us to execute _PTS after suspending devices, so we | ||
33 | * allow the user to request that behavior by using the 'acpi_new_pts_ordering' | ||
34 | * kernel command line option that causes the following variable to be set. | ||
35 | */ | ||
36 | static bool new_pts_ordering; | ||
37 | |||
38 | static int __init acpi_new_pts_ordering(char *str) | ||
39 | { | ||
40 | new_pts_ordering = true; | ||
41 | return 1; | ||
42 | } | ||
43 | __setup("acpi_new_pts_ordering", acpi_new_pts_ordering); | ||
44 | #endif | 29 | #endif |
45 | 30 | ||
46 | static int acpi_sleep_prepare(u32 acpi_state) | 31 | static int acpi_sleep_prepare(u32 acpi_state) |
@@ -91,14 +76,6 @@ static int acpi_pm_begin(suspend_state_t pm_state) | |||
91 | 76 | ||
92 | if (sleep_states[acpi_state]) { | 77 | if (sleep_states[acpi_state]) { |
93 | acpi_target_sleep_state = acpi_state; | 78 | acpi_target_sleep_state = acpi_state; |
94 | if (new_pts_ordering) | ||
95 | return 0; | ||
96 | |||
97 | error = acpi_sleep_prepare(acpi_state); | ||
98 | if (error) | ||
99 | acpi_target_sleep_state = ACPI_STATE_S0; | ||
100 | else | ||
101 | acpi_sleep_finish_wake_up = true; | ||
102 | } else { | 79 | } else { |
103 | printk(KERN_ERR "ACPI does not support this state: %d\n", | 80 | printk(KERN_ERR "ACPI does not support this state: %d\n", |
104 | pm_state); | 81 | pm_state); |
@@ -116,14 +93,11 @@ static int acpi_pm_begin(suspend_state_t pm_state) | |||
116 | 93 | ||
117 | static int acpi_pm_prepare(void) | 94 | static int acpi_pm_prepare(void) |
118 | { | 95 | { |
119 | if (new_pts_ordering) { | 96 | int error = acpi_sleep_prepare(acpi_target_sleep_state); |
120 | int error = acpi_sleep_prepare(acpi_target_sleep_state); | ||
121 | 97 | ||
122 | if (error) { | 98 | if (error) { |
123 | acpi_target_sleep_state = ACPI_STATE_S0; | 99 | acpi_target_sleep_state = ACPI_STATE_S0; |
124 | return error; | 100 | return error; |
125 | } | ||
126 | acpi_sleep_finish_wake_up = true; | ||
127 | } | 101 | } |
128 | 102 | ||
129 | return ACPI_SUCCESS(acpi_hw_disable_all_gpes()) ? 0 : -EFAULT; | 103 | return ACPI_SUCCESS(acpi_hw_disable_all_gpes()) ? 0 : -EFAULT; |
@@ -212,7 +186,6 @@ static void acpi_pm_finish(void) | |||
212 | acpi_set_firmware_waking_vector((acpi_physical_address) 0); | 186 | acpi_set_firmware_waking_vector((acpi_physical_address) 0); |
213 | 187 | ||
214 | acpi_target_sleep_state = ACPI_STATE_S0; | 188 | acpi_target_sleep_state = ACPI_STATE_S0; |
215 | acpi_sleep_finish_wake_up = false; | ||
216 | 189 | ||
217 | #ifdef CONFIG_X86 | 190 | #ifdef CONFIG_X86 |
218 | if (init_8259A_after_S1) { | 191 | if (init_8259A_after_S1) { |
@@ -229,11 +202,10 @@ static void acpi_pm_finish(void) | |||
229 | static void acpi_pm_end(void) | 202 | static void acpi_pm_end(void) |
230 | { | 203 | { |
231 | /* | 204 | /* |
232 | * This is necessary in case acpi_pm_finish() is not called directly | 205 | * This is necessary in case acpi_pm_finish() is not called during a |
233 | * during a failing transition to a sleep state. | 206 | * failing transition to a sleep state. |
234 | */ | 207 | */ |
235 | if (acpi_sleep_finish_wake_up) | 208 | acpi_target_sleep_state = ACPI_STATE_S0; |
236 | acpi_pm_finish(); | ||
237 | } | 209 | } |
238 | 210 | ||
239 | static int acpi_pm_state_valid(suspend_state_t pm_state) | 211 | static int acpi_pm_state_valid(suspend_state_t pm_state) |
@@ -285,31 +257,18 @@ static struct dmi_system_id __initdata acpisleep_dmi_table[] = { | |||
285 | #ifdef CONFIG_HIBERNATION | 257 | #ifdef CONFIG_HIBERNATION |
286 | static int acpi_hibernation_begin(void) | 258 | static int acpi_hibernation_begin(void) |
287 | { | 259 | { |
288 | int error; | ||
289 | |||
290 | acpi_target_sleep_state = ACPI_STATE_S4; | 260 | acpi_target_sleep_state = ACPI_STATE_S4; |
291 | if (new_pts_ordering) | ||
292 | return 0; | ||
293 | 261 | ||
294 | error = acpi_sleep_prepare(ACPI_STATE_S4); | 262 | return 0; |
295 | if (error) | ||
296 | acpi_target_sleep_state = ACPI_STATE_S0; | ||
297 | else | ||
298 | acpi_sleep_finish_wake_up = true; | ||
299 | |||
300 | return error; | ||
301 | } | 263 | } |
302 | 264 | ||
303 | static int acpi_hibernation_prepare(void) | 265 | static int acpi_hibernation_prepare(void) |
304 | { | 266 | { |
305 | if (new_pts_ordering) { | 267 | int error = acpi_sleep_prepare(ACPI_STATE_S4); |
306 | int error = acpi_sleep_prepare(ACPI_STATE_S4); | ||
307 | 268 | ||
308 | if (error) { | 269 | if (error) { |
309 | acpi_target_sleep_state = ACPI_STATE_S0; | 270 | acpi_target_sleep_state = ACPI_STATE_S0; |
310 | return error; | 271 | return error; |
311 | } | ||
312 | acpi_sleep_finish_wake_up = true; | ||
313 | } | 272 | } |
314 | 273 | ||
315 | return ACPI_SUCCESS(acpi_hw_disable_all_gpes()) ? 0 : -EFAULT; | 274 | return ACPI_SUCCESS(acpi_hw_disable_all_gpes()) ? 0 : -EFAULT; |
@@ -353,17 +312,15 @@ static void acpi_hibernation_finish(void) | |||
353 | acpi_set_firmware_waking_vector((acpi_physical_address) 0); | 312 | acpi_set_firmware_waking_vector((acpi_physical_address) 0); |
354 | 313 | ||
355 | acpi_target_sleep_state = ACPI_STATE_S0; | 314 | acpi_target_sleep_state = ACPI_STATE_S0; |
356 | acpi_sleep_finish_wake_up = false; | ||
357 | } | 315 | } |
358 | 316 | ||
359 | static void acpi_hibernation_end(void) | 317 | static void acpi_hibernation_end(void) |
360 | { | 318 | { |
361 | /* | 319 | /* |
362 | * This is necessary in case acpi_hibernation_finish() is not called | 320 | * This is necessary in case acpi_hibernation_finish() is not called |
363 | * directly during a failing transition to the sleep state. | 321 | * during a failing transition to the sleep state. |
364 | */ | 322 | */ |
365 | if (acpi_sleep_finish_wake_up) | 323 | acpi_target_sleep_state = ACPI_STATE_S0; |
366 | acpi_hibernation_finish(); | ||
367 | } | 324 | } |
368 | 325 | ||
369 | static int acpi_hibernation_pre_restore(void) | 326 | static int acpi_hibernation_pre_restore(void) |
diff --git a/drivers/atm/firestream.c b/drivers/atm/firestream.c index 47c57a4294b7..98099f526d82 100644 --- a/drivers/atm/firestream.c +++ b/drivers/atm/firestream.c | |||
@@ -978,6 +978,7 @@ static int fs_open(struct atm_vcc *atm_vcc) | |||
978 | /* Docs are vague about this atm_hdr field. By the way, the FS | 978 | /* Docs are vague about this atm_hdr field. By the way, the FS |
979 | * chip makes odd errors if lower bits are set.... -- REW */ | 979 | * chip makes odd errors if lower bits are set.... -- REW */ |
980 | tc->atm_hdr = (vpi << 20) | (vci << 4); | 980 | tc->atm_hdr = (vpi << 20) | (vci << 4); |
981 | tmc0 = 0; | ||
981 | { | 982 | { |
982 | int pcr = atm_pcr_goal (txtp); | 983 | int pcr = atm_pcr_goal (txtp); |
983 | 984 | ||
diff --git a/drivers/atm/he.c b/drivers/atm/he.c index 2e3395b7e8c1..ffc4a5a41946 100644 --- a/drivers/atm/he.c +++ b/drivers/atm/he.c | |||
@@ -3000,8 +3000,7 @@ he_proc_read(struct atm_dev *dev, loff_t *pos, char *page) | |||
3000 | 3000 | ||
3001 | /* eeprom routines -- see 4.7 */ | 3001 | /* eeprom routines -- see 4.7 */ |
3002 | 3002 | ||
3003 | u8 | 3003 | static u8 read_prom_byte(struct he_dev *he_dev, int addr) |
3004 | read_prom_byte(struct he_dev *he_dev, int addr) | ||
3005 | { | 3004 | { |
3006 | u32 val = 0, tmp_read = 0; | 3005 | u32 val = 0, tmp_read = 0; |
3007 | int i, j = 0; | 3006 | int i, j = 0; |
diff --git a/drivers/atm/idt77252.c b/drivers/atm/idt77252.c index b967919fb7e2..28d77b5195de 100644 --- a/drivers/atm/idt77252.c +++ b/drivers/atm/idt77252.c | |||
@@ -2016,8 +2016,7 @@ idt77252_send_skb(struct atm_vcc *vcc, struct sk_buff *skb, int oam) | |||
2016 | return 0; | 2016 | return 0; |
2017 | } | 2017 | } |
2018 | 2018 | ||
2019 | int | 2019 | static int idt77252_send(struct atm_vcc *vcc, struct sk_buff *skb) |
2020 | idt77252_send(struct atm_vcc *vcc, struct sk_buff *skb) | ||
2021 | { | 2020 | { |
2022 | return idt77252_send_skb(vcc, skb, 0); | 2021 | return idt77252_send_skb(vcc, skb, 0); |
2023 | } | 2022 | } |
@@ -3072,8 +3071,7 @@ idt77252_dev_open(struct idt77252_dev *card) | |||
3072 | return 0; | 3071 | return 0; |
3073 | } | 3072 | } |
3074 | 3073 | ||
3075 | void | 3074 | static void idt77252_dev_close(struct atm_dev *dev) |
3076 | idt77252_dev_close(struct atm_dev *dev) | ||
3077 | { | 3075 | { |
3078 | struct idt77252_dev *card = dev->dev_data; | 3076 | struct idt77252_dev *card = dev->dev_data; |
3079 | u32 conf; | 3077 | u32 conf; |
diff --git a/drivers/atm/iphase.c b/drivers/atm/iphase.c index ef52452640e0..670c093ed25f 100644 --- a/drivers/atm/iphase.c +++ b/drivers/atm/iphase.c | |||
@@ -958,6 +958,7 @@ static void ia_suni_pm7345_init (IADEV *iadev) | |||
958 | 958 | ||
959 | /***************************** IA_LIB END *****************************/ | 959 | /***************************** IA_LIB END *****************************/ |
960 | 960 | ||
961 | #ifdef CONFIG_ATM_IA_DEBUG | ||
961 | static int tcnter = 0; | 962 | static int tcnter = 0; |
962 | static void xdump( u_char* cp, int length, char* prefix ) | 963 | static void xdump( u_char* cp, int length, char* prefix ) |
963 | { | 964 | { |
@@ -992,6 +993,7 @@ static void xdump( u_char* cp, int length, char* prefix ) | |||
992 | } | 993 | } |
993 | 994 | ||
994 | } /* close xdump(... */ | 995 | } /* close xdump(... */ |
996 | #endif /* CONFIG_ATM_IA_DEBUG */ | ||
995 | 997 | ||
996 | 998 | ||
997 | static struct atm_dev *ia_boards = NULL; | 999 | static struct atm_dev *ia_boards = NULL; |
diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c index b53fdb0a282c..60cc54368b66 100644 --- a/drivers/block/nbd.c +++ b/drivers/block/nbd.c | |||
@@ -153,6 +153,12 @@ static int sock_xmit(struct nbd_device *lo, int send, void *buf, int size, | |||
153 | struct kvec iov; | 153 | struct kvec iov; |
154 | sigset_t blocked, oldset; | 154 | sigset_t blocked, oldset; |
155 | 155 | ||
156 | if (unlikely(!sock)) { | ||
157 | printk(KERN_ERR "%s: Attempted %s on closed socket in sock_xmit\n", | ||
158 | lo->disk->disk_name, (send ? "send" : "recv")); | ||
159 | return -EINVAL; | ||
160 | } | ||
161 | |||
156 | /* Allow interception of SIGKILL only | 162 | /* Allow interception of SIGKILL only |
157 | * Don't allow other signals to interrupt the transmission */ | 163 | * Don't allow other signals to interrupt the transmission */ |
158 | siginitsetinv(&blocked, sigmask(SIGKILL)); | 164 | siginitsetinv(&blocked, sigmask(SIGKILL)); |
diff --git a/drivers/char/ip2/i2lib.c b/drivers/char/ip2/i2lib.c index d6567b32fb5c..9c25320121ef 100644 --- a/drivers/char/ip2/i2lib.c +++ b/drivers/char/ip2/i2lib.c | |||
@@ -644,12 +644,12 @@ i2QueueCommands(int type, i2ChanStrPtr pCh, int timeout, int nCommands, | |||
644 | // Normal Expected path - We still hold LOCK | 644 | // Normal Expected path - We still hold LOCK |
645 | break; /* from for()- Enough room: goto proceed */ | 645 | break; /* from for()- Enough room: goto proceed */ |
646 | } | 646 | } |
647 | } | 647 | ip2trace(CHANN, ITRC_QUEUE, 3, 1, totalsize); |
648 | 648 | WRITE_UNLOCK_IRQRESTORE(lock_var_p, flags); | |
649 | ip2trace (CHANN, ITRC_QUEUE, 3, 1, totalsize ); | 649 | } else |
650 | ip2trace(CHANN, ITRC_QUEUE, 3, 1, totalsize); | ||
650 | 651 | ||
651 | // Prepare to wait for buffers to empty | 652 | /* Prepare to wait for buffers to empty */ |
652 | WRITE_UNLOCK_IRQRESTORE(lock_var_p,flags); | ||
653 | serviceOutgoingFifo(pB); // Dump what we got | 653 | serviceOutgoingFifo(pB); // Dump what we got |
654 | 654 | ||
655 | if (timeout == 0) { | 655 | if (timeout == 0) { |
@@ -1830,6 +1830,8 @@ i2StripFifo(i2eBordStrPtr pB) | |||
1830 | default: // Neither packet? should be impossible | 1830 | default: // Neither packet? should be impossible |
1831 | ip2trace (ITRC_NO_PORT, ITRC_SFIFO, 5, 1, | 1831 | ip2trace (ITRC_NO_PORT, ITRC_SFIFO, 5, 1, |
1832 | PTYPE_OF(pB->i2eLeadoffWord) ); | 1832 | PTYPE_OF(pB->i2eLeadoffWord) ); |
1833 | WRITE_UNLOCK_IRQRESTORE(&pB->read_fifo_spinlock, | ||
1834 | bflags); | ||
1833 | 1835 | ||
1834 | break; | 1836 | break; |
1835 | } // End of switch on type of packets | 1837 | } // End of switch on type of packets |
diff --git a/drivers/char/rio/riotable.c b/drivers/char/rio/riotable.c index 991119c9f473..9b52892a501f 100644 --- a/drivers/char/rio/riotable.c +++ b/drivers/char/rio/riotable.c | |||
@@ -425,8 +425,10 @@ int RIOApel(struct rio_info *p) | |||
425 | 425 | ||
426 | MapP = &p->RIOConnectTable[Next++]; | 426 | MapP = &p->RIOConnectTable[Next++]; |
427 | MapP->HostUniqueNum = HostP->UniqueNum; | 427 | MapP->HostUniqueNum = HostP->UniqueNum; |
428 | if ((HostP->Flags & RUN_STATE) != RC_RUNNING) | 428 | if ((HostP->Flags & RUN_STATE) != RC_RUNNING) { |
429 | rio_spin_unlock_irqrestore(&HostP->HostLock, flags); | ||
429 | continue; | 430 | continue; |
431 | } | ||
430 | MapP->RtaUniqueNum = 0; | 432 | MapP->RtaUniqueNum = 0; |
431 | MapP->ID = 0; | 433 | MapP->ID = 0; |
432 | MapP->Flags = SLOT_IN_USE; | 434 | MapP->Flags = SLOT_IN_USE; |
diff --git a/drivers/char/rio/riotty.c b/drivers/char/rio/riotty.c index a4f0b1e3e7fa..cfa54361473f 100644 --- a/drivers/char/rio/riotty.c +++ b/drivers/char/rio/riotty.c | |||
@@ -319,6 +319,7 @@ int riotopen(struct tty_struct *tty, struct file *filp) | |||
319 | PortP->State |= RIO_WOPEN; | 319 | PortP->State |= RIO_WOPEN; |
320 | rio_spin_unlock_irqrestore(&PortP->portSem, flags); | 320 | rio_spin_unlock_irqrestore(&PortP->portSem, flags); |
321 | if (RIODelay(PortP, HUNDRED_MS) == RIO_FAIL) { | 321 | if (RIODelay(PortP, HUNDRED_MS) == RIO_FAIL) { |
322 | rio_spin_lock_irqsave(&PortP->portSem, flags); | ||
322 | /* | 323 | /* |
323 | ** ACTION: verify that this is a good thing | 324 | ** ACTION: verify that this is a good thing |
324 | ** to do here. -- ??? | 325 | ** to do here. -- ??? |
@@ -334,6 +335,7 @@ int riotopen(struct tty_struct *tty, struct file *filp) | |||
334 | func_exit(); | 335 | func_exit(); |
335 | return -EINTR; | 336 | return -EINTR; |
336 | } | 337 | } |
338 | rio_spin_lock_irqsave(&PortP->portSem, flags); | ||
337 | } | 339 | } |
338 | PortP->State &= ~RIO_WOPEN; | 340 | PortP->State &= ~RIO_WOPEN; |
339 | } | 341 | } |
@@ -493,6 +495,7 @@ int riotclose(void *ptr) | |||
493 | 495 | ||
494 | if (RIOShortCommand(p, PortP, CLOSE, 1, 0) == RIO_FAIL) { | 496 | if (RIOShortCommand(p, PortP, CLOSE, 1, 0) == RIO_FAIL) { |
495 | RIOPreemptiveCmd(p, PortP, FCLOSE); | 497 | RIOPreemptiveCmd(p, PortP, FCLOSE); |
498 | rio_spin_lock_irqsave(&PortP->portSem, flags); | ||
496 | goto close_end; | 499 | goto close_end; |
497 | } | 500 | } |
498 | 501 | ||
@@ -508,6 +511,7 @@ int riotclose(void *ptr) | |||
508 | 511 | ||
509 | if (p->RIOHalted) { | 512 | if (p->RIOHalted) { |
510 | RIOClearUp(PortP); | 513 | RIOClearUp(PortP); |
514 | rio_spin_lock_irqsave(&PortP->portSem, flags); | ||
511 | goto close_end; | 515 | goto close_end; |
512 | } | 516 | } |
513 | if (RIODelay(PortP, HUNDRED_MS) == RIO_FAIL) { | 517 | if (RIODelay(PortP, HUNDRED_MS) == RIO_FAIL) { |
diff --git a/drivers/firewire/fw-ohci.c b/drivers/firewire/fw-ohci.c index 996d61f0d460..ca6d51efd8bb 100644 --- a/drivers/firewire/fw-ohci.c +++ b/drivers/firewire/fw-ohci.c | |||
@@ -401,7 +401,8 @@ static void ar_context_tasklet(unsigned long data) | |||
401 | 401 | ||
402 | if (d->res_count == 0) { | 402 | if (d->res_count == 0) { |
403 | size_t size, rest, offset; | 403 | size_t size, rest, offset; |
404 | dma_addr_t buffer_bus; | 404 | dma_addr_t start_bus; |
405 | void *start; | ||
405 | 406 | ||
406 | /* | 407 | /* |
407 | * This descriptor is finished and we may have a | 408 | * This descriptor is finished and we may have a |
@@ -410,9 +411,9 @@ static void ar_context_tasklet(unsigned long data) | |||
410 | */ | 411 | */ |
411 | 412 | ||
412 | offset = offsetof(struct ar_buffer, data); | 413 | offset = offsetof(struct ar_buffer, data); |
413 | buffer_bus = le32_to_cpu(ab->descriptor.data_address) - offset; | 414 | start = buffer = ab; |
415 | start_bus = le32_to_cpu(ab->descriptor.data_address) - offset; | ||
414 | 416 | ||
415 | buffer = ab; | ||
416 | ab = ab->next; | 417 | ab = ab->next; |
417 | d = &ab->descriptor; | 418 | d = &ab->descriptor; |
418 | size = buffer + PAGE_SIZE - ctx->pointer; | 419 | size = buffer + PAGE_SIZE - ctx->pointer; |
@@ -427,7 +428,7 @@ static void ar_context_tasklet(unsigned long data) | |||
427 | buffer = handle_ar_packet(ctx, buffer); | 428 | buffer = handle_ar_packet(ctx, buffer); |
428 | 429 | ||
429 | dma_free_coherent(ohci->card.device, PAGE_SIZE, | 430 | dma_free_coherent(ohci->card.device, PAGE_SIZE, |
430 | buffer, buffer_bus); | 431 | start, start_bus); |
431 | ar_context_add_page(ctx); | 432 | ar_context_add_page(ctx); |
432 | } else { | 433 | } else { |
433 | buffer = ctx->pointer; | 434 | buffer = ctx->pointer; |
diff --git a/drivers/hwmon/w83781d.c b/drivers/hwmon/w83781d.c index 5c85670e2d16..f942ecdd47c8 100644 --- a/drivers/hwmon/w83781d.c +++ b/drivers/hwmon/w83781d.c | |||
@@ -1367,7 +1367,8 @@ w83781d_isa_probe(struct platform_device *pdev) | |||
1367 | 1367 | ||
1368 | /* Reserve the ISA region */ | 1368 | /* Reserve the ISA region */ |
1369 | res = platform_get_resource(pdev, IORESOURCE_IO, 0); | 1369 | res = platform_get_resource(pdev, IORESOURCE_IO, 0); |
1370 | if (!request_region(res->start, W83781D_EXTENT, "w83781d")) { | 1370 | if (!request_region(res->start + W83781D_ADDR_REG_OFFSET, 2, |
1371 | "w83781d")) { | ||
1371 | err = -EBUSY; | 1372 | err = -EBUSY; |
1372 | goto exit; | 1373 | goto exit; |
1373 | } | 1374 | } |
@@ -1415,7 +1416,7 @@ w83781d_isa_probe(struct platform_device *pdev) | |||
1415 | device_remove_file(&pdev->dev, &dev_attr_name); | 1416 | device_remove_file(&pdev->dev, &dev_attr_name); |
1416 | kfree(data); | 1417 | kfree(data); |
1417 | exit_release_region: | 1418 | exit_release_region: |
1418 | release_region(res->start, W83781D_EXTENT); | 1419 | release_region(res->start + W83781D_ADDR_REG_OFFSET, 2); |
1419 | exit: | 1420 | exit: |
1420 | return err; | 1421 | return err; |
1421 | } | 1422 | } |
@@ -1429,7 +1430,7 @@ w83781d_isa_remove(struct platform_device *pdev) | |||
1429 | sysfs_remove_group(&pdev->dev.kobj, &w83781d_group); | 1430 | sysfs_remove_group(&pdev->dev.kobj, &w83781d_group); |
1430 | sysfs_remove_group(&pdev->dev.kobj, &w83781d_group_opt); | 1431 | sysfs_remove_group(&pdev->dev.kobj, &w83781d_group_opt); |
1431 | device_remove_file(&pdev->dev, &dev_attr_name); | 1432 | device_remove_file(&pdev->dev, &dev_attr_name); |
1432 | release_region(data->client.addr, W83781D_EXTENT); | 1433 | release_region(data->client.addr + W83781D_ADDR_REG_OFFSET, 2); |
1433 | kfree(data); | 1434 | kfree(data); |
1434 | 1435 | ||
1435 | return 0; | 1436 | return 0; |
@@ -1797,8 +1798,17 @@ w83781d_isa_found(unsigned short address) | |||
1797 | { | 1798 | { |
1798 | int val, save, found = 0; | 1799 | int val, save, found = 0; |
1799 | 1800 | ||
1800 | if (!request_region(address, W83781D_EXTENT, "w83781d")) | 1801 | /* We have to request the region in two parts because some |
1802 | boards declare base+4 to base+7 as a PNP device */ | ||
1803 | if (!request_region(address, 4, "w83781d")) { | ||
1804 | pr_debug("w83781d: Failed to request low part of region\n"); | ||
1801 | return 0; | 1805 | return 0; |
1806 | } | ||
1807 | if (!request_region(address + 4, 4, "w83781d")) { | ||
1808 | pr_debug("w83781d: Failed to request high part of region\n"); | ||
1809 | release_region(address, 4); | ||
1810 | return 0; | ||
1811 | } | ||
1802 | 1812 | ||
1803 | #define REALLY_SLOW_IO | 1813 | #define REALLY_SLOW_IO |
1804 | /* We need the timeouts for at least some W83781D-like | 1814 | /* We need the timeouts for at least some W83781D-like |
@@ -1871,7 +1881,8 @@ w83781d_isa_found(unsigned short address) | |||
1871 | val == 0x30 ? "W83782D" : "W83781D", (int)address); | 1881 | val == 0x30 ? "W83782D" : "W83781D", (int)address); |
1872 | 1882 | ||
1873 | release: | 1883 | release: |
1874 | release_region(address, W83781D_EXTENT); | 1884 | release_region(address + 4, 4); |
1885 | release_region(address, 4); | ||
1875 | return found; | 1886 | return found; |
1876 | } | 1887 | } |
1877 | 1888 | ||
diff --git a/drivers/ide/arm/ide_arm.c b/drivers/ide/arm/ide_arm.c index 43a70e91363e..be9ff7334c52 100644 --- a/drivers/ide/arm/ide_arm.c +++ b/drivers/ide/arm/ide_arm.c | |||
@@ -46,3 +46,5 @@ static int __init ide_arm_init(void) | |||
46 | } | 46 | } |
47 | 47 | ||
48 | module_init(ide_arm_init); | 48 | module_init(ide_arm_init); |
49 | |||
50 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/cris/ide-cris.c b/drivers/ide/cris/ide-cris.c index e79bf8f9b7db..c8ffbaf29a88 100644 --- a/drivers/ide/cris/ide-cris.c +++ b/drivers/ide/cris/ide-cris.c | |||
@@ -1067,3 +1067,5 @@ static void cris_dma_start(ide_drive_t *drive) | |||
1067 | } | 1067 | } |
1068 | 1068 | ||
1069 | module_init(init_e100_ide); | 1069 | module_init(init_e100_ide); |
1070 | |||
1071 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/h8300/ide-h8300.c b/drivers/ide/h8300/ide-h8300.c index 520aec075700..4108ec4ffa7f 100644 --- a/drivers/ide/h8300/ide-h8300.c +++ b/drivers/ide/h8300/ide-h8300.c | |||
@@ -110,6 +110,7 @@ static int __init h8300_ide_init(void) | |||
110 | ide_init_port_data(hwif, index); | 110 | ide_init_port_data(hwif, index); |
111 | ide_init_port_hw(hwif, &hw); | 111 | ide_init_port_hw(hwif, &hw); |
112 | hwif_setup(hwif); | 112 | hwif_setup(hwif); |
113 | hwif->host_flags = IDE_HFLAG_NO_IO_32BIT; | ||
113 | printk(KERN_INFO "ide%d: H8/300 generic IDE interface\n", index); | 114 | printk(KERN_INFO "ide%d: H8/300 generic IDE interface\n", index); |
114 | 115 | ||
115 | idx[0] = index; | 116 | idx[0] = index; |
@@ -125,3 +126,5 @@ out_busy: | |||
125 | } | 126 | } |
126 | 127 | ||
127 | module_init(h8300_ide_init); | 128 | module_init(h8300_ide_init); |
129 | |||
130 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/ide-iops.c b/drivers/ide/ide-iops.c index 01b92208f09d..e77cee0e5d65 100644 --- a/drivers/ide/ide-iops.c +++ b/drivers/ide/ide-iops.c | |||
@@ -658,7 +658,7 @@ int ide_driveid_update(ide_drive_t *drive) | |||
658 | local_irq_restore(flags); | 658 | local_irq_restore(flags); |
659 | return 0; | 659 | return 0; |
660 | } | 660 | } |
661 | ata_input_data(drive, id, SECTOR_WORDS); | 661 | hwif->ata_input_data(drive, id, SECTOR_WORDS); |
662 | (void)ide_read_status(drive); /* clear drive IRQ */ | 662 | (void)ide_read_status(drive); /* clear drive IRQ */ |
663 | local_irq_enable(); | 663 | local_irq_enable(); |
664 | local_irq_restore(flags); | 664 | local_irq_restore(flags); |
diff --git a/drivers/ide/ide-pnp.c b/drivers/ide/ide-pnp.c index b163b2e52212..c14bb5380c25 100644 --- a/drivers/ide/ide-pnp.c +++ b/drivers/ide/ide-pnp.c | |||
@@ -86,3 +86,5 @@ static void __exit pnpide_exit(void) | |||
86 | 86 | ||
87 | module_init(pnpide_init); | 87 | module_init(pnpide_init); |
88 | module_exit(pnpide_exit); | 88 | module_exit(pnpide_exit); |
89 | |||
90 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/legacy/buddha.c b/drivers/ide/legacy/buddha.c index 50ffa871d5e9..fdd3791e465f 100644 --- a/drivers/ide/legacy/buddha.c +++ b/drivers/ide/legacy/buddha.c | |||
@@ -241,3 +241,5 @@ fail_base2: | |||
241 | } | 241 | } |
242 | 242 | ||
243 | module_init(buddha_init); | 243 | module_init(buddha_init); |
244 | |||
245 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/legacy/falconide.c b/drivers/ide/legacy/falconide.c index 8949ce71bddc..e950afa5939c 100644 --- a/drivers/ide/legacy/falconide.c +++ b/drivers/ide/legacy/falconide.c | |||
@@ -93,3 +93,5 @@ static int __init falconide_init(void) | |||
93 | } | 93 | } |
94 | 94 | ||
95 | module_init(falconide_init); | 95 | module_init(falconide_init); |
96 | |||
97 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/legacy/gayle.c b/drivers/ide/legacy/gayle.c index b7d81090d5da..e3b4638cc883 100644 --- a/drivers/ide/legacy/gayle.c +++ b/drivers/ide/legacy/gayle.c | |||
@@ -195,3 +195,5 @@ found: | |||
195 | } | 195 | } |
196 | 196 | ||
197 | module_init(gayle_init); | 197 | module_init(gayle_init); |
198 | |||
199 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/legacy/macide.c b/drivers/ide/legacy/macide.c index 9a79098d9eb4..eaf5dbe58bc2 100644 --- a/drivers/ide/legacy/macide.c +++ b/drivers/ide/legacy/macide.c | |||
@@ -137,3 +137,5 @@ static int __init macide_init(void) | |||
137 | } | 137 | } |
138 | 138 | ||
139 | module_init(macide_init); | 139 | module_init(macide_init); |
140 | |||
141 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/legacy/q40ide.c b/drivers/ide/legacy/q40ide.c index 1381b91bc316..2da28759686e 100644 --- a/drivers/ide/legacy/q40ide.c +++ b/drivers/ide/legacy/q40ide.c | |||
@@ -153,3 +153,5 @@ static int __init q40ide_init(void) | |||
153 | } | 153 | } |
154 | 154 | ||
155 | module_init(q40ide_init); | 155 | module_init(q40ide_init); |
156 | |||
157 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/pci/cmd640.c b/drivers/ide/pci/cmd640.c index ec667982809c..29fbc5ead03b 100644 --- a/drivers/ide/pci/cmd640.c +++ b/drivers/ide/pci/cmd640.c | |||
@@ -881,3 +881,5 @@ module_param_named(probe_vlb, cmd640_vlb, bool, 0); | |||
881 | MODULE_PARM_DESC(probe_vlb, "probe for VLB version of CMD640 chipset"); | 881 | MODULE_PARM_DESC(probe_vlb, "probe for VLB version of CMD640 chipset"); |
882 | 882 | ||
883 | module_init(cmd640x_init); | 883 | module_init(cmd640x_init); |
884 | |||
885 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/ppc/mpc8xx.c b/drivers/ide/ppc/mpc8xx.c index 38fbfb8d5445..ebaba01c7551 100644 --- a/drivers/ide/ppc/mpc8xx.c +++ b/drivers/ide/ppc/mpc8xx.c | |||
@@ -853,3 +853,5 @@ static int __init mpc8xx_ide_probe(void) | |||
853 | } | 853 | } |
854 | 854 | ||
855 | module_init(mpc8xx_ide_probe); | 855 | module_init(mpc8xx_ide_probe); |
856 | |||
857 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/ide/ppc/pmac.c b/drivers/ide/ppc/pmac.c index 78c9eeb85634..d9ca52e6cdab 100644 --- a/drivers/ide/ppc/pmac.c +++ b/drivers/ide/ppc/pmac.c | |||
@@ -1771,3 +1771,5 @@ static int __devinit pmac_ide_setup_dma(pmac_ide_hwif_t *pmif, ide_hwif_t *hwif) | |||
1771 | #endif /* CONFIG_BLK_DEV_IDEDMA_PMAC */ | 1771 | #endif /* CONFIG_BLK_DEV_IDEDMA_PMAC */ |
1772 | 1772 | ||
1773 | module_init(pmac_ide_probe); | 1773 | module_init(pmac_ide_probe); |
1774 | |||
1775 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/input/apm-power.c b/drivers/input/apm-power.c index c36d110b349a..7d61a9660806 100644 --- a/drivers/input/apm-power.c +++ b/drivers/input/apm-power.c | |||
@@ -63,8 +63,6 @@ static int apmpower_connect(struct input_handler *handler, | |||
63 | handle->handler = handler; | 63 | handle->handler = handler; |
64 | handle->name = "apm-power"; | 64 | handle->name = "apm-power"; |
65 | 65 | ||
66 | handler->private = handle; | ||
67 | |||
68 | error = input_register_handle(handle); | 66 | error = input_register_handle(handle); |
69 | if (error) { | 67 | if (error) { |
70 | printk(KERN_ERR | 68 | printk(KERN_ERR |
@@ -87,11 +85,10 @@ static int apmpower_connect(struct input_handler *handler, | |||
87 | return 0; | 85 | return 0; |
88 | } | 86 | } |
89 | 87 | ||
90 | static void apmpower_disconnect(struct input_handle *handler) | 88 | static void apmpower_disconnect(struct input_handle *handle) |
91 | { | 89 | { |
92 | struct input_handle *handle = handler->private; | ||
93 | |||
94 | input_close_device(handle); | 90 | input_close_device(handle); |
91 | input_unregister_handle(handle); | ||
95 | kfree(handle); | 92 | kfree(handle); |
96 | } | 93 | } |
97 | 94 | ||
diff --git a/drivers/input/evdev.c b/drivers/input/evdev.c index 99562cee827e..b32984bc516f 100644 --- a/drivers/input/evdev.c +++ b/drivers/input/evdev.c | |||
@@ -124,6 +124,7 @@ static void evdev_free(struct device *dev) | |||
124 | { | 124 | { |
125 | struct evdev *evdev = container_of(dev, struct evdev, dev); | 125 | struct evdev *evdev = container_of(dev, struct evdev, dev); |
126 | 126 | ||
127 | input_put_device(evdev->handle.dev); | ||
127 | kfree(evdev); | 128 | kfree(evdev); |
128 | } | 129 | } |
129 | 130 | ||
@@ -853,9 +854,6 @@ static void evdev_cleanup(struct evdev *evdev) | |||
853 | evdev_hangup(evdev); | 854 | evdev_hangup(evdev); |
854 | evdev_remove_chrdev(evdev); | 855 | evdev_remove_chrdev(evdev); |
855 | 856 | ||
856 | if (evdev->grab) | ||
857 | evdev_ungrab(evdev, evdev->grab); | ||
858 | |||
859 | /* evdev is marked dead so no one else accesses evdev->open */ | 857 | /* evdev is marked dead so no one else accesses evdev->open */ |
860 | if (evdev->open) { | 858 | if (evdev->open) { |
861 | input_flush_device(handle, NULL); | 859 | input_flush_device(handle, NULL); |
@@ -896,7 +894,7 @@ static int evdev_connect(struct input_handler *handler, struct input_dev *dev, | |||
896 | evdev->exist = 1; | 894 | evdev->exist = 1; |
897 | evdev->minor = minor; | 895 | evdev->minor = minor; |
898 | 896 | ||
899 | evdev->handle.dev = dev; | 897 | evdev->handle.dev = input_get_device(dev); |
900 | evdev->handle.name = evdev->name; | 898 | evdev->handle.name = evdev->name; |
901 | evdev->handle.handler = handler; | 899 | evdev->handle.handler = handler; |
902 | evdev->handle.private = evdev; | 900 | evdev->handle.private = evdev; |
diff --git a/drivers/input/joydev.c b/drivers/input/joydev.c index 22b2789ef58a..65d7077a75a1 100644 --- a/drivers/input/joydev.c +++ b/drivers/input/joydev.c | |||
@@ -171,6 +171,7 @@ static void joydev_free(struct device *dev) | |||
171 | { | 171 | { |
172 | struct joydev *joydev = container_of(dev, struct joydev, dev); | 172 | struct joydev *joydev = container_of(dev, struct joydev, dev); |
173 | 173 | ||
174 | input_put_device(joydev->handle.dev); | ||
174 | kfree(joydev); | 175 | kfree(joydev); |
175 | } | 176 | } |
176 | 177 | ||
@@ -750,7 +751,7 @@ static int joydev_connect(struct input_handler *handler, struct input_dev *dev, | |||
750 | joydev->minor = minor; | 751 | joydev->minor = minor; |
751 | 752 | ||
752 | joydev->exist = 1; | 753 | joydev->exist = 1; |
753 | joydev->handle.dev = dev; | 754 | joydev->handle.dev = input_get_device(dev); |
754 | joydev->handle.name = joydev->name; | 755 | joydev->handle.name = joydev->name; |
755 | joydev->handle.handler = handler; | 756 | joydev->handle.handler = handler; |
756 | joydev->handle.private = joydev; | 757 | joydev->handle.private = joydev; |
diff --git a/drivers/input/keyboard/pxa27x_keypad.c b/drivers/input/keyboard/pxa27x_keypad.c index 6224c2fb3b65..4e651c11c1da 100644 --- a/drivers/input/keyboard/pxa27x_keypad.c +++ b/drivers/input/keyboard/pxa27x_keypad.c | |||
@@ -50,9 +50,9 @@ | |||
50 | #define KPKDI 0x0048 | 50 | #define KPKDI 0x0048 |
51 | 51 | ||
52 | /* bit definitions */ | 52 | /* bit definitions */ |
53 | #define KPC_MKRN(n) ((((n) & 0x7) - 1) << 26) /* matrix key row number */ | 53 | #define KPC_MKRN(n) ((((n) - 1) & 0x7) << 26) /* matrix key row number */ |
54 | #define KPC_MKCN(n) ((((n) & 0x7) - 1) << 23) /* matrix key column number */ | 54 | #define KPC_MKCN(n) ((((n) - 1) & 0x7) << 23) /* matrix key column number */ |
55 | #define KPC_DKN(n) ((((n) & 0x7) - 1) << 6) /* direct key number */ | 55 | #define KPC_DKN(n) ((((n) - 1) & 0x7) << 6) /* direct key number */ |
56 | 56 | ||
57 | #define KPC_AS (0x1 << 30) /* Automatic Scan bit */ | 57 | #define KPC_AS (0x1 << 30) /* Automatic Scan bit */ |
58 | #define KPC_ASACT (0x1 << 29) /* Automatic Scan on Activity */ | 58 | #define KPC_ASACT (0x1 << 29) /* Automatic Scan on Activity */ |
diff --git a/drivers/input/mousedev.c b/drivers/input/mousedev.c index bbbe5e81adc1..b989748598ae 100644 --- a/drivers/input/mousedev.c +++ b/drivers/input/mousedev.c | |||
@@ -414,6 +414,7 @@ static void mousedev_free(struct device *dev) | |||
414 | { | 414 | { |
415 | struct mousedev *mousedev = container_of(dev, struct mousedev, dev); | 415 | struct mousedev *mousedev = container_of(dev, struct mousedev, dev); |
416 | 416 | ||
417 | input_put_device(mousedev->handle.dev); | ||
417 | kfree(mousedev); | 418 | kfree(mousedev); |
418 | } | 419 | } |
419 | 420 | ||
@@ -865,7 +866,7 @@ static struct mousedev *mousedev_create(struct input_dev *dev, | |||
865 | 866 | ||
866 | mousedev->minor = minor; | 867 | mousedev->minor = minor; |
867 | mousedev->exist = 1; | 868 | mousedev->exist = 1; |
868 | mousedev->handle.dev = dev; | 869 | mousedev->handle.dev = input_get_device(dev); |
869 | mousedev->handle.name = mousedev->name; | 870 | mousedev->handle.name = mousedev->name; |
870 | mousedev->handle.handler = handler; | 871 | mousedev->handle.handler = handler; |
871 | mousedev->handle.private = mousedev; | 872 | mousedev->handle.private = mousedev; |
diff --git a/drivers/leds/leds-gpio.c b/drivers/leds/leds-gpio.c index 6c0a9c4761ee..4c0b05852cb6 100644 --- a/drivers/leds/leds-gpio.c +++ b/drivers/leds/leds-gpio.c | |||
@@ -49,13 +49,13 @@ static void gpio_led_set(struct led_classdev *led_cdev, | |||
49 | if (led_dat->active_low) | 49 | if (led_dat->active_low) |
50 | level = !level; | 50 | level = !level; |
51 | 51 | ||
52 | /* setting GPIOs with I2C/etc requires a preemptible task context */ | 52 | /* Setting GPIOs with I2C/etc requires a task context, and we don't |
53 | * seem to have a reliable way to know if we're already in one; so | ||
54 | * let's just assume the worst. | ||
55 | */ | ||
53 | if (led_dat->can_sleep) { | 56 | if (led_dat->can_sleep) { |
54 | if (preempt_count()) { | 57 | led_dat->new_level = level; |
55 | led_dat->new_level = level; | 58 | schedule_work(&led_dat->work); |
56 | schedule_work(&led_dat->work); | ||
57 | } else | ||
58 | gpio_set_value_cansleep(led_dat->gpio, level); | ||
59 | } else | 59 | } else |
60 | gpio_set_value(led_dat->gpio, level); | 60 | gpio_set_value(led_dat->gpio, level); |
61 | } | 61 | } |
@@ -79,6 +79,10 @@ static int gpio_led_probe(struct platform_device *pdev) | |||
79 | cur_led = &pdata->leds[i]; | 79 | cur_led = &pdata->leds[i]; |
80 | led_dat = &leds_data[i]; | 80 | led_dat = &leds_data[i]; |
81 | 81 | ||
82 | ret = gpio_request(cur_led->gpio, cur_led->name); | ||
83 | if (ret < 0) | ||
84 | goto err; | ||
85 | |||
82 | led_dat->cdev.name = cur_led->name; | 86 | led_dat->cdev.name = cur_led->name; |
83 | led_dat->cdev.default_trigger = cur_led->default_trigger; | 87 | led_dat->cdev.default_trigger = cur_led->default_trigger; |
84 | led_dat->gpio = cur_led->gpio; | 88 | led_dat->gpio = cur_led->gpio; |
@@ -87,10 +91,6 @@ static int gpio_led_probe(struct platform_device *pdev) | |||
87 | led_dat->cdev.brightness_set = gpio_led_set; | 91 | led_dat->cdev.brightness_set = gpio_led_set; |
88 | led_dat->cdev.brightness = LED_OFF; | 92 | led_dat->cdev.brightness = LED_OFF; |
89 | 93 | ||
90 | ret = gpio_request(led_dat->gpio, led_dat->cdev.name); | ||
91 | if (ret < 0) | ||
92 | goto err; | ||
93 | |||
94 | gpio_direction_output(led_dat->gpio, led_dat->active_low); | 94 | gpio_direction_output(led_dat->gpio, led_dat->active_low); |
95 | 95 | ||
96 | INIT_WORK(&led_dat->work, gpio_led_work); | 96 | INIT_WORK(&led_dat->work, gpio_led_work); |
diff --git a/drivers/media/radio/radio-cadet.c b/drivers/media/radio/radio-cadet.c index 34e317ced5a3..57b9e3adc8f0 100644 --- a/drivers/media/radio/radio-cadet.c +++ b/drivers/media/radio/radio-cadet.c | |||
@@ -587,6 +587,8 @@ static struct video_device cadet_radio= | |||
587 | .vidioc_s_input = vidioc_s_input, | 587 | .vidioc_s_input = vidioc_s_input, |
588 | }; | 588 | }; |
589 | 589 | ||
590 | #ifdef CONFIG_PNP | ||
591 | |||
590 | static struct pnp_device_id cadet_pnp_devices[] = { | 592 | static struct pnp_device_id cadet_pnp_devices[] = { |
591 | /* ADS Cadet AM/FM Radio Card */ | 593 | /* ADS Cadet AM/FM Radio Card */ |
592 | {.id = "MSM0c24", .driver_data = 0}, | 594 | {.id = "MSM0c24", .driver_data = 0}, |
@@ -621,6 +623,10 @@ static struct pnp_driver cadet_pnp_driver = { | |||
621 | .remove = NULL, | 623 | .remove = NULL, |
622 | }; | 624 | }; |
623 | 625 | ||
626 | #else | ||
627 | static struct pnp_driver cadet_pnp_driver; | ||
628 | #endif | ||
629 | |||
624 | static int cadet_probe(void) | 630 | static int cadet_probe(void) |
625 | { | 631 | { |
626 | static int iovals[8]={0x330,0x332,0x334,0x336,0x338,0x33a,0x33c,0x33e}; | 632 | static int iovals[8]={0x330,0x332,0x334,0x336,0x338,0x33a,0x33c,0x33e}; |
diff --git a/drivers/media/video/bt8xx/bttv-driver.c b/drivers/media/video/bt8xx/bttv-driver.c index a080c149cc6c..fcf8f2d208a8 100644 --- a/drivers/media/video/bt8xx/bttv-driver.c +++ b/drivers/media/video/bt8xx/bttv-driver.c | |||
@@ -1990,7 +1990,7 @@ static int bttv_g_frequency(struct file *file, void *priv, | |||
1990 | if (0 != err) | 1990 | if (0 != err) |
1991 | return err; | 1991 | return err; |
1992 | 1992 | ||
1993 | f->type = V4L2_TUNER_ANALOG_TV; | 1993 | f->type = btv->radio_user ? V4L2_TUNER_RADIO : V4L2_TUNER_ANALOG_TV; |
1994 | f->frequency = btv->freq; | 1994 | f->frequency = btv->freq; |
1995 | 1995 | ||
1996 | return 0; | 1996 | return 0; |
@@ -2009,7 +2009,8 @@ static int bttv_s_frequency(struct file *file, void *priv, | |||
2009 | 2009 | ||
2010 | if (unlikely(f->tuner != 0)) | 2010 | if (unlikely(f->tuner != 0)) |
2011 | return -EINVAL; | 2011 | return -EINVAL; |
2012 | if (unlikely(f->type != V4L2_TUNER_ANALOG_TV)) | 2012 | if (unlikely(f->type != (btv->radio_user |
2013 | ? V4L2_TUNER_RADIO : V4L2_TUNER_ANALOG_TV))) | ||
2013 | return -EINVAL; | 2014 | return -EINVAL; |
2014 | mutex_lock(&btv->lock); | 2015 | mutex_lock(&btv->lock); |
2015 | btv->freq = f->frequency; | 2016 | btv->freq = f->frequency; |
@@ -3415,6 +3416,7 @@ static int radio_open(struct inode *inode, struct file *file) | |||
3415 | { | 3416 | { |
3416 | int minor = iminor(inode); | 3417 | int minor = iminor(inode); |
3417 | struct bttv *btv = NULL; | 3418 | struct bttv *btv = NULL; |
3419 | struct bttv_fh *fh; | ||
3418 | unsigned int i; | 3420 | unsigned int i; |
3419 | 3421 | ||
3420 | dprintk("bttv: open minor=%d\n",minor); | 3422 | dprintk("bttv: open minor=%d\n",minor); |
@@ -3429,12 +3431,19 @@ static int radio_open(struct inode *inode, struct file *file) | |||
3429 | return -ENODEV; | 3431 | return -ENODEV; |
3430 | 3432 | ||
3431 | dprintk("bttv%d: open called (radio)\n",btv->c.nr); | 3433 | dprintk("bttv%d: open called (radio)\n",btv->c.nr); |
3434 | |||
3435 | /* allocate per filehandle data */ | ||
3436 | fh = kmalloc(sizeof(*fh), GFP_KERNEL); | ||
3437 | if (NULL == fh) | ||
3438 | return -ENOMEM; | ||
3439 | file->private_data = fh; | ||
3440 | *fh = btv->init; | ||
3441 | v4l2_prio_open(&btv->prio, &fh->prio); | ||
3442 | |||
3432 | mutex_lock(&btv->lock); | 3443 | mutex_lock(&btv->lock); |
3433 | 3444 | ||
3434 | btv->radio_user++; | 3445 | btv->radio_user++; |
3435 | 3446 | ||
3436 | file->private_data = btv; | ||
3437 | |||
3438 | bttv_call_i2c_clients(btv,AUDC_SET_RADIO,NULL); | 3447 | bttv_call_i2c_clients(btv,AUDC_SET_RADIO,NULL); |
3439 | audio_input(btv,TVAUDIO_INPUT_RADIO); | 3448 | audio_input(btv,TVAUDIO_INPUT_RADIO); |
3440 | 3449 | ||
@@ -3444,7 +3453,8 @@ static int radio_open(struct inode *inode, struct file *file) | |||
3444 | 3453 | ||
3445 | static int radio_release(struct inode *inode, struct file *file) | 3454 | static int radio_release(struct inode *inode, struct file *file) |
3446 | { | 3455 | { |
3447 | struct bttv *btv = file->private_data; | 3456 | struct bttv_fh *fh = file->private_data; |
3457 | struct bttv *btv = fh->btv; | ||
3448 | struct rds_command cmd; | 3458 | struct rds_command cmd; |
3449 | 3459 | ||
3450 | btv->radio_user--; | 3460 | btv->radio_user--; |
@@ -3508,8 +3518,12 @@ static int radio_enum_input(struct file *file, void *priv, | |||
3508 | static int radio_g_audio(struct file *file, void *priv, | 3518 | static int radio_g_audio(struct file *file, void *priv, |
3509 | struct v4l2_audio *a) | 3519 | struct v4l2_audio *a) |
3510 | { | 3520 | { |
3521 | if (a->index != 0) | ||
3522 | return -EINVAL; | ||
3523 | |||
3511 | memset(a, 0, sizeof(*a)); | 3524 | memset(a, 0, sizeof(*a)); |
3512 | strcpy(a->name, "Radio"); | 3525 | strcpy(a->name, "Radio"); |
3526 | |||
3513 | return 0; | 3527 | return 0; |
3514 | } | 3528 | } |
3515 | 3529 | ||
@@ -3569,7 +3583,8 @@ static int radio_g_input(struct file *filp, void *priv, unsigned int *i) | |||
3569 | static ssize_t radio_read(struct file *file, char __user *data, | 3583 | static ssize_t radio_read(struct file *file, char __user *data, |
3570 | size_t count, loff_t *ppos) | 3584 | size_t count, loff_t *ppos) |
3571 | { | 3585 | { |
3572 | struct bttv *btv = file->private_data; | 3586 | struct bttv_fh *fh = file->private_data; |
3587 | struct bttv *btv = fh->btv; | ||
3573 | struct rds_command cmd; | 3588 | struct rds_command cmd; |
3574 | cmd.block_count = count/3; | 3589 | cmd.block_count = count/3; |
3575 | cmd.buffer = data; | 3590 | cmd.buffer = data; |
@@ -3583,7 +3598,8 @@ static ssize_t radio_read(struct file *file, char __user *data, | |||
3583 | 3598 | ||
3584 | static unsigned int radio_poll(struct file *file, poll_table *wait) | 3599 | static unsigned int radio_poll(struct file *file, poll_table *wait) |
3585 | { | 3600 | { |
3586 | struct bttv *btv = file->private_data; | 3601 | struct bttv_fh *fh = file->private_data; |
3602 | struct bttv *btv = fh->btv; | ||
3587 | struct rds_command cmd; | 3603 | struct rds_command cmd; |
3588 | cmd.instance = file; | 3604 | cmd.instance = file; |
3589 | cmd.event_list = wait; | 3605 | cmd.event_list = wait; |
@@ -3599,6 +3615,7 @@ static const struct file_operations radio_fops = | |||
3599 | .open = radio_open, | 3615 | .open = radio_open, |
3600 | .read = radio_read, | 3616 | .read = radio_read, |
3601 | .release = radio_release, | 3617 | .release = radio_release, |
3618 | .compat_ioctl = v4l_compat_ioctl32, | ||
3602 | .ioctl = video_ioctl2, | 3619 | .ioctl = video_ioctl2, |
3603 | .llseek = no_llseek, | 3620 | .llseek = no_llseek, |
3604 | .poll = radio_poll, | 3621 | .poll = radio_poll, |
diff --git a/drivers/media/video/cx23885/cx23885-cards.c b/drivers/media/video/cx23885/cx23885-cards.c index 2d414dad5c31..dfa269838e01 100644 --- a/drivers/media/video/cx23885/cx23885-cards.c +++ b/drivers/media/video/cx23885/cx23885-cards.c | |||
@@ -232,6 +232,7 @@ static void hauppauge_eeprom(struct cx23885_dev *dev, u8 *eeprom_data) | |||
232 | case 78631: /* WinTV-HVR1800 (PCIe, OEM, No IR, No FM, Dual channel ATSC and MPEG2 HW Encoder */ | 232 | case 78631: /* WinTV-HVR1800 (PCIe, OEM, No IR, No FM, Dual channel ATSC and MPEG2 HW Encoder */ |
233 | case 79001: /* WinTV-HVR1250 (PCIe, Retail, IR, full height, ATSC and Basic analog */ | 233 | case 79001: /* WinTV-HVR1250 (PCIe, Retail, IR, full height, ATSC and Basic analog */ |
234 | case 79101: /* WinTV-HVR1250 (PCIe, Retail, IR, half height, ATSC and Basic analog */ | 234 | case 79101: /* WinTV-HVR1250 (PCIe, Retail, IR, half height, ATSC and Basic analog */ |
235 | case 79561: /* WinTV-HVR1250 (PCIe, OEM, No IR, half height, ATSC and Basic analog */ | ||
235 | case 79571: /* WinTV-HVR1250 (PCIe, OEM, No IR, full height, ATSC and Basic analog */ | 236 | case 79571: /* WinTV-HVR1250 (PCIe, OEM, No IR, full height, ATSC and Basic analog */ |
236 | case 79671: /* WinTV-HVR1250 (PCIe, OEM, No IR, half height, ATSC and Basic analog */ | 237 | case 79671: /* WinTV-HVR1250 (PCIe, OEM, No IR, half height, ATSC and Basic analog */ |
237 | break; | 238 | break; |
@@ -347,10 +348,13 @@ void cx23885_card_setup(struct cx23885_dev *dev) | |||
347 | case CX23885_BOARD_HAUPPAUGE_HVR1250: | 348 | case CX23885_BOARD_HAUPPAUGE_HVR1250: |
348 | case CX23885_BOARD_HAUPPAUGE_HVR1500: | 349 | case CX23885_BOARD_HAUPPAUGE_HVR1500: |
349 | case CX23885_BOARD_HAUPPAUGE_HVR1500Q: | 350 | case CX23885_BOARD_HAUPPAUGE_HVR1500Q: |
351 | if (dev->i2c_bus[0].i2c_rc == 0) | ||
352 | hauppauge_eeprom(dev, eeprom+0x80); | ||
353 | break; | ||
350 | case CX23885_BOARD_HAUPPAUGE_HVR1800: | 354 | case CX23885_BOARD_HAUPPAUGE_HVR1800: |
351 | case CX23885_BOARD_HAUPPAUGE_HVR1800lp: | 355 | case CX23885_BOARD_HAUPPAUGE_HVR1800lp: |
352 | if (dev->i2c_bus[0].i2c_rc == 0) | 356 | if (dev->i2c_bus[0].i2c_rc == 0) |
353 | hauppauge_eeprom(dev, eeprom+0x80); | 357 | hauppauge_eeprom(dev, eeprom+0xc0); |
354 | break; | 358 | break; |
355 | } | 359 | } |
356 | 360 | ||
diff --git a/drivers/media/video/cx23885/cx23885-core.c b/drivers/media/video/cx23885/cx23885-core.c index 8e40c7bcc06d..7f10b273598f 100644 --- a/drivers/media/video/cx23885/cx23885-core.c +++ b/drivers/media/video/cx23885/cx23885-core.c | |||
@@ -56,137 +56,6 @@ LIST_HEAD(cx23885_devlist); | |||
56 | 56 | ||
57 | #define NO_SYNC_LINE (-1U) | 57 | #define NO_SYNC_LINE (-1U) |
58 | 58 | ||
59 | /* | ||
60 | * CX23885 Assumptions | ||
61 | * 1 line = 16 bytes of CDT | ||
62 | * cmds size = 80 | ||
63 | * cdt size = 16 * linesize | ||
64 | * iqsize = 64 | ||
65 | * maxlines = 6 | ||
66 | * | ||
67 | * Address Space: | ||
68 | * 0x00000000 0x00008fff FIFO clusters | ||
69 | * 0x00010000 0x000104af Channel Management Data Structures | ||
70 | * 0x000104b0 0x000104ff Free | ||
71 | * 0x00010500 0x000108bf 15 channels * iqsize | ||
72 | * 0x000108c0 0x000108ff Free | ||
73 | * 0x00010900 0x00010e9f IQ's + Cluster Descriptor Tables | ||
74 | * 15 channels * (iqsize + (maxlines * linesize)) | ||
75 | * 0x00010ea0 0x00010xxx Free | ||
76 | */ | ||
77 | |||
78 | static struct sram_channel cx23885_sram_channels[] = { | ||
79 | [SRAM_CH01] = { | ||
80 | .name = "VID A", | ||
81 | .cmds_start = 0x10000, | ||
82 | .ctrl_start = 0x105b0, | ||
83 | .cdt = 0x107b0, | ||
84 | .fifo_start = 0x40, | ||
85 | .fifo_size = 0x2800, | ||
86 | .ptr1_reg = DMA1_PTR1, | ||
87 | .ptr2_reg = DMA1_PTR2, | ||
88 | .cnt1_reg = DMA1_CNT1, | ||
89 | .cnt2_reg = DMA1_CNT2, | ||
90 | .jumponly = 1, | ||
91 | }, | ||
92 | [SRAM_CH02] = { | ||
93 | .name = "ch2", | ||
94 | .cmds_start = 0x0, | ||
95 | .ctrl_start = 0x0, | ||
96 | .cdt = 0x0, | ||
97 | .fifo_start = 0x0, | ||
98 | .fifo_size = 0x0, | ||
99 | .ptr1_reg = DMA2_PTR1, | ||
100 | .ptr2_reg = DMA2_PTR2, | ||
101 | .cnt1_reg = DMA2_CNT1, | ||
102 | .cnt2_reg = DMA2_CNT2, | ||
103 | }, | ||
104 | [SRAM_CH03] = { | ||
105 | .name = "TS1 B", | ||
106 | .cmds_start = 0x100A0, | ||
107 | .ctrl_start = 0x10630, | ||
108 | .cdt = 0x10870, | ||
109 | .fifo_start = 0x5000, | ||
110 | .fifo_size = 0x1000, | ||
111 | .ptr1_reg = DMA3_PTR1, | ||
112 | .ptr2_reg = DMA3_PTR2, | ||
113 | .cnt1_reg = DMA3_CNT1, | ||
114 | .cnt2_reg = DMA3_CNT2, | ||
115 | }, | ||
116 | [SRAM_CH04] = { | ||
117 | .name = "ch4", | ||
118 | .cmds_start = 0x0, | ||
119 | .ctrl_start = 0x0, | ||
120 | .cdt = 0x0, | ||
121 | .fifo_start = 0x0, | ||
122 | .fifo_size = 0x0, | ||
123 | .ptr1_reg = DMA4_PTR1, | ||
124 | .ptr2_reg = DMA4_PTR2, | ||
125 | .cnt1_reg = DMA4_CNT1, | ||
126 | .cnt2_reg = DMA4_CNT2, | ||
127 | }, | ||
128 | [SRAM_CH05] = { | ||
129 | .name = "ch5", | ||
130 | .cmds_start = 0x0, | ||
131 | .ctrl_start = 0x0, | ||
132 | .cdt = 0x0, | ||
133 | .fifo_start = 0x0, | ||
134 | .fifo_size = 0x0, | ||
135 | .ptr1_reg = DMA5_PTR1, | ||
136 | .ptr2_reg = DMA5_PTR2, | ||
137 | .cnt1_reg = DMA5_CNT1, | ||
138 | .cnt2_reg = DMA5_CNT2, | ||
139 | }, | ||
140 | [SRAM_CH06] = { | ||
141 | .name = "TS2 C", | ||
142 | .cmds_start = 0x10140, | ||
143 | .ctrl_start = 0x10680, | ||
144 | .cdt = 0x108d0, | ||
145 | .fifo_start = 0x6000, | ||
146 | .fifo_size = 0x1000, | ||
147 | .ptr1_reg = DMA5_PTR1, | ||
148 | .ptr2_reg = DMA5_PTR2, | ||
149 | .cnt1_reg = DMA5_CNT1, | ||
150 | .cnt2_reg = DMA5_CNT2, | ||
151 | }, | ||
152 | [SRAM_CH07] = { | ||
153 | .name = "ch7", | ||
154 | .cmds_start = 0x0, | ||
155 | .ctrl_start = 0x0, | ||
156 | .cdt = 0x0, | ||
157 | .fifo_start = 0x0, | ||
158 | .fifo_size = 0x0, | ||
159 | .ptr1_reg = DMA6_PTR1, | ||
160 | .ptr2_reg = DMA6_PTR2, | ||
161 | .cnt1_reg = DMA6_CNT1, | ||
162 | .cnt2_reg = DMA6_CNT2, | ||
163 | }, | ||
164 | [SRAM_CH08] = { | ||
165 | .name = "ch8", | ||
166 | .cmds_start = 0x0, | ||
167 | .ctrl_start = 0x0, | ||
168 | .cdt = 0x0, | ||
169 | .fifo_start = 0x0, | ||
170 | .fifo_size = 0x0, | ||
171 | .ptr1_reg = DMA7_PTR1, | ||
172 | .ptr2_reg = DMA7_PTR2, | ||
173 | .cnt1_reg = DMA7_CNT1, | ||
174 | .cnt2_reg = DMA7_CNT2, | ||
175 | }, | ||
176 | [SRAM_CH09] = { | ||
177 | .name = "ch9", | ||
178 | .cmds_start = 0x0, | ||
179 | .ctrl_start = 0x0, | ||
180 | .cdt = 0x0, | ||
181 | .fifo_start = 0x0, | ||
182 | .fifo_size = 0x0, | ||
183 | .ptr1_reg = DMA8_PTR1, | ||
184 | .ptr2_reg = DMA8_PTR2, | ||
185 | .cnt1_reg = DMA8_CNT1, | ||
186 | .cnt2_reg = DMA8_CNT2, | ||
187 | }, | ||
188 | }; | ||
189 | |||
190 | /* FIXME, these allocations will change when | 59 | /* FIXME, these allocations will change when |
191 | * analog arrives. The be reviewed. | 60 | * analog arrives. The be reviewed. |
192 | * CX23887 Assumptions | 61 | * CX23887 Assumptions |
@@ -754,6 +623,7 @@ static int cx23885_dev_setup(struct cx23885_dev *dev) | |||
754 | atomic_inc(&dev->refcount); | 623 | atomic_inc(&dev->refcount); |
755 | 624 | ||
756 | dev->nr = cx23885_devcount++; | 625 | dev->nr = cx23885_devcount++; |
626 | dev->sram_channels = cx23887_sram_channels; | ||
757 | sprintf(dev->name, "cx23885[%d]", dev->nr); | 627 | sprintf(dev->name, "cx23885[%d]", dev->nr); |
758 | 628 | ||
759 | mutex_lock(&devlist); | 629 | mutex_lock(&devlist); |
@@ -763,13 +633,11 @@ static int cx23885_dev_setup(struct cx23885_dev *dev) | |||
763 | /* Configure the internal memory */ | 633 | /* Configure the internal memory */ |
764 | if(dev->pci->device == 0x8880) { | 634 | if(dev->pci->device == 0x8880) { |
765 | dev->bridge = CX23885_BRIDGE_887; | 635 | dev->bridge = CX23885_BRIDGE_887; |
766 | dev->sram_channels = cx23887_sram_channels; | ||
767 | /* Apply a sensible clock frequency for the PCIe bridge */ | 636 | /* Apply a sensible clock frequency for the PCIe bridge */ |
768 | dev->clk_freq = 25000000; | 637 | dev->clk_freq = 25000000; |
769 | } else | 638 | } else |
770 | if(dev->pci->device == 0x8852) { | 639 | if(dev->pci->device == 0x8852) { |
771 | dev->bridge = CX23885_BRIDGE_885; | 640 | dev->bridge = CX23885_BRIDGE_885; |
772 | dev->sram_channels = cx23885_sram_channels; | ||
773 | /* Apply a sensible clock frequency for the PCIe bridge */ | 641 | /* Apply a sensible clock frequency for the PCIe bridge */ |
774 | dev->clk_freq = 28000000; | 642 | dev->clk_freq = 28000000; |
775 | } else | 643 | } else |
diff --git a/drivers/media/video/v4l2-int-device.c b/drivers/media/video/v4l2-int-device.c index a545dcaf857f..0e4549922f26 100644 --- a/drivers/media/video/v4l2-int-device.c +++ b/drivers/media/video/v4l2-int-device.c | |||
@@ -156,3 +156,5 @@ int v4l2_int_ioctl_1(struct v4l2_int_device *d, int cmd, void *arg) | |||
156 | find_ioctl(d->u.slave, cmd, | 156 | find_ioctl(d->u.slave, cmd, |
157 | (v4l2_int_ioctl_func *)no_such_ioctl_1))(d, arg); | 157 | (v4l2_int_ioctl_func *)no_such_ioctl_1))(d, arg); |
158 | } | 158 | } |
159 | |||
160 | MODULE_LICENSE("GPL"); | ||
diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig index fe7b5ec09708..3a0b20afec7b 100644 --- a/drivers/net/Kconfig +++ b/drivers/net/Kconfig | |||
@@ -2635,7 +2635,7 @@ config NIU | |||
2635 | 2635 | ||
2636 | config PASEMI_MAC | 2636 | config PASEMI_MAC |
2637 | tristate "PA Semi 1/10Gbit MAC" | 2637 | tristate "PA Semi 1/10Gbit MAC" |
2638 | depends on PPC64 && PCI | 2638 | depends on PPC_PASEMI && PCI |
2639 | select PHYLIB | 2639 | select PHYLIB |
2640 | select INET_LRO | 2640 | select INET_LRO |
2641 | help | 2641 | help |
diff --git a/drivers/net/bfin_mac.c b/drivers/net/bfin_mac.c index c993a32b3f50..26b2dd5016cd 100644 --- a/drivers/net/bfin_mac.c +++ b/drivers/net/bfin_mac.c | |||
@@ -575,7 +575,6 @@ adjust_head: | |||
575 | static int bf537mac_hard_start_xmit(struct sk_buff *skb, | 575 | static int bf537mac_hard_start_xmit(struct sk_buff *skb, |
576 | struct net_device *dev) | 576 | struct net_device *dev) |
577 | { | 577 | { |
578 | struct bf537mac_local *lp = netdev_priv(dev); | ||
579 | unsigned int data; | 578 | unsigned int data; |
580 | 579 | ||
581 | current_tx_ptr->skb = skb; | 580 | current_tx_ptr->skb = skb; |
@@ -634,7 +633,6 @@ out: | |||
634 | static void bf537mac_rx(struct net_device *dev) | 633 | static void bf537mac_rx(struct net_device *dev) |
635 | { | 634 | { |
636 | struct sk_buff *skb, *new_skb; | 635 | struct sk_buff *skb, *new_skb; |
637 | struct bf537mac_local *lp = netdev_priv(dev); | ||
638 | unsigned short len; | 636 | unsigned short len; |
639 | 637 | ||
640 | /* allocate a new skb for next time receive */ | 638 | /* allocate a new skb for next time receive */ |
diff --git a/drivers/net/bonding/bond_sysfs.c b/drivers/net/bonding/bond_sysfs.c index 90a1f31e8e63..979c2d05ff9c 100644 --- a/drivers/net/bonding/bond_sysfs.c +++ b/drivers/net/bonding/bond_sysfs.c | |||
@@ -341,6 +341,7 @@ static ssize_t bonding_store_slaves(struct device *d, | |||
341 | 341 | ||
342 | if (command[0] == '-') { | 342 | if (command[0] == '-') { |
343 | dev = NULL; | 343 | dev = NULL; |
344 | original_mtu = 0; | ||
344 | bond_for_each_slave(bond, slave, i) | 345 | bond_for_each_slave(bond, slave, i) |
345 | if (strnicmp(slave->dev->name, ifname, IFNAMSIZ) == 0) { | 346 | if (strnicmp(slave->dev->name, ifname, IFNAMSIZ) == 0) { |
346 | dev = slave->dev; | 347 | dev = slave->dev; |
diff --git a/drivers/net/forcedeth.c b/drivers/net/forcedeth.c index 6f7e3fde9e7c..980c2c229a71 100644 --- a/drivers/net/forcedeth.c +++ b/drivers/net/forcedeth.c | |||
@@ -1854,6 +1854,7 @@ static int nv_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
1854 | struct ring_desc* start_tx; | 1854 | struct ring_desc* start_tx; |
1855 | struct ring_desc* prev_tx; | 1855 | struct ring_desc* prev_tx; |
1856 | struct nv_skb_map* prev_tx_ctx; | 1856 | struct nv_skb_map* prev_tx_ctx; |
1857 | unsigned long flags; | ||
1857 | 1858 | ||
1858 | /* add fragments to entries count */ | 1859 | /* add fragments to entries count */ |
1859 | for (i = 0; i < fragments; i++) { | 1860 | for (i = 0; i < fragments; i++) { |
@@ -1863,10 +1864,10 @@ static int nv_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
1863 | 1864 | ||
1864 | empty_slots = nv_get_empty_tx_slots(np); | 1865 | empty_slots = nv_get_empty_tx_slots(np); |
1865 | if (unlikely(empty_slots <= entries)) { | 1866 | if (unlikely(empty_slots <= entries)) { |
1866 | spin_lock_irq(&np->lock); | 1867 | spin_lock_irqsave(&np->lock, flags); |
1867 | netif_stop_queue(dev); | 1868 | netif_stop_queue(dev); |
1868 | np->tx_stop = 1; | 1869 | np->tx_stop = 1; |
1869 | spin_unlock_irq(&np->lock); | 1870 | spin_unlock_irqrestore(&np->lock, flags); |
1870 | return NETDEV_TX_BUSY; | 1871 | return NETDEV_TX_BUSY; |
1871 | } | 1872 | } |
1872 | 1873 | ||
@@ -1929,13 +1930,13 @@ static int nv_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
1929 | tx_flags_extra = skb->ip_summed == CHECKSUM_PARTIAL ? | 1930 | tx_flags_extra = skb->ip_summed == CHECKSUM_PARTIAL ? |
1930 | NV_TX2_CHECKSUM_L3 | NV_TX2_CHECKSUM_L4 : 0; | 1931 | NV_TX2_CHECKSUM_L3 | NV_TX2_CHECKSUM_L4 : 0; |
1931 | 1932 | ||
1932 | spin_lock_irq(&np->lock); | 1933 | spin_lock_irqsave(&np->lock, flags); |
1933 | 1934 | ||
1934 | /* set tx flags */ | 1935 | /* set tx flags */ |
1935 | start_tx->flaglen |= cpu_to_le32(tx_flags | tx_flags_extra); | 1936 | start_tx->flaglen |= cpu_to_le32(tx_flags | tx_flags_extra); |
1936 | np->put_tx.orig = put_tx; | 1937 | np->put_tx.orig = put_tx; |
1937 | 1938 | ||
1938 | spin_unlock_irq(&np->lock); | 1939 | spin_unlock_irqrestore(&np->lock, flags); |
1939 | 1940 | ||
1940 | dprintk(KERN_DEBUG "%s: nv_start_xmit: entries %d queued for transmission. tx_flags_extra: %x\n", | 1941 | dprintk(KERN_DEBUG "%s: nv_start_xmit: entries %d queued for transmission. tx_flags_extra: %x\n", |
1941 | dev->name, entries, tx_flags_extra); | 1942 | dev->name, entries, tx_flags_extra); |
@@ -1971,6 +1972,7 @@ static int nv_start_xmit_optimized(struct sk_buff *skb, struct net_device *dev) | |||
1971 | struct ring_desc_ex* prev_tx; | 1972 | struct ring_desc_ex* prev_tx; |
1972 | struct nv_skb_map* prev_tx_ctx; | 1973 | struct nv_skb_map* prev_tx_ctx; |
1973 | struct nv_skb_map* start_tx_ctx; | 1974 | struct nv_skb_map* start_tx_ctx; |
1975 | unsigned long flags; | ||
1974 | 1976 | ||
1975 | /* add fragments to entries count */ | 1977 | /* add fragments to entries count */ |
1976 | for (i = 0; i < fragments; i++) { | 1978 | for (i = 0; i < fragments; i++) { |
@@ -1980,10 +1982,10 @@ static int nv_start_xmit_optimized(struct sk_buff *skb, struct net_device *dev) | |||
1980 | 1982 | ||
1981 | empty_slots = nv_get_empty_tx_slots(np); | 1983 | empty_slots = nv_get_empty_tx_slots(np); |
1982 | if (unlikely(empty_slots <= entries)) { | 1984 | if (unlikely(empty_slots <= entries)) { |
1983 | spin_lock_irq(&np->lock); | 1985 | spin_lock_irqsave(&np->lock, flags); |
1984 | netif_stop_queue(dev); | 1986 | netif_stop_queue(dev); |
1985 | np->tx_stop = 1; | 1987 | np->tx_stop = 1; |
1986 | spin_unlock_irq(&np->lock); | 1988 | spin_unlock_irqrestore(&np->lock, flags); |
1987 | return NETDEV_TX_BUSY; | 1989 | return NETDEV_TX_BUSY; |
1988 | } | 1990 | } |
1989 | 1991 | ||
@@ -2059,7 +2061,7 @@ static int nv_start_xmit_optimized(struct sk_buff *skb, struct net_device *dev) | |||
2059 | start_tx->txvlan = 0; | 2061 | start_tx->txvlan = 0; |
2060 | } | 2062 | } |
2061 | 2063 | ||
2062 | spin_lock_irq(&np->lock); | 2064 | spin_lock_irqsave(&np->lock, flags); |
2063 | 2065 | ||
2064 | if (np->tx_limit) { | 2066 | if (np->tx_limit) { |
2065 | /* Limit the number of outstanding tx. Setup all fragments, but | 2067 | /* Limit the number of outstanding tx. Setup all fragments, but |
@@ -2085,7 +2087,7 @@ static int nv_start_xmit_optimized(struct sk_buff *skb, struct net_device *dev) | |||
2085 | start_tx->flaglen |= cpu_to_le32(tx_flags | tx_flags_extra); | 2087 | start_tx->flaglen |= cpu_to_le32(tx_flags | tx_flags_extra); |
2086 | np->put_tx.ex = put_tx; | 2088 | np->put_tx.ex = put_tx; |
2087 | 2089 | ||
2088 | spin_unlock_irq(&np->lock); | 2090 | spin_unlock_irqrestore(&np->lock, flags); |
2089 | 2091 | ||
2090 | dprintk(KERN_DEBUG "%s: nv_start_xmit_optimized: entries %d queued for transmission. tx_flags_extra: %x\n", | 2092 | dprintk(KERN_DEBUG "%s: nv_start_xmit_optimized: entries %d queued for transmission. tx_flags_extra: %x\n", |
2091 | dev->name, entries, tx_flags_extra); | 2093 | dev->name, entries, tx_flags_extra); |
diff --git a/drivers/net/ibm_newemac/core.c b/drivers/net/ibm_newemac/core.c index 0789802d59ed..378a23963495 100644 --- a/drivers/net/ibm_newemac/core.c +++ b/drivers/net/ibm_newemac/core.c | |||
@@ -1242,8 +1242,8 @@ static int emac_close(struct net_device *ndev) | |||
1242 | static inline u16 emac_tx_csum(struct emac_instance *dev, | 1242 | static inline u16 emac_tx_csum(struct emac_instance *dev, |
1243 | struct sk_buff *skb) | 1243 | struct sk_buff *skb) |
1244 | { | 1244 | { |
1245 | if (emac_has_feature(dev, EMAC_FTR_HAS_TAH && | 1245 | if (emac_has_feature(dev, EMAC_FTR_HAS_TAH) && |
1246 | skb->ip_summed == CHECKSUM_PARTIAL)) { | 1246 | (skb->ip_summed == CHECKSUM_PARTIAL)) { |
1247 | ++dev->stats.tx_packets_csum; | 1247 | ++dev->stats.tx_packets_csum; |
1248 | return EMAC_TX_CTRL_TAH_CSUM; | 1248 | return EMAC_TX_CTRL_TAH_CSUM; |
1249 | } | 1249 | } |
diff --git a/drivers/net/plip.c b/drivers/net/plip.c index fee3d7b1feba..1e965427b0e9 100644 --- a/drivers/net/plip.c +++ b/drivers/net/plip.c | |||
@@ -903,17 +903,18 @@ plip_interrupt(void *dev_id) | |||
903 | struct net_local *nl; | 903 | struct net_local *nl; |
904 | struct plip_local *rcv; | 904 | struct plip_local *rcv; |
905 | unsigned char c0; | 905 | unsigned char c0; |
906 | unsigned long flags; | ||
906 | 907 | ||
907 | nl = netdev_priv(dev); | 908 | nl = netdev_priv(dev); |
908 | rcv = &nl->rcv_data; | 909 | rcv = &nl->rcv_data; |
909 | 910 | ||
910 | spin_lock_irq (&nl->lock); | 911 | spin_lock_irqsave (&nl->lock, flags); |
911 | 912 | ||
912 | c0 = read_status(dev); | 913 | c0 = read_status(dev); |
913 | if ((c0 & 0xf8) != 0xc0) { | 914 | if ((c0 & 0xf8) != 0xc0) { |
914 | if ((dev->irq != -1) && (net_debug > 1)) | 915 | if ((dev->irq != -1) && (net_debug > 1)) |
915 | printk(KERN_DEBUG "%s: spurious interrupt\n", dev->name); | 916 | printk(KERN_DEBUG "%s: spurious interrupt\n", dev->name); |
916 | spin_unlock_irq (&nl->lock); | 917 | spin_unlock_irqrestore (&nl->lock, flags); |
917 | return; | 918 | return; |
918 | } | 919 | } |
919 | 920 | ||
@@ -942,7 +943,7 @@ plip_interrupt(void *dev_id) | |||
942 | break; | 943 | break; |
943 | } | 944 | } |
944 | 945 | ||
945 | spin_unlock_irq(&nl->lock); | 946 | spin_unlock_irqrestore(&nl->lock, flags); |
946 | } | 947 | } |
947 | 948 | ||
948 | static int | 949 | static int |
diff --git a/drivers/net/s2io.c b/drivers/net/s2io.c index 3c915b82e199..c082cf0b1ac6 100644 --- a/drivers/net/s2io.c +++ b/drivers/net/s2io.c | |||
@@ -84,7 +84,7 @@ | |||
84 | #include "s2io.h" | 84 | #include "s2io.h" |
85 | #include "s2io-regs.h" | 85 | #include "s2io-regs.h" |
86 | 86 | ||
87 | #define DRV_VERSION "2.0.26.15-2" | 87 | #define DRV_VERSION "2.0.26.20" |
88 | 88 | ||
89 | /* S2io Driver name & version. */ | 89 | /* S2io Driver name & version. */ |
90 | static char s2io_driver_name[] = "Neterion"; | 90 | static char s2io_driver_name[] = "Neterion"; |
diff --git a/drivers/net/sky2.c b/drivers/net/sky2.c index 54c662690f65..853bce0ac478 100644 --- a/drivers/net/sky2.c +++ b/drivers/net/sky2.c | |||
@@ -4329,10 +4329,14 @@ static int sky2_suspend(struct pci_dev *pdev, pm_message_t state) | |||
4329 | if (!hw) | 4329 | if (!hw) |
4330 | return 0; | 4330 | return 0; |
4331 | 4331 | ||
4332 | del_timer_sync(&hw->watchdog_timer); | ||
4333 | cancel_work_sync(&hw->restart_work); | ||
4334 | |||
4332 | for (i = 0; i < hw->ports; i++) { | 4335 | for (i = 0; i < hw->ports; i++) { |
4333 | struct net_device *dev = hw->dev[i]; | 4336 | struct net_device *dev = hw->dev[i]; |
4334 | struct sky2_port *sky2 = netdev_priv(dev); | 4337 | struct sky2_port *sky2 = netdev_priv(dev); |
4335 | 4338 | ||
4339 | netif_device_detach(dev); | ||
4336 | if (netif_running(dev)) | 4340 | if (netif_running(dev)) |
4337 | sky2_down(dev); | 4341 | sky2_down(dev); |
4338 | 4342 | ||
@@ -4383,6 +4387,8 @@ static int sky2_resume(struct pci_dev *pdev) | |||
4383 | 4387 | ||
4384 | for (i = 0; i < hw->ports; i++) { | 4388 | for (i = 0; i < hw->ports; i++) { |
4385 | struct net_device *dev = hw->dev[i]; | 4389 | struct net_device *dev = hw->dev[i]; |
4390 | |||
4391 | netif_device_attach(dev); | ||
4386 | if (netif_running(dev)) { | 4392 | if (netif_running(dev)) { |
4387 | err = sky2_up(dev); | 4393 | err = sky2_up(dev); |
4388 | if (err) { | 4394 | if (err) { |
diff --git a/drivers/net/tulip/eeprom.c b/drivers/net/tulip/eeprom.c index 206918bad539..da2206f6021d 100644 --- a/drivers/net/tulip/eeprom.c +++ b/drivers/net/tulip/eeprom.c | |||
@@ -343,6 +343,12 @@ int __devinit tulip_read_eeprom(struct net_device *dev, int location, int addr_l | |||
343 | void __iomem *ee_addr = tp->base_addr + CSR9; | 343 | void __iomem *ee_addr = tp->base_addr + CSR9; |
344 | int read_cmd = location | (EE_READ_CMD << addr_len); | 344 | int read_cmd = location | (EE_READ_CMD << addr_len); |
345 | 345 | ||
346 | /* If location is past the end of what we can address, don't | ||
347 | * read some other location (ie truncate). Just return zero. | ||
348 | */ | ||
349 | if (location > (1 << addr_len) - 1) | ||
350 | return 0; | ||
351 | |||
346 | iowrite32(EE_ENB & ~EE_CS, ee_addr); | 352 | iowrite32(EE_ENB & ~EE_CS, ee_addr); |
347 | iowrite32(EE_ENB, ee_addr); | 353 | iowrite32(EE_ENB, ee_addr); |
348 | 354 | ||
diff --git a/drivers/net/tulip/tulip_core.c b/drivers/net/tulip/tulip_core.c index ed600bf56e78..82f404b76d81 100644 --- a/drivers/net/tulip/tulip_core.c +++ b/drivers/net/tulip/tulip_core.c | |||
@@ -1437,6 +1437,7 @@ static int __devinit tulip_init_one (struct pci_dev *pdev, | |||
1437 | EEPROM. | 1437 | EEPROM. |
1438 | */ | 1438 | */ |
1439 | ee_data = tp->eeprom; | 1439 | ee_data = tp->eeprom; |
1440 | memset(ee_data, 0, sizeof(tp->eeprom)); | ||
1440 | sum = 0; | 1441 | sum = 0; |
1441 | if (chip_idx == LC82C168) { | 1442 | if (chip_idx == LC82C168) { |
1442 | for (i = 0; i < 3; i++) { | 1443 | for (i = 0; i < 3; i++) { |
@@ -1458,8 +1459,12 @@ static int __devinit tulip_init_one (struct pci_dev *pdev, | |||
1458 | /* A serial EEPROM interface, we read now and sort it out later. */ | 1459 | /* A serial EEPROM interface, we read now and sort it out later. */ |
1459 | int sa_offset = 0; | 1460 | int sa_offset = 0; |
1460 | int ee_addr_size = tulip_read_eeprom(dev, 0xff, 8) & 0x40000 ? 8 : 6; | 1461 | int ee_addr_size = tulip_read_eeprom(dev, 0xff, 8) & 0x40000 ? 8 : 6; |
1462 | int ee_max_addr = ((1 << ee_addr_size) - 1) * sizeof(u16); | ||
1461 | 1463 | ||
1462 | for (i = 0; i < sizeof(tp->eeprom); i+=2) { | 1464 | if (ee_max_addr > sizeof(tp->eeprom)) |
1465 | ee_max_addr = sizeof(tp->eeprom); | ||
1466 | |||
1467 | for (i = 0; i < ee_max_addr ; i += sizeof(u16)) { | ||
1463 | u16 data = tulip_read_eeprom(dev, i/2, ee_addr_size); | 1468 | u16 data = tulip_read_eeprom(dev, i/2, ee_addr_size); |
1464 | ee_data[i] = data & 0xff; | 1469 | ee_data[i] = data & 0xff; |
1465 | ee_data[i + 1] = data >> 8; | 1470 | ee_data[i + 1] = data >> 8; |
diff --git a/drivers/net/usb/Kconfig b/drivers/net/usb/Kconfig index a12c9c41b217..0604f3faf043 100644 --- a/drivers/net/usb/Kconfig +++ b/drivers/net/usb/Kconfig | |||
@@ -129,7 +129,7 @@ config USB_USBNET | |||
129 | 129 | ||
130 | config USB_NET_AX8817X | 130 | config USB_NET_AX8817X |
131 | tristate "ASIX AX88xxx Based USB 2.0 Ethernet Adapters" | 131 | tristate "ASIX AX88xxx Based USB 2.0 Ethernet Adapters" |
132 | depends on USB_USBNET && NET_ETHERNET | 132 | depends on USB_USBNET |
133 | select CRC32 | 133 | select CRC32 |
134 | default y | 134 | default y |
135 | help | 135 | help |
diff --git a/drivers/net/usb/dm9601.c b/drivers/net/usb/dm9601.c index 0343b00cf1fd..01660f68943a 100644 --- a/drivers/net/usb/dm9601.c +++ b/drivers/net/usb/dm9601.c | |||
@@ -354,7 +354,7 @@ static void dm9601_set_multicast(struct net_device *net) | |||
354 | struct dev_mc_list *mc_list = net->mc_list; | 354 | struct dev_mc_list *mc_list = net->mc_list; |
355 | int i; | 355 | int i; |
356 | 356 | ||
357 | for (i = 0; i < net->mc_count; i++) { | 357 | for (i = 0; i < net->mc_count; i++, mc_list = mc_list->next) { |
358 | u32 crc = ether_crc(ETH_ALEN, mc_list->dmi_addr) >> 26; | 358 | u32 crc = ether_crc(ETH_ALEN, mc_list->dmi_addr) >> 26; |
359 | hashes[crc >> 3] |= 1 << (crc & 0x7); | 359 | hashes[crc >> 3] |= 1 << (crc & 0x7); |
360 | } | 360 | } |
diff --git a/drivers/net/usb/pegasus.c b/drivers/net/usb/pegasus.c index d1ed68a11e70..b588c890ea70 100644 --- a/drivers/net/usb/pegasus.c +++ b/drivers/net/usb/pegasus.c | |||
@@ -1128,12 +1128,8 @@ pegasus_get_settings(struct net_device *dev, struct ethtool_cmd *ecmd) | |||
1128 | { | 1128 | { |
1129 | pegasus_t *pegasus; | 1129 | pegasus_t *pegasus; |
1130 | 1130 | ||
1131 | if (in_atomic()) | ||
1132 | return 0; | ||
1133 | |||
1134 | pegasus = netdev_priv(dev); | 1131 | pegasus = netdev_priv(dev); |
1135 | mii_ethtool_gset(&pegasus->mii, ecmd); | 1132 | mii_ethtool_gset(&pegasus->mii, ecmd); |
1136 | |||
1137 | return 0; | 1133 | return 0; |
1138 | } | 1134 | } |
1139 | 1135 | ||
diff --git a/drivers/net/wan/lapbether.c b/drivers/net/wan/lapbether.c index fb37b8095231..824df3b5ea49 100644 --- a/drivers/net/wan/lapbether.c +++ b/drivers/net/wan/lapbether.c | |||
@@ -58,7 +58,7 @@ struct lapbethdev { | |||
58 | struct net_device_stats stats; /* some statistics */ | 58 | struct net_device_stats stats; /* some statistics */ |
59 | }; | 59 | }; |
60 | 60 | ||
61 | static struct list_head lapbeth_devices = LIST_HEAD_INIT(lapbeth_devices); | 61 | static LIST_HEAD(lapbeth_devices); |
62 | 62 | ||
63 | /* ------------------------------------------------------------------------ */ | 63 | /* ------------------------------------------------------------------------ */ |
64 | 64 | ||
diff --git a/drivers/net/wireless/b43/dma.c b/drivers/net/wireless/b43/dma.c index cfbc1a26f601..948eb1fe916b 100644 --- a/drivers/net/wireless/b43/dma.c +++ b/drivers/net/wireless/b43/dma.c | |||
@@ -619,6 +619,7 @@ static int setup_rx_descbuffer(struct b43_dmaring *ring, | |||
619 | } | 619 | } |
620 | 620 | ||
621 | if (b43_dma_mapping_error(ring, dmaaddr, ring->rx_buffersize, 0)) { | 621 | if (b43_dma_mapping_error(ring, dmaaddr, ring->rx_buffersize, 0)) { |
622 | b43err(ring->dev->wl, "RX DMA buffer allocation failed\n"); | ||
622 | dev_kfree_skb_any(skb); | 623 | dev_kfree_skb_any(skb); |
623 | return -EIO; | 624 | return -EIO; |
624 | } | 625 | } |
@@ -874,8 +875,12 @@ struct b43_dmaring *b43_setup_dmaring(struct b43_wldev *dev, | |||
874 | DMA_TO_DEVICE); | 875 | DMA_TO_DEVICE); |
875 | 876 | ||
876 | if (b43_dma_mapping_error(ring, dma_test, | 877 | if (b43_dma_mapping_error(ring, dma_test, |
877 | b43_txhdr_size(dev), 1)) | 878 | b43_txhdr_size(dev), 1)) { |
879 | |||
880 | b43err(dev->wl, | ||
881 | "TXHDR DMA allocation failed\n"); | ||
878 | goto err_kfree_txhdr_cache; | 882 | goto err_kfree_txhdr_cache; |
883 | } | ||
879 | } | 884 | } |
880 | 885 | ||
881 | dma_unmap_single(dev->dev->dev, | 886 | dma_unmap_single(dev->dev->dev, |
diff --git a/drivers/net/wireless/b43/pcmcia.c b/drivers/net/wireless/b43/pcmcia.c index b79a6bd5396d..371e4a119511 100644 --- a/drivers/net/wireless/b43/pcmcia.c +++ b/drivers/net/wireless/b43/pcmcia.c | |||
@@ -91,6 +91,8 @@ static int __devinit b43_pcmcia_probe(struct pcmcia_device *dev) | |||
91 | 91 | ||
92 | dev->conf.ConfigBase = parse.config.base; | 92 | dev->conf.ConfigBase = parse.config.base; |
93 | dev->conf.Present = parse.config.rmask[0]; | 93 | dev->conf.Present = parse.config.rmask[0]; |
94 | dev->conf.Attributes = CONF_ENABLE_IRQ; | ||
95 | dev->conf.IntType = INT_MEMORY_AND_IO; | ||
94 | 96 | ||
95 | dev->io.BasePort2 = 0; | 97 | dev->io.BasePort2 = 0; |
96 | dev->io.NumPorts2 = 0; | 98 | dev->io.NumPorts2 = 0; |
@@ -112,8 +114,8 @@ static int __devinit b43_pcmcia_probe(struct pcmcia_device *dev) | |||
112 | if (res != CS_SUCCESS) | 114 | if (res != CS_SUCCESS) |
113 | goto err_disable; | 115 | goto err_disable; |
114 | 116 | ||
115 | dev->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING | IRQ_FIRST_SHARED; | 117 | dev->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING; |
116 | dev->irq.IRQInfo1 = IRQ_LEVEL_ID | IRQ_SHARE_ID; | 118 | dev->irq.IRQInfo1 = IRQ_LEVEL_ID; |
117 | dev->irq.Handler = NULL; /* The handler is registered later. */ | 119 | dev->irq.Handler = NULL; /* The handler is registered later. */ |
118 | dev->irq.Instance = NULL; | 120 | dev->irq.Instance = NULL; |
119 | res = pcmcia_request_irq(dev, &dev->irq); | 121 | res = pcmcia_request_irq(dev, &dev->irq); |
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.c b/drivers/net/wireless/iwlwifi/iwl-4965.c index d727de8b96fe..65767570be68 100644 --- a/drivers/net/wireless/iwlwifi/iwl-4965.c +++ b/drivers/net/wireless/iwlwifi/iwl-4965.c | |||
@@ -4589,7 +4589,7 @@ static u8 iwl4965_is_fat_tx_allowed(struct iwl4965_priv *priv, | |||
4589 | 4589 | ||
4590 | if (sta_ht_inf) { | 4590 | if (sta_ht_inf) { |
4591 | if ((!sta_ht_inf->ht_supported) || | 4591 | if ((!sta_ht_inf->ht_supported) || |
4592 | (!sta_ht_inf->cap & IEEE80211_HT_CAP_SUP_WIDTH)) | 4592 | (!(sta_ht_inf->cap & IEEE80211_HT_CAP_SUP_WIDTH))) |
4593 | return 0; | 4593 | return 0; |
4594 | } | 4594 | } |
4595 | 4595 | ||
diff --git a/drivers/net/wireless/libertas/if_cs.c b/drivers/net/wireless/libertas/if_cs.c index 5a9cadb97503..038c66a98f15 100644 --- a/drivers/net/wireless/libertas/if_cs.c +++ b/drivers/net/wireless/libertas/if_cs.c | |||
@@ -677,9 +677,7 @@ sbi_get_int_status_exit: | |||
677 | 677 | ||
678 | /* Card has a command result for us */ | 678 | /* Card has a command result for us */ |
679 | if (*ireg & IF_CS_C_S_CMD_UPLD_RDY) { | 679 | if (*ireg & IF_CS_C_S_CMD_UPLD_RDY) { |
680 | spin_lock(&priv->driver_lock); | ||
681 | ret = if_cs_receive_cmdres(priv, priv->upld_buf, &priv->upld_len); | 680 | ret = if_cs_receive_cmdres(priv, priv->upld_buf, &priv->upld_len); |
682 | spin_unlock(&priv->driver_lock); | ||
683 | if (ret < 0) | 681 | if (ret < 0) |
684 | lbs_pr_err("could not receive cmd from card\n"); | 682 | lbs_pr_err("could not receive cmd from card\n"); |
685 | } | 683 | } |
diff --git a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c index bd305f7f3efd..e873a39fcce3 100644 --- a/drivers/net/wireless/rt2x00/rt2x00dev.c +++ b/drivers/net/wireless/rt2x00/rt2x00dev.c | |||
@@ -1393,11 +1393,20 @@ int rt2x00lib_suspend(struct rt2x00_dev *rt2x00dev, pm_message_t state) | |||
1393 | 1393 | ||
1394 | exit: | 1394 | exit: |
1395 | /* | 1395 | /* |
1396 | * Set device mode to sleep for power management. | 1396 | * Set device mode to sleep for power management, |
1397 | * on some hardware this call seems to consistently fail. | ||
1398 | * From the specifications it is hard to tell why it fails, | ||
1399 | * and if this is a "bad thing". | ||
1400 | * Overall it is safe to just ignore the failure and | ||
1401 | * continue suspending. The only downside is that the | ||
1402 | * device will not be in optimal power save mode, but with | ||
1403 | * the radio and the other components already disabled the | ||
1404 | * device is as good as disabled. | ||
1397 | */ | 1405 | */ |
1398 | retval = rt2x00dev->ops->lib->set_device_state(rt2x00dev, STATE_SLEEP); | 1406 | retval = rt2x00dev->ops->lib->set_device_state(rt2x00dev, STATE_SLEEP); |
1399 | if (retval) | 1407 | if (retval) |
1400 | return retval; | 1408 | WARNING(rt2x00dev, "Device failed to enter sleep state, " |
1409 | "continue suspending.\n"); | ||
1401 | 1410 | ||
1402 | return 0; | 1411 | return 0; |
1403 | } | 1412 | } |
diff --git a/drivers/scsi/hosts.c b/drivers/scsi/hosts.c index 880c78bff0e1..ed7e0a1fc34d 100644 --- a/drivers/scsi/hosts.c +++ b/drivers/scsi/hosts.c | |||
@@ -218,18 +218,24 @@ int scsi_add_host(struct Scsi_Host *shost, struct device *dev) | |||
218 | 218 | ||
219 | get_device(&shost->shost_gendev); | 219 | get_device(&shost->shost_gendev); |
220 | 220 | ||
221 | if (shost->transportt->host_size && | 221 | if (shost->transportt->host_size) { |
222 | (shost->shost_data = kzalloc(shost->transportt->host_size, | 222 | shost->shost_data = kzalloc(shost->transportt->host_size, |
223 | GFP_KERNEL)) == NULL) | 223 | GFP_KERNEL); |
224 | goto out_del_classdev; | 224 | if (shost->shost_data == NULL) { |
225 | error = -ENOMEM; | ||
226 | goto out_del_classdev; | ||
227 | } | ||
228 | } | ||
225 | 229 | ||
226 | if (shost->transportt->create_work_queue) { | 230 | if (shost->transportt->create_work_queue) { |
227 | snprintf(shost->work_q_name, KOBJ_NAME_LEN, "scsi_wq_%d", | 231 | snprintf(shost->work_q_name, KOBJ_NAME_LEN, "scsi_wq_%d", |
228 | shost->host_no); | 232 | shost->host_no); |
229 | shost->work_q = create_singlethread_workqueue( | 233 | shost->work_q = create_singlethread_workqueue( |
230 | shost->work_q_name); | 234 | shost->work_q_name); |
231 | if (!shost->work_q) | 235 | if (!shost->work_q) { |
236 | error = -EINVAL; | ||
232 | goto out_free_shost_data; | 237 | goto out_free_shost_data; |
238 | } | ||
233 | } | 239 | } |
234 | 240 | ||
235 | error = scsi_sysfs_add_host(shost); | 241 | error = scsi_sysfs_add_host(shost); |
diff --git a/drivers/scsi/libsas/sas_discover.c b/drivers/scsi/libsas/sas_discover.c index 31b9af224243..709a6f75ca9d 100644 --- a/drivers/scsi/libsas/sas_discover.c +++ b/drivers/scsi/libsas/sas_discover.c | |||
@@ -295,11 +295,14 @@ static void sas_discover_domain(struct work_struct *work) | |||
295 | case FANOUT_DEV: | 295 | case FANOUT_DEV: |
296 | error = sas_discover_root_expander(dev); | 296 | error = sas_discover_root_expander(dev); |
297 | break; | 297 | break; |
298 | #ifdef CONFIG_SCSI_SAS_ATA | ||
299 | case SATA_DEV: | 298 | case SATA_DEV: |
300 | case SATA_PM: | 299 | case SATA_PM: |
300 | #ifdef CONFIG_SCSI_SAS_ATA | ||
301 | error = sas_discover_sata(dev); | 301 | error = sas_discover_sata(dev); |
302 | break; | 302 | break; |
303 | #else | ||
304 | SAS_DPRINTK("ATA device seen but CONFIG_SCSI_SAS_ATA=N so cannot attach\n"); | ||
305 | /* Fall through */ | ||
303 | #endif | 306 | #endif |
304 | default: | 307 | default: |
305 | error = -ENXIO; | 308 | error = -ENXIO; |
diff --git a/drivers/scsi/mvsas.c b/drivers/scsi/mvsas.c index 5ec0665b3a3d..e55b9037adb2 100644 --- a/drivers/scsi/mvsas.c +++ b/drivers/scsi/mvsas.c | |||
@@ -37,11 +37,13 @@ | |||
37 | #include <linux/dma-mapping.h> | 37 | #include <linux/dma-mapping.h> |
38 | #include <linux/ctype.h> | 38 | #include <linux/ctype.h> |
39 | #include <scsi/libsas.h> | 39 | #include <scsi/libsas.h> |
40 | #include <scsi/scsi_tcq.h> | ||
41 | #include <scsi/sas_ata.h> | ||
40 | #include <asm/io.h> | 42 | #include <asm/io.h> |
41 | 43 | ||
42 | #define DRV_NAME "mvsas" | 44 | #define DRV_NAME "mvsas" |
43 | #define DRV_VERSION "0.5.1" | 45 | #define DRV_VERSION "0.5.2" |
44 | #define _MV_DUMP 0 | 46 | #define _MV_DUMP 0 |
45 | #define MVS_DISABLE_NVRAM | 47 | #define MVS_DISABLE_NVRAM |
46 | #define MVS_DISABLE_MSI | 48 | #define MVS_DISABLE_MSI |
47 | 49 | ||
@@ -52,7 +54,7 @@ | |||
52 | readl(regs + MVS_##reg); \ | 54 | readl(regs + MVS_##reg); \ |
53 | } while (0) | 55 | } while (0) |
54 | 56 | ||
55 | #define MVS_ID_NOT_MAPPED 0xff | 57 | #define MVS_ID_NOT_MAPPED 0x7f |
56 | #define MVS_CHIP_SLOT_SZ (1U << mvi->chip->slot_width) | 58 | #define MVS_CHIP_SLOT_SZ (1U << mvi->chip->slot_width) |
57 | 59 | ||
58 | /* offset for D2H FIS in the Received FIS List Structure */ | 60 | /* offset for D2H FIS in the Received FIS List Structure */ |
@@ -84,6 +86,7 @@ enum driver_configuration { | |||
84 | MVS_RX_FIS_COUNT = 17, /* Optional rx'd FISs (max 17) */ | 86 | MVS_RX_FIS_COUNT = 17, /* Optional rx'd FISs (max 17) */ |
85 | 87 | ||
86 | MVS_QUEUE_SIZE = 30, /* Support Queue depth */ | 88 | MVS_QUEUE_SIZE = 30, /* Support Queue depth */ |
89 | MVS_CAN_QUEUE = MVS_SLOTS - 1, /* SCSI Queue depth */ | ||
87 | }; | 90 | }; |
88 | 91 | ||
89 | /* unchangeable hardware details */ | 92 | /* unchangeable hardware details */ |
@@ -358,7 +361,20 @@ enum hw_register_bits { | |||
358 | 361 | ||
359 | /* VSR */ | 362 | /* VSR */ |
360 | /* PHYMODE 6 (CDB) */ | 363 | /* PHYMODE 6 (CDB) */ |
361 | PHY_MODE6_DTL_SPEED = (1U << 27), | 364 | PHY_MODE6_LATECLK = (1U << 29), /* Lock Clock */ |
365 | PHY_MODE6_DTL_SPEED = (1U << 27), /* Digital Loop Speed */ | ||
366 | PHY_MODE6_FC_ORDER = (1U << 26), /* Fibre Channel Mode Order*/ | ||
367 | PHY_MODE6_MUCNT_EN = (1U << 24), /* u Count Enable */ | ||
368 | PHY_MODE6_SEL_MUCNT_LEN = (1U << 22), /* Training Length Select */ | ||
369 | PHY_MODE6_SELMUPI = (1U << 20), /* Phase Multi Select (init) */ | ||
370 | PHY_MODE6_SELMUPF = (1U << 18), /* Phase Multi Select (final) */ | ||
371 | PHY_MODE6_SELMUFF = (1U << 16), /* Freq Loop Multi Sel(final) */ | ||
372 | PHY_MODE6_SELMUFI = (1U << 14), /* Freq Loop Multi Sel(init) */ | ||
373 | PHY_MODE6_FREEZE_LOOP = (1U << 12), /* Freeze Rx CDR Loop */ | ||
374 | PHY_MODE6_INT_RXFOFFS = (1U << 3), /* Rx CDR Freq Loop Enable */ | ||
375 | PHY_MODE6_FRC_RXFOFFS = (1U << 2), /* Initial Rx CDR Offset */ | ||
376 | PHY_MODE6_STAU_0D8 = (1U << 1), /* Rx CDR Freq Loop Saturate */ | ||
377 | PHY_MODE6_RXSAT_DIS = (1U << 0), /* Saturate Ctl */ | ||
362 | }; | 378 | }; |
363 | 379 | ||
364 | enum mvs_info_flags { | 380 | enum mvs_info_flags { |
@@ -511,7 +527,43 @@ enum status_buffer { | |||
511 | }; | 527 | }; |
512 | 528 | ||
513 | enum error_info_rec { | 529 | enum error_info_rec { |
514 | CMD_ISS_STPD = (1U << 31), /* Cmd Issue Stopped */ | 530 | CMD_ISS_STPD = (1U << 31), /* Cmd Issue Stopped */ |
531 | CMD_PI_ERR = (1U << 30), /* Protection info error. see flags2 */ | ||
532 | RSP_OVER = (1U << 29), /* rsp buffer overflow */ | ||
533 | RETRY_LIM = (1U << 28), /* FIS/frame retry limit exceeded */ | ||
534 | UNK_FIS = (1U << 27), /* unknown FIS */ | ||
535 | DMA_TERM = (1U << 26), /* DMA terminate primitive rx'd */ | ||
536 | SYNC_ERR = (1U << 25), /* SYNC rx'd during frame xmit */ | ||
537 | TFILE_ERR = (1U << 24), /* SATA taskfile Error bit set */ | ||
538 | R_ERR = (1U << 23), /* SATA returned R_ERR prim */ | ||
539 | RD_OFS = (1U << 20), /* Read DATA frame invalid offset */ | ||
540 | XFER_RDY_OFS = (1U << 19), /* XFER_RDY offset error */ | ||
541 | UNEXP_XFER_RDY = (1U << 18), /* unexpected XFER_RDY error */ | ||
542 | DATA_OVER_UNDER = (1U << 16), /* data overflow/underflow */ | ||
543 | INTERLOCK = (1U << 15), /* interlock error */ | ||
544 | NAK = (1U << 14), /* NAK rx'd */ | ||
545 | ACK_NAK_TO = (1U << 13), /* ACK/NAK timeout */ | ||
546 | CXN_CLOSED = (1U << 12), /* cxn closed w/out ack/nak */ | ||
547 | OPEN_TO = (1U << 11), /* I_T nexus lost, open cxn timeout */ | ||
548 | PATH_BLOCKED = (1U << 10), /* I_T nexus lost, pathway blocked */ | ||
549 | NO_DEST = (1U << 9), /* I_T nexus lost, no destination */ | ||
550 | STP_RES_BSY = (1U << 8), /* STP resources busy */ | ||
551 | BREAK = (1U << 7), /* break received */ | ||
552 | BAD_DEST = (1U << 6), /* bad destination */ | ||
553 | BAD_PROTO = (1U << 5), /* protocol not supported */ | ||
554 | BAD_RATE = (1U << 4), /* cxn rate not supported */ | ||
555 | WRONG_DEST = (1U << 3), /* wrong destination error */ | ||
556 | CREDIT_TO = (1U << 2), /* credit timeout */ | ||
557 | WDOG_TO = (1U << 1), /* watchdog timeout */ | ||
558 | BUF_PAR = (1U << 0), /* buffer parity error */ | ||
559 | }; | ||
560 | |||
561 | enum error_info_rec_2 { | ||
562 | SLOT_BSY_ERR = (1U << 31), /* Slot Busy Error */ | ||
563 | GRD_CHK_ERR = (1U << 14), /* Guard Check Error */ | ||
564 | APP_CHK_ERR = (1U << 13), /* Application Check error */ | ||
565 | REF_CHK_ERR = (1U << 12), /* Reference Check Error */ | ||
566 | USR_BLK_NM = (1U << 0), /* User Block Number */ | ||
515 | }; | 567 | }; |
516 | 568 | ||
517 | struct mvs_chip_info { | 569 | struct mvs_chip_info { |
@@ -543,28 +595,12 @@ struct mvs_cmd_hdr { | |||
543 | __le32 reserved[4]; | 595 | __le32 reserved[4]; |
544 | }; | 596 | }; |
545 | 597 | ||
546 | struct mvs_slot_info { | ||
547 | struct sas_task *task; | ||
548 | u32 n_elem; | ||
549 | u32 tx; | ||
550 | |||
551 | /* DMA buffer for storing cmd tbl, open addr frame, status buffer, | ||
552 | * and PRD table | ||
553 | */ | ||
554 | void *buf; | ||
555 | dma_addr_t buf_dma; | ||
556 | #if _MV_DUMP | ||
557 | u32 cmd_size; | ||
558 | #endif | ||
559 | |||
560 | void *response; | ||
561 | }; | ||
562 | |||
563 | struct mvs_port { | 598 | struct mvs_port { |
564 | struct asd_sas_port sas_port; | 599 | struct asd_sas_port sas_port; |
565 | u8 port_attached; | 600 | u8 port_attached; |
566 | u8 taskfileset; | 601 | u8 taskfileset; |
567 | u8 wide_port_phymap; | 602 | u8 wide_port_phymap; |
603 | struct list_head list; | ||
568 | }; | 604 | }; |
569 | 605 | ||
570 | struct mvs_phy { | 606 | struct mvs_phy { |
@@ -582,6 +618,27 @@ struct mvs_phy { | |||
582 | u32 frame_rcvd_size; | 618 | u32 frame_rcvd_size; |
583 | u8 frame_rcvd[32]; | 619 | u8 frame_rcvd[32]; |
584 | u8 phy_attached; | 620 | u8 phy_attached; |
621 | enum sas_linkrate minimum_linkrate; | ||
622 | enum sas_linkrate maximum_linkrate; | ||
623 | }; | ||
624 | |||
625 | struct mvs_slot_info { | ||
626 | struct list_head list; | ||
627 | struct sas_task *task; | ||
628 | u32 n_elem; | ||
629 | u32 tx; | ||
630 | |||
631 | /* DMA buffer for storing cmd tbl, open addr frame, status buffer, | ||
632 | * and PRD table | ||
633 | */ | ||
634 | void *buf; | ||
635 | dma_addr_t buf_dma; | ||
636 | #if _MV_DUMP | ||
637 | u32 cmd_size; | ||
638 | #endif | ||
639 | |||
640 | void *response; | ||
641 | struct mvs_port *port; | ||
585 | }; | 642 | }; |
586 | 643 | ||
587 | struct mvs_info { | 644 | struct mvs_info { |
@@ -612,21 +669,14 @@ struct mvs_info { | |||
612 | 669 | ||
613 | const struct mvs_chip_info *chip; | 670 | const struct mvs_chip_info *chip; |
614 | 671 | ||
615 | unsigned long tags[MVS_SLOTS]; | 672 | u8 tags[MVS_SLOTS]; |
616 | struct mvs_slot_info slot_info[MVS_SLOTS]; | 673 | struct mvs_slot_info slot_info[MVS_SLOTS]; |
617 | /* further per-slot information */ | 674 | /* further per-slot information */ |
618 | struct mvs_phy phy[MVS_MAX_PHYS]; | 675 | struct mvs_phy phy[MVS_MAX_PHYS]; |
619 | struct mvs_port port[MVS_MAX_PHYS]; | 676 | struct mvs_port port[MVS_MAX_PHYS]; |
620 | 677 | #ifdef MVS_USE_TASKLET | |
621 | u32 can_queue; /* per adapter */ | 678 | struct tasklet_struct tasklet; |
622 | u32 tag_out; /*Get*/ | 679 | #endif |
623 | u32 tag_in; /*Give*/ | ||
624 | }; | ||
625 | |||
626 | struct mvs_queue_task { | ||
627 | struct list_head list; | ||
628 | |||
629 | void *uldd_task; | ||
630 | }; | 680 | }; |
631 | 681 | ||
632 | static int mvs_phy_control(struct asd_sas_phy *sas_phy, enum phy_func func, | 682 | static int mvs_phy_control(struct asd_sas_phy *sas_phy, enum phy_func func, |
@@ -641,10 +691,11 @@ static u32 mvs_read_port_irq_mask(struct mvs_info *mvi, u32 port); | |||
641 | static u32 mvs_is_phy_ready(struct mvs_info *mvi, int i); | 691 | static u32 mvs_is_phy_ready(struct mvs_info *mvi, int i); |
642 | static void mvs_detect_porttype(struct mvs_info *mvi, int i); | 692 | static void mvs_detect_porttype(struct mvs_info *mvi, int i); |
643 | static void mvs_update_phyinfo(struct mvs_info *mvi, int i, int get_st); | 693 | static void mvs_update_phyinfo(struct mvs_info *mvi, int i, int get_st); |
694 | static void mvs_release_task(struct mvs_info *mvi, int phy_no); | ||
644 | 695 | ||
645 | static int mvs_scan_finished(struct Scsi_Host *, unsigned long); | 696 | static int mvs_scan_finished(struct Scsi_Host *, unsigned long); |
646 | static void mvs_scan_start(struct Scsi_Host *); | 697 | static void mvs_scan_start(struct Scsi_Host *); |
647 | static int mvs_sas_slave_alloc(struct scsi_device *scsi_dev); | 698 | static int mvs_slave_configure(struct scsi_device *sdev); |
648 | 699 | ||
649 | static struct scsi_transport_template *mvs_stt; | 700 | static struct scsi_transport_template *mvs_stt; |
650 | 701 | ||
@@ -659,7 +710,7 @@ static struct scsi_host_template mvs_sht = { | |||
659 | .name = DRV_NAME, | 710 | .name = DRV_NAME, |
660 | .queuecommand = sas_queuecommand, | 711 | .queuecommand = sas_queuecommand, |
661 | .target_alloc = sas_target_alloc, | 712 | .target_alloc = sas_target_alloc, |
662 | .slave_configure = sas_slave_configure, | 713 | .slave_configure = mvs_slave_configure, |
663 | .slave_destroy = sas_slave_destroy, | 714 | .slave_destroy = sas_slave_destroy, |
664 | .scan_finished = mvs_scan_finished, | 715 | .scan_finished = mvs_scan_finished, |
665 | .scan_start = mvs_scan_start, | 716 | .scan_start = mvs_scan_start, |
@@ -674,7 +725,7 @@ static struct scsi_host_template mvs_sht = { | |||
674 | .use_clustering = ENABLE_CLUSTERING, | 725 | .use_clustering = ENABLE_CLUSTERING, |
675 | .eh_device_reset_handler = sas_eh_device_reset_handler, | 726 | .eh_device_reset_handler = sas_eh_device_reset_handler, |
676 | .eh_bus_reset_handler = sas_eh_bus_reset_handler, | 727 | .eh_bus_reset_handler = sas_eh_bus_reset_handler, |
677 | .slave_alloc = mvs_sas_slave_alloc, | 728 | .slave_alloc = sas_slave_alloc, |
678 | .target_destroy = sas_target_destroy, | 729 | .target_destroy = sas_target_destroy, |
679 | .ioctl = sas_ioctl, | 730 | .ioctl = sas_ioctl, |
680 | }; | 731 | }; |
@@ -709,10 +760,10 @@ static void mvs_hexdump(u32 size, u8 *data, u32 baseaddr) | |||
709 | printk("\n"); | 760 | printk("\n"); |
710 | } | 761 | } |
711 | 762 | ||
763 | #if _MV_DUMP | ||
712 | static void mvs_hba_sb_dump(struct mvs_info *mvi, u32 tag, | 764 | static void mvs_hba_sb_dump(struct mvs_info *mvi, u32 tag, |
713 | enum sas_protocol proto) | 765 | enum sas_protocol proto) |
714 | { | 766 | { |
715 | #if _MV_DUMP | ||
716 | u32 offset; | 767 | u32 offset; |
717 | struct pci_dev *pdev = mvi->pdev; | 768 | struct pci_dev *pdev = mvi->pdev; |
718 | struct mvs_slot_info *slot = &mvi->slot_info[tag]; | 769 | struct mvs_slot_info *slot = &mvi->slot_info[tag]; |
@@ -723,14 +774,14 @@ static void mvs_hba_sb_dump(struct mvs_info *mvi, u32 tag, | |||
723 | tag); | 774 | tag); |
724 | mvs_hexdump(32, (u8 *) slot->response, | 775 | mvs_hexdump(32, (u8 *) slot->response, |
725 | (u32) slot->buf_dma + offset); | 776 | (u32) slot->buf_dma + offset); |
726 | #endif | ||
727 | } | 777 | } |
778 | #endif | ||
728 | 779 | ||
729 | static void mvs_hba_memory_dump(struct mvs_info *mvi, u32 tag, | 780 | static void mvs_hba_memory_dump(struct mvs_info *mvi, u32 tag, |
730 | enum sas_protocol proto) | 781 | enum sas_protocol proto) |
731 | { | 782 | { |
732 | #if _MV_DUMP | 783 | #if _MV_DUMP |
733 | u32 sz, w_ptr, r_ptr; | 784 | u32 sz, w_ptr; |
734 | u64 addr; | 785 | u64 addr; |
735 | void __iomem *regs = mvi->regs; | 786 | void __iomem *regs = mvi->regs; |
736 | struct pci_dev *pdev = mvi->pdev; | 787 | struct pci_dev *pdev = mvi->pdev; |
@@ -738,12 +789,10 @@ static void mvs_hba_memory_dump(struct mvs_info *mvi, u32 tag, | |||
738 | 789 | ||
739 | /*Delivery Queue */ | 790 | /*Delivery Queue */ |
740 | sz = mr32(TX_CFG) & TX_RING_SZ_MASK; | 791 | sz = mr32(TX_CFG) & TX_RING_SZ_MASK; |
741 | w_ptr = mr32(TX_PROD_IDX) & TX_RING_SZ_MASK; | 792 | w_ptr = slot->tx; |
742 | r_ptr = mr32(TX_CONS_IDX) & TX_RING_SZ_MASK; | ||
743 | addr = mr32(TX_HI) << 16 << 16 | mr32(TX_LO); | 793 | addr = mr32(TX_HI) << 16 << 16 | mr32(TX_LO); |
744 | dev_printk(KERN_DEBUG, &pdev->dev, | 794 | dev_printk(KERN_DEBUG, &pdev->dev, |
745 | "Delivery Queue Size=%04d , WRT_PTR=%04X , RD_PTR=%04X\n", | 795 | "Delivery Queue Size=%04d , WRT_PTR=%04X\n", sz, w_ptr); |
746 | sz, w_ptr, r_ptr); | ||
747 | dev_printk(KERN_DEBUG, &pdev->dev, | 796 | dev_printk(KERN_DEBUG, &pdev->dev, |
748 | "Delivery Queue Base Address=0x%llX (PA)" | 797 | "Delivery Queue Base Address=0x%llX (PA)" |
749 | "(tx_dma=0x%llX), Entry=%04d\n", | 798 | "(tx_dma=0x%llX), Entry=%04d\n", |
@@ -751,11 +800,11 @@ static void mvs_hba_memory_dump(struct mvs_info *mvi, u32 tag, | |||
751 | mvs_hexdump(sizeof(u32), (u8 *)(&mvi->tx[mvi->tx_prod]), | 800 | mvs_hexdump(sizeof(u32), (u8 *)(&mvi->tx[mvi->tx_prod]), |
752 | (u32) mvi->tx_dma + sizeof(u32) * w_ptr); | 801 | (u32) mvi->tx_dma + sizeof(u32) * w_ptr); |
753 | /*Command List */ | 802 | /*Command List */ |
754 | addr = mr32(CMD_LIST_HI) << 16 << 16 | mr32(CMD_LIST_LO); | 803 | addr = mvi->slot_dma; |
755 | dev_printk(KERN_DEBUG, &pdev->dev, | 804 | dev_printk(KERN_DEBUG, &pdev->dev, |
756 | "Command List Base Address=0x%llX (PA)" | 805 | "Command List Base Address=0x%llX (PA)" |
757 | "(slot_dma=0x%llX), Header=%03d\n", | 806 | "(slot_dma=0x%llX), Header=%03d\n", |
758 | addr, mvi->slot_dma, tag); | 807 | addr, slot->buf_dma, tag); |
759 | dev_printk(KERN_DEBUG, &pdev->dev, "Command Header[%03d]:\n", tag); | 808 | dev_printk(KERN_DEBUG, &pdev->dev, "Command Header[%03d]:\n", tag); |
760 | /*mvs_cmd_hdr */ | 809 | /*mvs_cmd_hdr */ |
761 | mvs_hexdump(sizeof(struct mvs_cmd_hdr), (u8 *)(&mvi->slot[tag]), | 810 | mvs_hexdump(sizeof(struct mvs_cmd_hdr), (u8 *)(&mvi->slot[tag]), |
@@ -779,7 +828,7 @@ static void mvs_hba_memory_dump(struct mvs_info *mvi, u32 tag, | |||
779 | 828 | ||
780 | static void mvs_hba_cq_dump(struct mvs_info *mvi) | 829 | static void mvs_hba_cq_dump(struct mvs_info *mvi) |
781 | { | 830 | { |
782 | #if _MV_DUMP | 831 | #if (_MV_DUMP > 2) |
783 | u64 addr; | 832 | u64 addr; |
784 | void __iomem *regs = mvi->regs; | 833 | void __iomem *regs = mvi->regs; |
785 | struct pci_dev *pdev = mvi->pdev; | 834 | struct pci_dev *pdev = mvi->pdev; |
@@ -788,8 +837,8 @@ static void mvs_hba_cq_dump(struct mvs_info *mvi) | |||
788 | 837 | ||
789 | /*Completion Queue */ | 838 | /*Completion Queue */ |
790 | addr = mr32(RX_HI) << 16 << 16 | mr32(RX_LO); | 839 | addr = mr32(RX_HI) << 16 << 16 | mr32(RX_LO); |
791 | dev_printk(KERN_DEBUG, &pdev->dev, "Completion Task = 0x%08X\n", | 840 | dev_printk(KERN_DEBUG, &pdev->dev, "Completion Task = 0x%p\n", |
792 | (u32) mvi->slot_info[rx_desc & RXQ_SLOT_MASK].task); | 841 | mvi->slot_info[rx_desc & RXQ_SLOT_MASK].task); |
793 | dev_printk(KERN_DEBUG, &pdev->dev, | 842 | dev_printk(KERN_DEBUG, &pdev->dev, |
794 | "Completion List Base Address=0x%llX (PA), " | 843 | "Completion List Base Address=0x%llX (PA), " |
795 | "CQ_Entry=%04d, CQ_WP=0x%08X\n", | 844 | "CQ_Entry=%04d, CQ_WP=0x%08X\n", |
@@ -854,34 +903,53 @@ static int pci_go_64(struct pci_dev *pdev) | |||
854 | return rc; | 903 | return rc; |
855 | } | 904 | } |
856 | 905 | ||
906 | static int mvs_find_tag(struct mvs_info *mvi, struct sas_task *task, u32 *tag) | ||
907 | { | ||
908 | if (task->lldd_task) { | ||
909 | struct mvs_slot_info *slot; | ||
910 | slot = (struct mvs_slot_info *) task->lldd_task; | ||
911 | *tag = slot - mvi->slot_info; | ||
912 | return 1; | ||
913 | } | ||
914 | return 0; | ||
915 | } | ||
916 | |||
857 | static void mvs_tag_clear(struct mvs_info *mvi, u32 tag) | 917 | static void mvs_tag_clear(struct mvs_info *mvi, u32 tag) |
858 | { | 918 | { |
859 | mvi->tag_in = (mvi->tag_in + 1) & (MVS_SLOTS - 1); | 919 | void *bitmap = (void *) &mvi->tags; |
860 | mvi->tags[mvi->tag_in] = tag; | 920 | clear_bit(tag, bitmap); |
861 | } | 921 | } |
862 | 922 | ||
863 | static void mvs_tag_free(struct mvs_info *mvi, u32 tag) | 923 | static void mvs_tag_free(struct mvs_info *mvi, u32 tag) |
864 | { | 924 | { |
865 | mvi->tag_out = (mvi->tag_out - 1) & (MVS_SLOTS - 1); | 925 | mvs_tag_clear(mvi, tag); |
926 | } | ||
927 | |||
928 | static void mvs_tag_set(struct mvs_info *mvi, unsigned int tag) | ||
929 | { | ||
930 | void *bitmap = (void *) &mvi->tags; | ||
931 | set_bit(tag, bitmap); | ||
866 | } | 932 | } |
867 | 933 | ||
868 | static int mvs_tag_alloc(struct mvs_info *mvi, u32 *tag_out) | 934 | static int mvs_tag_alloc(struct mvs_info *mvi, u32 *tag_out) |
869 | { | 935 | { |
870 | if (mvi->tag_out != mvi->tag_in) { | 936 | unsigned int index, tag; |
871 | *tag_out = mvi->tags[mvi->tag_out]; | 937 | void *bitmap = (void *) &mvi->tags; |
872 | mvi->tag_out = (mvi->tag_out + 1) & (MVS_SLOTS - 1); | 938 | |
873 | return 0; | 939 | index = find_first_zero_bit(bitmap, MVS_SLOTS); |
874 | } | 940 | tag = index; |
875 | return -EBUSY; | 941 | if (tag >= MVS_SLOTS) |
942 | return -SAS_QUEUE_FULL; | ||
943 | mvs_tag_set(mvi, tag); | ||
944 | *tag_out = tag; | ||
945 | return 0; | ||
876 | } | 946 | } |
877 | 947 | ||
878 | static void mvs_tag_init(struct mvs_info *mvi) | 948 | static void mvs_tag_init(struct mvs_info *mvi) |
879 | { | 949 | { |
880 | int i; | 950 | int i; |
881 | for (i = 0; i < MVS_SLOTS; ++i) | 951 | for (i = 0; i < MVS_SLOTS; ++i) |
882 | mvi->tags[i] = i; | 952 | mvs_tag_clear(mvi, i); |
883 | mvi->tag_out = 0; | ||
884 | mvi->tag_in = MVS_SLOTS - 1; | ||
885 | } | 953 | } |
886 | 954 | ||
887 | #ifndef MVS_DISABLE_NVRAM | 955 | #ifndef MVS_DISABLE_NVRAM |
@@ -1013,10 +1081,21 @@ err_out: | |||
1013 | static void mvs_bytes_dmaed(struct mvs_info *mvi, int i) | 1081 | static void mvs_bytes_dmaed(struct mvs_info *mvi, int i) |
1014 | { | 1082 | { |
1015 | struct mvs_phy *phy = &mvi->phy[i]; | 1083 | struct mvs_phy *phy = &mvi->phy[i]; |
1084 | struct asd_sas_phy *sas_phy = mvi->sas.sas_phy[i]; | ||
1016 | 1085 | ||
1017 | if (!phy->phy_attached) | 1086 | if (!phy->phy_attached) |
1018 | return; | 1087 | return; |
1019 | 1088 | ||
1089 | if (sas_phy->phy) { | ||
1090 | struct sas_phy *sphy = sas_phy->phy; | ||
1091 | |||
1092 | sphy->negotiated_linkrate = sas_phy->linkrate; | ||
1093 | sphy->minimum_linkrate = phy->minimum_linkrate; | ||
1094 | sphy->minimum_linkrate_hw = SAS_LINK_RATE_1_5_GBPS; | ||
1095 | sphy->maximum_linkrate = phy->maximum_linkrate; | ||
1096 | sphy->maximum_linkrate_hw = SAS_LINK_RATE_3_0_GBPS; | ||
1097 | } | ||
1098 | |||
1020 | if (phy->phy_type & PORT_TYPE_SAS) { | 1099 | if (phy->phy_type & PORT_TYPE_SAS) { |
1021 | struct sas_identify_frame *id; | 1100 | struct sas_identify_frame *id; |
1022 | 1101 | ||
@@ -1053,80 +1132,149 @@ static void mvs_scan_start(struct Scsi_Host *shost) | |||
1053 | } | 1132 | } |
1054 | } | 1133 | } |
1055 | 1134 | ||
1056 | static int mvs_sas_slave_alloc(struct scsi_device *scsi_dev) | 1135 | static int mvs_slave_configure(struct scsi_device *sdev) |
1057 | { | 1136 | { |
1058 | int rc; | 1137 | struct domain_device *dev = sdev_to_domain_dev(sdev); |
1138 | int ret = sas_slave_configure(sdev); | ||
1059 | 1139 | ||
1060 | rc = sas_slave_alloc(scsi_dev); | 1140 | if (ret) |
1141 | return ret; | ||
1061 | 1142 | ||
1062 | return rc; | 1143 | if (dev_is_sata(dev)) { |
1144 | /* struct ata_port *ap = dev->sata_dev.ap; */ | ||
1145 | /* struct ata_device *adev = ap->link.device; */ | ||
1146 | |||
1147 | /* clamp at no NCQ for the time being */ | ||
1148 | /* adev->flags |= ATA_DFLAG_NCQ_OFF; */ | ||
1149 | scsi_adjust_queue_depth(sdev, MSG_SIMPLE_TAG, 1); | ||
1150 | } | ||
1151 | return 0; | ||
1063 | } | 1152 | } |
1064 | 1153 | ||
1065 | static void mvs_int_port(struct mvs_info *mvi, int port_no, u32 events) | 1154 | static void mvs_int_port(struct mvs_info *mvi, int phy_no, u32 events) |
1066 | { | 1155 | { |
1067 | struct pci_dev *pdev = mvi->pdev; | 1156 | struct pci_dev *pdev = mvi->pdev; |
1068 | struct sas_ha_struct *sas_ha = &mvi->sas; | 1157 | struct sas_ha_struct *sas_ha = &mvi->sas; |
1069 | struct mvs_phy *phy = &mvi->phy[port_no]; | 1158 | struct mvs_phy *phy = &mvi->phy[phy_no]; |
1070 | struct asd_sas_phy *sas_phy = &phy->sas_phy; | 1159 | struct asd_sas_phy *sas_phy = &phy->sas_phy; |
1071 | 1160 | ||
1072 | phy->irq_status = mvs_read_port_irq_stat(mvi, port_no); | 1161 | phy->irq_status = mvs_read_port_irq_stat(mvi, phy_no); |
1073 | /* | 1162 | /* |
1074 | * events is port event now , | 1163 | * events is port event now , |
1075 | * we need check the interrupt status which belongs to per port. | 1164 | * we need check the interrupt status which belongs to per port. |
1076 | */ | 1165 | */ |
1077 | dev_printk(KERN_DEBUG, &pdev->dev, | 1166 | dev_printk(KERN_DEBUG, &pdev->dev, |
1078 | "Port %d Event = %X\n", | 1167 | "Port %d Event = %X\n", |
1079 | port_no, phy->irq_status); | 1168 | phy_no, phy->irq_status); |
1080 | 1169 | ||
1081 | if (phy->irq_status & (PHYEV_POOF | PHYEV_DEC_ERR)) { | 1170 | if (phy->irq_status & (PHYEV_POOF | PHYEV_DEC_ERR)) { |
1082 | if (!mvs_is_phy_ready(mvi, port_no)) { | 1171 | mvs_release_task(mvi, phy_no); |
1172 | if (!mvs_is_phy_ready(mvi, phy_no)) { | ||
1083 | sas_phy_disconnected(sas_phy); | 1173 | sas_phy_disconnected(sas_phy); |
1084 | sas_ha->notify_phy_event(sas_phy, PHYE_LOSS_OF_SIGNAL); | 1174 | sas_ha->notify_phy_event(sas_phy, PHYE_LOSS_OF_SIGNAL); |
1175 | dev_printk(KERN_INFO, &pdev->dev, | ||
1176 | "Port %d Unplug Notice\n", phy_no); | ||
1177 | |||
1085 | } else | 1178 | } else |
1086 | mvs_phy_control(sas_phy, PHY_FUNC_LINK_RESET, NULL); | 1179 | mvs_phy_control(sas_phy, PHY_FUNC_LINK_RESET, NULL); |
1087 | } | 1180 | } |
1088 | if (!(phy->irq_status & PHYEV_DEC_ERR)) { | 1181 | if (!(phy->irq_status & PHYEV_DEC_ERR)) { |
1089 | if (phy->irq_status & PHYEV_COMWAKE) { | 1182 | if (phy->irq_status & PHYEV_COMWAKE) { |
1090 | u32 tmp = mvs_read_port_irq_mask(mvi, port_no); | 1183 | u32 tmp = mvs_read_port_irq_mask(mvi, phy_no); |
1091 | mvs_write_port_irq_mask(mvi, port_no, | 1184 | mvs_write_port_irq_mask(mvi, phy_no, |
1092 | tmp | PHYEV_SIG_FIS); | 1185 | tmp | PHYEV_SIG_FIS); |
1093 | } | 1186 | } |
1094 | if (phy->irq_status & (PHYEV_SIG_FIS | PHYEV_ID_DONE)) { | 1187 | if (phy->irq_status & (PHYEV_SIG_FIS | PHYEV_ID_DONE)) { |
1095 | phy->phy_status = mvs_is_phy_ready(mvi, port_no); | 1188 | phy->phy_status = mvs_is_phy_ready(mvi, phy_no); |
1096 | if (phy->phy_status) { | 1189 | if (phy->phy_status) { |
1097 | mvs_detect_porttype(mvi, port_no); | 1190 | mvs_detect_porttype(mvi, phy_no); |
1098 | 1191 | ||
1099 | if (phy->phy_type & PORT_TYPE_SATA) { | 1192 | if (phy->phy_type & PORT_TYPE_SATA) { |
1100 | u32 tmp = mvs_read_port_irq_mask(mvi, | 1193 | u32 tmp = mvs_read_port_irq_mask(mvi, |
1101 | port_no); | 1194 | phy_no); |
1102 | tmp &= ~PHYEV_SIG_FIS; | 1195 | tmp &= ~PHYEV_SIG_FIS; |
1103 | mvs_write_port_irq_mask(mvi, | 1196 | mvs_write_port_irq_mask(mvi, |
1104 | port_no, tmp); | 1197 | phy_no, tmp); |
1105 | } | 1198 | } |
1106 | 1199 | ||
1107 | mvs_update_phyinfo(mvi, port_no, 0); | 1200 | mvs_update_phyinfo(mvi, phy_no, 0); |
1108 | sas_ha->notify_phy_event(sas_phy, | 1201 | sas_ha->notify_phy_event(sas_phy, |
1109 | PHYE_OOB_DONE); | 1202 | PHYE_OOB_DONE); |
1110 | mvs_bytes_dmaed(mvi, port_no); | 1203 | mvs_bytes_dmaed(mvi, phy_no); |
1111 | } else { | 1204 | } else { |
1112 | dev_printk(KERN_DEBUG, &pdev->dev, | 1205 | dev_printk(KERN_DEBUG, &pdev->dev, |
1113 | "plugin interrupt but phy is gone\n"); | 1206 | "plugin interrupt but phy is gone\n"); |
1114 | mvs_phy_control(sas_phy, PHY_FUNC_LINK_RESET, | 1207 | mvs_phy_control(sas_phy, PHY_FUNC_LINK_RESET, |
1115 | NULL); | 1208 | NULL); |
1116 | } | 1209 | } |
1117 | } else if (phy->irq_status & PHYEV_BROAD_CH) | 1210 | } else if (phy->irq_status & PHYEV_BROAD_CH) { |
1211 | mvs_release_task(mvi, phy_no); | ||
1118 | sas_ha->notify_port_event(sas_phy, | 1212 | sas_ha->notify_port_event(sas_phy, |
1119 | PORTE_BROADCAST_RCVD); | 1213 | PORTE_BROADCAST_RCVD); |
1214 | } | ||
1120 | } | 1215 | } |
1121 | mvs_write_port_irq_stat(mvi, port_no, phy->irq_status); | 1216 | mvs_write_port_irq_stat(mvi, phy_no, phy->irq_status); |
1122 | } | 1217 | } |
1123 | 1218 | ||
1124 | static void mvs_int_sata(struct mvs_info *mvi) | 1219 | static void mvs_int_sata(struct mvs_info *mvi) |
1125 | { | 1220 | { |
1126 | /* FIXME */ | 1221 | u32 tmp; |
1222 | void __iomem *regs = mvi->regs; | ||
1223 | tmp = mr32(INT_STAT_SRS); | ||
1224 | mw32(INT_STAT_SRS, tmp & 0xFFFF); | ||
1225 | } | ||
1226 | |||
1227 | static void mvs_slot_reset(struct mvs_info *mvi, struct sas_task *task, | ||
1228 | u32 slot_idx) | ||
1229 | { | ||
1230 | void __iomem *regs = mvi->regs; | ||
1231 | struct domain_device *dev = task->dev; | ||
1232 | struct asd_sas_port *sas_port = dev->port; | ||
1233 | struct mvs_port *port = mvi->slot_info[slot_idx].port; | ||
1234 | u32 reg_set, phy_mask; | ||
1235 | |||
1236 | if (!sas_protocol_ata(task->task_proto)) { | ||
1237 | reg_set = 0; | ||
1238 | phy_mask = (port->wide_port_phymap) ? port->wide_port_phymap : | ||
1239 | sas_port->phy_mask; | ||
1240 | } else { | ||
1241 | reg_set = port->taskfileset; | ||
1242 | phy_mask = sas_port->phy_mask; | ||
1243 | } | ||
1244 | mvi->tx[mvi->tx_prod] = cpu_to_le32(TXQ_MODE_I | slot_idx | | ||
1245 | (TXQ_CMD_SLOT_RESET << TXQ_CMD_SHIFT) | | ||
1246 | (phy_mask << TXQ_PHY_SHIFT) | | ||
1247 | (reg_set << TXQ_SRS_SHIFT)); | ||
1248 | |||
1249 | mw32(TX_PROD_IDX, mvi->tx_prod); | ||
1250 | mvi->tx_prod = (mvi->tx_prod + 1) & (MVS_CHIP_SLOT_SZ - 1); | ||
1251 | } | ||
1252 | |||
1253 | static int mvs_sata_done(struct mvs_info *mvi, struct sas_task *task, | ||
1254 | u32 slot_idx, int err) | ||
1255 | { | ||
1256 | struct mvs_port *port = mvi->slot_info[slot_idx].port; | ||
1257 | struct task_status_struct *tstat = &task->task_status; | ||
1258 | struct ata_task_resp *resp = (struct ata_task_resp *)tstat->buf; | ||
1259 | int stat = SAM_GOOD; | ||
1260 | |||
1261 | resp->frame_len = sizeof(struct dev_to_host_fis); | ||
1262 | memcpy(&resp->ending_fis[0], | ||
1263 | SATA_RECEIVED_D2H_FIS(port->taskfileset), | ||
1264 | sizeof(struct dev_to_host_fis)); | ||
1265 | tstat->buf_valid_size = sizeof(*resp); | ||
1266 | if (unlikely(err)) | ||
1267 | stat = SAS_PROTO_RESPONSE; | ||
1268 | return stat; | ||
1127 | } | 1269 | } |
1128 | 1270 | ||
1129 | static void mvs_slot_free(struct mvs_info *mvi, struct sas_task *task, | 1271 | static void mvs_slot_free(struct mvs_info *mvi, u32 rx_desc) |
1272 | { | ||
1273 | u32 slot_idx = rx_desc & RXQ_SLOT_MASK; | ||
1274 | mvs_tag_clear(mvi, slot_idx); | ||
1275 | } | ||
1276 | |||
1277 | static void mvs_slot_task_free(struct mvs_info *mvi, struct sas_task *task, | ||
1130 | struct mvs_slot_info *slot, u32 slot_idx) | 1278 | struct mvs_slot_info *slot, u32 slot_idx) |
1131 | { | 1279 | { |
1132 | if (!sas_protocol_ata(task->task_proto)) | 1280 | if (!sas_protocol_ata(task->task_proto)) |
@@ -1149,38 +1297,58 @@ static void mvs_slot_free(struct mvs_info *mvi, struct sas_task *task, | |||
1149 | /* do nothing */ | 1297 | /* do nothing */ |
1150 | break; | 1298 | break; |
1151 | } | 1299 | } |
1152 | 1300 | list_del(&slot->list); | |
1301 | task->lldd_task = NULL; | ||
1153 | slot->task = NULL; | 1302 | slot->task = NULL; |
1154 | mvs_tag_clear(mvi, slot_idx); | 1303 | slot->port = NULL; |
1155 | } | 1304 | } |
1156 | 1305 | ||
1157 | static void mvs_slot_err(struct mvs_info *mvi, struct sas_task *task, | 1306 | static int mvs_slot_err(struct mvs_info *mvi, struct sas_task *task, |
1158 | u32 slot_idx) | 1307 | u32 slot_idx) |
1159 | { | 1308 | { |
1160 | struct mvs_slot_info *slot = &mvi->slot_info[slot_idx]; | 1309 | struct mvs_slot_info *slot = &mvi->slot_info[slot_idx]; |
1161 | u64 err_dw0 = *(u32 *) slot->response; | 1310 | u32 err_dw0 = le32_to_cpu(*(u32 *) (slot->response)); |
1162 | void __iomem *regs = mvi->regs; | 1311 | u32 err_dw1 = le32_to_cpu(*(u32 *) (slot->response + 4)); |
1163 | u32 tmp; | 1312 | int stat = SAM_CHECK_COND; |
1164 | 1313 | ||
1165 | if (err_dw0 & CMD_ISS_STPD) | 1314 | if (err_dw1 & SLOT_BSY_ERR) { |
1166 | if (sas_protocol_ata(task->task_proto)) { | 1315 | stat = SAS_QUEUE_FULL; |
1167 | tmp = mr32(INT_STAT_SRS); | 1316 | mvs_slot_reset(mvi, task, slot_idx); |
1168 | mw32(INT_STAT_SRS, tmp & 0xFFFF); | 1317 | } |
1169 | } | 1318 | switch (task->task_proto) { |
1319 | case SAS_PROTOCOL_SSP: | ||
1320 | break; | ||
1321 | case SAS_PROTOCOL_SMP: | ||
1322 | break; | ||
1323 | case SAS_PROTOCOL_SATA: | ||
1324 | case SAS_PROTOCOL_STP: | ||
1325 | case SAS_PROTOCOL_SATA | SAS_PROTOCOL_STP: | ||
1326 | if (err_dw0 & TFILE_ERR) | ||
1327 | stat = mvs_sata_done(mvi, task, slot_idx, 1); | ||
1328 | break; | ||
1329 | default: | ||
1330 | break; | ||
1331 | } | ||
1170 | 1332 | ||
1171 | mvs_hba_sb_dump(mvi, slot_idx, task->task_proto); | 1333 | mvs_hexdump(16, (u8 *) slot->response, 0); |
1334 | return stat; | ||
1172 | } | 1335 | } |
1173 | 1336 | ||
1174 | static int mvs_slot_complete(struct mvs_info *mvi, u32 rx_desc) | 1337 | static int mvs_slot_complete(struct mvs_info *mvi, u32 rx_desc, u32 flags) |
1175 | { | 1338 | { |
1176 | u32 slot_idx = rx_desc & RXQ_SLOT_MASK; | 1339 | u32 slot_idx = rx_desc & RXQ_SLOT_MASK; |
1177 | struct mvs_slot_info *slot = &mvi->slot_info[slot_idx]; | 1340 | struct mvs_slot_info *slot = &mvi->slot_info[slot_idx]; |
1178 | struct sas_task *task = slot->task; | 1341 | struct sas_task *task = slot->task; |
1179 | struct task_status_struct *tstat = &task->task_status; | 1342 | struct task_status_struct *tstat; |
1180 | struct mvs_port *port = &mvi->port[task->dev->port->id]; | 1343 | struct mvs_port *port; |
1181 | bool aborted; | 1344 | bool aborted; |
1182 | void *to; | 1345 | void *to; |
1183 | 1346 | ||
1347 | if (unlikely(!task || !task->lldd_task)) | ||
1348 | return -1; | ||
1349 | |||
1350 | mvs_hba_cq_dump(mvi); | ||
1351 | |||
1184 | spin_lock(&task->task_state_lock); | 1352 | spin_lock(&task->task_state_lock); |
1185 | aborted = task->task_state_flags & SAS_TASK_STATE_ABORTED; | 1353 | aborted = task->task_state_flags & SAS_TASK_STATE_ABORTED; |
1186 | if (!aborted) { | 1354 | if (!aborted) { |
@@ -1190,22 +1358,27 @@ static int mvs_slot_complete(struct mvs_info *mvi, u32 rx_desc) | |||
1190 | } | 1358 | } |
1191 | spin_unlock(&task->task_state_lock); | 1359 | spin_unlock(&task->task_state_lock); |
1192 | 1360 | ||
1193 | if (aborted) | 1361 | if (aborted) { |
1362 | mvs_slot_task_free(mvi, task, slot, slot_idx); | ||
1363 | mvs_slot_free(mvi, rx_desc); | ||
1194 | return -1; | 1364 | return -1; |
1365 | } | ||
1195 | 1366 | ||
1367 | port = slot->port; | ||
1368 | tstat = &task->task_status; | ||
1196 | memset(tstat, 0, sizeof(*tstat)); | 1369 | memset(tstat, 0, sizeof(*tstat)); |
1197 | tstat->resp = SAS_TASK_COMPLETE; | 1370 | tstat->resp = SAS_TASK_COMPLETE; |
1198 | 1371 | ||
1199 | 1372 | if (unlikely(!port->port_attached || flags)) { | |
1200 | if (unlikely(!port->port_attached)) { | 1373 | mvs_slot_err(mvi, task, slot_idx); |
1201 | tstat->stat = SAS_PHY_DOWN; | 1374 | if (!sas_protocol_ata(task->task_proto)) |
1375 | tstat->stat = SAS_PHY_DOWN; | ||
1202 | goto out; | 1376 | goto out; |
1203 | } | 1377 | } |
1204 | 1378 | ||
1205 | /* error info record present */ | 1379 | /* error info record present */ |
1206 | if ((rx_desc & RXQ_ERR) && (*(u64 *) slot->response)) { | 1380 | if (unlikely((rx_desc & RXQ_ERR) && (*(u64 *) slot->response))) { |
1207 | tstat->stat = SAM_CHECK_COND; | 1381 | tstat->stat = mvs_slot_err(mvi, task, slot_idx); |
1208 | mvs_slot_err(mvi, task, slot_idx); | ||
1209 | goto out; | 1382 | goto out; |
1210 | } | 1383 | } |
1211 | 1384 | ||
@@ -1242,21 +1415,7 @@ static int mvs_slot_complete(struct mvs_info *mvi, u32 rx_desc) | |||
1242 | case SAS_PROTOCOL_SATA: | 1415 | case SAS_PROTOCOL_SATA: |
1243 | case SAS_PROTOCOL_STP: | 1416 | case SAS_PROTOCOL_STP: |
1244 | case SAS_PROTOCOL_SATA | SAS_PROTOCOL_STP: { | 1417 | case SAS_PROTOCOL_SATA | SAS_PROTOCOL_STP: { |
1245 | struct ata_task_resp *resp = | 1418 | tstat->stat = mvs_sata_done(mvi, task, slot_idx, 0); |
1246 | (struct ata_task_resp *)tstat->buf; | ||
1247 | |||
1248 | if ((rx_desc & (RXQ_DONE | RXQ_ERR | RXQ_ATTN)) == | ||
1249 | RXQ_DONE) | ||
1250 | tstat->stat = SAM_GOOD; | ||
1251 | else | ||
1252 | tstat->stat = SAM_CHECK_COND; | ||
1253 | |||
1254 | resp->frame_len = sizeof(struct dev_to_host_fis); | ||
1255 | memcpy(&resp->ending_fis[0], | ||
1256 | SATA_RECEIVED_D2H_FIS(port->taskfileset), | ||
1257 | sizeof(struct dev_to_host_fis)); | ||
1258 | if (resp->ending_fis[2] & ATA_ERR) | ||
1259 | mvs_hexdump(16, resp->ending_fis, 0); | ||
1260 | break; | 1419 | break; |
1261 | } | 1420 | } |
1262 | 1421 | ||
@@ -1266,11 +1425,34 @@ static int mvs_slot_complete(struct mvs_info *mvi, u32 rx_desc) | |||
1266 | } | 1425 | } |
1267 | 1426 | ||
1268 | out: | 1427 | out: |
1269 | mvs_slot_free(mvi, task, slot, slot_idx); | 1428 | mvs_slot_task_free(mvi, task, slot, slot_idx); |
1429 | if (unlikely(tstat->stat != SAS_QUEUE_FULL)) | ||
1430 | mvs_slot_free(mvi, rx_desc); | ||
1431 | |||
1432 | spin_unlock(&mvi->lock); | ||
1270 | task->task_done(task); | 1433 | task->task_done(task); |
1434 | spin_lock(&mvi->lock); | ||
1271 | return tstat->stat; | 1435 | return tstat->stat; |
1272 | } | 1436 | } |
1273 | 1437 | ||
1438 | static void mvs_release_task(struct mvs_info *mvi, int phy_no) | ||
1439 | { | ||
1440 | struct list_head *pos, *n; | ||
1441 | struct mvs_slot_info *slot; | ||
1442 | struct mvs_phy *phy = &mvi->phy[phy_no]; | ||
1443 | struct mvs_port *port = phy->port; | ||
1444 | u32 rx_desc; | ||
1445 | |||
1446 | if (!port) | ||
1447 | return; | ||
1448 | |||
1449 | list_for_each_safe(pos, n, &port->list) { | ||
1450 | slot = container_of(pos, struct mvs_slot_info, list); | ||
1451 | rx_desc = (u32) (slot - mvi->slot_info); | ||
1452 | mvs_slot_complete(mvi, rx_desc, 1); | ||
1453 | } | ||
1454 | } | ||
1455 | |||
1274 | static void mvs_int_full(struct mvs_info *mvi) | 1456 | static void mvs_int_full(struct mvs_info *mvi) |
1275 | { | 1457 | { |
1276 | void __iomem *regs = mvi->regs; | 1458 | void __iomem *regs = mvi->regs; |
@@ -1305,40 +1487,43 @@ static int mvs_int_rx(struct mvs_info *mvi, bool self_clear) | |||
1305 | * we don't have to stall the CPU reading that register. | 1487 | * we don't have to stall the CPU reading that register. |
1306 | * The actual RX ring is offset by one dword, due to this. | 1488 | * The actual RX ring is offset by one dword, due to this. |
1307 | */ | 1489 | */ |
1308 | rx_prod_idx = mr32(RX_CONS_IDX) & RX_RING_SZ_MASK; | 1490 | rx_prod_idx = mvi->rx_cons; |
1309 | if (rx_prod_idx == 0xfff) { /* h/w hasn't touched RX ring yet */ | 1491 | mvi->rx_cons = le32_to_cpu(mvi->rx[0]); |
1310 | mvi->rx_cons = 0xfff; | 1492 | if (mvi->rx_cons == 0xfff) /* h/w hasn't touched RX ring yet */ |
1311 | return 0; | 1493 | return 0; |
1312 | } | ||
1313 | 1494 | ||
1314 | /* The CMPL_Q may come late, read from register and try again | 1495 | /* The CMPL_Q may come late, read from register and try again |
1315 | * note: if coalescing is enabled, | 1496 | * note: if coalescing is enabled, |
1316 | * it will need to read from register every time for sure | 1497 | * it will need to read from register every time for sure |
1317 | */ | 1498 | */ |
1318 | if (mvi->rx_cons == rx_prod_idx) | 1499 | if (mvi->rx_cons == rx_prod_idx) |
1319 | return 0; | 1500 | mvi->rx_cons = mr32(RX_CONS_IDX) & RX_RING_SZ_MASK; |
1320 | 1501 | ||
1321 | if (mvi->rx_cons == 0xfff) | 1502 | if (mvi->rx_cons == rx_prod_idx) |
1322 | mvi->rx_cons = MVS_RX_RING_SZ - 1; | 1503 | return 0; |
1323 | 1504 | ||
1324 | while (mvi->rx_cons != rx_prod_idx) { | 1505 | while (mvi->rx_cons != rx_prod_idx) { |
1325 | 1506 | ||
1326 | /* increment our internal RX consumer pointer */ | 1507 | /* increment our internal RX consumer pointer */ |
1327 | mvi->rx_cons = (mvi->rx_cons + 1) & (MVS_RX_RING_SZ - 1); | 1508 | rx_prod_idx = (rx_prod_idx + 1) & (MVS_RX_RING_SZ - 1); |
1328 | 1509 | ||
1329 | rx_desc = le32_to_cpu(mvi->rx[mvi->rx_cons + 1]); | 1510 | rx_desc = le32_to_cpu(mvi->rx[rx_prod_idx + 1]); |
1330 | |||
1331 | mvs_hba_cq_dump(mvi); | ||
1332 | 1511 | ||
1333 | if (likely(rx_desc & RXQ_DONE)) | 1512 | if (likely(rx_desc & RXQ_DONE)) |
1334 | mvs_slot_complete(mvi, rx_desc); | 1513 | mvs_slot_complete(mvi, rx_desc, 0); |
1335 | if (rx_desc & RXQ_ATTN) { | 1514 | if (rx_desc & RXQ_ATTN) { |
1336 | attn = true; | 1515 | attn = true; |
1337 | dev_printk(KERN_DEBUG, &pdev->dev, "ATTN %X\n", | 1516 | dev_printk(KERN_DEBUG, &pdev->dev, "ATTN %X\n", |
1338 | rx_desc); | 1517 | rx_desc); |
1339 | } else if (rx_desc & RXQ_ERR) { | 1518 | } else if (rx_desc & RXQ_ERR) { |
1519 | if (!(rx_desc & RXQ_DONE)) | ||
1520 | mvs_slot_complete(mvi, rx_desc, 0); | ||
1340 | dev_printk(KERN_DEBUG, &pdev->dev, "RXQ_ERR %X\n", | 1521 | dev_printk(KERN_DEBUG, &pdev->dev, "RXQ_ERR %X\n", |
1341 | rx_desc); | 1522 | rx_desc); |
1523 | } else if (rx_desc & RXQ_SLOT_RESET) { | ||
1524 | dev_printk(KERN_DEBUG, &pdev->dev, "Slot reset[%X]\n", | ||
1525 | rx_desc); | ||
1526 | mvs_slot_free(mvi, rx_desc); | ||
1342 | } | 1527 | } |
1343 | } | 1528 | } |
1344 | 1529 | ||
@@ -1348,6 +1533,23 @@ static int mvs_int_rx(struct mvs_info *mvi, bool self_clear) | |||
1348 | return 0; | 1533 | return 0; |
1349 | } | 1534 | } |
1350 | 1535 | ||
1536 | #ifdef MVS_USE_TASKLET | ||
1537 | static void mvs_tasklet(unsigned long data) | ||
1538 | { | ||
1539 | struct mvs_info *mvi = (struct mvs_info *) data; | ||
1540 | unsigned long flags; | ||
1541 | |||
1542 | spin_lock_irqsave(&mvi->lock, flags); | ||
1543 | |||
1544 | #ifdef MVS_DISABLE_MSI | ||
1545 | mvs_int_full(mvi); | ||
1546 | #else | ||
1547 | mvs_int_rx(mvi, true); | ||
1548 | #endif | ||
1549 | spin_unlock_irqrestore(&mvi->lock, flags); | ||
1550 | } | ||
1551 | #endif | ||
1552 | |||
1351 | static irqreturn_t mvs_interrupt(int irq, void *opaque) | 1553 | static irqreturn_t mvs_interrupt(int irq, void *opaque) |
1352 | { | 1554 | { |
1353 | struct mvs_info *mvi = opaque; | 1555 | struct mvs_info *mvi = opaque; |
@@ -1356,18 +1558,21 @@ static irqreturn_t mvs_interrupt(int irq, void *opaque) | |||
1356 | 1558 | ||
1357 | stat = mr32(GBL_INT_STAT); | 1559 | stat = mr32(GBL_INT_STAT); |
1358 | 1560 | ||
1359 | /* clear CMD_CMPLT ASAP */ | ||
1360 | mw32_f(INT_STAT, CINT_DONE); | ||
1361 | |||
1362 | if (stat == 0 || stat == 0xffffffff) | 1561 | if (stat == 0 || stat == 0xffffffff) |
1363 | return IRQ_NONE; | 1562 | return IRQ_NONE; |
1364 | 1563 | ||
1564 | /* clear CMD_CMPLT ASAP */ | ||
1565 | mw32_f(INT_STAT, CINT_DONE); | ||
1566 | |||
1567 | #ifndef MVS_USE_TASKLET | ||
1365 | spin_lock(&mvi->lock); | 1568 | spin_lock(&mvi->lock); |
1366 | 1569 | ||
1367 | mvs_int_full(mvi); | 1570 | mvs_int_full(mvi); |
1368 | 1571 | ||
1369 | spin_unlock(&mvi->lock); | 1572 | spin_unlock(&mvi->lock); |
1370 | 1573 | #else | |
1574 | tasklet_schedule(&mvi->tasklet); | ||
1575 | #endif | ||
1371 | return IRQ_HANDLED; | 1576 | return IRQ_HANDLED; |
1372 | } | 1577 | } |
1373 | 1578 | ||
@@ -1376,12 +1581,15 @@ static irqreturn_t mvs_msi_interrupt(int irq, void *opaque) | |||
1376 | { | 1581 | { |
1377 | struct mvs_info *mvi = opaque; | 1582 | struct mvs_info *mvi = opaque; |
1378 | 1583 | ||
1584 | #ifndef MVS_USE_TASKLET | ||
1379 | spin_lock(&mvi->lock); | 1585 | spin_lock(&mvi->lock); |
1380 | 1586 | ||
1381 | mvs_int_rx(mvi, true); | 1587 | mvs_int_rx(mvi, true); |
1382 | 1588 | ||
1383 | spin_unlock(&mvi->lock); | 1589 | spin_unlock(&mvi->lock); |
1384 | 1590 | #else | |
1591 | tasklet_schedule(&mvi->tasklet); | ||
1592 | #endif | ||
1385 | return IRQ_HANDLED; | 1593 | return IRQ_HANDLED; |
1386 | } | 1594 | } |
1387 | #endif | 1595 | #endif |
@@ -1576,15 +1784,19 @@ static u8 mvs_assign_reg_set(struct mvs_info *mvi, struct mvs_port *port) | |||
1576 | return MVS_ID_NOT_MAPPED; | 1784 | return MVS_ID_NOT_MAPPED; |
1577 | } | 1785 | } |
1578 | 1786 | ||
1579 | static u32 mvs_get_ncq_tag(struct sas_task *task) | 1787 | static u32 mvs_get_ncq_tag(struct sas_task *task, u32 *tag) |
1580 | { | 1788 | { |
1581 | u32 tag = 0; | ||
1582 | struct ata_queued_cmd *qc = task->uldd_task; | 1789 | struct ata_queued_cmd *qc = task->uldd_task; |
1583 | 1790 | ||
1584 | if (qc) | 1791 | if (qc) { |
1585 | tag = qc->tag; | 1792 | if (qc->tf.command == ATA_CMD_FPDMA_WRITE || |
1793 | qc->tf.command == ATA_CMD_FPDMA_READ) { | ||
1794 | *tag = qc->tag; | ||
1795 | return 1; | ||
1796 | } | ||
1797 | } | ||
1586 | 1798 | ||
1587 | return tag; | 1799 | return 0; |
1588 | } | 1800 | } |
1589 | 1801 | ||
1590 | static int mvs_task_prep_ata(struct mvs_info *mvi, | 1802 | static int mvs_task_prep_ata(struct mvs_info *mvi, |
@@ -1628,11 +1840,9 @@ static int mvs_task_prep_ata(struct mvs_info *mvi, | |||
1628 | hdr->flags = cpu_to_le32(flags); | 1840 | hdr->flags = cpu_to_le32(flags); |
1629 | 1841 | ||
1630 | /* FIXME: the low order order 5 bits for the TAG if enable NCQ */ | 1842 | /* FIXME: the low order order 5 bits for the TAG if enable NCQ */ |
1631 | if (task->ata_task.use_ncq) { | 1843 | if (task->ata_task.use_ncq && mvs_get_ncq_tag(task, &hdr->tags)) |
1632 | hdr->tags = cpu_to_le32(mvs_get_ncq_tag(task)); | 1844 | task->ata_task.fis.sector_count |= hdr->tags << 3; |
1633 | /*Fill in task file */ | 1845 | else |
1634 | task->ata_task.fis.sector_count = hdr->tags << 3; | ||
1635 | } else | ||
1636 | hdr->tags = cpu_to_le32(tag); | 1846 | hdr->tags = cpu_to_le32(tag); |
1637 | hdr->data_len = cpu_to_le32(task->total_xfer_len); | 1847 | hdr->data_len = cpu_to_le32(task->total_xfer_len); |
1638 | 1848 | ||
@@ -1725,13 +1935,16 @@ static int mvs_task_prep_ssp(struct mvs_info *mvi, | |||
1725 | u32 flags; | 1935 | u32 flags; |
1726 | u32 resp_len, req_len, i, tag = tei->tag; | 1936 | u32 resp_len, req_len, i, tag = tei->tag; |
1727 | const u32 max_resp_len = SB_RFB_MAX; | 1937 | const u32 max_resp_len = SB_RFB_MAX; |
1938 | u8 phy_mask; | ||
1728 | 1939 | ||
1729 | slot = &mvi->slot_info[tag]; | 1940 | slot = &mvi->slot_info[tag]; |
1730 | 1941 | ||
1942 | phy_mask = (port->wide_port_phymap) ? port->wide_port_phymap : | ||
1943 | task->dev->port->phy_mask; | ||
1731 | slot->tx = mvi->tx_prod; | 1944 | slot->tx = mvi->tx_prod; |
1732 | mvi->tx[mvi->tx_prod] = cpu_to_le32(TXQ_MODE_I | tag | | 1945 | mvi->tx[mvi->tx_prod] = cpu_to_le32(TXQ_MODE_I | tag | |
1733 | (TXQ_CMD_SSP << TXQ_CMD_SHIFT) | | 1946 | (TXQ_CMD_SSP << TXQ_CMD_SHIFT) | |
1734 | (port->wide_port_phymap << TXQ_PHY_SHIFT)); | 1947 | (phy_mask << TXQ_PHY_SHIFT)); |
1735 | 1948 | ||
1736 | flags = MCH_RETRY; | 1949 | flags = MCH_RETRY; |
1737 | if (task->ssp_task.enable_first_burst) { | 1950 | if (task->ssp_task.enable_first_burst) { |
@@ -1832,22 +2045,32 @@ static int mvs_task_exec(struct sas_task *task, const int num, gfp_t gfp_flags) | |||
1832 | void __iomem *regs = mvi->regs; | 2045 | void __iomem *regs = mvi->regs; |
1833 | struct mvs_task_exec_info tei; | 2046 | struct mvs_task_exec_info tei; |
1834 | struct sas_task *t = task; | 2047 | struct sas_task *t = task; |
2048 | struct mvs_slot_info *slot; | ||
1835 | u32 tag = 0xdeadbeef, rc, n_elem = 0; | 2049 | u32 tag = 0xdeadbeef, rc, n_elem = 0; |
1836 | unsigned long flags; | 2050 | unsigned long flags; |
1837 | u32 n = num, pass = 0; | 2051 | u32 n = num, pass = 0; |
1838 | 2052 | ||
1839 | spin_lock_irqsave(&mvi->lock, flags); | 2053 | spin_lock_irqsave(&mvi->lock, flags); |
1840 | |||
1841 | do { | 2054 | do { |
2055 | dev = t->dev; | ||
1842 | tei.port = &mvi->port[dev->port->id]; | 2056 | tei.port = &mvi->port[dev->port->id]; |
1843 | 2057 | ||
1844 | if (!tei.port->port_attached) { | 2058 | if (!tei.port->port_attached) { |
1845 | struct task_status_struct *ts = &t->task_status; | 2059 | if (sas_protocol_ata(t->task_proto)) { |
1846 | ts->stat = SAS_PHY_DOWN; | 2060 | rc = SAS_PHY_DOWN; |
1847 | t->task_done(t); | 2061 | goto out_done; |
1848 | rc = 0; | 2062 | } else { |
1849 | goto exec_exit; | 2063 | struct task_status_struct *ts = &t->task_status; |
2064 | ts->resp = SAS_TASK_UNDELIVERED; | ||
2065 | ts->stat = SAS_PHY_DOWN; | ||
2066 | t->task_done(t); | ||
2067 | if (n > 1) | ||
2068 | t = list_entry(t->list.next, | ||
2069 | struct sas_task, list); | ||
2070 | continue; | ||
2071 | } | ||
1850 | } | 2072 | } |
2073 | |||
1851 | if (!sas_protocol_ata(t->task_proto)) { | 2074 | if (!sas_protocol_ata(t->task_proto)) { |
1852 | if (t->num_scatter) { | 2075 | if (t->num_scatter) { |
1853 | n_elem = pci_map_sg(mvi->pdev, t->scatter, | 2076 | n_elem = pci_map_sg(mvi->pdev, t->scatter, |
@@ -1866,9 +2089,10 @@ static int mvs_task_exec(struct sas_task *task, const int num, gfp_t gfp_flags) | |||
1866 | if (rc) | 2089 | if (rc) |
1867 | goto err_out; | 2090 | goto err_out; |
1868 | 2091 | ||
1869 | mvi->slot_info[tag].task = t; | 2092 | slot = &mvi->slot_info[tag]; |
1870 | mvi->slot_info[tag].n_elem = n_elem; | 2093 | t->lldd_task = NULL; |
1871 | memset(mvi->slot_info[tag].buf, 0, MVS_SLOT_BUF_SZ); | 2094 | slot->n_elem = n_elem; |
2095 | memset(slot->buf, 0, MVS_SLOT_BUF_SZ); | ||
1872 | tei.task = t; | 2096 | tei.task = t; |
1873 | tei.hdr = &mvi->slot[tag]; | 2097 | tei.hdr = &mvi->slot[tag]; |
1874 | tei.tag = tag; | 2098 | tei.tag = tag; |
@@ -1897,28 +2121,26 @@ static int mvs_task_exec(struct sas_task *task, const int num, gfp_t gfp_flags) | |||
1897 | if (rc) | 2121 | if (rc) |
1898 | goto err_out_tag; | 2122 | goto err_out_tag; |
1899 | 2123 | ||
2124 | slot->task = t; | ||
2125 | slot->port = tei.port; | ||
2126 | t->lldd_task = (void *) slot; | ||
2127 | list_add_tail(&slot->list, &slot->port->list); | ||
1900 | /* TODO: select normal or high priority */ | 2128 | /* TODO: select normal or high priority */ |
1901 | 2129 | ||
1902 | spin_lock(&t->task_state_lock); | 2130 | spin_lock(&t->task_state_lock); |
1903 | t->task_state_flags |= SAS_TASK_AT_INITIATOR; | 2131 | t->task_state_flags |= SAS_TASK_AT_INITIATOR; |
1904 | spin_unlock(&t->task_state_lock); | 2132 | spin_unlock(&t->task_state_lock); |
1905 | 2133 | ||
1906 | if (n == 1) { | ||
1907 | spin_unlock_irqrestore(&mvi->lock, flags); | ||
1908 | mw32(TX_PROD_IDX, mvi->tx_prod); | ||
1909 | } | ||
1910 | mvs_hba_memory_dump(mvi, tag, t->task_proto); | 2134 | mvs_hba_memory_dump(mvi, tag, t->task_proto); |
1911 | 2135 | ||
1912 | ++pass; | 2136 | ++pass; |
1913 | mvi->tx_prod = (mvi->tx_prod + 1) & (MVS_CHIP_SLOT_SZ - 1); | 2137 | mvi->tx_prod = (mvi->tx_prod + 1) & (MVS_CHIP_SLOT_SZ - 1); |
1914 | 2138 | if (n > 1) | |
1915 | if (n == 1) | 2139 | t = list_entry(t->list.next, struct sas_task, list); |
1916 | break; | ||
1917 | |||
1918 | t = list_entry(t->list.next, struct sas_task, list); | ||
1919 | } while (--n); | 2140 | } while (--n); |
1920 | 2141 | ||
1921 | return 0; | 2142 | rc = 0; |
2143 | goto out_done; | ||
1922 | 2144 | ||
1923 | err_out_tag: | 2145 | err_out_tag: |
1924 | mvs_tag_free(mvi, tag); | 2146 | mvs_tag_free(mvi, tag); |
@@ -1928,7 +2150,7 @@ err_out: | |||
1928 | if (n_elem) | 2150 | if (n_elem) |
1929 | pci_unmap_sg(mvi->pdev, t->scatter, n_elem, | 2151 | pci_unmap_sg(mvi->pdev, t->scatter, n_elem, |
1930 | t->data_dir); | 2152 | t->data_dir); |
1931 | exec_exit: | 2153 | out_done: |
1932 | if (pass) | 2154 | if (pass) |
1933 | mw32(TX_PROD_IDX, (mvi->tx_prod - 1) & (MVS_CHIP_SLOT_SZ - 1)); | 2155 | mw32(TX_PROD_IDX, (mvi->tx_prod - 1) & (MVS_CHIP_SLOT_SZ - 1)); |
1934 | spin_unlock_irqrestore(&mvi->lock, flags); | 2156 | spin_unlock_irqrestore(&mvi->lock, flags); |
@@ -1937,42 +2159,59 @@ exec_exit: | |||
1937 | 2159 | ||
1938 | static int mvs_task_abort(struct sas_task *task) | 2160 | static int mvs_task_abort(struct sas_task *task) |
1939 | { | 2161 | { |
1940 | int rc = 1; | 2162 | int rc; |
1941 | unsigned long flags; | 2163 | unsigned long flags; |
1942 | struct mvs_info *mvi = task->dev->port->ha->lldd_ha; | 2164 | struct mvs_info *mvi = task->dev->port->ha->lldd_ha; |
1943 | struct pci_dev *pdev = mvi->pdev; | 2165 | struct pci_dev *pdev = mvi->pdev; |
2166 | int tag; | ||
1944 | 2167 | ||
1945 | spin_lock_irqsave(&task->task_state_lock, flags); | 2168 | spin_lock_irqsave(&task->task_state_lock, flags); |
1946 | if (task->task_state_flags & SAS_TASK_STATE_DONE) { | 2169 | if (task->task_state_flags & SAS_TASK_STATE_DONE) { |
1947 | rc = TMF_RESP_FUNC_COMPLETE; | 2170 | rc = TMF_RESP_FUNC_COMPLETE; |
2171 | spin_unlock_irqrestore(&task->task_state_lock, flags); | ||
1948 | goto out_done; | 2172 | goto out_done; |
1949 | } | 2173 | } |
1950 | spin_unlock_irqrestore(&task->task_state_lock, flags); | 2174 | spin_unlock_irqrestore(&task->task_state_lock, flags); |
1951 | 2175 | ||
1952 | /*FIXME*/ | ||
1953 | rc = TMF_RESP_FUNC_COMPLETE; | ||
1954 | |||
1955 | switch (task->task_proto) { | 2176 | switch (task->task_proto) { |
1956 | case SAS_PROTOCOL_SMP: | 2177 | case SAS_PROTOCOL_SMP: |
1957 | dev_printk(KERN_DEBUG, &pdev->dev, "SMP Abort! "); | 2178 | dev_printk(KERN_DEBUG, &pdev->dev, "SMP Abort! \n"); |
1958 | break; | 2179 | break; |
1959 | case SAS_PROTOCOL_SSP: | 2180 | case SAS_PROTOCOL_SSP: |
1960 | dev_printk(KERN_DEBUG, &pdev->dev, "SSP Abort! "); | 2181 | dev_printk(KERN_DEBUG, &pdev->dev, "SSP Abort! \n"); |
1961 | break; | 2182 | break; |
1962 | case SAS_PROTOCOL_SATA: | 2183 | case SAS_PROTOCOL_SATA: |
1963 | case SAS_PROTOCOL_STP: | 2184 | case SAS_PROTOCOL_STP: |
1964 | case SAS_PROTOCOL_SATA | SAS_PROTOCOL_STP:{ | 2185 | case SAS_PROTOCOL_SATA | SAS_PROTOCOL_STP:{ |
1965 | dev_printk(KERN_DEBUG, &pdev->dev, "STP Abort! " | 2186 | dev_printk(KERN_DEBUG, &pdev->dev, "STP Abort! \n"); |
1966 | "Dump D2H FIS: \n"); | 2187 | #if _MV_DUMP |
2188 | dev_printk(KERN_DEBUG, &pdev->dev, "Dump D2H FIS: \n"); | ||
1967 | mvs_hexdump(sizeof(struct host_to_dev_fis), | 2189 | mvs_hexdump(sizeof(struct host_to_dev_fis), |
1968 | (void *)&task->ata_task.fis, 0); | 2190 | (void *)&task->ata_task.fis, 0); |
1969 | dev_printk(KERN_DEBUG, &pdev->dev, "Dump ATAPI Cmd : \n"); | 2191 | dev_printk(KERN_DEBUG, &pdev->dev, "Dump ATAPI Cmd : \n"); |
1970 | mvs_hexdump(16, task->ata_task.atapi_packet, 0); | 2192 | mvs_hexdump(16, task->ata_task.atapi_packet, 0); |
2193 | #endif | ||
2194 | spin_lock_irqsave(&task->task_state_lock, flags); | ||
2195 | if (task->task_state_flags & SAS_TASK_NEED_DEV_RESET) { | ||
2196 | /* TODO */ | ||
2197 | ; | ||
2198 | } | ||
2199 | spin_unlock_irqrestore(&task->task_state_lock, flags); | ||
1971 | break; | 2200 | break; |
1972 | } | 2201 | } |
1973 | default: | 2202 | default: |
1974 | break; | 2203 | break; |
1975 | } | 2204 | } |
2205 | |||
2206 | if (mvs_find_tag(mvi, task, &tag)) { | ||
2207 | spin_lock_irqsave(&mvi->lock, flags); | ||
2208 | mvs_slot_task_free(mvi, task, &mvi->slot_info[tag], tag); | ||
2209 | spin_unlock_irqrestore(&mvi->lock, flags); | ||
2210 | } | ||
2211 | if (!mvs_task_exec(task, 1, GFP_ATOMIC)) | ||
2212 | rc = TMF_RESP_FUNC_COMPLETE; | ||
2213 | else | ||
2214 | rc = TMF_RESP_FUNC_FAILED; | ||
1976 | out_done: | 2215 | out_done: |
1977 | return rc; | 2216 | return rc; |
1978 | } | 2217 | } |
@@ -2001,7 +2240,7 @@ static void mvs_free(struct mvs_info *mvi) | |||
2001 | mvi->rx_fis, mvi->rx_fis_dma); | 2240 | mvi->rx_fis, mvi->rx_fis_dma); |
2002 | if (mvi->rx) | 2241 | if (mvi->rx) |
2003 | dma_free_coherent(&mvi->pdev->dev, | 2242 | dma_free_coherent(&mvi->pdev->dev, |
2004 | sizeof(*mvi->rx) * MVS_RX_RING_SZ, | 2243 | sizeof(*mvi->rx) * (MVS_RX_RING_SZ + 1), |
2005 | mvi->rx, mvi->rx_dma); | 2244 | mvi->rx, mvi->rx_dma); |
2006 | if (mvi->slot) | 2245 | if (mvi->slot) |
2007 | dma_free_coherent(&mvi->pdev->dev, | 2246 | dma_free_coherent(&mvi->pdev->dev, |
@@ -2109,6 +2348,9 @@ static struct mvs_info *__devinit mvs_alloc(struct pci_dev *pdev, | |||
2109 | return NULL; | 2348 | return NULL; |
2110 | 2349 | ||
2111 | spin_lock_init(&mvi->lock); | 2350 | spin_lock_init(&mvi->lock); |
2351 | #ifdef MVS_USE_TASKLET | ||
2352 | tasklet_init(&mvi->tasklet, mvs_tasklet, (unsigned long)mvi); | ||
2353 | #endif | ||
2112 | mvi->pdev = pdev; | 2354 | mvi->pdev = pdev; |
2113 | mvi->chip = chip; | 2355 | mvi->chip = chip; |
2114 | 2356 | ||
@@ -2132,6 +2374,10 @@ static struct mvs_info *__devinit mvs_alloc(struct pci_dev *pdev, | |||
2132 | mvs_phy_init(mvi, i); | 2374 | mvs_phy_init(mvi, i); |
2133 | arr_phy[i] = &mvi->phy[i].sas_phy; | 2375 | arr_phy[i] = &mvi->phy[i].sas_phy; |
2134 | arr_port[i] = &mvi->port[i].sas_port; | 2376 | arr_port[i] = &mvi->port[i].sas_port; |
2377 | mvi->port[i].taskfileset = MVS_ID_NOT_MAPPED; | ||
2378 | mvi->port[i].wide_port_phymap = 0; | ||
2379 | mvi->port[i].port_attached = 0; | ||
2380 | INIT_LIST_HEAD(&mvi->port[i].list); | ||
2135 | } | 2381 | } |
2136 | 2382 | ||
2137 | SHOST_TO_SAS_HA(mvi->shost) = &mvi->sas; | 2383 | SHOST_TO_SAS_HA(mvi->shost) = &mvi->sas; |
@@ -2148,9 +2394,10 @@ static struct mvs_info *__devinit mvs_alloc(struct pci_dev *pdev, | |||
2148 | mvi->sas.sas_phy = arr_phy; | 2394 | mvi->sas.sas_phy = arr_phy; |
2149 | mvi->sas.sas_port = arr_port; | 2395 | mvi->sas.sas_port = arr_port; |
2150 | mvi->sas.num_phys = chip->n_phy; | 2396 | mvi->sas.num_phys = chip->n_phy; |
2151 | mvi->sas.lldd_max_execute_num = MVS_CHIP_SLOT_SZ - 1; | 2397 | mvi->sas.lldd_max_execute_num = 1; |
2152 | mvi->sas.lldd_queue_size = MVS_QUEUE_SIZE; | 2398 | mvi->sas.lldd_queue_size = MVS_QUEUE_SIZE; |
2153 | mvi->can_queue = (MVS_CHIP_SLOT_SZ >> 1) - 1; | 2399 | mvi->shost->can_queue = MVS_CAN_QUEUE; |
2400 | mvi->shost->cmd_per_lun = MVS_SLOTS / mvi->sas.num_phys; | ||
2154 | mvi->sas.lldd_ha = mvi; | 2401 | mvi->sas.lldd_ha = mvi; |
2155 | mvi->sas.core.shost = mvi->shost; | 2402 | mvi->sas.core.shost = mvi->shost; |
2156 | 2403 | ||
@@ -2203,11 +2450,11 @@ static struct mvs_info *__devinit mvs_alloc(struct pci_dev *pdev, | |||
2203 | memset(mvi->rx_fis, 0, MVS_RX_FISL_SZ); | 2450 | memset(mvi->rx_fis, 0, MVS_RX_FISL_SZ); |
2204 | 2451 | ||
2205 | mvi->rx = dma_alloc_coherent(&pdev->dev, | 2452 | mvi->rx = dma_alloc_coherent(&pdev->dev, |
2206 | sizeof(*mvi->rx) * MVS_RX_RING_SZ, | 2453 | sizeof(*mvi->rx) * (MVS_RX_RING_SZ + 1), |
2207 | &mvi->rx_dma, GFP_KERNEL); | 2454 | &mvi->rx_dma, GFP_KERNEL); |
2208 | if (!mvi->rx) | 2455 | if (!mvi->rx) |
2209 | goto err_out; | 2456 | goto err_out; |
2210 | memset(mvi->rx, 0, sizeof(*mvi->rx) * MVS_RX_RING_SZ); | 2457 | memset(mvi->rx, 0, sizeof(*mvi->rx) * (MVS_RX_RING_SZ + 1)); |
2211 | 2458 | ||
2212 | mvi->rx[0] = cpu_to_le32(0xfff); | 2459 | mvi->rx[0] = cpu_to_le32(0xfff); |
2213 | mvi->rx_cons = 0xfff; | 2460 | mvi->rx_cons = 0xfff; |
@@ -2357,7 +2604,7 @@ static void __devinit mvs_phy_hacks(struct mvs_info *mvi) | |||
2357 | mvs_cw32(regs, CMD_SAS_CTL0, tmp); | 2604 | mvs_cw32(regs, CMD_SAS_CTL0, tmp); |
2358 | 2605 | ||
2359 | /* workaround for WDTIMEOUT , set to 550 ms */ | 2606 | /* workaround for WDTIMEOUT , set to 550 ms */ |
2360 | mvs_cw32(regs, CMD_WD_TIMER, 0xffffff); | 2607 | mvs_cw32(regs, CMD_WD_TIMER, 0x86470); |
2361 | 2608 | ||
2362 | /* not to halt for different port op during wideport link change */ | 2609 | /* not to halt for different port op during wideport link change */ |
2363 | mvs_cw32(regs, CMD_APP_ERR_CONFIG, 0xffefbf7d); | 2610 | mvs_cw32(regs, CMD_APP_ERR_CONFIG, 0xffefbf7d); |
@@ -2465,17 +2712,16 @@ static u32 mvs_is_phy_ready(struct mvs_info *mvi, int i) | |||
2465 | { | 2712 | { |
2466 | u32 tmp; | 2713 | u32 tmp; |
2467 | struct mvs_phy *phy = &mvi->phy[i]; | 2714 | struct mvs_phy *phy = &mvi->phy[i]; |
2468 | struct mvs_port *port; | 2715 | struct mvs_port *port = phy->port;; |
2469 | 2716 | ||
2470 | tmp = mvs_read_phy_ctl(mvi, i); | 2717 | tmp = mvs_read_phy_ctl(mvi, i); |
2471 | 2718 | ||
2472 | if ((tmp & PHY_READY_MASK) && !(phy->irq_status & PHYEV_POOF)) { | 2719 | if ((tmp & PHY_READY_MASK) && !(phy->irq_status & PHYEV_POOF)) { |
2473 | if (!phy->port) | 2720 | if (!port) |
2474 | phy->phy_attached = 1; | 2721 | phy->phy_attached = 1; |
2475 | return tmp; | 2722 | return tmp; |
2476 | } | 2723 | } |
2477 | 2724 | ||
2478 | port = phy->port; | ||
2479 | if (port) { | 2725 | if (port) { |
2480 | if (phy->phy_type & PORT_TYPE_SAS) { | 2726 | if (phy->phy_type & PORT_TYPE_SAS) { |
2481 | port->wide_port_phymap &= ~(1U << i); | 2727 | port->wide_port_phymap &= ~(1U << i); |
@@ -2497,7 +2743,7 @@ static void mvs_update_phyinfo(struct mvs_info *mvi, int i, | |||
2497 | { | 2743 | { |
2498 | struct mvs_phy *phy = &mvi->phy[i]; | 2744 | struct mvs_phy *phy = &mvi->phy[i]; |
2499 | struct pci_dev *pdev = mvi->pdev; | 2745 | struct pci_dev *pdev = mvi->pdev; |
2500 | u32 tmp, j; | 2746 | u32 tmp; |
2501 | u64 tmp64; | 2747 | u64 tmp64; |
2502 | 2748 | ||
2503 | mvs_write_port_cfg_addr(mvi, i, PHYR_IDENTIFY); | 2749 | mvs_write_port_cfg_addr(mvi, i, PHYR_IDENTIFY); |
@@ -2524,46 +2770,20 @@ static void mvs_update_phyinfo(struct mvs_info *mvi, int i, | |||
2524 | sas_phy->linkrate = | 2770 | sas_phy->linkrate = |
2525 | (phy->phy_status & PHY_NEG_SPP_PHYS_LINK_RATE_MASK) >> | 2771 | (phy->phy_status & PHY_NEG_SPP_PHYS_LINK_RATE_MASK) >> |
2526 | PHY_NEG_SPP_PHYS_LINK_RATE_MASK_OFFSET; | 2772 | PHY_NEG_SPP_PHYS_LINK_RATE_MASK_OFFSET; |
2527 | 2773 | phy->minimum_linkrate = | |
2528 | /* Updated attached_sas_addr */ | 2774 | (phy->phy_status & |
2529 | mvs_write_port_cfg_addr(mvi, i, PHYR_ATT_ADDR_HI); | 2775 | PHY_MIN_SPP_PHYS_LINK_RATE_MASK) >> 8; |
2530 | phy->att_dev_sas_addr = | 2776 | phy->maximum_linkrate = |
2531 | (u64) mvs_read_port_cfg_data(mvi, i) << 32; | 2777 | (phy->phy_status & |
2532 | 2778 | PHY_MAX_SPP_PHYS_LINK_RATE_MASK) >> 12; | |
2533 | mvs_write_port_cfg_addr(mvi, i, PHYR_ATT_ADDR_LO); | ||
2534 | phy->att_dev_sas_addr |= mvs_read_port_cfg_data(mvi, i); | ||
2535 | |||
2536 | dev_printk(KERN_DEBUG, &pdev->dev, | ||
2537 | "phy[%d] Get Attached Address 0x%llX ," | ||
2538 | " SAS Address 0x%llX\n", | ||
2539 | i, phy->att_dev_sas_addr, phy->dev_sas_addr); | ||
2540 | dev_printk(KERN_DEBUG, &pdev->dev, | ||
2541 | "Rate = %x , type = %d\n", | ||
2542 | sas_phy->linkrate, phy->phy_type); | ||
2543 | |||
2544 | #if 1 | ||
2545 | /* | ||
2546 | * If the device is capable of supporting a wide port | ||
2547 | * on its phys, it may configure the phys as a wide port. | ||
2548 | */ | ||
2549 | if (phy->phy_type & PORT_TYPE_SAS) | ||
2550 | for (j = 0; j < mvi->chip->n_phy && j != i; ++j) { | ||
2551 | if ((mvi->phy[j].phy_attached) && | ||
2552 | (mvi->phy[j].phy_type & PORT_TYPE_SAS)) | ||
2553 | if (phy->att_dev_sas_addr == | ||
2554 | mvi->phy[j].att_dev_sas_addr - 1) { | ||
2555 | phy->att_dev_sas_addr = | ||
2556 | mvi->phy[j].att_dev_sas_addr; | ||
2557 | break; | ||
2558 | } | ||
2559 | } | ||
2560 | |||
2561 | #endif | ||
2562 | |||
2563 | tmp64 = cpu_to_be64(phy->att_dev_sas_addr); | ||
2564 | memcpy(sas_phy->attached_sas_addr, &tmp64, SAS_ADDR_SIZE); | ||
2565 | 2779 | ||
2566 | if (phy->phy_type & PORT_TYPE_SAS) { | 2780 | if (phy->phy_type & PORT_TYPE_SAS) { |
2781 | /* Updated attached_sas_addr */ | ||
2782 | mvs_write_port_cfg_addr(mvi, i, PHYR_ATT_ADDR_HI); | ||
2783 | phy->att_dev_sas_addr = | ||
2784 | (u64) mvs_read_port_cfg_data(mvi, i) << 32; | ||
2785 | mvs_write_port_cfg_addr(mvi, i, PHYR_ATT_ADDR_LO); | ||
2786 | phy->att_dev_sas_addr |= mvs_read_port_cfg_data(mvi, i); | ||
2567 | mvs_write_port_cfg_addr(mvi, i, PHYR_ATT_DEV_INFO); | 2787 | mvs_write_port_cfg_addr(mvi, i, PHYR_ATT_DEV_INFO); |
2568 | phy->att_dev_info = mvs_read_port_cfg_data(mvi, i); | 2788 | phy->att_dev_info = mvs_read_port_cfg_data(mvi, i); |
2569 | phy->identify.device_type = | 2789 | phy->identify.device_type = |
@@ -2582,6 +2802,7 @@ static void mvs_update_phyinfo(struct mvs_info *mvi, int i, | |||
2582 | } else if (phy->phy_type & PORT_TYPE_SATA) { | 2802 | } else if (phy->phy_type & PORT_TYPE_SATA) { |
2583 | phy->identify.target_port_protocols = SAS_PROTOCOL_STP; | 2803 | phy->identify.target_port_protocols = SAS_PROTOCOL_STP; |
2584 | if (mvs_is_sig_fis_received(phy->irq_status)) { | 2804 | if (mvs_is_sig_fis_received(phy->irq_status)) { |
2805 | phy->att_dev_sas_addr = i; /* temp */ | ||
2585 | if (phy_st & PHY_OOB_DTCTD) | 2806 | if (phy_st & PHY_OOB_DTCTD) |
2586 | sas_phy->oob_mode = SATA_OOB_MODE; | 2807 | sas_phy->oob_mode = SATA_OOB_MODE; |
2587 | phy->frame_rcvd_size = | 2808 | phy->frame_rcvd_size = |
@@ -2591,20 +2812,34 @@ static void mvs_update_phyinfo(struct mvs_info *mvi, int i, | |||
2591 | } else { | 2812 | } else { |
2592 | dev_printk(KERN_DEBUG, &pdev->dev, | 2813 | dev_printk(KERN_DEBUG, &pdev->dev, |
2593 | "No sig fis\n"); | 2814 | "No sig fis\n"); |
2815 | phy->phy_type &= ~(PORT_TYPE_SATA); | ||
2816 | goto out_done; | ||
2594 | } | 2817 | } |
2595 | } | 2818 | } |
2819 | tmp64 = cpu_to_be64(phy->att_dev_sas_addr); | ||
2820 | memcpy(sas_phy->attached_sas_addr, &tmp64, SAS_ADDR_SIZE); | ||
2821 | |||
2822 | dev_printk(KERN_DEBUG, &pdev->dev, | ||
2823 | "phy[%d] Get Attached Address 0x%llX ," | ||
2824 | " SAS Address 0x%llX\n", | ||
2825 | i, phy->att_dev_sas_addr, phy->dev_sas_addr); | ||
2826 | dev_printk(KERN_DEBUG, &pdev->dev, | ||
2827 | "Rate = %x , type = %d\n", | ||
2828 | sas_phy->linkrate, phy->phy_type); | ||
2829 | |||
2596 | /* workaround for HW phy decoding error on 1.5g disk drive */ | 2830 | /* workaround for HW phy decoding error on 1.5g disk drive */ |
2597 | mvs_write_port_vsr_addr(mvi, i, VSR_PHY_MODE6); | 2831 | mvs_write_port_vsr_addr(mvi, i, VSR_PHY_MODE6); |
2598 | tmp = mvs_read_port_vsr_data(mvi, i); | 2832 | tmp = mvs_read_port_vsr_data(mvi, i); |
2599 | if (((phy->phy_status & PHY_NEG_SPP_PHYS_LINK_RATE_MASK) >> | 2833 | if (((phy->phy_status & PHY_NEG_SPP_PHYS_LINK_RATE_MASK) >> |
2600 | PHY_NEG_SPP_PHYS_LINK_RATE_MASK_OFFSET) == | 2834 | PHY_NEG_SPP_PHYS_LINK_RATE_MASK_OFFSET) == |
2601 | SAS_LINK_RATE_1_5_GBPS) | 2835 | SAS_LINK_RATE_1_5_GBPS) |
2602 | tmp &= ~PHY_MODE6_DTL_SPEED; | 2836 | tmp &= ~PHY_MODE6_LATECLK; |
2603 | else | 2837 | else |
2604 | tmp |= PHY_MODE6_DTL_SPEED; | 2838 | tmp |= PHY_MODE6_LATECLK; |
2605 | mvs_write_port_vsr_data(mvi, i, tmp); | 2839 | mvs_write_port_vsr_data(mvi, i, tmp); |
2606 | 2840 | ||
2607 | } | 2841 | } |
2842 | out_done: | ||
2608 | if (get_st) | 2843 | if (get_st) |
2609 | mvs_write_port_irq_stat(mvi, i, phy->irq_status); | 2844 | mvs_write_port_irq_stat(mvi, i, phy->irq_status); |
2610 | } | 2845 | } |
@@ -2629,6 +2864,11 @@ static void mvs_port_formed(struct asd_sas_phy *sas_phy) | |||
2629 | spin_unlock_irqrestore(&mvi->lock, flags); | 2864 | spin_unlock_irqrestore(&mvi->lock, flags); |
2630 | } | 2865 | } |
2631 | 2866 | ||
2867 | static int mvs_I_T_nexus_reset(struct domain_device *dev) | ||
2868 | { | ||
2869 | return TMF_RESP_FUNC_FAILED; | ||
2870 | } | ||
2871 | |||
2632 | static int __devinit mvs_hw_init(struct mvs_info *mvi) | 2872 | static int __devinit mvs_hw_init(struct mvs_info *mvi) |
2633 | { | 2873 | { |
2634 | void __iomem *regs = mvi->regs; | 2874 | void __iomem *regs = mvi->regs; |
@@ -2790,13 +3030,12 @@ static int __devinit mvs_hw_init(struct mvs_info *mvi) | |||
2790 | /* enable CMD/CMPL_Q/RESP mode */ | 3030 | /* enable CMD/CMPL_Q/RESP mode */ |
2791 | mw32(PCS, PCS_SATA_RETRY | PCS_FIS_RX_EN | PCS_CMD_EN); | 3031 | mw32(PCS, PCS_SATA_RETRY | PCS_FIS_RX_EN | PCS_CMD_EN); |
2792 | 3032 | ||
2793 | /* re-enable interrupts globally */ | ||
2794 | mvs_hba_interrupt_enable(mvi); | ||
2795 | |||
2796 | /* enable completion queue interrupt */ | 3033 | /* enable completion queue interrupt */ |
2797 | tmp = (CINT_PORT_MASK | CINT_DONE | CINT_MEM); | 3034 | tmp = (CINT_PORT_MASK | CINT_DONE | CINT_MEM | CINT_SRS); |
2798 | mw32(INT_MASK, tmp); | 3035 | mw32(INT_MASK, tmp); |
2799 | 3036 | ||
3037 | /* Enable SRS interrupt */ | ||
3038 | mw32(INT_MASK_SRS, 0xFF); | ||
2800 | return 0; | 3039 | return 0; |
2801 | } | 3040 | } |
2802 | 3041 | ||
@@ -2870,6 +3109,8 @@ static int __devinit mvs_pci_init(struct pci_dev *pdev, | |||
2870 | 3109 | ||
2871 | mvs_print_info(mvi); | 3110 | mvs_print_info(mvi); |
2872 | 3111 | ||
3112 | mvs_hba_interrupt_enable(mvi); | ||
3113 | |||
2873 | scsi_scan_host(mvi->shost); | 3114 | scsi_scan_host(mvi->shost); |
2874 | 3115 | ||
2875 | return 0; | 3116 | return 0; |
@@ -2915,12 +3156,22 @@ static struct sas_domain_function_template mvs_transport_ops = { | |||
2915 | .lldd_execute_task = mvs_task_exec, | 3156 | .lldd_execute_task = mvs_task_exec, |
2916 | .lldd_control_phy = mvs_phy_control, | 3157 | .lldd_control_phy = mvs_phy_control, |
2917 | .lldd_abort_task = mvs_task_abort, | 3158 | .lldd_abort_task = mvs_task_abort, |
2918 | .lldd_port_formed = mvs_port_formed | 3159 | .lldd_port_formed = mvs_port_formed, |
3160 | .lldd_I_T_nexus_reset = mvs_I_T_nexus_reset, | ||
2919 | }; | 3161 | }; |
2920 | 3162 | ||
2921 | static struct pci_device_id __devinitdata mvs_pci_table[] = { | 3163 | static struct pci_device_id __devinitdata mvs_pci_table[] = { |
2922 | { PCI_VDEVICE(MARVELL, 0x6320), chip_6320 }, | 3164 | { PCI_VDEVICE(MARVELL, 0x6320), chip_6320 }, |
2923 | { PCI_VDEVICE(MARVELL, 0x6340), chip_6440 }, | 3165 | { PCI_VDEVICE(MARVELL, 0x6340), chip_6440 }, |
3166 | { | ||
3167 | .vendor = PCI_VENDOR_ID_MARVELL, | ||
3168 | .device = 0x6440, | ||
3169 | .subvendor = PCI_ANY_ID, | ||
3170 | .subdevice = 0x6480, | ||
3171 | .class = 0, | ||
3172 | .class_mask = 0, | ||
3173 | .driver_data = chip_6480, | ||
3174 | }, | ||
2924 | { PCI_VDEVICE(MARVELL, 0x6440), chip_6440 }, | 3175 | { PCI_VDEVICE(MARVELL, 0x6440), chip_6440 }, |
2925 | { PCI_VDEVICE(MARVELL, 0x6480), chip_6480 }, | 3176 | { PCI_VDEVICE(MARVELL, 0x6480), chip_6480 }, |
2926 | 3177 | ||
diff --git a/drivers/scsi/scsi_sysfs.c b/drivers/scsi/scsi_sysfs.c index b9b09a704584..ed83cdb6e67d 100644 --- a/drivers/scsi/scsi_sysfs.c +++ b/drivers/scsi/scsi_sysfs.c | |||
@@ -294,7 +294,6 @@ static void scsi_device_dev_release_usercontext(struct work_struct *work) | |||
294 | } | 294 | } |
295 | 295 | ||
296 | if (sdev->request_queue) { | 296 | if (sdev->request_queue) { |
297 | bsg_unregister_queue(sdev->request_queue); | ||
298 | sdev->request_queue->queuedata = NULL; | 297 | sdev->request_queue->queuedata = NULL; |
299 | /* user context needed to free queue */ | 298 | /* user context needed to free queue */ |
300 | scsi_free_queue(sdev->request_queue); | 299 | scsi_free_queue(sdev->request_queue); |
@@ -858,6 +857,7 @@ void __scsi_remove_device(struct scsi_device *sdev) | |||
858 | if (scsi_device_set_state(sdev, SDEV_CANCEL) != 0) | 857 | if (scsi_device_set_state(sdev, SDEV_CANCEL) != 0) |
859 | return; | 858 | return; |
860 | 859 | ||
860 | bsg_unregister_queue(sdev->request_queue); | ||
861 | class_device_unregister(&sdev->sdev_classdev); | 861 | class_device_unregister(&sdev->sdev_classdev); |
862 | transport_remove_device(dev); | 862 | transport_remove_device(dev); |
863 | device_del(dev); | 863 | device_del(dev); |
diff --git a/drivers/serial/atmel_serial.c b/drivers/serial/atmel_serial.c index d57bf3e708d8..430997e33fc4 100644 --- a/drivers/serial/atmel_serial.c +++ b/drivers/serial/atmel_serial.c | |||
@@ -96,6 +96,7 @@ | |||
96 | 96 | ||
97 | /* PDC registers */ | 97 | /* PDC registers */ |
98 | #define UART_PUT_PTCR(port,v) __raw_writel(v, (port)->membase + ATMEL_PDC_PTCR) | 98 | #define UART_PUT_PTCR(port,v) __raw_writel(v, (port)->membase + ATMEL_PDC_PTCR) |
99 | #define UART_GET_TCR(port) __raw_readl((port)->membase + ATMEL_PDC_TCR) | ||
99 | #define UART_GET_PTSR(port) __raw_readl((port)->membase + ATMEL_PDC_PTSR) | 100 | #define UART_GET_PTSR(port) __raw_readl((port)->membase + ATMEL_PDC_PTSR) |
100 | 101 | ||
101 | #define UART_PUT_RPR(port,v) __raw_writel(v, (port)->membase + ATMEL_PDC_RPR) | 102 | #define UART_PUT_RPR(port,v) __raw_writel(v, (port)->membase + ATMEL_PDC_RPR) |
@@ -106,6 +107,7 @@ | |||
106 | 107 | ||
107 | #define UART_PUT_TPR(port,v) __raw_writel(v, (port)->membase + ATMEL_PDC_TPR) | 108 | #define UART_PUT_TPR(port,v) __raw_writel(v, (port)->membase + ATMEL_PDC_TPR) |
108 | #define UART_PUT_TCR(port,v) __raw_writel(v, (port)->membase + ATMEL_PDC_TCR) | 109 | #define UART_PUT_TCR(port,v) __raw_writel(v, (port)->membase + ATMEL_PDC_TCR) |
110 | #define UART_GET_TCR(port) __raw_readl((port)->membase + ATMEL_PDC_TCR) | ||
109 | 111 | ||
110 | static int (*atmel_open_hook)(struct uart_port *); | 112 | static int (*atmel_open_hook)(struct uart_port *); |
111 | static void (*atmel_close_hook)(struct uart_port *); | 113 | static void (*atmel_close_hook)(struct uart_port *); |
@@ -562,17 +564,22 @@ static void atmel_tx_dma(struct uart_port *port) | |||
562 | struct atmel_dma_buffer *pdc = &atmel_port->pdc_tx; | 564 | struct atmel_dma_buffer *pdc = &atmel_port->pdc_tx; |
563 | int count; | 565 | int count; |
564 | 566 | ||
567 | /* nothing left to transmit? */ | ||
568 | if (UART_GET_TCR(port)) | ||
569 | return; | ||
570 | |||
565 | xmit->tail += pdc->ofs; | 571 | xmit->tail += pdc->ofs; |
566 | xmit->tail &= UART_XMIT_SIZE - 1; | 572 | xmit->tail &= UART_XMIT_SIZE - 1; |
567 | 573 | ||
568 | port->icount.tx += pdc->ofs; | 574 | port->icount.tx += pdc->ofs; |
569 | pdc->ofs = 0; | 575 | pdc->ofs = 0; |
570 | 576 | ||
571 | if (!uart_circ_empty(xmit)) { | 577 | /* more to transmit - setup next transfer */ |
572 | /* more to transmit - setup next transfer */ | ||
573 | 578 | ||
574 | /* disable PDC transmit */ | 579 | /* disable PDC transmit */ |
575 | UART_PUT_PTCR(port, ATMEL_PDC_TXTDIS); | 580 | UART_PUT_PTCR(port, ATMEL_PDC_TXTDIS); |
581 | |||
582 | if (!uart_circ_empty(xmit)) { | ||
576 | dma_sync_single_for_device(port->dev, | 583 | dma_sync_single_for_device(port->dev, |
577 | pdc->dma_addr, | 584 | pdc->dma_addr, |
578 | pdc->dma_size, | 585 | pdc->dma_size, |
@@ -586,11 +593,6 @@ static void atmel_tx_dma(struct uart_port *port) | |||
586 | /* re-enable PDC transmit and interrupts */ | 593 | /* re-enable PDC transmit and interrupts */ |
587 | UART_PUT_PTCR(port, ATMEL_PDC_TXTEN); | 594 | UART_PUT_PTCR(port, ATMEL_PDC_TXTEN); |
588 | UART_PUT_IER(port, ATMEL_US_ENDTX | ATMEL_US_TXBUFE); | 595 | UART_PUT_IER(port, ATMEL_US_ENDTX | ATMEL_US_TXBUFE); |
589 | } else { | ||
590 | /* nothing left to transmit - disable the transmitter */ | ||
591 | |||
592 | /* disable PDC transmit */ | ||
593 | UART_PUT_PTCR(port, ATMEL_PDC_TXTDIS); | ||
594 | } | 596 | } |
595 | 597 | ||
596 | if (uart_circ_chars_pending(xmit) < WAKEUP_CHARS) | 598 | if (uart_circ_chars_pending(xmit) < WAKEUP_CHARS) |
@@ -1274,6 +1276,7 @@ static void atmel_console_write(struct console *co, const char *s, u_int count) | |||
1274 | { | 1276 | { |
1275 | struct uart_port *port = &atmel_ports[co->index].uart; | 1277 | struct uart_port *port = &atmel_ports[co->index].uart; |
1276 | unsigned int status, imr; | 1278 | unsigned int status, imr; |
1279 | unsigned int pdc_tx; | ||
1277 | 1280 | ||
1278 | /* | 1281 | /* |
1279 | * First, save IMR and then disable interrupts | 1282 | * First, save IMR and then disable interrupts |
@@ -1281,6 +1284,10 @@ static void atmel_console_write(struct console *co, const char *s, u_int count) | |||
1281 | imr = UART_GET_IMR(port); | 1284 | imr = UART_GET_IMR(port); |
1282 | UART_PUT_IDR(port, ATMEL_US_RXRDY | ATMEL_US_TXRDY); | 1285 | UART_PUT_IDR(port, ATMEL_US_RXRDY | ATMEL_US_TXRDY); |
1283 | 1286 | ||
1287 | /* Store PDC transmit status and disable it */ | ||
1288 | pdc_tx = UART_GET_PTSR(port) & ATMEL_PDC_TXTEN; | ||
1289 | UART_PUT_PTCR(port, ATMEL_PDC_TXTDIS); | ||
1290 | |||
1284 | uart_console_write(port, s, count, atmel_console_putchar); | 1291 | uart_console_write(port, s, count, atmel_console_putchar); |
1285 | 1292 | ||
1286 | /* | 1293 | /* |
@@ -1290,6 +1297,11 @@ static void atmel_console_write(struct console *co, const char *s, u_int count) | |||
1290 | do { | 1297 | do { |
1291 | status = UART_GET_CSR(port); | 1298 | status = UART_GET_CSR(port); |
1292 | } while (!(status & ATMEL_US_TXRDY)); | 1299 | } while (!(status & ATMEL_US_TXRDY)); |
1300 | |||
1301 | /* Restore PDC transmit status */ | ||
1302 | if (pdc_tx) | ||
1303 | UART_PUT_PTCR(port, ATMEL_PDC_TXTEN); | ||
1304 | |||
1293 | /* set interrupts back the way they were */ | 1305 | /* set interrupts back the way they were */ |
1294 | UART_PUT_IER(port, imr); | 1306 | UART_PUT_IER(port, imr); |
1295 | } | 1307 | } |
diff --git a/drivers/usb/host/ehci-hub.c b/drivers/usb/host/ehci-hub.c index 40e8240b7851..4e065e556e4b 100644 --- a/drivers/usb/host/ehci-hub.c +++ b/drivers/usb/host/ehci-hub.c | |||
@@ -135,8 +135,6 @@ static int ehci_bus_suspend (struct usb_hcd *hcd) | |||
135 | hcd->state = HC_STATE_QUIESCING; | 135 | hcd->state = HC_STATE_QUIESCING; |
136 | } | 136 | } |
137 | ehci->command = ehci_readl(ehci, &ehci->regs->command); | 137 | ehci->command = ehci_readl(ehci, &ehci->regs->command); |
138 | if (ehci->reclaim) | ||
139 | end_unlink_async(ehci); | ||
140 | ehci_work(ehci); | 138 | ehci_work(ehci); |
141 | 139 | ||
142 | /* Unlike other USB host controller types, EHCI doesn't have | 140 | /* Unlike other USB host controller types, EHCI doesn't have |
@@ -180,6 +178,9 @@ static int ehci_bus_suspend (struct usb_hcd *hcd) | |||
180 | ehci_halt (ehci); | 178 | ehci_halt (ehci); |
181 | hcd->state = HC_STATE_SUSPENDED; | 179 | hcd->state = HC_STATE_SUSPENDED; |
182 | 180 | ||
181 | if (ehci->reclaim) | ||
182 | end_unlink_async(ehci); | ||
183 | |||
183 | /* allow remote wakeup */ | 184 | /* allow remote wakeup */ |
184 | mask = INTR_MASK; | 185 | mask = INTR_MASK; |
185 | if (!device_may_wakeup(&hcd->self.root_hub->dev)) | 186 | if (!device_may_wakeup(&hcd->self.root_hub->dev)) |
diff --git a/drivers/usb/host/ohci-hcd.c b/drivers/usb/host/ohci-hcd.c index dd4798ee028e..33f1c1c32edf 100644 --- a/drivers/usb/host/ohci-hcd.c +++ b/drivers/usb/host/ohci-hcd.c | |||
@@ -467,7 +467,7 @@ static void unlink_watchdog_func(unsigned long _ohci) | |||
467 | out: | 467 | out: |
468 | kfree(seen); | 468 | kfree(seen); |
469 | if (ohci->eds_scheduled) | 469 | if (ohci->eds_scheduled) |
470 | mod_timer(&ohci->unlink_watchdog, round_jiffies_relative(HZ)); | 470 | mod_timer(&ohci->unlink_watchdog, round_jiffies(jiffies + HZ)); |
471 | done: | 471 | done: |
472 | spin_unlock_irqrestore(&ohci->lock, flags); | 472 | spin_unlock_irqrestore(&ohci->lock, flags); |
473 | } | 473 | } |
diff --git a/drivers/usb/host/ohci-q.c b/drivers/usb/host/ohci-q.c index 51817322232b..9c9f3b59186f 100644 --- a/drivers/usb/host/ohci-q.c +++ b/drivers/usb/host/ohci-q.c | |||
@@ -169,7 +169,7 @@ static int ed_schedule (struct ohci_hcd *ohci, struct ed *ed) | |||
169 | if (quirk_zfmicro(ohci) | 169 | if (quirk_zfmicro(ohci) |
170 | && (ed->type == PIPE_INTERRUPT) | 170 | && (ed->type == PIPE_INTERRUPT) |
171 | && !(ohci->eds_scheduled++)) | 171 | && !(ohci->eds_scheduled++)) |
172 | mod_timer(&ohci->unlink_watchdog, round_jiffies_relative(HZ)); | 172 | mod_timer(&ohci->unlink_watchdog, round_jiffies(jiffies + HZ)); |
173 | wmb (); | 173 | wmb (); |
174 | 174 | ||
175 | /* we care about rm_list when setting CLE/BLE in case the HC was at | 175 | /* we care about rm_list when setting CLE/BLE in case the HC was at |
diff --git a/drivers/usb/misc/usbtest.c b/drivers/usb/misc/usbtest.c index da922dfc0dcc..b6b5b2affad1 100644 --- a/drivers/usb/misc/usbtest.c +++ b/drivers/usb/misc/usbtest.c | |||
@@ -378,6 +378,7 @@ alloc_sglist (int nents, int max, int vary) | |||
378 | sg = kmalloc (nents * sizeof *sg, GFP_KERNEL); | 378 | sg = kmalloc (nents * sizeof *sg, GFP_KERNEL); |
379 | if (!sg) | 379 | if (!sg) |
380 | return NULL; | 380 | return NULL; |
381 | sg_init_table(sg, nents); | ||
381 | 382 | ||
382 | for (i = 0; i < nents; i++) { | 383 | for (i = 0; i < nents; i++) { |
383 | char *buf; | 384 | char *buf; |
@@ -390,7 +391,7 @@ alloc_sglist (int nents, int max, int vary) | |||
390 | } | 391 | } |
391 | 392 | ||
392 | /* kmalloc pages are always physically contiguous! */ | 393 | /* kmalloc pages are always physically contiguous! */ |
393 | sg_init_one(&sg[i], buf, size); | 394 | sg_set_buf(&sg[i], buf, size); |
394 | 395 | ||
395 | switch (pattern) { | 396 | switch (pattern) { |
396 | case 0: | 397 | case 0: |
diff --git a/drivers/usb/serial/cp2101.c b/drivers/usb/serial/cp2101.c index f3ca66017a03..324bb61d68ff 100644 --- a/drivers/usb/serial/cp2101.c +++ b/drivers/usb/serial/cp2101.c | |||
@@ -75,6 +75,7 @@ static struct usb_device_id id_table [] = { | |||
75 | { USB_DEVICE(0x10C4, 0x81E2) }, /* Lipowsky Industrie Elektronik GmbH, Baby-LIN */ | 75 | { USB_DEVICE(0x10C4, 0x81E2) }, /* Lipowsky Industrie Elektronik GmbH, Baby-LIN */ |
76 | { USB_DEVICE(0x10C4, 0x81E7) }, /* Aerocomm Radio */ | 76 | { USB_DEVICE(0x10C4, 0x81E7) }, /* Aerocomm Radio */ |
77 | { USB_DEVICE(0x10C4, 0x8218) }, /* Lipowsky Industrie Elektronik GmbH, HARP-1 */ | 77 | { USB_DEVICE(0x10C4, 0x8218) }, /* Lipowsky Industrie Elektronik GmbH, HARP-1 */ |
78 | { USB_DEVICE(0x10c4, 0x8293) }, /* Telegesys ETRX2USB */ | ||
78 | { USB_DEVICE(0x10C4, 0xEA60) }, /* Silicon Labs factory default */ | 79 | { USB_DEVICE(0x10C4, 0xEA60) }, /* Silicon Labs factory default */ |
79 | { USB_DEVICE(0x10C4, 0xEA61) }, /* Silicon Labs factory default */ | 80 | { USB_DEVICE(0x10C4, 0xEA61) }, /* Silicon Labs factory default */ |
80 | { USB_DEVICE(0x10C4, 0xF001) }, /* Elan Digital Systems USBscope50 */ | 81 | { USB_DEVICE(0x10C4, 0xF001) }, /* Elan Digital Systems USBscope50 */ |
diff --git a/drivers/usb/serial/keyspan.h b/drivers/usb/serial/keyspan.h index 8a0d17401529..74ce8bca3e66 100644 --- a/drivers/usb/serial/keyspan.h +++ b/drivers/usb/serial/keyspan.h | |||
@@ -637,6 +637,7 @@ static struct usb_serial_driver keyspan_pre_device = { | |||
637 | .description = "Keyspan - (without firmware)", | 637 | .description = "Keyspan - (without firmware)", |
638 | .id_table = keyspan_pre_ids, | 638 | .id_table = keyspan_pre_ids, |
639 | .num_interrupt_in = NUM_DONT_CARE, | 639 | .num_interrupt_in = NUM_DONT_CARE, |
640 | .num_interrupt_out = NUM_DONT_CARE, | ||
640 | .num_bulk_in = NUM_DONT_CARE, | 641 | .num_bulk_in = NUM_DONT_CARE, |
641 | .num_bulk_out = NUM_DONT_CARE, | 642 | .num_bulk_out = NUM_DONT_CARE, |
642 | .num_ports = 1, | 643 | .num_ports = 1, |
@@ -651,6 +652,7 @@ static struct usb_serial_driver keyspan_1port_device = { | |||
651 | .description = "Keyspan 1 port adapter", | 652 | .description = "Keyspan 1 port adapter", |
652 | .id_table = keyspan_1port_ids, | 653 | .id_table = keyspan_1port_ids, |
653 | .num_interrupt_in = NUM_DONT_CARE, | 654 | .num_interrupt_in = NUM_DONT_CARE, |
655 | .num_interrupt_out = NUM_DONT_CARE, | ||
654 | .num_bulk_in = NUM_DONT_CARE, | 656 | .num_bulk_in = NUM_DONT_CARE, |
655 | .num_bulk_out = NUM_DONT_CARE, | 657 | .num_bulk_out = NUM_DONT_CARE, |
656 | .num_ports = 1, | 658 | .num_ports = 1, |
@@ -678,6 +680,7 @@ static struct usb_serial_driver keyspan_2port_device = { | |||
678 | .description = "Keyspan 2 port adapter", | 680 | .description = "Keyspan 2 port adapter", |
679 | .id_table = keyspan_2port_ids, | 681 | .id_table = keyspan_2port_ids, |
680 | .num_interrupt_in = NUM_DONT_CARE, | 682 | .num_interrupt_in = NUM_DONT_CARE, |
683 | .num_interrupt_out = NUM_DONT_CARE, | ||
681 | .num_bulk_in = NUM_DONT_CARE, | 684 | .num_bulk_in = NUM_DONT_CARE, |
682 | .num_bulk_out = NUM_DONT_CARE, | 685 | .num_bulk_out = NUM_DONT_CARE, |
683 | .num_ports = 2, | 686 | .num_ports = 2, |
@@ -705,6 +708,7 @@ static struct usb_serial_driver keyspan_4port_device = { | |||
705 | .description = "Keyspan 4 port adapter", | 708 | .description = "Keyspan 4 port adapter", |
706 | .id_table = keyspan_4port_ids, | 709 | .id_table = keyspan_4port_ids, |
707 | .num_interrupt_in = NUM_DONT_CARE, | 710 | .num_interrupt_in = NUM_DONT_CARE, |
711 | .num_interrupt_out = NUM_DONT_CARE, | ||
708 | .num_bulk_in = NUM_DONT_CARE, | 712 | .num_bulk_in = NUM_DONT_CARE, |
709 | .num_bulk_out = NUM_DONT_CARE, | 713 | .num_bulk_out = NUM_DONT_CARE, |
710 | .num_ports = 4, | 714 | .num_ports = 4, |
diff --git a/drivers/usb/serial/ti_usb_3410_5052.c b/drivers/usb/serial/ti_usb_3410_5052.c index b517f93352ec..e3d241f67afc 100644 --- a/drivers/usb/serial/ti_usb_3410_5052.c +++ b/drivers/usb/serial/ti_usb_3410_5052.c | |||
@@ -265,8 +265,8 @@ static struct usb_serial_driver ti_1port_device = { | |||
265 | .description = "TI USB 3410 1 port adapter", | 265 | .description = "TI USB 3410 1 port adapter", |
266 | .usb_driver = &ti_usb_driver, | 266 | .usb_driver = &ti_usb_driver, |
267 | .id_table = ti_id_table_3410, | 267 | .id_table = ti_id_table_3410, |
268 | .num_interrupt_in = 1, | 268 | .num_interrupt_in = NUM_DONT_CARE, |
269 | .num_bulk_in = 1, | 269 | .num_bulk_in = NUM_DONT_CARE, |
270 | .num_bulk_out = 1, | 270 | .num_bulk_out = 1, |
271 | .num_ports = 1, | 271 | .num_ports = 1, |
272 | .attach = ti_startup, | 272 | .attach = ti_startup, |
diff --git a/drivers/usb/serial/visor.c b/drivers/usb/serial/visor.c index 22b3f78a388c..c2b01f7c3197 100644 --- a/drivers/usb/serial/visor.c +++ b/drivers/usb/serial/visor.c | |||
@@ -191,7 +191,7 @@ static struct usb_serial_driver handspring_device = { | |||
191 | .id_table = id_table, | 191 | .id_table = id_table, |
192 | .num_interrupt_in = NUM_DONT_CARE, | 192 | .num_interrupt_in = NUM_DONT_CARE, |
193 | .num_bulk_in = 2, | 193 | .num_bulk_in = 2, |
194 | .num_bulk_out = 2, | 194 | .num_bulk_out = NUM_DONT_CARE, |
195 | .num_ports = 2, | 195 | .num_ports = 2, |
196 | .open = visor_open, | 196 | .open = visor_open, |
197 | .close = visor_close, | 197 | .close = visor_close, |
diff --git a/drivers/watchdog/it8712f_wdt.c b/drivers/watchdog/it8712f_wdt.c index 1efcad3b6fca..ca90c5192596 100644 --- a/drivers/watchdog/it8712f_wdt.c +++ b/drivers/watchdog/it8712f_wdt.c | |||
@@ -111,15 +111,6 @@ superio_inw(int reg) | |||
111 | return val; | 111 | return val; |
112 | } | 112 | } |
113 | 113 | ||
114 | static void | ||
115 | superio_outw(int val, int reg) | ||
116 | { | ||
117 | outb(reg++, REG); | ||
118 | outb((val >> 8) & 0xff, VAL); | ||
119 | outb(reg, REG); | ||
120 | outb(val & 0xff, VAL); | ||
121 | } | ||
122 | |||
123 | static inline void | 114 | static inline void |
124 | superio_select(int ldn) | 115 | superio_select(int ldn) |
125 | { | 116 | { |
@@ -170,9 +161,8 @@ it8712f_wdt_update_margin(void) | |||
170 | superio_outb(config, WDT_CONFIG); | 161 | superio_outb(config, WDT_CONFIG); |
171 | 162 | ||
172 | if (revision >= 0x08) | 163 | if (revision >= 0x08) |
173 | superio_outw(units, WDT_TIMEOUT); | 164 | superio_outb(units >> 8, WDT_TIMEOUT + 1); |
174 | else | 165 | superio_outb(units, WDT_TIMEOUT); |
175 | superio_outb(units, WDT_TIMEOUT); | ||
176 | } | 166 | } |
177 | 167 | ||
178 | static int | 168 | static int |
diff --git a/fs/afs/cell.c b/fs/afs/cell.c index 788865df1bc9..584bb0f9c36a 100644 --- a/fs/afs/cell.c +++ b/fs/afs/cell.c | |||
@@ -138,6 +138,7 @@ struct afs_cell *afs_cell_create(const char *name, char *vllist) | |||
138 | cell = afs_cell_alloc(name, vllist); | 138 | cell = afs_cell_alloc(name, vllist); |
139 | if (IS_ERR(cell)) { | 139 | if (IS_ERR(cell)) { |
140 | _leave(" = %ld", PTR_ERR(cell)); | 140 | _leave(" = %ld", PTR_ERR(cell)); |
141 | up_write(&afs_cells_sem); | ||
141 | return cell; | 142 | return cell; |
142 | } | 143 | } |
143 | 144 | ||
diff --git a/fs/afs/internal.h b/fs/afs/internal.h index 9ba16edc0af2..eec41c76de72 100644 --- a/fs/afs/internal.h +++ b/fs/afs/internal.h | |||
@@ -749,7 +749,7 @@ extern int afs_fsync(struct file *, struct dentry *, int); | |||
749 | extern unsigned afs_debug; | 749 | extern unsigned afs_debug; |
750 | 750 | ||
751 | #define dbgprintk(FMT,...) \ | 751 | #define dbgprintk(FMT,...) \ |
752 | printk("[%x%-6.6s] "FMT"\n", smp_processor_id(), current->comm ,##__VA_ARGS__) | 752 | printk("[%-6.6s] "FMT"\n", current->comm ,##__VA_ARGS__) |
753 | 753 | ||
754 | /* make sure we maintain the format strings, even when debugging is disabled */ | 754 | /* make sure we maintain the format strings, even when debugging is disabled */ |
755 | static inline __attribute__((format(printf,1,2))) | 755 | static inline __attribute__((format(printf,1,2))) |
diff --git a/fs/efs/inode.c b/fs/efs/inode.c index 79e19e5958e1..a8e7797b9477 100644 --- a/fs/efs/inode.c +++ b/fs/efs/inode.c | |||
@@ -140,7 +140,7 @@ struct inode *efs_iget(struct super_block *super, unsigned long ino) | |||
140 | brelse(bh); | 140 | brelse(bh); |
141 | 141 | ||
142 | #ifdef DEBUG | 142 | #ifdef DEBUG |
143 | printk(KERN_DEBUG "EFS: read_inode(): inode %lu, extents %d, mode %o\n", | 143 | printk(KERN_DEBUG "EFS: efs_iget(): inode %lu, extents %d, mode %o\n", |
144 | inode->i_ino, in->numextents, inode->i_mode); | 144 | inode->i_ino, in->numextents, inode->i_mode); |
145 | #endif | 145 | #endif |
146 | 146 | ||
diff --git a/fs/splice.c b/fs/splice.c index 0670c915cd35..a861bb318ac8 100644 --- a/fs/splice.c +++ b/fs/splice.c | |||
@@ -320,7 +320,7 @@ __generic_file_splice_read(struct file *in, loff_t *ppos, | |||
320 | break; | 320 | break; |
321 | 321 | ||
322 | error = add_to_page_cache_lru(page, mapping, index, | 322 | error = add_to_page_cache_lru(page, mapping, index, |
323 | GFP_KERNEL); | 323 | mapping_gfp_mask(mapping)); |
324 | if (unlikely(error)) { | 324 | if (unlikely(error)) { |
325 | page_cache_release(page); | 325 | page_cache_release(page); |
326 | if (error == -EEXIST) | 326 | if (error == -EEXIST) |
diff --git a/include/asm-alpha/current.h b/include/asm-alpha/current.h index 8d88a13c1bec..094d285a1b34 100644 --- a/include/asm-alpha/current.h +++ b/include/asm-alpha/current.h | |||
@@ -3,7 +3,7 @@ | |||
3 | 3 | ||
4 | #include <linux/thread_info.h> | 4 | #include <linux/thread_info.h> |
5 | 5 | ||
6 | #define get_current() (current_thread_info()->task + 0) | 6 | #define get_current() (current_thread_info()->task) |
7 | #define current get_current() | 7 | #define current get_current() |
8 | 8 | ||
9 | #endif /* _ALPHA_CURRENT_H */ | 9 | #endif /* _ALPHA_CURRENT_H */ |
diff --git a/include/asm-alpha/dma-mapping.h b/include/asm-alpha/dma-mapping.h index 75a1aff5b57b..db351d1296f4 100644 --- a/include/asm-alpha/dma-mapping.h +++ b/include/asm-alpha/dma-mapping.h | |||
@@ -11,7 +11,7 @@ | |||
11 | #define dma_unmap_single(dev, addr, size, dir) \ | 11 | #define dma_unmap_single(dev, addr, size, dir) \ |
12 | pci_unmap_single(alpha_gendev_to_pci(dev), addr, size, dir) | 12 | pci_unmap_single(alpha_gendev_to_pci(dev), addr, size, dir) |
13 | #define dma_alloc_coherent(dev, size, addr, gfp) \ | 13 | #define dma_alloc_coherent(dev, size, addr, gfp) \ |
14 | pci_alloc_consistent(alpha_gendev_to_pci(dev), size, addr) | 14 | __pci_alloc_consistent(alpha_gendev_to_pci(dev), size, addr, gfp) |
15 | #define dma_free_coherent(dev, size, va, addr) \ | 15 | #define dma_free_coherent(dev, size, va, addr) \ |
16 | pci_free_consistent(alpha_gendev_to_pci(dev), size, va, addr) | 16 | pci_free_consistent(alpha_gendev_to_pci(dev), size, va, addr) |
17 | #define dma_map_page(dev, page, off, size, dir) \ | 17 | #define dma_map_page(dev, page, off, size, dir) \ |
diff --git a/include/asm-alpha/kvm.h b/include/asm-alpha/kvm.h new file mode 100644 index 000000000000..b9daec429689 --- /dev/null +++ b/include/asm-alpha/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_ALPHA_H | ||
2 | #define __LINUX_KVM_ALPHA_H | ||
3 | |||
4 | /* alpha does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-alpha/pci.h b/include/asm-alpha/pci.h index d5b10ef64364..d31fd49ff79a 100644 --- a/include/asm-alpha/pci.h +++ b/include/asm-alpha/pci.h | |||
@@ -76,7 +76,13 @@ extern inline void pcibios_penalize_isa_irq(int irq, int active) | |||
76 | successful and sets *DMA_ADDRP to the pci side dma address as well, | 76 | successful and sets *DMA_ADDRP to the pci side dma address as well, |
77 | else DMA_ADDRP is undefined. */ | 77 | else DMA_ADDRP is undefined. */ |
78 | 78 | ||
79 | extern void *pci_alloc_consistent(struct pci_dev *, size_t, dma_addr_t *); | 79 | extern void *__pci_alloc_consistent(struct pci_dev *, size_t, |
80 | dma_addr_t *, gfp_t); | ||
81 | static inline void * | ||
82 | pci_alloc_consistent(struct pci_dev *dev, size_t size, dma_addr_t *dma) | ||
83 | { | ||
84 | return __pci_alloc_consistent(dev, size, dma, GFP_ATOMIC); | ||
85 | } | ||
80 | 86 | ||
81 | /* Free and unmap a consistent DMA buffer. CPU_ADDR and DMA_ADDR must | 87 | /* Free and unmap a consistent DMA buffer. CPU_ADDR and DMA_ADDR must |
82 | be values that were returned from pci_alloc_consistent. SIZE must | 88 | be values that were returned from pci_alloc_consistent. SIZE must |
diff --git a/include/asm-arm/kvm.h b/include/asm-arm/kvm.h new file mode 100644 index 000000000000..cb3c08cbcb9e --- /dev/null +++ b/include/asm-arm/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_ARM_H | ||
2 | #define __LINUX_KVM_ARM_H | ||
3 | |||
4 | /* arm does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-avr32/kvm.h b/include/asm-avr32/kvm.h new file mode 100644 index 000000000000..8c5777020e2c --- /dev/null +++ b/include/asm-avr32/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_AVR32_H | ||
2 | #define __LINUX_KVM_AVR32_H | ||
3 | |||
4 | /* avr32 does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-blackfin/kvm.h b/include/asm-blackfin/kvm.h new file mode 100644 index 000000000000..e3477d77c014 --- /dev/null +++ b/include/asm-blackfin/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_BLACKFIN_H | ||
2 | #define __LINUX_KVM_BLACKFIN_H | ||
3 | |||
4 | /* blackfin does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-cris/kvm.h b/include/asm-cris/kvm.h new file mode 100644 index 000000000000..c860f51149f0 --- /dev/null +++ b/include/asm-cris/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_CRIS_H | ||
2 | #define __LINUX_KVM_CRIS_H | ||
3 | |||
4 | /* cris does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-frv/kvm.h b/include/asm-frv/kvm.h new file mode 100644 index 000000000000..9c8a4f08d0a9 --- /dev/null +++ b/include/asm-frv/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_FRV_H | ||
2 | #define __LINUX_KVM_FRV_H | ||
3 | |||
4 | /* frv does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-generic/Kbuild.asm b/include/asm-generic/Kbuild.asm index fd9dcfd91c39..92a6d91d0c1a 100644 --- a/include/asm-generic/Kbuild.asm +++ b/include/asm-generic/Kbuild.asm | |||
@@ -1,3 +1,5 @@ | |||
1 | header-y += kvm.h | ||
2 | |||
1 | ifeq ($(wildcard include/asm-$(SRCARCH)/a.out.h),include/asm-$(SRCARCH)/a.out.h) | 3 | ifeq ($(wildcard include/asm-$(SRCARCH)/a.out.h),include/asm-$(SRCARCH)/a.out.h) |
2 | unifdef-y += a.out.h | 4 | unifdef-y += a.out.h |
3 | endif | 5 | endif |
diff --git a/include/asm-h8300/kvm.h b/include/asm-h8300/kvm.h new file mode 100644 index 000000000000..bdbed7b987e1 --- /dev/null +++ b/include/asm-h8300/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_H8300_H | ||
2 | #define __LINUX_KVM_H8300_H | ||
3 | |||
4 | /* h8300 does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-ia64/kvm.h b/include/asm-ia64/kvm.h new file mode 100644 index 000000000000..030d29b4b26b --- /dev/null +++ b/include/asm-ia64/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_IA64_H | ||
2 | #define __LINUX_KVM_IA64_H | ||
3 | |||
4 | /* ia64 does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-m32r/kvm.h b/include/asm-m32r/kvm.h new file mode 100644 index 000000000000..99a40515b77e --- /dev/null +++ b/include/asm-m32r/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_M32R_H | ||
2 | #define __LINUX_KVM_M32R_H | ||
3 | |||
4 | /* m32r does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-m68k/kvm.h b/include/asm-m68k/kvm.h new file mode 100644 index 000000000000..7ed27fce5240 --- /dev/null +++ b/include/asm-m68k/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_M68K_H | ||
2 | #define __LINUX_KVM_M68K_H | ||
3 | |||
4 | /* m68k does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-m68knommu/kvm.h b/include/asm-m68knommu/kvm.h new file mode 100644 index 000000000000..b49d4258dabb --- /dev/null +++ b/include/asm-m68knommu/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_M68KNOMMU_H | ||
2 | #define __LINUX_KVM_M68KNOMMU_H | ||
3 | |||
4 | /* m68knommu does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-mips/kvm.h b/include/asm-mips/kvm.h new file mode 100644 index 000000000000..093a5b7f796b --- /dev/null +++ b/include/asm-mips/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_MIPS_H | ||
2 | #define __LINUX_KVM_MIPS_H | ||
3 | |||
4 | /* mips does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-mips/mach-au1x00/au1000.h b/include/asm-mips/mach-au1x00/au1000.h index cb18af989645..5bb57bf2b9d7 100644 --- a/include/asm-mips/mach-au1x00/au1000.h +++ b/include/asm-mips/mach-au1x00/au1000.h | |||
@@ -1786,6 +1786,7 @@ struct cpu_spec { | |||
1786 | char *cpu_name; | 1786 | char *cpu_name; |
1787 | unsigned char cpu_od; /* Set Config[OD] */ | 1787 | unsigned char cpu_od; /* Set Config[OD] */ |
1788 | unsigned char cpu_bclk; /* Enable BCLK switching */ | 1788 | unsigned char cpu_bclk; /* Enable BCLK switching */ |
1789 | unsigned char cpu_pll_wo; /* sys_cpupll reg. write-only */ | ||
1789 | }; | 1790 | }; |
1790 | 1791 | ||
1791 | extern struct cpu_spec cpu_specs[]; | 1792 | extern struct cpu_spec cpu_specs[]; |
diff --git a/include/asm-mn10300/kvm.h b/include/asm-mn10300/kvm.h new file mode 100644 index 000000000000..f6b609ff4a57 --- /dev/null +++ b/include/asm-mn10300/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_MN10300_H | ||
2 | #define __LINUX_KVM_MN10300_H | ||
3 | |||
4 | /* mn10300 does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-parisc/kvm.h b/include/asm-parisc/kvm.h new file mode 100644 index 000000000000..00cc45812547 --- /dev/null +++ b/include/asm-parisc/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_PARISC_H | ||
2 | #define __LINUX_KVM_PARISC_H | ||
3 | |||
4 | /* parisc does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-powerpc/kvm.h b/include/asm-powerpc/kvm.h new file mode 100644 index 000000000000..d1b530fbf8dd --- /dev/null +++ b/include/asm-powerpc/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_POWERPC_H | ||
2 | #define __LINUX_KVM_POWERPC_H | ||
3 | |||
4 | /* powerpc does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-s390/kvm.h b/include/asm-s390/kvm.h new file mode 100644 index 000000000000..573f2a351386 --- /dev/null +++ b/include/asm-s390/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_S390_H | ||
2 | #define __LINUX_KVM_S390_H | ||
3 | |||
4 | /* s390 does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-sh/floppy.h b/include/asm-sh/floppy.h deleted file mode 100644 index 59fbfdc90dfb..000000000000 --- a/include/asm-sh/floppy.h +++ /dev/null | |||
@@ -1,268 +0,0 @@ | |||
1 | /* | ||
2 | * Architecture specific parts of the Floppy driver | ||
3 | * include/asm-i386/floppy.h | ||
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 | * Copyright (C) 1995 | ||
10 | */ | ||
11 | #ifndef __ASM_SH_FLOPPY_H | ||
12 | #define __ASM_SH_FLOPPY_H | ||
13 | |||
14 | #include <linux/vmalloc.h> | ||
15 | |||
16 | |||
17 | /* | ||
18 | * The DMA channel used by the floppy controller cannot access data at | ||
19 | * addresses >= 16MB | ||
20 | * | ||
21 | * Went back to the 1MB limit, as some people had problems with the floppy | ||
22 | * driver otherwise. It doesn't matter much for performance anyway, as most | ||
23 | * floppy accesses go through the track buffer. | ||
24 | */ | ||
25 | #define _CROSS_64KB(a,s,vdma) \ | ||
26 | (!vdma && ((unsigned long)(a)/K_64 != ((unsigned long)(a) + (s) - 1) / K_64)) | ||
27 | |||
28 | #define CROSS_64KB(a,s) _CROSS_64KB(a,s,use_virtual_dma & 1) | ||
29 | |||
30 | |||
31 | #define SW fd_routine[use_virtual_dma&1] | ||
32 | #define CSW fd_routine[can_use_virtual_dma & 1] | ||
33 | |||
34 | |||
35 | #define fd_inb(port) inb_p(port) | ||
36 | #define fd_outb(value,port) outb_p(value,port) | ||
37 | |||
38 | #define fd_request_dma() CSW._request_dma(FLOPPY_DMA,"floppy") | ||
39 | #define fd_free_dma() CSW._free_dma(FLOPPY_DMA) | ||
40 | #define fd_enable_irq() enable_irq(FLOPPY_IRQ) | ||
41 | #define fd_disable_irq() disable_irq(FLOPPY_IRQ) | ||
42 | #define fd_free_irq() free_irq(FLOPPY_IRQ, NULL) | ||
43 | #define fd_get_dma_residue() SW._get_dma_residue(FLOPPY_DMA) | ||
44 | #define fd_dma_mem_alloc(size) SW._dma_mem_alloc(size) | ||
45 | #define fd_dma_setup(addr, size, mode, io) SW._dma_setup(addr, size, mode, io) | ||
46 | |||
47 | #define FLOPPY_CAN_FALLBACK_ON_NODMA | ||
48 | |||
49 | static int virtual_dma_count; | ||
50 | static int virtual_dma_residue; | ||
51 | static char *virtual_dma_addr; | ||
52 | static int virtual_dma_mode; | ||
53 | static int doing_pdma; | ||
54 | |||
55 | static void floppy_hardint(int irq, void *dev_id, struct pt_regs * regs) | ||
56 | { | ||
57 | register unsigned char st; | ||
58 | |||
59 | #undef TRACE_FLPY_INT | ||
60 | |||
61 | #ifdef TRACE_FLPY_INT | ||
62 | static int calls=0; | ||
63 | static int bytes=0; | ||
64 | static int dma_wait=0; | ||
65 | #endif | ||
66 | if(!doing_pdma) { | ||
67 | floppy_interrupt(irq, dev_id, regs); | ||
68 | return; | ||
69 | } | ||
70 | |||
71 | #ifdef TRACE_FLPY_INT | ||
72 | if(!calls) | ||
73 | bytes = virtual_dma_count; | ||
74 | #endif | ||
75 | |||
76 | { | ||
77 | register int lcount; | ||
78 | register char *lptr; | ||
79 | |||
80 | st = 1; | ||
81 | for(lcount=virtual_dma_count, lptr=virtual_dma_addr; | ||
82 | lcount; lcount--, lptr++) { | ||
83 | st=inb(virtual_dma_port+4) & 0xa0 ; | ||
84 | if(st != 0xa0) | ||
85 | break; | ||
86 | if(virtual_dma_mode) | ||
87 | outb_p(*lptr, virtual_dma_port+5); | ||
88 | else | ||
89 | *lptr = inb_p(virtual_dma_port+5); | ||
90 | } | ||
91 | virtual_dma_count = lcount; | ||
92 | virtual_dma_addr = lptr; | ||
93 | st = inb(virtual_dma_port+4); | ||
94 | } | ||
95 | |||
96 | #ifdef TRACE_FLPY_INT | ||
97 | calls++; | ||
98 | #endif | ||
99 | if(st == 0x20) | ||
100 | return; | ||
101 | if(!(st & 0x20)) { | ||
102 | virtual_dma_residue += virtual_dma_count; | ||
103 | virtual_dma_count=0; | ||
104 | #ifdef TRACE_FLPY_INT | ||
105 | printk("count=%x, residue=%x calls=%d bytes=%d dma_wait=%d\n", | ||
106 | virtual_dma_count, virtual_dma_residue, calls, bytes, | ||
107 | dma_wait); | ||
108 | calls = 0; | ||
109 | dma_wait=0; | ||
110 | #endif | ||
111 | doing_pdma = 0; | ||
112 | floppy_interrupt(irq, dev_id, regs); | ||
113 | return; | ||
114 | } | ||
115 | #ifdef TRACE_FLPY_INT | ||
116 | if(!virtual_dma_count) | ||
117 | dma_wait++; | ||
118 | #endif | ||
119 | } | ||
120 | |||
121 | static void fd_disable_dma(void) | ||
122 | { | ||
123 | if(! (can_use_virtual_dma & 1)) | ||
124 | disable_dma(FLOPPY_DMA); | ||
125 | doing_pdma = 0; | ||
126 | virtual_dma_residue += virtual_dma_count; | ||
127 | virtual_dma_count=0; | ||
128 | } | ||
129 | |||
130 | static int vdma_request_dma(unsigned int dmanr, const char * device_id) | ||
131 | { | ||
132 | return 0; | ||
133 | } | ||
134 | |||
135 | static void vdma_nop(unsigned int dummy) | ||
136 | { | ||
137 | } | ||
138 | |||
139 | |||
140 | static int vdma_get_dma_residue(unsigned int dummy) | ||
141 | { | ||
142 | return virtual_dma_count + virtual_dma_residue; | ||
143 | } | ||
144 | |||
145 | |||
146 | static int fd_request_irq(void) | ||
147 | { | ||
148 | if(can_use_virtual_dma) | ||
149 | return request_irq(FLOPPY_IRQ, floppy_hardint, | ||
150 | IRQF_DISABLED, "floppy", NULL); | ||
151 | else | ||
152 | return request_irq(FLOPPY_IRQ, floppy_interrupt, | ||
153 | IRQF_DISABLED, "floppy", NULL); | ||
154 | } | ||
155 | |||
156 | static unsigned long dma_mem_alloc(unsigned long size) | ||
157 | { | ||
158 | return __get_dma_pages(GFP_KERNEL,get_order(size)); | ||
159 | } | ||
160 | |||
161 | |||
162 | static unsigned long vdma_mem_alloc(unsigned long size) | ||
163 | { | ||
164 | return (unsigned long) vmalloc(size); | ||
165 | |||
166 | } | ||
167 | |||
168 | #define nodma_mem_alloc(size) vdma_mem_alloc(size) | ||
169 | |||
170 | static void _fd_dma_mem_free(unsigned long addr, unsigned long size) | ||
171 | { | ||
172 | if((unsigned int) addr >= (unsigned int) high_memory) | ||
173 | return vfree((void *)addr); | ||
174 | else | ||
175 | free_pages(addr, get_order(size)); | ||
176 | } | ||
177 | |||
178 | #define fd_dma_mem_free(addr, size) _fd_dma_mem_free(addr, size) | ||
179 | |||
180 | static void _fd_chose_dma_mode(char *addr, unsigned long size) | ||
181 | { | ||
182 | if(can_use_virtual_dma == 2) { | ||
183 | if((unsigned int) addr >= (unsigned int) high_memory || | ||
184 | virt_to_phys(addr) >= 0x10000000) | ||
185 | use_virtual_dma = 1; | ||
186 | else | ||
187 | use_virtual_dma = 0; | ||
188 | } else { | ||
189 | use_virtual_dma = can_use_virtual_dma & 1; | ||
190 | } | ||
191 | } | ||
192 | |||
193 | #define fd_chose_dma_mode(addr, size) _fd_chose_dma_mode(addr, size) | ||
194 | |||
195 | |||
196 | static int vdma_dma_setup(char *addr, unsigned long size, int mode, int io) | ||
197 | { | ||
198 | doing_pdma = 1; | ||
199 | virtual_dma_port = io; | ||
200 | virtual_dma_mode = (mode == DMA_MODE_WRITE); | ||
201 | virtual_dma_addr = addr; | ||
202 | virtual_dma_count = size; | ||
203 | virtual_dma_residue = 0; | ||
204 | return 0; | ||
205 | } | ||
206 | |||
207 | static int hard_dma_setup(char *addr, unsigned long size, int mode, int io) | ||
208 | { | ||
209 | #ifdef FLOPPY_SANITY_CHECK | ||
210 | if (CROSS_64KB(addr, size)) { | ||
211 | printk("DMA crossing 64-K boundary %p-%p\n", addr, addr+size); | ||
212 | return -1; | ||
213 | } | ||
214 | #endif | ||
215 | |||
216 | __flush_purge_region(addr, size); | ||
217 | |||
218 | /* actual, physical DMA */ | ||
219 | doing_pdma = 0; | ||
220 | clear_dma_ff(FLOPPY_DMA); | ||
221 | set_dma_mode(FLOPPY_DMA,mode); | ||
222 | set_dma_addr(FLOPPY_DMA,virt_to_phys(addr)); | ||
223 | set_dma_count(FLOPPY_DMA,size); | ||
224 | enable_dma(FLOPPY_DMA); | ||
225 | return 0; | ||
226 | } | ||
227 | |||
228 | static struct fd_routine_l { | ||
229 | int (*_request_dma)(unsigned int dmanr, const char * device_id); | ||
230 | void (*_free_dma)(unsigned int dmanr); | ||
231 | int (*_get_dma_residue)(unsigned int dummy); | ||
232 | unsigned long (*_dma_mem_alloc) (unsigned long size); | ||
233 | int (*_dma_setup)(char *addr, unsigned long size, int mode, int io); | ||
234 | } fd_routine[] = { | ||
235 | { | ||
236 | request_dma, | ||
237 | free_dma, | ||
238 | get_dma_residue, | ||
239 | dma_mem_alloc, | ||
240 | hard_dma_setup | ||
241 | }, | ||
242 | { | ||
243 | vdma_request_dma, | ||
244 | vdma_nop, | ||
245 | vdma_get_dma_residue, | ||
246 | vdma_mem_alloc, | ||
247 | vdma_dma_setup | ||
248 | } | ||
249 | }; | ||
250 | |||
251 | |||
252 | static int FDC1 = 0x3f0; | ||
253 | static int FDC2 = -1; | ||
254 | |||
255 | /* | ||
256 | * Floppy types are stored in the rtc's CMOS RAM and so rtc_lock | ||
257 | * is needed to prevent corrupted CMOS RAM in case "insmod floppy" | ||
258 | * coincides with another rtc CMOS user. Paul G. | ||
259 | */ | ||
260 | #define FLOPPY0_TYPE (4) | ||
261 | #define FLOPPY1_TYPE (0) | ||
262 | |||
263 | #define N_FDC 2 | ||
264 | #define N_DRIVE 8 | ||
265 | |||
266 | #define EXTRA_FLOPPY_PARAMS | ||
267 | |||
268 | #endif /* __ASM_SH_FLOPPY_H */ | ||
diff --git a/include/asm-sh/fpu.h b/include/asm-sh/fpu.h index f8429880a270..91462fea1507 100644 --- a/include/asm-sh/fpu.h +++ b/include/asm-sh/fpu.h | |||
@@ -1,9 +1,8 @@ | |||
1 | #ifndef __ASM_SH_FPU_H | 1 | #ifndef __ASM_SH_FPU_H |
2 | #define __ASM_SH_FPU_H | 2 | #define __ASM_SH_FPU_H |
3 | 3 | ||
4 | #define SR_FD 0x00008000 | ||
5 | |||
6 | #ifndef __ASSEMBLY__ | 4 | #ifndef __ASSEMBLY__ |
5 | #include <linux/preempt.h> | ||
7 | #include <asm/ptrace.h> | 6 | #include <asm/ptrace.h> |
8 | 7 | ||
9 | #ifdef CONFIG_SH_FPU | 8 | #ifdef CONFIG_SH_FPU |
@@ -21,25 +20,35 @@ struct task_struct; | |||
21 | 20 | ||
22 | extern void save_fpu(struct task_struct *__tsk, struct pt_regs *regs); | 21 | extern void save_fpu(struct task_struct *__tsk, struct pt_regs *regs); |
23 | #else | 22 | #else |
23 | |||
24 | #define release_fpu(regs) do { } while (0) | 24 | #define release_fpu(regs) do { } while (0) |
25 | #define grab_fpu(regs) do { } while (0) | 25 | #define grab_fpu(regs) do { } while (0) |
26 | #define save_fpu(tsk, regs) do { } while (0) | 26 | |
27 | static inline void save_fpu(struct task_struct *tsk, struct pt_regs *regs) | ||
28 | { | ||
29 | clear_tsk_thread_flag(tsk, TIF_USEDFPU); | ||
30 | } | ||
27 | #endif | 31 | #endif |
28 | 32 | ||
29 | extern int do_fpu_inst(unsigned short, struct pt_regs *); | 33 | extern int do_fpu_inst(unsigned short, struct pt_regs *); |
30 | 34 | ||
31 | #define unlazy_fpu(tsk, regs) do { \ | 35 | static inline void unlazy_fpu(struct task_struct *tsk, struct pt_regs *regs) |
32 | if (test_tsk_thread_flag(tsk, TIF_USEDFPU)) { \ | 36 | { |
33 | save_fpu(tsk, regs); \ | 37 | preempt_disable(); |
34 | } \ | 38 | if (test_tsk_thread_flag(tsk, TIF_USEDFPU)) |
35 | } while (0) | 39 | save_fpu(tsk, regs); |
36 | 40 | preempt_enable(); | |
37 | #define clear_fpu(tsk, regs) do { \ | 41 | } |
38 | if (test_tsk_thread_flag(tsk, TIF_USEDFPU)) { \ | 42 | |
39 | clear_tsk_thread_flag(tsk, TIF_USEDFPU); \ | 43 | static inline void clear_fpu(struct task_struct *tsk, struct pt_regs *regs) |
40 | release_fpu(regs); \ | 44 | { |
41 | } \ | 45 | preempt_disable(); |
42 | } while (0) | 46 | if (test_tsk_thread_flag(tsk, TIF_USEDFPU)) { |
47 | clear_tsk_thread_flag(tsk, TIF_USEDFPU); | ||
48 | release_fpu(regs); | ||
49 | } | ||
50 | preempt_enable(); | ||
51 | } | ||
43 | 52 | ||
44 | #endif /* __ASSEMBLY__ */ | 53 | #endif /* __ASSEMBLY__ */ |
45 | 54 | ||
diff --git a/include/asm-sh/kvm.h b/include/asm-sh/kvm.h new file mode 100644 index 000000000000..6af51dbab2d0 --- /dev/null +++ b/include/asm-sh/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_SH_H | ||
2 | #define __LINUX_KVM_SH_H | ||
3 | |||
4 | /* sh does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-sh/processor.h b/include/asm-sh/processor.h index 19fe47c1ca17..ec707b98e5b9 100644 --- a/include/asm-sh/processor.h +++ b/include/asm-sh/processor.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define __ASM_SH_PROCESSOR_H | 2 | #define __ASM_SH_PROCESSOR_H |
3 | 3 | ||
4 | #include <asm/cpu-features.h> | 4 | #include <asm/cpu-features.h> |
5 | #include <asm/fpu.h> | ||
6 | 5 | ||
7 | #ifndef __ASSEMBLY__ | 6 | #ifndef __ASSEMBLY__ |
8 | /* | 7 | /* |
diff --git a/include/asm-sh/processor_32.h b/include/asm-sh/processor_32.h index df2d5b039ef4..c09305d6a9d9 100644 --- a/include/asm-sh/processor_32.h +++ b/include/asm-sh/processor_32.h | |||
@@ -70,6 +70,7 @@ extern struct sh_cpuinfo cpu_data[]; | |||
70 | */ | 70 | */ |
71 | #define SR_DSP 0x00001000 | 71 | #define SR_DSP 0x00001000 |
72 | #define SR_IMASK 0x000000f0 | 72 | #define SR_IMASK 0x000000f0 |
73 | #define SR_FD 0x00008000 | ||
73 | 74 | ||
74 | /* | 75 | /* |
75 | * FPU structure and data | 76 | * FPU structure and data |
diff --git a/include/asm-sh/processor_64.h b/include/asm-sh/processor_64.h index eda4bef448e9..88a2edf8fa5d 100644 --- a/include/asm-sh/processor_64.h +++ b/include/asm-sh/processor_64.h | |||
@@ -112,6 +112,7 @@ extern struct sh_cpuinfo cpu_data[]; | |||
112 | #endif | 112 | #endif |
113 | 113 | ||
114 | #define SR_IMASK 0x000000f0 | 114 | #define SR_IMASK 0x000000f0 |
115 | #define SR_FD 0x00008000 | ||
115 | #define SR_SSTEP 0x08000000 | 116 | #define SR_SSTEP 0x08000000 |
116 | 117 | ||
117 | #ifndef __ASSEMBLY__ | 118 | #ifndef __ASSEMBLY__ |
diff --git a/include/asm-sparc/kvm.h b/include/asm-sparc/kvm.h new file mode 100644 index 000000000000..2e5478da3819 --- /dev/null +++ b/include/asm-sparc/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_SPARC_H | ||
2 | #define __LINUX_KVM_SPARC_H | ||
3 | |||
4 | /* sparc does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-sparc64/kvm.h b/include/asm-sparc64/kvm.h new file mode 100644 index 000000000000..380537a77bf9 --- /dev/null +++ b/include/asm-sparc64/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_SPARC64_H | ||
2 | #define __LINUX_KVM_SPARC64_H | ||
3 | |||
4 | /* sparc64 does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-um/kvm.h b/include/asm-um/kvm.h new file mode 100644 index 000000000000..66aa77094551 --- /dev/null +++ b/include/asm-um/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_UM_H | ||
2 | #define __LINUX_KVM_UM_H | ||
3 | |||
4 | /* um does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-v850/kvm.h b/include/asm-v850/kvm.h new file mode 100644 index 000000000000..3f729b79febc --- /dev/null +++ b/include/asm-v850/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_V850_H | ||
2 | #define __LINUX_KVM_V850_H | ||
3 | |||
4 | /* v850 does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/asm-xtensa/kvm.h b/include/asm-xtensa/kvm.h new file mode 100644 index 000000000000..bda4e331e98c --- /dev/null +++ b/include/asm-xtensa/kvm.h | |||
@@ -0,0 +1,6 @@ | |||
1 | #ifndef __LINUX_KVM_XTENSA_H | ||
2 | #define __LINUX_KVM_XTENSA_H | ||
3 | |||
4 | /* xtensa does not support KVM */ | ||
5 | |||
6 | #endif | ||
diff --git a/include/linux/Kbuild b/include/linux/Kbuild index 4a446a19295e..9cdd12a9e843 100644 --- a/include/linux/Kbuild +++ b/include/linux/Kbuild | |||
@@ -253,7 +253,7 @@ unifdef-y += kd.h | |||
253 | unifdef-y += kernelcapi.h | 253 | unifdef-y += kernelcapi.h |
254 | unifdef-y += kernel.h | 254 | unifdef-y += kernel.h |
255 | unifdef-y += keyboard.h | 255 | unifdef-y += keyboard.h |
256 | unifdef-$(CONFIG_HAVE_KVM) += kvm.h | 256 | unifdef-y += kvm.h |
257 | unifdef-y += llc.h | 257 | unifdef-y += llc.h |
258 | unifdef-y += loop.h | 258 | unifdef-y += loop.h |
259 | unifdef-y += lp.h | 259 | unifdef-y += lp.h |
diff --git a/include/linux/input.h b/include/linux/input.h index 1bdc39a8c76c..cae2c35d1206 100644 --- a/include/linux/input.h +++ b/include/linux/input.h | |||
@@ -1227,12 +1227,13 @@ void input_free_device(struct input_dev *dev); | |||
1227 | 1227 | ||
1228 | static inline struct input_dev *input_get_device(struct input_dev *dev) | 1228 | static inline struct input_dev *input_get_device(struct input_dev *dev) |
1229 | { | 1229 | { |
1230 | return to_input_dev(get_device(&dev->dev)); | 1230 | return dev ? to_input_dev(get_device(&dev->dev)) : NULL; |
1231 | } | 1231 | } |
1232 | 1232 | ||
1233 | static inline void input_put_device(struct input_dev *dev) | 1233 | static inline void input_put_device(struct input_dev *dev) |
1234 | { | 1234 | { |
1235 | put_device(&dev->dev); | 1235 | if (dev) |
1236 | put_device(&dev->dev); | ||
1236 | } | 1237 | } |
1237 | 1238 | ||
1238 | static inline void *input_get_drvdata(struct input_dev *dev) | 1239 | static inline void *input_get_drvdata(struct input_dev *dev) |
diff --git a/include/linux/iocontext.h b/include/linux/iocontext.h index 1b4ccf25b4d2..cac4b364cd40 100644 --- a/include/linux/iocontext.h +++ b/include/linux/iocontext.h | |||
@@ -2,6 +2,7 @@ | |||
2 | #define IOCONTEXT_H | 2 | #define IOCONTEXT_H |
3 | 3 | ||
4 | #include <linux/radix-tree.h> | 4 | #include <linux/radix-tree.h> |
5 | #include <linux/rcupdate.h> | ||
5 | 6 | ||
6 | /* | 7 | /* |
7 | * This is the per-process anticipatory I/O scheduler state. | 8 | * This is the per-process anticipatory I/O scheduler state. |
@@ -54,6 +55,8 @@ struct cfq_io_context { | |||
54 | 55 | ||
55 | void (*dtor)(struct io_context *); /* destructor */ | 56 | void (*dtor)(struct io_context *); /* destructor */ |
56 | void (*exit)(struct io_context *); /* called on task exit */ | 57 | void (*exit)(struct io_context *); /* called on task exit */ |
58 | |||
59 | struct rcu_head rcu_head; | ||
57 | }; | 60 | }; |
58 | 61 | ||
59 | /* | 62 | /* |
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index a2f003239c85..ee81906b5164 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
@@ -383,9 +383,11 @@ static inline void __napi_complete(struct napi_struct *n) | |||
383 | 383 | ||
384 | static inline void napi_complete(struct napi_struct *n) | 384 | static inline void napi_complete(struct napi_struct *n) |
385 | { | 385 | { |
386 | local_irq_disable(); | 386 | unsigned long flags; |
387 | |||
388 | local_irq_save(flags); | ||
387 | __napi_complete(n); | 389 | __napi_complete(n); |
388 | local_irq_enable(); | 390 | local_irq_restore(flags); |
389 | } | 391 | } |
390 | 392 | ||
391 | /** | 393 | /** |
@@ -1072,12 +1074,14 @@ static inline int netif_is_multiqueue(const struct net_device *dev) | |||
1072 | } | 1074 | } |
1073 | 1075 | ||
1074 | /* Use this variant when it is known for sure that it | 1076 | /* Use this variant when it is known for sure that it |
1075 | * is executing from interrupt context. | 1077 | * is executing from hardware interrupt context or with hardware interrupts |
1078 | * disabled. | ||
1076 | */ | 1079 | */ |
1077 | extern void dev_kfree_skb_irq(struct sk_buff *skb); | 1080 | extern void dev_kfree_skb_irq(struct sk_buff *skb); |
1078 | 1081 | ||
1079 | /* Use this variant in places where it could be invoked | 1082 | /* Use this variant in places where it could be invoked |
1080 | * either from interrupt or non-interrupt context. | 1083 | * from either hardware interrupt or other context, with hardware interrupts |
1084 | * either disabled or enabled. | ||
1081 | */ | 1085 | */ |
1082 | extern void dev_kfree_skb_any(struct sk_buff *skb); | 1086 | extern void dev_kfree_skb_any(struct sk_buff *skb); |
1083 | 1087 | ||
diff --git a/include/net/llc.h b/include/net/llc.h index f5024583fc8b..7940da1606e7 100644 --- a/include/net/llc.h +++ b/include/net/llc.h | |||
@@ -65,7 +65,6 @@ struct llc_sap { | |||
65 | 65 | ||
66 | extern struct list_head llc_sap_list; | 66 | extern struct list_head llc_sap_list; |
67 | extern rwlock_t llc_sap_list_lock; | 67 | extern rwlock_t llc_sap_list_lock; |
68 | extern unsigned char llc_station_mac_sa[ETH_ALEN]; | ||
69 | 68 | ||
70 | extern int llc_rcv(struct sk_buff *skb, struct net_device *dev, | 69 | extern int llc_rcv(struct sk_buff *skb, struct net_device *dev, |
71 | struct packet_type *pt, struct net_device *orig_dev); | 70 | struct packet_type *pt, struct net_device *orig_dev); |
diff --git a/include/net/llc_pdu.h b/include/net/llc_pdu.h index 4a8f58b17e43..75b8e2968c9b 100644 --- a/include/net/llc_pdu.h +++ b/include/net/llc_pdu.h | |||
@@ -381,7 +381,7 @@ static inline void llc_pdu_init_as_xid_cmd(struct sk_buff *skb, | |||
381 | xid_info->fmt_id = LLC_XID_FMT_ID; /* 0x81 */ | 381 | xid_info->fmt_id = LLC_XID_FMT_ID; /* 0x81 */ |
382 | xid_info->type = svcs_supported; | 382 | xid_info->type = svcs_supported; |
383 | xid_info->rw = rx_window << 1; /* size of receive window */ | 383 | xid_info->rw = rx_window << 1; /* size of receive window */ |
384 | skb_put(skb, 3); | 384 | skb_put(skb, sizeof(struct llc_xid_info)); |
385 | } | 385 | } |
386 | 386 | ||
387 | /** | 387 | /** |
@@ -406,7 +406,7 @@ static inline void llc_pdu_init_as_xid_rsp(struct sk_buff *skb, | |||
406 | xid_info->fmt_id = LLC_XID_FMT_ID; | 406 | xid_info->fmt_id = LLC_XID_FMT_ID; |
407 | xid_info->type = svcs_supported; | 407 | xid_info->type = svcs_supported; |
408 | xid_info->rw = rx_window << 1; | 408 | xid_info->rw = rx_window << 1; |
409 | skb_put(skb, 3); | 409 | skb_put(skb, sizeof(struct llc_xid_info)); |
410 | } | 410 | } |
411 | 411 | ||
412 | /* LLC Type 2 FRMR response information field format */ | 412 | /* LLC Type 2 FRMR response information field format */ |
diff --git a/include/net/llc_sap.h b/include/net/llc_sap.h index 2c56dbece729..ed25bec2f648 100644 --- a/include/net/llc_sap.h +++ b/include/net/llc_sap.h | |||
@@ -1,5 +1,8 @@ | |||
1 | #ifndef LLC_SAP_H | 1 | #ifndef LLC_SAP_H |
2 | #define LLC_SAP_H | 2 | #define LLC_SAP_H |
3 | |||
4 | #include <asm/types.h> | ||
5 | |||
3 | /* | 6 | /* |
4 | * Copyright (c) 1997 by Procom Technology,Inc. | 7 | * Copyright (c) 1997 by Procom Technology,Inc. |
5 | * 2001-2003 by Arnaldo Carvalho de Melo <acme@conectiva.com.br> | 8 | * 2001-2003 by Arnaldo Carvalho de Melo <acme@conectiva.com.br> |
@@ -19,8 +22,8 @@ struct sock; | |||
19 | extern void llc_sap_rtn_pdu(struct llc_sap *sap, struct sk_buff *skb); | 22 | extern void llc_sap_rtn_pdu(struct llc_sap *sap, struct sk_buff *skb); |
20 | extern void llc_save_primitive(struct sock *sk, struct sk_buff* skb, | 23 | extern void llc_save_primitive(struct sock *sk, struct sk_buff* skb, |
21 | unsigned char prim); | 24 | unsigned char prim); |
22 | extern struct sk_buff *llc_alloc_frame(struct sock *sk, | 25 | extern struct sk_buff *llc_alloc_frame(struct sock *sk, struct net_device *dev, |
23 | struct net_device *dev); | 26 | u8 type, u32 data_size); |
24 | 27 | ||
25 | extern void llc_build_and_send_test_pkt(struct llc_sap *sap, | 28 | extern void llc_build_and_send_test_pkt(struct llc_sap *sap, |
26 | struct sk_buff *skb, | 29 | struct sk_buff *skb, |
diff --git a/kernel/marker.c b/kernel/marker.c index 041c33e3e95c..005b95954593 100644 --- a/kernel/marker.c +++ b/kernel/marker.c | |||
@@ -671,6 +671,9 @@ int marker_probe_register(const char *name, const char *format, | |||
671 | entry->rcu_pending = 1; | 671 | entry->rcu_pending = 1; |
672 | /* write rcu_pending before calling the RCU callback */ | 672 | /* write rcu_pending before calling the RCU callback */ |
673 | smp_wmb(); | 673 | smp_wmb(); |
674 | #ifdef CONFIG_PREEMPT_RCU | ||
675 | synchronize_sched(); /* Until we have the call_rcu_sched() */ | ||
676 | #endif | ||
674 | call_rcu(&entry->rcu, free_old_closure); | 677 | call_rcu(&entry->rcu, free_old_closure); |
675 | end: | 678 | end: |
676 | mutex_unlock(&markers_mutex); | 679 | mutex_unlock(&markers_mutex); |
@@ -714,6 +717,9 @@ int marker_probe_unregister(const char *name, | |||
714 | entry->rcu_pending = 1; | 717 | entry->rcu_pending = 1; |
715 | /* write rcu_pending before calling the RCU callback */ | 718 | /* write rcu_pending before calling the RCU callback */ |
716 | smp_wmb(); | 719 | smp_wmb(); |
720 | #ifdef CONFIG_PREEMPT_RCU | ||
721 | synchronize_sched(); /* Until we have the call_rcu_sched() */ | ||
722 | #endif | ||
717 | call_rcu(&entry->rcu, free_old_closure); | 723 | call_rcu(&entry->rcu, free_old_closure); |
718 | remove_marker(name); /* Ignore busy error message */ | 724 | remove_marker(name); /* Ignore busy error message */ |
719 | ret = 0; | 725 | ret = 0; |
@@ -792,6 +798,9 @@ int marker_probe_unregister_private_data(marker_probe_func *probe, | |||
792 | entry->rcu_pending = 1; | 798 | entry->rcu_pending = 1; |
793 | /* write rcu_pending before calling the RCU callback */ | 799 | /* write rcu_pending before calling the RCU callback */ |
794 | smp_wmb(); | 800 | smp_wmb(); |
801 | #ifdef CONFIG_PREEMPT_RCU | ||
802 | synchronize_sched(); /* Until we have the call_rcu_sched() */ | ||
803 | #endif | ||
795 | call_rcu(&entry->rcu, free_old_closure); | 804 | call_rcu(&entry->rcu, free_old_closure); |
796 | remove_marker(entry->name); /* Ignore busy error message */ | 805 | remove_marker(entry->name); /* Ignore busy error message */ |
797 | end: | 806 | end: |
@@ -2688,7 +2688,7 @@ void kfree(const void *x) | |||
2688 | } | 2688 | } |
2689 | EXPORT_SYMBOL(kfree); | 2689 | EXPORT_SYMBOL(kfree); |
2690 | 2690 | ||
2691 | #if defined(SLUB_DEBUG) || defined(CONFIG_SLABINFO) | 2691 | #if defined(CONFIG_SLUB_DEBUG) || defined(CONFIG_SLABINFO) |
2692 | static unsigned long count_partial(struct kmem_cache_node *n) | 2692 | static unsigned long count_partial(struct kmem_cache_node *n) |
2693 | { | 2693 | { |
2694 | unsigned long flags; | 2694 | unsigned long flags; |
diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c index dbc81b965096..b33410abfd6b 100644 --- a/net/8021q/vlan.c +++ b/net/8021q/vlan.c | |||
@@ -374,17 +374,35 @@ static void vlan_sync_address(struct net_device *dev, | |||
374 | memcpy(vlan->real_dev_addr, dev->dev_addr, ETH_ALEN); | 374 | memcpy(vlan->real_dev_addr, dev->dev_addr, ETH_ALEN); |
375 | } | 375 | } |
376 | 376 | ||
377 | static void __vlan_device_event(struct net_device *dev, unsigned long event) | ||
378 | { | ||
379 | switch (event) { | ||
380 | case NETDEV_CHANGENAME: | ||
381 | vlan_proc_rem_dev(dev); | ||
382 | if (vlan_proc_add_dev(dev) < 0) | ||
383 | pr_warning("8021q: failed to change proc name for %s\n", | ||
384 | dev->name); | ||
385 | break; | ||
386 | } | ||
387 | } | ||
388 | |||
377 | static int vlan_device_event(struct notifier_block *unused, unsigned long event, | 389 | static int vlan_device_event(struct notifier_block *unused, unsigned long event, |
378 | void *ptr) | 390 | void *ptr) |
379 | { | 391 | { |
380 | struct net_device *dev = ptr; | 392 | struct net_device *dev = ptr; |
381 | struct vlan_group *grp = __vlan_find_group(dev->ifindex); | 393 | struct vlan_group *grp; |
382 | int i, flgs; | 394 | int i, flgs; |
383 | struct net_device *vlandev; | 395 | struct net_device *vlandev; |
384 | 396 | ||
385 | if (dev->nd_net != &init_net) | 397 | if (dev->nd_net != &init_net) |
386 | return NOTIFY_DONE; | 398 | return NOTIFY_DONE; |
387 | 399 | ||
400 | if (is_vlan_dev(dev)) { | ||
401 | __vlan_device_event(dev, event); | ||
402 | goto out; | ||
403 | } | ||
404 | |||
405 | grp = __vlan_find_group(dev->ifindex); | ||
388 | if (!grp) | 406 | if (!grp) |
389 | goto out; | 407 | goto out; |
390 | 408 | ||
diff --git a/net/8021q/vlan.h b/net/8021q/vlan.h index 73efcc715ccb..51271aea402b 100644 --- a/net/8021q/vlan.h +++ b/net/8021q/vlan.h | |||
@@ -45,4 +45,9 @@ void vlan_netlink_fini(void); | |||
45 | 45 | ||
46 | extern struct rtnl_link_ops vlan_link_ops; | 46 | extern struct rtnl_link_ops vlan_link_ops; |
47 | 47 | ||
48 | static inline int is_vlan_dev(struct net_device *dev) | ||
49 | { | ||
50 | return dev->priv_flags & IFF_802_1Q_VLAN; | ||
51 | } | ||
52 | |||
48 | #endif /* !(__BEN_VLAN_802_1Q_INC__) */ | 53 | #endif /* !(__BEN_VLAN_802_1Q_INC__) */ |
diff --git a/net/8021q/vlanproc.c b/net/8021q/vlanproc.c index 146cfb0e9882..9671aa51af2c 100644 --- a/net/8021q/vlanproc.c +++ b/net/8021q/vlanproc.c | |||
@@ -210,11 +210,6 @@ int vlan_proc_rem_dev(struct net_device *vlandev) | |||
210 | * The following few functions build the content of /proc/net/vlan/config | 210 | * The following few functions build the content of /proc/net/vlan/config |
211 | */ | 211 | */ |
212 | 212 | ||
213 | static inline int is_vlan_dev(struct net_device *dev) | ||
214 | { | ||
215 | return dev->priv_flags & IFF_802_1Q_VLAN; | ||
216 | } | ||
217 | |||
218 | /* start read of /proc/net/vlan/config */ | 213 | /* start read of /proc/net/vlan/config */ |
219 | static void *vlan_seq_start(struct seq_file *seq, loff_t *pos) | 214 | static void *vlan_seq_start(struct seq_file *seq, loff_t *pos) |
220 | __acquires(dev_base_lock) | 215 | __acquires(dev_base_lock) |
diff --git a/net/bluetooth/af_bluetooth.c b/net/bluetooth/af_bluetooth.c index 1220d8a41eb5..d366423c8392 100644 --- a/net/bluetooth/af_bluetooth.c +++ b/net/bluetooth/af_bluetooth.c | |||
@@ -53,6 +53,30 @@ | |||
53 | /* Bluetooth sockets */ | 53 | /* Bluetooth sockets */ |
54 | #define BT_MAX_PROTO 8 | 54 | #define BT_MAX_PROTO 8 |
55 | static struct net_proto_family *bt_proto[BT_MAX_PROTO]; | 55 | static struct net_proto_family *bt_proto[BT_MAX_PROTO]; |
56 | |||
57 | static struct lock_class_key bt_slock_key[BT_MAX_PROTO]; | ||
58 | static struct lock_class_key bt_lock_key[BT_MAX_PROTO]; | ||
59 | static const char *bt_key_strings[BT_MAX_PROTO] = { | ||
60 | "sk_lock-AF_BLUETOOTH-BTPROTO_L2CAP", | ||
61 | "sk_lock-AF_BLUETOOTH-BTPROTO_HCI", | ||
62 | "sk_lock-AF_BLUETOOTH-BTPROTO_SCO", | ||
63 | "sk_lock-AF_BLUETOOTH-BTPROTO_RFCOMM", | ||
64 | "sk_lock-AF_BLUETOOTH-BTPROTO_BNEP", | ||
65 | "sk_lock-AF_BLUETOOTH-BTPROTO_CMTP", | ||
66 | "sk_lock-AF_BLUETOOTH-BTPROTO_HIDP", | ||
67 | "sk_lock-AF_BLUETOOTH-BTPROTO_AVDTP", | ||
68 | }; | ||
69 | |||
70 | static const char *bt_slock_key_strings[BT_MAX_PROTO] = { | ||
71 | "slock-AF_BLUETOOTH-BTPROTO_L2CAP", | ||
72 | "slock-AF_BLUETOOTH-BTPROTO_HCI", | ||
73 | "slock-AF_BLUETOOTH-BTPROTO_SCO", | ||
74 | "slock-AF_BLUETOOTH-BTPROTO_RFCOMM", | ||
75 | "slock-AF_BLUETOOTH-BTPROTO_BNEP", | ||
76 | "slock-AF_BLUETOOTH-BTPROTO_CMTP", | ||
77 | "slock-AF_BLUETOOTH-BTPROTO_HIDP", | ||
78 | "slock-AF_BLUETOOTH-BTPROTO_AVDTP", | ||
79 | }; | ||
56 | static DEFINE_RWLOCK(bt_proto_lock); | 80 | static DEFINE_RWLOCK(bt_proto_lock); |
57 | 81 | ||
58 | int bt_sock_register(int proto, struct net_proto_family *ops) | 82 | int bt_sock_register(int proto, struct net_proto_family *ops) |
@@ -95,6 +119,21 @@ int bt_sock_unregister(int proto) | |||
95 | } | 119 | } |
96 | EXPORT_SYMBOL(bt_sock_unregister); | 120 | EXPORT_SYMBOL(bt_sock_unregister); |
97 | 121 | ||
122 | static void bt_reclassify_sock_lock(struct socket *sock, int proto) | ||
123 | { | ||
124 | struct sock *sk = sock->sk; | ||
125 | |||
126 | if (!sk) | ||
127 | return; | ||
128 | BUG_ON(sock_owned_by_user(sk)); | ||
129 | |||
130 | sock_lock_init_class_and_name(sk, | ||
131 | bt_slock_key_strings[proto], | ||
132 | &bt_slock_key[proto], | ||
133 | bt_key_strings[proto], | ||
134 | &bt_lock_key[proto]); | ||
135 | } | ||
136 | |||
98 | static int bt_sock_create(struct net *net, struct socket *sock, int proto) | 137 | static int bt_sock_create(struct net *net, struct socket *sock, int proto) |
99 | { | 138 | { |
100 | int err; | 139 | int err; |
@@ -117,6 +156,7 @@ static int bt_sock_create(struct net *net, struct socket *sock, int proto) | |||
117 | 156 | ||
118 | if (bt_proto[proto] && try_module_get(bt_proto[proto]->owner)) { | 157 | if (bt_proto[proto] && try_module_get(bt_proto[proto]->owner)) { |
119 | err = bt_proto[proto]->create(net, sock, proto); | 158 | err = bt_proto[proto]->create(net, sock, proto); |
159 | bt_reclassify_sock_lock(sock, proto); | ||
120 | module_put(bt_proto[proto]->owner); | 160 | module_put(bt_proto[proto]->owner); |
121 | } | 161 | } |
122 | 162 | ||
diff --git a/net/bluetooth/hci_sock.c b/net/bluetooth/hci_sock.c index b5d4019d3572..1d36c093523b 100644 --- a/net/bluetooth/hci_sock.c +++ b/net/bluetooth/hci_sock.c | |||
@@ -84,7 +84,7 @@ static struct hci_sec_filter hci_sec_filter = { | |||
84 | }; | 84 | }; |
85 | 85 | ||
86 | static struct bt_sock_list hci_sk_list = { | 86 | static struct bt_sock_list hci_sk_list = { |
87 | .lock = RW_LOCK_UNLOCKED | 87 | .lock = __RW_LOCK_UNLOCKED(hci_sk_list.lock) |
88 | }; | 88 | }; |
89 | 89 | ||
90 | /* Send frame to RAW socket */ | 90 | /* Send frame to RAW socket */ |
diff --git a/net/bluetooth/l2cap.c b/net/bluetooth/l2cap.c index 34f8bf98bc05..2957df4b6c0b 100644 --- a/net/bluetooth/l2cap.c +++ b/net/bluetooth/l2cap.c | |||
@@ -62,7 +62,7 @@ static u32 l2cap_feat_mask = 0x0000; | |||
62 | static const struct proto_ops l2cap_sock_ops; | 62 | static const struct proto_ops l2cap_sock_ops; |
63 | 63 | ||
64 | static struct bt_sock_list l2cap_sk_list = { | 64 | static struct bt_sock_list l2cap_sk_list = { |
65 | .lock = RW_LOCK_UNLOCKED | 65 | .lock = __RW_LOCK_UNLOCKED(l2cap_sk_list.lock) |
66 | }; | 66 | }; |
67 | 67 | ||
68 | static void __l2cap_sock_close(struct sock *sk, int reason); | 68 | static void __l2cap_sock_close(struct sock *sk, int reason); |
diff --git a/net/bluetooth/rfcomm/core.c b/net/bluetooth/rfcomm/core.c index 0c2c93735e93..eb62558e9b09 100644 --- a/net/bluetooth/rfcomm/core.c +++ b/net/bluetooth/rfcomm/core.c | |||
@@ -423,8 +423,8 @@ static int __rfcomm_dlc_close(struct rfcomm_dlc *d, int err) | |||
423 | 423 | ||
424 | rfcomm_dlc_lock(d); | 424 | rfcomm_dlc_lock(d); |
425 | d->state = BT_CLOSED; | 425 | d->state = BT_CLOSED; |
426 | d->state_change(d, err); | ||
427 | rfcomm_dlc_unlock(d); | 426 | rfcomm_dlc_unlock(d); |
427 | d->state_change(d, err); | ||
428 | 428 | ||
429 | skb_queue_purge(&d->tx_queue); | 429 | skb_queue_purge(&d->tx_queue); |
430 | rfcomm_dlc_unlink(d); | 430 | rfcomm_dlc_unlink(d); |
diff --git a/net/bluetooth/rfcomm/sock.c b/net/bluetooth/rfcomm/sock.c index c46d51035e77..af4e3934ee84 100644 --- a/net/bluetooth/rfcomm/sock.c +++ b/net/bluetooth/rfcomm/sock.c | |||
@@ -60,7 +60,7 @@ | |||
60 | static const struct proto_ops rfcomm_sock_ops; | 60 | static const struct proto_ops rfcomm_sock_ops; |
61 | 61 | ||
62 | static struct bt_sock_list rfcomm_sk_list = { | 62 | static struct bt_sock_list rfcomm_sk_list = { |
63 | .lock = RW_LOCK_UNLOCKED | 63 | .lock = __RW_LOCK_UNLOCKED(rfcomm_sk_list.lock) |
64 | }; | 64 | }; |
65 | 65 | ||
66 | static void rfcomm_sock_close(struct sock *sk); | 66 | static void rfcomm_sock_close(struct sock *sk); |
diff --git a/net/bluetooth/rfcomm/tty.c b/net/bluetooth/rfcomm/tty.c index e4c779bb8d76..c3f749abb2d0 100644 --- a/net/bluetooth/rfcomm/tty.c +++ b/net/bluetooth/rfcomm/tty.c | |||
@@ -570,12 +570,7 @@ static void rfcomm_dev_state_change(struct rfcomm_dlc *dlc, int err) | |||
570 | return; | 570 | return; |
571 | 571 | ||
572 | rfcomm_dev_del(dev); | 572 | rfcomm_dev_del(dev); |
573 | /* We have to drop DLC lock here, otherwise | ||
574 | rfcomm_dev_put() will dead lock if it's | ||
575 | the last reference. */ | ||
576 | rfcomm_dlc_unlock(dlc); | ||
577 | rfcomm_dev_put(dev); | 573 | rfcomm_dev_put(dev); |
578 | rfcomm_dlc_lock(dlc); | ||
579 | } | 574 | } |
580 | } else | 575 | } else |
581 | tty_hangup(dev->tty); | 576 | tty_hangup(dev->tty); |
diff --git a/net/bluetooth/sco.c b/net/bluetooth/sco.c index b91d3c81a73c..cd887cdca426 100644 --- a/net/bluetooth/sco.c +++ b/net/bluetooth/sco.c | |||
@@ -58,7 +58,7 @@ | |||
58 | static const struct proto_ops sco_sock_ops; | 58 | static const struct proto_ops sco_sock_ops; |
59 | 59 | ||
60 | static struct bt_sock_list sco_sk_list = { | 60 | static struct bt_sock_list sco_sk_list = { |
61 | .lock = RW_LOCK_UNLOCKED | 61 | .lock = __RW_LOCK_UNLOCKED(sco_sk_list.lock) |
62 | }; | 62 | }; |
63 | 63 | ||
64 | static void __sco_chan_add(struct sco_conn *conn, struct sock *sk, struct sock *parent); | 64 | static void __sco_chan_add(struct sco_conn *conn, struct sock *sk, struct sock *parent); |
diff --git a/net/ipv4/esp4.c b/net/ipv4/esp4.c index f3ceca31aa45..4e73e5708e70 100644 --- a/net/ipv4/esp4.c +++ b/net/ipv4/esp4.c | |||
@@ -336,7 +336,7 @@ static int esp_input(struct xfrm_state *x, struct sk_buff *skb) | |||
336 | struct scatterlist *asg; | 336 | struct scatterlist *asg; |
337 | int err = -EINVAL; | 337 | int err = -EINVAL; |
338 | 338 | ||
339 | if (!pskb_may_pull(skb, sizeof(*esph))) | 339 | if (!pskb_may_pull(skb, sizeof(*esph) + crypto_aead_ivsize(aead))) |
340 | goto out; | 340 | goto out; |
341 | 341 | ||
342 | if (elen <= 0) | 342 | if (elen <= 0) |
diff --git a/net/ipv4/inet_fragment.c b/net/ipv4/inet_fragment.c index 724d69aed031..a0a3c78cb5e0 100644 --- a/net/ipv4/inet_fragment.c +++ b/net/ipv4/inet_fragment.c | |||
@@ -86,7 +86,10 @@ EXPORT_SYMBOL(inet_frags_fini); | |||
86 | void inet_frags_exit_net(struct netns_frags *nf, struct inet_frags *f) | 86 | void inet_frags_exit_net(struct netns_frags *nf, struct inet_frags *f) |
87 | { | 87 | { |
88 | nf->low_thresh = 0; | 88 | nf->low_thresh = 0; |
89 | |||
90 | local_bh_disable(); | ||
89 | inet_frag_evictor(nf, f); | 91 | inet_frag_evictor(nf, f); |
92 | local_bh_enable(); | ||
90 | } | 93 | } |
91 | EXPORT_SYMBOL(inet_frags_exit_net); | 94 | EXPORT_SYMBOL(inet_frags_exit_net); |
92 | 95 | ||
diff --git a/net/ipv4/ip_forward.c b/net/ipv4/ip_forward.c index 0b3b328d82db..a4506c8cfef0 100644 --- a/net/ipv4/ip_forward.c +++ b/net/ipv4/ip_forward.c | |||
@@ -85,7 +85,7 @@ int ip_forward(struct sk_buff *skb) | |||
85 | if (opt->is_strictroute && rt->rt_dst != rt->rt_gateway) | 85 | if (opt->is_strictroute && rt->rt_dst != rt->rt_gateway) |
86 | goto sr_failed; | 86 | goto sr_failed; |
87 | 87 | ||
88 | if (unlikely(skb->len > dst_mtu(&rt->u.dst) && | 88 | if (unlikely(skb->len > dst_mtu(&rt->u.dst) && !skb_is_gso(skb) && |
89 | (ip_hdr(skb)->frag_off & htons(IP_DF))) && !skb->local_df) { | 89 | (ip_hdr(skb)->frag_off & htons(IP_DF))) && !skb->local_df) { |
90 | IP_INC_STATS(IPSTATS_MIB_FRAGFAILS); | 90 | IP_INC_STATS(IPSTATS_MIB_FRAGFAILS); |
91 | icmp_send(skb, ICMP_DEST_UNREACH, ICMP_FRAG_NEEDED, | 91 | icmp_send(skb, ICMP_DEST_UNREACH, ICMP_FRAG_NEEDED, |
diff --git a/net/ipv4/netfilter/ip_queue.c b/net/ipv4/netfilter/ip_queue.c index fe05da41d6ba..4dc162894cb2 100644 --- a/net/ipv4/netfilter/ip_queue.c +++ b/net/ipv4/netfilter/ip_queue.c | |||
@@ -588,11 +588,9 @@ static int __init ip_queue_init(void) | |||
588 | } | 588 | } |
589 | 589 | ||
590 | #ifdef CONFIG_PROC_FS | 590 | #ifdef CONFIG_PROC_FS |
591 | proc = create_proc_entry(IPQ_PROC_FS_NAME, 0, init_net.proc_net); | 591 | proc = proc_create(IPQ_PROC_FS_NAME, 0, init_net.proc_net, |
592 | if (proc) { | 592 | &ip_queue_proc_fops); |
593 | proc->owner = THIS_MODULE; | 593 | if (!proc) { |
594 | proc->proc_fops = &ip_queue_proc_fops; | ||
595 | } else { | ||
596 | printk(KERN_ERR "ip_queue: failed to create proc entry\n"); | 594 | printk(KERN_ERR "ip_queue: failed to create proc entry\n"); |
597 | goto cleanup_ipqnl; | 595 | goto cleanup_ipqnl; |
598 | } | 596 | } |
diff --git a/net/ipv4/netfilter/ipt_CLUSTERIP.c b/net/ipv4/netfilter/ipt_CLUSTERIP.c index c6cf84c77611..52926c8e3cc1 100644 --- a/net/ipv4/netfilter/ipt_CLUSTERIP.c +++ b/net/ipv4/netfilter/ipt_CLUSTERIP.c | |||
@@ -167,14 +167,13 @@ clusterip_config_init(struct ipt_clusterip_tgt_info *i, __be32 ip, | |||
167 | 167 | ||
168 | /* create proc dir entry */ | 168 | /* create proc dir entry */ |
169 | sprintf(buffer, "%u.%u.%u.%u", NIPQUAD(ip)); | 169 | sprintf(buffer, "%u.%u.%u.%u", NIPQUAD(ip)); |
170 | c->pde = create_proc_entry(buffer, S_IWUSR|S_IRUSR, | 170 | c->pde = proc_create(buffer, S_IWUSR|S_IRUSR, |
171 | clusterip_procdir); | 171 | clusterip_procdir, &clusterip_proc_fops); |
172 | if (!c->pde) { | 172 | if (!c->pde) { |
173 | kfree(c); | 173 | kfree(c); |
174 | return NULL; | 174 | return NULL; |
175 | } | 175 | } |
176 | } | 176 | } |
177 | c->pde->proc_fops = &clusterip_proc_fops; | ||
178 | c->pde->data = c; | 177 | c->pde->data = c; |
179 | #endif | 178 | #endif |
180 | 179 | ||
diff --git a/net/ipv4/netfilter/ipt_recent.c b/net/ipv4/netfilter/ipt_recent.c index 8e8f0425a8ed..50e06690eb5b 100644 --- a/net/ipv4/netfilter/ipt_recent.c +++ b/net/ipv4/netfilter/ipt_recent.c | |||
@@ -276,12 +276,11 @@ recent_mt_check(const char *tablename, const void *ip, | |||
276 | for (i = 0; i < ip_list_hash_size; i++) | 276 | for (i = 0; i < ip_list_hash_size; i++) |
277 | INIT_LIST_HEAD(&t->iphash[i]); | 277 | INIT_LIST_HEAD(&t->iphash[i]); |
278 | #ifdef CONFIG_PROC_FS | 278 | #ifdef CONFIG_PROC_FS |
279 | t->proc = create_proc_entry(t->name, ip_list_perms, proc_dir); | 279 | t->proc = proc_create(t->name, ip_list_perms, proc_dir, &recent_fops); |
280 | if (t->proc == NULL) { | 280 | if (t->proc == NULL) { |
281 | kfree(t); | 281 | kfree(t); |
282 | goto out; | 282 | goto out; |
283 | } | 283 | } |
284 | t->proc->proc_fops = &recent_fops; | ||
285 | t->proc->uid = ip_list_uid; | 284 | t->proc->uid = ip_list_uid; |
286 | t->proc->gid = ip_list_gid; | 285 | t->proc->gid = ip_list_gid; |
287 | t->proc->data = t; | 286 | t->proc->data = t; |
diff --git a/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4_compat.c b/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4_compat.c index 089252e82c01..f500b0fdaef4 100644 --- a/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4_compat.c +++ b/net/ipv4/netfilter/nf_conntrack_l3proto_ipv4_compat.c | |||
@@ -395,13 +395,10 @@ int __init nf_conntrack_ipv4_compat_init(void) | |||
395 | if (!proc_exp) | 395 | if (!proc_exp) |
396 | goto err2; | 396 | goto err2; |
397 | 397 | ||
398 | proc_stat = create_proc_entry("ip_conntrack", S_IRUGO, init_net.proc_net_stat); | 398 | proc_stat = proc_create("ip_conntrack", S_IRUGO, |
399 | init_net.proc_net_stat, &ct_cpu_seq_fops); | ||
399 | if (!proc_stat) | 400 | if (!proc_stat) |
400 | goto err3; | 401 | goto err3; |
401 | |||
402 | proc_stat->proc_fops = &ct_cpu_seq_fops; | ||
403 | proc_stat->owner = THIS_MODULE; | ||
404 | |||
405 | return 0; | 402 | return 0; |
406 | 403 | ||
407 | err3: | 404 | err3: |
diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c index 7ea1b67b6de1..1704c1474ea1 100644 --- a/net/ipv4/udp.c +++ b/net/ipv4/udp.c | |||
@@ -1556,14 +1556,14 @@ static void *udp_seq_start(struct seq_file *seq, loff_t *pos) | |||
1556 | __acquires(udp_hash_lock) | 1556 | __acquires(udp_hash_lock) |
1557 | { | 1557 | { |
1558 | read_lock(&udp_hash_lock); | 1558 | read_lock(&udp_hash_lock); |
1559 | return *pos ? udp_get_idx(seq, *pos-1) : (void *)1; | 1559 | return *pos ? udp_get_idx(seq, *pos-1) : SEQ_START_TOKEN; |
1560 | } | 1560 | } |
1561 | 1561 | ||
1562 | static void *udp_seq_next(struct seq_file *seq, void *v, loff_t *pos) | 1562 | static void *udp_seq_next(struct seq_file *seq, void *v, loff_t *pos) |
1563 | { | 1563 | { |
1564 | struct sock *sk; | 1564 | struct sock *sk; |
1565 | 1565 | ||
1566 | if (v == (void *)1) | 1566 | if (v == SEQ_START_TOKEN) |
1567 | sk = udp_get_idx(seq, 0); | 1567 | sk = udp_get_idx(seq, 0); |
1568 | else | 1568 | else |
1569 | sk = udp_get_next(seq, v); | 1569 | sk = udp_get_next(seq, v); |
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index 101e0e70ba27..e7a1882db048 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c | |||
@@ -776,6 +776,7 @@ static int ipv6_create_tempaddr(struct inet6_ifaddr *ifp, struct inet6_ifaddr *i | |||
776 | struct inet6_dev *idev = ifp->idev; | 776 | struct inet6_dev *idev = ifp->idev; |
777 | struct in6_addr addr, *tmpaddr; | 777 | struct in6_addr addr, *tmpaddr; |
778 | unsigned long tmp_prefered_lft, tmp_valid_lft, tmp_cstamp, tmp_tstamp; | 778 | unsigned long tmp_prefered_lft, tmp_valid_lft, tmp_cstamp, tmp_tstamp; |
779 | unsigned long regen_advance; | ||
779 | int tmp_plen; | 780 | int tmp_plen; |
780 | int ret = 0; | 781 | int ret = 0; |
781 | int max_addresses; | 782 | int max_addresses; |
@@ -836,8 +837,23 @@ retry: | |||
836 | tmp_tstamp = ifp->tstamp; | 837 | tmp_tstamp = ifp->tstamp; |
837 | spin_unlock_bh(&ifp->lock); | 838 | spin_unlock_bh(&ifp->lock); |
838 | 839 | ||
840 | regen_advance = idev->cnf.regen_max_retry * | ||
841 | idev->cnf.dad_transmits * | ||
842 | idev->nd_parms->retrans_time / HZ; | ||
839 | write_unlock(&idev->lock); | 843 | write_unlock(&idev->lock); |
840 | 844 | ||
845 | /* A temporary address is created only if this calculated Preferred | ||
846 | * Lifetime is greater than REGEN_ADVANCE time units. In particular, | ||
847 | * an implementation must not create a temporary address with a zero | ||
848 | * Preferred Lifetime. | ||
849 | */ | ||
850 | if (tmp_prefered_lft <= regen_advance) { | ||
851 | in6_ifa_put(ifp); | ||
852 | in6_dev_put(idev); | ||
853 | ret = -1; | ||
854 | goto out; | ||
855 | } | ||
856 | |||
841 | addr_flags = IFA_F_TEMPORARY; | 857 | addr_flags = IFA_F_TEMPORARY; |
842 | /* set in addrconf_prefix_rcv() */ | 858 | /* set in addrconf_prefix_rcv() */ |
843 | if (ifp->flags & IFA_F_OPTIMISTIC) | 859 | if (ifp->flags & IFA_F_OPTIMISTIC) |
@@ -1831,6 +1847,9 @@ ok: | |||
1831 | * lifetimes of an existing temporary address | 1847 | * lifetimes of an existing temporary address |
1832 | * when processing a Prefix Information Option. | 1848 | * when processing a Prefix Information Option. |
1833 | */ | 1849 | */ |
1850 | if (ifp != ift->ifpub) | ||
1851 | continue; | ||
1852 | |||
1834 | spin_lock(&ift->lock); | 1853 | spin_lock(&ift->lock); |
1835 | flags = ift->flags; | 1854 | flags = ift->flags; |
1836 | if (ift->valid_lft > valid_lft && | 1855 | if (ift->valid_lft > valid_lft && |
diff --git a/net/ipv6/esp6.c b/net/ipv6/esp6.c index 0ec1402320ea..c6bb4c6d24b3 100644 --- a/net/ipv6/esp6.c +++ b/net/ipv6/esp6.c | |||
@@ -282,7 +282,7 @@ static int esp6_input(struct xfrm_state *x, struct sk_buff *skb) | |||
282 | struct scatterlist *sg; | 282 | struct scatterlist *sg; |
283 | struct scatterlist *asg; | 283 | struct scatterlist *asg; |
284 | 284 | ||
285 | if (!pskb_may_pull(skb, sizeof(*esph))) { | 285 | if (!pskb_may_pull(skb, sizeof(*esph) + crypto_aead_ivsize(aead))) { |
286 | ret = -EINVAL; | 286 | ret = -EINVAL; |
287 | goto out; | 287 | goto out; |
288 | } | 288 | } |
diff --git a/net/ipv6/icmp.c b/net/ipv6/icmp.c index 121d517bf91c..f204a7275a0d 100644 --- a/net/ipv6/icmp.c +++ b/net/ipv6/icmp.c | |||
@@ -436,10 +436,10 @@ void icmpv6_send(struct sk_buff *skb, int type, int code, __u32 info, | |||
436 | } | 436 | } |
437 | 437 | ||
438 | if (xfrm_decode_session_reverse(skb, &fl2, AF_INET6)) | 438 | if (xfrm_decode_session_reverse(skb, &fl2, AF_INET6)) |
439 | goto out; | 439 | goto out_dst_release; |
440 | 440 | ||
441 | if (ip6_dst_lookup(sk, &dst2, &fl)) | 441 | if (ip6_dst_lookup(sk, &dst2, &fl)) |
442 | goto out; | 442 | goto out_dst_release; |
443 | 443 | ||
444 | err = xfrm_lookup(&dst2, &fl, sk, XFRM_LOOKUP_ICMP); | 444 | err = xfrm_lookup(&dst2, &fl, sk, XFRM_LOOKUP_ICMP); |
445 | if (err == -ENOENT) { | 445 | if (err == -ENOENT) { |
diff --git a/net/ipv6/ip6_input.c b/net/ipv6/ip6_input.c index 178aebc0427a..98ab4f459905 100644 --- a/net/ipv6/ip6_input.c +++ b/net/ipv6/ip6_input.c | |||
@@ -239,8 +239,7 @@ int ip6_mc_input(struct sk_buff *skb) | |||
239 | IP6_INC_STATS_BH(ip6_dst_idev(skb->dst), IPSTATS_MIB_INMCASTPKTS); | 239 | IP6_INC_STATS_BH(ip6_dst_idev(skb->dst), IPSTATS_MIB_INMCASTPKTS); |
240 | 240 | ||
241 | hdr = ipv6_hdr(skb); | 241 | hdr = ipv6_hdr(skb); |
242 | deliver = unlikely(skb->dev->flags & (IFF_PROMISC|IFF_ALLMULTI)) || | 242 | deliver = ipv6_chk_mcast_addr(skb->dev, &hdr->daddr, NULL); |
243 | ipv6_chk_mcast_addr(skb->dev, &hdr->daddr, NULL); | ||
244 | 243 | ||
245 | /* | 244 | /* |
246 | * IPv6 multicast router mode isnt currently supported. | 245 | * IPv6 multicast router mode isnt currently supported. |
diff --git a/net/ipv6/netfilter/ip6_queue.c b/net/ipv6/netfilter/ip6_queue.c index cc2f9afcf808..8d366f7f2a9a 100644 --- a/net/ipv6/netfilter/ip6_queue.c +++ b/net/ipv6/netfilter/ip6_queue.c | |||
@@ -591,11 +591,9 @@ static int __init ip6_queue_init(void) | |||
591 | } | 591 | } |
592 | 592 | ||
593 | #ifdef CONFIG_PROC_FS | 593 | #ifdef CONFIG_PROC_FS |
594 | proc = create_proc_entry(IPQ_PROC_FS_NAME, 0, init_net.proc_net); | 594 | proc = proc_create(IPQ_PROC_FS_NAME, 0, init_net.proc_net, |
595 | if (proc) { | 595 | &ip6_queue_proc_fops); |
596 | proc->owner = THIS_MODULE; | 596 | if (!proc) { |
597 | proc->proc_fops = &ip6_queue_proc_fops; | ||
598 | } else { | ||
599 | printk(KERN_ERR "ip6_queue: failed to create proc entry\n"); | 597 | printk(KERN_ERR "ip6_queue: failed to create proc entry\n"); |
600 | goto cleanup_ipqnl; | 598 | goto cleanup_ipqnl; |
601 | } | 599 | } |
diff --git a/net/ipv6/netfilter/nf_conntrack_reasm.c b/net/ipv6/netfilter/nf_conntrack_reasm.c index 2a0d698b24d5..24c0d03095bf 100644 --- a/net/ipv6/netfilter/nf_conntrack_reasm.c +++ b/net/ipv6/netfilter/nf_conntrack_reasm.c | |||
@@ -171,7 +171,9 @@ static __inline__ void fq_kill(struct nf_ct_frag6_queue *fq) | |||
171 | 171 | ||
172 | static void nf_ct_frag6_evictor(void) | 172 | static void nf_ct_frag6_evictor(void) |
173 | { | 173 | { |
174 | local_bh_disable(); | ||
174 | inet_frag_evictor(&nf_init_frags, &nf_frags); | 175 | inet_frag_evictor(&nf_init_frags, &nf_frags); |
176 | local_bh_enable(); | ||
175 | } | 177 | } |
176 | 178 | ||
177 | static void nf_ct_frag6_expire(unsigned long data) | 179 | static void nf_ct_frag6_expire(unsigned long data) |
diff --git a/net/llc/af_llc.c b/net/llc/af_llc.c index 46cf962f7f88..8c50eb430c19 100644 --- a/net/llc/af_llc.c +++ b/net/llc/af_llc.c | |||
@@ -155,6 +155,9 @@ static int llc_ui_create(struct net *net, struct socket *sock, int protocol) | |||
155 | struct sock *sk; | 155 | struct sock *sk; |
156 | int rc = -ESOCKTNOSUPPORT; | 156 | int rc = -ESOCKTNOSUPPORT; |
157 | 157 | ||
158 | if (!capable(CAP_NET_RAW)) | ||
159 | return -EPERM; | ||
160 | |||
158 | if (net != &init_net) | 161 | if (net != &init_net) |
159 | return -EAFNOSUPPORT; | 162 | return -EAFNOSUPPORT; |
160 | 163 | ||
diff --git a/net/llc/llc_c_ac.c b/net/llc/llc_c_ac.c index 860140caa6e0..71a00225bdb3 100644 --- a/net/llc/llc_c_ac.c +++ b/net/llc/llc_c_ac.c | |||
@@ -198,7 +198,7 @@ int llc_conn_ac_send_disc_cmd_p_set_x(struct sock *sk, struct sk_buff *skb) | |||
198 | { | 198 | { |
199 | int rc = -ENOBUFS; | 199 | int rc = -ENOBUFS; |
200 | struct llc_sock *llc = llc_sk(sk); | 200 | struct llc_sock *llc = llc_sk(sk); |
201 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 201 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_U, 0); |
202 | 202 | ||
203 | if (nskb) { | 203 | if (nskb) { |
204 | struct llc_sap *sap = llc->sap; | 204 | struct llc_sap *sap = llc->sap; |
@@ -223,7 +223,7 @@ int llc_conn_ac_send_dm_rsp_f_set_p(struct sock *sk, struct sk_buff *skb) | |||
223 | { | 223 | { |
224 | int rc = -ENOBUFS; | 224 | int rc = -ENOBUFS; |
225 | struct llc_sock *llc = llc_sk(sk); | 225 | struct llc_sock *llc = llc_sk(sk); |
226 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 226 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_U, 0); |
227 | 227 | ||
228 | if (nskb) { | 228 | if (nskb) { |
229 | struct llc_sap *sap = llc->sap; | 229 | struct llc_sap *sap = llc->sap; |
@@ -249,7 +249,7 @@ int llc_conn_ac_send_dm_rsp_f_set_1(struct sock *sk, struct sk_buff *skb) | |||
249 | { | 249 | { |
250 | int rc = -ENOBUFS; | 250 | int rc = -ENOBUFS; |
251 | struct llc_sock *llc = llc_sk(sk); | 251 | struct llc_sock *llc = llc_sk(sk); |
252 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 252 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_U, 0); |
253 | 253 | ||
254 | if (nskb) { | 254 | if (nskb) { |
255 | struct llc_sap *sap = llc->sap; | 255 | struct llc_sap *sap = llc->sap; |
@@ -282,7 +282,8 @@ int llc_conn_ac_send_frmr_rsp_f_set_x(struct sock *sk, struct sk_buff *skb) | |||
282 | llc_pdu_decode_pf_bit(skb, &f_bit); | 282 | llc_pdu_decode_pf_bit(skb, &f_bit); |
283 | else | 283 | else |
284 | f_bit = 0; | 284 | f_bit = 0; |
285 | nskb = llc_alloc_frame(sk, llc->dev); | 285 | nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_U, |
286 | sizeof(struct llc_frmr_info)); | ||
286 | if (nskb) { | 287 | if (nskb) { |
287 | struct llc_sap *sap = llc->sap; | 288 | struct llc_sap *sap = llc->sap; |
288 | 289 | ||
@@ -306,7 +307,8 @@ int llc_conn_ac_resend_frmr_rsp_f_set_0(struct sock *sk, struct sk_buff *skb) | |||
306 | { | 307 | { |
307 | int rc = -ENOBUFS; | 308 | int rc = -ENOBUFS; |
308 | struct llc_sock *llc = llc_sk(sk); | 309 | struct llc_sock *llc = llc_sk(sk); |
309 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 310 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_U, |
311 | sizeof(struct llc_frmr_info)); | ||
310 | 312 | ||
311 | if (nskb) { | 313 | if (nskb) { |
312 | struct llc_sap *sap = llc->sap; | 314 | struct llc_sap *sap = llc->sap; |
@@ -336,7 +338,8 @@ int llc_conn_ac_resend_frmr_rsp_f_set_p(struct sock *sk, struct sk_buff *skb) | |||
336 | struct llc_sock *llc = llc_sk(sk); | 338 | struct llc_sock *llc = llc_sk(sk); |
337 | 339 | ||
338 | llc_pdu_decode_pf_bit(skb, &f_bit); | 340 | llc_pdu_decode_pf_bit(skb, &f_bit); |
339 | nskb = llc_alloc_frame(sk, llc->dev); | 341 | nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_U, |
342 | sizeof(struct llc_frmr_info)); | ||
340 | if (nskb) { | 343 | if (nskb) { |
341 | struct llc_sap *sap = llc->sap; | 344 | struct llc_sap *sap = llc->sap; |
342 | struct llc_pdu_sn *pdu = llc_pdu_sn_hdr(skb); | 345 | struct llc_pdu_sn *pdu = llc_pdu_sn_hdr(skb); |
@@ -424,7 +427,7 @@ int llc_conn_ac_resend_i_xxx_x_set_0_or_send_rr(struct sock *sk, | |||
424 | struct llc_pdu_sn *pdu = llc_pdu_sn_hdr(skb); | 427 | struct llc_pdu_sn *pdu = llc_pdu_sn_hdr(skb); |
425 | int rc = -ENOBUFS; | 428 | int rc = -ENOBUFS; |
426 | struct llc_sock *llc = llc_sk(sk); | 429 | struct llc_sock *llc = llc_sk(sk); |
427 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 430 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_U, 0); |
428 | 431 | ||
429 | if (nskb) { | 432 | if (nskb) { |
430 | struct llc_sap *sap = llc->sap; | 433 | struct llc_sap *sap = llc->sap; |
@@ -459,7 +462,7 @@ int llc_conn_ac_send_rej_cmd_p_set_1(struct sock *sk, struct sk_buff *skb) | |||
459 | { | 462 | { |
460 | int rc = -ENOBUFS; | 463 | int rc = -ENOBUFS; |
461 | struct llc_sock *llc = llc_sk(sk); | 464 | struct llc_sock *llc = llc_sk(sk); |
462 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 465 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
463 | 466 | ||
464 | if (nskb) { | 467 | if (nskb) { |
465 | struct llc_sap *sap = llc->sap; | 468 | struct llc_sap *sap = llc->sap; |
@@ -483,7 +486,7 @@ int llc_conn_ac_send_rej_rsp_f_set_1(struct sock *sk, struct sk_buff *skb) | |||
483 | { | 486 | { |
484 | int rc = -ENOBUFS; | 487 | int rc = -ENOBUFS; |
485 | struct llc_sock *llc = llc_sk(sk); | 488 | struct llc_sock *llc = llc_sk(sk); |
486 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 489 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
487 | 490 | ||
488 | if (nskb) { | 491 | if (nskb) { |
489 | struct llc_sap *sap = llc->sap; | 492 | struct llc_sap *sap = llc->sap; |
@@ -507,7 +510,7 @@ int llc_conn_ac_send_rej_xxx_x_set_0(struct sock *sk, struct sk_buff *skb) | |||
507 | { | 510 | { |
508 | int rc = -ENOBUFS; | 511 | int rc = -ENOBUFS; |
509 | struct llc_sock *llc = llc_sk(sk); | 512 | struct llc_sock *llc = llc_sk(sk); |
510 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 513 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
511 | 514 | ||
512 | if (nskb) { | 515 | if (nskb) { |
513 | struct llc_sap *sap = llc->sap; | 516 | struct llc_sap *sap = llc->sap; |
@@ -531,7 +534,7 @@ int llc_conn_ac_send_rnr_cmd_p_set_1(struct sock *sk, struct sk_buff *skb) | |||
531 | { | 534 | { |
532 | int rc = -ENOBUFS; | 535 | int rc = -ENOBUFS; |
533 | struct llc_sock *llc = llc_sk(sk); | 536 | struct llc_sock *llc = llc_sk(sk); |
534 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 537 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
535 | 538 | ||
536 | if (nskb) { | 539 | if (nskb) { |
537 | struct llc_sap *sap = llc->sap; | 540 | struct llc_sap *sap = llc->sap; |
@@ -555,7 +558,7 @@ int llc_conn_ac_send_rnr_rsp_f_set_1(struct sock *sk, struct sk_buff *skb) | |||
555 | { | 558 | { |
556 | int rc = -ENOBUFS; | 559 | int rc = -ENOBUFS; |
557 | struct llc_sock *llc = llc_sk(sk); | 560 | struct llc_sock *llc = llc_sk(sk); |
558 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 561 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
559 | 562 | ||
560 | if (nskb) { | 563 | if (nskb) { |
561 | struct llc_sap *sap = llc->sap; | 564 | struct llc_sap *sap = llc->sap; |
@@ -579,7 +582,7 @@ int llc_conn_ac_send_rnr_xxx_x_set_0(struct sock *sk, struct sk_buff *skb) | |||
579 | { | 582 | { |
580 | int rc = -ENOBUFS; | 583 | int rc = -ENOBUFS; |
581 | struct llc_sock *llc = llc_sk(sk); | 584 | struct llc_sock *llc = llc_sk(sk); |
582 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 585 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
583 | 586 | ||
584 | if (nskb) { | 587 | if (nskb) { |
585 | struct llc_sap *sap = llc->sap; | 588 | struct llc_sap *sap = llc->sap; |
@@ -615,7 +618,7 @@ int llc_conn_ac_opt_send_rnr_xxx_x_set_0(struct sock *sk, struct sk_buff *skb) | |||
615 | { | 618 | { |
616 | int rc = -ENOBUFS; | 619 | int rc = -ENOBUFS; |
617 | struct llc_sock *llc = llc_sk(sk); | 620 | struct llc_sock *llc = llc_sk(sk); |
618 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 621 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
619 | 622 | ||
620 | if (nskb) { | 623 | if (nskb) { |
621 | struct llc_sap *sap = llc->sap; | 624 | struct llc_sap *sap = llc->sap; |
@@ -639,7 +642,7 @@ int llc_conn_ac_send_rr_cmd_p_set_1(struct sock *sk, struct sk_buff *skb) | |||
639 | { | 642 | { |
640 | int rc = -ENOBUFS; | 643 | int rc = -ENOBUFS; |
641 | struct llc_sock *llc = llc_sk(sk); | 644 | struct llc_sock *llc = llc_sk(sk); |
642 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 645 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
643 | 646 | ||
644 | if (nskb) { | 647 | if (nskb) { |
645 | struct llc_sap *sap = llc->sap; | 648 | struct llc_sap *sap = llc->sap; |
@@ -663,7 +666,7 @@ int llc_conn_ac_send_rr_rsp_f_set_1(struct sock *sk, struct sk_buff *skb) | |||
663 | { | 666 | { |
664 | int rc = -ENOBUFS; | 667 | int rc = -ENOBUFS; |
665 | struct llc_sock *llc = llc_sk(sk); | 668 | struct llc_sock *llc = llc_sk(sk); |
666 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 669 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
667 | 670 | ||
668 | if (nskb) { | 671 | if (nskb) { |
669 | struct llc_sap *sap = llc->sap; | 672 | struct llc_sap *sap = llc->sap; |
@@ -688,7 +691,7 @@ int llc_conn_ac_send_ack_rsp_f_set_1(struct sock *sk, struct sk_buff *skb) | |||
688 | { | 691 | { |
689 | int rc = -ENOBUFS; | 692 | int rc = -ENOBUFS; |
690 | struct llc_sock *llc = llc_sk(sk); | 693 | struct llc_sock *llc = llc_sk(sk); |
691 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 694 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
692 | 695 | ||
693 | if (nskb) { | 696 | if (nskb) { |
694 | struct llc_sap *sap = llc->sap; | 697 | struct llc_sap *sap = llc->sap; |
@@ -712,7 +715,7 @@ int llc_conn_ac_send_rr_xxx_x_set_0(struct sock *sk, struct sk_buff *skb) | |||
712 | { | 715 | { |
713 | int rc = -ENOBUFS; | 716 | int rc = -ENOBUFS; |
714 | struct llc_sock *llc = llc_sk(sk); | 717 | struct llc_sock *llc = llc_sk(sk); |
715 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 718 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
716 | 719 | ||
717 | if (nskb) { | 720 | if (nskb) { |
718 | struct llc_sap *sap = llc->sap; | 721 | struct llc_sap *sap = llc->sap; |
@@ -736,7 +739,7 @@ int llc_conn_ac_send_ack_xxx_x_set_0(struct sock *sk, struct sk_buff *skb) | |||
736 | { | 739 | { |
737 | int rc = -ENOBUFS; | 740 | int rc = -ENOBUFS; |
738 | struct llc_sock *llc = llc_sk(sk); | 741 | struct llc_sock *llc = llc_sk(sk); |
739 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 742 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
740 | 743 | ||
741 | if (nskb) { | 744 | if (nskb) { |
742 | struct llc_sap *sap = llc->sap; | 745 | struct llc_sap *sap = llc->sap; |
@@ -770,7 +773,7 @@ int llc_conn_ac_send_sabme_cmd_p_set_x(struct sock *sk, struct sk_buff *skb) | |||
770 | { | 773 | { |
771 | int rc = -ENOBUFS; | 774 | int rc = -ENOBUFS; |
772 | struct llc_sock *llc = llc_sk(sk); | 775 | struct llc_sock *llc = llc_sk(sk); |
773 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 776 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_U, 0); |
774 | 777 | ||
775 | if (nskb) { | 778 | if (nskb) { |
776 | struct llc_sap *sap = llc->sap; | 779 | struct llc_sap *sap = llc->sap; |
@@ -799,7 +802,7 @@ int llc_conn_ac_send_ua_rsp_f_set_p(struct sock *sk, struct sk_buff *skb) | |||
799 | u8 f_bit; | 802 | u8 f_bit; |
800 | int rc = -ENOBUFS; | 803 | int rc = -ENOBUFS; |
801 | struct llc_sock *llc = llc_sk(sk); | 804 | struct llc_sock *llc = llc_sk(sk); |
802 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 805 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_U, 0); |
803 | 806 | ||
804 | llc_pdu_decode_pf_bit(skb, &f_bit); | 807 | llc_pdu_decode_pf_bit(skb, &f_bit); |
805 | if (nskb) { | 808 | if (nskb) { |
@@ -956,7 +959,7 @@ static int llc_conn_ac_send_rr_rsp_f_set_ackpf(struct sock *sk, | |||
956 | { | 959 | { |
957 | int rc = -ENOBUFS; | 960 | int rc = -ENOBUFS; |
958 | struct llc_sock *llc = llc_sk(sk); | 961 | struct llc_sock *llc = llc_sk(sk); |
959 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev); | 962 | struct sk_buff *nskb = llc_alloc_frame(sk, llc->dev, LLC_PDU_TYPE_S, 0); |
960 | 963 | ||
961 | if (nskb) { | 964 | if (nskb) { |
962 | struct llc_sap *sap = llc->sap; | 965 | struct llc_sap *sap = llc->sap; |
diff --git a/net/llc/llc_core.c b/net/llc/llc_core.c index 248b5903bb13..50d5b10e23a2 100644 --- a/net/llc/llc_core.c +++ b/net/llc/llc_core.c | |||
@@ -25,8 +25,6 @@ | |||
25 | LIST_HEAD(llc_sap_list); | 25 | LIST_HEAD(llc_sap_list); |
26 | DEFINE_RWLOCK(llc_sap_list_lock); | 26 | DEFINE_RWLOCK(llc_sap_list_lock); |
27 | 27 | ||
28 | unsigned char llc_station_mac_sa[ETH_ALEN]; | ||
29 | |||
30 | /** | 28 | /** |
31 | * llc_sap_alloc - allocates and initializes sap. | 29 | * llc_sap_alloc - allocates and initializes sap. |
32 | * | 30 | * |
@@ -37,8 +35,8 @@ static struct llc_sap *llc_sap_alloc(void) | |||
37 | struct llc_sap *sap = kzalloc(sizeof(*sap), GFP_ATOMIC); | 35 | struct llc_sap *sap = kzalloc(sizeof(*sap), GFP_ATOMIC); |
38 | 36 | ||
39 | if (sap) { | 37 | if (sap) { |
38 | /* sap->laddr.mac - leave as a null, it's filled by bind */ | ||
40 | sap->state = LLC_SAP_STATE_ACTIVE; | 39 | sap->state = LLC_SAP_STATE_ACTIVE; |
41 | memcpy(sap->laddr.mac, llc_station_mac_sa, ETH_ALEN); | ||
42 | rwlock_init(&sap->sk_list.lock); | 40 | rwlock_init(&sap->sk_list.lock); |
43 | atomic_set(&sap->refcnt, 1); | 41 | atomic_set(&sap->refcnt, 1); |
44 | } | 42 | } |
@@ -167,10 +165,6 @@ static int __init llc_init(void) | |||
167 | if (dev != NULL) | 165 | if (dev != NULL) |
168 | dev = next_net_device(dev); | 166 | dev = next_net_device(dev); |
169 | 167 | ||
170 | if (dev != NULL) | ||
171 | memcpy(llc_station_mac_sa, dev->dev_addr, ETH_ALEN); | ||
172 | else | ||
173 | memset(llc_station_mac_sa, 0, ETH_ALEN); | ||
174 | dev_add_pack(&llc_packet_type); | 168 | dev_add_pack(&llc_packet_type); |
175 | dev_add_pack(&llc_tr_packet_type); | 169 | dev_add_pack(&llc_tr_packet_type); |
176 | return 0; | 170 | return 0; |
@@ -185,7 +179,6 @@ static void __exit llc_exit(void) | |||
185 | module_init(llc_init); | 179 | module_init(llc_init); |
186 | module_exit(llc_exit); | 180 | module_exit(llc_exit); |
187 | 181 | ||
188 | EXPORT_SYMBOL(llc_station_mac_sa); | ||
189 | EXPORT_SYMBOL(llc_sap_list); | 182 | EXPORT_SYMBOL(llc_sap_list); |
190 | EXPORT_SYMBOL(llc_sap_list_lock); | 183 | EXPORT_SYMBOL(llc_sap_list_lock); |
191 | EXPORT_SYMBOL(llc_sap_find); | 184 | EXPORT_SYMBOL(llc_sap_find); |
diff --git a/net/llc/llc_input.c b/net/llc/llc_input.c index c40c9b2a345a..bfd2567dd365 100644 --- a/net/llc/llc_input.c +++ b/net/llc/llc_input.c | |||
@@ -117,8 +117,12 @@ static inline int llc_fixup_skb(struct sk_buff *skb) | |||
117 | skb_pull(skb, llc_len); | 117 | skb_pull(skb, llc_len); |
118 | if (skb->protocol == htons(ETH_P_802_2)) { | 118 | if (skb->protocol == htons(ETH_P_802_2)) { |
119 | __be16 pdulen = eth_hdr(skb)->h_proto; | 119 | __be16 pdulen = eth_hdr(skb)->h_proto; |
120 | u16 data_size = ntohs(pdulen) - llc_len; | 120 | s32 data_size = ntohs(pdulen) - llc_len; |
121 | 121 | ||
122 | if (data_size < 0 || | ||
123 | ((skb_tail_pointer(skb) - | ||
124 | (u8 *)pdu) - llc_len) < data_size) | ||
125 | return 0; | ||
122 | if (unlikely(pskb_trim_rcsum(skb, data_size))) | 126 | if (unlikely(pskb_trim_rcsum(skb, data_size))) |
123 | return 0; | 127 | return 0; |
124 | } | 128 | } |
diff --git a/net/llc/llc_pdu.c b/net/llc/llc_pdu.c index fa8324396db3..2e6cb79196bb 100644 --- a/net/llc/llc_pdu.c +++ b/net/llc/llc_pdu.c | |||
@@ -241,7 +241,7 @@ void llc_pdu_init_as_frmr_rsp(struct sk_buff *skb, struct llc_pdu_sn *prev_pdu, | |||
241 | FRMR_INFO_SET_PDU_INFO_2LONG_IND(frmr_info, vzyxw); | 241 | FRMR_INFO_SET_PDU_INFO_2LONG_IND(frmr_info, vzyxw); |
242 | FRMR_INFO_SET_PDU_INVALID_Nr_IND(frmr_info, vzyxw); | 242 | FRMR_INFO_SET_PDU_INVALID_Nr_IND(frmr_info, vzyxw); |
243 | FRMR_INFO_SET_PDU_INVALID_Ns_IND(frmr_info, vzyxw); | 243 | FRMR_INFO_SET_PDU_INVALID_Ns_IND(frmr_info, vzyxw); |
244 | skb_put(skb, 5); | 244 | skb_put(skb, sizeof(struct llc_frmr_info)); |
245 | } | 245 | } |
246 | 246 | ||
247 | /** | 247 | /** |
diff --git a/net/llc/llc_s_ac.c b/net/llc/llc_s_ac.c index ac3d93b210d2..a94bd56bcac6 100644 --- a/net/llc/llc_s_ac.c +++ b/net/llc/llc_s_ac.c | |||
@@ -103,7 +103,8 @@ int llc_sap_action_send_xid_r(struct llc_sap *sap, struct sk_buff *skb) | |||
103 | llc_pdu_decode_sa(skb, mac_da); | 103 | llc_pdu_decode_sa(skb, mac_da); |
104 | llc_pdu_decode_da(skb, mac_sa); | 104 | llc_pdu_decode_da(skb, mac_sa); |
105 | llc_pdu_decode_ssap(skb, &dsap); | 105 | llc_pdu_decode_ssap(skb, &dsap); |
106 | nskb = llc_alloc_frame(NULL, skb->dev); | 106 | nskb = llc_alloc_frame(NULL, skb->dev, LLC_PDU_TYPE_U, |
107 | sizeof(struct llc_xid_info)); | ||
107 | if (!nskb) | 108 | if (!nskb) |
108 | goto out; | 109 | goto out; |
109 | llc_pdu_header_init(nskb, LLC_PDU_TYPE_U, sap->laddr.lsap, dsap, | 110 | llc_pdu_header_init(nskb, LLC_PDU_TYPE_U, sap->laddr.lsap, dsap, |
@@ -144,11 +145,15 @@ int llc_sap_action_send_test_r(struct llc_sap *sap, struct sk_buff *skb) | |||
144 | u8 mac_da[ETH_ALEN], mac_sa[ETH_ALEN], dsap; | 145 | u8 mac_da[ETH_ALEN], mac_sa[ETH_ALEN], dsap; |
145 | struct sk_buff *nskb; | 146 | struct sk_buff *nskb; |
146 | int rc = 1; | 147 | int rc = 1; |
148 | u32 data_size; | ||
147 | 149 | ||
148 | llc_pdu_decode_sa(skb, mac_da); | 150 | llc_pdu_decode_sa(skb, mac_da); |
149 | llc_pdu_decode_da(skb, mac_sa); | 151 | llc_pdu_decode_da(skb, mac_sa); |
150 | llc_pdu_decode_ssap(skb, &dsap); | 152 | llc_pdu_decode_ssap(skb, &dsap); |
151 | nskb = llc_alloc_frame(NULL, skb->dev); | 153 | |
154 | /* The test request command is type U (llc_len = 3) */ | ||
155 | data_size = ntohs(eth_hdr(skb)->h_proto) - 3; | ||
156 | nskb = llc_alloc_frame(NULL, skb->dev, LLC_PDU_TYPE_U, data_size); | ||
152 | if (!nskb) | 157 | if (!nskb) |
153 | goto out; | 158 | goto out; |
154 | llc_pdu_header_init(nskb, LLC_PDU_TYPE_U, sap->laddr.lsap, dsap, | 159 | llc_pdu_header_init(nskb, LLC_PDU_TYPE_U, sap->laddr.lsap, dsap, |
diff --git a/net/llc/llc_sap.c b/net/llc/llc_sap.c index 2525165e2e8f..e2ddde755019 100644 --- a/net/llc/llc_sap.c +++ b/net/llc/llc_sap.c | |||
@@ -24,20 +24,41 @@ | |||
24 | #include <net/tcp_states.h> | 24 | #include <net/tcp_states.h> |
25 | #include <linux/llc.h> | 25 | #include <linux/llc.h> |
26 | 26 | ||
27 | static int llc_mac_header_len(unsigned short devtype) | ||
28 | { | ||
29 | switch (devtype) { | ||
30 | case ARPHRD_ETHER: | ||
31 | case ARPHRD_LOOPBACK: | ||
32 | return sizeof(struct ethhdr); | ||
33 | #ifdef CONFIG_TR | ||
34 | case ARPHRD_IEEE802_TR: | ||
35 | return sizeof(struct trh_hdr); | ||
36 | #endif | ||
37 | } | ||
38 | return 0; | ||
39 | } | ||
40 | |||
27 | /** | 41 | /** |
28 | * llc_alloc_frame - allocates sk_buff for frame | 42 | * llc_alloc_frame - allocates sk_buff for frame |
29 | * @dev: network device this skb will be sent over | 43 | * @dev: network device this skb will be sent over |
44 | * @type: pdu type to allocate | ||
45 | * @data_size: data size to allocate | ||
30 | * | 46 | * |
31 | * Allocates an sk_buff for frame and initializes sk_buff fields. | 47 | * Allocates an sk_buff for frame and initializes sk_buff fields. |
32 | * Returns allocated skb or %NULL when out of memory. | 48 | * Returns allocated skb or %NULL when out of memory. |
33 | */ | 49 | */ |
34 | struct sk_buff *llc_alloc_frame(struct sock *sk, struct net_device *dev) | 50 | struct sk_buff *llc_alloc_frame(struct sock *sk, struct net_device *dev, |
51 | u8 type, u32 data_size) | ||
35 | { | 52 | { |
36 | struct sk_buff *skb = alloc_skb(128, GFP_ATOMIC); | 53 | int hlen = type == LLC_PDU_TYPE_U ? 3 : 4; |
54 | struct sk_buff *skb; | ||
55 | |||
56 | hlen += llc_mac_header_len(dev->type); | ||
57 | skb = alloc_skb(hlen + data_size, GFP_ATOMIC); | ||
37 | 58 | ||
38 | if (skb) { | 59 | if (skb) { |
39 | skb_reset_mac_header(skb); | 60 | skb_reset_mac_header(skb); |
40 | skb_reserve(skb, 50); | 61 | skb_reserve(skb, hlen); |
41 | skb_reset_network_header(skb); | 62 | skb_reset_network_header(skb); |
42 | skb_reset_transport_header(skb); | 63 | skb_reset_transport_header(skb); |
43 | skb->protocol = htons(ETH_P_802_2); | 64 | skb->protocol = htons(ETH_P_802_2); |
diff --git a/net/llc/llc_station.c b/net/llc/llc_station.c index 6f2ea2090322..83da13339490 100644 --- a/net/llc/llc_station.c +++ b/net/llc/llc_station.c | |||
@@ -253,13 +253,14 @@ static int llc_station_ac_inc_xid_r_cnt_by_1(struct sk_buff *skb) | |||
253 | static int llc_station_ac_send_null_dsap_xid_c(struct sk_buff *skb) | 253 | static int llc_station_ac_send_null_dsap_xid_c(struct sk_buff *skb) |
254 | { | 254 | { |
255 | int rc = 1; | 255 | int rc = 1; |
256 | struct sk_buff *nskb = llc_alloc_frame(NULL, skb->dev); | 256 | struct sk_buff *nskb = llc_alloc_frame(NULL, skb->dev, LLC_PDU_TYPE_U, |
257 | sizeof(struct llc_xid_info)); | ||
257 | 258 | ||
258 | if (!nskb) | 259 | if (!nskb) |
259 | goto out; | 260 | goto out; |
260 | llc_pdu_header_init(nskb, LLC_PDU_TYPE_U, 0, 0, LLC_PDU_CMD); | 261 | llc_pdu_header_init(nskb, LLC_PDU_TYPE_U, 0, 0, LLC_PDU_CMD); |
261 | llc_pdu_init_as_xid_cmd(nskb, LLC_XID_NULL_CLASS_2, 127); | 262 | llc_pdu_init_as_xid_cmd(nskb, LLC_XID_NULL_CLASS_2, 127); |
262 | rc = llc_mac_hdr_init(nskb, llc_station_mac_sa, llc_station_mac_sa); | 263 | rc = llc_mac_hdr_init(nskb, skb->dev->dev_addr, skb->dev->dev_addr); |
263 | if (unlikely(rc)) | 264 | if (unlikely(rc)) |
264 | goto free; | 265 | goto free; |
265 | llc_station_send_pdu(nskb); | 266 | llc_station_send_pdu(nskb); |
@@ -274,7 +275,8 @@ static int llc_station_ac_send_xid_r(struct sk_buff *skb) | |||
274 | { | 275 | { |
275 | u8 mac_da[ETH_ALEN], dsap; | 276 | u8 mac_da[ETH_ALEN], dsap; |
276 | int rc = 1; | 277 | int rc = 1; |
277 | struct sk_buff* nskb = llc_alloc_frame(NULL, skb->dev); | 278 | struct sk_buff *nskb = llc_alloc_frame(NULL, skb->dev, LLC_PDU_TYPE_U, |
279 | sizeof(struct llc_xid_info)); | ||
278 | 280 | ||
279 | if (!nskb) | 281 | if (!nskb) |
280 | goto out; | 282 | goto out; |
@@ -283,7 +285,7 @@ static int llc_station_ac_send_xid_r(struct sk_buff *skb) | |||
283 | llc_pdu_decode_ssap(skb, &dsap); | 285 | llc_pdu_decode_ssap(skb, &dsap); |
284 | llc_pdu_header_init(nskb, LLC_PDU_TYPE_U, 0, dsap, LLC_PDU_RSP); | 286 | llc_pdu_header_init(nskb, LLC_PDU_TYPE_U, 0, dsap, LLC_PDU_RSP); |
285 | llc_pdu_init_as_xid_rsp(nskb, LLC_XID_NULL_CLASS_2, 127); | 287 | llc_pdu_init_as_xid_rsp(nskb, LLC_XID_NULL_CLASS_2, 127); |
286 | rc = llc_mac_hdr_init(nskb, llc_station_mac_sa, mac_da); | 288 | rc = llc_mac_hdr_init(nskb, skb->dev->dev_addr, mac_da); |
287 | if (unlikely(rc)) | 289 | if (unlikely(rc)) |
288 | goto free; | 290 | goto free; |
289 | llc_station_send_pdu(nskb); | 291 | llc_station_send_pdu(nskb); |
@@ -298,7 +300,12 @@ static int llc_station_ac_send_test_r(struct sk_buff *skb) | |||
298 | { | 300 | { |
299 | u8 mac_da[ETH_ALEN], dsap; | 301 | u8 mac_da[ETH_ALEN], dsap; |
300 | int rc = 1; | 302 | int rc = 1; |
301 | struct sk_buff *nskb = llc_alloc_frame(NULL, skb->dev); | 303 | u32 data_size; |
304 | struct sk_buff *nskb; | ||
305 | |||
306 | /* The test request command is type U (llc_len = 3) */ | ||
307 | data_size = ntohs(eth_hdr(skb)->h_proto) - 3; | ||
308 | nskb = llc_alloc_frame(NULL, skb->dev, LLC_PDU_TYPE_U, data_size); | ||
302 | 309 | ||
303 | if (!nskb) | 310 | if (!nskb) |
304 | goto out; | 311 | goto out; |
@@ -307,7 +314,7 @@ static int llc_station_ac_send_test_r(struct sk_buff *skb) | |||
307 | llc_pdu_decode_ssap(skb, &dsap); | 314 | llc_pdu_decode_ssap(skb, &dsap); |
308 | llc_pdu_header_init(nskb, LLC_PDU_TYPE_U, 0, dsap, LLC_PDU_RSP); | 315 | llc_pdu_header_init(nskb, LLC_PDU_TYPE_U, 0, dsap, LLC_PDU_RSP); |
309 | llc_pdu_init_as_test_rsp(nskb, skb); | 316 | llc_pdu_init_as_test_rsp(nskb, skb); |
310 | rc = llc_mac_hdr_init(nskb, llc_station_mac_sa, mac_da); | 317 | rc = llc_mac_hdr_init(nskb, skb->dev->dev_addr, mac_da); |
311 | if (unlikely(rc)) | 318 | if (unlikely(rc)) |
312 | goto free; | 319 | goto free; |
313 | llc_station_send_pdu(nskb); | 320 | llc_station_send_pdu(nskb); |
diff --git a/net/mac80211/ieee80211.c b/net/mac80211/ieee80211.c index 28bcdf9fc3df..8e586390a2ef 100644 --- a/net/mac80211/ieee80211.c +++ b/net/mac80211/ieee80211.c | |||
@@ -286,6 +286,18 @@ static int ieee80211_open(struct net_device *dev) | |||
286 | if (need_hw_reconfig) | 286 | if (need_hw_reconfig) |
287 | ieee80211_hw_config(local); | 287 | ieee80211_hw_config(local); |
288 | 288 | ||
289 | /* | ||
290 | * ieee80211_sta_work is disabled while network interface | ||
291 | * is down. Therefore, some configuration changes may not | ||
292 | * yet be effective. Trigger execution of ieee80211_sta_work | ||
293 | * to fix this. | ||
294 | */ | ||
295 | if(sdata->vif.type == IEEE80211_IF_TYPE_STA || | ||
296 | sdata->vif.type == IEEE80211_IF_TYPE_IBSS) { | ||
297 | struct ieee80211_if_sta *ifsta = &sdata->u.sta; | ||
298 | queue_work(local->hw.workqueue, &ifsta->work); | ||
299 | } | ||
300 | |||
289 | netif_start_queue(dev); | 301 | netif_start_queue(dev); |
290 | 302 | ||
291 | return 0; | 303 | return 0; |
diff --git a/net/mac80211/ieee80211_sta.c b/net/mac80211/ieee80211_sta.c index 9aeed5320228..e0c72d04584b 100644 --- a/net/mac80211/ieee80211_sta.c +++ b/net/mac80211/ieee80211_sta.c | |||
@@ -319,7 +319,7 @@ static u32 ieee80211_handle_erp_ie(struct ieee80211_sub_if_data *sdata, | |||
319 | struct ieee80211_bss_conf *bss_conf = &sdata->bss_conf; | 319 | struct ieee80211_bss_conf *bss_conf = &sdata->bss_conf; |
320 | struct ieee80211_if_sta *ifsta = &sdata->u.sta; | 320 | struct ieee80211_if_sta *ifsta = &sdata->u.sta; |
321 | bool use_protection = (erp_value & WLAN_ERP_USE_PROTECTION) != 0; | 321 | bool use_protection = (erp_value & WLAN_ERP_USE_PROTECTION) != 0; |
322 | bool preamble_mode = (erp_value & WLAN_ERP_BARKER_PREAMBLE) != 0; | 322 | bool use_short_preamble = (erp_value & WLAN_ERP_BARKER_PREAMBLE) == 0; |
323 | DECLARE_MAC_BUF(mac); | 323 | DECLARE_MAC_BUF(mac); |
324 | u32 changed = 0; | 324 | u32 changed = 0; |
325 | 325 | ||
@@ -335,16 +335,15 @@ static u32 ieee80211_handle_erp_ie(struct ieee80211_sub_if_data *sdata, | |||
335 | changed |= BSS_CHANGED_ERP_CTS_PROT; | 335 | changed |= BSS_CHANGED_ERP_CTS_PROT; |
336 | } | 336 | } |
337 | 337 | ||
338 | if (preamble_mode != bss_conf->use_short_preamble) { | 338 | if (use_short_preamble != bss_conf->use_short_preamble) { |
339 | if (net_ratelimit()) { | 339 | if (net_ratelimit()) { |
340 | printk(KERN_DEBUG "%s: switched to %s barker preamble" | 340 | printk(KERN_DEBUG "%s: switched to %s barker preamble" |
341 | " (BSSID=%s)\n", | 341 | " (BSSID=%s)\n", |
342 | sdata->dev->name, | 342 | sdata->dev->name, |
343 | (preamble_mode == WLAN_ERP_PREAMBLE_SHORT) ? | 343 | use_short_preamble ? "short" : "long", |
344 | "short" : "long", | ||
345 | print_mac(mac, ifsta->bssid)); | 344 | print_mac(mac, ifsta->bssid)); |
346 | } | 345 | } |
347 | bss_conf->use_short_preamble = preamble_mode; | 346 | bss_conf->use_short_preamble = use_short_preamble; |
348 | changed |= BSS_CHANGED_ERP_PREAMBLE; | 347 | changed |= BSS_CHANGED_ERP_PREAMBLE; |
349 | } | 348 | } |
350 | 349 | ||
diff --git a/net/netfilter/nf_conntrack_standalone.c b/net/netfilter/nf_conntrack_standalone.c index e88e96af613d..8599068050ec 100644 --- a/net/netfilter/nf_conntrack_standalone.c +++ b/net/netfilter/nf_conntrack_standalone.c | |||
@@ -395,7 +395,7 @@ EXPORT_SYMBOL_GPL(nf_ct_log_invalid); | |||
395 | static int __init nf_conntrack_standalone_init(void) | 395 | static int __init nf_conntrack_standalone_init(void) |
396 | { | 396 | { |
397 | #ifdef CONFIG_PROC_FS | 397 | #ifdef CONFIG_PROC_FS |
398 | struct proc_dir_entry *proc, *proc_stat; | 398 | struct proc_dir_entry *proc; |
399 | #endif | 399 | #endif |
400 | int ret = 0; | 400 | int ret = 0; |
401 | 401 | ||
@@ -407,12 +407,9 @@ static int __init nf_conntrack_standalone_init(void) | |||
407 | proc = proc_net_fops_create(&init_net, "nf_conntrack", 0440, &ct_file_ops); | 407 | proc = proc_net_fops_create(&init_net, "nf_conntrack", 0440, &ct_file_ops); |
408 | if (!proc) goto cleanup_init; | 408 | if (!proc) goto cleanup_init; |
409 | 409 | ||
410 | proc_stat = create_proc_entry("nf_conntrack", S_IRUGO, init_net.proc_net_stat); | 410 | if (!proc_create("nf_conntrack", S_IRUGO, |
411 | if (!proc_stat) | 411 | init_net.proc_net_stat, &ct_cpu_seq_fops)) |
412 | goto cleanup_proc; | 412 | goto cleanup_proc; |
413 | |||
414 | proc_stat->proc_fops = &ct_cpu_seq_fops; | ||
415 | proc_stat->owner = THIS_MODULE; | ||
416 | #endif | 413 | #endif |
417 | #ifdef CONFIG_SYSCTL | 414 | #ifdef CONFIG_SYSCTL |
418 | nf_ct_sysctl_header = register_sysctl_paths(nf_ct_path, | 415 | nf_ct_sysctl_header = register_sysctl_paths(nf_ct_path, |
diff --git a/net/netfilter/nf_log.c b/net/netfilter/nf_log.c index cec9976aecbf..bc11d7092032 100644 --- a/net/netfilter/nf_log.c +++ b/net/netfilter/nf_log.c | |||
@@ -168,13 +168,9 @@ static const struct file_operations nflog_file_ops = { | |||
168 | int __init netfilter_log_init(void) | 168 | int __init netfilter_log_init(void) |
169 | { | 169 | { |
170 | #ifdef CONFIG_PROC_FS | 170 | #ifdef CONFIG_PROC_FS |
171 | struct proc_dir_entry *pde; | 171 | if (!proc_create("nf_log", S_IRUGO, |
172 | 172 | proc_net_netfilter, &nflog_file_ops)) | |
173 | pde = create_proc_entry("nf_log", S_IRUGO, proc_net_netfilter); | ||
174 | if (!pde) | ||
175 | return -1; | 173 | return -1; |
176 | |||
177 | pde->proc_fops = &nflog_file_ops; | ||
178 | #endif | 174 | #endif |
179 | return 0; | 175 | return 0; |
180 | } | 176 | } |
diff --git a/net/netfilter/nf_queue.c b/net/netfilter/nf_queue.c index ddc80ea114cd..bbd26893c0c4 100644 --- a/net/netfilter/nf_queue.c +++ b/net/netfilter/nf_queue.c | |||
@@ -348,12 +348,9 @@ static const struct file_operations nfqueue_file_ops = { | |||
348 | int __init netfilter_queue_init(void) | 348 | int __init netfilter_queue_init(void) |
349 | { | 349 | { |
350 | #ifdef CONFIG_PROC_FS | 350 | #ifdef CONFIG_PROC_FS |
351 | struct proc_dir_entry *pde; | 351 | if (!proc_create("nf_queue", S_IRUGO, |
352 | 352 | proc_net_netfilter, &nfqueue_file_ops)) | |
353 | pde = create_proc_entry("nf_queue", S_IRUGO, proc_net_netfilter); | ||
354 | if (!pde) | ||
355 | return -1; | 353 | return -1; |
356 | pde->proc_fops = &nfqueue_file_ops; | ||
357 | #endif | 354 | #endif |
358 | return 0; | 355 | return 0; |
359 | } | 356 | } |
diff --git a/net/netfilter/nfnetlink_log.c b/net/netfilter/nfnetlink_log.c index bf3f19b21fe4..b8173af8c24a 100644 --- a/net/netfilter/nfnetlink_log.c +++ b/net/netfilter/nfnetlink_log.c | |||
@@ -923,9 +923,6 @@ static const struct file_operations nful_file_ops = { | |||
923 | static int __init nfnetlink_log_init(void) | 923 | static int __init nfnetlink_log_init(void) |
924 | { | 924 | { |
925 | int i, status = -ENOMEM; | 925 | int i, status = -ENOMEM; |
926 | #ifdef CONFIG_PROC_FS | ||
927 | struct proc_dir_entry *proc_nful; | ||
928 | #endif | ||
929 | 926 | ||
930 | for (i = 0; i < INSTANCE_BUCKETS; i++) | 927 | for (i = 0; i < INSTANCE_BUCKETS; i++) |
931 | INIT_HLIST_HEAD(&instance_table[i]); | 928 | INIT_HLIST_HEAD(&instance_table[i]); |
@@ -943,11 +940,9 @@ static int __init nfnetlink_log_init(void) | |||
943 | } | 940 | } |
944 | 941 | ||
945 | #ifdef CONFIG_PROC_FS | 942 | #ifdef CONFIG_PROC_FS |
946 | proc_nful = create_proc_entry("nfnetlink_log", 0440, | 943 | if (!proc_create("nfnetlink_log", 0440, |
947 | proc_net_netfilter); | 944 | proc_net_netfilter, &nful_file_ops)) |
948 | if (!proc_nful) | ||
949 | goto cleanup_subsys; | 945 | goto cleanup_subsys; |
950 | proc_nful->proc_fops = &nful_file_ops; | ||
951 | #endif | 946 | #endif |
952 | return status; | 947 | return status; |
953 | 948 | ||
diff --git a/net/netfilter/nfnetlink_queue.c b/net/netfilter/nfnetlink_queue.c index 012cb6910820..10522c04ed24 100644 --- a/net/netfilter/nfnetlink_queue.c +++ b/net/netfilter/nfnetlink_queue.c | |||
@@ -896,9 +896,6 @@ static const struct file_operations nfqnl_file_ops = { | |||
896 | static int __init nfnetlink_queue_init(void) | 896 | static int __init nfnetlink_queue_init(void) |
897 | { | 897 | { |
898 | int i, status = -ENOMEM; | 898 | int i, status = -ENOMEM; |
899 | #ifdef CONFIG_PROC_FS | ||
900 | struct proc_dir_entry *proc_nfqueue; | ||
901 | #endif | ||
902 | 899 | ||
903 | for (i = 0; i < INSTANCE_BUCKETS; i++) | 900 | for (i = 0; i < INSTANCE_BUCKETS; i++) |
904 | INIT_HLIST_HEAD(&instance_table[i]); | 901 | INIT_HLIST_HEAD(&instance_table[i]); |
@@ -911,11 +908,9 @@ static int __init nfnetlink_queue_init(void) | |||
911 | } | 908 | } |
912 | 909 | ||
913 | #ifdef CONFIG_PROC_FS | 910 | #ifdef CONFIG_PROC_FS |
914 | proc_nfqueue = create_proc_entry("nfnetlink_queue", 0440, | 911 | if (!proc_create("nfnetlink_queue", 0440, |
915 | proc_net_netfilter); | 912 | proc_net_netfilter, &nfqnl_file_ops)) |
916 | if (!proc_nfqueue) | ||
917 | goto cleanup_subsys; | 913 | goto cleanup_subsys; |
918 | proc_nfqueue->proc_fops = &nfqnl_file_ops; | ||
919 | #endif | 914 | #endif |
920 | 915 | ||
921 | register_netdevice_notifier(&nfqnl_dev_notifier); | 916 | register_netdevice_notifier(&nfqnl_dev_notifier); |
diff --git a/net/netfilter/xt_hashlimit.c b/net/netfilter/xt_hashlimit.c index 5418ce59ac3a..dc29007c52cd 100644 --- a/net/netfilter/xt_hashlimit.c +++ b/net/netfilter/xt_hashlimit.c | |||
@@ -237,14 +237,14 @@ static int htable_create_v0(struct xt_hashlimit_info *minfo, int family) | |||
237 | hinfo->family = family; | 237 | hinfo->family = family; |
238 | hinfo->rnd_initialized = 0; | 238 | hinfo->rnd_initialized = 0; |
239 | spin_lock_init(&hinfo->lock); | 239 | spin_lock_init(&hinfo->lock); |
240 | hinfo->pde = create_proc_entry(minfo->name, 0, | 240 | hinfo->pde = proc_create(minfo->name, 0, |
241 | family == AF_INET ? hashlimit_procdir4 : | 241 | family == AF_INET ? hashlimit_procdir4 : |
242 | hashlimit_procdir6); | 242 | hashlimit_procdir6, |
243 | &dl_file_ops); | ||
243 | if (!hinfo->pde) { | 244 | if (!hinfo->pde) { |
244 | vfree(hinfo); | 245 | vfree(hinfo); |
245 | return -1; | 246 | return -1; |
246 | } | 247 | } |
247 | hinfo->pde->proc_fops = &dl_file_ops; | ||
248 | hinfo->pde->data = hinfo; | 248 | hinfo->pde->data = hinfo; |
249 | 249 | ||
250 | setup_timer(&hinfo->timer, htable_gc, (unsigned long )hinfo); | 250 | setup_timer(&hinfo->timer, htable_gc, (unsigned long )hinfo); |
@@ -301,14 +301,14 @@ static int htable_create(struct xt_hashlimit_mtinfo1 *minfo, | |||
301 | hinfo->rnd_initialized = 0; | 301 | hinfo->rnd_initialized = 0; |
302 | spin_lock_init(&hinfo->lock); | 302 | spin_lock_init(&hinfo->lock); |
303 | 303 | ||
304 | hinfo->pde = create_proc_entry(minfo->name, 0, | 304 | hinfo->pde = proc_create(minfo->name, 0, |
305 | family == AF_INET ? hashlimit_procdir4 : | 305 | family == AF_INET ? hashlimit_procdir4 : |
306 | hashlimit_procdir6); | 306 | hashlimit_procdir6, |
307 | &dl_file_ops); | ||
307 | if (hinfo->pde == NULL) { | 308 | if (hinfo->pde == NULL) { |
308 | vfree(hinfo); | 309 | vfree(hinfo); |
309 | return -1; | 310 | return -1; |
310 | } | 311 | } |
311 | hinfo->pde->proc_fops = &dl_file_ops; | ||
312 | hinfo->pde->data = hinfo; | 312 | hinfo->pde->data = hinfo; |
313 | 313 | ||
314 | setup_timer(&hinfo->timer, htable_gc, (unsigned long)hinfo); | 314 | setup_timer(&hinfo->timer, htable_gc, (unsigned long)hinfo); |
diff --git a/net/rose/af_rose.c b/net/rose/af_rose.c index 4a31a81059ab..063cbc5c26b1 100644 --- a/net/rose/af_rose.c +++ b/net/rose/af_rose.c | |||
@@ -598,17 +598,24 @@ static int rose_release(struct socket *sock) | |||
598 | 598 | ||
599 | if (sk == NULL) return 0; | 599 | if (sk == NULL) return 0; |
600 | 600 | ||
601 | sock_hold(sk); | ||
602 | sock_orphan(sk); | ||
603 | lock_sock(sk); | ||
601 | rose = rose_sk(sk); | 604 | rose = rose_sk(sk); |
602 | 605 | ||
603 | switch (rose->state) { | 606 | switch (rose->state) { |
604 | case ROSE_STATE_0: | 607 | case ROSE_STATE_0: |
608 | release_sock(sk); | ||
605 | rose_disconnect(sk, 0, -1, -1); | 609 | rose_disconnect(sk, 0, -1, -1); |
610 | lock_sock(sk); | ||
606 | rose_destroy_socket(sk); | 611 | rose_destroy_socket(sk); |
607 | break; | 612 | break; |
608 | 613 | ||
609 | case ROSE_STATE_2: | 614 | case ROSE_STATE_2: |
610 | rose->neighbour->use--; | 615 | rose->neighbour->use--; |
616 | release_sock(sk); | ||
611 | rose_disconnect(sk, 0, -1, -1); | 617 | rose_disconnect(sk, 0, -1, -1); |
618 | lock_sock(sk); | ||
612 | rose_destroy_socket(sk); | 619 | rose_destroy_socket(sk); |
613 | break; | 620 | break; |
614 | 621 | ||
@@ -633,6 +640,8 @@ static int rose_release(struct socket *sock) | |||
633 | } | 640 | } |
634 | 641 | ||
635 | sock->sk = NULL; | 642 | sock->sk = NULL; |
643 | release_sock(sk); | ||
644 | sock_put(sk); | ||
636 | 645 | ||
637 | return 0; | 646 | return 0; |
638 | } | 647 | } |
diff --git a/net/rxrpc/ar-internal.h b/net/rxrpc/ar-internal.h index 126ca777b410..53fe94c9d36b 100644 --- a/net/rxrpc/ar-internal.h +++ b/net/rxrpc/ar-internal.h | |||
@@ -611,7 +611,7 @@ extern struct rxrpc_transport *rxrpc_find_transport(struct rxrpc_local *, | |||
611 | extern unsigned rxrpc_debug; | 611 | extern unsigned rxrpc_debug; |
612 | 612 | ||
613 | #define dbgprintk(FMT,...) \ | 613 | #define dbgprintk(FMT,...) \ |
614 | printk("[%x%-6.6s] "FMT"\n", smp_processor_id(), current->comm ,##__VA_ARGS__) | 614 | printk("[%-6.6s] "FMT"\n", current->comm ,##__VA_ARGS__) |
615 | 615 | ||
616 | /* make sure we maintain the format strings, even when debugging is disabled */ | 616 | /* make sure we maintain the format strings, even when debugging is disabled */ |
617 | static inline __attribute__((format(printf,1,2))) | 617 | static inline __attribute__((format(printf,1,2))) |
diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c index 10b5c0887fff..b741618e4d54 100644 --- a/net/sched/sch_generic.c +++ b/net/sched/sch_generic.c | |||
@@ -184,10 +184,22 @@ static inline int qdisc_restart(struct net_device *dev) | |||
184 | 184 | ||
185 | void __qdisc_run(struct net_device *dev) | 185 | void __qdisc_run(struct net_device *dev) |
186 | { | 186 | { |
187 | do { | 187 | unsigned long start_time = jiffies; |
188 | if (!qdisc_restart(dev)) | 188 | |
189 | while (qdisc_restart(dev)) { | ||
190 | if (netif_queue_stopped(dev)) | ||
191 | break; | ||
192 | |||
193 | /* | ||
194 | * Postpone processing if | ||
195 | * 1. another process needs the CPU; | ||
196 | * 2. we've been doing it for too long. | ||
197 | */ | ||
198 | if (need_resched() || jiffies != start_time) { | ||
199 | netif_schedule(dev); | ||
189 | break; | 200 | break; |
190 | } while (!netif_queue_stopped(dev)); | 201 | } |
202 | } | ||
191 | 203 | ||
192 | clear_bit(__LINK_STATE_QDISC_RUNNING, &dev->state); | 204 | clear_bit(__LINK_STATE_QDISC_RUNNING, &dev->state); |
193 | } | 205 | } |
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index 41a049f50f58..c2fef7b12dc7 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c | |||
@@ -1630,6 +1630,12 @@ static inline u32 file_to_av(struct file *file) | |||
1630 | else | 1630 | else |
1631 | av |= FILE__WRITE; | 1631 | av |= FILE__WRITE; |
1632 | } | 1632 | } |
1633 | if (!av) { | ||
1634 | /* | ||
1635 | * Special file opened with flags 3 for ioctl-only use. | ||
1636 | */ | ||
1637 | av = FILE__IOCTL; | ||
1638 | } | ||
1633 | 1639 | ||
1634 | return av; | 1640 | return av; |
1635 | } | 1641 | } |