Message ID | 1461076135-31540-1-git-send-email-stefan@osg.samsung.com (mailing list archive) |
---|---|
State | Accepted |
Headers | show |
Hi, On 04/19/2016 04:28 PM, Stefan Schmidt wrote: > Catching up with the stack here and implement CSMA parameter setting. > > Signed-off-by: Stefan Schmidt <stefan@osg.samsung.com> all patches are fine. I want to remember this settings have no effects until atusb has TX_ARET support and drops basic operation mode. But I am sure you already known that and this will part of next firmware version. Also please care of ed-levels if they are the same on at86rf230, don't known yet. There is some calculation with rssi_base_val parameter which is on 2.4 Ghz always -91. - Alex -- To unsubscribe from this list: send the line "unsubscribe linux-wpan" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi Alex, >> Catching up with the stack here and implement CSMA parameter setting. >> >> Signed-off-by: Stefan Schmidt <stefan@osg.samsung.com> > > all patches are fine. I want to remember this settings have no effects > until atusb has TX_ARET support and drops basic operation mode. I have applied all 4 patches to bluetooth-next tree. Regards Marcel -- To unsubscribe from this list: send the line "unsubscribe linux-wpan" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hello. On 20/04/16 20:55, Alexander Aring wrote: > Hi, > > On 04/19/2016 04:28 PM, Stefan Schmidt wrote: >> Catching up with the stack here and implement CSMA parameter setting. >> >> Signed-off-by: Stefan Schmidt <stefan@osg.samsung.com> > all patches are fine. I want to remember this settings have no effects > until atusb has TX_ARET support and drops basic operation mode. > > But I am sure you already known that and this will part of next firmware > version. Yes, thats what I'm working on right now. > Also please care of ed-levels if they are the same on at86rf230, don't > known yet. There is some calculation with rssi_base_val parameter which > is on 2.4 Ghz always -91. I will have a look at the 230 ed level table and see if anything special is needed for it when running atusb with the rzusb dongle. regards Stefan Schmidt -- To unsubscribe from this list: send the line "unsubscribe linux-wpan" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hello. On 21/04/16 12:00, Stefan Schmidt wrote: > Hello. > > On 20/04/16 20:55, Alexander Aring wrote: >> Hi, >> >> On 04/19/2016 04:28 PM, Stefan Schmidt wrote: >>> Catching up with the stack here and implement CSMA parameter setting. >>> >>> Signed-off-by: Stefan Schmidt <stefan@osg.samsung.com> >> all patches are fine. I want to remember this settings have no effects >> until atusb has TX_ARET support and drops basic operation mode. >> >> But I am sure you already known that and this will part of next firmware >> version. > > Yes, thats what I'm working on right now. > >> Also please care of ed-levels if they are the same on at86rf230, don't >> known yet. There is some calculation with rssi_base_val parameter which >> is on 2.4 Ghz always -91. > > I will have a look at the 230 ed level table and see if anything > special is needed for it when running atusb with the rzusb dongle. I looked it up in the datasheets (231 on page 91ff and for 230 page 50ff). Both have 85 ED levels in 1dB steps and the range is 0 - 84 on both as well. Nothing I can see where 230 and 231 have any difference how we would need to handle them. regards Stefan Schmidt -- To unsubscribe from this list: send the line "unsubscribe linux-wpan" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/net/ieee802154/atusb.c b/drivers/net/ieee802154/atusb.c index b1cd865..2d8de9f 100644 --- a/drivers/net/ieee802154/atusb.c +++ b/drivers/net/ieee802154/atusb.c @@ -473,6 +473,23 @@ atusb_set_txpower(struct ieee802154_hw *hw, s32 mbm) } static int +atusb_set_csma_params(struct ieee802154_hw *hw, u8 min_be, u8 max_be, u8 retries) +{ + struct atusb *atusb = hw->priv; + int ret; + + ret = atusb_write_subreg(atusb, SR_MIN_BE, min_be); + if (ret) + return ret; + + ret = atusb_write_subreg(atusb, SR_MAX_BE, max_be); + if (ret) + return ret; + + return atusb_write_subreg(atusb, SR_MAX_CSMA_RETRIES, retries); +} + +static int atusb_set_promiscuous_mode(struct ieee802154_hw *hw, const bool on) { struct atusb *atusb = hw->priv; @@ -508,6 +525,7 @@ static struct ieee802154_ops atusb_ops = { .stop = atusb_stop, .set_hw_addr_filt = atusb_set_hw_addr_filt, .set_txpower = atusb_set_txpower, + .set_csma_params = atusb_set_csma_params, .set_promiscuous_mode = atusb_set_promiscuous_mode, }; @@ -636,7 +654,7 @@ static int atusb_probe(struct usb_interface *interface, hw->parent = &usb_dev->dev; hw->flags = IEEE802154_HW_TX_OMIT_CKSUM | IEEE802154_HW_AFILT | - IEEE802154_HW_PROMISCUOUS; + IEEE802154_HW_PROMISCUOUS | IEEE802154_HW_CSMA_PARAMS; hw->phy->flags = WPAN_PHY_FLAG_TXPOWER;
Catching up with the stack here and implement CSMA parameter setting. Signed-off-by: Stefan Schmidt <stefan@osg.samsung.com> --- drivers/net/ieee802154/atusb.c | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-)