* Compile warning with current kernel and netfs
@ 2021-05-11 2:01 Steve French
2021-05-11 2:07 ` Matthew Wilcox
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Steve French @ 2021-05-11 2:01 UTC (permalink / raw)
To: David Howells; +Cc: linux-fsdevel, CIFS
Noticed the following netfs related new warning when compiling cifs.ko
with the current 5.13-rc1
CC [M] /home/smfrench/cifs-2.6/fs/cifs/fscache.o
CHECK /home/smfrench/cifs-2.6/fs/cifs/fscache.c
/home/smfrench/cifs-2.6/fs/cifs/fscache.c: note: in included file
(through include/linux/fscache.h,
/home/smfrench/cifs-2.6/fs/cifs/fscache.h):
./include/linux/netfs.h:93:15: error: don't know how to apply mode to
unsigned int enum netfs_read_source
CC [M] /home/smfrench/cifs-2.6/fs/cifs/cache.o
CHECK /home/smfrench/cifs-2.6/fs/cifs/cache.c
/home/smfrench/cifs-2.6/fs/cifs/cache.c: note: in included file
(through include/linux/fscache.h,
/home/smfrench/cifs-2.6/fs/cifs/fscache.h):
./include/linux/netfs.h:93:15: error: don't know how to apply mode to
unsigned int enum netfs_read_source
It doesn't like this enum in include/linux/netfs.h:
enum netfs_read_source {
NETFS_FILL_WITH_ZEROES,
NETFS_DOWNLOAD_FROM_SERVER,
NETFS_READ_FROM_CACHE,
NETFS_INVALID_READ,
} __mode(byte);
--
Thanks,
Steve
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Compile warning with current kernel and netfs
2021-05-11 2:01 Compile warning with current kernel and netfs Steve French
@ 2021-05-11 2:07 ` Matthew Wilcox
2021-05-11 3:28 ` Steve French
2021-05-11 3:30 ` Steve French
2021-05-11 13:03 ` David Howells
2 siblings, 1 reply; 6+ messages in thread
From: Matthew Wilcox @ 2021-05-11 2:07 UTC (permalink / raw)
To: Steve French; +Cc: David Howells, linux-fsdevel, CIFS
On Mon, May 10, 2021 at 09:01:06PM -0500, Steve French wrote:
> Noticed the following netfs related new warning when compiling cifs.ko
> with the current 5.13-rc1
I don't see that ... what compiler & version are you using?
> CC [M] /home/smfrench/cifs-2.6/fs/cifs/fscache.o
> CHECK /home/smfrench/cifs-2.6/fs/cifs/fscache.c
> /home/smfrench/cifs-2.6/fs/cifs/fscache.c: note: in included file
> (through include/linux/fscache.h,
> /home/smfrench/cifs-2.6/fs/cifs/fscache.h):
> ./include/linux/netfs.h:93:15: error: don't know how to apply mode to
> unsigned int enum netfs_read_source
> CC [M] /home/smfrench/cifs-2.6/fs/cifs/cache.o
> CHECK /home/smfrench/cifs-2.6/fs/cifs/cache.c
> /home/smfrench/cifs-2.6/fs/cifs/cache.c: note: in included file
> (through include/linux/fscache.h,
> /home/smfrench/cifs-2.6/fs/cifs/fscache.h):
> ./include/linux/netfs.h:93:15: error: don't know how to apply mode to
> unsigned int enum netfs_read_source
>
> It doesn't like this enum in include/linux/netfs.h:
>
> enum netfs_read_source {
> NETFS_FILL_WITH_ZEROES,
> NETFS_DOWNLOAD_FROM_SERVER,
> NETFS_READ_FROM_CACHE,
> NETFS_INVALID_READ,
> } __mode(byte);
>
> --
> Thanks,
>
> Steve
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Compile warning with current kernel and netfs
2021-05-11 2:07 ` Matthew Wilcox
@ 2021-05-11 3:28 ` Steve French
0 siblings, 0 replies; 6+ messages in thread
From: Steve French @ 2021-05-11 3:28 UTC (permalink / raw)
To: Matthew Wilcox; +Cc: David Howells, linux-fsdevel, CIFS
$ gcc --version
gcc (Ubuntu 10.3.0-1ubuntu1) 10.3.0
$ sparse --version
v0.6.1-393-ge140005c
On Mon, May 10, 2021 at 9:09 PM Matthew Wilcox <willy@infradead.org> wrote:
>
> On Mon, May 10, 2021 at 09:01:06PM -0500, Steve French wrote:
> > Noticed the following netfs related new warning when compiling cifs.ko
> > with the current 5.13-rc1
>
> I don't see that ... what compiler & version are you using?
>
> > CC [M] /home/smfrench/cifs-2.6/fs/cifs/fscache.o
> > CHECK /home/smfrench/cifs-2.6/fs/cifs/fscache.c
> > /home/smfrench/cifs-2.6/fs/cifs/fscache.c: note: in included file
> > (through include/linux/fscache.h,
> > /home/smfrench/cifs-2.6/fs/cifs/fscache.h):
> > ./include/linux/netfs.h:93:15: error: don't know how to apply mode to
> > unsigned int enum netfs_read_source
> > CC [M] /home/smfrench/cifs-2.6/fs/cifs/cache.o
> > CHECK /home/smfrench/cifs-2.6/fs/cifs/cache.c
> > /home/smfrench/cifs-2.6/fs/cifs/cache.c: note: in included file
> > (through include/linux/fscache.h,
> > /home/smfrench/cifs-2.6/fs/cifs/fscache.h):
> > ./include/linux/netfs.h:93:15: error: don't know how to apply mode to
> > unsigned int enum netfs_read_source
> >
> > It doesn't like this enum in include/linux/netfs.h:
> >
> > enum netfs_read_source {
> > NETFS_FILL_WITH_ZEROES,
> > NETFS_DOWNLOAD_FROM_SERVER,
> > NETFS_READ_FROM_CACHE,
> > NETFS_INVALID_READ,
> > } __mode(byte);
> >
> > --
> > Thanks,
> >
> > Steve
--
Thanks,
Steve
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Compile warning with current kernel and netfs
2021-05-11 2:01 Compile warning with current kernel and netfs Steve French
2021-05-11 2:07 ` Matthew Wilcox
@ 2021-05-11 3:30 ` Steve French
2021-05-11 13:03 ` David Howells
2 siblings, 0 replies; 6+ messages in thread
From: Steve French @ 2021-05-11 3:30 UTC (permalink / raw)
To: David Howells; +Cc: linux-fsdevel, CIFS
And forgot to mention that this is on very recent distro, has recent
libraries etc., I had to move to Ubuntu 21.04 due to dependencies of
eBPF and other pieces on newer libc, pahole etc
On Mon, May 10, 2021 at 9:01 PM Steve French <smfrench@gmail.com> wrote:
>
> Noticed the following netfs related new warning when compiling cifs.ko
> with the current 5.13-rc1
>
> CC [M] /home/smfrench/cifs-2.6/fs/cifs/fscache.o
> CHECK /home/smfrench/cifs-2.6/fs/cifs/fscache.c
> /home/smfrench/cifs-2.6/fs/cifs/fscache.c: note: in included file
> (through include/linux/fscache.h,
> /home/smfrench/cifs-2.6/fs/cifs/fscache.h):
> ./include/linux/netfs.h:93:15: error: don't know how to apply mode to
> unsigned int enum netfs_read_source
> CC [M] /home/smfrench/cifs-2.6/fs/cifs/cache.o
> CHECK /home/smfrench/cifs-2.6/fs/cifs/cache.c
> /home/smfrench/cifs-2.6/fs/cifs/cache.c: note: in included file
> (through include/linux/fscache.h,
> /home/smfrench/cifs-2.6/fs/cifs/fscache.h):
> ./include/linux/netfs.h:93:15: error: don't know how to apply mode to
> unsigned int enum netfs_read_source
>
> It doesn't like this enum in include/linux/netfs.h:
>
> enum netfs_read_source {
> NETFS_FILL_WITH_ZEROES,
> NETFS_DOWNLOAD_FROM_SERVER,
> NETFS_READ_FROM_CACHE,
> NETFS_INVALID_READ,
> } __mode(byte);
>
> --
> Thanks,
>
> Steve
--
Thanks,
Steve
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Compile warning with current kernel and netfs
2021-05-11 2:01 Compile warning with current kernel and netfs Steve French
2021-05-11 2:07 ` Matthew Wilcox
2021-05-11 3:30 ` Steve French
@ 2021-05-11 13:03 ` David Howells
2021-05-11 19:41 ` Steve French
2 siblings, 1 reply; 6+ messages in thread
From: David Howells @ 2021-05-11 13:03 UTC (permalink / raw)
To: Steve French; +Cc: dhowells, linux-fsdevel, CIFS
Steve French <smfrench@gmail.com> wrote:
> CC [M] /home/smfrench/cifs-2.6/fs/cifs/fscache.o
> CHECK /home/smfrench/cifs-2.6/fs/cifs/fscache.c
> /home/smfrench/cifs-2.6/fs/cifs/fscache.c: note: in included file
> (through include/linux/fscache.h,
> /home/smfrench/cifs-2.6/fs/cifs/fscache.h):
> ./include/linux/netfs.h:93:15: error: don't know how to apply mode to
> unsigned int enum netfs_read_source
Yeah - that's a bit the checker doesn't know how to support. It's meant to
make enum netfs_read_source-type struct members take less space. I think gcc
and clang are both fine with it.
David
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Compile warning with current kernel and netfs
2021-05-11 13:03 ` David Howells
@ 2021-05-11 19:41 ` Steve French
0 siblings, 0 replies; 6+ messages in thread
From: Steve French @ 2021-05-11 19:41 UTC (permalink / raw)
To: David Howells; +Cc: linux-fsdevel, CIFS
On Tue, May 11, 2021 at 8:03 AM David Howells <dhowells@redhat.com> wrote:
>
> Steve French <smfrench@gmail.com> wrote:
>
> > CC [M] /home/smfrench/cifs-2.6/fs/cifs/fscache.o
> > CHECK /home/smfrench/cifs-2.6/fs/cifs/fscache.c
> > /home/smfrench/cifs-2.6/fs/cifs/fscache.c: note: in included file
> > (through include/linux/fscache.h,
> > /home/smfrench/cifs-2.6/fs/cifs/fscache.h):
> > ./include/linux/netfs.h:93:15: error: don't know how to apply mode to
> > unsigned int enum netfs_read_source
>
> Yeah - that's a bit the checker doesn't know how to support. It's meant to
> make enum netfs_read_source-type struct members take less space. I think gcc
> and clang are both fine with it.
Looks like sparse has been recently updated to fix this. I pulled
from their git tree and rebuilt sparse to:
$ sparse --version
v0.6.3-341-g8af24329
and it works - no warnings (other than the "Skipping BTF generation
one - which is unrelated, see https://lkml.org/lkml/2020/11/16/1452)
make: Entering directory '/usr/src/linux-headers-5.13.0-051300rc1-generic'
CC [M] /home/smfrench/cifs-2.6/fs/cifs/fscache.o
CHECK /home/smfrench/cifs-2.6/fs/cifs/fscache.c
CC [M] /home/smfrench/cifs-2.6/fs/cifs/cache.o
CHECK /home/smfrench/cifs-2.6/fs/cifs/cache.c
LD [M] /home/smfrench/cifs-2.6/fs/cifs/cifs.o
MODPOST /home/smfrench/cifs-2.6/fs/cifs/Module.symvers
LD [M] /home/smfrench/cifs-2.6/fs/cifs/cifs.ko
BTF [M] /home/smfrench/cifs-2.6/fs/cifs/cifs.ko
--
Thanks,
Steve
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2021-05-11 19:41 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-11 2:01 Compile warning with current kernel and netfs Steve French
2021-05-11 2:07 ` Matthew Wilcox
2021-05-11 3:28 ` Steve French
2021-05-11 3:30 ` Steve French
2021-05-11 13:03 ` David Howells
2021-05-11 19:41 ` Steve French
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).