/[linux-patches]/genpatches-2.6/tags/2.6.32-47/1035_linux-2.6.32.36.patch
Gentoo

Contents of /genpatches-2.6/tags/2.6.32-47/1035_linux-2.6.32.36.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2037 - (show annotations) (download)
Wed Dec 28 14:38:55 2011 UTC (6 years, 6 months ago) by psomas
File size: 19737 byte(s)
2.6.32-47 release
1 diff --git a/arch/x86/kernel/head64.c b/arch/x86/kernel/head64.c
2 index 0b06cd7..0b08160 100644
3 --- a/arch/x86/kernel/head64.c
4 +++ b/arch/x86/kernel/head64.c
5 @@ -76,9 +76,6 @@ void __init x86_64_start_kernel(char * real_mode_data)
6 /* Make NULL pointers segfault */
7 zap_identity_mappings();
8
9 - /* Cleanup the over mapped high alias */
10 - cleanup_highmap();
11 -
12 for (i = 0; i < NUM_EXCEPTION_VECTORS; i++) {
13 #ifdef CONFIG_EARLY_PRINTK
14 set_intr_gate(i, &early_idt_handlers[i]);
15 diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
16 index 5449a26..76358ee 100644
17 --- a/arch/x86/kernel/setup.c
18 +++ b/arch/x86/kernel/setup.c
19 @@ -294,6 +294,9 @@ static void __init init_gbpages(void)
20 static inline void init_gbpages(void)
21 {
22 }
23 +static void __init cleanup_highmap(void)
24 +{
25 +}
26 #endif
27
28 static void __init reserve_brk(void)
29 @@ -921,6 +924,8 @@ void __init setup_arch(char **cmdline_p)
30
31 reserve_brk();
32
33 + cleanup_highmap();
34 +
35 init_gbpages();
36
37 /* max_pfn_mapped is updated here */
38 diff --git a/arch/x86/mm/init.c b/arch/x86/mm/init.c
39 index 73ffd55..6bce215 100644
40 --- a/arch/x86/mm/init.c
41 +++ b/arch/x86/mm/init.c
42 @@ -287,25 +287,6 @@ unsigned long __init_refok init_memory_mapping(unsigned long start,
43 load_cr3(swapper_pg_dir);
44 #endif
45
46 -#ifdef CONFIG_X86_64
47 - if (!after_bootmem && !start) {
48 - pud_t *pud;
49 - pmd_t *pmd;
50 -
51 - mmu_cr4_features = read_cr4();
52 -
53 - /*
54 - * _brk_end cannot change anymore, but it and _end may be
55 - * located on different 2M pages. cleanup_highmap(), however,
56 - * can only consider _end when it runs, so destroy any
57 - * mappings beyond _brk_end here.
58 - */
59 - pud = pud_offset(pgd_offset_k(_brk_end), _brk_end);
60 - pmd = pmd_offset(pud, _brk_end - 1);
61 - while (++pmd <= pmd_offset(pud, (unsigned long)_end - 1))
62 - pmd_clear(pmd);
63 - }
64 -#endif
65 __flush_tlb_all();
66
67 if (!after_bootmem && e820_table_end > e820_table_start)
68 diff --git a/arch/x86/mm/init_64.c b/arch/x86/mm/init_64.c
69 index 7d095ad..1584023 100644
70 --- a/arch/x86/mm/init_64.c
71 +++ b/arch/x86/mm/init_64.c
72 @@ -49,6 +49,7 @@
73 #include <asm/numa.h>
74 #include <asm/cacheflush.h>
75 #include <asm/init.h>
76 +#include <asm/setup.h>
77 #include <linux/bootmem.h>
78
79 static unsigned long dma_reserve __initdata;
80 @@ -257,18 +258,18 @@ void __init init_extra_mapping_uc(unsigned long phys, unsigned long size)
81 * to the compile time generated pmds. This results in invalid pmds up
82 * to the point where we hit the physaddr 0 mapping.
83 *
84 - * We limit the mappings to the region from _text to _end. _end is
85 - * rounded up to the 2MB boundary. This catches the invalid pmds as
86 + * We limit the mappings to the region from _text to _brk_end. _brk_end
87 + * is rounded up to the 2MB boundary. This catches the invalid pmds as
88 * well, as they are located before _text:
89 */
90 void __init cleanup_highmap(void)
91 {
92 unsigned long vaddr = __START_KERNEL_map;
93 - unsigned long end = roundup((unsigned long)_end, PMD_SIZE) - 1;
94 + unsigned long vaddr_end = __START_KERNEL_map + (max_pfn_mapped << PAGE_SHIFT);
95 + unsigned long end = roundup((unsigned long)_brk_end, PMD_SIZE) - 1;
96 pmd_t *pmd = level2_kernel_pgt;
97 - pmd_t *last_pmd = pmd + PTRS_PER_PMD;
98
99 - for (; pmd < last_pmd; pmd++, vaddr += PMD_SIZE) {
100 + for (; vaddr + PMD_SIZE - 1 < vaddr_end; pmd++, vaddr += PMD_SIZE) {
101 if (pmd_none(*pmd))
102 continue;
103 if (vaddr < (unsigned long) _text || vaddr > end)
104 diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c
105 index 350a3de..6ec047d 100644
106 --- a/arch/x86/xen/mmu.c
107 +++ b/arch/x86/xen/mmu.c
108 @@ -1658,9 +1658,6 @@ static __init void xen_map_identity_early(pmd_t *pmd, unsigned long max_pfn)
109 for (pteidx = 0; pteidx < PTRS_PER_PTE; pteidx++, pfn++) {
110 pte_t pte;
111
112 - if (pfn > max_pfn_mapped)
113 - max_pfn_mapped = pfn;
114 -
115 if (!pte_none(pte_page[pteidx]))
116 continue;
117
118 @@ -1704,6 +1701,12 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *pgd,
119 pud_t *l3;
120 pmd_t *l2;
121
122 + /* max_pfn_mapped is the last pfn mapped in the initial memory
123 + * mappings. Considering that on Xen after the kernel mappings we
124 + * have the mappings of some pages that don't exist in pfn space, we
125 + * set max_pfn_mapped to the last real pfn mapped. */
126 + max_pfn_mapped = PFN_DOWN(__pa(xen_start_info->mfn_list));
127 +
128 /* Zap identity mapping */
129 init_level4_pgt[0] = __pgd(0);
130
131 @@ -1767,9 +1770,7 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *pgd,
132 {
133 pmd_t *kernel_pmd;
134
135 - max_pfn_mapped = PFN_DOWN(__pa(xen_start_info->pt_base) +
136 - xen_start_info->nr_pt_frames * PAGE_SIZE +
137 - 512*1024);
138 + max_pfn_mapped = PFN_DOWN(__pa(xen_start_info->mfn_list));
139
140 kernel_pmd = m2v(pgd[KERNEL_PGD_BOUNDARY].pgd);
141 memcpy(level2_kernel_pgt, kernel_pmd, sizeof(pmd_t) * PTRS_PER_PMD);
142 diff --git a/drivers/firmware/dcdbas.c b/drivers/firmware/dcdbas.c
143 index 18d65fb..3abb515 100644
144 --- a/drivers/firmware/dcdbas.c
145 +++ b/drivers/firmware/dcdbas.c
146 @@ -267,8 +267,10 @@ int dcdbas_smi_request(struct smi_cmd *smi_cmd)
147 }
148
149 /* generate SMI */
150 + /* inb to force posted write through and make SMI happen now */
151 asm volatile (
152 - "outb %b0,%w1"
153 + "outb %b0,%w1\n"
154 + "inb %w1"
155 : /* no output args */
156 : "a" (smi_cmd->command_code),
157 "d" (smi_cmd->command_address),
158 diff --git a/drivers/input/xen-kbdfront.c b/drivers/input/xen-kbdfront.c
159 index b115726..eb88f40 100644
160 --- a/drivers/input/xen-kbdfront.c
161 +++ b/drivers/input/xen-kbdfront.c
162 @@ -105,7 +105,7 @@ static irqreturn_t input_handler(int rq, void *dev_id)
163 static int __devinit xenkbd_probe(struct xenbus_device *dev,
164 const struct xenbus_device_id *id)
165 {
166 - int ret, i;
167 + int ret, i, abs;
168 struct xenkbd_info *info;
169 struct input_dev *kbd, *ptr;
170
171 @@ -123,6 +123,11 @@ static int __devinit xenkbd_probe(struct xenbus_device *dev,
172 if (!info->page)
173 goto error_nomem;
174
175 + if (xenbus_scanf(XBT_NIL, dev->otherend, "feature-abs-pointer", "%d", &abs) < 0)
176 + abs = 0;
177 + if (abs)
178 + xenbus_printf(XBT_NIL, dev->nodename, "request-abs-pointer", "1");
179 +
180 /* keyboard */
181 kbd = input_allocate_device();
182 if (!kbd)
183 @@ -132,11 +137,12 @@ static int __devinit xenkbd_probe(struct xenbus_device *dev,
184 kbd->id.bustype = BUS_PCI;
185 kbd->id.vendor = 0x5853;
186 kbd->id.product = 0xffff;
187 - kbd->evbit[0] = BIT(EV_KEY);
188 +
189 + __set_bit(EV_KEY, kbd->evbit);
190 for (i = KEY_ESC; i < KEY_UNKNOWN; i++)
191 - set_bit(i, kbd->keybit);
192 + __set_bit(i, kbd->keybit);
193 for (i = KEY_OK; i < KEY_MAX; i++)
194 - set_bit(i, kbd->keybit);
195 + __set_bit(i, kbd->keybit);
196
197 ret = input_register_device(kbd);
198 if (ret) {
199 @@ -155,12 +161,20 @@ static int __devinit xenkbd_probe(struct xenbus_device *dev,
200 ptr->id.bustype = BUS_PCI;
201 ptr->id.vendor = 0x5853;
202 ptr->id.product = 0xfffe;
203 - ptr->evbit[0] = BIT(EV_KEY) | BIT(EV_REL) | BIT(EV_ABS);
204 +
205 + if (abs) {
206 + __set_bit(EV_ABS, ptr->evbit);
207 + input_set_abs_params(ptr, ABS_X, 0, XENFB_WIDTH, 0, 0);
208 + input_set_abs_params(ptr, ABS_Y, 0, XENFB_HEIGHT, 0, 0);
209 + } else {
210 + input_set_capability(ptr, EV_REL, REL_X);
211 + input_set_capability(ptr, EV_REL, REL_Y);
212 + }
213 + input_set_capability(ptr, EV_REL, REL_WHEEL);
214 +
215 + __set_bit(EV_KEY, ptr->evbit);
216 for (i = BTN_LEFT; i <= BTN_TASK; i++)
217 - set_bit(i, ptr->keybit);
218 - ptr->relbit[0] = BIT(REL_X) | BIT(REL_Y) | BIT(REL_WHEEL);
219 - input_set_abs_params(ptr, ABS_X, 0, XENFB_WIDTH, 0, 0);
220 - input_set_abs_params(ptr, ABS_Y, 0, XENFB_HEIGHT, 0, 0);
221 + __set_bit(i, ptr->keybit);
222
223 ret = input_register_device(ptr);
224 if (ret) {
225 @@ -267,7 +281,7 @@ static void xenkbd_backend_changed(struct xenbus_device *dev,
226 enum xenbus_state backend_state)
227 {
228 struct xenkbd_info *info = dev_get_drvdata(&dev->dev);
229 - int ret, val;
230 + int val;
231
232 switch (backend_state) {
233 case XenbusStateInitialising:
234 @@ -278,17 +292,6 @@ static void xenkbd_backend_changed(struct xenbus_device *dev,
235
236 case XenbusStateInitWait:
237 InitWait:
238 - ret = xenbus_scanf(XBT_NIL, info->xbdev->otherend,
239 - "feature-abs-pointer", "%d", &val);
240 - if (ret < 0)
241 - val = 0;
242 - if (val) {
243 - ret = xenbus_printf(XBT_NIL, info->xbdev->nodename,
244 - "request-abs-pointer", "1");
245 - if (ret)
246 - printk(KERN_WARNING
247 - "xenkbd: can't request abs-pointer");
248 - }
249 xenbus_switch_state(dev, XenbusStateConnected);
250 break;
251
252 diff --git a/drivers/media/video/uvc/uvc_video.c b/drivers/media/video/uvc/uvc_video.c
253 index a6e41d1..688598a 100644
254 --- a/drivers/media/video/uvc/uvc_video.c
255 +++ b/drivers/media/video/uvc/uvc_video.c
256 @@ -64,15 +64,19 @@ int uvc_query_ctrl(struct uvc_device *dev, __u8 query, __u8 unit,
257 static void uvc_fixup_video_ctrl(struct uvc_streaming *stream,
258 struct uvc_streaming_control *ctrl)
259 {
260 - struct uvc_format *format;
261 + struct uvc_format *format = NULL;
262 struct uvc_frame *frame = NULL;
263 unsigned int i;
264
265 - if (ctrl->bFormatIndex <= 0 ||
266 - ctrl->bFormatIndex > stream->nformats)
267 - return;
268 + for (i = 0; i < stream->nformats; ++i) {
269 + if (stream->format[i].index == ctrl->bFormatIndex) {
270 + format = &stream->format[i];
271 + break;
272 + }
273 + }
274
275 - format = &stream->format[ctrl->bFormatIndex - 1];
276 + if (format == NULL)
277 + return;
278
279 for (i = 0; i < format->nframes; ++i) {
280 if (format->frame[i].bFrameIndex == ctrl->bFrameIndex) {
281 diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c
282 index 58d25a1..73e7d8e 100644
283 --- a/drivers/pci/hotplug/acpiphp_glue.c
284 +++ b/drivers/pci/hotplug/acpiphp_glue.c
285 @@ -213,6 +213,7 @@ register_slot(acpi_handle handle, u32 lvl, void *context, void **rv)
286
287 pdev = pci_get_slot(pbus, PCI_DEVFN(device, function));
288 if (pdev) {
289 + pdev->current_state = PCI_D0;
290 slot->flags |= (SLOT_ENABLED | SLOT_POWEREDON);
291 pci_dev_put(pdev);
292 }
293 diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
294 index 0964b4c..8313311 100644
295 --- a/drivers/pci/pci-sysfs.c
296 +++ b/drivers/pci/pci-sysfs.c
297 @@ -939,7 +939,12 @@ static ssize_t reset_store(struct device *dev,
298
299 if (val != 1)
300 return -EINVAL;
301 - return pci_reset_function(pdev);
302 +
303 + result = pci_reset_function(pdev);
304 + if (result < 0)
305 + return result;
306 +
307 + return count;
308 }
309
310 static struct device_attribute reset_attr = __ATTR(reset, 0200, NULL, reset_store);
311 diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c
312 index 399dd67..4e32da6 100644
313 --- a/drivers/usb/class/cdc-acm.c
314 +++ b/drivers/usb/class/cdc-acm.c
315 @@ -297,6 +297,8 @@ static void acm_ctrl_irq(struct urb *urb)
316 if (!ACM_READY(acm))
317 goto exit;
318
319 + usb_mark_last_busy(acm->dev);
320 +
321 data = (unsigned char *)(dr + 1);
322 switch (dr->bNotificationType) {
323 case USB_CDC_NOTIFY_NETWORK_CONNECTION:
324 @@ -336,7 +338,6 @@ static void acm_ctrl_irq(struct urb *urb)
325 break;
326 }
327 exit:
328 - usb_mark_last_busy(acm->dev);
329 retval = usb_submit_urb(urb, GFP_ATOMIC);
330 if (retval)
331 dev_err(&urb->dev->dev, "%s - usb_submit_urb failed with "
332 @@ -534,6 +535,8 @@ static void acm_softint(struct work_struct *work)
333 if (!ACM_READY(acm))
334 return;
335 tty = tty_port_tty_get(&acm->port);
336 + if (!tty)
337 + return;
338 tty_wakeup(tty);
339 tty_kref_put(tty);
340 }
341 @@ -652,8 +655,10 @@ static void acm_port_down(struct acm *acm, int drain)
342 usb_kill_urb(acm->ctrlurb);
343 for (i = 0; i < ACM_NW; i++)
344 usb_kill_urb(acm->wb[i].urb);
345 + tasklet_disable(&acm->urb_task);
346 for (i = 0; i < nr; i++)
347 usb_kill_urb(acm->ru[i].urb);
348 + tasklet_enable(&acm->urb_task);
349 acm->control->needs_remote_wakeup = 0;
350 usb_autopm_put_interface(acm->control);
351 }
352 diff --git a/drivers/usb/host/ehci-q.c b/drivers/usb/host/ehci-q.c
353 index c0d4b39..d4bd6ef 100644
354 --- a/drivers/usb/host/ehci-q.c
355 +++ b/drivers/usb/host/ehci-q.c
356 @@ -315,7 +315,6 @@ qh_completions (struct ehci_hcd *ehci, struct ehci_qh *qh)
357 int stopped;
358 unsigned count = 0;
359 u8 state;
360 - const __le32 halt = HALT_BIT(ehci);
361 struct ehci_qh_hw *hw = qh->hw;
362
363 if (unlikely (list_empty (&qh->qtd_list)))
364 @@ -422,7 +421,6 @@ qh_completions (struct ehci_hcd *ehci, struct ehci_qh *qh)
365 && !(qtd->hw_alt_next
366 & EHCI_LIST_END(ehci))) {
367 stopped = 1;
368 - goto halt;
369 }
370
371 /* stop scanning when we reach qtds the hc is using */
372 @@ -456,16 +454,6 @@ qh_completions (struct ehci_hcd *ehci, struct ehci_qh *qh)
373 */
374 ehci_clear_tt_buffer(ehci, qh, urb, token);
375 }
376 -
377 - /* force halt for unlinked or blocked qh, so we'll
378 - * patch the qh later and so that completions can't
379 - * activate it while we "know" it's stopped.
380 - */
381 - if ((halt & hw->hw_token) == 0) {
382 -halt:
383 - hw->hw_token |= halt;
384 - wmb ();
385 - }
386 }
387
388 /* unless we already know the urb's status, collect qtd status
389 diff --git a/drivers/usb/misc/uss720.c b/drivers/usb/misc/uss720.c
390 index 5a03b2e..56b1e73 100644
391 --- a/drivers/usb/misc/uss720.c
392 +++ b/drivers/usb/misc/uss720.c
393 @@ -176,12 +176,11 @@ static struct uss720_async_request *submit_async_request(struct parport_uss720_p
394 spin_lock_irqsave(&priv->asynclock, flags);
395 list_add_tail(&rq->asynclist, &priv->asynclist);
396 spin_unlock_irqrestore(&priv->asynclock, flags);
397 + kref_get(&rq->ref_count);
398 ret = usb_submit_urb(rq->urb, mem_flags);
399 - if (!ret) {
400 - kref_get(&rq->ref_count);
401 + if (!ret)
402 return rq;
403 - }
404 - kref_put(&rq->ref_count, destroy_async);
405 + destroy_async(&rq->ref_count);
406 err("submit_async_request submit_urb failed with %d", ret);
407 return NULL;
408 }
409 diff --git a/drivers/video/console/tileblit.c b/drivers/video/console/tileblit.c
410 index 0056a41..15e8e1a 100644
411 --- a/drivers/video/console/tileblit.c
412 +++ b/drivers/video/console/tileblit.c
413 @@ -83,7 +83,7 @@ static void tile_cursor(struct vc_data *vc, struct fb_info *info, int mode,
414 int softback_lines, int fg, int bg)
415 {
416 struct fb_tilecursor cursor;
417 - int use_sw = (vc->vc_cursor_type & 0x01);
418 + int use_sw = (vc->vc_cursor_type & 0x10);
419
420 cursor.sx = vc->vc_x;
421 cursor.sy = vc->vc_y;
422 diff --git a/fs/aio.c b/fs/aio.c
423 index b84a769..22a19ad 100644
424 --- a/fs/aio.c
425 +++ b/fs/aio.c
426 @@ -497,7 +497,7 @@ static inline void really_put_req(struct kioctx *ctx, struct kiocb *req)
427 ctx->reqs_active--;
428
429 if (unlikely(!ctx->reqs_active && ctx->dead))
430 - wake_up(&ctx->wait);
431 + wake_up_all(&ctx->wait);
432 }
433
434 static void aio_fput_routine(struct work_struct *data)
435 @@ -1219,7 +1219,7 @@ static void io_destroy(struct kioctx *ioctx)
436 * by other CPUs at this point. Right now, we rely on the
437 * locking done by the above calls to ensure this consistency.
438 */
439 - wake_up(&ioctx->wait);
440 + wake_up_all(&ioctx->wait);
441 put_ioctx(ioctx); /* once for the lookup */
442 }
443
444 diff --git a/fs/dcache.c b/fs/dcache.c
445 index a100fa3..44c0aea 100644
446 --- a/fs/dcache.c
447 +++ b/fs/dcache.c
448 @@ -1175,9 +1175,12 @@ struct dentry *d_obtain_alias(struct inode *inode)
449 spin_unlock(&tmp->d_lock);
450
451 spin_unlock(&dcache_lock);
452 + security_d_instantiate(tmp, inode);
453 return tmp;
454
455 out_iput:
456 + if (res && !IS_ERR(res))
457 + security_d_instantiate(res, inode);
458 iput(inode);
459 return res;
460 }
461 diff --git a/fs/ext3/super.c b/fs/ext3/super.c
462 index ca3068f..9cfa28d 100644
463 --- a/fs/ext3/super.c
464 +++ b/fs/ext3/super.c
465 @@ -1404,6 +1404,13 @@ static void ext3_orphan_cleanup (struct super_block * sb,
466 return;
467 }
468
469 + /* Check if feature set allows readwrite operations */
470 + if (EXT3_HAS_RO_COMPAT_FEATURE(sb, ~EXT3_FEATURE_RO_COMPAT_SUPP)) {
471 + printk(KERN_INFO "EXT3-fs: %s: Skipping orphan cleanup due to "
472 + "unknown ROCOMPAT features\n", sb->s_id);
473 + return;
474 + }
475 +
476 if (EXT3_SB(sb)->s_mount_state & EXT3_ERROR_FS) {
477 if (es->s_last_orphan)
478 jbd_debug(1, "Errors on filesystem, "
479 diff --git a/fs/nfsd/nfs4proc.c b/fs/nfsd/nfs4proc.c
480 index bebc0c2..01d83a5 100644
481 --- a/fs/nfsd/nfs4proc.c
482 +++ b/fs/nfsd/nfs4proc.c
483 @@ -964,8 +964,8 @@ typedef __be32(*nfsd4op_func)(struct svc_rqst *, struct nfsd4_compound_state *,
484 void *);
485 enum nfsd4_op_flags {
486 ALLOWED_WITHOUT_FH = 1 << 0, /* No current filehandle required */
487 - ALLOWED_ON_ABSENT_FS = 2 << 0, /* ops processed on absent fs */
488 - ALLOWED_AS_FIRST_OP = 3 << 0, /* ops reqired first in compound */
489 + ALLOWED_ON_ABSENT_FS = 1 << 1, /* ops processed on absent fs */
490 + ALLOWED_AS_FIRST_OP = 1 << 2, /* ops reqired first in compound */
491 };
492
493 struct nfsd4_operation {
494 diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c
495 index 4fde2c5..4a82a96 100644
496 --- a/fs/nfsd/nfs4xdr.c
497 +++ b/fs/nfsd/nfs4xdr.c
498 @@ -1114,7 +1114,7 @@ nfsd4_decode_create_session(struct nfsd4_compoundargs *argp,
499
500 u32 dummy;
501 char *machine_name;
502 - int i, j;
503 + int i;
504 int nr_secflavs;
505
506 READ_BUF(16);
507 @@ -1187,8 +1187,6 @@ nfsd4_decode_create_session(struct nfsd4_compoundargs *argp,
508 READ_BUF(4);
509 READ32(dummy);
510 READ_BUF(dummy * 4);
511 - for (j = 0; j < dummy; ++j)
512 - READ32(dummy);
513 break;
514 case RPC_AUTH_GSS:
515 dprintk("RPC_AUTH_GSS callback secflavor "
516 @@ -1204,7 +1202,6 @@ nfsd4_decode_create_session(struct nfsd4_compoundargs *argp,
517 READ_BUF(4);
518 READ32(dummy);
519 READ_BUF(dummy);
520 - p += XDR_QUADLEN(dummy);
521 break;
522 default:
523 dprintk("Illegal callback secflavor\n");
524 diff --git a/fs/proc/array.c b/fs/proc/array.c
525 index 2adedda..c5ef152 100644
526 --- a/fs/proc/array.c
527 +++ b/fs/proc/array.c
528 @@ -473,8 +473,8 @@ static int do_task_stat(struct seq_file *m, struct pid_namespace *ns,
529 vsize,
530 mm ? get_mm_rss(mm) : 0,
531 rsslim,
532 - mm ? mm->start_code : 0,
533 - mm ? mm->end_code : 0,
534 + mm ? (permitted ? mm->start_code : 1) : 0,
535 + mm ? (permitted ? mm->end_code : 1) : 0,
536 (permitted && mm) ? mm->start_stack : 0,
537 esp,
538 eip,
539 diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c
540 index e10ef04..3b7b82a 100644
541 --- a/fs/proc/task_mmu.c
542 +++ b/fs/proc/task_mmu.c
543 @@ -244,8 +244,8 @@ static void show_map_vma(struct seq_file *m, struct vm_area_struct *vma)
544 const char *name = arch_vma_name(vma);
545 if (!name) {
546 if (mm) {
547 - if (vma->vm_start <= mm->start_brk &&
548 - vma->vm_end >= mm->brk) {
549 + if (vma->vm_start <= mm->brk &&
550 + vma->vm_end >= mm->start_brk) {
551 name = "[heap]";
552 } else if (vma->vm_start <= mm->start_stack &&
553 vma->vm_end >= mm->start_stack) {
554 diff --git a/kernel/signal.c b/kernel/signal.c
555 index 423655a..e26d423 100644
556 --- a/kernel/signal.c
557 +++ b/kernel/signal.c
558 @@ -2351,9 +2351,13 @@ SYSCALL_DEFINE3(rt_sigqueueinfo, pid_t, pid, int, sig,
559 return -EFAULT;
560
561 /* Not even root can pretend to send signals from the kernel.
562 - Nor can they impersonate a kill(), which adds source info. */
563 - if (info.si_code >= 0)
564 + * Nor can they impersonate a kill()/tgkill(), which adds source info.
565 + */
566 + if (info.si_code != SI_QUEUE) {
567 + /* We used to allow any < 0 si_code */
568 + WARN_ON_ONCE(info.si_code < 0);
569 return -EPERM;
570 + }
571 info.si_signo = sig;
572
573 /* POSIX.1b doesn't mention process groups. */
574 @@ -2367,9 +2371,13 @@ long do_rt_tgsigqueueinfo(pid_t tgid, pid_t pid, int sig, siginfo_t *info)
575 return -EINVAL;
576
577 /* Not even root can pretend to send signals from the kernel.
578 - Nor can they impersonate a kill(), which adds source info. */
579 - if (info->si_code >= 0)
580 + * Nor can they impersonate a kill()/tgkill(), which adds source info.
581 + */
582 + if (info->si_code != SI_QUEUE) {
583 + /* We used to allow any < 0 si_code */
584 + WARN_ON_ONCE(info->si_code < 0);
585 return -EPERM;
586 + }
587 info->si_signo = sig;
588
589 return do_send_specific(tgid, pid, sig, info);
590 diff --git a/mm/shmem.c b/mm/shmem.c
591 index 356dd99..3e0005b 100644
592 --- a/mm/shmem.c
593 +++ b/mm/shmem.c
594 @@ -2691,5 +2691,6 @@ int shmem_zero_setup(struct vm_area_struct *vma)
595 fput(vma->vm_file);
596 vma->vm_file = file;
597 vma->vm_ops = &shmem_vm_ops;
598 + vma->vm_flags |= VM_CAN_NONLINEAR;
599 return 0;
600 }
601 diff --git a/net/sunrpc/xprtsock.c b/net/sunrpc/xprtsock.c
602 index b6fcf68..d270403 100644
603 --- a/net/sunrpc/xprtsock.c
604 +++ b/net/sunrpc/xprtsock.c
605 @@ -743,6 +743,8 @@ static void xs_reset_transport(struct sock_xprt *transport)
606 if (sk == NULL)
607 return;
608
609 + transport->srcport = 0;
610 +
611 write_lock_bh(&sk->sk_callback_lock);
612 transport->inet = NULL;
613 transport->sock = NULL;

  ViewVC Help
Powered by ViewVC 1.1.20