mkinitrd unification across distributions
 help / color / mirror / Atom feed
* [PATCH] ifup.sh: Add support for bridge over team and vlan tagged team
@ 2013-04-01 12:34 WANG Chao
       [not found] ` <1364819680-1618-1-git-send-email-chaowang-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
  0 siblings, 1 reply; 5+ messages in thread
From: WANG Chao @ 2013-04-01 12:34 UTC (permalink / raw)
  To: harald-H+wXaHxf7aLQT0dZR+AlfA, amwang-H+wXaHxf7aLQT0dZR+AlfA,
	jpirko-H+wXaHxf7aLQT0dZR+AlfA, dyoung-H+wXaHxf7aLQT0dZR+AlfA,
	bhe-H+wXaHxf7aLQT0dZR+AlfA
  Cc: initramfs-u79uwXL29TY76Z2rM5mHXA

Team is the same network stack as bonding. Therefore give ifup the ability to
handle bridge over team and vlan tagged team as bonding too.

Signed-off-by: WANG Chao <chaowang-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
---
 modules.d/40network/ifup.sh | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/modules.d/40network/ifup.sh b/modules.d/40network/ifup.sh
index 582278f..815ab64 100755
--- a/modules.d/40network/ifup.sh
+++ b/modules.d/40network/ifup.sh
@@ -46,6 +46,8 @@ if [ -e /tmp/bridge.info ]; then
         if [ "$netif" = "$ethname" ]; then
             if [ "$netif" = "$bondname" ] && [ -n "$DO_BOND_SETUP" ] ; then
                 : # We need to really setup bond (recursive call)
+            elif [ "$netif" = "$teammaster" ] && [ -n "$DO_TEAM_SETUP" ] ; then
+                : # We need to really setup team (recursive call)
             else
                 netif="$bridgename"
                 use_bridge='true'
@@ -59,6 +61,8 @@ if [ -e /tmp/vlan.info ]; then
     if [ "$netif" = "$phydevice" ]; then
         if [ "$netif" = "$bondname" ] && [ -n "$DO_BOND_SETUP" ] ; then
             : # We need to really setup bond (recursive call)
+        elif [ "$netif" = "$teammaster" ] && [ -n "$DO_TEAM_SETUP" ] ; then
+            : # We need to really setup team (recursive call)
         else
             netif="$vlanname"
             use_vlan='true'
@@ -212,6 +216,8 @@ if [ -e /tmp/bridge.info ]; then
         for ethname in $ethnames ; do
             if [ "$ethname" = "$bondname" ] ; then
                 DO_BOND_SETUP=yes ifup $bondname -m
+            elif [ "$ethname" = "$teammaster" ] ; then
+                DO_TEAM_SETUP=yes ifup $teammaster -m
             else
                 linkup $ethname
             fi
@@ -235,6 +241,8 @@ if [ "$netif" = "$vlanname" ] && [ ! -e /tmp/net.$vlanname.up ]; then
     modprobe 8021q
     if [ "$phydevice" = "$bondname" ] ; then
         DO_BOND_SETUP=yes ifup $phydevice -m
+    elif [ "$phydevice" = "$teammaster" ] ; then
+        DO_TEAM_SETUP=yes ifup $phydevice -m
     else
         linkup "$phydevice"
     fi
-- 
1.8.2

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

* Re: [PATCH] ifup.sh: Add support for bridge over team and vlan tagged team
       [not found] ` <1364819680-1618-1-git-send-email-chaowang-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
@ 2013-04-07  6:47   ` WANG Chao
  2013-04-07  9:20   ` Cong Wang
  2013-04-09  8:53   ` Harald Hoyer
  2 siblings, 0 replies; 5+ messages in thread
From: WANG Chao @ 2013-04-07  6:47 UTC (permalink / raw)
  To: harald-H+wXaHxf7aLQT0dZR+AlfA, amwang-H+wXaHxf7aLQT0dZR+AlfA,
	jpirko-H+wXaHxf7aLQT0dZR+AlfA, dyoung-H+wXaHxf7aLQT0dZR+AlfA,
	bhe-H+wXaHxf7aLQT0dZR+AlfA
  Cc: initramfs-u79uwXL29TY76Z2rM5mHXA

On 04/01/2013 08:34 PM, WANG Chao wrote:
> Team is the same network stack as bonding. Therefore give ifup the ability to
> handle bridge over team and vlan tagged team as bonding too.
> 
> Signed-off-by: WANG Chao <chaowang-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
> ---
>  modules.d/40network/ifup.sh | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/modules.d/40network/ifup.sh b/modules.d/40network/ifup.sh
> index 582278f..815ab64 100755
> --- a/modules.d/40network/ifup.sh
> +++ b/modules.d/40network/ifup.sh
> @@ -46,6 +46,8 @@ if [ -e /tmp/bridge.info ]; then
>          if [ "$netif" = "$ethname" ]; then
>              if [ "$netif" = "$bondname" ] && [ -n "$DO_BOND_SETUP" ] ; then
>                  : # We need to really setup bond (recursive call)
> +            elif [ "$netif" = "$teammaster" ] && [ -n "$DO_TEAM_SETUP" ] ; then
> +                : # We need to really setup team (recursive call)
>              else
>                  netif="$bridgename"
>                  use_bridge='true'
> @@ -59,6 +61,8 @@ if [ -e /tmp/vlan.info ]; then
>      if [ "$netif" = "$phydevice" ]; then
>          if [ "$netif" = "$bondname" ] && [ -n "$DO_BOND_SETUP" ] ; then
>              : # We need to really setup bond (recursive call)
> +        elif [ "$netif" = "$teammaster" ] && [ -n "$DO_TEAM_SETUP" ] ; then
> +            : # We need to really setup team (recursive call)
>          else
>              netif="$vlanname"
>              use_vlan='true'
> @@ -212,6 +216,8 @@ if [ -e /tmp/bridge.info ]; then
>          for ethname in $ethnames ; do
>              if [ "$ethname" = "$bondname" ] ; then
>                  DO_BOND_SETUP=yes ifup $bondname -m
> +            elif [ "$ethname" = "$teammaster" ] ; then
> +                DO_TEAM_SETUP=yes ifup $teammaster -m
>              else
>                  linkup $ethname
>              fi
> @@ -235,6 +241,8 @@ if [ "$netif" = "$vlanname" ] && [ ! -e /tmp/net.$vlanname.up ]; then
>      modprobe 8021q
>      if [ "$phydevice" = "$bondname" ] ; then
>          DO_BOND_SETUP=yes ifup $phydevice -m
> +    elif [ "$phydevice" = "$teammaster" ] ; then
> +        DO_TEAM_SETUP=yes ifup $phydevice -m
>      else
>          linkup "$phydevice"
>      fi
> 

Hi, Harald

Team is one of the supported network devices in our kdump. And bridge over
team and vlan tagged team is also required, while dracut is now lack of this
ability. I tested this patch myself and it really solves the problem.

Can you or anyone else help to review this patch?

(Actually, I've also got another patch to support bridge a vlan tagged
interface upon this one. I'll send that to ML once this patch is merged)

Thanks for your time.

WANG Chao

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

* Re: [PATCH] ifup.sh: Add support for bridge over team and vlan tagged team
       [not found] ` <1364819680-1618-1-git-send-email-chaowang-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
  2013-04-07  6:47   ` WANG Chao
@ 2013-04-07  9:20   ` Cong Wang
  2013-04-07  9:32     ` WANG Chao
  2013-04-09  8:53   ` Harald Hoyer
  2 siblings, 1 reply; 5+ messages in thread
From: Cong Wang @ 2013-04-07  9:20 UTC (permalink / raw)
  To: WANG Chao
  Cc: harald-H+wXaHxf7aLQT0dZR+AlfA, jpirko-H+wXaHxf7aLQT0dZR+AlfA,
	dyoung-H+wXaHxf7aLQT0dZR+AlfA, bhe-H+wXaHxf7aLQT0dZR+AlfA,
	initramfs-u79uwXL29TY76Z2rM5mHXA

On Mon, 2013-04-01 at 20:34 +0800, WANG Chao wrote:
> Team is the same network stack as bonding. Therefore give ifup the ability to
> handle bridge over team and vlan tagged team as bonding too.
> 

Looks good to me.

Next time please mention how you test the patch in the changelog, it
helps too.


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

* Re: [PATCH] ifup.sh: Add support for bridge over team and vlan tagged team
  2013-04-07  9:20   ` Cong Wang
@ 2013-04-07  9:32     ` WANG Chao
  0 siblings, 0 replies; 5+ messages in thread
From: WANG Chao @ 2013-04-07  9:32 UTC (permalink / raw)
  To: Cong Wang
  Cc: harald-H+wXaHxf7aLQT0dZR+AlfA, jpirko-H+wXaHxf7aLQT0dZR+AlfA,
	dyoung-H+wXaHxf7aLQT0dZR+AlfA, bhe-H+wXaHxf7aLQT0dZR+AlfA,
	initramfs-u79uwXL29TY76Z2rM5mHXA

On 04/07/2013 05:20 PM, Cong Wang wrote:
> On Mon, 2013-04-01 at 20:34 +0800, WANG Chao wrote:
>> Team is the same network stack as bonding. Therefore give ifup the ability to
>> handle bridge over team and vlan tagged team as bonding too.
>>
> 
> Looks good to me.
> 
> Next time please mention how you test the patch in the changelog, it
> helps too.

Thanks for review.

I thought this patch is quite straightforward so I didn't mention the tests.
I'll bring it up next time. Thanks!

WANG Chao

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

* Re: [PATCH] ifup.sh: Add support for bridge over team and vlan tagged team
       [not found] ` <1364819680-1618-1-git-send-email-chaowang-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
  2013-04-07  6:47   ` WANG Chao
  2013-04-07  9:20   ` Cong Wang
@ 2013-04-09  8:53   ` Harald Hoyer
  2 siblings, 0 replies; 5+ messages in thread
From: Harald Hoyer @ 2013-04-09  8:53 UTC (permalink / raw)
  To: WANG Chao
  Cc: amwang-H+wXaHxf7aLQT0dZR+AlfA, jpirko-H+wXaHxf7aLQT0dZR+AlfA,
	dyoung-H+wXaHxf7aLQT0dZR+AlfA, bhe-H+wXaHxf7aLQT0dZR+AlfA,
	initramfs-u79uwXL29TY76Z2rM5mHXA

Am 01.04.2013 14:34, schrieb WANG Chao:
> Team is the same network stack as bonding. Therefore give ifup the ability to
> handle bridge over team and vlan tagged team as bonding too.
> 
> Signed-off-by: WANG Chao <chaowang-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
> ---
>  modules.d/40network/ifup.sh | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/modules.d/40network/ifup.sh b/modules.d/40network/ifup.sh
> index 582278f..815ab64 100755
> --- a/modules.d/40network/ifup.sh
> +++ b/modules.d/40network/ifup.sh
> @@ -46,6 +46,8 @@ if [ -e /tmp/bridge.info ]; then
>          if [ "$netif" = "$ethname" ]; then
>              if [ "$netif" = "$bondname" ] && [ -n "$DO_BOND_SETUP" ] ; then
>                  : # We need to really setup bond (recursive call)
> +            elif [ "$netif" = "$teammaster" ] && [ -n "$DO_TEAM_SETUP" ] ; then
> +                : # We need to really setup team (recursive call)
>              else
>                  netif="$bridgename"
>                  use_bridge='true'
> @@ -59,6 +61,8 @@ if [ -e /tmp/vlan.info ]; then
>      if [ "$netif" = "$phydevice" ]; then
>          if [ "$netif" = "$bondname" ] && [ -n "$DO_BOND_SETUP" ] ; then
>              : # We need to really setup bond (recursive call)
> +        elif [ "$netif" = "$teammaster" ] && [ -n "$DO_TEAM_SETUP" ] ; then
> +            : # We need to really setup team (recursive call)
>          else
>              netif="$vlanname"
>              use_vlan='true'
> @@ -212,6 +216,8 @@ if [ -e /tmp/bridge.info ]; then
>          for ethname in $ethnames ; do
>              if [ "$ethname" = "$bondname" ] ; then
>                  DO_BOND_SETUP=yes ifup $bondname -m
> +            elif [ "$ethname" = "$teammaster" ] ; then
> +                DO_TEAM_SETUP=yes ifup $teammaster -m
>              else
>                  linkup $ethname
>              fi
> @@ -235,6 +241,8 @@ if [ "$netif" = "$vlanname" ] && [ ! -e /tmp/net.$vlanname.up ]; then
>      modprobe 8021q
>      if [ "$phydevice" = "$bondname" ] ; then
>          DO_BOND_SETUP=yes ifup $phydevice -m
> +    elif [ "$phydevice" = "$teammaster" ] ; then
> +        DO_TEAM_SETUP=yes ifup $phydevice -m
>      else
>          linkup "$phydevice"
>      fi
> 

applied

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

end of thread, other threads:[~2013-04-09  8:53 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-01 12:34 [PATCH] ifup.sh: Add support for bridge over team and vlan tagged team WANG Chao
     [not found] ` <1364819680-1618-1-git-send-email-chaowang-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2013-04-07  6:47   ` WANG Chao
2013-04-07  9:20   ` Cong Wang
2013-04-07  9:32     ` WANG Chao
2013-04-09  8:53   ` Harald Hoyer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox