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: <Yg9GcPtAOeVtmTyg@kroah.com>
Date:   Fri, 18 Feb 2022 08:10:40 +0100
From:   Greg KH <gregkh@...uxfoundation.org>
To:     Ahamed Husni <ahamedhusni73@...il.com>
Cc:     Bryan O'Donoghue <pure.logic@...us-software.ie>, elder@...nel.org,
        greybus-dev@...ts.linaro.org, linux-staging@...ts.linux.dev,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] staging: greybus: loopback: Fix Coding Style Error

On Fri, Feb 18, 2022 at 10:22:28AM +0530, Ahamed Husni wrote:
> Hi Greg,
> 
> On Fri, Feb 18, 2022 at 12:56 AM Greg KH <gregkh@...uxfoundation.org> wrote:
> > Did you try to build this change?
> 
> I am a newbie kernel dev and trying to understand how things work.
> I did not build this change by the time I sent you this, thinking this
> is just a style change.
> I should have tested the build. I am sorry.

You always have to build-test your changes, as you have found out.

> Now I built the changes by setting the following configurations.
> CONFIG_GREYBUS
> CONFIG_STAGING
> CONFIG_GREYBUS_LOOPBACK
> 
> My change introduces the following error.
> ''''
> drivers/staging/greybus/loopback.c:166:2: error: expected identifier
> or ‘(’ before ‘do’
>   166 |  do {            \
>       |  ^~
> ''''
> I could not fix or find the reason for this error. Please guide me in
> this regard.

There is nothing wrong with the original code here.  Remember that
checkpatch is a perl script that gives good advice, but it is not always
correct.  You must always manually check it based on your knowledge of
the C language.

I recommend learning a bit more C before working on kernel code.

Best of luck!

greg k-h

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ