/linux/drivers/net/ |
A D | vsockmon.c | 67 static int vsockmon_is_valid_mtu(int new_mtu) in vsockmon_is_valid_mtu() argument 69 return new_mtu >= (int)sizeof(struct af_vsockmon_hdr); in vsockmon_is_valid_mtu() 72 static int vsockmon_change_mtu(struct net_device *dev, int new_mtu) in vsockmon_change_mtu() argument 74 if (!vsockmon_is_valid_mtu(new_mtu)) in vsockmon_change_mtu() 77 dev->mtu = new_mtu; in vsockmon_change_mtu()
|
A D | ntb_netdev.c | 299 static int ntb_netdev_change_mtu(struct net_device *ndev, int new_mtu) in ntb_netdev_change_mtu() argument 305 if (new_mtu > ntb_transport_max_size(dev->qp) - ETH_HLEN) in ntb_netdev_change_mtu() 309 ndev->mtu = new_mtu; in ntb_netdev_change_mtu() 316 if (ndev->mtu < new_mtu) { in ntb_netdev_change_mtu() 323 skb = netdev_alloc_skb(ndev, new_mtu + ETH_HLEN); in ntb_netdev_change_mtu() 330 new_mtu + ETH_HLEN); in ntb_netdev_change_mtu() 338 ndev->mtu = new_mtu; in ntb_netdev_change_mtu()
|
A D | net_failover.c | 215 static int net_failover_change_mtu(struct net_device *dev, int new_mtu) in net_failover_change_mtu() argument 223 ret = dev_set_mtu(primary_dev, new_mtu); in net_failover_change_mtu() 230 ret = dev_set_mtu(standby_dev, new_mtu); in net_failover_change_mtu() 238 dev->mtu = new_mtu; in net_failover_change_mtu()
|
/linux/drivers/net/can/ |
A D | vcan.c | 130 static int vcan_change_mtu(struct net_device *dev, int new_mtu) in vcan_change_mtu() argument 136 if (new_mtu != CAN_MTU && new_mtu != CANFD_MTU) in vcan_change_mtu() 139 dev->mtu = new_mtu; in vcan_change_mtu()
|
A D | vxcan.c | 121 static int vxcan_change_mtu(struct net_device *dev, int new_mtu) in vxcan_change_mtu() argument 127 if (new_mtu != CAN_MTU && new_mtu != CANFD_MTU) in vxcan_change_mtu() 130 dev->mtu = new_mtu; in vxcan_change_mtu()
|
/linux/drivers/net/ethernet/qualcomm/rmnet/ |
A D | rmnet_vnd.c | 74 static int rmnet_vnd_change_mtu(struct net_device *rmnet_dev, int new_mtu) in rmnet_vnd_change_mtu() argument 84 if (new_mtu < 0 || new_mtu > RMNET_MAX_PACKET_SIZE || in rmnet_vnd_change_mtu() 85 new_mtu > (priv->real_dev->mtu - headroom)) in rmnet_vnd_change_mtu() 88 rmnet_dev->mtu = new_mtu; in rmnet_vnd_change_mtu()
|
/linux/drivers/net/ethernet/netronome/nfp/ |
A D | nfp_app.h | 112 int new_mtu); 114 int new_mtu); 259 nfp_app_check_mtu(struct nfp_app *app, struct net_device *netdev, int new_mtu) in nfp_app_check_mtu() argument 263 return app->type->check_mtu(app, netdev, new_mtu); in nfp_app_check_mtu() 268 int new_mtu) in nfp_app_repr_change_mtu() argument 272 return app->type->repr_change_mtu(app, netdev, new_mtu); in nfp_app_repr_change_mtu()
|
A D | nfp_net_repr.c | 167 static int nfp_repr_change_mtu(struct net_device *netdev, int new_mtu) in nfp_repr_change_mtu() argument 172 err = nfp_app_check_mtu(repr->app, netdev, new_mtu); in nfp_repr_change_mtu() 176 err = nfp_app_repr_change_mtu(repr->app, netdev, new_mtu); in nfp_repr_change_mtu() 180 netdev->mtu = new_mtu; in nfp_repr_change_mtu()
|
/linux/drivers/net/ethernet/mellanox/mlx5/core/ipoib/ |
A D | ipoib_vlan.c | 142 static int mlx5i_pkey_change_mtu(struct net_device *netdev, int new_mtu); 266 static int mlx5i_pkey_change_mtu(struct net_device *netdev, int new_mtu) in mlx5i_pkey_change_mtu() argument 271 netdev->mtu = new_mtu; in mlx5i_pkey_change_mtu()
|
/linux/drivers/net/can/dev/ |
A D | dev.c | 300 int can_change_mtu(struct net_device *dev, int new_mtu) in can_change_mtu() argument 309 switch (new_mtu) { in can_change_mtu() 331 dev->mtu = new_mtu; in can_change_mtu()
|
/linux/drivers/net/ethernet/aquantia/atlantic/ |
A D | aq_main.c | 127 static int aq_ndev_change_mtu(struct net_device *ndev, int new_mtu) in aq_ndev_change_mtu() argument 132 err = aq_nic_set_mtu(aq_nic, new_mtu + ETH_HLEN); in aq_ndev_change_mtu() 136 ndev->mtu = new_mtu; in aq_ndev_change_mtu()
|
/linux/drivers/net/netdevsim/ |
A D | netdev.c | 51 static int nsim_change_mtu(struct net_device *dev, int new_mtu) in nsim_change_mtu() argument 55 if (ns->xdp.prog && new_mtu > NSIM_XDP_MAX_MTU) in nsim_change_mtu() 58 dev->mtu = new_mtu; in nsim_change_mtu()
|
/linux/drivers/net/ethernet/cavium/liquidio/ |
A D | lio_vf_rep.c | 39 static int lio_vf_rep_change_mtu(struct net_device *ndev, int new_mtu); 199 lio_vf_rep_change_mtu(struct net_device *ndev, int new_mtu) in lio_vf_rep_change_mtu() argument 211 rep_cfg.rep_mtu.mtu = cpu_to_be32(new_mtu); in lio_vf_rep_change_mtu() 221 ndev->mtu = new_mtu; in lio_vf_rep_change_mtu()
|
/linux/drivers/net/ethernet/ |
A D | lantiq_xrx200.c | 359 xrx200_change_mtu(struct net_device *net_dev, int new_mtu) in xrx200_change_mtu() argument 369 net_dev->mtu = new_mtu; in xrx200_change_mtu() 370 priv->rx_buf_size = xrx200_buffer_size(new_mtu); in xrx200_change_mtu() 372 if (new_mtu <= old_mtu) in xrx200_change_mtu()
|
/linux/net/sched/ |
A D | sch_teql.c | 415 static int teql_master_mtu(struct net_device *dev, int new_mtu) in teql_master_mtu() argument 423 if (new_mtu > qdisc_dev(q)->mtu) in teql_master_mtu() 428 dev->mtu = new_mtu; in teql_master_mtu()
|
/linux/net/hsr/ |
A D | hsr_device.c | 124 static int hsr_dev_change_mtu(struct net_device *dev, int new_mtu) in hsr_dev_change_mtu() argument 130 if (new_mtu > hsr_get_max_mtu(hsr)) { in hsr_dev_change_mtu() 136 dev->mtu = new_mtu; in hsr_dev_change_mtu()
|
/linux/net/batman-adv/ |
A D | soft-interface.c | 155 static int batadv_interface_change_mtu(struct net_device *dev, int new_mtu) in batadv_interface_change_mtu() argument 158 if (new_mtu < 68 || new_mtu > batadv_hardif_min_mtu(dev)) in batadv_interface_change_mtu() 161 dev->mtu = new_mtu; in batadv_interface_change_mtu()
|
/linux/net/ipv4/ |
A D | ip_tunnel.c | 976 int __ip_tunnel_change_mtu(struct net_device *dev, int new_mtu, bool strict) in __ip_tunnel_change_mtu() argument 985 if (new_mtu < ETH_MIN_MTU) in __ip_tunnel_change_mtu() 988 if (new_mtu > max_mtu) { in __ip_tunnel_change_mtu() 992 new_mtu = max_mtu; in __ip_tunnel_change_mtu() 995 dev->mtu = new_mtu; in __ip_tunnel_change_mtu() 1000 int ip_tunnel_change_mtu(struct net_device *dev, int new_mtu) in ip_tunnel_change_mtu() argument 1002 return __ip_tunnel_change_mtu(dev, new_mtu, true); in ip_tunnel_change_mtu()
|
/linux/net/bridge/ |
A D | br_device.c | 211 static int br_change_mtu(struct net_device *dev, int new_mtu) in br_change_mtu() argument 215 dev->mtu = new_mtu; in br_change_mtu() 221 dst_metric_set(&br->fake_rtable.dst, RTAX_MTU, new_mtu); in br_change_mtu()
|
/linux/drivers/net/ethernet/sfc/ |
A D | efx_common.c | 285 int efx_change_mtu(struct net_device *net_dev, int new_mtu) in efx_change_mtu() argument 295 new_mtu > efx_xdp_max_mtu(efx)) { in efx_change_mtu() 298 new_mtu, efx_xdp_max_mtu(efx)); in efx_change_mtu() 302 netif_dbg(efx, drv, efx->net_dev, "changing MTU to %d\n", new_mtu); in efx_change_mtu() 308 net_dev->mtu = new_mtu; in efx_change_mtu()
|
/linux/drivers/net/ethernet/ibm/emac/ |
A D | core.c | 1034 int rx_sync_size = emac_rx_sync_size(new_mtu); in emac_resize_rx_ring() 1035 int rx_skb_size = emac_rx_skb_size(new_mtu); in emac_resize_rx_ring() 1089 mr1_jumbo_bit_change = (new_mtu > ETH_DATA_LEN) || in emac_resize_rx_ring() 1092 mr1_jumbo_bit_change = (new_mtu > ETH_DATA_LEN) ^ in emac_resize_rx_ring() 1100 dev->ndev->mtu = new_mtu; in emac_resize_rx_ring() 1123 DBG(dev, "change_mtu(%d)" NL, new_mtu); in emac_change_mtu() 1127 if (emac_rx_skb_size(ndev->mtu) != emac_rx_skb_size(new_mtu)) in emac_change_mtu() 1128 ret = emac_resize_rx_ring(dev, new_mtu); in emac_change_mtu() 1132 ndev->mtu = new_mtu; in emac_change_mtu() 1133 dev->rx_skb_size = emac_rx_skb_size(new_mtu); in emac_change_mtu() [all …]
|
/linux/drivers/infiniband/ulp/ipoib/ |
A D | ipoib_main.c | 227 static int ipoib_change_mtu(struct net_device *dev, int new_mtu) in ipoib_change_mtu() argument 234 if (new_mtu > ipoib_cm_max_mtu(dev)) in ipoib_change_mtu() 237 if (new_mtu > priv->mcast_mtu) in ipoib_change_mtu() 241 dev->mtu = new_mtu; in ipoib_change_mtu() 245 if (new_mtu < (ETH_MIN_MTU + IPOIB_ENCAP_LEN) || in ipoib_change_mtu() 246 new_mtu > IPOIB_UD_MTU(priv->max_ib_mtu)) in ipoib_change_mtu() 249 priv->admin_mtu = new_mtu; in ipoib_change_mtu() 255 new_mtu = min(priv->mcast_mtu, priv->admin_mtu); in ipoib_change_mtu() 263 ret = priv->rn_ops->ndo_change_mtu(dev, new_mtu); in ipoib_change_mtu() 268 dev->mtu = new_mtu; in ipoib_change_mtu()
|
/linux/drivers/net/ethernet/qualcomm/emac/ |
A D | emac.c | 213 static int emac_change_mtu(struct net_device *netdev, int new_mtu) in emac_change_mtu() argument 219 new_mtu); in emac_change_mtu() 220 netdev->mtu = new_mtu; in emac_change_mtu()
|
/linux/include/linux/usb/ |
A D | cdc_ncm.h | 156 int cdc_ncm_change_mtu(struct net_device *net, int new_mtu);
|
/linux/drivers/net/dsa/ |
A D | dsa_loop.c | 264 int new_mtu) in dsa_loop_port_change_mtu() argument 268 priv->ports[port].mtu = new_mtu; in dsa_loop_port_change_mtu()
|