X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=datapath%2Fvport.c;h=ca802b4b28e02fa372e7c706caf0614a9b8ca98e;hb=9197df76b46ff6fbe1f7a522961730ffc55a860d;hp=b1418a4c343ac858710c45cf1f8c6b606bbb643b;hpb=a89721b529d83aac3a09d5027a01756771c78187;p=sliver-openvswitch.git diff --git a/datapath/vport.c b/datapath/vport.c index b1418a4c3..ca802b4b2 100644 --- a/datapath/vport.c +++ b/datapath/vport.c @@ -284,36 +284,6 @@ void vport_del(struct vport *vport) vport->ops->destroy(vport); } -/** - * vport_set_mtu - set device MTU (for kernel callers) - * - * @vport: vport on which to set MTU. - * @mtu: New MTU. - * - * Sets the MTU of the given device. Some devices may not support setting the - * MTU, in which case the result will always be -EOPNOTSUPP. RTNL lock must - * be held. - */ -int vport_set_mtu(struct vport *vport, int mtu) -{ - ASSERT_RTNL(); - - if (mtu < 68) - return -EINVAL; - - if (vport->ops->set_mtu) { - int ret; - - ret = vport->ops->set_mtu(vport, mtu); - - if (!ret && !is_internal_vport(vport)) - set_internal_devs_mtu(vport->dp); - - return ret; - } else - return -EOPNOTSUPP; -} - /** * vport_set_addr - set device Ethernet address (for kernel callers) *