diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2015-03-02 22:12:58 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2015-03-02 22:12:58 +0000 |
commit | c144d3d96e0c0d4ce9cdabc1d941ba7af50f7d2c (patch) | |
tree | e35bd6475b12177cadb383fc8fad0aeb3c8455a5 /sys/dev/pci/if_iwm.c | |
parent | 40b326539ed32a1108217b668838639f33e3eb5e (diff) |
sc_fixed_ridx is initialised to 0 but tested as it it were initialised
to -1. The result of this is tx frames were always sent out at fixed
rate 0 instead of ni_txrate.
Match the iwn behaviour and test ic_fixed_rate for -1 instead.
Problem spotted by kettenis@ in an earlier diff.
ok kettenis@ stsp@
Diffstat (limited to 'sys/dev/pci/if_iwm.c')
-rw-r--r-- | sys/dev/pci/if_iwm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/pci/if_iwm.c b/sys/dev/pci/if_iwm.c index a199a273f12..bc19315c6e5 100644 --- a/sys/dev/pci/if_iwm.c +++ b/sys/dev/pci/if_iwm.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_iwm.c,v 1.28 2015/03/02 13:59:38 jsg Exp $ */ +/* $OpenBSD: if_iwm.c,v 1.29 2015/03/02 22:12:57 jsg Exp $ */ /* * Copyright (c) 2014 genua mbh <info@genua.de> @@ -3715,7 +3715,7 @@ iwm_tx_fill_cmd(struct iwm_softc *sc, struct iwm_node *in, /* for data frames, use RS table */ if (type == IEEE80211_FC0_TYPE_DATA) { - if (sc->sc_fixed_ridx != -1) { + if (sc->sc_ic.ic_fixed_rate != -1) { tx->initial_rate_index = sc->sc_fixed_ridx; } else { tx->initial_rate_index = (nrates-1) - in->in_ni.ni_txrate; |