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] [day] [month] [year] [list]
Date:   Mon, 10 Sep 2018 10:35:02 +0200
From:   Greg KH <gregkh@...uxfoundation.org>
To:     Ray Clinton <mr.ray.clinton@...il.com>
Cc:     abbotti@....co.uk, hsweeten@...ionengravers.com,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/4] staging: comedi: Correct multiline dereference as
 per TODO

On Thu, Aug 30, 2018 at 01:32:17PM -0400, Ray Clinton wrote:
> Using checkpatch.pl I was able to find a multiline dereference which goes
> again the coding style for the kernel. I'm still working on my email client so
> the indentation looks bad here (in gmail) but the arguments for
> comedi_check_trigger_arg_min should go just under the opening (
> 
> Signed-off-by: Ray Clinton <mr.ray.clinton@...il.com>
> ---
>  drivers/staging/comedi/drivers/ni_labpc_common.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/staging/comedi/drivers/ni_labpc_common.c
> b/drivers/staging/comedi/drivers/ni_labpc_common.c
> index 7fa2d39..0fad809 100644
> --- a/drivers/staging/comedi/drivers/ni_labpc_common.c
> +++ b/drivers/staging/comedi/drivers/ni_labpc_common.c
> @@ -560,10 +560,10 @@ static int labpc_ai_cmdtest(struct comedi_device *dev,
>         /* make sure scan timing is not too fast */
>         if (cmd->scan_begin_src == TRIG_TIMER) {
>                 if (cmd->convert_src == TRIG_TIMER) {
> -                       err |= comedi_check_trigger_arg_min(&cmd->
> -                                                           scan_begin_arg,
> -                                                           cmd->convert_arg *
> -                                                           cmd->chanlist_len);
> +                       err |= comedi_check_trigger_arg_min(
> +                                                          &cmd->scan_begin_arg,
> +                                                          cmd->convert_arg *
> +                                                          cmd->chanlist_len);

Ick, this is still messy, just try making this:

			err |= comedi_check_trigger_arg_min(&cmd->scan_begin_arg,
							    cmd->convert_arg * cmd->chanlist_len);

Yeah, it's over 80 columns, but it looks better and is easier to read,
right?

Also, all your patches have the whitespace turned from tabs into spaces,
making them impossible to be applied even if I wanted to :)

thanks,

greg k-h

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ