All of lore.kernel.org
 help / color / mirror / Atom feed
From: Felix Fietkau <nbd@openwrt.org>
To: ath9k-devel@lists.ath9k.org
Subject: [ath9k-devel] [PATCH] ath9k: Futher fix for mesh beaconing.
Date: Mon, 23 May 2011 23:53:19 +0200	[thread overview]
Message-ID: <4DDAD74F.1040400@openwrt.org> (raw)
In-Reply-To: <1306171357-24988-1-git-send-email-fabricedeyber@agilemesh.com>

On 2011-05-23 7:22 PM, Fabrice Deyber wrote:
>   This fix ensure the timers to be set at beacon interval boundaries. Without this change timers can
>   be set improperly resulting in absence of beacons.
>
>
> Signed-off-by: Fabrice Deyber<fabricedeyber@agilemesh.com>
> ---
>   drivers/net/wireless/ath/ath9k/beacon.c |    2 ++
>   1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath9k/beacon.c b/drivers/net/wireless/ath/ath9k/beacon.c
> index d4d8cec..ffb3d81 100644
> --- a/drivers/net/wireless/ath/ath9k/beacon.c
> +++ b/drivers/net/wireless/ath/ath9k/beacon.c
> @@ -669,6 +669,8 @@ static void ath_beacon_config_adhoc(struct ath_softc *sc,
>   		nexttbtt = tsf + intval - (delta % intval);
>   	}
>
> +	nexttbtt = roundup(nexttbtt, intval);
> +
If you're placing the nexttbtt boundary that way, you can easily also 
simplify the previous code to not calculate the delta between the last 
timestamp and the current one, but instead just round up
tsf + TU_TO_USEC(FUDGE) to intval, making the code easier to read.

- Felix

  reply	other threads:[~2011-05-23 21:53 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-23 17:22 [ath9k-devel] [PATCH] ath9k: Futher fix for mesh beaconing Fabrice Deyber
2011-05-23 21:53 ` Felix Fietkau [this message]
2011-05-23 23:26   ` Fabrice Deyber
2011-05-24  0:07     ` Felix Fietkau

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=4DDAD74F.1040400@openwrt.org \
    --to=nbd@openwrt.org \
    --cc=ath9k-devel@lists.ath9k.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.