Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src-draft/trunk]: src/sys/dev/pci Refactor iwn_parent.



details:   https://anonhg.NetBSD.org/src-all/rev/b63d3625b63a
branches:  trunk
changeset: 370592:b63d3625b63a
user:      Nathanial Sloss <nat%netbsd.org@localhost>
date:      Sun Aug 07 20:11:57 2022 +1000

description:
Refactor iwn_parent.

This brings it in line with other drivers.

diffstat:

 sys/dev/pci/if_iwn.c |  7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diffs (35 lines):

diff -r a0e03e991da9 -r b63d3625b63a sys/dev/pci/if_iwn.c
--- a/sys/dev/pci/if_iwn.c      Sun Aug 07 20:10:43 2022 +1000
+++ b/sys/dev/pci/if_iwn.c      Sun Aug 07 20:11:57 2022 +1000
@@ -980,7 +980,8 @@
                } else {
                        /* update filters or whatever */
                }
-       }
+       } else
+               iwn_stop(vap->iv_ifp, 1);
 
        if (startall)
                ieee80211_start_all(ic);
@@ -2326,10 +2327,12 @@
                 * Purge the xmit queue so we don't have old frames
                 * during a new association attempt.
                 */
+#if 0
                iwn_stop(ifp, 0);
                error = iwn_init(ifp);
                if (error)
                        return error;
+#endif
                sc->sc_beacon_wait = 0;
                ifp->if_flags &= ~IFF_OACTIVE;
                iwn_start(ifp);
@@ -6985,7 +6988,7 @@
 
        if (!disable)
                mutex_enter(&sc->sc_mtx);
-       sc->sc_flags &= ~IWN_FLAG_HW_INITED;
+       sc->sc_flags &= ~(IWN_FLAG_HW_INITED | IWN_FLAG_STARTED);
        ifp->if_timer = sc->sc_tx_timer = 0;
        ifp->if_flags &= ~(IFF_RUNNING | IFF_OACTIVE);
 



Home | Main Index | Thread Index | Old Index