)]}'
{
  "commit": "eaddcd76903c28e84bb452a35835babb0800a2c4",
  "tree": "97e512e21955da69d434a34b4e073ba880ec7d3d",
  "parents": [
    "523f610e1be2a4afca605962e137064378883c5f"
  ],
  "author": {
    "name": "Andy Gospodarek",
    "email": "andy@greyhouse.net",
    "time": "Thu Mar 22 16:14:29 2012 +0000"
  },
  "committer": {
    "name": "David S. Miller",
    "email": "davem@davemloft.net",
    "time": "Thu Mar 22 22:36:17 2012 -0400"
  },
  "message": "bonding: remove entries for master_ip and vlan_ip and query devices instead\n\nThe following patch aimed to resolve an issue where secondary, tertiary,\netc. addresses added to bond interfaces could overwrite the\nbond-\u003emaster_ip and vlan_ip values.\n\n        commit 917fbdb32f37e9a93b00bb12ee83532982982df3\n        Author: Henrik Saavedra Persson \u003chenrik.e.persson@ericsson.com\u003e\n        Date:   Wed Nov 23 23:37:15 2011 +0000\n\n            bonding: only use primary address for ARP\n\nThat patch was good because it prevented bonds using ARP monitoring from\nsending frames with an invalid source IP address.  Unfortunately, it\ndidn\u0027t always work as expected.\n\nWhen using an ioctl (like ifconfig does) to set the IP address and\nnetmask, 2 separate ioctls are actually called to set the IP and netmask\nif the mask chosen doesn\u0027t match the standard mask for that class of\naddress.  The first ioctl did not have a mask that matched the one in\nthe primary address and would still cause the device address to be\noverwritten.  The second ioctl that was called to set the mask would\nthen detect as secondary and ignored, but the damage was already done.\n\nThis was not an issue when using an application that used netlink\nsockets as the setting of IP and netmask came down at once.  The\ninconsistent behavior between those two interfaces was something that\nneeded to be resolved.\n\nWhile I was thinking about how I wanted to resolve this, Ralf Zeidler\ncame with a patch that resolved this on a RHEL kernel by keeping a full\nshadow of the entries in dev-\u003eifa_list for the bonding device and vlan\ndevices in the bonding driver.  I didn\u0027t like the duplication of the\nlist as I want to see the \u0027bonding\u0027 struct and code shrink rather than\ngrow, but liked the general idea.\n\nAs the Subject indicates this patch drops the master_ip and vlan_ip\nelements from the \u0027bonding\u0027 and \u0027vlan_entry\u0027 structs, respectively.\nThis can be done because a device\u0027s address-list is now traversed to\ndetermine the optimal source IP address for ARP requests and for checks\nto see if the bonding device has a particular IP address.  This code\ncould have all be contained inside the bonding driver, but it made more\nsense to me to EXPORT and call inet_confirm_addr since it did exactly\nwhat was needed.\n\nI tested this and a backported patch and everything works as expected.\nRalf also helped with verification of the backported patch.\n\nThanks to Ralf for all his help on this.\n\nv2: Whitespace and organizational changes based on suggestions from Jay\nVosburgh and Dave Miller.\n\nv3: Fixup incorrect usage of rcu_read_unlock based on Dave Miller\u0027s\nsuggestion.\n\nSigned-off-by: Andy Gospodarek \u003candy@greyhouse.net\u003e\nCC: Ralf Zeidler \u003cralf.zeidler@nsn.com\u003e\nSigned-off-by: David S. Miller \u003cdavem@davemloft.net\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "0730203a19f21c6019499c9b487a1f87fabd984e",
      "old_mode": 33188,
      "old_path": "drivers/net/bonding/bond_main.c",
      "new_id": "b920d829692aa35394962f87910678bfe1d4cbb7",
      "new_mode": 33188,
      "new_path": "drivers/net/bonding/bond_main.c"
    },
    {
      "type": "modify",
      "old_id": "1aecc37e5b4dcd041cefecc1fb3e7813ab39d8b0",
      "old_mode": 33188,
      "old_path": "drivers/net/bonding/bonding.h",
      "new_id": "9f2bae6616d3f455ed097f927ba1ca9fd27be945",
      "new_mode": 33188,
      "new_path": "drivers/net/bonding/bonding.h"
    },
    {
      "type": "modify",
      "old_id": "e41c40f48cfe053f28baa3fe9dcf4179ce5a1f37",
      "old_mode": 33188,
      "old_path": "net/ipv4/devinet.c",
      "new_id": "d4fad5c774471529dbe76703a7c4e95d2b694b6e",
      "new_mode": 33188,
      "new_path": "net/ipv4/devinet.c"
    }
  ]
}
