提交 683fbb42 编写于 作者: A Arend van Spriel 提交者: Greg Kroah-Hartman

staging: brcm80211: only allow one call to add_interface callback

The driver only supports one network interface to be associated
with it. Only for the first call it does actually something. For
subsequent calls it does return -ENODEV error code.
Reported-by: NJohannes Berg <johannes@sipsolutions.net>
Reviewed-by: NRoland Vossen <rvossen@broadcom.com>
Reviewed-by: NPieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: NFranky Lin <frankyl@broadcom.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 71e233a2
......@@ -341,7 +341,10 @@ brcms_ops_add_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif)
wl = hw->priv;
LOCK(wl);
err = brcms_up(wl);
if (!wl->pub->up)
err = brcms_up(wl);
else
err = -ENODEV;
UNLOCK(wl);
if (err != 0)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册