Skip to content

Commit

Permalink
rtl8187: Add missing priv->vif assignments
Browse files Browse the repository at this point in the history
This adds missing priv->vif assignments after "mac80211: don't use
interface indices in drivers" change. As rtl8180, rtl8187 also needs
priv->vif to be set, as without this an oops can happen in rtl8187_tx
function (priv->vif is passed to ieee80211_rts_duration).

Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
Acked-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Herton Ronaldo Krzesinski authored and John W. Linville committed Apr 15, 2008
1 parent 56690c2 commit aa979a6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/net/wireless/rtl8187_dev.c
Original file line number Diff line number Diff line change
Expand Up @@ -509,6 +509,8 @@ static int rtl8187_add_interface(struct ieee80211_hw *dev,
return -EOPNOTSUPP;
}

priv->vif = conf->vif;

rtl818x_iowrite8(priv, &priv->map->EEPROM_CMD, RTL818X_EEPROM_CMD_CONFIG);
for (i = 0; i < ETH_ALEN; i++)
rtl818x_iowrite8(priv, &priv->map->MAC[i],
Expand All @@ -523,6 +525,7 @@ static void rtl8187_remove_interface(struct ieee80211_hw *dev,
{
struct rtl8187_priv *priv = dev->priv;
priv->mode = IEEE80211_IF_TYPE_MNTR;
priv->vif = NULL;
}

static int rtl8187_config(struct ieee80211_hw *dev, struct ieee80211_conf *conf)
Expand Down

0 comments on commit aa979a6

Please sign in to comment.