Skip to content

samples: usb: sample.usb_device_next.midi: build failure on NXP series platforms #97242

@hakehuang

Description

@hakehuang

Describe the bug

  • frdm_mcxa156
  • frdm_mcxn236
  • frdm_k64f
  • lpcxpresso55sxx

4b04b74 is the first bad commit
commit 4b04b74
Author: Titouan Christophe titouan.christophe@mind.be
Date: Thu Jul 31 11:47:56 2025 +0200

audio: midi: improve API documentation

Improve the API documentation for Universal MIDI Packets definitions:

- Add link to the reference document, and make it referenceable in doxygen
- Use BIT_MASK macro instead of hexadecimal litterals to better convey the
  length of various fields within UMP packets
- Add more cross-references where possible
- Use @remark when applicable

Signed-off-by: Titouan Christophe <titouan.christophe@mind.be>

Regression

  • This is a regression.

Steps to reproduce

west build -b frdm_mcxa156 samples/subsys/usb/midi

Relevant log output

/home/jenkins/agent/workspace/bitbucket_build_platform/zephyr/subsys/usb/device_next/class/usbd_midi2.c
In file included from /home/jenkins/agent/workspace/bitbucket_build_platform/zephyr/include/zephyr/logging/log.h:11,
                 from /home/jenkins/agent/workspace/bitbucket_build_platform/zephyr/include/zephyr/usb/usbd.h:24,
                 from /home/jenkins/agent/workspace/bitbucket_build_platform/zephyr/subsys/usb/device_next/class/usbd_midi2.c:13:
/home/jenkins/agent/workspace/bitbucket_build_platform/zephyr/subsys/usb/device_next/class/usbd_midi2.c: In function 'usbd_midi_send':
/home/jenkins/agent/workspace/bitbucket_build_platform/zephyr/subsys/usb/device_next/class/usbd_midi2.c:472:17: error: format '%X' expects argument of type 'unsigned int', but argument 3 has type 'long unsigned int' [-Werror=format=]
  472 |         LOG_DBG("Send MT=%X group=%X", UMP_MT(ump), UMP_GROUP(ump));
      |                 ^~~~~~~~~~~~~~~~~~~~~
/home/jenkins/agent/workspace/bitbucket_build_platform/zephyr/include/zephyr/logging/log_core.h:315:50: note: in definition of macro 'Z_LOG2'
  315 |                         z_log_printf_arg_checker(__VA_ARGS__);                                     \
      |                                                  ^~~~~~~~~~~
/home/jenkins/agent/workspace/bitbucket_build_platform/zephyr/include/zephyr/logging/log.h:93:22: note: in expansion of macro 'Z_LOG'
   93 | #define LOG_DBG(...) Z_LOG(LOG_LEVEL_DBG, __VA_ARGS__)
      |                      ^~~~~
/home/jenkins/agent/workspace/bitbucket_build_platform/zephyr/subsys/usb/device_next/class/usbd_midi2.c:472:9: note: in expansion of macro 'LOG_DBG'
  472 |         LOG_DBG("Send MT=%X group=%X", UMP_MT(ump), UMP_GROUP(ump));
      |         ^~~~~~~
/home/jenkins/agent/workspace/bitbucket_build_platform/zephyr/subsys/usb/device_next/class/usbd_midi2.c:472:36: note: format string is defined here
  472 |         LOG_DBG("Send MT=%X group=%X", UMP_MT(ump), UMP_GROUP(ump));
      |                                   ~^
      |                                    |
      |                                    unsigned int
      |                                   %lX

Impact

Annoyance – Minor irritation; no significant impact on usability or functionality.

Environment

  • OS: ubuntu
  • toolchain: Zephyr
  • version: v4.2.0-5335-g57df5abaa675

Additional Context

No response

Metadata

Metadata

Assignees

Labels

bugThe issue is a bug, or the PR is fixing a bugplatform: NXPNXPplatform: nRFNordic nRFxpriority: lowLow impact/importance bug

Type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions