diff options
author | Alexander Aring <alex.aring@gmail.com> | 2015-05-17 21:44:48 +0200 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2015-05-19 11:44:42 +0200 |
commit | 8377d22c0385b4a08ddeb1029b80674eb5db38b4 (patch) | |
tree | c82fd6d6596e3ea18966bbe1068bf50a28d560b3 /drivers/net/ieee802154/at86rf230.c | |
parent | 65318680c97cca15e3678148b3a5acaa33e991ec (diff) |
at86rf230: set cca_modes supported flags
This patch sets the at86rf230 supported cca modes. In case of at86rf212
it also can support listen before transmit.
Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'drivers/net/ieee802154/at86rf230.c')
-rw-r--r-- | drivers/net/ieee802154/at86rf230.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/ieee802154/at86rf230.c b/drivers/net/ieee802154/at86rf230.c index b0ffd1cd0010..fabde3ac49b3 100644 --- a/drivers/net/ieee802154/at86rf230.c +++ b/drivers/net/ieee802154/at86rf230.c @@ -1574,6 +1574,11 @@ at86rf230_detect_device(struct at86rf230_local *lp) WPAN_PHY_FLAG_CCA_ED_LEVEL | WPAN_PHY_FLAG_CCA_MODE; + lp->hw->phy->supported.cca_modes = BIT(NL802154_CCA_ENERGY) | + BIT(NL802154_CCA_CARRIER) | BIT(NL802154_CCA_ENERGY_CARRIER); + lp->hw->phy->supported.cca_opts = BIT(NL802154_CCA_OPT_ENERGY_CARRIER_AND) | + BIT(NL802154_CCA_OPT_ENERGY_CARRIER_OR); + lp->hw->phy->cca.mode = NL802154_CCA_ENERGY; switch (part) { @@ -1596,6 +1601,7 @@ at86rf230_detect_device(struct at86rf230_local *lp) lp->hw->phy->supported.channels[2] = 0x00007FF; lp->hw->phy->current_channel = 5; lp->hw->phy->symbol_duration = 25; + lp->hw->phy->supported.lbt = NL802154_SUPPORTED_BOOL_BOTH; break; case 11: chip = "at86rf233"; |