From patchwork Mon Feb 1 10:09:28 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Dedecker X-Patchwork-Id: 576441 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from arrakis.dune.hu (arrakis.dune.hu [78.24.191.176]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 428AB140321 for ; Mon, 1 Feb 2016 21:10:15 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b=OW9w0mQx; dkim-atps=neutral Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 469D228A6AF; Mon, 1 Feb 2016 11:10:08 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on arrakis.dune.hu X-Spam-Level: X-Spam-Status: No, score=-1.5 required=5.0 tests=BAYES_00,FREEMAIL_FROM, T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 162D328124A for ; Mon, 1 Feb 2016 11:09:59 +0100 (CET) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 CL_IP_EQ_HELO_IP=-2 (check from: .gmail. - helo: .mail-wm0-f49.google. - helo-domain: .google.) FROM/MX_MATCHES_HELO(DOMAIN)=-2; rate: -8.5 Received: from mail-wm0-f49.google.com (mail-wm0-f49.google.com [74.125.82.49]) by arrakis.dune.hu (Postfix) with ESMTPS for ; Mon, 1 Feb 2016 11:09:58 +0100 (CET) Received: by mail-wm0-f49.google.com with SMTP id r129so62189350wmr.0 for ; Mon, 01 Feb 2016 02:09:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=MDh9xwZvClVHPJtmWqo+p3so5mL2jwYU0uEiedua23g=; b=OW9w0mQxJEEHCXuSuchF6yfkOliRkP4/SxlIpM5rKRyr3oBry/pIJgKtwgtF/uQxu6 vtGNDK6rpSMBZfTnJIBe3u130t8HmOeUrQoAtuPzcOAib6pisd5g9WL6NNWoUOWbwnYm TuJJkBQtZhwsZvZ8JbgiboTg3DkmPu1kfbuWqf1+c0VlpcklwSBPXjCFnEZPHXeyiejk A4Jky4322cf+UELcsIkEj5eXyGu7TAybQ0gB9w/IZO7eNysnAImMUXWF9WhJHDPyVOhQ 65TC6MoX1YskKBsNh1Jfb9MbaHKckDfVo+rLGE+MjejkP6at8qqto7Yh0XgdGgoJzuA5 /luw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=MDh9xwZvClVHPJtmWqo+p3so5mL2jwYU0uEiedua23g=; b=kXxTWTUpvJqEujimz9EqMQrOApak94RpsLOvgtbvHQVJrYjkovJwQ2WCzvVY4WnJ0h iup98+TgZBqdipN+t5Vj+lHPy8tBAadjlwJC942zEO1Ld3kHP1SjU43hxP4OWpN6kqTv OZcAceudLeviu5Q2tuU9qUPcCTjxnXYowahE5/f7CcUVlbaKVrpPBrr7rFAh3G4f7jEr O8NOXehZBMgPf/toEYhmLbdbBkbrf+OPuHeyriU7PVTCuZiKzyfMlsu2+4P1nG2pffGL x3PmOyndt9giLjyRFDznENqWzUnj1W/5m5hgn1xSLBdEPronzJyh4cHiWc0oI8Jw0XtT nUHw== X-Gm-Message-State: AG10YOTLjepSoff3rMF+iccZ+PS6Mc7BCnjbQ/xOHQjeD5/bP00I+S0d0S9Grx6oJdzxUQ== X-Received: by 10.28.158.198 with SMTP id h189mr10558371wme.74.1454321397764; Mon, 01 Feb 2016 02:09:57 -0800 (PST) Received: from cplx43.eu.thmulti.com ([141.11.62.7]) by smtp.gmail.com with ESMTPSA id e77sm10632207wma.18.2016.02.01.02.09.56 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 01 Feb 2016 02:09:56 -0800 (PST) From: Hans Dedecker To: openwrt-devel@lists.openwrt.org Date: Mon, 1 Feb 2016 11:09:28 +0100 Message-Id: <1454321368-26081-1-git-send-email-dedeckeh@gmail.com> X-Mailer: git-send-email 1.9.1 Cc: Hans Dedecker , cyrus@openwrt.org, Nick Podolak Subject: [OpenWrt-Devel] [PATCH] gre: Support multicast configurable gre interfaces X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: openwrt-devel-bounces@lists.openwrt.org Sender: "openwrt-devel" UCI paramater multicast is added which allows to toggle multicast support on gre interfaces. By default multicast support is enabled as gre tunnels are often used in combination with routing protocols using multicast. Signed-off-by: Hans Dedecker Signed-off-by: Nick Podolak --- Based on a patch by Nick Podolak (https://lists.openwrt.org/pipermail/openwrt-devel/2015-October/036655.html) with a minor adapatation package/network/config/gre/files/gre.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/package/network/config/gre/files/gre.sh b/package/network/config/gre/files/gre.sh index 4483a08..cab52d3 100755 --- a/package/network/config/gre/files/gre.sh +++ b/package/network/config/gre/files/gre.sh @@ -13,10 +13,11 @@ gre_generic_setup() { local local="$3" local remote="$4" local link="$5" - local mtu ttl tos zone ikey okey icsum ocsum iseqno oseqno - json_get_vars mtu ttl tos zone ikey okey icsum ocsum iseqno oseqno + local mtu ttl tos zone ikey okey icsum ocsum iseqno oseqno multicast + json_get_vars mtu ttl tos zone ikey okey icsum ocsum iseqno oseqno multicast [ -z "$zone" ] && zone="wan" + [ -z "$multicast" ] && multicast=1 proto_init_update "$link" 1 @@ -26,6 +27,7 @@ gre_generic_setup() { [ -n "$df" ] && json_add_boolean df "$df" json_add_int ttl "${ttl:-64}" [ -n "$tos" ] && json_add_string tos "$tos" + json_add_boolean multicast "$multicast" json_add_string local "$local" json_add_string remote "$remote" [ -n "$tunlink" ] && json_add_string link "$tunlink" @@ -203,6 +205,7 @@ gre_generic_init_config() { proto_config_add_boolean "ocsum" proto_config_add_boolean "iseqno" proto_config_add_boolean "oseqno" + proto_config_add_boolean "multicast" } proto_gre_init_config() {