/[linux-patches]/genpatches-2.6/tags/2.6.18-9/1002_linux-2.6.18.3.patch
Gentoo

Contents of /genpatches-2.6/tags/2.6.18-9/1002_linux-2.6.18.3.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 802 - (show annotations) (download)
Wed Jan 10 14:47:23 2007 UTC (11 years, 9 months ago) by dsd
File size: 25690 byte(s)
2.6.18-9 release
1 diff --git a/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c b/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c
2 index e6ea00e..ec0c5c2 100644
3 --- a/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c
4 +++ b/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c
5 @@ -560,7 +560,6 @@ static struct cpufreq_driver acpi_cpufre
6 .name = "acpi-cpufreq",
7 .owner = THIS_MODULE,
8 .attr = acpi_cpufreq_attr,
9 - .flags = CPUFREQ_STICKY,
10 };
11
12
13 @@ -571,7 +570,7 @@ acpi_cpufreq_init (void)
14
15 acpi_cpufreq_early_init_acpi();
16
17 - return cpufreq_register_driver(&acpi_cpufreq_driver);
18 + return cpufreq_register_driver(&acpi_cpufreq_driver);
19 }
20
21
22 diff --git a/arch/i386/pci/irq.c b/arch/i386/pci/irq.c
23 index 4a8995c..65a2ce8 100644
24 --- a/arch/i386/pci/irq.c
25 +++ b/arch/i386/pci/irq.c
26 @@ -255,13 +255,13 @@ static int pirq_via_set(struct pci_dev *
27 */
28 static int pirq_via586_get(struct pci_dev *router, struct pci_dev *dev, int pirq)
29 {
30 - static const unsigned int pirqmap[4] = { 3, 2, 5, 1 };
31 + static const unsigned int pirqmap[5] = { 3, 2, 5, 1, 1 };
32 return read_config_nybble(router, 0x55, pirqmap[pirq-1]);
33 }
34
35 static int pirq_via586_set(struct pci_dev *router, struct pci_dev *dev, int pirq, int irq)
36 {
37 - static const unsigned int pirqmap[4] = { 3, 2, 5, 1 };
38 + static const unsigned int pirqmap[5] = { 3, 2, 5, 1, 1 };
39 write_config_nybble(router, 0x55, pirqmap[pirq-1], irq);
40 return 1;
41 }
42 diff --git a/arch/powerpc/kernel/traps.c b/arch/powerpc/kernel/traps.c
43 index 9b352bd..20780f8 100644
44 --- a/arch/powerpc/kernel/traps.c
45 +++ b/arch/powerpc/kernel/traps.c
46 @@ -818,7 +818,7 @@ #endif /* CONFIG_MATH_EMULATION */
47
48 void alignment_exception(struct pt_regs *regs)
49 {
50 - int fixed = 0;
51 + int sig, code, fixed = 0;
52
53 /* we don't implement logging of alignment exceptions */
54 if (!(current->thread.align_ctl & PR_UNALIGN_SIGBUS))
55 @@ -832,14 +832,16 @@ void alignment_exception(struct pt_regs
56
57 /* Operand address was bad */
58 if (fixed == -EFAULT) {
59 - if (user_mode(regs))
60 - _exception(SIGSEGV, regs, SEGV_ACCERR, regs->dar);
61 - else
62 - /* Search exception table */
63 - bad_page_fault(regs, regs->dar, SIGSEGV);
64 - return;
65 + sig = SIGSEGV;
66 + code = SEGV_ACCERR;
67 + } else {
68 + sig = SIGBUS;
69 + code = BUS_ADRALN;
70 }
71 - _exception(SIGBUS, regs, BUS_ADRALN, regs->dar);
72 + if (user_mode(regs))
73 + _exception(sig, regs, code, regs->dar);
74 + else
75 + bad_page_fault(regs, regs->dar, sig);
76 }
77
78 void StackOverflow(struct pt_regs *regs)
79 diff --git a/arch/ppc/kernel/traps.c b/arch/ppc/kernel/traps.c
80 index d7a4330..0193cc4 100644
81 --- a/arch/ppc/kernel/traps.c
82 +++ b/arch/ppc/kernel/traps.c
83 @@ -708,7 +708,7 @@ void single_step_exception(struct pt_reg
84
85 void alignment_exception(struct pt_regs *regs)
86 {
87 - int fixed;
88 + int sig, code, fixed = 0;
89
90 fixed = fix_alignment(regs);
91 if (fixed == 1) {
92 @@ -717,14 +717,16 @@ void alignment_exception(struct pt_regs
93 return;
94 }
95 if (fixed == -EFAULT) {
96 - /* fixed == -EFAULT means the operand address was bad */
97 - if (user_mode(regs))
98 - _exception(SIGSEGV, regs, SEGV_ACCERR, regs->dar);
99 - else
100 - bad_page_fault(regs, regs->dar, SIGSEGV);
101 - return;
102 + sig = SIGSEGV;
103 + code = SEGV_ACCERR;
104 + } else {
105 + sig = SIGBUS;
106 + code = BUS_ADRALN;
107 }
108 - _exception(SIGBUS, regs, BUS_ADRALN, regs->dar);
109 + if (user_mode(regs))
110 + _exception(sig, regs, code, regs->dar);
111 + else
112 + bad_page_fault(regs, regs->dar, sig);
113 }
114
115 void StackOverflow(struct pt_regs *regs)
116 diff --git a/arch/s390/lib/uaccess.S b/arch/s390/lib/uaccess.S
117 index 3f5511d..90443e7 100644
118 --- a/arch/s390/lib/uaccess.S
119 +++ b/arch/s390/lib/uaccess.S
120 @@ -41,15 +41,15 @@ __copy_from_user_asm:
121 5: mvcp 0(%r5,%r2),0(%r4),%r0
122 slr %r3,%r5
123 alr %r2,%r5
124 -6: lgr %r5,%r3 # copy remaining size
125 +6: lr %r5,%r3 # copy remaining size
126 ahi %r5,-1 # subtract 1 for xc loop
127 bras %r4,8f
128 - xc 0(1,%2),0(%2)
129 -7: xc 0(256,%2),0(%2)
130 + xc 0(1,%r2),0(%r2)
131 +7: xc 0(256,%r2),0(%r2)
132 la %r2,256(%r2)
133 -8: ahji %r5,-256
134 +8: ahi %r5,-256
135 jnm 7b
136 - ex %r5,0(%r2)
137 + ex %r5,0(%r4)
138 9: lr %r2,%r3
139 br %r14
140 .section __ex_table,"a"
141 diff --git a/arch/s390/lib/uaccess64.S b/arch/s390/lib/uaccess64.S
142 index 9376df0..2d42c7e 100644
143 --- a/arch/s390/lib/uaccess64.S
144 +++ b/arch/s390/lib/uaccess64.S
145 @@ -49,7 +49,7 @@ __copy_from_user_asm:
146 la %r2,256(%r2)
147 8: aghi %r5,-256
148 jnm 7b
149 - ex %r5,0(%r2)
150 + ex %r5,0(%r4)
151 9: lgr %r2,%r3
152 br %r14
153 .section __ex_table,"a"
154 diff --git a/arch/sparc/kernel/entry.S b/arch/sparc/kernel/entry.S
155 index a4edff4..831f540 100644
156 --- a/arch/sparc/kernel/entry.S
157 +++ b/arch/sparc/kernel/entry.S
158 @@ -32,13 +32,12 @@ #include <asm/obio.h>
159 #include <asm/mxcc.h>
160 #include <asm/thread_info.h>
161 #include <asm/param.h>
162 +#include <asm/unistd.h>
163
164 #include <asm/asmmacro.h>
165
166 #define curptr g6
167
168 -#define NR_SYSCALLS 300 /* Each OS is different... */
169 -
170 /* These are just handy. */
171 #define _SV save %sp, -STACKFRAME_SZ, %sp
172 #define _RS restore
173 diff --git a/arch/sparc64/kernel/entry.S b/arch/sparc64/kernel/entry.S
174 index 0aaa35f..6f28bec 100644
175 --- a/arch/sparc64/kernel/entry.S
176 +++ b/arch/sparc64/kernel/entry.S
177 @@ -22,11 +22,10 @@ #include <asm/estate.h>
178 #include <asm/auxio.h>
179 #include <asm/sfafsr.h>
180 #include <asm/pil.h>
181 +#include <asm/unistd.h>
182
183 #define curptr g6
184
185 -#define NR_SYSCALLS 300 /* Each OS is different... */
186 -
187 .text
188 .align 32
189
190 diff --git a/arch/x86_64/kernel/process.c b/arch/x86_64/kernel/process.c
191 index bb6745d..f127e23 100644
192 --- a/arch/x86_64/kernel/process.c
193 +++ b/arch/x86_64/kernel/process.c
194 @@ -571,6 +571,9 @@ __switch_to(struct task_struct *prev_p,
195 prev->gsindex = gsindex;
196 }
197
198 + /* Must be after DS reload */
199 + unlazy_fpu(prev_p);
200 +
201 /*
202 * Switch the PDA and FPU contexts.
203 */
204 @@ -578,10 +581,6 @@ __switch_to(struct task_struct *prev_p,
205 write_pda(oldrsp, next->userrsp);
206 write_pda(pcurrent, next_p);
207
208 - /* This must be here to ensure both math_state_restore() and
209 - kernel_fpu_begin() work consistently.
210 - And the AMD workaround requires it to be after DS reload. */
211 - unlazy_fpu(prev_p);
212 write_pda(kernelstack,
213 task_stack_page(next_p) + THREAD_SIZE - PDA_STACKOFFSET);
214
215 diff --git a/block/scsi_ioctl.c b/block/scsi_ioctl.c
216 index b33eda2..ed3d3ae 100644
217 --- a/block/scsi_ioctl.c
218 +++ b/block/scsi_ioctl.c
219 @@ -246,10 +246,10 @@ static int sg_io(struct file *file, requ
220 switch (hdr->dxfer_direction) {
221 default:
222 return -EINVAL;
223 - case SG_DXFER_TO_FROM_DEV:
224 case SG_DXFER_TO_DEV:
225 writing = 1;
226 break;
227 + case SG_DXFER_TO_FROM_DEV:
228 case SG_DXFER_FROM_DEV:
229 break;
230 }
231 diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c
232 index 2cd3391..455c318 100644
233 --- a/drivers/block/cciss.c
234 +++ b/drivers/block/cciss.c
235 @@ -1302,6 +1302,12 @@ static void cciss_softirq_done(struct re
236
237 complete_buffers(rq->bio, rq->errors);
238
239 + if (blk_fs_request(rq)) {
240 + const int rw = rq_data_dir(rq);
241 +
242 + disk_stat_add(rq->rq_disk, sectors[rw], rq->nr_sectors);
243 + }
244 +
245 #ifdef CCISS_DEBUG
246 printk("Done with %p\n", rq);
247 #endif /* CCISS_DEBUG */
248 diff --git a/drivers/block/cpqarray.c b/drivers/block/cpqarray.c
249 index 78082ed..5ee5f93 100644
250 --- a/drivers/block/cpqarray.c
251 +++ b/drivers/block/cpqarray.c
252 @@ -1000,6 +1000,7 @@ static inline void complete_buffers(stru
253 */
254 static inline void complete_command(cmdlist_t *cmd, int timeout)
255 {
256 + struct request *rq = cmd->rq;
257 int ok=1;
258 int i, ddir;
259
260 @@ -1031,12 +1032,18 @@ static inline void complete_command(cmdl
261 pci_unmap_page(hba[cmd->ctlr]->pci_dev, cmd->req.sg[i].addr,
262 cmd->req.sg[i].size, ddir);
263
264 - complete_buffers(cmd->rq->bio, ok);
265 + complete_buffers(rq->bio, ok);
266
267 - add_disk_randomness(cmd->rq->rq_disk);
268 + if (blk_fs_request(rq)) {
269 + const int rw = rq_data_dir(rq);
270
271 - DBGPX(printk("Done with %p\n", cmd->rq););
272 - end_that_request_last(cmd->rq, ok ? 1 : -EIO);
273 + disk_stat_add(rq->rq_disk, sectors[rw], rq->nr_sectors);
274 + }
275 +
276 + add_disk_randomness(rq->rq_disk);
277 +
278 + DBGPX(printk("Done with %p\n", rq););
279 + end_that_request_last(rq, ok ? 1 : -EIO);
280 }
281
282 /*
283 diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c
284 index abca98b..5292258 100644
285 --- a/drivers/char/ipmi/ipmi_si_intf.c
286 +++ b/drivers/char/ipmi/ipmi_si_intf.c
287 @@ -1845,7 +1845,7 @@ #endif
288
289 static struct pci_device_id ipmi_pci_devices[] = {
290 { PCI_DEVICE(PCI_HP_VENDOR_ID, PCI_MMC_DEVICE_ID) },
291 - { PCI_DEVICE_CLASS(PCI_ERMC_CLASSCODE, PCI_ERMC_CLASSCODE) }
292 + { PCI_DEVICE_CLASS(PCI_ERMC_CLASSCODE, PCI_ERMC_CLASSCODE_MASK) }
293 };
294 MODULE_DEVICE_TABLE(pci, ipmi_pci_devices);
295
296 diff --git a/drivers/char/isicom.c b/drivers/char/isicom.c
297 index 913be23..d4f6361 100644
298 --- a/drivers/char/isicom.c
299 +++ b/drivers/char/isicom.c
300 @@ -1062,11 +1062,12 @@ static void isicom_shutdown_port(struct
301 static void isicom_close(struct tty_struct *tty, struct file *filp)
302 {
303 struct isi_port *port = tty->driver_data;
304 - struct isi_board *card = port->card;
305 + struct isi_board *card;
306 unsigned long flags;
307
308 if (!port)
309 return;
310 + card = port->card;
311 if (isicom_paranoia_check(port, tty->name, "isicom_close"))
312 return;
313
314 diff --git a/drivers/input/mouse/psmouse-base.c b/drivers/input/mouse/psmouse-base.c
315 index 343afa3..07b0604 100644
316 --- a/drivers/input/mouse/psmouse-base.c
317 +++ b/drivers/input/mouse/psmouse-base.c
318 @@ -1332,20 +1332,22 @@ ssize_t psmouse_attr_set_helper(struct d
319
320 static ssize_t psmouse_show_int_attr(struct psmouse *psmouse, void *offset, char *buf)
321 {
322 - unsigned long *field = (unsigned long *)((char *)psmouse + (size_t)offset);
323 + unsigned int *field = (unsigned int *)((char *)psmouse + (size_t)offset);
324
325 - return sprintf(buf, "%lu\n", *field);
326 + return sprintf(buf, "%u\n", *field);
327 }
328
329 static ssize_t psmouse_set_int_attr(struct psmouse *psmouse, void *offset, const char *buf, size_t count)
330 {
331 - unsigned long *field = (unsigned long *)((char *)psmouse + (size_t)offset);
332 + unsigned int *field = (unsigned int *)((char *)psmouse + (size_t)offset);
333 unsigned long value;
334 char *rest;
335
336 value = simple_strtoul(buf, &rest, 10);
337 if (*rest)
338 return -EINVAL;
339 + if ((unsigned int)value != value)
340 + return -EINVAL;
341
342 *field = value;
343
344 diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c
345 index 98ef9f8..aefcba7 100644
346 --- a/drivers/net/e1000/e1000_main.c
347 +++ b/drivers/net/e1000/e1000_main.c
348 @@ -4683,6 +4683,9 @@ #endif
349 if (adapter->hw.phy_type == e1000_phy_igp_3)
350 e1000_phy_powerdown_workaround(&adapter->hw);
351
352 + if (netif_running(netdev))
353 + e1000_free_irq(adapter);
354 +
355 /* Release control of h/w to f/w. If f/w is AMT enabled, this
356 * would have already happened in close and is redundant. */
357 e1000_release_hw_control(adapter);
358 @@ -4710,6 +4713,10 @@ e1000_resume(struct pci_dev *pdev)
359 pci_enable_wake(pdev, PCI_D3hot, 0);
360 pci_enable_wake(pdev, PCI_D3cold, 0);
361
362 + if (netif_running(netdev) && (ret_val = e1000_request_irq(adapter)))
363 + return ret_val;
364 +
365 + e1000_power_up_phy(adapter);
366 e1000_reset(adapter);
367 E1000_WRITE_REG(&adapter->hw, WUS, ~0);
368
369 diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
370 index fdefa7d..a9c7d41 100644
371 --- a/drivers/pci/pci-sysfs.c
372 +++ b/drivers/pci/pci-sysfs.c
373 @@ -571,6 +571,9 @@ int pci_create_sysfs_dev_files (struct p
374 */
375 void pci_remove_sysfs_dev_files(struct pci_dev *pdev)
376 {
377 + if (!sysfs_initialized)
378 + return;
379 +
380 if (pdev->cfg_size < 4096)
381 sysfs_remove_bin_file(&pdev->dev.kobj, &pci_config_attr);
382 else
383 diff --git a/drivers/usb/class/usblp.c b/drivers/usb/class/usblp.c
384 index 48dee4b..acc7cd8 100644
385 --- a/drivers/usb/class/usblp.c
386 +++ b/drivers/usb/class/usblp.c
387 @@ -701,6 +701,7 @@ static ssize_t usblp_write(struct file *
388 usblp->wcomplete = 0;
389 err = usb_submit_urb(usblp->writeurb, GFP_KERNEL);
390 if (err) {
391 + usblp->wcomplete = 1;
392 if (err != -ENOMEM)
393 count = -EIO;
394 else
395 diff --git a/drivers/usb/input/hid-core.c b/drivers/usb/input/hid-core.c
396 index a2c56b2..19aaf56 100644
397 --- a/drivers/usb/input/hid-core.c
398 +++ b/drivers/usb/input/hid-core.c
399 @@ -1734,10 +1734,10 @@ static const struct hid_blacklist {
400 { USB_VENDOR_ID_APPLE, 0x020E, HID_QUIRK_POWERBOOK_HAS_FN },
401 { USB_VENDOR_ID_APPLE, 0x020F, HID_QUIRK_POWERBOOK_HAS_FN },
402 { USB_VENDOR_ID_APPLE, 0x0214, HID_QUIRK_POWERBOOK_HAS_FN },
403 - { USB_VENDOR_ID_APPLE, 0x0215, HID_QUIRK_POWERBOOK_HAS_FN },
404 + { USB_VENDOR_ID_APPLE, 0x0215, HID_QUIRK_POWERBOOK_HAS_FN | HID_QUIRK_POWERBOOK_ISO_KEYBOARD},
405 { USB_VENDOR_ID_APPLE, 0x0216, HID_QUIRK_POWERBOOK_HAS_FN },
406 { USB_VENDOR_ID_APPLE, 0x0217, HID_QUIRK_POWERBOOK_HAS_FN },
407 - { USB_VENDOR_ID_APPLE, 0x0218, HID_QUIRK_POWERBOOK_HAS_FN },
408 + { USB_VENDOR_ID_APPLE, 0x0218, HID_QUIRK_POWERBOOK_HAS_FN | HID_QUIRK_POWERBOOK_ISO_KEYBOARD},
409 { USB_VENDOR_ID_APPLE, 0x0219, HID_QUIRK_POWERBOOK_HAS_FN },
410 { USB_VENDOR_ID_APPLE, 0x030A, HID_QUIRK_POWERBOOK_HAS_FN },
411 { USB_VENDOR_ID_APPLE, 0x030B, HID_QUIRK_POWERBOOK_HAS_FN },
412 diff --git a/drivers/usb/input/hid-input.c b/drivers/usb/input/hid-input.c
413 index 7208839..2ae4fb9 100644
414 --- a/drivers/usb/input/hid-input.c
415 +++ b/drivers/usb/input/hid-input.c
416 @@ -123,6 +123,12 @@ static struct hidinput_key_translation p
417 { }
418 };
419
420 +static struct hidinput_key_translation powerbook_iso_keyboard[] = {
421 + { KEY_GRAVE, KEY_102ND },
422 + { KEY_102ND, KEY_GRAVE },
423 + { }
424 +};
425 +
426 static int usbhid_pb_fnmode = 1;
427 module_param_named(pb_fnmode, usbhid_pb_fnmode, int, 0644);
428 MODULE_PARM_DESC(pb_fnmode,
429 @@ -197,6 +203,14 @@ static int hidinput_pb_event(struct hid_
430 }
431 }
432
433 + if (hid->quirks & HID_QUIRK_POWERBOOK_ISO_KEYBOARD) {
434 + trans = find_translation(powerbook_iso_keyboard, usage->code);
435 + if (trans) {
436 + input_event(input, usage->type, trans->to, value);
437 + return 1;
438 + }
439 + }
440 +
441 return 0;
442 }
443
444 @@ -212,6 +226,9 @@ static void hidinput_pb_setup(struct inp
445
446 for (trans = powerbook_numlock_keys; trans->from; trans++)
447 set_bit(trans->to, input->keybit);
448 +
449 + for (trans = powerbook_iso_keyboard; trans->from; trans++)
450 + set_bit(trans->to, input->keybit);
451 }
452 #else
453 static inline int hidinput_pb_event(struct hid_device *hid, struct input_dev *input,
454 diff --git a/drivers/usb/input/hid.h b/drivers/usb/input/hid.h
455 index 778e575..aa85d0b 100644
456 --- a/drivers/usb/input/hid.h
457 +++ b/drivers/usb/input/hid.h
458 @@ -260,6 +260,7 @@ #define HID_QUIRK_CYMOTION 0x00000800
459 #define HID_QUIRK_POWERBOOK_HAS_FN 0x00001000
460 #define HID_QUIRK_POWERBOOK_FN_ON 0x00002000
461 #define HID_QUIRK_INVERT_HWHEEL 0x00004000
462 +#define HID_QUIRK_POWERBOOK_ISO_KEYBOARD 0x00010000
463
464 /*
465 * This is the global environment of the parser. This information is
466 diff --git a/drivers/usb/input/usbtouchscreen.c b/drivers/usb/input/usbtouchscreen.c
467 index a338bf4..0f3adc4 100644
468 --- a/drivers/usb/input/usbtouchscreen.c
469 +++ b/drivers/usb/input/usbtouchscreen.c
470 @@ -522,7 +522,7 @@ static int usbtouch_probe(struct usb_int
471 type->max_press, 0, 0);
472
473 usb_fill_int_urb(usbtouch->irq, usbtouch->udev,
474 - usb_rcvintpipe(usbtouch->udev, 0x81),
475 + usb_rcvintpipe(usbtouch->udev, endpoint->bEndpointAddress),
476 usbtouch->data, type->rept_size,
477 usbtouch_irq, usbtouch, endpoint->bInterval);
478
479 diff --git a/drivers/video/nvidia/nv_hw.c b/drivers/video/nvidia/nv_hw.c
480 index 9ed640d..ea42611 100644
481 --- a/drivers/video/nvidia/nv_hw.c
482 +++ b/drivers/video/nvidia/nv_hw.c
483 @@ -145,12 +145,18 @@ static void nvGetClocks(struct nvidia_pa
484
485 if (par->Architecture >= NV_ARCH_40) {
486 pll = NV_RD32(par->PMC, 0x4020);
487 - P = (pll >> 16) & 0x03;
488 + P = (pll >> 16) & 0x07;
489 pll = NV_RD32(par->PMC, 0x4024);
490 M = pll & 0xFF;
491 N = (pll >> 8) & 0xFF;
492 - MB = (pll >> 16) & 0xFF;
493 - NB = (pll >> 24) & 0xFF;
494 + if (((par->Chipset & 0xfff0) == 0x0290) ||
495 + ((par->Chipset & 0xfff0) == 0x0390)) {
496 + MB = 1;
497 + NB = 1;
498 + } else {
499 + MB = (pll >> 16) & 0xFF;
500 + NB = (pll >> 24) & 0xFF;
501 + }
502 *MClk = ((N * NB * par->CrystalFreqKHz) / (M * MB)) >> P;
503
504 pll = NV_RD32(par->PMC, 0x4000);
505 diff --git a/drivers/video/nvidia/nv_setup.c b/drivers/video/nvidia/nv_setup.c
506 index a18a9ae..61dc46f 100644
507 --- a/drivers/video/nvidia/nv_setup.c
508 +++ b/drivers/video/nvidia/nv_setup.c
509 @@ -359,6 +359,7 @@ int NVCommonSetup(struct fb_info *info)
510 case 0x0186:
511 case 0x0187:
512 case 0x018D:
513 + case 0x0228:
514 case 0x0286:
515 case 0x028C:
516 case 0x0316:
517 @@ -382,6 +383,10 @@ int NVCommonSetup(struct fb_info *info)
518 case 0x034C:
519 case 0x0160:
520 case 0x0166:
521 + case 0x0169:
522 + case 0x016B:
523 + case 0x016C:
524 + case 0x016D:
525 case 0x00C8:
526 case 0x00CC:
527 case 0x0144:
528 @@ -639,12 +644,23 @@ int NVCommonSetup(struct fb_info *info)
529 par->fpHeight = NV_RD32(par->PRAMDAC, 0x0800) + 1;
530 par->fpSyncs = NV_RD32(par->PRAMDAC, 0x0848) & 0x30000033;
531
532 - printk("Panel size is %i x %i\n", par->fpWidth, par->fpHeight);
533 + printk("nvidiafb: Panel size is %i x %i\n", par->fpWidth, par->fpHeight);
534 }
535
536 if (monA)
537 info->monspecs = *monA;
538
539 + if (!par->FlatPanel || !par->twoHeads)
540 + par->FPDither = 0;
541 +
542 + par->LVDS = 0;
543 + if (par->FlatPanel && par->twoHeads) {
544 + NV_WR32(par->PRAMDAC0, 0x08B0, 0x00010004);
545 + if (par->PRAMDAC0[0x08b4] & 1)
546 + par->LVDS = 1;
547 + printk("nvidiafb: Panel is %s\n", par->LVDS ? "LVDS" : "TMDS");
548 + }
549 +
550 kfree(edidA);
551 kfree(edidB);
552 done:
553 diff --git a/drivers/video/nvidia/nv_type.h b/drivers/video/nvidia/nv_type.h
554 index acdc266..86e65de 100644
555 --- a/drivers/video/nvidia/nv_type.h
556 +++ b/drivers/video/nvidia/nv_type.h
557 @@ -129,6 +129,7 @@ struct nvidia_par {
558 int fpHeight;
559 int PanelTweak;
560 int paneltweak;
561 + int LVDS;
562 int pm_state;
563 u32 crtcSync_read;
564 u32 fpSyncs;
565 diff --git a/drivers/video/nvidia/nvidia.c b/drivers/video/nvidia/nvidia.c
566 index d4f8501..2a961f8 100644
567 --- a/drivers/video/nvidia/nvidia.c
568 +++ b/drivers/video/nvidia/nvidia.c
569 @@ -1145,20 +1145,20 @@ static u32 __devinit nvidia_get_arch(str
570 case 0x0340: /* GeForceFX 5700 */
571 arch = NV_ARCH_30;
572 break;
573 - case 0x0040:
574 - case 0x00C0:
575 - case 0x0120:
576 + case 0x0040: /* GeForce 6800 */
577 + case 0x00C0: /* GeForce 6800 */
578 + case 0x0120: /* GeForce 6800 */
579 case 0x0130:
580 - case 0x0140:
581 - case 0x0160:
582 - case 0x01D0:
583 - case 0x0090:
584 - case 0x0210:
585 - case 0x0220:
586 + case 0x0140: /* GeForce 6600 */
587 + case 0x0160: /* GeForce 6200 */
588 + case 0x01D0: /* GeForce 7200, 7300, 7400 */
589 + case 0x0090: /* GeForce 7800 */
590 + case 0x0210: /* GeForce 6800 */
591 + case 0x0220: /* GeForce 6200 */
592 case 0x0230:
593 - case 0x0240:
594 - case 0x0290:
595 - case 0x0390:
596 + case 0x0240: /* GeForce 6100 */
597 + case 0x0290: /* GeForce 7900 */
598 + case 0x0390: /* GeForce 7600 */
599 arch = NV_ARCH_40;
600 break;
601 case 0x0020: /* TNT, TNT2 */
602 diff --git a/fs/cifs/CHANGES b/fs/cifs/CHANGES
603 index 0feb3bd..77a2fbb 100644
604 --- a/fs/cifs/CHANGES
605 +++ b/fs/cifs/CHANGES
606 @@ -6,7 +6,11 @@ on requests on other threads. Improve P
607 (lock cancel now works, and unlock of merged range works even
608 to Windows servers now). Fix oops on mount to lanman servers
609 (win9x, os/2 etc.) when null password. Do not send listxattr
610 -(SMB to query all EAs) if nouser_xattr specified.
611 +(SMB to query all EAs) if nouser_xattr specified. Return error
612 +in rename 2nd attempt retry (ie report if rename by handle also
613 +fails, after rename by path fails, we were not reporting whether
614 +the retry worked or not).
615 +
616
617 Version 1.44
618 ------------
619 diff --git a/fs/cifs/file.c b/fs/cifs/file.c
620 index e9c5ba9..ddb012a 100644
621 --- a/fs/cifs/file.c
622 +++ b/fs/cifs/file.c
623 @@ -752,6 +752,7 @@ int cifs_lock(struct file *file, int cmd
624 int stored_rc = 0;
625 struct cifsLockInfo *li, *tmp;
626
627 + rc = 0;
628 down(&fid->lock_sem);
629 list_for_each_entry_safe(li, tmp, &fid->llist, llist) {
630 if (pfLock->fl_start <= li->offset &&
631 @@ -766,7 +767,7 @@ int cifs_lock(struct file *file, int cmd
632 kfree(li);
633 }
634 }
635 - up(&fid->lock_sem);
636 + up(&fid->lock_sem);
637 }
638 }
639
640 diff --git a/fs/cifs/inode.c b/fs/cifs/inode.c
641 index b88147c..c76ac38 100644
642 --- a/fs/cifs/inode.c
643 +++ b/fs/cifs/inode.c
644 @@ -880,10 +880,14 @@ int cifs_rename(struct inode *source_ino
645 kmalloc(2 * sizeof(FILE_UNIX_BASIC_INFO), GFP_KERNEL);
646 if (info_buf_source != NULL) {
647 info_buf_target = info_buf_source + 1;
648 - rc = CIFSSMBUnixQPathInfo(xid, pTcon, fromName,
649 - info_buf_source, cifs_sb_source->local_nls,
650 - cifs_sb_source->mnt_cifs_flags &
651 - CIFS_MOUNT_MAP_SPECIAL_CHR);
652 + if (pTcon->ses->capabilities & CAP_UNIX)
653 + rc = CIFSSMBUnixQPathInfo(xid, pTcon, fromName,
654 + info_buf_source,
655 + cifs_sb_source->local_nls,
656 + cifs_sb_source->mnt_cifs_flags &
657 + CIFS_MOUNT_MAP_SPECIAL_CHR);
658 + /* else rc is still EEXIST so will fall through to
659 + unlink the target and retry rename */
660 if (rc == 0) {
661 rc = CIFSSMBUnixQPathInfo(xid, pTcon, toName,
662 info_buf_target,
663 @@ -932,7 +936,7 @@ int cifs_rename(struct inode *source_ino
664 cifs_sb_source->mnt_cifs_flags &
665 CIFS_MOUNT_MAP_SPECIAL_CHR);
666 if (rc==0) {
667 - CIFSSMBRenameOpenFile(xid, pTcon, netfid, toName,
668 + rc = CIFSSMBRenameOpenFile(xid, pTcon, netfid, toName,
669 cifs_sb_source->local_nls,
670 cifs_sb_source->mnt_cifs_flags &
671 CIFS_MOUNT_MAP_SPECIAL_CHR);
672 diff --git a/include/asm-sparc/unistd.h b/include/asm-sparc/unistd.h
673 index 2553762..68380ad 100644
674 --- a/include/asm-sparc/unistd.h
675 +++ b/include/asm-sparc/unistd.h
676 @@ -319,6 +319,8 @@ #define __NR_unshare 299
677 #define __NR_set_robust_list 300
678 #define __NR_get_robust_list 301
679
680 +#define NR_SYSCALLS 302
681 +
682 #ifdef __KERNEL__
683 /* WARNING: You MAY NOT add syscall numbers larger than 301, since
684 * all of the syscall tables in the Sparc kernel are
685 diff --git a/include/asm-sparc64/futex.h b/include/asm-sparc64/futex.h
686 index dee4020..7392fc4 100644
687 --- a/include/asm-sparc64/futex.h
688 +++ b/include/asm-sparc64/futex.h
689 @@ -87,24 +87,22 @@ static inline int
690 futex_atomic_cmpxchg_inatomic(int __user *uaddr, int oldval, int newval)
691 {
692 __asm__ __volatile__(
693 - "\n1: lduwa [%2] %%asi, %0\n"
694 - "2: casa [%2] %%asi, %0, %1\n"
695 - "3:\n"
696 + "\n1: casa [%3] %%asi, %2, %0\n"
697 + "2:\n"
698 " .section .fixup,#alloc,#execinstr\n"
699 " .align 4\n"
700 - "4: ba 3b\n"
701 - " mov %3, %0\n"
702 + "3: ba 2b\n"
703 + " mov %4, %0\n"
704 " .previous\n"
705 " .section __ex_table,\"a\"\n"
706 " .align 4\n"
707 - " .word 1b, 4b\n"
708 - " .word 2b, 4b\n"
709 + " .word 1b, 3b\n"
710 " .previous\n"
711 - : "=&r" (oldval)
712 - : "r" (newval), "r" (uaddr), "i" (-EFAULT)
713 + : "=r" (newval)
714 + : "0" (newval), "r" (oldval), "r" (uaddr), "i" (-EFAULT)
715 : "memory");
716
717 - return oldval;
718 + return newval;
719 }
720
721 #endif /* !(_SPARC64_FUTEX_H) */
722 diff --git a/include/asm-sparc64/unistd.h b/include/asm-sparc64/unistd.h
723 index badc73f..124dcef 100644
724 --- a/include/asm-sparc64/unistd.h
725 +++ b/include/asm-sparc64/unistd.h
726 @@ -321,6 +321,8 @@ #define __NR_unshare 299
727 #define __NR_set_robust_list 300
728 #define __NR_get_robust_list 301
729
730 +#define NR_SYSCALLS 302
731 +
732 #ifdef __KERNEL__
733 /* WARNING: You MAY NOT add syscall numbers larger than 301, since
734 * all of the syscall tables in the Sparc kernel are
735 diff --git a/include/linux/ufs_fs.h b/include/linux/ufs_fs.h
736 index fc62887..aa6832b 100644
737 --- a/include/linux/ufs_fs.h
738 +++ b/include/linux/ufs_fs.h
739 @@ -900,7 +900,7 @@ struct ufs_super_block_third {
740 __fs64 fs_csaddr; /* blk addr of cyl grp summary area */
741 __fs64 fs_pendingblocks;/* blocks in process of being freed */
742 __fs32 fs_pendinginodes;/*inodes in process of being freed */
743 - } fs_u2;
744 + } __attribute__ ((packed)) fs_u2;
745 } fs_un1;
746 union {
747 struct {
748 diff --git a/mm/migrate.c b/mm/migrate.c
749 index 3f1e0c2..fd28046 100644
750 --- a/mm/migrate.c
751 +++ b/mm/migrate.c
752 @@ -950,7 +950,8 @@ asmlinkage long sys_move_pages(pid_t pid
753 goto out;
754
755 pm[i].node = node;
756 - }
757 + } else
758 + pm[i].node = 0; /* anything to not match MAX_NUMNODES */
759 }
760 /* End marker */
761 pm[nr_pages].node = MAX_NUMNODES;
762 diff --git a/mm/slab.c b/mm/slab.c
763 index 21ba060..0a94239 100644
764 --- a/mm/slab.c
765 +++ b/mm/slab.c
766 @@ -867,7 +867,7 @@ static void init_reap_node(int cpu)
767 if (node == MAX_NUMNODES)
768 node = first_node(node_online_map);
769
770 - __get_cpu_var(reap_node) = node;
771 + per_cpu(reap_node, cpu) = node;
772 }
773
774 static void next_reap_node(void)
775 diff --git a/net/core/skbuff.c b/net/core/skbuff.c
776 index 7de9857..4ae562f 100644
777 --- a/net/core/skbuff.c
778 +++ b/net/core/skbuff.c
779 @@ -638,6 +638,7 @@ struct sk_buff *pskb_copy(struct sk_buff
780 n->csum = skb->csum;
781 n->ip_summed = skb->ip_summed;
782
783 + n->truesize += skb->data_len;
784 n->data_len = skb->data_len;
785 n->len = skb->len;
786
787 diff --git a/net/core/sock.c b/net/core/sock.c
788 index 51fcfbc..e7ecdf2 100644
789 --- a/net/core/sock.c
790 +++ b/net/core/sock.c
791 @@ -1164,7 +1164,7 @@ static struct sk_buff *sock_alloc_send_p
792 goto failure;
793
794 if (atomic_read(&sk->sk_wmem_alloc) < sk->sk_sndbuf) {
795 - skb = alloc_skb(header_len, sk->sk_allocation);
796 + skb = alloc_skb(header_len, gfp_mask);
797 if (skb) {
798 int npages;
799 int i;
800 diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c
801 index 934396b..0a4ed27 100644
802 --- a/net/ipv4/tcp.c
803 +++ b/net/ipv4/tcp.c
804 @@ -2269,7 +2269,7 @@ void __init tcp_init(void)
805 thash_entries,
806 (num_physpages >= 128 * 1024) ?
807 13 : 15,
808 - HASH_HIGHMEM,
809 + 0,
810 &tcp_hashinfo.ehash_size,
811 NULL,
812 0);
813 @@ -2285,7 +2285,7 @@ void __init tcp_init(void)
814 tcp_hashinfo.ehash_size,
815 (num_physpages >= 128 * 1024) ?
816 13 : 15,
817 - HASH_HIGHMEM,
818 + 0,
819 &tcp_hashinfo.bhash_size,
820 NULL,
821 64 * 1024);
822 diff --git a/security/seclvl.c b/security/seclvl.c
823 index c26dd7d..d5371b8 100644
824 --- a/security/seclvl.c
825 +++ b/security/seclvl.c
826 @@ -370,6 +370,8 @@ static int seclvl_settime(struct timespe
827 current->group_leader->pid);
828 return -EPERM;
829 } /* if attempt to decrement time */
830 + if (tv->tv_sec > 1924988400) /* disallow dates after 2030) */
831 + return -EPERM; /* CVE-2005-4352 */
832 } /* if seclvl > 1 */
833 return 0;
834 }

  ViewVC Help
Powered by ViewVC 1.1.20