Make the kernel less chatty

Change some messages from always printed to varying level of the "verbose"
argument.

Change-Id: I6899268aa895c66e72806ca4d02bb53a0e4ea785
This commit is contained in:
Lionel Sambuc 2014-09-01 16:17:18 +02:00
parent 48e74378c7
commit da9af514b5
6 changed files with 13 additions and 13 deletions

View file

@ -60,7 +60,7 @@ static int acpi_check_signature(const char * orig, const char * match)
static u32_t acpi_phys2vir(u32_t p)
{
if(!vm_running) {
printf("acpi: returning 0x%lx as vir addr\n", p);
DEBUGEXTRA(("acpi: returning 0x%lx as vir addr\n", p));
return p;
}
panic("acpi: can't get virtual address of arbitrary physical address");
@ -304,7 +304,7 @@ static void acpi_init_poweroff(void)
exit:
if (msg) {
printf("acpi: %s\n", msg);
DEBUGBASIC(("acpi: %s\n", msg));
}
}

View file

@ -136,7 +136,7 @@ int init_local_timer(unsigned freq)
tsc_per_ms[cpu] = (unsigned long)(cpu_get_freq(cpu) / 1000);
lapic_set_timer_one_shot(1000000 / system_hz);
} else {
BOOT_VERBOSE(printf("Initiating legacy i8253 timer\n"));
DEBUGBASIC(("Initiating legacy i8253 timer\n"));
#else
{
#endif

View file

@ -271,10 +271,10 @@ void arch_init(void)
#if defined(USE_APIC) && !defined(CONFIG_SMP)
if (config_no_apic) {
BOOT_VERBOSE(printf("APIC disabled, using legacy PIC\n"));
DEBUGBASIC(("APIC disabled, using legacy PIC\n"));
}
else if (!apic_single_cpu_init()) {
BOOT_VERBOSE(printf("APIC not present, using legacy PIC\n"));
DEBUGBASIC(("APIC not present, using legacy PIC\n"));
}
#endif

View file

@ -939,13 +939,13 @@ int arch_phys_map_reply(const int index, const vir_bytes addr)
/* select the right set of IPC routines to map into processes */
if(minix_feature_flags & MKF_I386_INTEL_SYSENTER) {
printf("kernel: selecting intel sysenter ipc style\n");
DEBUGBASIC(("kernel: selecting intel sysenter ipc style\n"));
minix_kerninfo.minix_ipcvecs = &minix_ipcvecs_sysenter;
} else if(minix_feature_flags & MKF_I386_AMD_SYSCALL) {
printf("kernel: selecting amd syscall ipc style\n");
DEBUGBASIC(("kernel: selecting amd syscall ipc style\n"));
minix_kerninfo.minix_ipcvecs = &minix_ipcvecs_syscall;
} else {
printf("kernel: selecting fallback (int) ipc style\n");
DEBUGBASIC(("kernel: selecting fallback (int) ipc style\n"));
minix_kerninfo.minix_ipcvecs = &minix_ipcvecs_softint;
}

View file

@ -141,7 +141,7 @@ void kmain(kinfo_t *local_cbi)
arch_ser_init();
#endif
/* We can talk now */
printf("MINIX booting\n");
DEBUGBASIC(("MINIX booting\n"));
/* Kernel may use bits of main memory before VM is started */
kernel_may_alloc = 1;
@ -299,10 +299,10 @@ void kmain(kinfo_t *local_cbi)
#ifdef CONFIG_SMP
if (config_no_apic) {
BOOT_VERBOSE(printf("APIC disabled, disables SMP, using legacy PIC\n"));
DEBUGBASIC(("APIC disabled, disables SMP, using legacy PIC\n"));
smp_single_cpu_fallback();
} else if (config_no_smp) {
BOOT_VERBOSE(printf("SMP disabled, using legacy PIC\n"));
DEBUGBASIC(("SMP disabled, using legacy PIC\n"));
smp_single_cpu_fallback();
} else {
smp_init();
@ -505,7 +505,7 @@ void cpu_print_freq(unsigned cpu)
u64_t freq;
freq = cpu_get_freq(cpu);
printf("CPU %d freq %lu MHz\n", cpu, (unsigned long)(freq / 1000000));
DEBUGBASIC(("CPU %d freq %lu MHz\n", cpu, (unsigned long)(freq / 1000000)));
}
int is_fpu(void)

View file

@ -24,7 +24,7 @@ BOOT="mmcbootcmd"
#default for the beagleboard-xM
CONSOLE=tty02
#verbosity
VERBOSE=3
VERBOSE=0
HZ=1000
while getopts "c:v:h:p:n?" c