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 Limit the number of streams to 2 as some s...



details:   https://anonhg.NetBSD.org/src-all/rev/ade652901f6d
branches:  trunk
changeset: 376821:ade652901f6d
user:      Nathanial Sloss <nat%netbsd.org@localhost>
date:      Tue Jun 23 01:26:02 2020 +1000

description:
Limit the number of streams to 2 as some supported variants of
iwn report the wrong number of streams.

diffstat:

 sys/dev/pci/if_iwn.c |  4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diffs (14 lines):

diff -r e76fce8ac978 -r ade652901f6d sys/dev/pci/if_iwn.c
--- a/sys/dev/pci/if_iwn.c      Sat Jun 20 08:35:14 2020 +1000
+++ b/sys/dev/pci/if_iwn.c      Tue Jun 23 01:26:02 2020 +1000
@@ -721,6 +721,10 @@ iwn_config_complete(device_t self)
 
        ic->ic_txstream = sc->ntxchains;
        ic->ic_rxstream = sc->nrxchains;
+       if (ic->ic_rxstream > 2)
+               ic->ic_rxstream = 2;
+       if (ic->ic_txstream > 2)
+               ic->ic_txstream = 2;
 
        ic->ic_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
 



Home | Main Index | Thread Index | Old Index