Remove switch(type) as type is constant and never matches any of the cases. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@xxxxxxxxx> --- drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c index 3fe27ee75b47..82722897d6cc 100644 --- a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c +++ b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c @@ -2549,7 +2549,6 @@ static int cfg80211_rtw_mgmt_tx(struct wiphy *wiphy, struct wireless_dev *wdev, bool ack = true; u8 tx_ch = (u8)ieee80211_frequency_to_channel(chan->center_freq); u8 category, action; - int type = (-1); struct adapter *padapter; struct rtw_wdev_priv *pwdev_priv; @@ -2581,19 +2580,6 @@ static int cfg80211_rtw_mgmt_tx(struct wiphy *wiphy, struct wireless_dev *wdev, tx_ret = _cfg80211_rtw_mgmt_tx(padapter, tx_ch, buf, len); } while (dump_cnt < dump_limit && tx_ret != _SUCCESS); - switch (type) { - case P2P_GO_NEGO_CONF: - rtw_clear_scan_deny(padapter); - break; - case P2P_INVIT_RESP: - if (pwdev_priv->invit_info.flags & BIT(0) && pwdev_priv->invit_info.status == 0) { - rtw_set_scan_deny(padapter, 5000); - rtw_pwr_wakeup_ex(padapter, 5000); - rtw_clear_scan_deny(padapter); - } - break; - } - cancel_ps_deny: rtw_ps_deny_cancel(padapter, PS_DENY_MGNT_TX); exit: -- 2.45.2