All of lore.kernel.org
 help / color / mirror / Atom feed
* [B.A.T.M.A.N.] [PATCH] openwrt-feed-batman-adv: Allow to select routing algorithm
@ 2016-01-19 11:47 Sven Eckelmann
  2016-01-30  7:11 ` Marek Lindner
  0 siblings, 1 reply; 2+ messages in thread
From: Sven Eckelmann @ 2016-01-19 11:47 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Sven Eckelmann

The network config section for proto batadv now allows to select the
routing algorithm via the option routing_algo. This allows to chose between
BATMAN_IV and BATMAN_V when BATMAN_V is released. This option is only
useful when a new batman-adv device is created and not when only a device
is added to an already existing batman-adv device.

Signed-off-by: Sven Eckelmann <sven@open-mesh.com>
---
 batman-adv-devel/files/lib/netifd/proto/batadv.sh | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/batman-adv-devel/files/lib/netifd/proto/batadv.sh b/batman-adv-devel/files/lib/netifd/proto/batadv.sh
index 632a209..1e0c9d0 100644
--- a/batman-adv-devel/files/lib/netifd/proto/batadv.sh
+++ b/batman-adv-devel/files/lib/netifd/proto/batadv.sh
@@ -6,14 +6,18 @@ init_proto "$@"
 
 proto_batadv_init_config() {
 	proto_config_add_string "mesh"
+	proto_config_add_string "routing_algo"
 }
 
 proto_batadv_setup() {
 	local config="$1"
 	local iface="$2"
 
-	local mesh
-	json_get_vars mesh
+	local mesh routing_algo
+	json_get_vars mesh routing_algo
+
+	[ -n "$routing_algo" ] || routing_algo="BATMAN_IV"
+	echo "$routing_algo" > "/sys/module/batman_adv/parameters/routing_algo"
 
 	echo "$mesh" > "/sys/class/net/$iface/batman_adv/mesh_iface"
 	proto_init_update "$iface" 1
-- 
2.7.0.rc3


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCH] openwrt-feed-batman-adv: Allow to select routing algorithm
  2016-01-19 11:47 [B.A.T.M.A.N.] [PATCH] openwrt-feed-batman-adv: Allow to select routing algorithm Sven Eckelmann
@ 2016-01-30  7:11 ` Marek Lindner
  0 siblings, 0 replies; 2+ messages in thread
From: Marek Lindner @ 2016-01-30  7:11 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Sven Eckelmann

[-- Attachment #1: Type: text/plain, Size: 634 bytes --]

On Tuesday, January 19, 2016 12:47:07 Sven Eckelmann wrote:
> The network config section for proto batadv now allows to select the
> routing algorithm via the option routing_algo. This allows to chose between
> BATMAN_IV and BATMAN_V when BATMAN_V is released. This option is only
> useful when a new batman-adv device is created and not when only a device
> is added to an already existing batman-adv device.
> 
> Signed-off-by: Sven Eckelmann <sven@open-mesh.com>
> ---
>  batman-adv-devel/files/lib/netifd/proto/batadv.sh | 8 ++++++--
>  1 file changed, 6 insertions(+), 2 deletions(-)

Applied in revision 3dafbb1.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-01-30  7:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-01-19 11:47 [B.A.T.M.A.N.] [PATCH] openwrt-feed-batman-adv: Allow to select routing algorithm Sven Eckelmann
2016-01-30  7:11 ` Marek Lindner

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.