summaryrefslogtreecommitdiffstats
path: root/net/ceph
diff options
context:
space:
mode:
authorTaehee Yoo <ap420073@gmail.com>2019-10-21 18:47:56 +0000
committerDavid S. Miller <davem@davemloft.net>2019-10-24 14:53:48 -0700
commit32b6d34fedc2229cdf6a047fdbc0704085441915 (patch)
tree9520855b7c114420d269b5aaa3d1fab3bcd4af1b /net/ceph
parent2bce1ebed17da54c65042ec2b962e3234bad5b47 (diff)
downloadlinux-32b6d34fedc2229cdf6a047fdbc0704085441915.tar.bz2
net: core: add ignore flag to netdev_adjacent structure
In order to link an adjacent node, netdev_upper_dev_link() is used and in order to unlink an adjacent node, netdev_upper_dev_unlink() is used. unlink operation does not fail, but link operation can fail. In order to exchange adjacent nodes, we should unlink an old adjacent node first. then, link a new adjacent node. If link operation is failed, we should link an old adjacent node again. But this link operation can fail too. It eventually breaks the adjacent link relationship. This patch adds an ignore flag into the netdev_adjacent structure. If this flag is set, netdev_upper_dev_link() ignores an old adjacent node for a moment. This patch also adds new functions for other modules. netdev_adjacent_change_prepare() netdev_adjacent_change_commit() netdev_adjacent_change_abort() netdev_adjacent_change_prepare() inserts new device into adjacent list but new device is not allowed to use immediately. If netdev_adjacent_change_prepare() fails, it internally rollbacks adjacent list so that we don't need any other action. netdev_adjacent_change_commit() deletes old device in the adjacent list and allows new device to use. netdev_adjacent_change_abort() rollbacks adjacent list. Signed-off-by: Taehee Yoo <ap420073@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ceph')
0 files changed, 0 insertions, 0 deletions