mac80211 rate control decides which odfm rates to use so all of them should be set enabled at the appropriate bit rate. This means vnt_get_ofdm_rate is no longer required. Signed-off-by: Malcolm Priestley <tvboxspy@xxxxxxxxx> --- drivers/staging/vt6656/card.c | 54 +++-------------------------------- 1 file changed, 4 insertions(+), 50 deletions(-) diff --git a/drivers/staging/vt6656/card.c b/drivers/staging/vt6656/card.c index dc3ab10eb630..4abbe9b30b65 100644 --- a/drivers/staging/vt6656/card.c +++ b/drivers/staging/vt6656/card.c @@ -100,48 +100,6 @@ static u16 vnt_get_cck_rate(struct vnt_private *priv, u16 rate_idx) return RATE_1M; } -/* - * Description: Get OFDM mode basic rate - * - * Parameters: - * In: - * priv - The adapter to be set - * rate_idx - Receiving data rate - * Out: - * none - * - * Return Value: response Control frame rate - * - */ -static u16 vnt_get_ofdm_rate(struct vnt_private *priv, u16 rate_idx) -{ - u16 ui = rate_idx; - - dev_dbg(&priv->usb->dev, "%s basic rate: %d\n", - __func__, priv->basic_rates); - - if (!vnt_ofdm_min_rate(priv)) { - dev_dbg(&priv->usb->dev, "%s (NO OFDM) %d\n", - __func__, rate_idx); - if (rate_idx > RATE_24M) - rate_idx = RATE_24M; - return rate_idx; - } - - while (ui > RATE_11M) { - if (priv->basic_rates & (1 << ui)) { - dev_dbg(&priv->usb->dev, "%s rate: %d\n", - __func__, ui); - return ui; - } - ui--; - } - - dev_dbg(&priv->usb->dev, "%s basic rate: 24M\n", __func__); - - return RATE_24M; -} - /* * Description: Calculate TxRate and RsvTime fields for RSPINF in OFDM mode. * @@ -289,20 +247,16 @@ void vnt_set_rspinf(struct vnt_private *priv, u8 bb_type) vnt_calculate_ofdm_rate(RATE_24M, bb_type, &tx_rate[4], &rsv_time[4]); /*RSPINF_a_36*/ - vnt_calculate_ofdm_rate(vnt_get_ofdm_rate(priv, RATE_36M), - bb_type, &tx_rate[5], &rsv_time[5]); + vnt_calculate_ofdm_rate(RATE_36M, bb_type, &tx_rate[5], &rsv_time[5]); /*RSPINF_a_48*/ - vnt_calculate_ofdm_rate(vnt_get_ofdm_rate(priv, RATE_48M), - bb_type, &tx_rate[6], &rsv_time[6]); + vnt_calculate_ofdm_rate(RATE_48M, bb_type, &tx_rate[6], &rsv_time[6]); /*RSPINF_a_54*/ - vnt_calculate_ofdm_rate(vnt_get_ofdm_rate(priv, RATE_54M), - bb_type, &tx_rate[7], &rsv_time[7]); + vnt_calculate_ofdm_rate(RATE_54M, bb_type, &tx_rate[7], &rsv_time[7]); /*RSPINF_a_72*/ - vnt_calculate_ofdm_rate(vnt_get_ofdm_rate(priv, RATE_54M), - bb_type, &tx_rate[8], &rsv_time[8]); + vnt_calculate_ofdm_rate(RATE_54M, bb_type, &tx_rate[8], &rsv_time[8]); put_unaligned(phy[0].len, (u16 *)&data[0]); data[2] = phy[0].signal; -- 2.25.1