diff options
| author | Ingo Molnar <mingo@elte.hu> | 2008-07-21 11:19:50 -0400 |
|---|---|---|
| committer | Ingo Molnar <mingo@elte.hu> | 2008-07-21 11:19:50 -0400 |
| commit | eb6a12c2428d21a9f3e0f1a50e927d5fd80fc3d0 (patch) | |
| tree | 5ac6f43899648abeab1d43aad3107f664e7f13d5 /net/iucv | |
| parent | c4762aba0b1f72659aae9ce37b772ca8bd8f06f4 (diff) | |
| parent | 14b395e35d1afdd8019d11b92e28041fad591b71 (diff) | |
Merge branch 'linus' into cpus4096-for-linus
Conflicts:
net/sunrpc/svc.c
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'net/iucv')
| -rw-r--r-- | net/iucv/af_iucv.c | 1 | ||||
| -rw-r--r-- | net/iucv/iucv.c | 15 |
2 files changed, 11 insertions, 5 deletions
diff --git a/net/iucv/af_iucv.c b/net/iucv/af_iucv.c index bda71015885..29f7baa2511 100644 --- a/net/iucv/af_iucv.c +++ b/net/iucv/af_iucv.c | |||
| @@ -644,6 +644,7 @@ static int iucv_sock_sendmsg(struct kiocb *iocb, struct socket *sock, | |||
| 644 | } | 644 | } |
| 645 | 645 | ||
| 646 | txmsg.class = 0; | 646 | txmsg.class = 0; |
| 647 | memcpy(&txmsg.class, skb->data, skb->len >= 4 ? 4 : skb->len); | ||
| 647 | txmsg.tag = iucv->send_tag++; | 648 | txmsg.tag = iucv->send_tag++; |
| 648 | memcpy(skb->cb, &txmsg.tag, 4); | 649 | memcpy(skb->cb, &txmsg.tag, 4); |
| 649 | skb_queue_tail(&iucv->send_skb_q, skb); | 650 | skb_queue_tail(&iucv->send_skb_q, skb); |
diff --git a/net/iucv/iucv.c b/net/iucv/iucv.c index 411b339a0c8..705959b31e2 100644 --- a/net/iucv/iucv.c +++ b/net/iucv/iucv.c | |||
| @@ -474,14 +474,14 @@ static void iucv_setmask_mp(void) | |||
| 474 | { | 474 | { |
| 475 | int cpu; | 475 | int cpu; |
| 476 | 476 | ||
| 477 | preempt_disable(); | 477 | get_online_cpus(); |
| 478 | for_each_online_cpu(cpu) | 478 | for_each_online_cpu(cpu) |
| 479 | /* Enable all cpus with a declared buffer. */ | 479 | /* Enable all cpus with a declared buffer. */ |
| 480 | if (cpu_isset(cpu, iucv_buffer_cpumask) && | 480 | if (cpu_isset(cpu, iucv_buffer_cpumask) && |
| 481 | !cpu_isset(cpu, iucv_irq_cpumask)) | 481 | !cpu_isset(cpu, iucv_irq_cpumask)) |
| 482 | smp_call_function_single(cpu, iucv_allow_cpu, | 482 | smp_call_function_single(cpu, iucv_allow_cpu, |
| 483 | NULL, 1); | 483 | NULL, 1); |
| 484 | preempt_enable(); | 484 | put_online_cpus(); |
| 485 | } | 485 | } |
| 486 | 486 | ||
| 487 | /** | 487 | /** |
| @@ -521,16 +521,18 @@ static int iucv_enable(void) | |||
| 521 | goto out; | 521 | goto out; |
| 522 | /* Declare per cpu buffers. */ | 522 | /* Declare per cpu buffers. */ |
| 523 | rc = -EIO; | 523 | rc = -EIO; |
| 524 | preempt_disable(); | 524 | get_online_cpus(); |
| 525 | for_each_online_cpu(cpu) | 525 | for_each_online_cpu(cpu) |
| 526 | smp_call_function_single(cpu, iucv_declare_cpu, NULL, 1); | 526 | smp_call_function_single(cpu, iucv_declare_cpu, NULL, 1); |
| 527 | preempt_enable(); | 527 | preempt_enable(); |
| 528 | if (cpus_empty(iucv_buffer_cpumask)) | 528 | if (cpus_empty(iucv_buffer_cpumask)) |
| 529 | /* No cpu could declare an iucv buffer. */ | 529 | /* No cpu could declare an iucv buffer. */ |
| 530 | goto out_path; | 530 | goto out_path; |
| 531 | put_online_cpus(); | ||
| 531 | return 0; | 532 | return 0; |
| 532 | 533 | ||
| 533 | out_path: | 534 | out_path: |
| 535 | put_online_cpus(); | ||
| 534 | kfree(iucv_path_table); | 536 | kfree(iucv_path_table); |
| 535 | out: | 537 | out: |
| 536 | return rc; | 538 | return rc; |
| @@ -564,8 +566,11 @@ static int __cpuinit iucv_cpu_notify(struct notifier_block *self, | |||
| 564 | return NOTIFY_BAD; | 566 | return NOTIFY_BAD; |
| 565 | iucv_param[cpu] = kmalloc_node(sizeof(union iucv_param), | 567 | iucv_param[cpu] = kmalloc_node(sizeof(union iucv_param), |
| 566 | GFP_KERNEL|GFP_DMA, cpu_to_node(cpu)); | 568 | GFP_KERNEL|GFP_DMA, cpu_to_node(cpu)); |
| 567 | if (!iucv_param[cpu]) | 569 | if (!iucv_param[cpu]) { |
| 570 | kfree(iucv_irq_data[cpu]); | ||
| 571 | iucv_irq_data[cpu] = NULL; | ||
| 568 | return NOTIFY_BAD; | 572 | return NOTIFY_BAD; |
| 573 | } | ||
| 569 | break; | 574 | break; |
| 570 | case CPU_UP_CANCELED: | 575 | case CPU_UP_CANCELED: |
| 571 | case CPU_UP_CANCELED_FROZEN: | 576 | case CPU_UP_CANCELED_FROZEN: |
| @@ -598,7 +603,7 @@ static int __cpuinit iucv_cpu_notify(struct notifier_block *self, | |||
| 598 | return NOTIFY_OK; | 603 | return NOTIFY_OK; |
| 599 | } | 604 | } |
| 600 | 605 | ||
| 601 | static struct notifier_block __cpuinitdata iucv_cpu_notifier = { | 606 | static struct notifier_block __refdata iucv_cpu_notifier = { |
| 602 | .notifier_call = iucv_cpu_notify, | 607 | .notifier_call = iucv_cpu_notify, |
| 603 | }; | 608 | }; |
| 604 | 609 | ||
