]>
Commit | Line | Data |
---|---|---|
82094b55 AF |
1 | From: Greg Kroah-Hartman <gregkh@suse.de> |
2 | Subject: Linux 2.6.27.10 | |
3 | ||
4 | Upstream 2.6.27.10 release from kernel.org | |
5 | ||
6 | Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> | |
7 | ||
8 | diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt | |
9 | index 1150444..792be86 100644 | |
10 | --- a/Documentation/kernel-parameters.txt | |
11 | +++ b/Documentation/kernel-parameters.txt | |
12 | @@ -283,7 +283,7 @@ and is between 256 and 4096 characters. It is defined in the file | |
13 | Possible values are: | |
14 | isolate - enable device isolation (each device, as far | |
15 | as possible, will get its own protection | |
16 | - domain) | |
17 | + domain) [default] | |
18 | amd_iommu_size= [HW,X86-64] | |
19 | Define the size of the aperture for the AMD IOMMU | |
20 | driver. Possible values are: | |
21 | diff --git a/Makefile b/Makefile | |
22 | index cb93e2b..24f4804 100644 | |
23 | --- a/Makefile | |
24 | +++ b/Makefile | |
25 | @@ -1,7 +1,7 @@ | |
26 | VERSION = 2 | |
27 | PATCHLEVEL = 6 | |
28 | SUBLEVEL = 27 | |
29 | -EXTRAVERSION = .9 | |
30 | +EXTRAVERSION = .10 | |
31 | NAME = Trembling Tortoise | |
32 | ||
33 | # *DOCUMENTATION* | |
34 | diff --git a/arch/x86/kernel/amd_iommu_init.c b/arch/x86/kernel/amd_iommu_init.c | |
35 | index bccd0ef..a1378c4 100644 | |
36 | --- a/arch/x86/kernel/amd_iommu_init.c | |
37 | +++ b/arch/x86/kernel/amd_iommu_init.c | |
38 | @@ -120,7 +120,7 @@ u16 amd_iommu_last_bdf; /* largest PCI device id we have | |
39 | LIST_HEAD(amd_iommu_unity_map); /* a list of required unity mappings | |
40 | we find in ACPI */ | |
41 | unsigned amd_iommu_aperture_order = 26; /* size of aperture in power of 2 */ | |
42 | -int amd_iommu_isolate; /* if 1, device isolation is enabled */ | |
43 | +int amd_iommu_isolate = 1; /* if 1, device isolation is enabled */ | |
44 | ||
45 | LIST_HEAD(amd_iommu_list); /* list of all AMD IOMMUs in the | |
46 | system */ | |
47 | diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c | |
48 | index 7667443..6d5a3c4 100644 | |
49 | --- a/arch/x86/kernel/setup.c | |
50 | +++ b/arch/x86/kernel/setup.c | |
51 | @@ -634,6 +634,9 @@ void __init setup_arch(char **cmdline_p) | |
52 | printk(KERN_INFO "Command line: %s\n", boot_command_line); | |
53 | #endif | |
54 | ||
55 | + /* VMI may relocate the fixmap; do this before touching ioremap area */ | |
56 | + vmi_init(); | |
57 | + | |
58 | early_cpu_init(); | |
59 | early_ioremap_init(); | |
60 | ||
61 | @@ -707,13 +710,8 @@ void __init setup_arch(char **cmdline_p) | |
62 | check_efer(); | |
63 | #endif | |
64 | ||
65 | -#if defined(CONFIG_VMI) && defined(CONFIG_X86_32) | |
66 | - /* | |
67 | - * Must be before kernel pagetables are setup | |
68 | - * or fixmap area is touched. | |
69 | - */ | |
70 | - vmi_init(); | |
71 | -#endif | |
72 | + /* Must be before kernel pagetables are setup */ | |
73 | + vmi_activate(); | |
74 | ||
75 | /* after early param, so could get panic from serial */ | |
76 | reserve_early_setup_data(); | |
77 | diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c | |
78 | index 7985c5b..259569f 100644 | |
79 | --- a/arch/x86/kernel/smpboot.c | |
80 | +++ b/arch/x86/kernel/smpboot.c | |
81 | @@ -289,9 +289,7 @@ static void __cpuinit start_secondary(void *unused) | |
82 | * fragile that we want to limit the things done here to the | |
83 | * most necessary things. | |
84 | */ | |
85 | -#ifdef CONFIG_VMI | |
86 | vmi_bringup(); | |
87 | -#endif | |
88 | cpu_init(); | |
89 | preempt_disable(); | |
90 | smp_callin(); | |
91 | diff --git a/arch/x86/kernel/vmi_32.c b/arch/x86/kernel/vmi_32.c | |
92 | index edfb09f..f370d38 100644 | |
93 | --- a/arch/x86/kernel/vmi_32.c | |
94 | +++ b/arch/x86/kernel/vmi_32.c | |
95 | @@ -960,8 +960,6 @@ static inline int __init activate_vmi(void) | |
96 | ||
97 | void __init vmi_init(void) | |
98 | { | |
99 | - unsigned long flags; | |
100 | - | |
101 | if (!vmi_rom) | |
102 | probe_vmi_rom(); | |
103 | else | |
104 | @@ -973,13 +971,21 @@ void __init vmi_init(void) | |
105 | ||
106 | reserve_top_address(-vmi_rom->virtual_top); | |
107 | ||
108 | - local_irq_save(flags); | |
109 | - activate_vmi(); | |
110 | - | |
111 | #ifdef CONFIG_X86_IO_APIC | |
112 | /* This is virtual hardware; timer routing is wired correctly */ | |
113 | no_timer_check = 1; | |
114 | #endif | |
115 | +} | |
116 | + | |
117 | +void vmi_activate(void) | |
118 | +{ | |
119 | + unsigned long flags; | |
120 | + | |
121 | + if (!vmi_rom) | |
122 | + return; | |
123 | + | |
124 | + local_irq_save(flags); | |
125 | + activate_vmi(); | |
126 | local_irq_restore(flags & X86_EFLAGS_IF); | |
127 | } | |
128 | ||
129 | diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c | |
130 | index b551cda..f38e2af 100644 | |
131 | --- a/drivers/ata/libata-core.c | |
132 | +++ b/drivers/ata/libata-core.c | |
133 | @@ -3979,17 +3979,70 @@ static const struct ata_blacklist_entry ata_device_blacklist [] = { | |
134 | { "ST3160023AS", "3.42", ATA_HORKAGE_NONCQ }, | |
135 | ||
136 | /* Seagate NCQ + FLUSH CACHE firmware bug */ | |
137 | - { "ST31500341AS", "9JU138", ATA_HORKAGE_NONCQ | | |
138 | + { "ST31500341AS", "SD15", ATA_HORKAGE_NONCQ | | |
139 | ATA_HORKAGE_FIRMWARE_WARN }, | |
140 | - { "ST31000333AS", "9FZ136", ATA_HORKAGE_NONCQ | | |
141 | + { "ST31500341AS", "SD16", ATA_HORKAGE_NONCQ | | |
142 | ATA_HORKAGE_FIRMWARE_WARN }, | |
143 | - { "ST3640623AS", "9FZ164", ATA_HORKAGE_NONCQ | | |
144 | + { "ST31500341AS", "SD17", ATA_HORKAGE_NONCQ | | |
145 | ATA_HORKAGE_FIRMWARE_WARN }, | |
146 | - { "ST3640323AS", "9FZ134", ATA_HORKAGE_NONCQ | | |
147 | + { "ST31500341AS", "SD18", ATA_HORKAGE_NONCQ | | |
148 | ATA_HORKAGE_FIRMWARE_WARN }, | |
149 | - { "ST3320813AS", "9FZ182", ATA_HORKAGE_NONCQ | | |
150 | + { "ST31500341AS", "SD19", ATA_HORKAGE_NONCQ | | |
151 | ATA_HORKAGE_FIRMWARE_WARN }, | |
152 | - { "ST3320613AS", "9FZ162", ATA_HORKAGE_NONCQ | | |
153 | + | |
154 | + { "ST31000333AS", "SD15", ATA_HORKAGE_NONCQ | | |
155 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
156 | + { "ST31000333AS", "SD16", ATA_HORKAGE_NONCQ | | |
157 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
158 | + { "ST31000333AS", "SD17", ATA_HORKAGE_NONCQ | | |
159 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
160 | + { "ST31000333AS", "SD18", ATA_HORKAGE_NONCQ | | |
161 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
162 | + { "ST31000333AS", "SD19", ATA_HORKAGE_NONCQ | | |
163 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
164 | + | |
165 | + { "ST3640623AS", "SD15", ATA_HORKAGE_NONCQ | | |
166 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
167 | + { "ST3640623AS", "SD16", ATA_HORKAGE_NONCQ | | |
168 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
169 | + { "ST3640623AS", "SD17", ATA_HORKAGE_NONCQ | | |
170 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
171 | + { "ST3640623AS", "SD18", ATA_HORKAGE_NONCQ | | |
172 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
173 | + { "ST3640623AS", "SD19", ATA_HORKAGE_NONCQ | | |
174 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
175 | + | |
176 | + { "ST3640323AS", "SD15", ATA_HORKAGE_NONCQ | | |
177 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
178 | + { "ST3640323AS", "SD16", ATA_HORKAGE_NONCQ | | |
179 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
180 | + { "ST3640323AS", "SD17", ATA_HORKAGE_NONCQ | | |
181 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
182 | + { "ST3640323AS", "SD18", ATA_HORKAGE_NONCQ | | |
183 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
184 | + { "ST3640323AS", "SD19", ATA_HORKAGE_NONCQ | | |
185 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
186 | + | |
187 | + { "ST3320813AS", "SD15", ATA_HORKAGE_NONCQ | | |
188 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
189 | + { "ST3320813AS", "SD16", ATA_HORKAGE_NONCQ | | |
190 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
191 | + { "ST3320813AS", "SD17", ATA_HORKAGE_NONCQ | | |
192 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
193 | + { "ST3320813AS", "SD18", ATA_HORKAGE_NONCQ | | |
194 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
195 | + { "ST3320813AS", "SD19", ATA_HORKAGE_NONCQ | | |
196 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
197 | + | |
198 | + { "ST3320613AS", "SD15", ATA_HORKAGE_NONCQ | | |
199 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
200 | + { "ST3320613AS", "SD16", ATA_HORKAGE_NONCQ | | |
201 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
202 | + { "ST3320613AS", "SD17", ATA_HORKAGE_NONCQ | | |
203 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
204 | + { "ST3320613AS", "SD18", ATA_HORKAGE_NONCQ | | |
205 | + ATA_HORKAGE_FIRMWARE_WARN }, | |
206 | + { "ST3320613AS", "SD19", ATA_HORKAGE_NONCQ | | |
207 | ATA_HORKAGE_FIRMWARE_WARN }, | |
208 | ||
209 | /* Blacklist entries taken from Silicon Image 3124/3132 | |
210 | diff --git a/drivers/char/cp437.uni b/drivers/char/cp437.uni | |
211 | index 1f06889..bc61634 100644 | |
212 | --- a/drivers/char/cp437.uni | |
213 | +++ b/drivers/char/cp437.uni | |
214 | @@ -27,7 +27,7 @@ | |
215 | 0x0c U+2640 | |
216 | 0x0d U+266a | |
217 | 0x0e U+266b | |
218 | -0x0f U+263c | |
219 | +0x0f U+263c U+00a4 | |
220 | 0x10 U+25b6 U+25ba | |
221 | 0x11 U+25c0 U+25c4 | |
222 | 0x12 U+2195 | |
223 | @@ -55,7 +55,7 @@ | |
224 | 0x24 U+0024 | |
225 | 0x25 U+0025 | |
226 | 0x26 U+0026 | |
227 | -0x27 U+0027 | |
228 | +0x27 U+0027 U+00b4 | |
229 | 0x28 U+0028 | |
230 | 0x29 U+0029 | |
231 | 0x2a U+002a | |
232 | @@ -84,7 +84,7 @@ | |
233 | 0x41 U+0041 U+00c0 U+00c1 U+00c2 U+00c3 | |
234 | 0x42 U+0042 | |
235 | 0x43 U+0043 U+00a9 | |
236 | -0x44 U+0044 | |
237 | +0x44 U+0044 U+00d0 | |
238 | 0x45 U+0045 U+00c8 U+00ca U+00cb | |
239 | 0x46 U+0046 | |
240 | 0x47 U+0047 | |
241 | @@ -140,7 +140,7 @@ | |
242 | 0x79 U+0079 U+00fd | |
243 | 0x7a U+007a | |
244 | 0x7b U+007b | |
245 | -0x7c U+007c U+00a5 | |
246 | +0x7c U+007c U+00a6 | |
247 | 0x7d U+007d | |
248 | 0x7e U+007e | |
249 | # | |
250 | @@ -263,10 +263,10 @@ | |
251 | 0xe8 U+03a6 U+00d8 | |
252 | 0xe9 U+0398 | |
253 | 0xea U+03a9 U+2126 | |
254 | -0xeb U+03b4 | |
255 | +0xeb U+03b4 U+00f0 | |
256 | 0xec U+221e | |
257 | 0xed U+03c6 U+00f8 | |
258 | -0xee U+03b5 | |
259 | +0xee U+03b5 U+2208 | |
260 | 0xef U+2229 | |
261 | 0xf0 U+2261 | |
262 | 0xf1 U+00b1 | |
263 | diff --git a/drivers/char/vt.c b/drivers/char/vt.c | |
264 | index 60359c3..d429499 100644 | |
265 | --- a/drivers/char/vt.c | |
266 | +++ b/drivers/char/vt.c | |
267 | @@ -2287,7 +2287,7 @@ rescan_last_byte: | |
268 | continue; /* nothing to display */ | |
269 | } | |
270 | /* Glyph not found */ | |
271 | - if ((!(vc->vc_utf && !vc->vc_disp_ctrl) || c < 128) && !(c & ~charmask)) { | |
272 | + if ((!(vc->vc_utf && !vc->vc_disp_ctrl) && c < 128) && !(c & ~charmask)) { | |
273 | /* In legacy mode use the glyph we get by a 1:1 mapping. | |
274 | This would make absolutely no sense with Unicode in mind, | |
275 | but do this for ASCII characters since a font may lack | |
276 | diff --git a/drivers/char/xilinx_hwicap/buffer_icap.c b/drivers/char/xilinx_hwicap/buffer_icap.c | |
277 | index aa7f796..05d8977 100644 | |
278 | --- a/drivers/char/xilinx_hwicap/buffer_icap.c | |
279 | +++ b/drivers/char/xilinx_hwicap/buffer_icap.c | |
280 | @@ -21,9 +21,6 @@ | |
281 | * INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS | |
282 | * FOR A PARTICULAR PURPOSE. | |
283 | * | |
284 | - * Xilinx products are not intended for use in life support appliances, | |
285 | - * devices, or systems. Use in such applications is expressly prohibited. | |
286 | - * | |
287 | * (c) Copyright 2003-2008 Xilinx Inc. | |
288 | * All rights reserved. | |
289 | * | |
290 | diff --git a/drivers/char/xilinx_hwicap/buffer_icap.h b/drivers/char/xilinx_hwicap/buffer_icap.h | |
291 | index 8b0252b..d4f419e 100644 | |
292 | --- a/drivers/char/xilinx_hwicap/buffer_icap.h | |
293 | +++ b/drivers/char/xilinx_hwicap/buffer_icap.h | |
294 | @@ -21,9 +21,6 @@ | |
295 | * INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS | |
296 | * FOR A PARTICULAR PURPOSE. | |
297 | * | |
298 | - * Xilinx products are not intended for use in life support appliances, | |
299 | - * devices, or systems. Use in such applications is expressly prohibited. | |
300 | - * | |
301 | * (c) Copyright 2003-2008 Xilinx Inc. | |
302 | * All rights reserved. | |
303 | * | |
304 | diff --git a/drivers/char/xilinx_hwicap/fifo_icap.c b/drivers/char/xilinx_hwicap/fifo_icap.c | |
305 | index 776b505..02225eb 100644 | |
306 | --- a/drivers/char/xilinx_hwicap/fifo_icap.c | |
307 | +++ b/drivers/char/xilinx_hwicap/fifo_icap.c | |
308 | @@ -21,9 +21,6 @@ | |
309 | * INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS | |
310 | * FOR A PARTICULAR PURPOSE. | |
311 | * | |
312 | - * Xilinx products are not intended for use in life support appliances, | |
313 | - * devices, or systems. Use in such applications is expressly prohibited. | |
314 | - * | |
315 | * (c) Copyright 2007-2008 Xilinx Inc. | |
316 | * All rights reserved. | |
317 | * | |
318 | diff --git a/drivers/char/xilinx_hwicap/fifo_icap.h b/drivers/char/xilinx_hwicap/fifo_icap.h | |
319 | index 62bda45..4c9dd9a 100644 | |
320 | --- a/drivers/char/xilinx_hwicap/fifo_icap.h | |
321 | +++ b/drivers/char/xilinx_hwicap/fifo_icap.h | |
322 | @@ -21,9 +21,6 @@ | |
323 | * INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS | |
324 | * FOR A PARTICULAR PURPOSE. | |
325 | * | |
326 | - * Xilinx products are not intended for use in life support appliances, | |
327 | - * devices, or systems. Use in such applications is expressly prohibited. | |
328 | - * | |
329 | * (c) Copyright 2007-2008 Xilinx Inc. | |
330 | * All rights reserved. | |
331 | * | |
332 | diff --git a/drivers/char/xilinx_hwicap/xilinx_hwicap.c b/drivers/char/xilinx_hwicap/xilinx_hwicap.c | |
333 | index 278c985..15ead99 100644 | |
334 | --- a/drivers/char/xilinx_hwicap/xilinx_hwicap.c | |
335 | +++ b/drivers/char/xilinx_hwicap/xilinx_hwicap.c | |
336 | @@ -21,9 +21,6 @@ | |
337 | * INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS | |
338 | * FOR A PARTICULAR PURPOSE. | |
339 | * | |
340 | - * Xilinx products are not intended for use in life support appliances, | |
341 | - * devices, or systems. Use in such applications is expressly prohibited. | |
342 | - * | |
343 | * (c) Copyright 2002 Xilinx Inc., Systems Engineering Group | |
344 | * (c) Copyright 2004 Xilinx Inc., Systems Engineering Group | |
345 | * (c) Copyright 2007-2008 Xilinx Inc. | |
346 | diff --git a/drivers/char/xilinx_hwicap/xilinx_hwicap.h b/drivers/char/xilinx_hwicap/xilinx_hwicap.h | |
347 | index 24d0d9b..8cca119 100644 | |
348 | --- a/drivers/char/xilinx_hwicap/xilinx_hwicap.h | |
349 | +++ b/drivers/char/xilinx_hwicap/xilinx_hwicap.h | |
350 | @@ -21,9 +21,6 @@ | |
351 | * INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS | |
352 | * FOR A PARTICULAR PURPOSE. | |
353 | * | |
354 | - * Xilinx products are not intended for use in life support appliances, | |
355 | - * devices, or systems. Use in such applications is expressly prohibited. | |
356 | - * | |
357 | * (c) Copyright 2003-2007 Xilinx Inc. | |
358 | * All rights reserved. | |
359 | * | |
360 | diff --git a/drivers/firewire/fw-ohci.c b/drivers/firewire/fw-ohci.c | |
361 | index 251416f..595759c 100644 | |
362 | --- a/drivers/firewire/fw-ohci.c | |
363 | +++ b/drivers/firewire/fw-ohci.c | |
364 | @@ -958,6 +958,7 @@ at_context_queue_packet(struct context *ctx, struct fw_packet *packet) | |
365 | packet->ack = RCODE_SEND_ERROR; | |
366 | return -1; | |
367 | } | |
368 | + packet->payload_bus = payload_bus; | |
369 | ||
370 | d[2].req_count = cpu_to_le16(packet->payload_length); | |
371 | d[2].data_address = cpu_to_le32(payload_bus); | |
372 | @@ -1009,7 +1010,6 @@ static int handle_at_packet(struct context *context, | |
373 | struct driver_data *driver_data; | |
374 | struct fw_packet *packet; | |
375 | struct fw_ohci *ohci = context->ohci; | |
376 | - dma_addr_t payload_bus; | |
377 | int evt; | |
378 | ||
379 | if (last->transfer_status == 0) | |
380 | @@ -1022,9 +1022,8 @@ static int handle_at_packet(struct context *context, | |
381 | /* This packet was cancelled, just continue. */ | |
382 | return 1; | |
383 | ||
384 | - payload_bus = le32_to_cpu(last->data_address); | |
385 | - if (payload_bus != 0) | |
386 | - dma_unmap_single(ohci->card.device, payload_bus, | |
387 | + if (packet->payload_bus) | |
388 | + dma_unmap_single(ohci->card.device, packet->payload_bus, | |
389 | packet->payload_length, DMA_TO_DEVICE); | |
390 | ||
391 | evt = le16_to_cpu(last->transfer_status) & 0x1f; | |
392 | @@ -1681,6 +1680,10 @@ static int ohci_cancel_packet(struct fw_card *card, struct fw_packet *packet) | |
393 | if (packet->ack != 0) | |
394 | goto out; | |
395 | ||
396 | + if (packet->payload_bus) | |
397 | + dma_unmap_single(ohci->card.device, packet->payload_bus, | |
398 | + packet->payload_length, DMA_TO_DEVICE); | |
399 | + | |
400 | log_ar_at_event('T', packet->speed, packet->header, 0x20); | |
401 | driver_data->packet = NULL; | |
402 | packet->ack = RCODE_CANCELLED; | |
403 | diff --git a/drivers/firewire/fw-transaction.c b/drivers/firewire/fw-transaction.c | |
404 | index e5d1a0b..27f7c7e 100644 | |
405 | --- a/drivers/firewire/fw-transaction.c | |
406 | +++ b/drivers/firewire/fw-transaction.c | |
407 | @@ -207,6 +207,7 @@ fw_fill_request(struct fw_packet *packet, int tcode, int tlabel, | |
408 | packet->speed = speed; | |
409 | packet->generation = generation; | |
410 | packet->ack = 0; | |
411 | + packet->payload_bus = 0; | |
412 | } | |
413 | ||
414 | /** | |
415 | @@ -541,6 +542,8 @@ fw_fill_response(struct fw_packet *response, u32 *request_header, | |
416 | BUG(); | |
417 | return; | |
418 | } | |
419 | + | |
420 | + response->payload_bus = 0; | |
421 | } | |
422 | EXPORT_SYMBOL(fw_fill_response); | |
423 | ||
424 | diff --git a/drivers/firewire/fw-transaction.h b/drivers/firewire/fw-transaction.h | |
425 | index 81b15ba..04cc9b0 100644 | |
426 | --- a/drivers/firewire/fw-transaction.h | |
427 | +++ b/drivers/firewire/fw-transaction.h | |
428 | @@ -27,6 +27,7 @@ | |
429 | #include <linux/list.h> | |
430 | #include <linux/spinlock_types.h> | |
431 | #include <linux/timer.h> | |
432 | +#include <linux/types.h> | |
433 | #include <linux/workqueue.h> | |
434 | ||
435 | #define TCODE_IS_READ_REQUEST(tcode) (((tcode) & ~1) == 4) | |
436 | @@ -153,6 +154,7 @@ struct fw_packet { | |
437 | size_t header_length; | |
438 | void *payload; | |
439 | size_t payload_length; | |
440 | + dma_addr_t payload_bus; | |
441 | u32 timestamp; | |
442 | ||
443 | /* | |
444 | diff --git a/drivers/ieee1394/nodemgr.c b/drivers/ieee1394/nodemgr.c | |
445 | index 16240a7..3d3c3bc 100644 | |
446 | --- a/drivers/ieee1394/nodemgr.c | |
447 | +++ b/drivers/ieee1394/nodemgr.c | |
448 | @@ -115,8 +115,14 @@ static int nodemgr_bus_read(struct csr1212_csr *csr, u64 addr, u16 length, | |
449 | return error; | |
450 | } | |
451 | ||
452 | +#define OUI_FREECOM_TECHNOLOGIES_GMBH 0x0001db | |
453 | + | |
454 | static int nodemgr_get_max_rom(quadlet_t *bus_info_data, void *__ci) | |
455 | { | |
456 | + /* Freecom FireWire Hard Drive firmware bug */ | |
457 | + if (be32_to_cpu(bus_info_data[3]) >> 8 == OUI_FREECOM_TECHNOLOGIES_GMBH) | |
458 | + return 0; | |
459 | + | |
460 | return (be32_to_cpu(bus_info_data[2]) >> 8) & 0x3; | |
461 | } | |
462 | ||
463 | diff --git a/drivers/isdn/hardware/avm/b1isa.c b/drivers/isdn/hardware/avm/b1isa.c | |
464 | index 1e288ee..6461a32 100644 | |
465 | --- a/drivers/isdn/hardware/avm/b1isa.c | |
466 | +++ b/drivers/isdn/hardware/avm/b1isa.c | |
467 | @@ -233,10 +233,8 @@ static void __exit b1isa_exit(void) | |
468 | int i; | |
469 | ||
470 | for (i = 0; i < MAX_CARDS; i++) { | |
471 | - if (!io[i]) | |
472 | - break; | |
473 | - | |
474 | - b1isa_remove(&isa_dev[i]); | |
475 | + if (isa_dev[i].resource[0].start) | |
476 | + b1isa_remove(&isa_dev[i]); | |
477 | } | |
478 | unregister_capi_driver(&capi_driver_b1isa); | |
479 | } | |
480 | diff --git a/drivers/media/video/tvaudio.c b/drivers/media/video/tvaudio.c | |
481 | index d74df58..bec489e 100644 | |
482 | --- a/drivers/media/video/tvaudio.c | |
483 | +++ b/drivers/media/video/tvaudio.c | |
484 | @@ -152,7 +152,7 @@ static int chip_write(struct CHIPSTATE *chip, int subaddr, int val) | |
485 | { | |
486 | unsigned char buffer[2]; | |
487 | ||
488 | - if (-1 == subaddr) { | |
489 | + if (subaddr < 0) { | |
490 | v4l_dbg(1, debug, chip->c, "%s: chip_write: 0x%x\n", | |
491 | chip->c->name, val); | |
492 | chip->shadow.bytes[1] = val; | |
493 | @@ -163,6 +163,13 @@ static int chip_write(struct CHIPSTATE *chip, int subaddr, int val) | |
494 | return -1; | |
495 | } | |
496 | } else { | |
497 | + if (subaddr + 1 >= ARRAY_SIZE(chip->shadow.bytes)) { | |
498 | + v4l_info(chip->c, | |
499 | + "Tried to access a non-existent register: %d\n", | |
500 | + subaddr); | |
501 | + return -EINVAL; | |
502 | + } | |
503 | + | |
504 | v4l_dbg(1, debug, chip->c, "%s: chip_write: reg%d=0x%x\n", | |
505 | chip->c->name, subaddr, val); | |
506 | chip->shadow.bytes[subaddr+1] = val; | |
507 | @@ -177,12 +184,20 @@ static int chip_write(struct CHIPSTATE *chip, int subaddr, int val) | |
508 | return 0; | |
509 | } | |
510 | ||
511 | -static int chip_write_masked(struct CHIPSTATE *chip, int subaddr, int val, int mask) | |
512 | +static int chip_write_masked(struct CHIPSTATE *chip, | |
513 | + int subaddr, int val, int mask) | |
514 | { | |
515 | if (mask != 0) { | |
516 | - if (-1 == subaddr) { | |
517 | + if (subaddr < 0) { | |
518 | val = (chip->shadow.bytes[1] & ~mask) | (val & mask); | |
519 | } else { | |
520 | + if (subaddr + 1 >= ARRAY_SIZE(chip->shadow.bytes)) { | |
521 | + v4l_info(chip->c, | |
522 | + "Tried to access a non-existent register: %d\n", | |
523 | + subaddr); | |
524 | + return -EINVAL; | |
525 | + } | |
526 | + | |
527 | val = (chip->shadow.bytes[subaddr+1] & ~mask) | (val & mask); | |
528 | } | |
529 | } | |
530 | @@ -228,6 +243,15 @@ static int chip_cmd(struct CHIPSTATE *chip, char *name, audiocmd *cmd) | |
531 | if (0 == cmd->count) | |
532 | return 0; | |
533 | ||
534 | + if (cmd->count + cmd->bytes[0] - 1 >= ARRAY_SIZE(chip->shadow.bytes)) { | |
535 | + v4l_info(chip->c, | |
536 | + "Tried to access a non-existent register range: %d to %d\n", | |
537 | + cmd->bytes[0] + 1, cmd->bytes[0] + cmd->count - 1); | |
538 | + return -EINVAL; | |
539 | + } | |
540 | + | |
541 | + /* FIXME: it seems that the shadow bytes are wrong bellow !*/ | |
542 | + | |
543 | /* update our shadow register set; print bytes if (debug > 0) */ | |
544 | v4l_dbg(1, debug, chip->c, "%s: chip_cmd(%s): reg=%d, data:", | |
545 | chip->c->name, name,cmd->bytes[0]); | |
546 | diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c | |
547 | index c792138..1b9c4dc 100644 | |
548 | --- a/drivers/net/bonding/bond_main.c | |
549 | +++ b/drivers/net/bonding/bond_main.c | |
550 | @@ -2370,6 +2370,9 @@ static void bond_miimon_commit(struct bonding *bond) | |
551 | continue; | |
552 | ||
553 | case BOND_LINK_DOWN: | |
554 | + if (slave->link_failure_count < UINT_MAX) | |
555 | + slave->link_failure_count++; | |
556 | + | |
557 | slave->link = BOND_LINK_DOWN; | |
558 | ||
559 | if (bond->params.mode == BOND_MODE_ACTIVEBACKUP || | |
560 | diff --git a/drivers/net/e1000e/ich8lan.c b/drivers/net/e1000e/ich8lan.c | |
561 | index bcd2bc4..79be768 100644 | |
562 | --- a/drivers/net/e1000e/ich8lan.c | |
563 | +++ b/drivers/net/e1000e/ich8lan.c | |
564 | @@ -1791,12 +1791,17 @@ static s32 e1000_reset_hw_ich8lan(struct e1000_hw *hw) | |
565 | ctrl |= E1000_CTRL_PHY_RST; | |
566 | } | |
567 | ret_val = e1000_acquire_swflag_ich8lan(hw); | |
568 | + /* Whether or not the swflag was acquired, we need to reset the part */ | |
569 | hw_dbg(hw, "Issuing a global reset to ich8lan"); | |
570 | ew32(CTRL, (ctrl | E1000_CTRL_RST)); | |
571 | msleep(20); | |
572 | ||
573 | - /* release the swflag because it is not reset by hardware reset */ | |
574 | - e1000_release_swflag_ich8lan(hw); | |
575 | + if (!ret_val) { | |
576 | + /* release the swflag because it is not reset by | |
577 | + * hardware reset | |
578 | + */ | |
579 | + e1000_release_swflag_ich8lan(hw); | |
580 | + } | |
581 | ||
582 | ret_val = e1000e_get_auto_rd_done(hw); | |
583 | if (ret_val) { | |
584 | diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c | |
585 | index cf7056e..79b7ae3 100644 | |
586 | --- a/drivers/net/wireless/iwlwifi/iwl-agn.c | |
587 | +++ b/drivers/net/wireless/iwlwifi/iwl-agn.c | |
588 | @@ -1384,7 +1384,7 @@ void iwl_rx_handle(struct iwl_priv *priv) | |
589 | ||
590 | rxq->queue[i] = NULL; | |
591 | ||
592 | - pci_dma_sync_single_for_cpu(priv->pci_dev, rxb->dma_addr, | |
593 | + pci_dma_sync_single_for_cpu(priv->pci_dev, rxb->aligned_dma_addr, | |
594 | priv->hw_params.rx_buf_size, | |
595 | PCI_DMA_FROMDEVICE); | |
596 | pkt = (struct iwl_rx_packet *)rxb->skb->data; | |
597 | @@ -1436,8 +1436,8 @@ void iwl_rx_handle(struct iwl_priv *priv) | |
598 | rxb->skb = NULL; | |
599 | } | |
600 | ||
601 | - pci_unmap_single(priv->pci_dev, rxb->dma_addr, | |
602 | - priv->hw_params.rx_buf_size, | |
603 | + pci_unmap_single(priv->pci_dev, rxb->real_dma_addr, | |
604 | + priv->hw_params.rx_buf_size + 256, | |
605 | PCI_DMA_FROMDEVICE); | |
606 | spin_lock_irqsave(&rxq->lock, flags); | |
607 | list_add_tail(&rxb->list, &priv->rxq.rx_used); | |
608 | diff --git a/drivers/net/wireless/iwlwifi/iwl-core.c b/drivers/net/wireless/iwlwifi/iwl-core.c | |
609 | index 1383fd1..b346268 100644 | |
610 | --- a/drivers/net/wireless/iwlwifi/iwl-core.c | |
611 | +++ b/drivers/net/wireless/iwlwifi/iwl-core.c | |
612 | @@ -290,6 +290,9 @@ void iwl_clear_stations_table(struct iwl_priv *priv) | |
613 | priv->num_stations = 0; | |
614 | memset(priv->stations, 0, sizeof(priv->stations)); | |
615 | ||
616 | + /* clean ucode key table bit map */ | |
617 | + priv->ucode_key_table = 0; | |
618 | + | |
619 | spin_unlock_irqrestore(&priv->sta_lock, flags); | |
620 | } | |
621 | EXPORT_SYMBOL(iwl_clear_stations_table); | |
622 | diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wireless/iwlwifi/iwl-dev.h | |
623 | index 09bdf8e..cf7757f 100644 | |
624 | --- a/drivers/net/wireless/iwlwifi/iwl-dev.h | |
625 | +++ b/drivers/net/wireless/iwlwifi/iwl-dev.h | |
626 | @@ -89,7 +89,8 @@ extern struct iwl_cfg iwl5100_abg_cfg; | |
627 | #define DEFAULT_LONG_RETRY_LIMIT 4U | |
628 | ||
629 | struct iwl_rx_mem_buffer { | |
630 | - dma_addr_t dma_addr; | |
631 | + dma_addr_t real_dma_addr; | |
632 | + dma_addr_t aligned_dma_addr; | |
633 | struct sk_buff *skb; | |
634 | struct list_head list; | |
635 | }; | |
636 | diff --git a/drivers/net/wireless/iwlwifi/iwl-rx.c b/drivers/net/wireless/iwlwifi/iwl-rx.c | |
637 | index e81bfc4..ce25379 100644 | |
638 | --- a/drivers/net/wireless/iwlwifi/iwl-rx.c | |
639 | +++ b/drivers/net/wireless/iwlwifi/iwl-rx.c | |
640 | @@ -204,7 +204,7 @@ int iwl_rx_queue_restock(struct iwl_priv *priv) | |
641 | list_del(element); | |
642 | ||
643 | /* Point to Rx buffer via next RBD in circular buffer */ | |
644 | - rxq->bd[rxq->write] = iwl_dma_addr2rbd_ptr(priv, rxb->dma_addr); | |
645 | + rxq->bd[rxq->write] = iwl_dma_addr2rbd_ptr(priv, rxb->aligned_dma_addr); | |
646 | rxq->queue[rxq->write] = rxb; | |
647 | rxq->write = (rxq->write + 1) & RX_QUEUE_MASK; | |
648 | rxq->free_count--; | |
649 | @@ -251,7 +251,7 @@ void iwl_rx_allocate(struct iwl_priv *priv) | |
650 | rxb = list_entry(element, struct iwl_rx_mem_buffer, list); | |
651 | ||
652 | /* Alloc a new receive buffer */ | |
653 | - rxb->skb = alloc_skb(priv->hw_params.rx_buf_size, | |
654 | + rxb->skb = alloc_skb(priv->hw_params.rx_buf_size + 256, | |
655 | __GFP_NOWARN | GFP_ATOMIC); | |
656 | if (!rxb->skb) { | |
657 | if (net_ratelimit()) | |
658 | @@ -266,9 +266,17 @@ void iwl_rx_allocate(struct iwl_priv *priv) | |
659 | list_del(element); | |
660 | ||
661 | /* Get physical address of RB/SKB */ | |
662 | - rxb->dma_addr = | |
663 | - pci_map_single(priv->pci_dev, rxb->skb->data, | |
664 | - priv->hw_params.rx_buf_size, PCI_DMA_FROMDEVICE); | |
665 | + rxb->real_dma_addr = pci_map_single( | |
666 | + priv->pci_dev, | |
667 | + rxb->skb->data, | |
668 | + priv->hw_params.rx_buf_size + 256, | |
669 | + PCI_DMA_FROMDEVICE); | |
670 | + /* dma address must be no more than 36 bits */ | |
671 | + BUG_ON(rxb->real_dma_addr & ~DMA_BIT_MASK(36)); | |
672 | + /* and also 256 byte aligned! */ | |
673 | + rxb->aligned_dma_addr = ALIGN(rxb->real_dma_addr, 256); | |
674 | + skb_reserve(rxb->skb, rxb->aligned_dma_addr - rxb->real_dma_addr); | |
675 | + | |
676 | list_add_tail(&rxb->list, &rxq->rx_free); | |
677 | rxq->free_count++; | |
678 | } | |
679 | @@ -300,8 +308,8 @@ void iwl_rx_queue_free(struct iwl_priv *priv, struct iwl_rx_queue *rxq) | |
680 | for (i = 0; i < RX_QUEUE_SIZE + RX_FREE_BUFFERS; i++) { | |
681 | if (rxq->pool[i].skb != NULL) { | |
682 | pci_unmap_single(priv->pci_dev, | |
683 | - rxq->pool[i].dma_addr, | |
684 | - priv->hw_params.rx_buf_size, | |
685 | + rxq->pool[i].real_dma_addr, | |
686 | + priv->hw_params.rx_buf_size + 256, | |
687 | PCI_DMA_FROMDEVICE); | |
688 | dev_kfree_skb(rxq->pool[i].skb); | |
689 | } | |
690 | @@ -354,8 +362,8 @@ void iwl_rx_queue_reset(struct iwl_priv *priv, struct iwl_rx_queue *rxq) | |
691 | * to an SKB, so we need to unmap and free potential storage */ | |
692 | if (rxq->pool[i].skb != NULL) { | |
693 | pci_unmap_single(priv->pci_dev, | |
694 | - rxq->pool[i].dma_addr, | |
695 | - priv->hw_params.rx_buf_size, | |
696 | + rxq->pool[i].real_dma_addr, | |
697 | + priv->hw_params.rx_buf_size + 256, | |
698 | PCI_DMA_FROMDEVICE); | |
699 | priv->alloc_rxb_skb--; | |
700 | dev_kfree_skb(rxq->pool[i].skb); | |
701 | diff --git a/drivers/net/wireless/iwlwifi/iwl-sta.c b/drivers/net/wireless/iwlwifi/iwl-sta.c | |
702 | index 6283a3a..f2d473c 100644 | |
703 | --- a/drivers/net/wireless/iwlwifi/iwl-sta.c | |
704 | +++ b/drivers/net/wireless/iwlwifi/iwl-sta.c | |
705 | @@ -475,7 +475,7 @@ static int iwl_get_free_ucode_key_index(struct iwl_priv *priv) | |
706 | if (!test_and_set_bit(i, &priv->ucode_key_table)) | |
707 | return i; | |
708 | ||
709 | - return -1; | |
710 | + return WEP_INVALID_OFFSET; | |
711 | } | |
712 | ||
713 | int iwl_send_static_wepkey_cmd(struct iwl_priv *priv, u8 send_if_empty) | |
714 | @@ -620,6 +620,9 @@ static int iwl_set_wep_dynamic_key_info(struct iwl_priv *priv, | |
715 | /* else, we are overriding an existing key => no need to allocated room | |
716 | * in uCode. */ | |
717 | ||
718 | + WARN(priv->stations[sta_id].sta.key.key_offset == WEP_INVALID_OFFSET, | |
719 | + "no space for new kew"); | |
720 | + | |
721 | priv->stations[sta_id].sta.key.key_flags = key_flags; | |
722 | priv->stations[sta_id].sta.sta.modify_mask = STA_MODIFY_KEY_MASK; | |
723 | priv->stations[sta_id].sta.mode = STA_CONTROL_MODIFY_MSK; | |
724 | @@ -637,6 +640,7 @@ static int iwl_set_ccmp_dynamic_key_info(struct iwl_priv *priv, | |
725 | { | |
726 | unsigned long flags; | |
727 | __le16 key_flags = 0; | |
728 | + int ret; | |
729 | ||
730 | key_flags |= (STA_KEY_FLG_CCMP | STA_KEY_FLG_MAP_KEY_MSK); | |
731 | key_flags |= cpu_to_le16(keyconf->keyidx << STA_KEY_FLG_KEYID_POS); | |
732 | @@ -664,14 +668,18 @@ static int iwl_set_ccmp_dynamic_key_info(struct iwl_priv *priv, | |
733 | /* else, we are overriding an existing key => no need to allocated room | |
734 | * in uCode. */ | |
735 | ||
736 | + WARN(priv->stations[sta_id].sta.key.key_offset == WEP_INVALID_OFFSET, | |
737 | + "no space for new kew"); | |
738 | + | |
739 | priv->stations[sta_id].sta.key.key_flags = key_flags; | |
740 | priv->stations[sta_id].sta.sta.modify_mask = STA_MODIFY_KEY_MASK; | |
741 | priv->stations[sta_id].sta.mode = STA_CONTROL_MODIFY_MSK; | |
742 | ||
743 | + ret = iwl_send_add_sta(priv, &priv->stations[sta_id].sta, CMD_ASYNC); | |
744 | + | |
745 | spin_unlock_irqrestore(&priv->sta_lock, flags); | |
746 | ||
747 | - IWL_DEBUG_INFO("hwcrypto: modify ucode station key info\n"); | |
748 | - return iwl_send_add_sta(priv, &priv->stations[sta_id].sta, CMD_ASYNC); | |
749 | + return ret; | |
750 | } | |
751 | ||
752 | static int iwl_set_tkip_dynamic_key_info(struct iwl_priv *priv, | |
753 | @@ -696,6 +704,9 @@ static int iwl_set_tkip_dynamic_key_info(struct iwl_priv *priv, | |
754 | /* else, we are overriding an existing key => no need to allocated room | |
755 | * in uCode. */ | |
756 | ||
757 | + WARN(priv->stations[sta_id].sta.key.key_offset == WEP_INVALID_OFFSET, | |
758 | + "no space for new kew"); | |
759 | + | |
760 | /* This copy is acutally not needed: we get the key with each TX */ | |
761 | memcpy(priv->stations[sta_id].keyinfo.key, keyconf->key, 16); | |
762 | ||
763 | @@ -734,6 +745,13 @@ int iwl_remove_dynamic_key(struct iwl_priv *priv, | |
764 | return 0; | |
765 | } | |
766 | ||
767 | + if (priv->stations[sta_id].sta.key.key_offset == WEP_INVALID_OFFSET) { | |
768 | + IWL_WARNING("Removing wrong key %d 0x%x\n", | |
769 | + keyconf->keyidx, key_flags); | |
770 | + spin_unlock_irqrestore(&priv->sta_lock, flags); | |
771 | + return 0; | |
772 | + } | |
773 | + | |
774 | if (!test_and_clear_bit(priv->stations[sta_id].sta.key.key_offset, | |
775 | &priv->ucode_key_table)) | |
776 | IWL_ERROR("index %d not used in uCode key table.\n", | |
777 | diff --git a/drivers/video/macfb.c b/drivers/video/macfb.c | |
778 | index b790ddf..ee380d5 100644 | |
779 | --- a/drivers/video/macfb.c | |
780 | +++ b/drivers/video/macfb.c | |
781 | @@ -164,7 +164,6 @@ static struct fb_var_screeninfo macfb_defined = { | |
782 | }; | |
783 | ||
784 | static struct fb_fix_screeninfo macfb_fix = { | |
785 | - .id = "Macintosh ", | |
786 | .type = FB_TYPE_PACKED_PIXELS, | |
787 | .accel = FB_ACCEL_NONE, | |
788 | }; | |
789 | @@ -760,22 +759,22 @@ static int __init macfb_init(void) | |
790 | ||
791 | switch(ndev->dr_hw) { | |
792 | case NUBUS_DRHW_APPLE_MDC: | |
793 | - strcat( macfb_fix.id, "Display Card" ); | |
794 | + strcpy(macfb_fix.id, "Mac Disp. Card"); | |
795 | macfb_setpalette = mdc_setpalette; | |
796 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
797 | break; | |
798 | case NUBUS_DRHW_APPLE_TFB: | |
799 | - strcat( macfb_fix.id, "Toby" ); | |
800 | + strcpy(macfb_fix.id, "Toby"); | |
801 | macfb_setpalette = toby_setpalette; | |
802 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
803 | break; | |
804 | case NUBUS_DRHW_APPLE_JET: | |
805 | - strcat( macfb_fix.id, "Jet"); | |
806 | + strcpy(macfb_fix.id, "Jet"); | |
807 | macfb_setpalette = jet_setpalette; | |
808 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
809 | break; | |
810 | default: | |
811 | - strcat( macfb_fix.id, "Generic NuBus" ); | |
812 | + strcpy(macfb_fix.id, "Generic NuBus"); | |
813 | break; | |
814 | } | |
815 | } | |
816 | @@ -786,21 +785,11 @@ static int __init macfb_init(void) | |
817 | if (!video_is_nubus) | |
818 | switch( mac_bi_data.id ) | |
819 | { | |
820 | - /* These don't have onboard video. Eventually, we may | |
821 | - be able to write separate framebuffer drivers for | |
822 | - them (tobyfb.c, hiresfb.c, etc, etc) */ | |
823 | - case MAC_MODEL_II: | |
824 | - case MAC_MODEL_IIX: | |
825 | - case MAC_MODEL_IICX: | |
826 | - case MAC_MODEL_IIFX: | |
827 | - strcat( macfb_fix.id, "Generic NuBus" ); | |
828 | - break; | |
829 | - | |
830 | /* Valkyrie Quadras */ | |
831 | case MAC_MODEL_Q630: | |
832 | /* I'm not sure about this one */ | |
833 | case MAC_MODEL_P588: | |
834 | - strcat( macfb_fix.id, "Valkyrie built-in" ); | |
835 | + strcpy(macfb_fix.id, "Valkyrie"); | |
836 | macfb_setpalette = valkyrie_setpalette; | |
837 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
838 | valkyrie_cmap_regs = ioremap(DAC_BASE, 0x1000); | |
839 | @@ -823,7 +812,7 @@ static int __init macfb_init(void) | |
840 | case MAC_MODEL_Q700: | |
841 | case MAC_MODEL_Q900: | |
842 | case MAC_MODEL_Q950: | |
843 | - strcat( macfb_fix.id, "DAFB built-in" ); | |
844 | + strcpy(macfb_fix.id, "DAFB"); | |
845 | macfb_setpalette = dafb_setpalette; | |
846 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
847 | dafb_cmap_regs = ioremap(DAFB_BASE, 0x1000); | |
848 | @@ -831,7 +820,7 @@ static int __init macfb_init(void) | |
849 | ||
850 | /* LC II uses the V8 framebuffer */ | |
851 | case MAC_MODEL_LCII: | |
852 | - strcat( macfb_fix.id, "V8 built-in" ); | |
853 | + strcpy(macfb_fix.id, "V8"); | |
854 | macfb_setpalette = v8_brazil_setpalette; | |
855 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
856 | v8_brazil_cmap_regs = ioremap(DAC_BASE, 0x1000); | |
857 | @@ -843,7 +832,7 @@ static int __init macfb_init(void) | |
858 | case MAC_MODEL_IIVI: | |
859 | case MAC_MODEL_IIVX: | |
860 | case MAC_MODEL_P600: | |
861 | - strcat( macfb_fix.id, "Brazil built-in" ); | |
862 | + strcpy(macfb_fix.id, "Brazil"); | |
863 | macfb_setpalette = v8_brazil_setpalette; | |
864 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
865 | v8_brazil_cmap_regs = ioremap(DAC_BASE, 0x1000); | |
866 | @@ -860,7 +849,7 @@ static int __init macfb_init(void) | |
867 | case MAC_MODEL_P460: | |
868 | macfb_setpalette = v8_brazil_setpalette; | |
869 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
870 | - strcat( macfb_fix.id, "Sonora built-in" ); | |
871 | + strcpy(macfb_fix.id, "Sonora"); | |
872 | v8_brazil_cmap_regs = ioremap(DAC_BASE, 0x1000); | |
873 | break; | |
874 | ||
875 | @@ -871,7 +860,7 @@ static int __init macfb_init(void) | |
876 | case MAC_MODEL_IISI: | |
877 | macfb_setpalette = rbv_setpalette; | |
878 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
879 | - strcat( macfb_fix.id, "RBV built-in" ); | |
880 | + strcpy(macfb_fix.id, "RBV"); | |
881 | rbv_cmap_regs = ioremap(DAC_BASE, 0x1000); | |
882 | break; | |
883 | ||
884 | @@ -880,7 +869,7 @@ static int __init macfb_init(void) | |
885 | case MAC_MODEL_C660: | |
886 | macfb_setpalette = civic_setpalette; | |
887 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
888 | - strcat( macfb_fix.id, "Civic built-in" ); | |
889 | + strcpy(macfb_fix.id, "Civic"); | |
890 | civic_cmap_regs = ioremap(CIVIC_BASE, 0x1000); | |
891 | break; | |
892 | ||
893 | @@ -901,7 +890,7 @@ static int __init macfb_init(void) | |
894 | v8_brazil_cmap_regs = | |
895 | ioremap(DAC_BASE, 0x1000); | |
896 | } | |
897 | - strcat( macfb_fix.id, "LC built-in" ); | |
898 | + strcpy(macfb_fix.id, "LC"); | |
899 | break; | |
900 | /* We think this may be like the LC II */ | |
901 | case MAC_MODEL_CCL: | |
902 | @@ -911,18 +900,18 @@ static int __init macfb_init(void) | |
903 | v8_brazil_cmap_regs = | |
904 | ioremap(DAC_BASE, 0x1000); | |
905 | } | |
906 | - strcat( macfb_fix.id, "Color Classic built-in" ); | |
907 | + strcpy(macfb_fix.id, "Color Classic"); | |
908 | break; | |
909 | ||
910 | /* And we *do* mean "weirdos" */ | |
911 | case MAC_MODEL_TV: | |
912 | - strcat( macfb_fix.id, "Mac TV built-in" ); | |
913 | + strcpy(macfb_fix.id, "Mac TV"); | |
914 | break; | |
915 | ||
916 | /* These don't have colour, so no need to worry */ | |
917 | case MAC_MODEL_SE30: | |
918 | case MAC_MODEL_CLII: | |
919 | - strcat( macfb_fix.id, "Monochrome built-in" ); | |
920 | + strcpy(macfb_fix.id, "Monochrome"); | |
921 | break; | |
922 | ||
923 | /* Powerbooks are particularly difficult. Many of | |
924 | @@ -935,7 +924,7 @@ static int __init macfb_init(void) | |
925 | case MAC_MODEL_PB140: | |
926 | case MAC_MODEL_PB145: | |
927 | case MAC_MODEL_PB170: | |
928 | - strcat( macfb_fix.id, "DDC built-in" ); | |
929 | + strcpy(macfb_fix.id, "DDC"); | |
930 | break; | |
931 | ||
932 | /* Internal is GSC, External (if present) is ViSC */ | |
933 | @@ -945,13 +934,13 @@ static int __init macfb_init(void) | |
934 | case MAC_MODEL_PB180: | |
935 | case MAC_MODEL_PB210: | |
936 | case MAC_MODEL_PB230: | |
937 | - strcat( macfb_fix.id, "GSC built-in" ); | |
938 | + strcpy(macfb_fix.id, "GSC"); | |
939 | break; | |
940 | ||
941 | /* Internal is TIM, External is ViSC */ | |
942 | case MAC_MODEL_PB165C: | |
943 | case MAC_MODEL_PB180C: | |
944 | - strcat( macfb_fix.id, "TIM built-in" ); | |
945 | + strcpy(macfb_fix.id, "TIM"); | |
946 | break; | |
947 | ||
948 | /* Internal is CSC, External is Keystone+Ariel. */ | |
949 | @@ -963,12 +952,12 @@ static int __init macfb_init(void) | |
950 | case MAC_MODEL_PB280C: | |
951 | macfb_setpalette = csc_setpalette; | |
952 | macfb_defined.activate = FB_ACTIVATE_NOW; | |
953 | - strcat( macfb_fix.id, "CSC built-in" ); | |
954 | + strcpy(macfb_fix.id, "CSC"); | |
955 | csc_cmap_regs = ioremap(CSC_BASE, 0x1000); | |
956 | break; | |
957 | ||
958 | default: | |
959 | - strcat( macfb_fix.id, "Unknown/Unsupported built-in" ); | |
960 | + strcpy(macfb_fix.id, "Unknown"); | |
961 | break; | |
962 | } | |
963 | ||
964 | @@ -978,16 +967,23 @@ static int __init macfb_init(void) | |
965 | fb_info.pseudo_palette = pseudo_palette; | |
966 | fb_info.flags = FBINFO_DEFAULT; | |
967 | ||
968 | - fb_alloc_cmap(&fb_info.cmap, video_cmap_len, 0); | |
969 | + err = fb_alloc_cmap(&fb_info.cmap, video_cmap_len, 0); | |
970 | + if (err) | |
971 | + goto fail_unmap; | |
972 | ||
973 | err = register_framebuffer(&fb_info); | |
974 | - if (!err) | |
975 | - printk("fb%d: %s frame buffer device\n", | |
976 | - fb_info.node, fb_info.fix.id); | |
977 | - else { | |
978 | - iounmap(fb_info.screen_base); | |
979 | - iounmap_macfb(); | |
980 | - } | |
981 | + if (err) | |
982 | + goto fail_dealloc; | |
983 | + | |
984 | + printk("fb%d: %s frame buffer device\n", | |
985 | + fb_info.node, fb_info.fix.id); | |
986 | + return 0; | |
987 | + | |
988 | +fail_dealloc: | |
989 | + fb_dealloc_cmap(&fb_info.cmap); | |
990 | +fail_unmap: | |
991 | + iounmap(fb_info.screen_base); | |
992 | + iounmap_macfb(); | |
993 | return err; | |
994 | } | |
995 | ||
996 | diff --git a/include/asm-x86/vmi.h b/include/asm-x86/vmi.h | |
997 | index b7c0dea..61e08c0 100644 | |
998 | --- a/include/asm-x86/vmi.h | |
999 | +++ b/include/asm-x86/vmi.h | |
1000 | @@ -223,9 +223,15 @@ struct pci_header { | |
1001 | } __attribute__((packed)); | |
1002 | ||
1003 | /* Function prototypes for bootstrapping */ | |
1004 | +#ifdef CONFIG_VMI | |
1005 | extern void vmi_init(void); | |
1006 | +extern void vmi_activate(void); | |
1007 | extern void vmi_bringup(void); | |
1008 | -extern void vmi_apply_boot_page_allocations(void); | |
1009 | +#else | |
1010 | +static inline void vmi_init(void) {} | |
1011 | +static inline void vmi_activate(void) {} | |
1012 | +static inline void vmi_bringup(void) {} | |
1013 | +#endif | |
1014 | ||
1015 | /* State needed to start an application processor in an SMP system. */ | |
1016 | struct vmi_ap_state { | |
1017 | diff --git a/include/linux/can/core.h b/include/linux/can/core.h | |
1018 | index e9ca210..f50785a 100644 | |
1019 | --- a/include/linux/can/core.h | |
1020 | +++ b/include/linux/can/core.h | |
1021 | @@ -19,7 +19,7 @@ | |
1022 | #include <linux/skbuff.h> | |
1023 | #include <linux/netdevice.h> | |
1024 | ||
1025 | -#define CAN_VERSION "20071116" | |
1026 | +#define CAN_VERSION "20081130" | |
1027 | ||
1028 | /* increment this number each time you change some user-space interface */ | |
1029 | #define CAN_ABI_VERSION "8" | |
1030 | diff --git a/kernel/sched_clock.c b/kernel/sched_clock.c | |
1031 | index 8178724..e8ab096 100644 | |
1032 | --- a/kernel/sched_clock.c | |
1033 | +++ b/kernel/sched_clock.c | |
1034 | @@ -118,13 +118,13 @@ static u64 __update_sched_clock(struct sched_clock_data *scd, u64 now) | |
1035 | ||
1036 | /* | |
1037 | * scd->clock = clamp(scd->tick_gtod + delta, | |
1038 | - * max(scd->tick_gtod, scd->clock), | |
1039 | - * max(scd->clock, scd->tick_gtod + TICK_NSEC)); | |
1040 | + * max(scd->tick_gtod, scd->clock), | |
1041 | + * scd->tick_gtod + TICK_NSEC); | |
1042 | */ | |
1043 | ||
1044 | clock = scd->tick_gtod + delta; | |
1045 | min_clock = wrap_max(scd->tick_gtod, scd->clock); | |
1046 | - max_clock = wrap_max(scd->clock, scd->tick_gtod + TICK_NSEC); | |
1047 | + max_clock = scd->tick_gtod + TICK_NSEC; | |
1048 | ||
1049 | clock = wrap_max(clock, min_clock); | |
1050 | clock = wrap_min(clock, max_clock); | |
1051 | diff --git a/lib/idr.c b/lib/idr.c | |
1052 | index 7a785a0..1c4f928 100644 | |
1053 | --- a/lib/idr.c | |
1054 | +++ b/lib/idr.c | |
1055 | @@ -220,8 +220,14 @@ build_up: | |
1056 | */ | |
1057 | while ((layers < (MAX_LEVEL - 1)) && (id >= (1 << (layers*IDR_BITS)))) { | |
1058 | layers++; | |
1059 | - if (!p->count) | |
1060 | + if (!p->count) { | |
1061 | + /* special case: if the tree is currently empty, | |
1062 | + * then we grow the tree by moving the top node | |
1063 | + * upwards. | |
1064 | + */ | |
1065 | + p->layer++; | |
1066 | continue; | |
1067 | + } | |
1068 | if (!(new = get_from_free_list(idp))) { | |
1069 | /* | |
1070 | * The allocation failed. If we built part of | |
1071 | diff --git a/mm/page_alloc.c b/mm/page_alloc.c | |
1072 | index ed5cdae..51daae5 100644 | |
1073 | --- a/mm/page_alloc.c | |
1074 | +++ b/mm/page_alloc.c | |
1075 | @@ -4224,7 +4224,7 @@ void setup_per_zone_pages_min(void) | |
1076 | for_each_zone(zone) { | |
1077 | u64 tmp; | |
1078 | ||
1079 | - spin_lock_irqsave(&zone->lru_lock, flags); | |
1080 | + spin_lock_irqsave(&zone->lock, flags); | |
1081 | tmp = (u64)pages_min * zone->present_pages; | |
1082 | do_div(tmp, lowmem_pages); | |
1083 | if (is_highmem(zone)) { | |
1084 | @@ -4256,7 +4256,7 @@ void setup_per_zone_pages_min(void) | |
1085 | zone->pages_low = zone->pages_min + (tmp >> 2); | |
1086 | zone->pages_high = zone->pages_min + (tmp >> 1); | |
1087 | setup_zone_migrate_reserve(zone); | |
1088 | - spin_unlock_irqrestore(&zone->lru_lock, flags); | |
1089 | + spin_unlock_irqrestore(&zone->lock, flags); | |
1090 | } | |
1091 | ||
1092 | /* update totalreserve_pages */ | |
1093 | diff --git a/net/can/af_can.c b/net/can/af_can.c | |
1094 | index 8035fbf..150f0b2 100644 | |
1095 | --- a/net/can/af_can.c | |
1096 | +++ b/net/can/af_can.c | |
1097 | @@ -319,23 +319,52 @@ static struct dev_rcv_lists *find_dev_rcv_lists(struct net_device *dev) | |
1098 | return n ? d : NULL; | |
1099 | } | |
1100 | ||
1101 | +/** | |
1102 | + * find_rcv_list - determine optimal filterlist inside device filter struct | |
1103 | + * @can_id: pointer to CAN identifier of a given can_filter | |
1104 | + * @mask: pointer to CAN mask of a given can_filter | |
1105 | + * @d: pointer to the device filter struct | |
1106 | + * | |
1107 | + * Description: | |
1108 | + * Returns the optimal filterlist to reduce the filter handling in the | |
1109 | + * receive path. This function is called by service functions that need | |
1110 | + * to register or unregister a can_filter in the filter lists. | |
1111 | + * | |
1112 | + * A filter matches in general, when | |
1113 | + * | |
1114 | + * <received_can_id> & mask == can_id & mask | |
1115 | + * | |
1116 | + * so every bit set in the mask (even CAN_EFF_FLAG, CAN_RTR_FLAG) describe | |
1117 | + * relevant bits for the filter. | |
1118 | + * | |
1119 | + * The filter can be inverted (CAN_INV_FILTER bit set in can_id) or it can | |
1120 | + * filter for error frames (CAN_ERR_FLAG bit set in mask). For error frames | |
1121 | + * there is a special filterlist and a special rx path filter handling. | |
1122 | + * | |
1123 | + * Return: | |
1124 | + * Pointer to optimal filterlist for the given can_id/mask pair. | |
1125 | + * Constistency checked mask. | |
1126 | + * Reduced can_id to have a preprocessed filter compare value. | |
1127 | + */ | |
1128 | static struct hlist_head *find_rcv_list(canid_t *can_id, canid_t *mask, | |
1129 | struct dev_rcv_lists *d) | |
1130 | { | |
1131 | canid_t inv = *can_id & CAN_INV_FILTER; /* save flag before masking */ | |
1132 | ||
1133 | - /* filter error frames */ | |
1134 | + /* filter for error frames in extra filterlist */ | |
1135 | if (*mask & CAN_ERR_FLAG) { | |
1136 | - /* clear CAN_ERR_FLAG in list entry */ | |
1137 | + /* clear CAN_ERR_FLAG in filter entry */ | |
1138 | *mask &= CAN_ERR_MASK; | |
1139 | return &d->rx[RX_ERR]; | |
1140 | } | |
1141 | ||
1142 | - /* ensure valid values in can_mask */ | |
1143 | - if (*mask & CAN_EFF_FLAG) | |
1144 | - *mask &= (CAN_EFF_MASK | CAN_EFF_FLAG | CAN_RTR_FLAG); | |
1145 | - else | |
1146 | - *mask &= (CAN_SFF_MASK | CAN_RTR_FLAG); | |
1147 | + /* with cleared CAN_ERR_FLAG we have a simple mask/value filterpair */ | |
1148 | + | |
1149 | +#define CAN_EFF_RTR_FLAGS (CAN_EFF_FLAG | CAN_RTR_FLAG) | |
1150 | + | |
1151 | + /* ensure valid values in can_mask for 'SFF only' frame filtering */ | |
1152 | + if ((*mask & CAN_EFF_FLAG) && !(*can_id & CAN_EFF_FLAG)) | |
1153 | + *mask &= (CAN_SFF_MASK | CAN_EFF_RTR_FLAGS); | |
1154 | ||
1155 | /* reduce condition testing at receive time */ | |
1156 | *can_id &= *mask; | |
1157 | @@ -348,15 +377,19 @@ static struct hlist_head *find_rcv_list(canid_t *can_id, canid_t *mask, | |
1158 | if (!(*mask)) | |
1159 | return &d->rx[RX_ALL]; | |
1160 | ||
1161 | - /* use extra filterset for the subscription of exactly *ONE* can_id */ | |
1162 | - if (*can_id & CAN_EFF_FLAG) { | |
1163 | - if (*mask == (CAN_EFF_MASK | CAN_EFF_FLAG)) { | |
1164 | - /* RFC: a use-case for hash-tables in the future? */ | |
1165 | - return &d->rx[RX_EFF]; | |
1166 | + /* extra filterlists for the subscription of a single non-RTR can_id */ | |
1167 | + if (((*mask & CAN_EFF_RTR_FLAGS) == CAN_EFF_RTR_FLAGS) | |
1168 | + && !(*can_id & CAN_RTR_FLAG)) { | |
1169 | + | |
1170 | + if (*can_id & CAN_EFF_FLAG) { | |
1171 | + if (*mask == (CAN_EFF_MASK | CAN_EFF_RTR_FLAGS)) { | |
1172 | + /* RFC: a future use-case for hash-tables? */ | |
1173 | + return &d->rx[RX_EFF]; | |
1174 | + } | |
1175 | + } else { | |
1176 | + if (*mask == (CAN_SFF_MASK | CAN_EFF_RTR_FLAGS)) | |
1177 | + return &d->rx_sff[*can_id]; | |
1178 | } | |
1179 | - } else { | |
1180 | - if (*mask == CAN_SFF_MASK) | |
1181 | - return &d->rx_sff[*can_id]; | |
1182 | } | |
1183 | ||
1184 | /* default: filter via can_id/can_mask */ | |
1185 | @@ -589,7 +622,10 @@ static int can_rcv_filter(struct dev_rcv_lists *d, struct sk_buff *skb) | |
1186 | } | |
1187 | } | |
1188 | ||
1189 | - /* check CAN_ID specific entries */ | |
1190 | + /* check filterlists for single non-RTR can_ids */ | |
1191 | + if (can_id & CAN_RTR_FLAG) | |
1192 | + return matches; | |
1193 | + | |
1194 | if (can_id & CAN_EFF_FLAG) { | |
1195 | hlist_for_each_entry_rcu(r, n, &d->rx[RX_EFF], list) { | |
1196 | if (r->can_id == can_id) { | |
1197 | diff --git a/net/can/bcm.c b/net/can/bcm.c | |
1198 | index d0dd382..da0d426 100644 | |
1199 | --- a/net/can/bcm.c | |
1200 | +++ b/net/can/bcm.c | |
1201 | @@ -64,10 +64,11 @@ | |
1202 | #define BCM_CAN_DLC_MASK 0x0F /* clean private flags in can_dlc by masking */ | |
1203 | ||
1204 | /* get best masking value for can_rx_register() for a given single can_id */ | |
1205 | -#define REGMASK(id) ((id & CAN_RTR_FLAG) | ((id & CAN_EFF_FLAG) ? \ | |
1206 | - (CAN_EFF_MASK | CAN_EFF_FLAG) : CAN_SFF_MASK)) | |
1207 | +#define REGMASK(id) ((id & CAN_EFF_FLAG) ? \ | |
1208 | + (CAN_EFF_MASK | CAN_EFF_FLAG | CAN_RTR_FLAG) : \ | |
1209 | + (CAN_SFF_MASK | CAN_EFF_FLAG | CAN_RTR_FLAG)) | |
1210 | ||
1211 | -#define CAN_BCM_VERSION "20080415" | |
1212 | +#define CAN_BCM_VERSION CAN_VERSION | |
1213 | static __initdata const char banner[] = KERN_INFO | |
1214 | "can: broadcast manager protocol (rev " CAN_BCM_VERSION ")\n"; | |
1215 | ||
1216 | diff --git a/net/core/dev.c b/net/core/dev.c | |
1217 | index 0ae08d3..5a25896 100644 | |
1218 | --- a/net/core/dev.c | |
1219 | +++ b/net/core/dev.c | |
1220 | @@ -3990,7 +3990,7 @@ int register_netdevice(struct net_device *dev) | |
1221 | dev->features &= ~NETIF_F_TSO; | |
1222 | } | |
1223 | if (dev->features & NETIF_F_UFO) { | |
1224 | - if (!(dev->features & NETIF_F_HW_CSUM)) { | |
1225 | + if (!(dev->features & NETIF_F_GEN_CSUM)) { | |
1226 | printk(KERN_ERR "%s: Dropping NETIF_F_UFO since no " | |
1227 | "NETIF_F_HW_CSUM feature.\n", | |
1228 | dev->name); | |
1229 | diff --git a/net/key/af_key.c b/net/key/af_key.c | |
1230 | index b7f5a1c..ef3b4d5 100644 | |
1231 | --- a/net/key/af_key.c | |
1232 | +++ b/net/key/af_key.c | |
1233 | @@ -2051,7 +2051,6 @@ static int pfkey_xfrm_policy2msg(struct sk_buff *skb, struct xfrm_policy *xp, in | |
1234 | req_size += socklen * 2; | |
1235 | } else { | |
1236 | size -= 2*socklen; | |
1237 | - socklen = 0; | |
1238 | } | |
1239 | rq = (void*)skb_put(skb, req_size); | |
1240 | pol->sadb_x_policy_len += req_size/8; | |
1241 | diff --git a/net/sunrpc/auth_generic.c b/net/sunrpc/auth_generic.c | |
1242 | index 744b79f..4028502 100644 | |
1243 | --- a/net/sunrpc/auth_generic.c | |
1244 | +++ b/net/sunrpc/auth_generic.c | |
1245 | @@ -133,13 +133,29 @@ static int | |
1246 | generic_match(struct auth_cred *acred, struct rpc_cred *cred, int flags) | |
1247 | { | |
1248 | struct generic_cred *gcred = container_of(cred, struct generic_cred, gc_base); | |
1249 | + int i; | |
1250 | ||
1251 | if (gcred->acred.uid != acred->uid || | |
1252 | gcred->acred.gid != acred->gid || | |
1253 | - gcred->acred.group_info != acred->group_info || | |
1254 | gcred->acred.machine_cred != acred->machine_cred) | |
1255 | - return 0; | |
1256 | + goto out_nomatch; | |
1257 | + | |
1258 | + /* Optimisation in the case where pointers are identical... */ | |
1259 | + if (gcred->acred.group_info == acred->group_info) | |
1260 | + goto out_match; | |
1261 | + | |
1262 | + /* Slow path... */ | |
1263 | + if (gcred->acred.group_info->ngroups != acred->group_info->ngroups) | |
1264 | + goto out_nomatch; | |
1265 | + for (i = 0; i < gcred->acred.group_info->ngroups; i++) { | |
1266 | + if (GROUP_AT(gcred->acred.group_info, i) != | |
1267 | + GROUP_AT(acred->group_info, i)) | |
1268 | + goto out_nomatch; | |
1269 | + } | |
1270 | +out_match: | |
1271 | return 1; | |
1272 | +out_nomatch: | |
1273 | + return 0; | |
1274 | } | |
1275 | ||
1276 | void __init rpc_init_generic_auth(void) |