Skip to content

Commit

Permalink
Merge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/li…
Browse files Browse the repository at this point in the history
…nux/kernel/git/tip/linux-2.6-tip

* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  x86, dmi, debug: Log board name (when present) in dmesg/oops output
  x86, ioapic: Don't warn about non-existing IOAPICs if we have none
  x86: Fix mwait_usable section mismatch
  x86: Readd missing irq_to_desc() in fixup_irq()
  x86: Fix section mismatch in LAPIC initialization
  • Loading branch information
torvalds committed Feb 15, 2011
2 parents 87450bd + 84e383b commit fef86db
Show file tree
Hide file tree
Showing 8 changed files with 42 additions and 15 deletions.
1 change: 1 addition & 0 deletions arch/x86/include/asm/apic.h
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,7 @@ extern void sync_Arb_IDs(void);
extern void init_bsp_APIC(void);
extern void setup_local_APIC(void);
extern void end_local_APIC_setup(void);
extern void bsp_end_local_APIC_setup(void);
extern void init_apic_mappings(void);
void register_lapic_address(unsigned long address);
extern void setup_boot_APIC_clock(void);
Expand Down
2 changes: 1 addition & 1 deletion arch/x86/include/asm/cpu.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,6 @@ extern void arch_unregister_cpu(int);

DECLARE_PER_CPU(int, cpu_state);

int __cpuinit mwait_usable(const struct cpuinfo_x86 *);
int mwait_usable(const struct cpuinfo_x86 *);

#endif /* _ASM_X86_CPU_H */
9 changes: 7 additions & 2 deletions arch/x86/kernel/apic/apic.c
Original file line number Diff line number Diff line change
Expand Up @@ -1381,12 +1381,17 @@ void __cpuinit end_local_APIC_setup(void)
#endif

apic_pm_activate();
}

void __init bsp_end_local_APIC_setup(void)
{
end_local_APIC_setup();

/*
* Now that local APIC setup is completed for BP, configure the fault
* handling for interrupt remapping.
*/
if (!smp_processor_id() && intr_remapping_enabled)
if (intr_remapping_enabled)
enable_drhd_fault_handling();

}
Expand Down Expand Up @@ -1756,7 +1761,7 @@ int __init APIC_init_uniprocessor(void)
enable_IO_APIC();
#endif

end_local_APIC_setup();
bsp_end_local_APIC_setup();

#ifdef CONFIG_X86_IO_APIC
if (smp_found_config && !skip_ioapic_setup && nr_ioapics)
Expand Down
3 changes: 3 additions & 0 deletions arch/x86/kernel/apic/io_apic.c
Original file line number Diff line number Diff line change
Expand Up @@ -4002,6 +4002,9 @@ int mp_find_ioapic(u32 gsi)
{
int i = 0;

if (nr_ioapics == 0)
return -1;

/* Find the IOAPIC that manages this GSI. */
for (i = 0; i < nr_ioapics; i++) {
if ((gsi >= mp_gsi_routing[i].gsi_base)
Expand Down
3 changes: 2 additions & 1 deletion arch/x86/kernel/irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,8 @@ void fixup_irqs(void)
if (irr & (1 << (vector % 32))) {
irq = __this_cpu_read(vector_irq[vector]);

data = irq_get_irq_data(irq);
desc = irq_to_desc(irq);
data = &desc->irq_data;
raw_spin_lock(&desc->lock);
if (data->chip->irq_retrigger)
data->chip->irq_retrigger(data);
Expand Down
24 changes: 17 additions & 7 deletions arch/x86/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -92,21 +92,31 @@ void show_regs(struct pt_regs *regs)

void show_regs_common(void)
{
const char *board, *product;
const char *vendor, *product, *board;

board = dmi_get_system_info(DMI_BOARD_NAME);
if (!board)
board = "";
vendor = dmi_get_system_info(DMI_SYS_VENDOR);
if (!vendor)
vendor = "";
product = dmi_get_system_info(DMI_PRODUCT_NAME);
if (!product)
product = "";

/* Board Name is optional */
board = dmi_get_system_info(DMI_BOARD_NAME);

printk(KERN_CONT "\n");
printk(KERN_DEFAULT "Pid: %d, comm: %.20s %s %s %.*s %s/%s\n",
printk(KERN_DEFAULT "Pid: %d, comm: %.20s %s %s %.*s",
current->pid, current->comm, print_tainted(),
init_utsname()->release,
(int)strcspn(init_utsname()->version, " "),
init_utsname()->version, board, product);
init_utsname()->version);
printk(KERN_CONT " ");
printk(KERN_CONT "%s %s", vendor, product);
if (board) {
printk(KERN_CONT "/");
printk(KERN_CONT "%s", board);
}
printk(KERN_CONT "\n");
}

void flush_thread(void)
Expand Down Expand Up @@ -506,7 +516,7 @@ static void poll_idle(void)
#define MWAIT_ECX_EXTENDED_INFO 0x01
#define MWAIT_EDX_C1 0xf0

int __cpuinit mwait_usable(const struct cpuinfo_x86 *c)
int mwait_usable(const struct cpuinfo_x86 *c)
{
u32 eax, ebx, ecx, edx;

Expand Down
4 changes: 2 additions & 2 deletions arch/x86/kernel/smpboot.c
Original file line number Diff line number Diff line change
Expand Up @@ -1060,7 +1060,7 @@ static int __init smp_sanity_check(unsigned max_cpus)

connect_bsp_APIC();
setup_local_APIC();
end_local_APIC_setup();
bsp_end_local_APIC_setup();
return -1;
}

Expand Down Expand Up @@ -1137,7 +1137,7 @@ void __init native_smp_prepare_cpus(unsigned int max_cpus)
if (!skip_ioapic_setup && nr_ioapics)
enable_IO_APIC();

end_local_APIC_setup();
bsp_end_local_APIC_setup();

map_cpu_to_logical_apicid();

Expand Down
11 changes: 9 additions & 2 deletions drivers/firmware/dmi_scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -378,10 +378,17 @@ static void __init print_filtered(const char *info)

static void __init dmi_dump_ids(void)
{
const char *board; /* Board Name is optional */

printk(KERN_DEBUG "DMI: ");
print_filtered(dmi_get_system_info(DMI_BOARD_NAME));
printk(KERN_CONT "/");
print_filtered(dmi_get_system_info(DMI_SYS_VENDOR));
printk(KERN_CONT " ");
print_filtered(dmi_get_system_info(DMI_PRODUCT_NAME));
board = dmi_get_system_info(DMI_BOARD_NAME);
if (board) {
printk(KERN_CONT "/");
print_filtered(board);
}
printk(KERN_CONT ", BIOS ");
print_filtered(dmi_get_system_info(DMI_BIOS_VERSION));
printk(KERN_CONT " ");
Expand Down

0 comments on commit fef86db

Please sign in to comment.