]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
wlcore: Use fallthrough pseudo-keyword
authorGustavo A. R. Silva <gustavoars@kernel.org>
Thu, 8 Oct 2020 22:09:05 +0000 (17:09 -0500)
committerKalle Valo <kvalo@codeaurora.org>
Sat, 7 Nov 2020 11:30:54 +0000 (13:30 +0200)
In order to enable -Wimplicit-fallthrough for Clang[1], replace the
existing /* fall-through */ comments with the new pseudo-keyword
macro fallthrough[2].

[1] https://git.kernel.org/linus/e2079e93f562c7f7a030eb7642017ee5eabaaa10
[2] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through

Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/20201008220905.GA8040@embeddedor
drivers/net/wireless/ti/wlcore/main.c

index 6863fd552d5e7f33ce61818942021d16e5d72b41..122c7a4b374f17b36b7b00081bf891014c251600 100644 (file)
@@ -2227,7 +2227,7 @@ static int wl12xx_init_vif_data(struct wl1271 *wl, struct ieee80211_vif *vif)
        switch (ieee80211_vif_type_p2p(vif)) {
        case NL80211_IFTYPE_P2P_CLIENT:
                wlvif->p2p = 1;
-               /* fall-through */
+               fallthrough;
        case NL80211_IFTYPE_STATION:
        case NL80211_IFTYPE_P2P_DEVICE:
                wlvif->bss_type = BSS_TYPE_STA_BSS;
@@ -2237,7 +2237,7 @@ static int wl12xx_init_vif_data(struct wl1271 *wl, struct ieee80211_vif *vif)
                break;
        case NL80211_IFTYPE_P2P_GO:
                wlvif->p2p = 1;
-               /* fall-through */
+               fallthrough;
        case NL80211_IFTYPE_AP:
        case NL80211_IFTYPE_MESH_POINT:
                wlvif->bss_type = BSS_TYPE_AP_BSS;