* Re: [PATCH 3/5] staging: lustre: lustre: Remove unnecessary cast on void pointer
2017-03-02 21:19 ` [PATCH 3/5] staging: lustre: " simran singhal
@ 2017-03-02 21:43 ` Joe Perches
2017-03-02 21:55 ` SIMRAN SINGHAL
2017-03-03 22:41 ` kbuild test robot
2017-03-04 0:16 ` kbuild test robot
2 siblings, 1 reply; 17+ messages in thread
From: Joe Perches @ 2017-03-02 21:43 UTC (permalink / raw)
To: simran singhal, Larry.Finger
Cc: florian.c.schilhabel, gregkh, devel, linux-kernel, oleg.drokin,
marvin24, outreachy-kernel
On Fri, 2017-03-03 at 02:49 +0530, simran singhal wrote:
> The following Coccinelle script was used to detect this:
> @r@
> expression x;
> void* e;
> type T;
> identifier f;
> @@
> (
> *((T *)e)
> >
>
> ((T *)x)[...]
> >
>
> ((T*)x)->f
> >
>
> - (T*)
> e
> )
NAK.
Nice, but you still have to verify correctness
before submitting these patches.
> diff --git a/drivers/staging/lustre/lustre/mgc/mgc_request.c b/drivers/staging/lustre/lustre/mgc/mgc_request.c
[]
> @@ -1034,7 +1034,7 @@ static int mgc_set_info_async(const struct lu_env *env, struct obd_export *exp,
> rc = sptlrpc_parse_flavor(val, &flvr);
> if (rc) {
> CERROR("invalid sptlrpc flavor %s to MGS\n",
> - (char *)val);
> + val);
Try compiling this.
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH 3/5] staging: lustre: lustre: Remove unnecessary cast on void pointer
2017-03-02 21:43 ` Joe Perches
@ 2017-03-02 21:55 ` SIMRAN SINGHAL
2017-03-02 21:59 ` Joe Perches
0 siblings, 1 reply; 17+ messages in thread
From: SIMRAN SINGHAL @ 2017-03-02 21:55 UTC (permalink / raw)
To: Joe Perches
Cc: Larry.Finger, Florian Schilhabel, Greg KH, devel, linux-kernel,
oleg.drokin, marvin24, outreachy-kernel
On Fri, Mar 3, 2017 at 3:13 AM, Joe Perches <joe@perches.com> wrote:
> On Fri, 2017-03-03 at 02:49 +0530, simran singhal wrote:
>> The following Coccinelle script was used to detect this:
>> @r@
>> expression x;
>> void* e;
>> type T;
>> identifier f;
>> @@
>> (
>> *((T *)e)
>> >
>>
>> ((T *)x)[...]
>> >
>>
>> ((T*)x)->f
>> >
>>
>> - (T*)
>> e
>> )
>
> NAK.
>
> Nice, but you still have to verify correctness
> before submitting these patches.
>
>> diff --git a/drivers/staging/lustre/lustre/mgc/mgc_request.c b/drivers/staging/lustre/lustre/mgc/mgc_request.c
> []
>> @@ -1034,7 +1034,7 @@ static int mgc_set_info_async(const struct lu_env *env, struct obd_export *exp,
>> rc = sptlrpc_parse_flavor(val, &flvr);
>> if (rc) {
>> CERROR("invalid sptlrpc flavor %s to MGS\n",
>> - (char *)val);
>> + val);
>
> Try compiling this.
>
I compiled it before sending.
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH 3/5] staging: lustre: lustre: Remove unnecessary cast on void pointer
2017-03-02 21:55 ` SIMRAN SINGHAL
@ 2017-03-02 21:59 ` Joe Perches
2017-03-02 22:05 ` SIMRAN SINGHAL
0 siblings, 1 reply; 17+ messages in thread
From: Joe Perches @ 2017-03-02 21:59 UTC (permalink / raw)
To: SIMRAN SINGHAL
Cc: Larry.Finger, Florian Schilhabel, Greg KH, devel, linux-kernel,
oleg.drokin, marvin24, outreachy-kernel
On Fri, 2017-03-03 at 03:25 +0530, SIMRAN SINGHAL wrote:
> On Fri, Mar 3, 2017 at 3:13 AM, Joe Perches <joe@perches.com> wrote:
> > On Fri, 2017-03-03 at 02:49 +0530, simran singhal wrote:
> > > The following Coccinelle script was used to detect this:
> > > @r@
> > > expression x;
> > > void* e;
> > > type T;
> > > identifier f;
> > > @@
> > > (
> > > *((T *)e)
> > > >
> > >
> > > ((T *)x)[...]
> > > >
> > >
> > > ((T*)x)->f
> > > >
> > >
> > > - (T*)
> > > e
> > > )
> >
> > NAK.
> >
> > Nice, but you still have to verify correctness
> > before submitting these patches.
> >
> > > diff --git a/drivers/staging/lustre/lustre/mgc/mgc_request.c b/drivers/staging/lustre/lustre/mgc/mgc_request.c
> >
> > []
> > > @@ -1034,7 +1034,7 @@ static int mgc_set_info_async(const struct lu_env *env, struct obd_export *exp,
> > > rc = sptlrpc_parse_flavor(val, &flvr);
> > > if (rc) {
> > > CERROR("invalid sptlrpc flavor %s to MGS\n",
> > > - (char *)val);
> > > + val);
> >
> > Try compiling this.
> >
>
> I compiled it before sending.
Did you look at the warnings?
CC [M] drivers/staging/lustre/lustre/mgc/mgc_request.o
drivers/staging/lustre/lustre/mgc/mgc_request.c: In function ‘mgc_set_info_async’:
drivers/staging/lustre/lustre/mgc/mgc_request.c:1036:115: warning: format ‘%s’ expects argument of type ‘char *’, but argument 3 has type ‘void *’ [-Wformat=]
CERROR("invalid sptlrpc flavor %s to MGS\n",
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH 3/5] staging: lustre: lustre: Remove unnecessary cast on void pointer
2017-03-02 21:59 ` Joe Perches
@ 2017-03-02 22:05 ` SIMRAN SINGHAL
2017-03-02 22:07 ` [Outreachy kernel] " Julia Lawall
2017-03-02 22:09 ` Joe Perches
0 siblings, 2 replies; 17+ messages in thread
From: SIMRAN SINGHAL @ 2017-03-02 22:05 UTC (permalink / raw)
To: Joe Perches
Cc: Larry.Finger, Florian Schilhabel, Greg KH, devel, linux-kernel,
oleg.drokin, marvin24, outreachy-kernel
On Fri, Mar 3, 2017 at 3:29 AM, Joe Perches <joe@perches.com> wrote:
> On Fri, 2017-03-03 at 03:25 +0530, SIMRAN SINGHAL wrote:
>> On Fri, Mar 3, 2017 at 3:13 AM, Joe Perches <joe@perches.com> wrote:
>> > On Fri, 2017-03-03 at 02:49 +0530, simran singhal wrote:
>> > > The following Coccinelle script was used to detect this:
>> > > @r@
>> > > expression x;
>> > > void* e;
>> > > type T;
>> > > identifier f;
>> > > @@
>> > > (
>> > > *((T *)e)
>> > > >
>> > >
>> > > ((T *)x)[...]
>> > > >
>> > >
>> > > ((T*)x)->f
>> > > >
>> > >
>> > > - (T*)
>> > > e
>> > > )
>> >
>> > NAK.
>> >
>> > Nice, but you still have to verify correctness
>> > before submitting these patches.
>> >
>> > > diff --git a/drivers/staging/lustre/lustre/mgc/mgc_request.c b/drivers/staging/lustre/lustre/mgc/mgc_request.c
>> >
>> > []
>> > > @@ -1034,7 +1034,7 @@ static int mgc_set_info_async(const struct lu_env *env, struct obd_export *exp,
>> > > rc = sptlrpc_parse_flavor(val, &flvr);
>> > > if (rc) {
>> > > CERROR("invalid sptlrpc flavor %s to MGS\n",
>> > > - (char *)val);
>> > > + val);
>> >
>> > Try compiling this.
>> >
>>
>> I compiled it before sending.
>
> Did you look at the warnings?
>
> CC [M] drivers/staging/lustre/lustre/mgc/mgc_request.o
> drivers/staging/lustre/lustre/mgc/mgc_request.c: In function ‘mgc_set_info_async’:
> drivers/staging/lustre/lustre/mgc/mgc_request.c:1036:115: warning: format ‘%s’ expects argument of type ‘char *’, but argument 3 has type ‘void *’ [-Wformat=]
> CERROR("invalid sptlrpc flavor %s to MGS\n",
>
I again compiled it and this is what I got :-
CHK include/config/kernel.release
CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
CHK include/generated/timeconst.h
CHK include/generated/bounds.h
CHK include/generated/asm-offsets.h
CALL scripts/checksyscalls.sh
CHK include/generated/compile.h
LD arch/x86/boot/compressed/vmlinux
ZOFFSET arch/x86/boot/zoffset.h
AS arch/x86/boot/header.o
LD arch/x86/boot/setup.elf
OBJCOPY arch/x86/boot/setup.bin
OBJCOPY arch/x86/boot/vmlinux.bin
BUILD arch/x86/boot/bzImage
Setup is 17500 bytes (padded to 17920 bytes).
System is 7128 kB
CRC 37713343
Kernel: arch/x86/boot/bzImage is ready (#4)
Building modules, stage 2.
MODPOST 4541 modules
I am not getting any warning.
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [Outreachy kernel] Re: [PATCH 3/5] staging: lustre: lustre: Remove unnecessary cast on void pointer
2017-03-02 22:05 ` SIMRAN SINGHAL
@ 2017-03-02 22:07 ` Julia Lawall
2017-03-02 22:09 ` Joe Perches
1 sibling, 0 replies; 17+ messages in thread
From: Julia Lawall @ 2017-03-02 22:07 UTC (permalink / raw)
To: SIMRAN SINGHAL
Cc: Joe Perches, Larry.Finger, Florian Schilhabel, Greg KH, devel,
linux-kernel, oleg.drokin, marvin24, outreachy-kernel
[-- Attachment #1: Type: text/plain, Size: 3479 bytes --]
On Fri, 3 Mar 2017, SIMRAN SINGHAL wrote:
> On Fri, Mar 3, 2017 at 3:29 AM, Joe Perches <joe@perches.com> wrote:
> > On Fri, 2017-03-03 at 03:25 +0530, SIMRAN SINGHAL wrote:
> >> On Fri, Mar 3, 2017 at 3:13 AM, Joe Perches <joe@perches.com> wrote:
> >> > On Fri, 2017-03-03 at 02:49 +0530, simran singhal wrote:
> >> > > The following Coccinelle script was used to detect this:
> >> > > @r@
> >> > > expression x;
> >> > > void* e;
> >> > > type T;
> >> > > identifier f;
> >> > > @@
> >> > > (
> >> > > *((T *)e)
> >> > > >
> >> > >
> >> > > ((T *)x)[...]
> >> > > >
> >> > >
> >> > > ((T*)x)->f
> >> > > >
> >> > >
> >> > > - (T*)
> >> > > e
> >> > > )
> >> >
> >> > NAK.
> >> >
> >> > Nice, but you still have to verify correctness
> >> > before submitting these patches.
> >> >
> >> > > diff --git a/drivers/staging/lustre/lustre/mgc/mgc_request.c b/drivers/staging/lustre/lustre/mgc/mgc_request.c
> >> >
> >> > []
> >> > > @@ -1034,7 +1034,7 @@ static int mgc_set_info_async(const struct lu_env *env, struct obd_export *exp,
> >> > > rc = sptlrpc_parse_flavor(val, &flvr);
> >> > > if (rc) {
> >> > > CERROR("invalid sptlrpc flavor %s to MGS\n",
> >> > > - (char *)val);
> >> > > + val);
> >> >
> >> > Try compiling this.
> >> >
> >>
> >> I compiled it before sending.
> >
> > Did you look at the warnings?
> >
> > CC [M] drivers/staging/lustre/lustre/mgc/mgc_request.o
> > drivers/staging/lustre/lustre/mgc/mgc_request.c: In function ‘mgc_set_info_async’:
> > drivers/staging/lustre/lustre/mgc/mgc_request.c:1036:115: warning: format ‘%s’ expects argument of type ‘char *’, but argument 3 has type ‘void *’ [-Wformat=]
> > CERROR("invalid sptlrpc flavor %s to MGS\n",
> >
>
> I again compiled it and this is what I got :-
>
> CHK include/config/kernel.release
> CHK include/generated/uapi/linux/version.h
> CHK include/generated/utsrelease.h
> CHK include/generated/timeconst.h
> CHK include/generated/bounds.h
> CHK include/generated/asm-offsets.h
> CALL scripts/checksyscalls.sh
> CHK include/generated/compile.h
> LD arch/x86/boot/compressed/vmlinux
> ZOFFSET arch/x86/boot/zoffset.h
> AS arch/x86/boot/header.o
> LD arch/x86/boot/setup.elf
> OBJCOPY arch/x86/boot/setup.bin
> OBJCOPY arch/x86/boot/vmlinux.bin
> BUILD arch/x86/boot/bzImage
> Setup is 17500 bytes (padded to 17920 bytes).
> System is 7128 kB
> CRC 37713343
> Kernel: arch/x86/boot/bzImage is ready (#4)
> Building modules, stage 2.
> MODPOST 4541 modules
>
> I am not getting any warning.
Did you touch the .c file before compiling it? Warnings still allow the
creation of a .o, and once there is a .o that s more recent than the .c,
make won't compile it again.
I got a whole of host of warnings, including the ones Joe showed.
julia
>
> --
> You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to outreachy-kernel+unsubscribe@googlegroups.com.
> To post to this group, send email to outreachy-kernel@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/CALrZqyP6S2mwYUBERerLnG99qVSFm5jHppjy695JARHMfZ-5Pw%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.
>
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH 3/5] staging: lustre: lustre: Remove unnecessary cast on void pointer
2017-03-02 22:05 ` SIMRAN SINGHAL
2017-03-02 22:07 ` [Outreachy kernel] " Julia Lawall
@ 2017-03-02 22:09 ` Joe Perches
1 sibling, 0 replies; 17+ messages in thread
From: Joe Perches @ 2017-03-02 22:09 UTC (permalink / raw)
To: SIMRAN SINGHAL
Cc: Larry.Finger, Florian Schilhabel, Greg KH, devel, linux-kernel,
oleg.drokin, marvin24, outreachy-kernel
On Fri, 2017-03-03 at 03:35 +0530, SIMRAN SINGHAL wrote:
> On Fri, Mar 3, 2017 at 3:29 AM, Joe Perches <joe@perches.com> wrote:
> > On Fri, 2017-03-03 at 03:25 +0530, SIMRAN SINGHAL wrote:
> > > On Fri, Mar 3, 2017 at 3:13 AM, Joe Perches <joe@perches.com> wrote:
> > > > On Fri, 2017-03-03 at 02:49 +0530, simran singhal wrote:
> > > > > The following Coccinelle script was used to detect this:
> > > > > @r@
> > > > > expression x;
> > > > > void* e;
> > > > > type T;
> > > > > identifier f;
> > > > > @@
> > > > > (
> > > > > *((T *)e)
> > > > > >
> > > > >
> > > > > ((T *)x)[...]
> > > > > >
> > > > >
> > > > > ((T*)x)->f
> > > > > >
> > > > >
> > > > > - (T*)
> > > > > e
> > > > > )
> > > >
> > > > NAK.
> > > >
> > > > Nice, but you still have to verify correctness
> > > > before submitting these patches.
> > > >
> > > > > diff --git a/drivers/staging/lustre/lustre/mgc/mgc_request.c b/drivers/staging/lustre/lustre/mgc/mgc_request.c
> > > >
> > > > []
> > > > > @@ -1034,7 +1034,7 @@ static int mgc_set_info_async(const struct lu_env *env, struct obd_export *exp,
> > > > > rc = sptlrpc_parse_flavor(val, &flvr);
> > > > > if (rc) {
> > > > > CERROR("invalid sptlrpc flavor %s to MGS\n",
> > > > > - (char *)val);
> > > > > + val);
> > > >
> > > > Try compiling this.
> > > >
> > >
> > > I compiled it before sending.
> >
> > Did you look at the warnings?
> >
> > CC [M] drivers/staging/lustre/lustre/mgc/mgc_request.o
> > drivers/staging/lustre/lustre/mgc/mgc_request.c: In function ‘mgc_set_info_async’:
> > drivers/staging/lustre/lustre/mgc/mgc_request.c:1036:115: warning: format ‘%s’ expects argument of type ‘char *’, but argument 3 has type ‘void *’ [-Wformat=]
> > CERROR("invalid sptlrpc flavor %s to MGS\n",
> >
>
> I again compiled it and this is what I got :-
>
> CHK include/config/kernel.release
> CHK include/generated/uapi/linux/version.h
> CHK include/generated/utsrelease.h
> CHK include/generated/timeconst.h
> CHK include/generated/bounds.h
> CHK include/generated/asm-offsets.h
> CALL scripts/checksyscalls.sh
> CHK include/generated/compile.h
> LD arch/x86/boot/compressed/vmlinux
> ZOFFSET arch/x86/boot/zoffset.h
> AS arch/x86/boot/header.o
> LD arch/x86/boot/setup.elf
> OBJCOPY arch/x86/boot/setup.bin
> OBJCOPY arch/x86/boot/vmlinux.bin
> BUILD arch/x86/boot/bzImage
> Setup is 17500 bytes (padded to 17920 bytes).
> System is 7128 kB
> CRC 37713343
> Kernel: arch/x86/boot/bzImage is ready (#4)
> Building modules, stage 2.
> MODPOST 4541 modules
>
> I am not getting any warning.
Then you are likely not compiling the modified file.
try:
$ <git checkout latest-next>
$ make clean
$ make allyesconfig
<apply your patch>
$ make drivers/staging/lustre/lustre/mgc/mgc_request.o
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH 3/5] staging: lustre: lustre: Remove unnecessary cast on void pointer
2017-03-02 21:19 ` [PATCH 3/5] staging: lustre: " simran singhal
2017-03-02 21:43 ` Joe Perches
@ 2017-03-03 22:41 ` kbuild test robot
2017-03-04 0:16 ` kbuild test robot
2 siblings, 0 replies; 17+ messages in thread
From: kbuild test robot @ 2017-03-03 22:41 UTC (permalink / raw)
To: simran singhal
Cc: kbuild-all, Larry.Finger, devel, florian.c.schilhabel, gregkh,
linux-kernel, oleg.drokin, outreachy-kernel
[-- Attachment #1: Type: text/plain, Size: 5461 bytes --]
Hi simran,
[auto build test WARNING on staging/staging-testing]
[also build test WARNING on v4.10 next-20170303]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/simran-singhal/staging-nvec-Remove-unnecessary-cast-on-void-pointer/20170304-061120
config: x86_64-randconfig-x018-201709 (attached as .config)
compiler: gcc-6 (Debian 6.2.0-3) 6.2.0 20160901
reproduce:
# save the attached .config to linux build tree
make ARCH=x86_64
All warnings (new ones prefixed by >>):
In file included from drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs.h:77:0,
from drivers/staging/lustre/lustre/mgc/../include/lprocfs_status.h:46,
from drivers/staging/lustre/lustre/mgc/mgc_request.c:42:
drivers/staging/lustre/lustre/mgc/mgc_request.c: In function 'mgc_set_info_async':
>> drivers/staging/lustre/lustre/mgc/mgc_request.c:1036:11: warning: format '%s' expects argument of type 'char *', but argument 3 has type 'void *' [-Wformat=]
CERROR("invalid sptlrpc flavor %s to MGS\n",
^
drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:222:30: note: in definition of macro '__CDEBUG'
libcfs_debug_msg(&msgdata, format, ## __VA_ARGS__); \
^~~~~~
>> drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:236:29: note: in expansion of macro 'CDEBUG_LIMIT'
#define CERROR(format, ...) CDEBUG_LIMIT(D_ERROR, format, ## __VA_ARGS__)
^~~~~~~~~~~~
>> drivers/staging/lustre/lustre/mgc/mgc_request.c:1036:4: note: in expansion of macro 'CERROR'
CERROR("invalid sptlrpc flavor %s to MGS\n",
^~~~~~
>> drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:244:7: warning: format '%s' expects argument of type 'char *', but argument 5 has type 'void *' [-Wformat=]
"%x-%x: " format, errnum, LERRCHKSUM(errnum), ## __VA_ARGS__)
^
drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:222:30: note: in definition of macro '__CDEBUG'
libcfs_debug_msg(&msgdata, format, ## __VA_ARGS__); \
^~~~~~
drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:243:49: note: in expansion of macro 'CDEBUG_LIMIT'
#define LCONSOLE_ERROR_MSG(errnum, format, ...) CDEBUG_LIMIT(D_CONSOLE | D_ERROR, \
^~~~~~~~~~~~
>> drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:245:37: note: in expansion of macro 'LCONSOLE_ERROR_MSG'
#define LCONSOLE_ERROR(format, ...) LCONSOLE_ERROR_MSG(0x00, format, ## __VA_ARGS__)
^~~~~~~~~~~~~~~~~~
>> drivers/staging/lustre/lustre/mgc/mgc_request.c:1052:4: note: in expansion of macro 'LCONSOLE_ERROR'
LCONSOLE_ERROR("asking sptlrpc flavor %s to MGS but currently %s is in use\n",
^~~~~~~~~~~~~~
vim +1036 drivers/staging/lustre/lustre/mgc/mgc_request.c
d7e09d039 Peng Tao 2013-05-02 1030 val = "null";
d7e09d039 Peng Tao 2013-05-02 1031 vallen = 4;
d7e09d039 Peng Tao 2013-05-02 1032 }
d7e09d039 Peng Tao 2013-05-02 1033
d7e09d039 Peng Tao 2013-05-02 1034 rc = sptlrpc_parse_flavor(val, &flvr);
d7e09d039 Peng Tao 2013-05-02 1035 if (rc) {
d7e09d039 Peng Tao 2013-05-02 @1036 CERROR("invalid sptlrpc flavor %s to MGS\n",
49b8751ff simran singhal 2017-03-03 1037 val);
0a3bdb007 Greg Kroah-Hartman 2013-08-03 1038 return rc;
d7e09d039 Peng Tao 2013-05-02 1039 }
d7e09d039 Peng Tao 2013-05-02 1040
d7e09d039 Peng Tao 2013-05-02 1041 /*
d7e09d039 Peng Tao 2013-05-02 1042 * caller already hold a mutex
d7e09d039 Peng Tao 2013-05-02 1043 */
d7e09d039 Peng Tao 2013-05-02 1044 if (cli->cl_flvr_mgc.sf_rpc == SPTLRPC_FLVR_INVALID) {
d7e09d039 Peng Tao 2013-05-02 1045 cli->cl_flvr_mgc = flvr;
d7e09d039 Peng Tao 2013-05-02 1046 } else if (memcmp(&cli->cl_flvr_mgc, &flvr,
d7e09d039 Peng Tao 2013-05-02 1047 sizeof(flvr)) != 0) {
d7e09d039 Peng Tao 2013-05-02 1048 char str[20];
d7e09d039 Peng Tao 2013-05-02 1049
d7e09d039 Peng Tao 2013-05-02 1050 sptlrpc_flavor2name(&cli->cl_flvr_mgc,
d7e09d039 Peng Tao 2013-05-02 1051 str, sizeof(str));
2d00bd17a Joe Perches 2014-11-23 @1052 LCONSOLE_ERROR("asking sptlrpc flavor %s to MGS but currently %s is in use\n",
49b8751ff simran singhal 2017-03-03 1053 val, str);
d7e09d039 Peng Tao 2013-05-02 1054 rc = -EPERM;
d7e09d039 Peng Tao 2013-05-02 1055 }
:::::: The code at line 1036 was first introduced by commit
:::::: d7e09d0397e84eefbabfd9cb353221f3c6448d83 staging: add Lustre file system client support
:::::: TO: Peng Tao <bergwolf@gmail.com>
:::::: CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 31546 bytes --]
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH 3/5] staging: lustre: lustre: Remove unnecessary cast on void pointer
2017-03-02 21:19 ` [PATCH 3/5] staging: lustre: " simran singhal
2017-03-02 21:43 ` Joe Perches
2017-03-03 22:41 ` kbuild test robot
@ 2017-03-04 0:16 ` kbuild test robot
2 siblings, 0 replies; 17+ messages in thread
From: kbuild test robot @ 2017-03-04 0:16 UTC (permalink / raw)
To: simran singhal
Cc: kbuild-all, Larry.Finger, devel, florian.c.schilhabel, gregkh,
linux-kernel, oleg.drokin, outreachy-kernel
[-- Attachment #1: Type: text/plain, Size: 5536 bytes --]
Hi simran,
[auto build test WARNING on staging/staging-testing]
[also build test WARNING on v4.10 next-20170303]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/simran-singhal/staging-nvec-Remove-unnecessary-cast-on-void-pointer/20170304-061120
config: m68k-allmodconfig (attached as .config)
compiler: m68k-linux-gcc (GCC) 4.9.0
reproduce:
wget https://raw.githubusercontent.com/01org/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
make.cross ARCH=m68k
All warnings (new ones prefixed by >>):
In file included from drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs.h:77:0,
from drivers/staging/lustre/lustre/mgc/../include/lprocfs_status.h:46,
from drivers/staging/lustre/lustre/mgc/mgc_request.c:42:
drivers/staging/lustre/lustre/mgc/mgc_request.c: In function 'mgc_set_info_async':
drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:216:16: warning: format '%s' expects argument of type 'char *', but argument 3 has type 'void *' [-Wformat=]
static struct libcfs_debug_msg_data msgdata; \
^
>> drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:232:2: note: in expansion of macro '__CDEBUG'
__CDEBUG(&cdls, mask, format, ## __VA_ARGS__); \
^
drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:236:29: note: in expansion of macro 'CDEBUG_LIMIT'
#define CERROR(format, ...) CDEBUG_LIMIT(D_ERROR, format, ## __VA_ARGS__)
^
drivers/staging/lustre/lustre/mgc/mgc_request.c:1036:4: note: in expansion of macro 'CERROR'
CERROR("invalid sptlrpc flavor %s to MGS\n",
^
drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:216:16: warning: format '%s' expects argument of type 'char *', but argument 5 has type 'void *' [-Wformat=]
static struct libcfs_debug_msg_data msgdata; \
^
>> drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:232:2: note: in expansion of macro '__CDEBUG'
__CDEBUG(&cdls, mask, format, ## __VA_ARGS__); \
^
drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:243:49: note: in expansion of macro 'CDEBUG_LIMIT'
#define LCONSOLE_ERROR_MSG(errnum, format, ...) CDEBUG_LIMIT(D_CONSOLE | D_ERROR, \
^
drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h:245:37: note: in expansion of macro 'LCONSOLE_ERROR_MSG'
#define LCONSOLE_ERROR(format, ...) LCONSOLE_ERROR_MSG(0x00, format, ## __VA_ARGS__)
^
drivers/staging/lustre/lustre/mgc/mgc_request.c:1052:4: note: in expansion of macro 'LCONSOLE_ERROR'
LCONSOLE_ERROR("asking sptlrpc flavor %s to MGS but currently %s is in use\n",
^
vim +/__CDEBUG +232 drivers/staging/lustre/lustre/mgc/../include/../../include/linux/libcfs/libcfs_debug.h
d7e09d039 Peng Tao 2013-05-02 210 return mask & D_CANTMASK ||
d7e09d039 Peng Tao 2013-05-02 211 ((libcfs_debug & mask) && (libcfs_subsystem_debug & subsystem));
d7e09d039 Peng Tao 2013-05-02 212 }
d7e09d039 Peng Tao 2013-05-02 213
d7e09d039 Peng Tao 2013-05-02 214 #define __CDEBUG(cdls, mask, format, ...) \
d7e09d039 Peng Tao 2013-05-02 215 do { \
d7e09d039 Peng Tao 2013-05-02 @216 static struct libcfs_debug_msg_data msgdata; \
d7e09d039 Peng Tao 2013-05-02 217 \
d7e09d039 Peng Tao 2013-05-02 218 CFS_CHECK_STACK(&msgdata, mask, cdls); \
d7e09d039 Peng Tao 2013-05-02 219 \
d7e09d039 Peng Tao 2013-05-02 220 if (cfs_cdebug_show(mask, DEBUG_SUBSYSTEM)) { \
d7e09d039 Peng Tao 2013-05-02 221 LIBCFS_DEBUG_MSG_DATA_INIT(&msgdata, mask, cdls); \
d7e09d039 Peng Tao 2013-05-02 222 libcfs_debug_msg(&msgdata, format, ## __VA_ARGS__); \
d7e09d039 Peng Tao 2013-05-02 223 } \
d7e09d039 Peng Tao 2013-05-02 224 } while (0)
d7e09d039 Peng Tao 2013-05-02 225
d7e09d039 Peng Tao 2013-05-02 226 #define CDEBUG(mask, format, ...) __CDEBUG(NULL, mask, format, ## __VA_ARGS__)
d7e09d039 Peng Tao 2013-05-02 227
d7e09d039 Peng Tao 2013-05-02 228 #define CDEBUG_LIMIT(mask, format, ...) \
d7e09d039 Peng Tao 2013-05-02 229 do { \
a3ea59e0e Lisa Nguyen 2013-10-21 230 static struct cfs_debug_limit_state cdls; \
d7e09d039 Peng Tao 2013-05-02 231 \
d7e09d039 Peng Tao 2013-05-02 @232 __CDEBUG(&cdls, mask, format, ## __VA_ARGS__); \
d7e09d039 Peng Tao 2013-05-02 233 } while (0)
d7e09d039 Peng Tao 2013-05-02 234
d7e09d039 Peng Tao 2013-05-02 235 #define CWARN(format, ...) CDEBUG_LIMIT(D_WARNING, format, ## __VA_ARGS__)
:::::: The code at line 232 was first introduced by commit
:::::: d7e09d0397e84eefbabfd9cb353221f3c6448d83 staging: add Lustre file system client support
:::::: TO: Peng Tao <bergwolf@gmail.com>
:::::: CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 39600 bytes --]
^ permalink raw reply [flat|nested] 17+ messages in thread