kernelnewbies.kernelnewbies.org archive mirror
 help / color / mirror / Atom feed
* thrashing on format %u vs size_t arg
@ 2021-09-14 15:32 jim.cromie
  2021-09-14 19:39 ` Valdis Klētnieks
  0 siblings, 1 reply; 6+ messages in thread
From: jim.cromie @ 2021-09-14 15:32 UTC (permalink / raw)
  To: kernelnewbies

wrt:

+       v2pr_info("read %u bytes from userspace <\n%s>\n", len, tmpbuf);

Im getting what appears to be conflicting warnings
about %u vs unsigned int (sometimes unsigned long int)
depending upon platform ??

Ive now tried both  %lu  and  %u

What have I missed ?




[jimc:dd-drm-next 3/16] lib/dynamic_debug.c:786:53: warning: format
specifies type 'unsigned int' but the argument has type 'size_t' (aka
'unsigned long')

head:   bf8f0832d11f09c546179ca6a2c5432706ea3d32



[kbuild-all] [jimc:dd-drm-next 3/16] include/linux/kern_levels.h:5:25:
warning: format '%u' expects argument of type 'unsigned int', but
argument 2 has type 'size_t' {aka 'long unsigned int'}

Inbox
Linux/kbuild-all
to-me

kernel test robot via lists.01.org

Mon, Sep 13, 9:08 PM (11 hours ago)
to me, kbuild-all
tree:   https://github.com/jimc/linux.git dd-drm-next
head:   bf8f0832d11f09c546179ca6a2c5432706ea3d32
commit: 221a341c10ebb8545beac6ee3937859d26ddcc60 [3/16] dyndbg:
rationalize verbosity
config: alpha-allyesconfig (attached as .config)


kernel test robot

Sep 13, 2021, 5:45 AM (1 day ago)
to me
tree/branch: https://github.com/jimc/linux.git dd-drm-next
branch HEAD: 02a6c357b6a5eb02cc6b2ceb5a7a93c809388ae0  nouveau: fold
multiple DRM_DEBUG_DRIVERs together

Error/Warning in current branch:

lib/dynamic_debug.c:786:54: warning: format specifies type 'unsigned
long' but the argument has type 'size_t' (aka 'unsigned int')
[-Wformat]
lib/dynamic_debug.c:864:54: warning: format specifies type 'unsigned
long' but the argument has type 'size_t' (aka 'unsigned int')
[-Wformat]
lib/dynamic_debug.c:876:54: warning: format specifies type 'unsigned
long' but the argument has type 'size_t' (aka 'unsigned int')
[-Wformat]


[jimc:dd-drm-next 3/16] lib/dynamic_debug.c:786:54: warning: format
specifies type 'unsigned long' but the argument has type 'size_t' (aka
'unsigned int')

Inbox
Linux/kbuild-all
to-me

kernel test robot

Sep 11, 2021, 5:17 PM (3 days ago)
to me, kbuild-all
tree:   https://github.com/jimc/linux.git dd-drm-next
head:   02a6c357b6a5eb02cc6b2ceb5a7a93c809388ae0
commit: 74992de06222ed51caed07800e291e68eb4a627e [3/16] dyndbg:
rationalize verbosity
config: hexagon-randconfig-r034-20210911 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project
261cbe98c38f8c1ee1a482fe76511110e790f58a)

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-09-15 21:45 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-14 15:32 thrashing on format %u vs size_t arg jim.cromie
2021-09-14 19:39 ` Valdis Klētnieks
2021-09-14 22:38   ` jim.cromie
2021-09-15  4:47     ` Bernd Petrovitsch
2021-09-15 16:20       ` jim.cromie
2021-09-15 21:44         ` Bernd Petrovitsch

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).