summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/i386/pc386/console
diff options
context:
space:
mode:
authorChris Johns <chrisj@rtems.org>2016-05-23 15:24:34 +1000
committerChris Johns <chrisj@rtems.org>2016-05-25 15:47:34 +1000
commit1503c1c382b501bdcf87703c00a1ad0908f4ac01 (patch)
tree17912855e40df940d10737af42798860d2d205dc /c/src/lib/libbsp/i386/pc386/console
parentcpukit, testsuite: Add rtems_printf and rtems_printer support. (diff)
downloadrtems-1503c1c382b501bdcf87703c00a1ad0908f4ac01.tar.bz2
i386/pc386: Fix printk formatting warnings.
Diffstat (limited to 'c/src/lib/libbsp/i386/pc386/console')
-rw-r--r--c/src/lib/libbsp/i386/pc386/console/console_control.c2
-rw-r--r--c/src/lib/libbsp/i386/pc386/console/exar17d15x.c2
-rw-r--r--c/src/lib/libbsp/i386/pc386/console/fb_vesa_rm.c12
-rw-r--r--c/src/lib/libbsp/i386/pc386/console/inch.c2
-rw-r--r--c/src/lib/libbsp/i386/pc386/console/uart_bus_pci.c6
5 files changed, 14 insertions, 10 deletions
diff --git a/c/src/lib/libbsp/i386/pc386/console/console_control.c b/c/src/lib/libbsp/i386/pc386/console/console_control.c
index 3a454d97e9..e5e4bc18e8 100644
--- a/c/src/lib/libbsp/i386/pc386/console/console_control.c
+++ b/c/src/lib/libbsp/i386/pc386/console/console_control.c
@@ -54,7 +54,7 @@ rtems_device_driver console_control(
break;
case MW_UID_REGISTER_DEVICE:
- printk( "SerialMouse: reg=%s\n", args->buffer );
+ printk( "SerialMouse: reg=%s\n", (const char*) args->buffer );
register_kbd_msg_queue( args->buffer, 0 );
break;
diff --git a/c/src/lib/libbsp/i386/pc386/console/exar17d15x.c b/c/src/lib/libbsp/i386/pc386/console/exar17d15x.c
index d17c9485d2..83cb0298d4 100644
--- a/c/src/lib/libbsp/i386/pc386/console/exar17d15x.c
+++ b/c/src/lib/libbsp/i386/pc386/console/exar17d15x.c
@@ -166,7 +166,7 @@ rtems_device_driver exar17d15x_initialize(
&conf[instance].base
);
printk(
- "Found Exar 17D15x %d at 0x%08x IRQ %d with %d ports\n",
+ "Found Exar 17D15x %d at 0x%08lx IRQ %d with %d ports\n",
instance,
conf[instance].base,
conf[instance].irq,
diff --git a/c/src/lib/libbsp/i386/pc386/console/fb_vesa_rm.c b/c/src/lib/libbsp/i386/pc386/console/fb_vesa_rm.c
index fa41d01570..fa3f00c675 100644
--- a/c/src/lib/libbsp/i386/pc386/console/fb_vesa_rm.c
+++ b/c/src/lib/libbsp/i386/pc386/console/fb_vesa_rm.c
@@ -42,6 +42,8 @@
* - RTEMS fb_cirrus.c - Alexandru-Sever Horin (alex.sever.h@gmail.com)
*/
+#include <inttypes.h>
+
#include <bsp.h>
#include <bsp/fb_default_mode.h>
@@ -785,7 +787,7 @@ void vesa_realmode_bootup_init(void)
if ((vbe_ret_val&0xff)!=VBE_functionSupported ||
(vbe_ret_val>>8)!=VBE_callSuccessful)
{
- printk(FB_VESA_NAME " Cannot get mode info anymore. ax=0x%x\n",
+ printk(FB_VESA_NAME " Cannot get mode info anymore. ax=0x%lx\n",
vbe_ret_val);
}
@@ -822,7 +824,7 @@ void vesa_realmode_bootup_init(void)
if ((vbe_ret_val&0xff)!= (VBE_functionSupported | VBE_callSuccessful<<8))
printk(FB_VESA_NAME " Call to function 2h (set VBE mode) failed. "
- "ax=0x%x\n", vbe_ret_val);
+ "ax=0x%" PRIx32 "\n", vbe_ret_val);
vib = (void *) 0;
mib = (void *) 0;
@@ -968,9 +970,9 @@ frame_buffer_control(
{
rtems_libio_ioctl_args_t *args = arg;
- printk( FB_VESA_NAME " ioctl called, cmd=%x\n", args->command );
- printk("fbxres %d, fbyres %d\n", fb_var.xres, fb_var.yres);
- printk("fbbpp %d\n", fb_var.bits_per_pixel);
+ printk( FB_VESA_NAME " ioctl called, cmd=%" PRIx32 "\n", args->command );
+ printk("fbxres %lu, fbyres %lu\n", fb_var.xres, fb_var.yres);
+ printk("fbbpp %lu\n", fb_var.bits_per_pixel);
switch (args->command)
{
diff --git a/c/src/lib/libbsp/i386/pc386/console/inch.c b/c/src/lib/libbsp/i386/pc386/console/inch.c
index e503de5329..047269e4f0 100644
--- a/c/src/lib/libbsp/i386/pc386/console/inch.c
+++ b/c/src/lib/libbsp/i386/pc386/console/inch.c
@@ -206,9 +206,11 @@ _IBMPC_scankey(char *outChar)
static bool
_IBMPC_chrdy(char *c)
{
+#if CCJ_REMOVED_NO_IDEA_ABOUT_THIS_CODE_OR_COMMENT
/* FIX ME!!! It doesn't work without something like the following line.
Find out why! */
printk("");
+#endif
/* Check buffer our ISR builds */
if (kbd_first != kbd_last)
diff --git a/c/src/lib/libbsp/i386/pc386/console/uart_bus_pci.c b/c/src/lib/libbsp/i386/pc386/console/uart_bus_pci.c
index 7b4824895f..e90eb57b7e 100644
--- a/c/src/lib/libbsp/i386/pc386/console/uart_bus_pci.c
+++ b/c/src/lib/libbsp/i386/pc386/console/uart_bus_pci.c
@@ -285,14 +285,14 @@ static uint8_t pci_ns16550_io_get_register(uint32_t addr, uint8_t i)
{
uint8_t val = rtems_inb(addr + i);
if (UART_PCI_IO)
- printk( "RD(%p -> 0x%02x) ", addr + i, val );
+ printk( "RD(%p -> 0x%02x) ", (void*) addr + i, val );
return val;
}
static void pci_ns16550_io_set_register(uint32_t addr, uint8_t i, uint8_t val)
{
if (UART_PCI_IO)
- printk( "WR(%p <- 0x%02x) ", addr + i, val );
+ printk( "WR(%p <- 0x%02x) ", (void*) addr + i, val );
rtems_outb(addr + i, val);
}
@@ -453,7 +453,7 @@ void pci_uart_probe(void)
printk(
- "%s:%d:%s,%s:0x%x%s%s,irq:%d,clk:%d\n", /* */
+ "%s:%d:%s,%s:0x%lx%s%s,irq:%d,clk:%lu\n", /* */
name, b, conf[b].desc,
io ? "io" : "mem", base, locatable, prefectable,
conf[b].irq, conf[b].clock