aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
authorJianhua Xie <jianhua.xie@freescale.com>2014-07-17 02:16:26 -0400
committerDavid S. Miller <davem@davemloft.net>2014-07-17 19:03:27 -0400
commit92abf75033d2677a684c623d60f093b130c4b38f (patch)
tree54cc9282e46d7d3c0f78671a7d8d801ddcf1bbe4 /Documentation
parentce04d63502ca7ec30ef07336a0fd6f1165fd486b (diff)
bonding: update bonding.txt for Layer2 hash factors
Document the Layer 2 hash factors with packet type ID field. CC: Jay Vosburgh <j.vosburgh@gmail.com> CC: Veaceslav Falico <vfalico@gmail.com> CC: Andy Gospodarek <andy@greyhouse.net> CC: David S. Miller <davem@davemloft.net> CC: Pan Jiafei <Jiafei.Pan@freescale.com> Signed-off-by: Jianhua Xie <jianhua.xie@freescale.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/networking/bonding.txt31
1 files changed, 16 insertions, 15 deletions
diff --git a/Documentation/networking/bonding.txt b/Documentation/networking/bonding.txt
index 9c723ecd0025..eeb5b2e97bed 100644
--- a/Documentation/networking/bonding.txt
+++ b/Documentation/networking/bonding.txt
@@ -542,10 +542,10 @@ mode
542 542
543 XOR policy: Transmit based on the selected transmit 543 XOR policy: Transmit based on the selected transmit
544 hash policy. The default policy is a simple [(source 544 hash policy. The default policy is a simple [(source
545 MAC address XOR'd with destination MAC address) modulo 545 MAC address XOR'd with destination MAC address XOR
546 slave count]. Alternate transmit policies may be 546 packet type ID) modulo slave count]. Alternate transmit
547 selected via the xmit_hash_policy option, described 547 policies may be selected via the xmit_hash_policy option,
548 below. 548 described below.
549 549
550 This mode provides load balancing and fault tolerance. 550 This mode provides load balancing and fault tolerance.
551 551
@@ -801,10 +801,11 @@ xmit_hash_policy
801 801
802 layer2 802 layer2
803 803
804 Uses XOR of hardware MAC addresses to generate the 804 Uses XOR of hardware MAC addresses and packet type ID
805 hash. The formula is 805 field to generate the hash. The formula is
806 806
807 (source MAC XOR destination MAC) modulo slave count 807 hash = source MAC XOR destination MAC XOR packet type ID
808 slave number = hash modulo slave count
808 809
809 This algorithm will place all traffic to a particular 810 This algorithm will place all traffic to a particular
810 network peer on the same slave. 811 network peer on the same slave.
@@ -819,7 +820,7 @@ xmit_hash_policy
819 Uses XOR of hardware MAC addresses and IP addresses to 820 Uses XOR of hardware MAC addresses and IP addresses to
820 generate the hash. The formula is 821 generate the hash. The formula is
821 822
822 hash = source MAC XOR destination MAC 823 hash = source MAC XOR destination MAC XOR packet type ID
823 hash = hash XOR source IP XOR destination IP 824 hash = hash XOR source IP XOR destination IP
824 hash = hash XOR (hash RSHIFT 16) 825 hash = hash XOR (hash RSHIFT 16)
825 hash = hash XOR (hash RSHIFT 8) 826 hash = hash XOR (hash RSHIFT 8)
@@ -2301,13 +2302,13 @@ broadcast: Like active-backup, there is not much advantage to this
2301 bandwidth. 2302 bandwidth.
2302 2303
2303 Additionally, the linux bonding 802.3ad implementation 2304 Additionally, the linux bonding 802.3ad implementation
2304 distributes traffic by peer (using an XOR of MAC addresses), 2305 distributes traffic by peer (using an XOR of MAC addresses
2305 so in a "gatewayed" configuration, all outgoing traffic will 2306 and packet type ID), so in a "gatewayed" configuration, all
2306 generally use the same device. Incoming traffic may also end 2307 outgoing traffic will generally use the same device. Incoming
2307 up on a single device, but that is dependent upon the 2308 traffic may also end up on a single device, but that is
2308 balancing policy of the peer's 8023.ad implementation. In a 2309 dependent upon the balancing policy of the peer's 8023.ad
2309 "local" configuration, traffic will be distributed across the 2310 implementation. In a "local" configuration, traffic will be
2310 devices in the bond. 2311 distributed across the devices in the bond.
2311 2312
2312 Finally, the 802.3ad mode mandates the use of the MII monitor, 2313 Finally, the 802.3ad mode mandates the use of the MII monitor,
2313 therefore, the ARP monitor is not available in this mode. 2314 therefore, the ARP monitor is not available in this mode.