lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAAhDqq1hwtgqyOnfx__OFgTkm9QDs0or-Zg76cMojShCYRAN2w@mail.gmail.com>
Date:   Wed, 15 Jul 2020 04:41:52 -0400
From:   B K Karthik <bkkarthik@...u.pes.edu>
To:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc:     Ian Abbott <abbotti@....co.uk>,
        H Hartley Sweeten <hsweeten@...ionengravers.com>,
        Al Viro <viro@...iv.linux.org.uk>,
        Xiyu Yang <xiyuyang19@...an.edu.cn>,
        Michel Lespinasse <walken@...gle.com>,
        Divyansh Kamboj <kambojdivyansh2000@...il.com>,
        devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] staging: comedi: comedi_fops.c: changed type in
 assignment to unsigned int *

On Wed, Jul 15, 2020 at 4:31 AM Greg Kroah-Hartman
<gregkh@...uxfoundation.org> wrote:
>
> On Wed, Jul 15, 2020 at 01:56:45PM +0530, B K Karthik wrote:
> > On Wed, Jul 15, 2020, 12:38 PM Greg Kroah-Hartman <
> > gregkh@...uxfoundation.org> wrote:
> >
> > > On Wed, Jul 15, 2020 at 12:48:13AM -0400, B K Karthik wrote:
> > > > fixed a sparse warning by changing the type in
> > > > assignment from void [noderef] __user * to unsigned int *
> > > > (different address space)
> > > >
> > > > Signed-off-by: B K Karthik <karthik.bk2000@...e.com>
> > > > ---
> > > >  drivers/staging/comedi/comedi_fops.c | 2 +-
> > > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > > >
> > > > diff --git a/drivers/staging/comedi/comedi_fops.c
> > > b/drivers/staging/comedi/comedi_fops.c
> > > > index 3f70e5dfac39..4cc012e231b7 100644
> > > > --- a/drivers/staging/comedi/comedi_fops.c
> > > > +++ b/drivers/staging/comedi/comedi_fops.c
> > > > @@ -2956,7 +2956,7 @@ static int get_compat_cmd(struct comedi_cmd *cmd,
> > > >       cmd->scan_end_arg = v32.scan_end_arg;
> > > >       cmd->stop_src = v32.stop_src;
> > > >       cmd->stop_arg = v32.stop_arg;
> > > > -     cmd->chanlist = compat_ptr(v32.chanlist);
> > > > +     cmd->chanlist = (unsigned int *) compat_ptr(v32.chanlist);
> > > >       cmd->chanlist_len = v32.chanlist_len;
> > > >       cmd->data = compat_ptr(v32.data);
> > > >       cmd->data_len = v32.data_len;
> > >
> > > Always run your patches through checkpatch before sending them, so you
> > > do not have a grumpy maintainer telling you that you have to run
> > > checkpatch on your patch before sending them.
> > >
> >
> > I will. Sorry for that.
> >
> > But the error that's being shown in this patch is something that comes up
> > on its own.
>
> No it is not.
>
> > git format-patch leaves trailing whitespace in blank lines.
>
> It does?  Where is any trailing whitespace here?  That's not the issue.

To give you an example,
https://lore.kernel.org/lkml/20200714132350.naekk4zqivpuaedi@pesu-pes-edu/
was a patch i submitted recently.
This is what checkpatch has to say:

$ perl scripts/checkpatch.pl -f
../cbridge/1407d/1/0001-drivers-staging-media-atomisp-pci-css_2401_system-ho.patch
ERROR: trailing whitespace
#21: FILE: ../cbridge/1407d/1/0001-drivers-staging-media-atomisp-pci-css_2401_system-ho.patch:21:
+ $

ERROR: trailing whitespace
#23: FILE: ../cbridge/1407d/1/0001-drivers-staging-media-atomisp-pci-css_2401_system-ho.patch:23:
+ $

ERROR: trailing whitespace
#30: FILE: ../cbridge/1407d/1/0001-drivers-staging-media-atomisp-pci-css_2401_system-ho.patch:30:
+ $

ERROR: trailing whitespace
#37: FILE: ../cbridge/1407d/1/0001-drivers-staging-media-atomisp-pci-css_2401_system-ho.patch:37:
+ $

ERROR: trailing whitespace
#44: FILE: ../cbridge/1407d/1/0001-drivers-staging-media-atomisp-pci-css_2401_system-ho.patch:44:
+ $

ERROR: trailing whitespace
#51: FILE: ../cbridge/1407d/1/0001-drivers-staging-media-atomisp-pci-css_2401_system-ho.patch:51:
+-- $

total: 6 errors, 0 warnings, 53 lines checked

NOTE: For some of the reported defects, checkpatch may be able to
      mechanically convert to the typical style using --fix or --fix-inplace.

NOTE: Whitespace errors detected.
      You may wish to use scripts/cleanpatch or scripts/cleanfile

../cbridge/1407d/1/0001-drivers-staging-media-atomisp-pci-css_2401_system-ho.patch
has style problems, please review.

NOTE: If any of the errors are false positives, please report
      them to the maintainer, see CHECKPATCH in MAINTAINERS.

Does this happen only to patches I make? Am I making a silly mistake
while making a patch?
I use 'git format-patch -1' to generate the patch file.
If I am going wrong somewhere, please let me know.

>
> > It has been reported to the maintainers.
>
> It was?  Where?

I am extremely sorry, I should have verified if it was indeed reported
before telling it out.
It has not been reported (yet).
I apologise for my mistake.

thanks,

karthik

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ