Date: Wed, 11 Jan 2012 05:40:58 +0100 From: Monthadar Al Jaberi <monthadar@gmail.com> To: freebsd-wireless@freebsd.org Subject: 11s mesh path setup problem Message-ID: <CA%2BsBSoJWXD5S-zvxHR_=iwh26G0bd00trR=E-jCUBD03uMrU%2BQ@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
--14dae9340cc7f5f09404b6393c41 Content-Type: text/plain; charset=ISO-8859-1 Hi, Current hwmp cant handle to setup a path between 4 nodes in a line topology (among other things it cant handle) Below you will find a small patch to correct this with some debug output cleanup and comments. After the patch, you should be able to e.g. ping from node 4 to node 1 and get a ping reply back, he is what the output from ifconfig list mesh should look like on all 4 nodes after one ping packet. Node1# ifconfig wlan1 list mesh DEST NEXT HOP HOPS METRIC LIFETIME MSEQ FLAGS Node2 Node2 1 17018 5000 0 V Node3 Node2 2 34036 5000 0 V Node4 Node2 3 34036 5000 3 V Node2# ifconfig wlan1 list mesh DEST NEXT HOP HOPS METRIC LIFETIME MSEQ FLAGS Node1 Node1 1 17018 5000 3 V Node3 Node3 1 17018 5000 0 V Node4 Node3 2 17018 5000 3 V Node3# ifconfig wlan1 list mesh DEST NEXT HOP HOPS METRIC LIFETIME MSEQ FLAGS Node2 Node2 1 0 5000 0 V Node4 Node4 1 0 5000 3 V Node1 Node2 2 34036 5000 3 V Node4# ifconfig wlan1 list mesh DEST NEXT HOP HOPS METRIC LIFETIME MSEQ FLAGS Node3 Node3 1 0 5000 0 V Node1 Node3 3 51054 5000 3 V If anyone could try it that would be nice, either on real hardware as I did above, or in a simulated environment (https://github.com/monthadar/FreeBSD-IEEE80211s-simulator/wiki) :) and please do test other scenarios :) patch is attached. -- Monthadar Al Jaberi --14dae9340cc7f5f09404b6393c41 Content-Type: text/x-patch; charset=US-ASCII; name="patch_11s_4_nodes_in_line.patch" Content-Disposition: attachment; filename="patch_11s_4_nodes_in_line.patch" Content-Transfer-Encoding: base64 X-Attachment-Id: f_gx9v1nv70 ZGlmZiAtLWdpdCBhL3N5cy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FODAyMTFfTUVTSFBSRVFfVEZM QUdTX1JGOwogCQkJUFJFUV9URkxBR1MoMCkgfD0gSUVFRTgwMjExX01FU0hQUkVRX1RGTEFHU19V U047Ci0JCQlQUkVRX1RTRVEoMCkgPSAwOworCQkJUFJFUV9UU0VRKDApID0gaHItPmhyX3NlcTsK IAkJCS8qIFhYWCBjaGVjayByZXR1cm4gdmFsdWUgKi8KIAkJCWh3bXBfc2VuZF9wcmVxKHZhcC0+ aXZfYnNzLCB2YXAtPml2X215YWRkciwKIAkJCSAgICBicm9hZGNhc3RhZGRyLCAmcHJlcSk7Cg== --14dae9340cc7f5f09404b6393c41--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CA%2BsBSoJWXD5S-zvxHR_=iwh26G0bd00trR=E-jCUBD03uMrU%2BQ>