Linux IEEE 802.15.4 and 6LoWPAN development
 help / color / mirror / Atom feed
From: Stefan Schmidt <stefan@osg.samsung.com>
To: Alexander Aring <alex.aring@gmail.com>, linux-wpan@vger.kernel.org
Cc: kernel@pengutronix.de
Subject: Re: [RFC bluetooth-next] ieee802154: 6lowpan: set ackreq when needed
Date: Thu, 28 May 2015 10:22:19 +0200	[thread overview]
Message-ID: <5566D03B.7080209@osg.samsung.com> (raw)
In-Reply-To: <1432721532-21239-1-git-send-email-alex.aring@gmail.com>

Hello.

On 27/05/15 12:12, Alexander Aring wrote:
> This patch sets the acknowledge request bit inside the 802.15.4 mac
> header when frame retries is 0 or above. The other frame retries value
> which is -1 indicates that the transmitter doesn't care about an
> acknowledge frame which will be ignored after transmitting if the node
> sends anyway an ack frame after receiving. This is currently unnecessary
> traffic if the max frame retries parameter is -1. I hope transceivers
> which supports AACK handling will check on this bit and doesn't send an
> ack frame after receiving.

Do we know if AACK enbaled receivers really parse this and avoid sending 
the ACK? They should but I wonder if you did run any test for this.

regards
Stefan Schmidt

> Signed-off-by: Alexander Aring <alex.aring@gmail.com>
> ---
>   net/ieee802154/6lowpan/tx.c | 5 +++--
>   1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/net/ieee802154/6lowpan/tx.c b/net/ieee802154/6lowpan/tx.c
> index 98acf73..2597abb 100644
> --- a/net/ieee802154/6lowpan/tx.c
> +++ b/net/ieee802154/6lowpan/tx.c
> @@ -190,6 +190,7 @@ err:
>   
>   static int lowpan_header(struct sk_buff *skb, struct net_device *dev)
>   {
> +	struct wpan_dev *wpan_dev = lowpan_dev_info(dev)->real_dev->ieee802154_ptr;
>   	struct ieee802154_addr sa, da;
>   	struct ieee802154_mac_cb *cb = mac_cb_init(skb);
>   	struct lowpan_addr_info info;
> @@ -207,7 +208,7 @@ static int lowpan_header(struct sk_buff *skb, struct net_device *dev)
>   
>   	/* prepare wpan address data */
>   	sa.mode = IEEE802154_ADDR_LONG;
> -	sa.pan_id = lowpan_dev_info(dev)->real_dev->ieee802154_ptr->pan_id;
> +	sa.pan_id = wpan_dev->pan_id;
>   	sa.extended_addr = ieee802154_devaddr_from_raw(saddr);
>   
>   	/* intra-PAN communications */
> @@ -223,7 +224,7 @@ static int lowpan_header(struct sk_buff *skb, struct net_device *dev)
>   	} else {
>   		da.mode = IEEE802154_ADDR_LONG;
>   		da.extended_addr = ieee802154_devaddr_from_raw(daddr);
> -		cb->ackreq = true;
> +		cb->ackreq = wpan_dev->frame_retries >= 0;
>   	}
>   
>   	return dev_hard_header(skb, lowpan_dev_info(dev)->real_dev,


  reply	other threads:[~2015-05-28  8:22 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-27 10:12 [RFC bluetooth-next] ieee802154: 6lowpan: set ackreq when needed Alexander Aring
2015-05-28  8:22 ` Stefan Schmidt [this message]
2015-05-28 10:02   ` Alexander Aring

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5566D03B.7080209@osg.samsung.com \
    --to=stefan@osg.samsung.com \
    --cc=alex.aring@gmail.com \
    --cc=kernel@pengutronix.de \
    --cc=linux-wpan@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox