diff options
author | Stefan Reinauer <stepan@coresystems.de> | 2010-03-22 11:42:32 +0000 |
---|---|---|
committer | Stefan Reinauer <stepan@openbios.org> | 2010-03-22 11:42:32 +0000 |
commit | c02b4fc9db3c3c1e263027382697b566127f66bb (patch) | |
tree | 11bd18488e360e5c1beeb9ccb852ef4489c3689a /src/pc80 | |
parent | 27852aba6787617ca5656995cbc7e8ef0a3ea22c (diff) | |
download | coreboot-staging-c02b4fc9db3c3c1e263027382697b566127f66bb.zip coreboot-staging-c02b4fc9db3c3c1e263027382697b566127f66bb.tar.gz |
printk_foo -> printk(BIOS_FOO, ...)
Signed-off-by: Stefan Reinauer <stepan@coresystems.de>
Acked-by: Ronald G. Minnich <rminnich@gmail.com>
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@5266 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/pc80')
-rw-r--r-- | src/pc80/i8259.c | 8 | ||||
-rw-r--r-- | src/pc80/keyboard.c | 36 | ||||
-rw-r--r-- | src/pc80/mc146818rtc.c | 8 |
3 files changed, 26 insertions, 26 deletions
diff --git a/src/pc80/i8259.c b/src/pc80/i8259.c index 1361f37..330b7c6 100644 --- a/src/pc80/i8259.c +++ b/src/pc80/i8259.c @@ -113,26 +113,26 @@ void i8259_configure_irq_trigger(int int_num, int is_level_triggered) { u16 int_bits = inb(ELCR1) | (((u16)inb(ELCR2)) << 8); - printk_spew("%s: current interrupts are 0x%x\n", __func__, int_bits); + printk(BIOS_SPEW, "%s: current interrupts are 0x%x\n", __func__, int_bits); if (is_level_triggered) int_bits |= (1 << int_num); else int_bits &= ~(1 << int_num); /* Write new values */ - printk_spew("%s: try to set interrupts 0x%x\n", __func__, int_bits); + printk(BIOS_SPEW, "%s: try to set interrupts 0x%x\n", __func__, int_bits); outb((u8)(int_bits & 0xff), ELCR1); outb((u8)(int_bits >> 8), ELCR2); #ifdef PARANOID_IRQ_TRIGGERS /* Try reading back the new values. This seems like an error but is not ... */ if (inb(ELCR1) != (int_bits & 0xff)) { - printk_err("%s: lower order bits are wrong: want 0x%x, got 0x%x\n", + printk(BIOS_ERR, "%s: lower order bits are wrong: want 0x%x, got 0x%x\n", __func__, (int_bits & 0xff), inb(ELCR1)); } if (inb(ELCR2) != (int_bits >> 8)) { - printk_err("%s: higher order bits are wrong: want 0x%x, got 0x%x\n", + printk(BIOS_ERR, "%s: higher order bits are wrong: want 0x%x, got 0x%x\n", __func__, (int_bits>>8), inb(ELCR2)); } #endif diff --git a/src/pc80/keyboard.c b/src/pc80/keyboard.c index 6b80620..32e2576 100644 --- a/src/pc80/keyboard.c +++ b/src/pc80/keyboard.c @@ -71,7 +71,7 @@ static int kbc_input_buffer_empty(void) } if (!timeout) { - printk_warning("Unexpected Keyboard controller input buffer full\n"); + printk(BIOS_WARNING, "Unexpected Keyboard controller input buffer full\n"); } return !!timeout; } @@ -85,7 +85,7 @@ static int kbc_output_buffer_full(void) } if (!timeout) { - printk_warning("Keyboard controller output buffer result timeout\n"); + printk(BIOS_WARNING, "Keyboard controller output buffer result timeout\n"); } return !!timeout; } @@ -100,8 +100,8 @@ static int kbc_cleanup_buffers(void) } if (!timeout) { - printk_err("Couldn't cleanup the keyboard controller buffers\n"); - printk_err("Status (0x%x): 0x%x, Buffer (0x%x): 0x%x\n", + printk(BIOS_ERR, "Couldn't cleanup the keyboard controller buffers\n"); + printk(BIOS_ERR, "Status (0x%x): 0x%x, Buffer (0x%x): 0x%x\n", KBD_STATUS, inb(KBD_STATUS), KBD_DATA, inb(KBD_DATA)); } @@ -123,7 +123,7 @@ static int kbc_self_test(void) if (!kbc_output_buffer_full()) { /* There probably is no keyboard controller. */ - printk_err("Could not reset keyboard controller.\n"); + printk(BIOS_ERR, "Could not reset keyboard controller.\n"); return 0; } @@ -131,7 +131,7 @@ static int kbc_self_test(void) self_test = inb(KBD_DATA); if (self_test != 0x55) { - printk_err("Keyboard Controller self-test failed: 0x%x\n", + printk(BIOS_ERR, "Keyboard Controller self-test failed: 0x%x\n", self_test); return 0; } @@ -148,7 +148,7 @@ static u8 send_keyboard(u8 command) if (!kbc_input_buffer_empty()) return 0; outb(command, KBD_DATA); if (!kbc_output_buffer_full()) { - printk_err("Could not send keyboard command %02x\n", + printk(BIOS_ERR, "Could not send keyboard command %02x\n", command); return 0; } @@ -162,7 +162,7 @@ static u8 send_keyboard(u8 command) void pc_keyboard_init(struct pc_keyboard *keyboard) { u8 regval; - printk_debug("Keyboard init...\n"); + printk(BIOS_DEBUG, "Keyboard init...\n"); /* Run a keyboard controller self-test */ if (!kbc_self_test()) @@ -174,7 +174,7 @@ void pc_keyboard_init(struct pc_keyboard *keyboard) if (!kbc_input_buffer_empty()) return; outb(0x20, KBD_DATA); /* send cmd: enable keyboard */ if (!kbc_input_buffer_empty()) { - printk_info("Timeout while enabling keyboard\n"); + printk(BIOS_INFO, "Timeout while enabling keyboard\n"); return; } @@ -185,23 +185,23 @@ void pc_keyboard_init(struct pc_keyboard *keyboard) regval = send_keyboard(0xFF); if (regval == KBD_REPLY_RESEND) { /* keeps sending RESENDs, probably no keyboard. */ - printk_info("No PS/2 keyboard detected.\n"); + printk(BIOS_INFO, "No PS/2 keyboard detected.\n"); return; } if (regval != KBD_REPLY_ACK) { - printk_err("Keyboard selftest failed ACK: 0x%x\n", regval); + printk(BIOS_ERR, "Keyboard selftest failed ACK: 0x%x\n", regval); return; } if (!kbc_output_buffer_full()) { - printk_err("Timeout waiting for keyboard after reset.\n"); + printk(BIOS_ERR, "Timeout waiting for keyboard after reset.\n"); return; } regval = inb(KBD_DATA); if (regval != 0xAA) { - printk_err("Keyboard selftest failed: 0x%x\n", regval); + printk(BIOS_ERR, "Keyboard selftest failed: 0x%x\n", regval); return; } @@ -213,27 +213,27 @@ void pc_keyboard_init(struct pc_keyboard *keyboard) /* disable the keyboard */ regval = send_keyboard(0xF5); if (regval != KBD_REPLY_ACK) { - printk_err("Keyboard disable failed ACK: 0x%x\n", regval); + printk(BIOS_ERR, "Keyboard disable failed ACK: 0x%x\n", regval); return; } /* Set scancode command */ regval = send_keyboard(0xF0); if (regval != KBD_REPLY_ACK) { - printk_err("Keyboard set scancode cmd failed ACK: 0x%x\n", regval); + printk(BIOS_ERR, "Keyboard set scancode cmd failed ACK: 0x%x\n", regval); return; } /* Set scancode mode 2 */ regval = send_keyboard(0x02); if (regval != KBD_REPLY_ACK) { - printk_err("Keyboard set scancode mode failed ACK: 0x%x\n", regval); + printk(BIOS_ERR, "Keyboard set scancode mode failed ACK: 0x%x\n", regval); return; } /* enable the keyboard */ regval = send_keyboard(0xF4); if (regval != KBD_REPLY_ACK) { - printk_err("Keyboard enable failed ACK: 0x%x\n", regval); + printk(BIOS_ERR, "Keyboard enable failed ACK: 0x%x\n", regval); return; } @@ -243,7 +243,7 @@ void pc_keyboard_init(struct pc_keyboard *keyboard) if (!kbc_input_buffer_empty()) return; outb(0x61, KBD_DATA); /* send cmd: enable keyboard and IRQ 1 */ if (kbc_output_buffer_full()) { - printk_err("Timeout during final keyboard enable\n"); + printk(BIOS_ERR, "Timeout during final keyboard enable\n"); return; } } diff --git a/src/pc80/mc146818rtc.c b/src/pc80/mc146818rtc.c index e318167..9251f79 100644 --- a/src/pc80/mc146818rtc.c +++ b/src/pc80/mc146818rtc.c @@ -140,7 +140,7 @@ void rtc_init(int invalid) int cmos_invalid, checksum_invalid; #endif - printk_debug("RTC Init\n"); + printk(BIOS_DEBUG, "RTC Init\n"); #if CONFIG_HAVE_OPTION_TABLE /* See if there has been a CMOS power problem. */ @@ -152,7 +152,7 @@ void rtc_init(int invalid) PC_CKS_RANGE_END,PC_CKS_LOC); if (invalid || cmos_invalid || checksum_invalid) { - printk_warning("RTC:%s%s%s zeroing cmos\n", + printk(BIOS_WARNING, "RTC:%s%s%s zeroing cmos\n", invalid?" Clear requested":"", cmos_invalid?" Power Problem":"", checksum_invalid?" Checksum invalid":""); @@ -188,7 +188,7 @@ void rtc_init(int invalid) checksum_invalid = !rtc_checksum_valid(CONFIG_LB_CKS_RANGE_START, CONFIG_LB_CKS_RANGE_END,CONFIG_LB_CKS_LOC); if(checksum_invalid) - printk_debug("Invalid CMOS LB checksum\n"); + printk(BIOS_DEBUG, "Invalid CMOS LB checksum\n"); /* Make certain we have a valid checksum */ rtc_set_checksum(PC_CKS_RANGE_START, @@ -257,7 +257,7 @@ int get_option(void *dest, const char *name) } } if(!found) { - printk_debug("WARNING: No cmos option '%s'\n", name); + printk(BIOS_DEBUG, "WARNING: No cmos option '%s'\n", name); return(-2); } |