[PATCH 1/1] net: replace /* Fall through */
Tom Rini
trini at konsulko.com
Thu Apr 6 23:10:58 CEST 2023
On Sat, Apr 01, 2023 at 09:30:05AM +0200, Heinrich Schuchardt wrote:
> gcc 12 does not understand /* Fall through */.
> Use the fallthrough macro instead.
>
> Fallthrough at the start of a switch statement makes no sense.
>
> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt at canonical.com>
> Reviewed-by: Ramon Fried <rfried.dev at gmail.com>
> Reviewed-by: Simon Glass <sjg at chromium.org>
[snip]
> @@ -1484,11 +1483,11 @@ static int net_check_prereq(enum proto_t protocol)
> puts("*** ERROR: `serverip' not set\n");
> return 1;
> }
> + fallthrough;
> #if defined(CONFIG_CMD_PING) || \
> defined(CONFIG_CMD_DNS) || defined(CONFIG_PROT_UDP)
> common:
> #endif
This leads to:
net/net.c:1486:3: error: fallthrough annotation does not directly precede switch label
with clang.
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20230406/aae3cfc7/attachment.sig>
More information about the U-Boot
mailing list