svn commit: r319088 - head/sys/dev/rtwn
Andriy Voskoboinyk
avos at FreeBSD.org
Sun May 28 22:51:08 UTC 2017
Author: avos
Date: Sun May 28 22:51:06 2017
New Revision: 319088
URL: https://svnweb.freebsd.org/changeset/base/319088
Log:
rtwn: fix connection problems with 'options RTWN_WITHOUT_UCODE'
sc_set_media_status() callback may involve some generic code in addition to
firmware-specific part (e.g., link status register setup for RTL8188E);
so, remove 'RTWN_WITHOUT_UCODE' ifdefs around it.
Tested with RTL8188CUS, RTL8188EU and RTL8821AU, STA mode.
Modified:
head/sys/dev/rtwn/if_rtwn.c
Modified: head/sys/dev/rtwn/if_rtwn.c
==============================================================================
--- head/sys/dev/rtwn/if_rtwn.c Sun May 28 22:38:19 2017 (r319087)
+++ head/sys/dev/rtwn/if_rtwn.c Sun May 28 22:51:06 2017 (r319088)
@@ -91,9 +91,9 @@ static struct ieee80211vap *rtwn_vap_cre
static void rtwn_vap_delete(struct ieee80211vap *);
static int rtwn_read_chipid(struct rtwn_softc *);
static int rtwn_ioctl_reset(struct ieee80211vap *, u_long);
-#ifndef RTWN_WITHOUT_UCODE
static void rtwn_set_media_status(struct rtwn_softc *,
union sec_param *);
+#ifndef RTWN_WITHOUT_UCODE
static int rtwn_tx_fwpkt_check(struct rtwn_softc *,
struct ieee80211vap *);
static int rtwn_construct_nulldata(struct rtwn_softc *,
@@ -703,13 +703,13 @@ rtwn_ioctl_reset(struct ieee80211vap *va
return (error);
}
-#ifndef RTWN_WITHOUT_UCODE
static void
rtwn_set_media_status(struct rtwn_softc *sc, union sec_param *data)
{
sc->sc_set_media_status(sc, data->macid);
}
+#ifndef RTWN_WITHOUT_UCODE
static int
rtwn_tx_fwpkt_check(struct rtwn_softc *sc, struct ieee80211vap *vap)
{
@@ -1743,11 +1743,9 @@ rtwn_newassoc(struct ieee80211_node *ni,
return;
}
-#ifndef RTWN_WITHOUT_UCODE
/* Notify firmware. */
id |= RTWN_MACID_VALID;
rtwn_cmd_sleepable(sc, &id, sizeof(id), rtwn_set_media_status);
-#endif
}
static void
@@ -1759,10 +1757,8 @@ rtwn_node_free(struct ieee80211_node *ni
RTWN_NT_LOCK(sc);
if (un->id != RTWN_MACID_UNDEFINED) {
sc->node_list[un->id] = NULL;
-#ifndef RTWN_WITHOUT_UCODE
rtwn_cmd_sleepable(sc, &un->id, sizeof(un->id),
rtwn_set_media_status);
-#endif
}
RTWN_NT_UNLOCK(sc);
More information about the svn-src-head
mailing list