[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1290169011.2109.1571.camel@laptop>
Date: Fri, 19 Nov 2010 13:16:51 +0100
From: Peter Zijlstra <peterz@...radead.org>
To: Bruno Randolf <br1@...fach.org>
Cc: Bob Copeland <me@...copeland.com>,
Johannes Berg <johannes@...solutions.net>,
Jouni Malinen <j@...fi>, linville@...driver.com,
randy.dunlap@...cle.com, blp@...stanford.edu,
linux-wireless@...r.kernel.org, linux-kernel@...r.kernel.org,
Lars_Ericsson@...ia.com, stefanr@...6.in-berlin.de,
kosaki.motohiro@...fujitsu.com, akpm@...ux-foundation.org,
kevin.granade@...il.com
Subject: Re: [PATCH v7 3/3] nl80211/mac80211: Report signal average
On Fri, 2010-11-19 at 18:07 +0900, Bruno Randolf wrote:
> Hmm, maybe I suck in mathemathics, but I don't see a way to do that given the
> formula:
>
> (((internal * (weight - 1)) + (val * factor)) / weight
If you assume weight == 2^n, you can write that as:
(((internal << n) - internal) + (val * factor)) >> n
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists