CV-Bowen opened a new pull request, #21830:
URL: https://github.com/apache/nuttx/pull/21830
## Summary
#21741 (the "!audio: widen ac_chmap to 32 bits" commit) made `ac_chmap` in
`struct audio_caps_s` a `uint32_t`. On 32-bit RISC-V that is
`long unsigned int`, so the `"%x"` in virtio-snd's debug print no
longer matches and rv-virt:netnsh_smp fails to build with
`-Werror=format`:
```
virtio/virtio-snd.c:787:17: error: format '%x' expects argument of type
'unsigned int', but argument 3 has type 'uint32_t' {aka 'long unsigned
int'} [-Werror=format=]
787 | vrtinfo("channel map: 0x%x\n", caps->ac_chmap);
```
Print it with `PRIx32`.
## Impact
Debug print only. No functional change.
## Testing
Host: Ubuntu 22.04.5 LTS x86_64, QEMU version 10.2.1, riscv-none-elf-gcc
(GCC) 13.4.0
rv-virt:netnsh_smp (`CONFIG_ARCH_RV32`, `CONFIG_DRIVERS_VIRTIO`
and `CONFIG_AUDIO` enabled): master warns at `virtio-snd.c:787`,
which `-Werror` turns into the error above; with this patch
`virtio-snd.c` compiles cleanly.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]