diff for duplicates of <4E031B97.2010609@jp.fujitsu.com> diff --git a/a/1.txt b/N1/1.txt index ff845f2..339025d 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -50,7 +50,7 @@ index a06dfb1..226c3bb 100644 for (cpu = low_cpu; cpu < high_cpu; cpu++) { - cpu_set(cpu, early_cpu_possible_map); + cpumask_set_cpu(cpu, &early_cpu_possible_map); - if (node_cpuid[cpu].nid = NUMA_NO_NODE) { + if (node_cpuid[cpu].nid == NUMA_NO_NODE) { node_cpuid[cpu].nid = next_nid; next_nid++; diff --git a/arch/ia64/kernel/acpi.c b/arch/ia64/kernel/acpi.c @@ -151,8 +151,8 @@ index 782c3a35..4a04304 100644 + cpumask_and(&mask, &domain, cpu_online_mask); + if (cpumask_empty(&mask)) return -EINVAL; -- if ((cfg->vector = vector) && cpus_equal(cfg->domain, domain)) -+ if ((cfg->vector = vector) && cpumask_equal(&cfg->domain, &domain)) +- if ((cfg->vector == vector) && cpus_equal(cfg->domain, domain)) ++ if ((cfg->vector == vector) && cpumask_equal(&cfg->domain, &domain)) return 0; if (cfg->vector != IRQ_VECTOR_UNASSIGNED) return -EBUSY; @@ -168,7 +168,7 @@ index 782c3a35..4a04304 100644 } @@ -179,13 +179,13 @@ static void __clear_irq_vector(int irq) - BUG_ON(cfg->vector = IRQ_VECTOR_UNASSIGNED); + BUG_ON(cfg->vector == IRQ_VECTOR_UNASSIGNED); vector = cfg->vector; domain = cfg->domain; - cpus_and(mask, cfg->domain, cpu_online_map); @@ -207,7 +207,7 @@ index 782c3a35..4a04304 100644 @@ -271,7 +272,7 @@ static enum vector_domain_type { static cpumask_t vector_allocation_domain(int cpu) { - if (vector_domain_type = VECTOR_DOMAIN_PERCPU) + if (vector_domain_type == VECTOR_DOMAIN_PERCPU) - return cpumask_of_cpu(cpu); + return *cpumask_of(cpu); return CPU_MASK_ALL; @@ -215,7 +215,7 @@ index 782c3a35..4a04304 100644 @@ -285,7 +286,7 @@ static int __irq_prepare_move(int irq, int cpu) return -EBUSY; - if (cfg->vector = IRQ_VECTOR_UNASSIGNED || !cpu_online(cpu)) + if (cfg->vector == IRQ_VECTOR_UNASSIGNED || !cpu_online(cpu)) return -EINVAL; - if (cpu_isset(cpu, cfg->domain)) + if (cpumask_test_cpu(cpu, &cfg->domain)) @@ -360,7 +360,8 @@ index 009df54..8aa458c 100644 + dest = cpu_physical_id(cpumask_first(&mask)); msg->address_hi = 0; - msg->address_lo diff --git a/arch/ia64/kernel/numa.c b/arch/ia64/kernel/numa.c + msg->address_lo = +diff --git a/arch/ia64/kernel/numa.c b/arch/ia64/kernel/numa.c index c93420c..4d5437e 100644 --- a/arch/ia64/kernel/numa.c +++ b/arch/ia64/kernel/numa.c @@ -480,7 +481,7 @@ index 79802e5..b47c530 100644 data->saved_num = 0; @@ -514,7 +515,7 @@ salinfo_log_clear(struct salinfo_data *data, int cpu) salinfo_log_new_read(cpu, data); - if (data->state = STATE_LOG_RECORD) { + if (data->state == STATE_LOG_RECORD) { spin_lock_irqsave(&data_saved_lock, flags); - cpu_set(cpu, data->cpu_event); + cpumask_set_cpu(cpu, &data->cpu_event); @@ -531,9 +532,9 @@ index 5e2c724..2112cb9 100644 # ifdef CONFIG_ACPI_HOTPLUG_CPU prefill_possible_map(); # endif -- per_cpu_scan_finalize((cpus_weight(early_cpu_possible_map) = 0 ? +- per_cpu_scan_finalize((cpus_weight(early_cpu_possible_map) == 0 ? - 32 : cpus_weight(early_cpu_possible_map)), -+ per_cpu_scan_finalize((cpumask_weight(&early_cpu_possible_map) = 0 ? ++ per_cpu_scan_finalize((cpumask_weight(&early_cpu_possible_map) == 0 ? + 32 : cpumask_weight(&early_cpu_possible_map)), additional_cpus > 0 ? additional_cpus : 0); # endif @@ -550,7 +551,7 @@ index 5e2c724..2112cb9 100644 @@ -915,8 +915,8 @@ cpu_init (void) * (must be done after per_cpu area is setup) */ - if (smp_processor_id() = 0) { + if (smp_processor_id() == 0) { - cpu_set(0, per_cpu(cpu_sibling_map, 0)); - cpu_set(0, cpu_core_map[0]); + cpumask_set_cpu(0, &per_cpu(cpu_sibling_map, 0)); @@ -590,7 +591,7 @@ index be450a3..9f86422 100644 mb(); - for_each_cpu_mask(cpu, cpumask) { + for_each_cpu(cpu, &cpumask) { - if (cpu = mycpu) + if (cpu == mycpu) flush_mycpu = 1; else @@ -277,7 +278,7 @@ smp_flush_tlb_cpumask(cpumask_t xcpumask) @@ -599,7 +600,7 @@ index be450a3..9f86422 100644 - for_each_cpu_mask(cpu, cpumask) + for_each_cpu(cpu, &cpumask) - while(counts[cpu] = (local_tlb_flush_counts[cpu].count & 0xffff)) + while(counts[cpu] == (local_tlb_flush_counts[cpu].count & 0xffff)) udelay(FLUSH_DELAY); diff --git a/arch/ia64/kernel/smpboot.c b/arch/ia64/kernel/smpboot.c @@ -692,8 +693,8 @@ index 14ec641..a5b6526 100644 } @@ -661,12 +661,12 @@ remove_siblinginfo(int cpu) - if (cpu_data(cpu)->threads_per_core = 1 && - cpu_data(cpu)->cores_per_socket = 1) { + if (cpu_data(cpu)->threads_per_core == 1 && + cpu_data(cpu)->cores_per_socket == 1) { - cpu_clear(cpu, cpu_core_map[cpu]); - cpu_clear(cpu, per_cpu(cpu_sibling_map, cpu)); + cpumask_clear_cpu(cpu, &cpu_core_map[cpu]); @@ -701,8 +702,8 @@ index 14ec641..a5b6526 100644 return; } -- last = (cpus_weight(cpu_core_map[cpu]) = 1 ? 1 : 0); -+ last = (cpumask_weight(&cpu_core_map[cpu]) = 1 ? 1 : 0); +- last = (cpus_weight(cpu_core_map[cpu]) == 1 ? 1 : 0); ++ last = (cpumask_weight(&cpu_core_map[cpu]) == 1 ? 1 : 0); /* remove it from all sibling map's */ clear_cpu_sibling_map(cpu); @@ -739,12 +740,12 @@ index 14ec641..a5b6526 100644 @@ -788,11 +788,11 @@ set_cpu_sibling_map(int cpu) for_each_online_cpu(i) { - if ((cpu_data(cpu)->socket_id = cpu_data(i)->socket_id)) { + if ((cpu_data(cpu)->socket_id == cpu_data(i)->socket_id)) { - cpu_set(i, cpu_core_map[cpu]); - cpu_set(cpu, cpu_core_map[i]); + cpumask_set_cpu(i, &cpu_core_map[cpu]); + cpumask_set_cpu(cpu, &cpu_core_map[i]); - if (cpu_data(cpu)->core_id = cpu_data(i)->core_id) { + if (cpu_data(cpu)->core_id == cpu_data(i)->core_id) { - cpu_set(i, per_cpu(cpu_sibling_map, cpu)); - cpu_set(cpu, per_cpu(cpu_sibling_map, i)); + cpumask_set_cpu(i, &per_cpu(cpu_sibling_map, cpu)); @@ -763,8 +764,8 @@ index 14ec641..a5b6526 100644 per_cpu(cpu_state, cpu) = CPU_UP_PREPARE; @@ -823,8 +823,8 @@ __cpu_up (unsigned int cpu) - if (cpu_data(cpu)->threads_per_core = 1 && - cpu_data(cpu)->cores_per_socket = 1) { + if (cpu_data(cpu)->threads_per_core == 1 && + cpu_data(cpu)->cores_per_socket == 1) { - cpu_set(cpu, per_cpu(cpu_sibling_map, cpu)); - cpu_set(cpu, cpu_core_map[cpu]); + cpumask_set_cpu(cpu, &per_cpu(cpu_sibling_map, cpu)); @@ -786,9 +787,9 @@ index 0e0e0cc..737a5b4 100644 } @@ -163,7 +163,7 @@ static void __cpuinit cache_shared_cpu_map_setup( unsigned int cpu, - if (cpu_data(cpu)->socket_id = cpu_data(j)->socket_id - && cpu_data(j)->core_id = csi.log1_cid - && cpu_data(j)->thread_id = csi.log1_tid) + if (cpu_data(cpu)->socket_id == cpu_data(j)->socket_id + && cpu_data(j)->core_id == csi.log1_cid + && cpu_data(j)->thread_id == csi.log1_tid) - cpu_set(j, this_leaf->shared_cpu_map); + cpumask_set_cpu(j, &this_leaf->shared_cpu_map); diff --git a/a/content_digest b/N1/content_digest index 7030187..d6472c1 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -1,6 +1,6 @@ "From\0KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>\0" "Subject\0ia64: replace old cpumask functions with new one\0" - "Date\0Thu, 23 Jun 2011 10:55:19 +0000\0" + "Date\0Thu, 23 Jun 2011 19:55:19 +0900\0" "To\0tony.luck@intel.com" fenghua.yu@intel.com linux-ia64@vger.kernel.org @@ -60,7 +60,7 @@ " \tfor (cpu = low_cpu; cpu < high_cpu; cpu++) {\n" "-\t\tcpu_set(cpu, early_cpu_possible_map);\n" "+\t\tcpumask_set_cpu(cpu, &early_cpu_possible_map);\n" - " \t\tif (node_cpuid[cpu].nid = NUMA_NO_NODE) {\n" + " \t\tif (node_cpuid[cpu].nid == NUMA_NO_NODE) {\n" " \t\t\tnode_cpuid[cpu].nid = next_nid;\n" " \t\t\tnext_nid++;\n" "diff --git a/arch/ia64/kernel/acpi.c b/arch/ia64/kernel/acpi.c\n" @@ -161,8 +161,8 @@ "+\tcpumask_and(&mask, &domain, cpu_online_mask);\n" "+\tif (cpumask_empty(&mask))\n" " \t\treturn -EINVAL;\n" - "-\tif ((cfg->vector = vector) && cpus_equal(cfg->domain, domain))\n" - "+\tif ((cfg->vector = vector) && cpumask_equal(&cfg->domain, &domain))\n" + "-\tif ((cfg->vector == vector) && cpus_equal(cfg->domain, domain))\n" + "+\tif ((cfg->vector == vector) && cpumask_equal(&cfg->domain, &domain))\n" " \t\treturn 0;\n" " \tif (cfg->vector != IRQ_VECTOR_UNASSIGNED)\n" " \t\treturn -EBUSY;\n" @@ -178,7 +178,7 @@ " }\n" "\n" "@@ -179,13 +179,13 @@ static void __clear_irq_vector(int irq)\n" - " \tBUG_ON(cfg->vector = IRQ_VECTOR_UNASSIGNED);\n" + " \tBUG_ON(cfg->vector == IRQ_VECTOR_UNASSIGNED);\n" " \tvector = cfg->vector;\n" " \tdomain = cfg->domain;\n" "-\tcpus_and(mask, cfg->domain, cpu_online_map);\n" @@ -217,7 +217,7 @@ "@@ -271,7 +272,7 @@ static enum vector_domain_type {\n" " static cpumask_t vector_allocation_domain(int cpu)\n" " {\n" - " \tif (vector_domain_type = VECTOR_DOMAIN_PERCPU)\n" + " \tif (vector_domain_type == VECTOR_DOMAIN_PERCPU)\n" "-\t\treturn cpumask_of_cpu(cpu);\n" "+\t\treturn *cpumask_of(cpu);\n" " \treturn CPU_MASK_ALL;\n" @@ -225,7 +225,7 @@ "\n" "@@ -285,7 +286,7 @@ static int __irq_prepare_move(int irq, int cpu)\n" " \t\treturn -EBUSY;\n" - " \tif (cfg->vector = IRQ_VECTOR_UNASSIGNED || !cpu_online(cpu))\n" + " \tif (cfg->vector == IRQ_VECTOR_UNASSIGNED || !cpu_online(cpu))\n" " \t\treturn -EINVAL;\n" "-\tif (cpu_isset(cpu, cfg->domain))\n" "+\tif (cpumask_test_cpu(cpu, &cfg->domain))\n" @@ -370,7 +370,8 @@ "+\tdest = cpu_physical_id(cpumask_first(&mask));\n" "\n" " \tmsg->address_hi = 0;\n" - " \tmsg->address_lo diff --git a/arch/ia64/kernel/numa.c b/arch/ia64/kernel/numa.c\n" + " \tmsg->address_lo =\n" + "diff --git a/arch/ia64/kernel/numa.c b/arch/ia64/kernel/numa.c\n" "index c93420c..4d5437e 100644\n" "--- a/arch/ia64/kernel/numa.c\n" "+++ b/arch/ia64/kernel/numa.c\n" @@ -490,7 +491,7 @@ " \t\tdata->saved_num = 0;\n" "@@ -514,7 +515,7 @@ salinfo_log_clear(struct salinfo_data *data, int cpu)\n" " \tsalinfo_log_new_read(cpu, data);\n" - " \tif (data->state = STATE_LOG_RECORD) {\n" + " \tif (data->state == STATE_LOG_RECORD) {\n" " \t\tspin_lock_irqsave(&data_saved_lock, flags);\n" "-\t\tcpu_set(cpu, data->cpu_event);\n" "+\t\tcpumask_set_cpu(cpu, &data->cpu_event);\n" @@ -541,9 +542,9 @@ " # ifdef CONFIG_ACPI_HOTPLUG_CPU\n" " \tprefill_possible_map();\n" " # endif\n" - "-\tper_cpu_scan_finalize((cpus_weight(early_cpu_possible_map) = 0 ?\n" + "-\tper_cpu_scan_finalize((cpus_weight(early_cpu_possible_map) == 0 ?\n" "-\t\t32 : cpus_weight(early_cpu_possible_map)),\n" - "+\tper_cpu_scan_finalize((cpumask_weight(&early_cpu_possible_map) = 0 ?\n" + "+\tper_cpu_scan_finalize((cpumask_weight(&early_cpu_possible_map) == 0 ?\n" "+\t\t32 : cpumask_weight(&early_cpu_possible_map)),\n" " \t\tadditional_cpus > 0 ? additional_cpus : 0);\n" " # endif\n" @@ -560,7 +561,7 @@ "@@ -915,8 +915,8 @@ cpu_init (void)\n" " \t * (must be done after per_cpu area is setup)\n" " \t */\n" - " \tif (smp_processor_id() = 0) {\n" + " \tif (smp_processor_id() == 0) {\n" "-\t\tcpu_set(0, per_cpu(cpu_sibling_map, 0));\n" "-\t\tcpu_set(0, cpu_core_map[0]);\n" "+\t\tcpumask_set_cpu(0, &per_cpu(cpu_sibling_map, 0));\n" @@ -600,7 +601,7 @@ " \tmb();\n" "-\tfor_each_cpu_mask(cpu, cpumask) {\n" "+\tfor_each_cpu(cpu, &cpumask) {\n" - " \t\tif (cpu = mycpu)\n" + " \t\tif (cpu == mycpu)\n" " \t\t\tflush_mycpu = 1;\n" " \t\telse\n" "@@ -277,7 +278,7 @@ smp_flush_tlb_cpumask(cpumask_t xcpumask)\n" @@ -609,7 +610,7 @@ "\n" "-\tfor_each_cpu_mask(cpu, cpumask)\n" "+\tfor_each_cpu(cpu, &cpumask)\n" - " \t\twhile(counts[cpu] = (local_tlb_flush_counts[cpu].count & 0xffff))\n" + " \t\twhile(counts[cpu] == (local_tlb_flush_counts[cpu].count & 0xffff))\n" " \t\t\tudelay(FLUSH_DELAY);\n" "\n" "diff --git a/arch/ia64/kernel/smpboot.c b/arch/ia64/kernel/smpboot.c\n" @@ -702,8 +703,8 @@ " }\n" "@@ -661,12 +661,12 @@ remove_siblinginfo(int cpu)\n" "\n" - " \tif (cpu_data(cpu)->threads_per_core = 1 &&\n" - " \t cpu_data(cpu)->cores_per_socket = 1) {\n" + " \tif (cpu_data(cpu)->threads_per_core == 1 &&\n" + " \t cpu_data(cpu)->cores_per_socket == 1) {\n" "-\t\tcpu_clear(cpu, cpu_core_map[cpu]);\n" "-\t\tcpu_clear(cpu, per_cpu(cpu_sibling_map, cpu));\n" "+\t\tcpumask_clear_cpu(cpu, &cpu_core_map[cpu]);\n" @@ -711,8 +712,8 @@ " \t\treturn;\n" " \t}\n" "\n" - "-\tlast = (cpus_weight(cpu_core_map[cpu]) = 1 ? 1 : 0);\n" - "+\tlast = (cpumask_weight(&cpu_core_map[cpu]) = 1 ? 1 : 0);\n" + "-\tlast = (cpus_weight(cpu_core_map[cpu]) == 1 ? 1 : 0);\n" + "+\tlast = (cpumask_weight(&cpu_core_map[cpu]) == 1 ? 1 : 0);\n" "\n" " \t/* remove it from all sibling map's */\n" " \tclear_cpu_sibling_map(cpu);\n" @@ -749,12 +750,12 @@ "@@ -788,11 +788,11 @@ set_cpu_sibling_map(int cpu)\n" "\n" " \tfor_each_online_cpu(i) {\n" - " \t\tif ((cpu_data(cpu)->socket_id = cpu_data(i)->socket_id)) {\n" + " \t\tif ((cpu_data(cpu)->socket_id == cpu_data(i)->socket_id)) {\n" "-\t\t\tcpu_set(i, cpu_core_map[cpu]);\n" "-\t\t\tcpu_set(cpu, cpu_core_map[i]);\n" "+\t\t\tcpumask_set_cpu(i, &cpu_core_map[cpu]);\n" "+\t\t\tcpumask_set_cpu(cpu, &cpu_core_map[i]);\n" - " \t\t\tif (cpu_data(cpu)->core_id = cpu_data(i)->core_id) {\n" + " \t\t\tif (cpu_data(cpu)->core_id == cpu_data(i)->core_id) {\n" "-\t\t\t\tcpu_set(i, per_cpu(cpu_sibling_map, cpu));\n" "-\t\t\t\tcpu_set(cpu, per_cpu(cpu_sibling_map, i));\n" "+\t\t\t\tcpumask_set_cpu(i, &per_cpu(cpu_sibling_map, cpu));\n" @@ -773,8 +774,8 @@ " \tper_cpu(cpu_state, cpu) = CPU_UP_PREPARE;\n" "@@ -823,8 +823,8 @@ __cpu_up (unsigned int cpu)\n" "\n" - " \tif (cpu_data(cpu)->threads_per_core = 1 &&\n" - " \t cpu_data(cpu)->cores_per_socket = 1) {\n" + " \tif (cpu_data(cpu)->threads_per_core == 1 &&\n" + " \t cpu_data(cpu)->cores_per_socket == 1) {\n" "-\t\tcpu_set(cpu, per_cpu(cpu_sibling_map, cpu));\n" "-\t\tcpu_set(cpu, cpu_core_map[cpu]);\n" "+\t\tcpumask_set_cpu(cpu, &per_cpu(cpu_sibling_map, cpu));\n" @@ -796,9 +797,9 @@ " \t}\n" "\n" "@@ -163,7 +163,7 @@ static void __cpuinit cache_shared_cpu_map_setup( unsigned int cpu,\n" - " \t\t\tif (cpu_data(cpu)->socket_id = cpu_data(j)->socket_id\n" - " \t\t\t\t&& cpu_data(j)->core_id = csi.log1_cid\n" - " \t\t\t\t&& cpu_data(j)->thread_id = csi.log1_tid)\n" + " \t\t\tif (cpu_data(cpu)->socket_id == cpu_data(j)->socket_id\n" + " \t\t\t\t&& cpu_data(j)->core_id == csi.log1_cid\n" + " \t\t\t\t&& cpu_data(j)->thread_id == csi.log1_tid)\n" "-\t\t\t\tcpu_set(j, this_leaf->shared_cpu_map);\n" "+\t\t\t\tcpumask_set_cpu(j, &this_leaf->shared_cpu_map);\n" "\n" @@ -848,4 +849,4 @@ "-- \n" 1.7.3.1 -557235203890e50a9d4ae8887b0b44a0326cab0e672d5fbf48aba3a54db616d0 +c459ca91e330ce771a0fa4d880c1fe0d0b9c6057c729214b913461407a38d115
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.