diff options
| author | Adrian Chadd <adrian@FreeBSD.org> | 2016-04-26 01:37:03 +0000 |
|---|---|---|
| committer | Adrian Chadd <adrian@FreeBSD.org> | 2016-04-26 01:37:03 +0000 |
| commit | 9f3a915030c102cd28bd208c40d0c236c845435c (patch) | |
| tree | fb2ce84a0755fbe2a5b33c60cf61dea7b62a97e5 /sys/dev | |
| parent | f026d6931a01b46883f2292f2d431aa66aee5ee5 (diff) | |
Notes
Diffstat (limited to 'sys/dev')
| -rw-r--r-- | sys/dev/ath/if_ath.c | 13 | ||||
| -rw-r--r-- | sys/dev/ath/if_athvar.h | 5 |
2 files changed, 18 insertions, 0 deletions
diff --git a/sys/dev/ath/if_ath.c b/sys/dev/ath/if_ath.c index 9a06218ce0e3..ab7cec3e4324 100644 --- a/sys/dev/ath/if_ath.c +++ b/sys/dev/ath/if_ath.c @@ -1062,6 +1062,7 @@ ath_attach(u_int16_t devid, struct ath_softc *sc) if (ath_hal_getcapability(ah, HAL_CAP_HT, 0, NULL) == HAL_OK && (wmodes & (HAL_MODE_HT20 | HAL_MODE_HT40))) { uint32_t rxs, txs; + uint32_t ldpc; device_printf(sc->sc_dev, "[HT] enabling HT modes\n"); @@ -1130,6 +1131,18 @@ ath_attach(u_int16_t devid, struct ath_softc *sc) "[HT] RTS aggregates limited to %d KiB\n", sc->sc_rts_aggr_limit / 1024); + /* + * LDPC + */ + if ((ath_hal_getcapability(ah, HAL_CAP_LDPC, 0, &ldpc)) + == HAL_OK && (ldpc == 1)) { + sc->sc_has_ldpc = 1; + device_printf(sc->sc_dev, + "[HT] LDPC transmit/receive enabled\n"); + ic->ic_htcaps |= IEEE80211_HTCAP_LDPC; + } + + device_printf(sc->sc_dev, "[HT] %d RX streams; %d TX streams\n", rxs, txs); } diff --git a/sys/dev/ath/if_athvar.h b/sys/dev/ath/if_athvar.h index 30763a28d3ef..b0ab2d1dc0fd 100644 --- a/sys/dev/ath/if_athvar.h +++ b/sys/dev/ath/if_athvar.h @@ -653,6 +653,7 @@ struct ath_softc { sc_use_ent : 1, sc_rx_stbc : 1, sc_tx_stbc : 1, + sc_has_ldpc : 1, sc_hasenforcetxop : 1, /* support enforce TxOP */ sc_hasdivcomb : 1, /* RX diversity combining */ sc_rx_lnamixer : 1; /* RX using LNA mixing */ @@ -1307,6 +1308,10 @@ void ath_intr(void *); #define ath_hal_hasdivantcomb(_ah) \ (ath_hal_getcapability(_ah, HAL_CAP_ANT_DIV_COMB, 0, NULL) == HAL_OK) +#define ath_hal_hasldpc(_ah) \ + (ath_hal_getcapability(_ah, HAL_CAP_LDPC, 0, NULL) == HAL_OK) +#define ath_hal_hasldpcwar(_ah) \ + (ath_hal_getcapability(_ah, HAL_CAP_LDPCWAR, 0, NULL) == HAL_OK) /* EDMA definitions */ #define ath_hal_hasedma(_ah) \ |
