Home
last modified time | relevance | path

Searched refs:new_mtu (Results 1 – 25 of 175) sorted by relevance

1234567

/drivers/net/can/
Dvcan.c133 static int vcan_change_mtu(struct net_device *dev, int new_mtu) in vcan_change_mtu() argument
139 if (new_mtu != CAN_MTU && new_mtu != CANFD_MTU && in vcan_change_mtu()
140 !can_is_canxl_dev_mtu(new_mtu)) in vcan_change_mtu()
143 dev->mtu = new_mtu; in vcan_change_mtu()
Dvxcan.c128 static int vxcan_change_mtu(struct net_device *dev, int new_mtu) in vxcan_change_mtu() argument
134 if (new_mtu != CAN_MTU && new_mtu != CANFD_MTU && in vxcan_change_mtu()
135 !can_is_canxl_dev_mtu(new_mtu)) in vxcan_change_mtu()
138 dev->mtu = new_mtu; in vxcan_change_mtu()
/drivers/net/
Dvsockmon.c67 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()
Dntb_netdev.c299 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()
Dnet_failover.c211 static int net_failover_change_mtu(struct net_device *dev, int new_mtu) in net_failover_change_mtu() argument
219 ret = dev_set_mtu(primary_dev, new_mtu); in net_failover_change_mtu()
226 ret = dev_set_mtu(standby_dev, new_mtu); in net_failover_change_mtu()
234 dev->mtu = new_mtu; in net_failover_change_mtu()
/drivers/net/ethernet/qualcomm/rmnet/
Drmnet_vnd.c74 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()
/drivers/net/dsa/microchip/
Dlan937x_main.c223 int lan937x_change_mtu(struct ksz_device *dev, int port, int new_mtu) in lan937x_change_mtu() argument
228 new_mtu += VLAN_ETH_HLEN + ETH_FCS_LEN; in lan937x_change_mtu()
231 new_mtu += LAN937X_TAG_LEN; in lan937x_change_mtu()
233 if (new_mtu >= FR_MIN_SIZE) in lan937x_change_mtu()
245 ksz_pwrite16(dev, port, PORT_MAX_FR_SIZE, new_mtu); in lan937x_change_mtu()
Dlan937x.h18 int lan937x_change_mtu(struct ksz_device *dev, int port, int new_mtu);
/drivers/net/ethernet/netronome/nfp/
Dnfp_app.h112 int new_mtu);
114 int new_mtu);
269 nfp_app_check_mtu(struct nfp_app *app, struct net_device *netdev, int new_mtu) in nfp_app_check_mtu() argument
273 return app->type->check_mtu(app, netdev, new_mtu); in nfp_app_check_mtu()
278 int new_mtu) in nfp_app_repr_change_mtu() argument
282 return app->type->repr_change_mtu(app, netdev, new_mtu); in nfp_app_repr_change_mtu()
Dnfp_net_repr.c167 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()
/drivers/net/ethernet/aquantia/atlantic/
Daq_main.c129 static int aq_ndev_change_mtu(struct net_device *ndev, int new_mtu) in aq_ndev_change_mtu() argument
131 int new_frame_size = new_mtu + ETH_HLEN + ETH_FCS_LEN; in aq_ndev_change_mtu()
144 err = aq_nic_set_mtu(aq_nic, new_mtu + ETH_HLEN); in aq_ndev_change_mtu()
148 ndev->mtu = new_mtu; in aq_ndev_change_mtu()
/drivers/net/ethernet/mellanox/mlx5/core/ipoib/
Dipoib_vlan.c142 static int mlx5i_pkey_change_mtu(struct net_device *netdev, int new_mtu);
274 static int mlx5i_pkey_change_mtu(struct net_device *netdev, int new_mtu) in mlx5i_pkey_change_mtu() argument
279 netdev->mtu = new_mtu; in mlx5i_pkey_change_mtu()
/drivers/net/netdevsim/
Dnetdev.c51 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()
/drivers/net/can/dev/
Ddev.c290 int can_change_mtu(struct net_device *dev, int new_mtu) in can_change_mtu() argument
300 switch (new_mtu) { in can_change_mtu()
322 dev->mtu = new_mtu; in can_change_mtu()
/drivers/net/ethernet/cavium/liquidio/
Dlio_vf_rep.c39 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()
/drivers/net/ethernet/
Dlantiq_xrx200.c412 xrx200_change_mtu(struct net_device *net_dev, int new_mtu) in xrx200_change_mtu() argument
422 net_dev->mtu = new_mtu; in xrx200_change_mtu()
423 priv->rx_buf_size = xrx200_buffer_size(new_mtu); in xrx200_change_mtu()
426 if (new_mtu <= old_mtu) in xrx200_change_mtu()
/drivers/net/ethernet/marvell/octeon_ep/
Doctep_main.c837 static int octep_change_mtu(struct net_device *netdev, int new_mtu) in octep_change_mtu() argument
844 if (link_info->mtu == new_mtu) in octep_change_mtu()
847 err = octep_set_mtu(oct, new_mtu); in octep_change_mtu()
849 oct->link_info.mtu = new_mtu; in octep_change_mtu()
850 netdev->mtu = new_mtu; in octep_change_mtu()
/drivers/net/ethernet/sfc/siena/
Defx_common.c286 int efx_siena_change_mtu(struct net_device *net_dev, int new_mtu) in efx_siena_change_mtu() argument
296 new_mtu > efx_siena_xdp_max_mtu(efx)) { in efx_siena_change_mtu()
299 new_mtu, efx_siena_xdp_max_mtu(efx)); in efx_siena_change_mtu()
303 netif_dbg(efx, drv, efx->net_dev, "changing MTU to %d\n", new_mtu); in efx_siena_change_mtu()
309 net_dev->mtu = new_mtu; in efx_siena_change_mtu()
Defx_common.h105 int efx_siena_change_mtu(struct net_device *net_dev, int new_mtu);
/drivers/net/ethernet/sfc/
Defx_common.c287 int efx_change_mtu(struct net_device *net_dev, int new_mtu) in efx_change_mtu() argument
297 new_mtu > efx_xdp_max_mtu(efx)) { in efx_change_mtu()
300 new_mtu, efx_xdp_max_mtu(efx)); in efx_change_mtu()
304 netif_dbg(efx, drv, efx->net_dev, "changing MTU to %d\n", new_mtu); in efx_change_mtu()
310 net_dev->mtu = new_mtu; in efx_change_mtu()
Defx_common.h102 int efx_change_mtu(struct net_device *net_dev, int new_mtu);
/drivers/net/ethernet/ibm/emac/
Dcore.c1032 static int emac_resize_rx_ring(struct emac_instance *dev, int new_mtu) in emac_resize_rx_ring() argument
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()
1104 mal_set_rcbs(dev->mal, dev->mal_rx_chan, emac_rx_size(new_mtu)); in emac_resize_rx_ring()
1118 static int emac_change_mtu(struct net_device *ndev, int new_mtu) in emac_change_mtu() argument
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()
[all …]
/drivers/infiniband/ulp/ipoib/
Dipoib_main.c227 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()
/drivers/net/ethernet/qualcomm/emac/
Demac.c213 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()
/drivers/net/dsa/
Ddsa_loop.c266 int new_mtu) in dsa_loop_port_change_mtu() argument
270 priv->ports[port].mtu = new_mtu; in dsa_loop_port_change_mtu()

1234567