Skip to contentSkip to conversation

video: omapfb: Fix fall-through warning for Clang

PATCH Applied Gustavo A. R. Silva 2 participants 3 messages Oct 14, 2021

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 video: omapfb: Fix fall-through warning for Clang

Fix the following fallthrough warnings:

drivers/video/fbdev/omap/omapfb_main.c:1558:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]

           case 0:
           ^
   drivers/video/fbdev/omap/omapfb_main.c:1558:2: note: insert 'break;' to avoid fall-through
           case 0:
           ^
           break;

1 warning generated.

This helps with the ongoing efforts to globally enable -Wimplicit-fallthrough for Clang.

---
 drivers/video/fbdev/omap/omapfb_main.c | 1 +
 1 file changed, 1 insertion(+)
drivers/video/fbdev/omap/omapfb_main.c +1 -0
index 3d090d2d9ed9..b495c09e6102 100644
@@ -1555,6 +1555,7 @@ static void omapfb_free_resources(struct omapfb_device *fbdev, int state)
 	case 1:
 		dev_set_drvdata(fbdev->dev, NULL);
 		kfree(fbdev);
+		break;
 	case 0:
 		/* nothing to free */
 		break;
Signature · 1 line
2.27.0
Applied
#1 lore raw

Hi Gustavo,

Quoted 11 lines · Gustavo A. R. Silva

Fix the following fallthrough warnings:

drivers/video/fbdev/omap/omapfb_main.c:1558:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]

           case 0:
           ^
   drivers/video/fbdev/omap/omapfb_main.c:1558:2: note: insert 'break;' to avoid fall-through
           case 0:
           ^
           break;

1 warning generated.

Quoted 7 lines

This helps with the ongoing efforts to globally enable -Wimplicit-fallthrough for Clang.

applied to drm-misc-next. It will show up in -next in 1-2 weeks time. Thanks,
Sam

#2 lore raw
Quoted 13 lines · Sam Ravnborg

Hi Gustavo,

Quoted 11 lines · Gustavo A. R. Silva

Fix the following fallthrough warnings:

drivers/video/fbdev/omap/omapfb_main.c:1558:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]

           case 0:
           ^
   drivers/video/fbdev/omap/omapfb_main.c:1558:2: note: insert 'break;' to avoid fall-through
           case 0:
           ^
           break;

1 warning generated.

Quoted 8 lines
Quoted 7 lines

This helps with the ongoing efforts to globally enable -Wimplicit-fallthrough for Clang.

applied to drm-misc-next. It will show up in -next in 1-2 weeks time.

Great. :)

Thanks, Sam.
--
Gustavo