* linux-next: build warning after merge of the y2038 tree
@ 2018-06-06 10:41 Stephen Rothwell
2018-06-06 13:47 ` Arnd Bergmann
0 siblings, 1 reply; 2+ messages in thread
From: Stephen Rothwell @ 2018-06-06 10:41 UTC (permalink / raw)
To: Arnd Bergmann
Cc: Linux-Next Mailing List, Linux Kernel Mailing List, Kees Cook,
Deepa Dinamani
[-- Attachment #1: Type: text/plain, Size: 2021 bytes --]
Hi all,
After merging the y2038 tree, today's linux-next build (x86_64
allmodconfig) produced this warning:
fs/pstore/ram.c: In function 'ramoops_read_kmsg_hdr':
fs/pstore/ram.c:39:29: warning: format '%ld' expects argument of type 'long int *', but argument 3 has type 'time64_t * {aka long long int *}' [-Wformat=]
#define RAMOOPS_KERNMSG_HDR "===="
^
fs/pstore/ram.c:167:21: note: in expansion of macro 'RAMOOPS_KERNMSG_HDR'
if (sscanf(buffer, RAMOOPS_KERNMSG_HDR TVSEC_FMT ".%lu-%c\n%n",
^~~~~~~~~~~~~~~~~~~
fs/pstore/ram.c:42:23: note: format string is defined here
# define TVSEC_FMT "%ld"
~~^
%lld
fs/pstore/ram.c:39:29: warning: format '%ld' expects argument of type 'long int *', but argument 3 has type 'time64_t * {aka long long int *}' [-Wformat=]
#define RAMOOPS_KERNMSG_HDR "===="
^
fs/pstore/ram.c:174:28: note: in expansion of macro 'RAMOOPS_KERNMSG_HDR'
} else if (sscanf(buffer, RAMOOPS_KERNMSG_HDR TVSEC_FMT ".%lu\n%n",
^~~~~~~~~~~~~~~~~~~
fs/pstore/ram.c:42:23: note: format string is defined here
# define TVSEC_FMT "%ld"
~~^
%lld
fs/pstore/ram.c: In function 'ramoops_write_kmsg_hdr':
fs/pstore/ram.c:39:29: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'time64_t {aka long long int}' [-Wformat=]
#define RAMOOPS_KERNMSG_HDR "===="
^
fs/pstore/ram.c:370:30: note: in expansion of macro 'RAMOOPS_KERNMSG_HDR'
hdr = kasprintf(GFP_ATOMIC, RAMOOPS_KERNMSG_HDR TVSEC_FMT ".%lu-%c\n",
^~~~~~~~~~~~~~~~~~~
fs/pstore/ram.c:42:23: note: format string is defined here
# define TVSEC_FMT "%ld"
~~^
%lld
Introduced by commit
0f0d83b99ef7 ("pstore: Convert internal records to timespec64")
--
Cheers,
Stephen Rothwell
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: linux-next: build warning after merge of the y2038 tree
2018-06-06 10:41 linux-next: build warning after merge of the y2038 tree Stephen Rothwell
@ 2018-06-06 13:47 ` Arnd Bergmann
0 siblings, 0 replies; 2+ messages in thread
From: Arnd Bergmann @ 2018-06-06 13:47 UTC (permalink / raw)
To: Stephen Rothwell
Cc: Linux-Next Mailing List, Linux Kernel Mailing List, Kees Cook,
Deepa Dinamani
On Wed, Jun 6, 2018 at 12:41 PM, Stephen Rothwell <sfr@canb•auug.org.au> wrote:
> Hi all,
>
> After merging the y2038 tree, today's linux-next build (x86_64
> allmodconfig) produced this warning:
>
> fs/pstore/ram.c: In function 'ramoops_read_kmsg_hdr':
> fs/pstore/ram.c:39:29: warning: format '%ld' expects argument of type 'long int *', but argument 3 has type 'time64_t * {aka long long int *}' [-Wformat=]
> #define RAMOOPS_KERNMSG_HDR "===="
> ^
> fs/pstore/ram.c:167:21: note: in expansion of macro 'RAMOOPS_KERNMSG_HDR'
> if (sscanf(buffer, RAMOOPS_KERNMSG_HDR TVSEC_FMT ".%lu-%c\n%n",
> ^~~~~~~~~~~~~~~~~~~
> fs/pstore/ram.c:42:23: note: format string is defined here
> # define TVSEC_FMT "%ld"
> ~~^
> %lld
> fs/pstore/ram.c:39:29: warning: format '%ld' expects argument of type 'long int *', but argument 3 has type 'time64_t * {aka long long int *}' [-Wformat=]
> #define RAMOOPS_KERNMSG_HDR "===="
> ^
> fs/pstore/ram.c:174:28: note: in expansion of macro 'RAMOOPS_KERNMSG_HDR'
> } else if (sscanf(buffer, RAMOOPS_KERNMSG_HDR TVSEC_FMT ".%lu\n%n",
> ^~~~~~~~~~~~~~~~~~~
> fs/pstore/ram.c:42:23: note: format string is defined here
> # define TVSEC_FMT "%ld"
> ~~^
> %lld
> fs/pstore/ram.c: In function 'ramoops_write_kmsg_hdr':
> fs/pstore/ram.c:39:29: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'time64_t {aka long long int}' [-Wformat=]
> #define RAMOOPS_KERNMSG_HDR "===="
> ^
> fs/pstore/ram.c:370:30: note: in expansion of macro 'RAMOOPS_KERNMSG_HDR'
> hdr = kasprintf(GFP_ATOMIC, RAMOOPS_KERNMSG_HDR TVSEC_FMT ".%lu-%c\n",
> ^~~~~~~~~~~~~~~~~~~
> fs/pstore/ram.c:42:23: note: format string is defined here
> # define TVSEC_FMT "%ld"
> ~~^
> %lld
>
> Introduced by commit
>
> 0f0d83b99ef7 ("pstore: Convert internal records to timespec64")
>
Thanks for the report, I had actually provided a fix for this earlier
(it was a clash
between a patch in Deepa's tree with one of mine that Thomas had picked up
into tip) but forgot to apply it before I pushed out the merged tree.
I've updated my tree now.
Arnd
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-06-06 13:47 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-06-06 10:41 linux-next: build warning after merge of the y2038 tree Stephen Rothwell
2018-06-06 13:47 ` Arnd Bergmann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox