[RTEMS Project] #3504: Warning and formatting in bsps/powerpc/mpc55xxevb/dev/dspi.c

RTEMS trac trac at rtems.org
Wed Aug 22 17:01:54 UTC 2018


#3504: Warning and formatting in bsps/powerpc/mpc55xxevb/dev/dspi.c
----------------------------+--------------------
  Reporter:  Joel Sherrill  |      Owner:  (none)
      Type:  defect         |     Status:  new
  Priority:  normal         |  Milestone:  5.1
 Component:  arch/powerpc   |    Version:  5
  Severity:  normal         |   Keywords:
Blocked By:                 |   Blocking:
----------------------------+--------------------
 This is a printf format warning. Also the file is formatted with tabs and
 not two spaces.

 In file included from
 ../../../../../../../../rtems/c/src/lib/libbsp/powerpc/mpc55xxevb/../../../../../../bsps/powerpc/mpc55xxevb/dev/dspi.c:32:0:
 ../../../../../../../../rtems/c/src/lib/libbsp/powerpc/mpc55xxevb/../../../../../../bsps/powerpc/mpc55xxevb/dev/dspi.c:
 In function 'mpc55xx_dspi_edma_done':
 /home/joel/rtems-work/rtems-testing/rtems/rtems/cpukit/include/rtems
 /status-checks.h:88:23: warning: format '%x' expects argument of type
 'unsigned int', but argument 3 has type 'uint32_t {aka long unsigned int}'
 [-Wformat=]
    RTEMS_SYSLOG_PRINT( "%s: " fmt, __func__, ##__VA_ARGS__)
                        ^
 /home/joel/rtems-work/rtems-testing/rtems/rtems/cpukit/include/rtems
 /status-checks.h:76:15: note: in definition of macro 'RTEMS_SYSLOG_PRINT'
        printk( fmt, ##__VA_ARGS__)
                ^~~
 /home/joel/rtems-work/rtems-testing/rtems/rtems/cpukit/include/rtems
 /status-checks.h:109:3: note: in expansion of macro 'RTEMS_SYSLOG'
    RTEMS_SYSLOG( "Error: " fmt, ##__VA_ARGS__)
    ^~~~~~~~~~~~
 ../../../../../../../../rtems/c/src/lib/libbsp/powerpc/mpc55xxevb/../../../../../../bsps/powerpc/mpc55xxevb/dev/dspi.c:122:3:
 note: in expansion of macro 'RTEMS_SYSLOG_ERROR'
    RTEMS_SYSLOG_ERROR( "eDMA error: 0x%08x\n", error_status);
    ^~~~~~~~~~~~~~~~~~
 ../../../../../../../../rtems/c/src/lib/libbsp/powerpc/mpc55xxevb/../../../../../../bsps/powerpc/mpc55xxevb/dev/dspi.c:122:41:
 note: format string is defined here
    RTEMS_SYSLOG_ERROR( "eDMA error: 0x%08x\n", error_status);
                                       ~~~^
                                       %08lx

--
Ticket URL: <http://devel.rtems.org/ticket/3504>
RTEMS Project <http://www.rtems.org/>
RTEMS Project


More information about the bugs mailing list