Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6

* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6:
[IA64] IOSAPIC bogus error cleanup
[IA64] Update printing of feature set bits
[IA64] Fix IOSAPIC delivery mode setting
[IA64] XPC heartbeat timer function must run on CPU 0
[IA64] Clean up /proc/interrupts output
[IA64] Disable/re-enable CPE interrupts on Altix
[IA64] Clean-up McKinley Errata message
[IA64] Add gate.lds to list of files ignored by Git
[IA64] Fix section mismatch in contig.c version of per_cpu_init()
[IA64] Wrong args to memset in efi_gettimeofday()
[IA64] Remove duplicate includes from ia32priv.h
[IA64] fix number of bytes zeroed by sys_fw_init() in arch/ia64/hp/sim/boot/fw-emu.c
[IA64] Fix perfmon sysctl directory modes

+165 -75
+1 -1
arch/ia64/hp/sim/boot/fw-emu.c
··· 285 285 } 286 286 cmd_line[arglen] = '\0'; 287 287 288 - memset(efi_systab, 0, sizeof(efi_systab)); 288 + memset(efi_systab, 0, sizeof(*efi_systab)); 289 289 efi_systab->hdr.signature = EFI_SYSTEM_TABLE_SIGNATURE; 290 290 efi_systab->hdr.revision = ((1 << 16) | 00); 291 291 efi_systab->hdr.headersize = sizeof(efi_systab->hdr);
-1
arch/ia64/ia32/ia32priv.h
··· 290 290 #define _ASM_IA64_ELF_H /* Don't include elf.h */ 291 291 292 292 #include <linux/sched.h> 293 - #include <asm/processor.h> 294 293 295 294 /* 296 295 * This is used to ensure we don't load something for the wrong architecture.
+1
arch/ia64/kernel/.gitignore
··· 1 + gate.lds
+5 -3
arch/ia64/kernel/acpi.c
··· 678 678 /* I/O APIC */ 679 679 680 680 if (acpi_table_parse_madt 681 - (ACPI_MADT_TYPE_IO_SAPIC, acpi_parse_iosapic, NR_IOSAPICS) < 1) 682 - printk(KERN_ERR PREFIX 683 - "Error parsing MADT - no IOSAPIC entries\n"); 681 + (ACPI_MADT_TYPE_IO_SAPIC, acpi_parse_iosapic, NR_IOSAPICS) < 1) { 682 + if (!ia64_platform_is("sn2")) 683 + printk(KERN_ERR PREFIX 684 + "Error parsing MADT - no IOSAPIC entries\n"); 685 + } 684 686 685 687 /* System-Level Interrupt Routing */ 686 688
+3 -2
arch/ia64/kernel/efi.c
··· 218 218 { 219 219 efi_time_t tm; 220 220 221 - memset(ts, 0, sizeof(ts)); 222 - if ((*efi.get_time)(&tm, NULL) != EFI_SUCCESS) 221 + if ((*efi.get_time)(&tm, NULL) != EFI_SUCCESS) { 222 + memset(ts, 0, sizeof(*ts)); 223 223 return; 224 + } 224 225 225 226 ts->tv_sec = mktime(tm.year, tm.month, tm.day, tm.hour, tm.minute, tm.second); 226 227 ts->tv_nsec = tm.nanosecond;
+15 -3
arch/ia64/kernel/iosapic.c
··· 748 748 #endif 749 749 } 750 750 751 + static inline unsigned char choose_dmode(void) 752 + { 753 + #ifdef CONFIG_SMP 754 + if (smp_int_redirect & SMP_IRQ_REDIRECTION) 755 + return IOSAPIC_LOWEST_PRIORITY; 756 + #endif 757 + return IOSAPIC_FIXED; 758 + } 759 + 751 760 /* 752 761 * ACPI can describe IOSAPIC interrupts via static tables and namespace 753 762 * methods. This provides an interface to register those interrupts and ··· 771 762 unsigned long flags; 772 763 struct iosapic_rte_info *rte; 773 764 u32 low32; 765 + unsigned char dmode; 774 766 775 767 /* 776 768 * If this GSI has already been registered (i.e., it's a ··· 801 791 802 792 spin_lock(&irq_desc[irq].lock); 803 793 dest = get_target_cpu(gsi, irq); 804 - err = register_intr(gsi, irq, IOSAPIC_LOWEST_PRIORITY, 805 - polarity, trigger); 794 + dmode = choose_dmode(); 795 + err = register_intr(gsi, irq, dmode, polarity, trigger); 806 796 if (err < 0) { 807 797 spin_unlock(&irq_desc[irq].lock); 808 798 irq = err; ··· 971 961 { 972 962 int vector, irq; 973 963 unsigned int dest = cpu_physical_id(smp_processor_id()); 964 + unsigned char dmode; 974 965 975 966 irq = vector = isa_irq_to_vector(isa_irq); 976 967 BUG_ON(bind_irq_vector(irq, vector, CPU_MASK_ALL)); 977 - register_intr(gsi, irq, IOSAPIC_LOWEST_PRIORITY, polarity, trigger); 968 + dmode = choose_dmode(); 969 + register_intr(gsi, irq, dmode, polarity, trigger); 978 970 979 971 DBG("ISA: IRQ %u -> GSI %u (%s,%s) -> CPU %d (0x%04x) vector %d\n", 980 972 isa_irq, gsi, trigger == IOSAPIC_EDGE ? "edge" : "level",
+4 -2
arch/ia64/kernel/irq.c
··· 61 61 unsigned long flags; 62 62 63 63 if (i == 0) { 64 - seq_printf(p, " "); 64 + char cpuname[16]; 65 + seq_printf(p, " "); 65 66 for_each_online_cpu(j) { 66 - seq_printf(p, "CPU%d ",j); 67 + snprintf(cpuname, 10, "CPU%d", j); 68 + seq_printf(p, "%10s ", cpuname); 67 69 } 68 70 seq_putc(p, '\n'); 69 71 }
+1 -1
arch/ia64/kernel/mca.c
··· 571 571 * Outputs 572 572 * None 573 573 */ 574 - static void __init 574 + void 575 575 ia64_mca_register_cpev (int cpev) 576 576 { 577 577 /* Register the CPE interrupt vector with SAL */
+79 -12
arch/ia64/kernel/palinfo.c
··· 470 470 return p - page; 471 471 } 472 472 473 - static const char *proc_features[]={ 473 + static char *proc_features_0[]={ /* Feature set 0 */ 474 474 NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL, 475 475 NULL,NULL,NULL,NULL,NULL,NULL,NULL, NULL,NULL, 476 476 NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL, ··· 502 502 "Enable BERR promotion" 503 503 }; 504 504 505 + static char *proc_features_16[]={ /* Feature set 16 */ 506 + "Disable ETM", 507 + "Enable ETM", 508 + "Enable MCA on half-way timer", 509 + "Enable snoop WC", 510 + NULL, 511 + "Enable Fast Deferral", 512 + "Disable MCA on memory aliasing", 513 + "Enable RSB", 514 + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 515 + "DP system processor", 516 + "Low Voltage", 517 + "HT supported", 518 + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 519 + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 520 + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 521 + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 522 + NULL, NULL, NULL, NULL, NULL 523 + }; 524 + 525 + static char **proc_features[]={ 526 + proc_features_0, 527 + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 528 + NULL, NULL, NULL, NULL, 529 + proc_features_16, 530 + NULL, NULL, NULL, NULL, 531 + }; 532 + 533 + static char * 534 + feature_set_info(char *page, u64 avail, u64 status, u64 control, u64 set) 535 + { 536 + char *p = page; 537 + char **vf, **v; 538 + int i; 539 + 540 + vf = v = proc_features[set]; 541 + for(i=0; i < 64; i++, avail >>=1, status >>=1, control >>=1) { 542 + 543 + if (!(control)) /* No remaining bits set */ 544 + break; 545 + if (!(avail & 0x1)) /* Print only bits that are available */ 546 + continue; 547 + if (vf) 548 + v = vf + i; 549 + if ( v && *v ) { 550 + p += sprintf(p, "%-40s : %s %s\n", *v, 551 + avail & 0x1 ? (status & 0x1 ? 552 + "On " : "Off"): "", 553 + avail & 0x1 ? (control & 0x1 ? 554 + "Ctrl" : "NoCtrl"): ""); 555 + } else { 556 + p += sprintf(p, "Feature set %2ld bit %2d\t\t\t" 557 + " : %s %s\n", 558 + set, i, 559 + avail & 0x1 ? (status & 0x1 ? 560 + "On " : "Off"): "", 561 + avail & 0x1 ? (control & 0x1 ? 562 + "Ctrl" : "NoCtrl"): ""); 563 + } 564 + } 565 + return p; 566 + } 505 567 506 568 static int 507 569 processor_info(char *page) 508 570 { 509 571 char *p = page; 510 - const char **v = proc_features; 511 - u64 avail=1, status=1, control=1; 512 - int i; 572 + u64 avail=1, status=1, control=1, feature_set=0; 513 573 s64 ret; 514 574 515 - if ((ret=ia64_pal_proc_get_features(&avail, &status, &control)) != 0) return 0; 575 + do { 576 + ret = ia64_pal_proc_get_features(&avail, &status, &control, 577 + feature_set); 578 + if (ret < 0) { 579 + return p - page; 580 + } 581 + if (ret == 1) { 582 + feature_set++; 583 + continue; 584 + } 516 585 517 - for(i=0; i < 64; i++, v++,avail >>=1, status >>=1, control >>=1) { 518 - if ( ! *v ) continue; 519 - p += sprintf(p, "%-40s : %s%s %s\n", *v, 520 - avail & 0x1 ? "" : "NotImpl", 521 - avail & 0x1 ? (status & 0x1 ? "On" : "Off"): "", 522 - avail & 0x1 ? (control & 0x1 ? "Ctrl" : "NoCtrl"): ""); 523 - } 586 + p = feature_set_info(p, avail, status, control, feature_set); 587 + 588 + feature_set++; 589 + } while(1); 590 + 524 591 return p - page; 525 592 } 526 593
-3
arch/ia64/kernel/patch.c
··· 129 129 first_time = 0; 130 130 if (need_workaround) 131 131 printk(KERN_INFO "Leaving McKinley Errata 9 workaround enabled\n"); 132 - else 133 - printk(KERN_INFO "McKinley Errata 9 workaround not needed; " 134 - "disabling it\n"); 135 132 } 136 133 if (need_workaround) 137 134 return;
+2 -2
arch/ia64/kernel/perfmon.c
··· 558 558 { 559 559 .ctl_name = CTL_UNNUMBERED, 560 560 .procname = "perfmon", 561 - .mode = 0755, 561 + .mode = 0555, 562 562 .child = pfm_ctl_table, 563 563 }, 564 564 {} ··· 567 567 { 568 568 .ctl_name = CTL_KERN, 569 569 .procname = "kernel", 570 - .mode = 0755, 570 + .mode = 0555, 571 571 .child = pfm_sysctl_dir, 572 572 }, 573 573 {}
+41 -33
arch/ia64/mm/contig.c
··· 146 146 return 0; 147 147 } 148 148 149 + #ifdef CONFIG_SMP 150 + static void *cpu_data; 151 + /** 152 + * per_cpu_init - setup per-cpu variables 153 + * 154 + * Allocate and setup per-cpu data areas. 155 + */ 156 + void * __cpuinit 157 + per_cpu_init (void) 158 + { 159 + int cpu; 160 + static int first_time=1; 161 + 162 + /* 163 + * get_free_pages() cannot be used before cpu_init() done. BSP 164 + * allocates "NR_CPUS" pages for all CPUs to avoid that AP calls 165 + * get_zeroed_page(). 166 + */ 167 + if (first_time) { 168 + first_time=0; 169 + for (cpu = 0; cpu < NR_CPUS; cpu++) { 170 + memcpy(cpu_data, __phys_per_cpu_start, __per_cpu_end - __per_cpu_start); 171 + __per_cpu_offset[cpu] = (char *) cpu_data - __per_cpu_start; 172 + cpu_data += PERCPU_PAGE_SIZE; 173 + per_cpu(local_per_cpu_offset, cpu) = __per_cpu_offset[cpu]; 174 + } 175 + } 176 + return __per_cpu_start + __per_cpu_offset[smp_processor_id()]; 177 + } 178 + 179 + static inline void 180 + alloc_per_cpu_data(void) 181 + { 182 + cpu_data = __alloc_bootmem(PERCPU_PAGE_SIZE * NR_CPUS, 183 + PERCPU_PAGE_SIZE, __pa(MAX_DMA_ADDRESS)); 184 + } 185 + #else 186 + #define alloc_per_cpu_data() do { } while (0) 187 + #endif /* CONFIG_SMP */ 188 + 149 189 /** 150 190 * find_memory - setup memory map 151 191 * ··· 222 182 223 183 find_initrd(); 224 184 185 + alloc_per_cpu_data(); 225 186 } 226 - 227 - #ifdef CONFIG_SMP 228 - /** 229 - * per_cpu_init - setup per-cpu variables 230 - * 231 - * Allocate and setup per-cpu data areas. 232 - */ 233 - void * __cpuinit 234 - per_cpu_init (void) 235 - { 236 - void *cpu_data; 237 - int cpu; 238 - static int first_time=1; 239 - 240 - /* 241 - * get_free_pages() cannot be used before cpu_init() done. BSP 242 - * allocates "NR_CPUS" pages for all CPUs to avoid that AP calls 243 - * get_zeroed_page(). 244 - */ 245 - if (first_time) { 246 - first_time=0; 247 - cpu_data = __alloc_bootmem(PERCPU_PAGE_SIZE * NR_CPUS, 248 - PERCPU_PAGE_SIZE, __pa(MAX_DMA_ADDRESS)); 249 - for (cpu = 0; cpu < NR_CPUS; cpu++) { 250 - memcpy(cpu_data, __phys_per_cpu_start, __per_cpu_end - __per_cpu_start); 251 - __per_cpu_offset[cpu] = (char *) cpu_data - __per_cpu_start; 252 - cpu_data += PERCPU_PAGE_SIZE; 253 - per_cpu(local_per_cpu_offset, cpu) = __per_cpu_offset[cpu]; 254 - } 255 - } 256 - return __per_cpu_start + __per_cpu_offset[smp_processor_id()]; 257 - } 258 - #endif /* CONFIG_SMP */ 259 187 260 188 static int 261 189 count_pages (u64 start, u64 end, void *arg)
+7 -1
arch/ia64/sn/kernel/irq.c
··· 5 5 * License. See the file "COPYING" in the main directory of this archive 6 6 * for more details. 7 7 * 8 - * Copyright (c) 2000-2006 Silicon Graphics, Inc. All Rights Reserved. 8 + * Copyright (c) 2000-2007 Silicon Graphics, Inc. All Rights Reserved. 9 9 */ 10 10 11 11 #include <linux/irq.h> ··· 85 85 { 86 86 } 87 87 88 + extern void ia64_mca_register_cpev(int); 89 + 88 90 static void sn_disable_irq(unsigned int irq) 89 91 { 92 + if (irq == local_vector_to_irq(IA64_CPE_VECTOR)) 93 + ia64_mca_register_cpev(0); 90 94 } 91 95 92 96 static void sn_enable_irq(unsigned int irq) 93 97 { 98 + if (irq == local_vector_to_irq(IA64_CPE_VECTOR)) 99 + ia64_mca_register_cpev(irq); 94 100 } 95 101 96 102 static void sn_ack_irq(unsigned int irq)
+3 -9
arch/ia64/sn/kernel/xpc_main.c
··· 3 3 * License. See the file "COPYING" in the main directory of this archive 4 4 * for more details. 5 5 * 6 - * Copyright (c) 2004-2006 Silicon Graphics, Inc. All Rights Reserved. 6 + * Copyright (c) 2004-2007 Silicon Graphics, Inc. All Rights Reserved. 7 7 */ 8 8 9 9 ··· 257 257 258 258 set_cpus_allowed(current, cpumask_of_cpu(XPC_HB_CHECK_CPU)); 259 259 260 + /* set our heartbeating to other partitions into motion */ 260 261 xpc_hb_check_timeout = jiffies + (xpc_hb_check_interval * HZ); 262 + xpc_hb_beater(0); 261 263 262 264 while (!(volatile int) xpc_exiting) { 263 265 ··· 1340 1338 dev_warn(xpc_part, "can't register die notifier\n"); 1341 1339 } 1342 1340 1343 - 1344 - /* 1345 - * Set the beating to other partitions into motion. This is 1346 - * the last requirement for other partitions' discovery to 1347 - * initiate communications with us. 1348 - */ 1349 1341 init_timer(&xpc_hb_timer); 1350 1342 xpc_hb_timer.function = xpc_hb_beater; 1351 - xpc_hb_beater(0); 1352 - 1353 1343 1354 1344 /* 1355 1345 * The real work-horse behind xpc. This processes incoming
+3 -2
include/asm-ia64/pal.h
··· 1379 1379 static inline s64 1380 1380 ia64_pal_proc_get_features (u64 *features_avail, 1381 1381 u64 *features_status, 1382 - u64 *features_control) 1382 + u64 *features_control, 1383 + u64 features_set) 1383 1384 { 1384 1385 struct ia64_pal_retval iprv; 1385 - PAL_CALL_PHYS(iprv, PAL_PROC_GET_FEATURES, 0, 0, 0); 1386 + PAL_CALL_PHYS(iprv, PAL_PROC_GET_FEATURES, 0, features_set, 0); 1386 1387 if (iprv.status == 0) { 1387 1388 *features_avail = iprv.v0; 1388 1389 *features_status = iprv.v1;