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]
Date:   Mon, 16 Oct 2023 14:39:28 +0200
From:   Jiri Slaby <jirislaby@...nel.org>
To:     Florian Eckert <fe@....tdt.de>, m.brock@...mierlo.com
Cc:     Eckert.Florian@...glemail.com, gregkh@...uxfoundation.org,
        pavel@....cz, lee@...nel.org, kabel@...nel.org,
        u.kleine-koenig@...gutronix.de, linux-kernel@...r.kernel.org,
        linux-serial@...r.kernel.org, linux-leds@...r.kernel.org,
        kernel test robot <lkp@...el.com>
Subject: Re: [PATCH v3 3/4] trigger: ledtrig-tty: move variable definition to
 the top

On 16. 10. 23, 11:12, Florian Eckert wrote:
> 
> 
> On 2023-10-16 10:46, m.brock@...mierlo.com wrote:
>> Florian Eckert wrote on 2023-10-16 09:13:
>>> Has complained about the following construct:
>>
>> Who is "Has" or who/what has complained?
> 
> The test robot who does not agree with my change in the v1 patchset.

Well, you should have put subject to that sentence, so that we can 
understand. And not to parse "Has" as a tool/person name ;).

>>> drivers/leds/trigger/ledtrig-tty.c:362:3: error: a label can only be
>>> part of a statement and a declaration is not a statement
>>>
>>> Hence move the variable definition to the beginning of the function.
>>>
>>> Reported-by: kernel test robot <lkp@...el.com>
>>> Closes:
>>> https://lore.kernel.org/oe-kbuild-all/202309270440.IJB24Xap-lkp@intel.com/
>>> Signed-off-by: Florian Eckert <fe@....tdt.de>
>>> ---
>>> @@ -124,8 +125,6 @@ static void ledtrig_tty_work(struct work_struct 
>>> *work)
>>>
>>>      if (icount.rx != trigger_data->rx ||
>>>          icount.tx != trigger_data->tx) {
>>> -        unsigned long interval = LEDTRIG_TTY_INTERVAL;
>>> -
>>
>> Is this kernel test robot broken?
> 
> The test robot does nothing wrong.
> 
>> I see no label definition here.

case is a label.

>> And this variable declaration is at the start of a new block which 
>> does not
>> even require C99 support.

Nah. The block begins after the switch.
So
"""
switch (X) {
type var;
case X:
}
would work. Moving the def after case is no longer at the block beginning.

So just wrap put the case code in a block like we are used to:
"""
case X: {
   type var;
}
""".

regards,
-- 
js
suse labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ