29 Nov, 2011
1 commit
-
We used to initiate a path discovery when receiving a frame for which
there is no forwarding information. To cut down on PREQ spam, just send
a (gated) PERR in response.Also separate path discovery logic from nexthop querying. This patch
means we no longer queue frames when forwarding, so kill the PERR TX
stuff in discard_frame().Signed-off-by: Thomas Pedersen
Signed-off-by: John W. Linville
10 Nov, 2011
1 commit
-
Don't accept redundant PREQs for a given destination. This fixes a
problem under high load:kernel: [20386.250913] mesh_queue_preq: 235 callbacks suppressed
kernel: [20386.253335] Mesh HWMP (mesh0): PREQ node queue full
kernel: [20386.253352] Mesh HWMP (mesh0): PREQ node queue full
(...)The 802.11s protocol has a provision to limit the rate of path requests
(PREQs) are transmitted (dot11MeshHWMPpreqMinInterval) but there was no
limit on the rate at which PREQs were being queued up. There is a valid
reason for queuing PREQs: this way we can even out PREQ bursts. But
queueing multiple PREQs for the same destination is useless.Reported-by: Pedro Larbig
Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville
09 Nov, 2011
1 commit
-
Signed-off-by: Thomas Pedersen
Signed-off-by: Ashok Nagarajan
Signed-off-by: John W. Linville
01 Oct, 2011
1 commit
-
Relocate the mesh implementation of adding the (extended) supported
rates IE to util.c, anticipating its use by other parts of mac80211.Signed-off-by: Arik Nemtsov
Cc: Kalyan C Gaddam
Signed-off-by: John W. Linville
14 Sep, 2011
2 commits
-
No need to take the mpath state lock when an mpath is removed.
Also, no need checking the lock when reading mpath flags.Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville -
When an interface is removed, the mesh paths associated with it should
also be removed.This fixes a bug we observed when reloading a device driver module
without reloading mac80211s.Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville
25 Aug, 2011
2 commits
-
Allow userspace to set Root Announcement Interval for our mesh
interface. Also, RANN interval is now in proper units of TUs.Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville -
In this implementation, a mesh gate is a root node with a certain bit
set in its RANN flags. The mpath to this root node is marked as a path
to a gate, and added to our list of known gates for this if_mesh. Once a
path discovery process fails, we forward the unresolved frames to a
known gate. Thanks to Luis Rodriguez for refactoring and bug fix help.Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville
23 Aug, 2011
2 commits
-
Make mesh path selection frames Mesh Action category, remove outdated
Mesh Path Selection category and defines, use updated reason codes, add
mesh_action_is_path_sel for readability, and update/correct path
selection IEs.Signed-off-by: Thomas Pedersen
Signed-off-by: John W. Linville -
Correct ordering of IEs in the mesh beacon while removing unneeded IEs
from mesh peering frames. Set privacy bit in capability info if security
is enabled. Add utility functions to aid in construction
of IEs and reduce code duplication.Signed-off-by: Thomas Pedersen
Signed-off-by: John W. Linville
17 May, 2011
3 commits
-
This adds proper RCU annotations to the mesh path
table code, and fixes a number of bugs in the code
that I found while checking the sparse warnings I
got as a result of the annotations.Some things like the changes in mesh_path_add() or
mesh_pathtbl_init() only serve to shut up sparse,
but other changes like the changes surrounding the
for_each_mesh_entry() macro fix real RCU bugs in
the code.Signed-off-by: Johannes Berg
Signed-off-by: John W. Linville -
The locking in mesh_{mpath,mpp}_table_grow not only
has an rcu_read_unlock() missing, it's also racy
(though really only technically since it's invoked
from a single function only) since it obtains the
new size of the table without any locking, so two
invocations of the function could attempt the same
resize.Additionally, it uses synchronize_rcu() which is
rather expensive and can be avoided trivially here.Modify the functions to only use the table lock
and use call_rcu() instead of synchronize_rcu().Signed-off-by: Johannes Berg
Signed-off-by: John W. Linville -
This adds sparse RCU annotations to most of
mac80211, only the mesh code remains to be
done.Due the the previous patches, the annotations
are pretty simple. The only thing that this
actually changes is removing the RCU usage of
key->sta in debugfs since this pointer isn't
actually an RCU-managed pointer (it only has
a single assignment done before the key even
goes live). As that is otherwise harmless, I
decided to make it part of this patch.Signed-off-by: Johannes Berg
Signed-off-by: John W. Linville
13 May, 2011
1 commit
-
There's no need to have table functions in one
file and all users in another, move the functions
to the right file and make them static. Also move
a static variable to the beginning of the file to
make it easier to find.Signed-off-by: Johannes Berg
Signed-off-by: John W. Linville
13 Apr, 2011
1 commit
-
Also, advertise support for mesh authentication.
Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville
21 Dec, 2010
2 commits
-
The Mesh Control header only includes 0, 1 or 2 addresses. If there is
one address, it should be interpreted as Address 4. If there are 2,
they are interpreted as Addresses 5 and 6 (Address 4 being the 4th
address in the 802.11 header).The address extension used to hold up to 3 addresses instead of the current 2.
I'm not sure which draft version changed this, but it is very unlikely that it
will change again given the state of the approval process of this draft. See
section 7.1.3.6.3 in current draft (8.0).Also, note that the extra address that I'm removing was not being used, so this
change has no effect on over-the-air frame formats. But I thought I better
remove it before someone does start using it.Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville -
Let path selection frames for protocols other than HWMP be sent to
userspace via NL80211_CMD_REGISTER_FRAME. Also allow userspace to send
and receive mesh path selection frames.Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville
16 Dec, 2010
1 commit
-
Commit 00d3f14c has removed the references of this macro,
but left it only. So remove this definition.commit 00d3f14cf9f12c21428121026a5e1d5f65926447
Author: Johannes Berg
Date: Tue Feb 10 21:26:00 2009 +0100mac80211: use cfg80211s BSS infrastructure
Remove all the code from mac80211 to keep track of BSSes
and use the cfg80211-provided code completely.Signed-off-by: Shan Wei
Signed-off-by: John W. Linville
07 Dec, 2010
2 commits
-
Instead of tying mesh activity to interface up,
add join and leave commands for mesh. Since we
must be backward compatible, let cfg80211 handle
joining a mesh if a mesh ID was pre-configured
when the device goes up.Note that this therefore must modify mac80211 as
well since mac80211 needs to lose the logic to
start the mesh on interface up.We now allow querying mesh parameters before the
mesh is connected, which simply returns defaults.
Setting them (internally renamed to "update") is
only allowed while connected. Specify them with
the new mesh join command instead where needed.In mac80211, beaconing must now also follow the
mesh enabled/not enabled state, which is done
by testing the mesh ID.Signed-off-by: Javier Cardona
Signed-off-by: Johannes Berg
Signed-off-by: John W. Linville -
The TTL in path selection information elements is different from
the mesh ttl used in mesh data frames. Version 7.03 of the 11s
draft calls this ttl 'Element TTL'.Signed-off-by: Johannes Berg
Signed-off-by: John W. Linville
09 Aug, 2010
1 commit
-
To avoid more patches, I also fixed other spelling
and grammar bugs when they were in the same or
following line:successfull -> successful
parse -> parses
controler -> controller
controlers -> controllersCc: Jiri Kosina
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Stefan Weil
Signed-off-by: Jiri Kosina
15 Jun, 2010
1 commit
-
Some code is duplicated between ibss, mesh and
managed mode regarding the queueing of management
frames. Since all modes now use a common skb
queue and a common work function, we can pull
the queueing code into the rx handler directly
and remove the duplicated length checks etc.Signed-off-by: Johannes Berg
Signed-off-by: John W. Linville
09 Apr, 2010
1 commit
-
Grouped mesh action codes together with the other action codes in
ieee80211.h.Signed-off-by: Javier Cardona
Reviewed-by: Johannes Berg
Signed-off-by: John W. Linville
11 Dec, 2009
1 commit
-
The patch ("mac80211: Use correct sign for mesh active path
refresh.") was actually a bug. Reverted it and improved the
explanation of how mesh path refresh works.Signed-off-by: Javier Cardona
Signed-off-by: Andrey Yurovsky
Cc: stable@kernel.org
Signed-off-by: John W. Linville
19 Nov, 2009
1 commit
-
The netdev broadcast address cannot change from
all-ones so there's no need to use it; we can
instead hard-code it. Since we already have an
instance in tkip.c, which will be shared if it
is marked static const, doing this reduces text
size at no data/bss cost.The real motivation for this is, of course, the
desire to get rid of almost all uses of netdevs
in mac80211 so that auditing their use becomes
easier.Signed-off-by: Johannes Berg
Signed-off-by: John W. Linville
14 Nov, 2009
5 commits
-
Signed-off-by: Rui Paulo
Signed-off-by: Javier Cardona
Reviewed-by: Andrey Yurovsky
Tested-by: Brian Cavagnolo
Signed-off-by: John W. Linville -
Signed-off-by: Rui Paulo
Signed-off-by: Javier Cardona
Reviewed-by: Andrey Yurovsky
Tested-by: Brian Cavagnolo
Signed-off-by: John W. Linville -
RANN (Root Annoucement) frame TX. Send an action frame every second
trying to build a path to all nodes on the mesh.Signed-off-by: Rui Paulo
Signed-off-by: Javier Cardona
Reviewed-by: Andrey Yurovsky
Tested-by: Brian Cavagnolo
Signed-off-by: John W. Linville -
Resulting object files have the same MD5 as before.
Signed-off-by: Rui Paulo
Signed-off-by: Javier Cardona
Reviewed-by: Andrey Yurovsky
Tested-by: Brian Cavagnolo
Signed-off-by: John W. Linville -
Update the PERR IE frame format according to latest draft (3.03).
Signed-off-by: Rui Paulo
Signed-off-by: Javier Cardona
Reviewed-by: Andrey Yurovsky
Tested-by: Brian Cavagnolo
Signed-off-by: John W. Linville
12 Nov, 2009
3 commits
-
Update the format of path selection frames according to latest
draft (3.03).Signed-off-by: Rui Paulo
Signed-off-by: Javier Cardona
Reviewed-by: Andrey Yurovsky
Tested-by: Brian Cavagnolo
Signed-off-by: John W. Linville -
Update the length and format of the peer link management action frames.
Signed-off-by: Rui Paulo
Signed-off-by: Javier Cardona
Reviewed-by: Andrey Yurovsky
Tested-by: Brian Cavagnolo
Signed-off-by: John W. Linville -
Update the mesh time to live field to 31 according to draft 3.03.
Signed-off-by: Rui Paulo
Signed-off-by: Javier Cardona
Reviewed-by: Andrey Yurovsky
Tested-by: Brian Cavagnolo
Signed-off-by: John W. Linville
20 Aug, 2009
1 commit
-
Mesh uses the tx failure average to compute the (m)path metric. This used to
be done inside the rate control module. This patch breaks the dependency
between the mesh stack and the rate control algorithm. Mesh will now work
independently of the chosen rate control algorithm.The mesh stack keeps a moving average of the average transmission losses for
each mesh peer station. If the fail average exceeds a certain threshold, the
peer link is marked as broken.Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville
14 Aug, 2009
5 commits
-
This prevents calling rcu_synchronize from within the tx path by moving the
table growth code to the mesh workqueue.Move mesh_table_free and mesh_table_grow from mesh.c to mesh_pathtbl.c and
declare them static.Also, re-enable mesh in Kconfig and update the configuration description.
Signed-off-by: Javier Cardona
Tested-by: Andrey Yurovsky
Signed-off-by: John W. Linville -
The mesh stack was enabling beaconing without specifying an interval. This
patch defines a default beaconing interval of 1s.Incidentally, this fixes mesh beaconing in mac80211_hwsim devices.
Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville -
The 11s task group recently changed the frame mesh multicast/broadcast frame
format to use 3-address. This was done to avoid interactions with widely
deployed lazy-WDS access points.This patch changes the format of group addressed frames, both mesh-originated
and proxied, to use the data format defined in draft D2.08 and forward. The
address fields used for group addressed frames is:In 802.11 header
ToDS:0 FromDS:1
addr1: DA (broadcast/multicast address)
addr2: TA
addr3: Mesh SAIn address extension header:
addr4: SA (only present if frame was proxied)Note that this change breaks backward compatibility with earlier mesh stack
versions.Signed-off-by: Andrey Yurovsky
Signed-off-by: Javier Cardona
Signed-off-by: John W. Linville -
Also, fix typo in comment.
Signed-off-by: Javier Cardona
Tested-by: Andrey Yurovsky
Signed-off-by: John W. Linville -
In order for userspace to be able to figure out whether
it obtained a consistent snapshot of data or not when
using netlink dumps, we need to have a generation number
in each dump message that indicates whether the list has
changed or not -- its value is arbitrary.This patch adds such a number to all dumps, this needs
some mac80211 involvement to keep track of a generation
number to start with when adding/removing mesh paths or
stations.The wiphy and netdev lists can be fully handled within
cfg80211, of course, but generation numbers need to be
stored there as well.Signed-off-by: Johannes Berg
Signed-off-by: John W. Linville
11 Jul, 2009
1 commit
-
Within mac80211, we often need to copy the rx status into
skb->cb. This is wasteful, as drivers could be building it
in there to start with. This patch changes the API so that
drivers are expected to pass the RX status in skb->cb, now
accessible as IEEE80211_SKB_RXCB(skb). It also updates all
drivers to pass the rx status in there, but only by making
them memcpy() it into place before the call to the receive
function (ieee80211_rx(_irqsafe)). Each driver can now be
optimised on its own schedule.Signed-off-by: Johannes Berg
Signed-off-by: John W. Linville