Changeset 1503c1c3 in rtems for c/src/lib/libbsp/i386


Ignore:
Timestamp:
May 23, 2016, 5:24:34 AM (4 years ago)
Author:
Chris Johns <chrisj@…>
Branches:
master
Children:
c16e54a
Parents:
24d0ee57
git-author:
Chris Johns <chrisj@…> (05/23/16 05:24:34)
git-committer:
Chris Johns <chrisj@…> (05/25/16 05:47:34)
Message:

i386/pc386: Fix printk formatting warnings.

Location:
c/src/lib/libbsp/i386
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/i386/pc386/console/console_control.c

    r24d0ee57 r1503c1c3  
    5555
    5656      case MW_UID_REGISTER_DEVICE:
    57         printk( "SerialMouse: reg=%s\n", args->buffer );
     57        printk( "SerialMouse: reg=%s\n", (const char*) args->buffer );
    5858        register_kbd_msg_queue( args->buffer, 0 );
    5959        break;
  • c/src/lib/libbsp/i386/pc386/console/exar17d15x.c

    r24d0ee57 r1503c1c3  
    167167    );
    168168    printk(
    169       "Found Exar 17D15x %d at 0x%08x IRQ %d with %d ports\n",
     169      "Found Exar 17D15x %d at 0x%08lx IRQ %d with %d ports\n",
    170170      instance,
    171171      conf[instance].base,
  • c/src/lib/libbsp/i386/pc386/console/fb_vesa_rm.c

    r24d0ee57 r1503c1c3  
    4242 *   - RTEMS fb_cirrus.c - Alexandru-Sever Horin (alex.sever.h@gmail.com)
    4343 */
     44
     45#include <inttypes.h>
    4446
    4547#include <bsp.h>
     
    786788        (vbe_ret_val>>8)!=VBE_callSuccessful)
    787789    {
    788         printk(FB_VESA_NAME " Cannot get mode info anymore. ax=0x%x\n",
     790        printk(FB_VESA_NAME " Cannot get mode info anymore. ax=0x%lx\n",
    789791            vbe_ret_val);
    790792    }
     
    823825    if ((vbe_ret_val&0xff)!= (VBE_functionSupported | VBE_callSuccessful<<8))
    824826        printk(FB_VESA_NAME " Call to function 2h (set VBE mode) failed. "
    825             "ax=0x%x\n", vbe_ret_val);
     827            "ax=0x%" PRIx32 "\n", vbe_ret_val);
    826828
    827829    vib = (void *) 0;
     
    969971  rtems_libio_ioctl_args_t *args = arg;
    970972
    971   printk( FB_VESA_NAME " ioctl called, cmd=%x\n", args->command  );
    972     printk("fbxres %d, fbyres %d\n", fb_var.xres, fb_var.yres);
    973     printk("fbbpp %d\n", fb_var.bits_per_pixel);
     973  printk( FB_VESA_NAME " ioctl called, cmd=%" PRIx32 "\n", args->command  );
     974    printk("fbxres %lu, fbyres %lu\n", fb_var.xres, fb_var.yres);
     975    printk("fbbpp %lu\n", fb_var.bits_per_pixel);
    974976
    975977  switch (args->command)
  • c/src/lib/libbsp/i386/pc386/console/inch.c

    r24d0ee57 r1503c1c3  
    207207_IBMPC_chrdy(char *c)
    208208{
     209#if CCJ_REMOVED_NO_IDEA_ABOUT_THIS_CODE_OR_COMMENT
    209210  /* FIX ME!!! It doesn't work without something like the following line.
    210211     Find out why! */
    211212  printk("");
     213#endif
    212214
    213215  /* Check buffer our ISR builds */
  • c/src/lib/libbsp/i386/pc386/console/uart_bus_pci.c

    r24d0ee57 r1503c1c3  
    286286  uint8_t val = rtems_inb(addr + i);
    287287  if (UART_PCI_IO)
    288     printk( "RD(%p -> 0x%02x) ", addr + i, val );
     288    printk( "RD(%p -> 0x%02x) ", (void*) addr + i, val );
    289289  return val;
    290290}
     
    293293{
    294294  if (UART_PCI_IO)
    295     printk( "WR(%p <- 0x%02x) ", addr + i, val );
     295    printk( "WR(%p <- 0x%02x) ", (void*) addr + i, val );
    296296  rtems_outb(addr + i, val);
    297297}
     
    454454
    455455        printk(
    456           "%s:%d:%s,%s:0x%x%s%s,irq:%d,clk:%d\n", /*  */
     456          "%s:%d:%s,%s:0x%lx%s%s,irq:%d,clk:%lu\n", /*  */
    457457          name, b, conf[b].desc,
    458458          io ? "io" : "mem", base, locatable, prefectable,
  • c/src/lib/libbsp/i386/pc386/ide/ide.c

    r24d0ee57 r1503c1c3  
    2424\*===============================================================*/
    2525
     26#include <inttypes.h>
     27
    2628#include <rtems.h>
     29
    2730#include <bsp.h>
    2831#include <libchip/ide_ctrl.h>
     
    200203
    201204  if (pc386_ide_show)
    202     printk("IDE%d: port base: %04x\n", minor, port);
     205    printk("IDE%d: port base: %04" PRIu32 "\n", minor, port);
    203206
    204207  outport_byte(port+IDE_REGISTER_DEVICE_HEAD,
     
    304307
    305308      if (pc386_ide_show && ((byte % 16) == 0))
    306         printk("\n %04x : ", byte);
     309        printk("\n %04" PRIx32 " : ", byte);
    307310
    308311      inport_word(port+IDE_REGISTER_DATA, word);
     
    347350
    348351    if (pc386_ide_show)
    349       printk("\nbytes read = %d\n", byte);
     352      printk("\nbytes read = %" PRIu32 "\n", byte);
    350353
    351354    if (p != &model_number[0])
     
    389392      }
    390393
    391       printk("IDE%d:%s:%s, %u.%u%c (%u/%u/%u), max blk size:%d\n",
     394      printk("IDE%d:%s:%s, %" PRIu32 ".%" PRIu32 "%c (%" PRIu32 "/%" PRIu32 "/%" PRIu32 "), max blk size:%d\n",
    392395             minor, label, model_number, left, right, units,
    393396             heads, cylinders, sectors, max_multiple_sectors * 512);
     
    542545                                      &status_val, pc386_ide_tasking_sleep))
    543546    {
    544       printk ("pc386_ide_read_block: block=%u cbuf=%u status=%02x, cnt=%d bs=%d\n",
     547      printk ("pc386_ide_read_block: block=%" PRIu32 \
     548              " cbuf=%" PRIu32 " status=%02x, cnt=%" PRIu32 " bs=%" PRIu32 "\n",
    545549              bufs[*cbuf].block, *cbuf, status_val, cnt, block_size);
    546550      /* FIXME: add an error here. */
     
    621625                                      &status_val, pc386_ide_tasking_sleep))
    622626    {
    623       printk ("pc386_ide_write_block: block=%u status=%02x, cnt=%d bs=%d\n",
     627      printk ("pc386_ide_write_block: block=%" PRIu32 " status=%02x, cnt=%" PRIu32 " bs=%" PRIu32 "\n",
    624628              bufs[*cbuf].block, status_val, cnt, block_size);
    625629      /* FIXME: add an error here. */
  • c/src/lib/libbsp/i386/shared/comm/i386-stub.c

    r24d0ee57 r1503c1c3  
    10331033            {
    10341034              bool insert = remcomInBuffer[0] == 'Z';
    1035               printk("hbreak type\n", insert);
    10361035              if (hexToInt (&ptr, &addr))
    10371036                {
  • c/src/lib/libbsp/i386/shared/comm/tty_drv.c

    r24d0ee57 r1503c1c3  
    1717
    1818
     19#include <inttypes.h>
    1920#include <stdio.h>
    2021#include <stdlib.h>
     
    263264  }
    264265
    265   printk("Setting attributes, port=%X, baud=%d, linemode = 0x%02x\n", port, baud, databits | parity | stopbits );
     266  printk("Setting attributes, port=%X, baud=%" PRId32 ", linemode = 0x%02" PRIx32 "\n",
     267         port, baud, databits | parity | stopbits );
    266268  BSP_uart_set_attributes(port, baud, databits, parity, stopbits);
    267269  return 0;
Note: See TracChangeset for help on using the changeset viewer.