提交 5c326ab4 编写于 作者: I Ido Schimmel 提交者: David S. Miller

switchdev: Support parent ID comparison for stacked devices

switchdev_port_same_parent_id() currently expects port netdevs, but we
need it to support stacked devices in the next patch, so drop the
NO_RECURSE flag.
Signed-off-by: NIdo Schimmel <idosch@mellanox.com>
Signed-off-by: NJiri Pirko <jiri@mellanox.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 2a313cdf
...@@ -1292,12 +1292,10 @@ bool switchdev_port_same_parent_id(struct net_device *a, ...@@ -1292,12 +1292,10 @@ bool switchdev_port_same_parent_id(struct net_device *a,
struct switchdev_attr a_attr = { struct switchdev_attr a_attr = {
.orig_dev = a, .orig_dev = a,
.id = SWITCHDEV_ATTR_ID_PORT_PARENT_ID, .id = SWITCHDEV_ATTR_ID_PORT_PARENT_ID,
.flags = SWITCHDEV_F_NO_RECURSE,
}; };
struct switchdev_attr b_attr = { struct switchdev_attr b_attr = {
.orig_dev = b, .orig_dev = b,
.id = SWITCHDEV_ATTR_ID_PORT_PARENT_ID, .id = SWITCHDEV_ATTR_ID_PORT_PARENT_ID,
.flags = SWITCHDEV_F_NO_RECURSE,
}; };
if (switchdev_port_attr_get(a, &a_attr) || if (switchdev_port_attr_get(a, &a_attr) ||
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册