Page MenuHomeFreeBSD

kern/subr_intr: fix build with DEBUG on arm64/aarch64
ClosedPublic

Authored by val_packett.cool on May 24 2020, 4:23 PM.
Tags
Referenced Files
Unknown Object (File)
Tue, Oct 14, 6:44 AM
Unknown Object (File)
Sun, Oct 5, 8:55 PM
Unknown Object (File)
Sat, Sep 20, 8:02 PM
Unknown Object (File)
Sep 12 2025, 10:43 PM
Unknown Object (File)
Sep 10 2025, 7:11 AM
Unknown Object (File)
Sep 8 2025, 8:06 AM
Unknown Object (File)
Sep 8 2025, 7:14 AM
Unknown Object (File)
Jul 21 2025, 11:39 AM
Subscribers

Details

Summary

Fixes the following error:

/usr/src/sys/kern/subr_intr.c:802:37: error: format specifies type 'unsigned int' but the argument has type 'intptr_t' (aka 'long') [-Werror,-Wformat]
            device_get_nameunit(dev), dev, xref);
                                           ^~~~

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

val_packett.cool created this revision.
andrew added inline comments.
sys/kern/subr_intr.c
800–801 ↗(On Diff #72192)

The normal way in the kernel is to cast to uintmax_t and use %jx.

This revision was not accepted when it landed; it landed in state Needs Review.Jun 10 2020, 4:01 PM
This revision was automatically updated to reflect the committed changes.
sys/kern/subr_intr.c
800–801 ↗(On Diff #72192)

Indeed, there is another instance of this same debugf earlier, with (uintmax_t).