usbdebug: Drop temporary disables of log output
With this patch, output on usbdebug also includes the section of MTRR setups for every CPU. This makes usbdebug output almost identical with that of serial port and CBMEM console. Tested with model_206ax. Also tested previously on model_f2x which does not have these disable/enable calls in model_f2x_init() without detected issues. Change-Id: Idfd0e93439907b17255633658195d698feab3895 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: http://review.coreboot.org/3423 Reviewed-by: Aaron Durbin <adurbin@google.com> Tested-by: build bot (Jenkins)
This commit is contained in:
parent
f55a54257a
commit
e49679d5a1
|
@ -456,31 +456,17 @@ static inline void k8_errata(void)
|
|||
|
||||
}
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
static unsigned ehci_debug_addr;
|
||||
#endif
|
||||
|
||||
static void model_fxx_init(device_t dev)
|
||||
{
|
||||
unsigned long i;
|
||||
msr_t msr;
|
||||
struct node_core_id id;
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
if (!ehci_debug_addr)
|
||||
ehci_debug_addr = get_ehci_debug();
|
||||
set_ehci_debug(0);
|
||||
#endif
|
||||
|
||||
/* Turn on caching if we haven't already */
|
||||
x86_enable_cache();
|
||||
amd_setup_mtrrs();
|
||||
x86_mtrr_check();
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
set_ehci_debug(ehci_debug_addr);
|
||||
#endif
|
||||
|
||||
/* Update the microcode */
|
||||
model_fxx_update_microcode(dev->device);
|
||||
|
||||
|
|
|
@ -438,10 +438,6 @@ static void configure_mca(void)
|
|||
wrmsr(IA32_MC0_STATUS + (i * 4), msr);
|
||||
}
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
static unsigned ehci_debug_addr;
|
||||
#endif
|
||||
|
||||
static void bsp_init_before_ap_bringup(struct bus *cpu_bus)
|
||||
{
|
||||
struct device_path cpu_path;
|
||||
|
@ -466,22 +462,11 @@ static void bsp_init_before_ap_bringup(struct bus *cpu_bus)
|
|||
if (info->index != 0)
|
||||
printk(BIOS_CRIT, "BSP index(%d) != 0!\n", info->index);
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
// Is this caution really needed?
|
||||
if(!ehci_debug_addr)
|
||||
ehci_debug_addr = get_ehci_debug();
|
||||
set_ehci_debug(0);
|
||||
#endif
|
||||
|
||||
/* Setup MTRRs based on physical address size. */
|
||||
x86_setup_fixed_mtrrs();
|
||||
x86_setup_var_mtrrs(cpuid_eax(0x80000008) & 0xff, 2);
|
||||
x86_mtrr_check();
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
set_ehci_debug(ehci_debug_addr);
|
||||
#endif
|
||||
|
||||
/* Call through the cpu driver's initialization. */
|
||||
cpu_initialize(0);
|
||||
}
|
||||
|
|
|
@ -303,10 +303,6 @@ static void configure_pic_thermal_sensors(const int tm2, const int quad)
|
|||
wrmsr(PIC_SENS_CFG, msr);
|
||||
}
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
static unsigned ehci_debug_addr;
|
||||
#endif
|
||||
|
||||
static void model_1067x_init(device_t cpu)
|
||||
{
|
||||
char processor_name[49];
|
||||
|
@ -345,21 +341,10 @@ static void model_1067x_init(device_t cpu)
|
|||
fill_processor_name(processor_name);
|
||||
printk(BIOS_INFO, "CPU: %s.\n", processor_name);
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
// Is this caution really needed?
|
||||
if(!ehci_debug_addr)
|
||||
ehci_debug_addr = get_ehci_debug();
|
||||
set_ehci_debug(0);
|
||||
#endif
|
||||
|
||||
/* Setup MTRRs */
|
||||
x86_setup_mtrrs();
|
||||
x86_mtrr_check();
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
set_ehci_debug(ehci_debug_addr);
|
||||
#endif
|
||||
|
||||
/* Enable the local cpu apics */
|
||||
setup_lapic();
|
||||
|
||||
|
|
|
@ -128,10 +128,6 @@ static void configure_misc(void)
|
|||
wrmsr(IA32_MISC_ENABLE, msr);
|
||||
}
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
static unsigned ehci_debug_addr;
|
||||
#endif
|
||||
|
||||
static void model_106cx_init(device_t cpu)
|
||||
{
|
||||
char processor_name[49];
|
||||
|
@ -146,21 +142,10 @@ static void model_106cx_init(device_t cpu)
|
|||
fill_processor_name(processor_name);
|
||||
printk(BIOS_INFO, "CPU: %s.\n", processor_name);
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
// Is this caution really needed?
|
||||
if(!ehci_debug_addr)
|
||||
ehci_debug_addr = get_ehci_debug();
|
||||
set_ehci_debug(0);
|
||||
#endif
|
||||
|
||||
/* Setup MTRRs */
|
||||
x86_setup_mtrrs();
|
||||
x86_mtrr_check();
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
set_ehci_debug(ehci_debug_addr);
|
||||
#endif
|
||||
|
||||
/* Enable the local cpu apics */
|
||||
setup_lapic();
|
||||
|
||||
|
|
|
@ -342,10 +342,6 @@ static void configure_mca(void)
|
|||
wrmsr(IA32_MC0_STATUS + (i * 4), msr);
|
||||
}
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
static unsigned ehci_debug_addr;
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Initialize any extra cores/threads in this package.
|
||||
*/
|
||||
|
@ -420,12 +416,6 @@ static void model_2065x_init(device_t cpu)
|
|||
fill_processor_name(processor_name);
|
||||
printk(BIOS_INFO, "CPU: %s.\n", processor_name);
|
||||
printk(BIOS_INFO, "CPU:lapic=%ld, boot_cpu=%d\n", lapicid (), boot_cpu ());
|
||||
#if CONFIG_USBDEBUG
|
||||
// Is this caution really needed?
|
||||
if(!ehci_debug_addr)
|
||||
ehci_debug_addr = get_ehci_debug();
|
||||
set_ehci_debug(0);
|
||||
#endif
|
||||
|
||||
/* Setup MTRRs based on physical address size */
|
||||
cpuid_regs = cpuid(0x80000008);
|
||||
|
@ -436,10 +426,6 @@ static void model_2065x_init(device_t cpu)
|
|||
/* Setup Page Attribute Tables (PAT) */
|
||||
// TODO set up PAT
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
set_ehci_debug(ehci_debug_addr);
|
||||
#endif
|
||||
|
||||
/* Enable the local cpu apics */
|
||||
enable_lapic_tpr();
|
||||
setup_lapic();
|
||||
|
|
|
@ -476,10 +476,6 @@ static void configure_mca(void)
|
|||
wrmsr(IA32_MC0_STATUS + (i * 4), msr);
|
||||
}
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
static unsigned ehci_debug_addr;
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Initialize any extra cores/threads in this package.
|
||||
*/
|
||||
|
@ -554,13 +550,6 @@ static void model_206ax_init(device_t cpu)
|
|||
fill_processor_name(processor_name);
|
||||
printk(BIOS_INFO, "CPU: %s.\n", processor_name);
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
// Is this caution really needed?
|
||||
if(!ehci_debug_addr)
|
||||
ehci_debug_addr = get_ehci_debug();
|
||||
set_ehci_debug(0);
|
||||
#endif
|
||||
|
||||
/* Setup MTRRs based on physical address size */
|
||||
cpuid_regs = cpuid(0x80000008);
|
||||
x86_setup_fixed_mtrrs();
|
||||
|
@ -570,10 +559,6 @@ static void model_206ax_init(device_t cpu)
|
|||
/* Setup Page Attribute Tables (PAT) */
|
||||
// TODO set up PAT
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
set_ehci_debug(ehci_debug_addr);
|
||||
#endif
|
||||
|
||||
/* Enable the local cpu apics */
|
||||
enable_lapic_tpr();
|
||||
setup_lapic();
|
||||
|
|
|
@ -59,10 +59,6 @@ static const uint32_t microcode_updates[] = {
|
|||
0x0, 0x0, 0x0, 0x0,
|
||||
};
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
static unsigned ehci_debug_addr;
|
||||
#endif
|
||||
|
||||
static void model_68x_init(device_t cpu)
|
||||
{
|
||||
char processor_name[49];
|
||||
|
@ -77,21 +73,10 @@ static void model_68x_init(device_t cpu)
|
|||
fill_processor_name(processor_name);
|
||||
printk(BIOS_INFO, "CPU: %s.\n", processor_name);
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
// Is this caution really needed?
|
||||
if(!ehci_debug_addr)
|
||||
ehci_debug_addr = get_ehci_debug();
|
||||
set_ehci_debug(0);
|
||||
#endif
|
||||
|
||||
/* Setup MTRRs */
|
||||
x86_setup_mtrrs();
|
||||
x86_mtrr_check();
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
set_ehci_debug(ehci_debug_addr);
|
||||
#endif
|
||||
|
||||
/* Enable the local cpu apics */
|
||||
setup_lapic();
|
||||
}
|
||||
|
|
|
@ -45,10 +45,6 @@ static const uint32_t microcode_updates[] = {
|
|||
0x0, 0x0, 0x0, 0x0,
|
||||
};
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
static unsigned ehci_debug_addr;
|
||||
#endif
|
||||
|
||||
static void model_6bx_init(device_t cpu)
|
||||
{
|
||||
char processor_name[49];
|
||||
|
@ -63,21 +59,10 @@ static void model_6bx_init(device_t cpu)
|
|||
fill_processor_name(processor_name);
|
||||
printk(BIOS_INFO, "CPU: %s.\n", processor_name);
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
// Is this caution really needed?
|
||||
if(!ehci_debug_addr)
|
||||
ehci_debug_addr = get_ehci_debug();
|
||||
set_ehci_debug(0);
|
||||
#endif
|
||||
|
||||
/* Setup MTRRs */
|
||||
x86_setup_mtrrs();
|
||||
x86_mtrr_check();
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
set_ehci_debug(ehci_debug_addr);
|
||||
#endif
|
||||
|
||||
/* Enable the local cpu apics */
|
||||
setup_lapic();
|
||||
}
|
||||
|
|
|
@ -153,10 +153,6 @@ static void configure_pic_thermal_sensors(void)
|
|||
wrmsr(PIC_SENS_CFG, msr);
|
||||
}
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
static unsigned ehci_debug_addr;
|
||||
#endif
|
||||
|
||||
static void model_6ex_init(device_t cpu)
|
||||
{
|
||||
char processor_name[49];
|
||||
|
@ -171,21 +167,10 @@ static void model_6ex_init(device_t cpu)
|
|||
fill_processor_name(processor_name);
|
||||
printk(BIOS_INFO, "CPU: %s.\n", processor_name);
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
// Is this caution really needed?
|
||||
if(!ehci_debug_addr)
|
||||
ehci_debug_addr = get_ehci_debug();
|
||||
set_ehci_debug(0);
|
||||
#endif
|
||||
|
||||
/* Setup MTRRs */
|
||||
x86_setup_mtrrs();
|
||||
x86_mtrr_check();
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
set_ehci_debug(ehci_debug_addr);
|
||||
#endif
|
||||
|
||||
/* Enable the local cpu apics */
|
||||
setup_lapic();
|
||||
|
||||
|
|
|
@ -190,10 +190,6 @@ static void configure_pic_thermal_sensors(void)
|
|||
wrmsr(PIC_SENS_CFG, msr);
|
||||
}
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
static unsigned ehci_debug_addr;
|
||||
#endif
|
||||
|
||||
static void model_6fx_init(device_t cpu)
|
||||
{
|
||||
char processor_name[49];
|
||||
|
@ -208,13 +204,6 @@ static void model_6fx_init(device_t cpu)
|
|||
fill_processor_name(processor_name);
|
||||
printk(BIOS_INFO, "CPU: %s.\n", processor_name);
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
// Is this caution really needed?
|
||||
if(!ehci_debug_addr)
|
||||
ehci_debug_addr = get_ehci_debug();
|
||||
set_ehci_debug(0);
|
||||
#endif
|
||||
|
||||
/* Setup MTRRs */
|
||||
x86_setup_mtrrs();
|
||||
x86_mtrr_check();
|
||||
|
@ -222,10 +211,6 @@ static void model_6fx_init(device_t cpu)
|
|||
/* Setup Page Attribute Tables (PAT) */
|
||||
// TODO set up PAT
|
||||
|
||||
#if CONFIG_USBDEBUG
|
||||
set_ehci_debug(ehci_debug_addr);
|
||||
#endif
|
||||
|
||||
/* Enable the local cpu apics */
|
||||
setup_lapic();
|
||||
|
||||
|
|
Loading…
Reference in New Issue