/linux-3.4.99/net/rxrpc/ |
D | ar-error.c | 74 u32 mtu = serr->ee.ee_info; in rxrpc_UDP_error_report() local 76 _net("Rx Received ICMP Fragmentation Needed (%d)", mtu); in rxrpc_UDP_error_report() 79 if (mtu > 0 && peer->if_mtu == 65535 && mtu < peer->if_mtu) { in rxrpc_UDP_error_report() 80 peer->if_mtu = mtu; in rxrpc_UDP_error_report() 81 _net("I/F MTU %u", mtu); in rxrpc_UDP_error_report() 85 if (mtu == 0) in rxrpc_UDP_error_report() 86 mtu = ntohs(icmp_hdr(skb)->un.frag.mtu); in rxrpc_UDP_error_report() 88 if (mtu == 0) { in rxrpc_UDP_error_report() 90 if (mtu > 1500) { in rxrpc_UDP_error_report() 91 mtu >>= 1; in rxrpc_UDP_error_report() [all …]
|
/linux-3.4.99/net/ipv6/ |
D | xfrm6_output.c | 46 static void xfrm6_local_rxpmtu(struct sk_buff *skb, u32 mtu) in xfrm6_local_rxpmtu() argument 54 ipv6_local_rxpmtu(sk, &fl6, mtu); in xfrm6_local_rxpmtu() 57 static void xfrm6_local_error(struct sk_buff *skb, u32 mtu) in xfrm6_local_error() argument 65 ipv6_local_error(sk, EMSGSIZE, &fl6, mtu); in xfrm6_local_error() 70 int mtu, ret = 0; in xfrm6_tunnel_check_size() local 73 mtu = dst_mtu(dst); in xfrm6_tunnel_check_size() 74 if (mtu < IPV6_MIN_MTU) in xfrm6_tunnel_check_size() 75 mtu = IPV6_MIN_MTU; in xfrm6_tunnel_check_size() 77 if (!skb->local_df && skb->len > mtu) { in xfrm6_tunnel_check_size() 81 xfrm6_local_rxpmtu(skb, mtu); in xfrm6_tunnel_check_size() [all …]
|
D | ip6_output.c | 193 u32 mtu; in ip6_xmit() local 247 mtu = dst_mtu(dst); in ip6_xmit() 248 if ((skb->len <= mtu) || skb->local_df || skb_is_gso(skb)) { in ip6_xmit() 258 icmpv6_send(skb, ICMPV6_PKT_TOOBIG, 0, mtu); in ip6_xmit() 385 static bool ip6_pkt_too_big(const struct sk_buff *skb, unsigned int mtu) in ip6_pkt_too_big() argument 387 if (skb->len <= mtu || skb->local_df) in ip6_pkt_too_big() 390 if (skb_is_gso(skb) && skb_gso_network_seglen(skb) <= mtu) in ip6_pkt_too_big() 402 u32 mtu; in ip6_forward() local 513 mtu = dst_mtu(dst); in ip6_forward() 514 if (mtu < IPV6_MIN_MTU) in ip6_forward() [all …]
|
D | ip6_tunnel.c | 462 __u32 mtu; in ip6_tnl_err() local 502 mtu = *info - offset; in ip6_tnl_err() 503 if (mtu < IPV6_MIN_MTU) in ip6_tnl_err() 504 mtu = IPV6_MIN_MTU; in ip6_tnl_err() 505 t->dev->mtu = mtu; in ip6_tnl_err() 507 if ((len = sizeof (*ipv6h) + ntohs(ipv6h->payload_len)) > mtu) { in ip6_tnl_err() 510 rel_info = mtu; in ip6_tnl_err() 897 int mtu; in ip6_tnl_xmit2() local 929 mtu = dst_mtu(dst) - sizeof (*ipv6h); in ip6_tnl_xmit2() 932 mtu -= 8; in ip6_tnl_xmit2() [all …]
|
/linux-3.4.99/net/netfilter/ipvs/ |
D | ip_vs_xmit.c | 400 int mtu; in ip_vs_bypass_xmit() local 409 mtu = dst_mtu(&rt->dst); in ip_vs_bypass_xmit() 410 if ((skb->len > mtu) && (iph->frag_off & htons(IP_DF)) && in ip_vs_bypass_xmit() 413 icmp_send(skb, ICMP_DEST_UNREACH,ICMP_FRAG_NEEDED, htonl(mtu)); in ip_vs_bypass_xmit() 455 int mtu; in ip_vs_bypass_xmit_v6() local 464 mtu = dst_mtu(&rt->dst); in ip_vs_bypass_xmit_v6() 465 if (skb->len > mtu && !skb_is_gso(skb)) { in ip_vs_bypass_xmit_v6() 471 icmpv6_send(skb, ICMPV6_PKT_TOOBIG, 0, mtu); in ip_vs_bypass_xmit_v6() 517 int mtu; in ip_vs_nat_xmit() local 567 mtu = dst_mtu(&rt->dst); in ip_vs_nat_xmit() [all …]
|
/linux-3.4.99/net/sched/ |
D | sch_teql.c | 203 dev->mtu < m->dev->mtu) in teql_qdisc_init() 212 if (dev->mtu < m->dev->mtu) in teql_qdisc_init() 213 m->dev->mtu = dev->mtu; in teql_qdisc_init() 220 m->dev->mtu = dev->mtu; in teql_qdisc_init() 370 int mtu = 0xFFFE; in teql_master_open() local 385 if (slave->mtu < mtu) in teql_master_open() 386 mtu = slave->mtu; in teql_master_open() 402 m->dev->mtu = mtu; in teql_master_open() 437 if (new_mtu > qdisc_dev(q)->mtu) in teql_master_mtu() 442 dev->mtu = new_mtu; in teql_master_mtu() [all …]
|
D | sch_tbf.c | 104 u32 mtu; member 169 if (ptoks > (long)q->mtu) in tbf_dequeue() 170 ptoks = q->mtu; in tbf_dequeue() 219 q->ptokens = q->mtu; in tbf_reset() 268 if (ptab->data[n] > qopt->mtu) in tbf_change() 296 q->mtu = qopt->mtu; in tbf_change() 300 q->ptokens = q->mtu; in tbf_change() 360 opt.mtu = q->mtu; in tbf_dump()
|
/linux-3.4.99/include/rdma/ |
D | ib_addr.h | 195 static inline enum ib_mtu iboe_get_mtu(int mtu) in iboe_get_mtu() argument 201 mtu = mtu - IB_GRH_BYTES - IB_BTH_BYTES - 28; in iboe_get_mtu() 203 if (mtu >= ib_mtu_enum_to_int(IB_MTU_4096)) in iboe_get_mtu() 205 else if (mtu >= ib_mtu_enum_to_int(IB_MTU_2048)) in iboe_get_mtu() 207 else if (mtu >= ib_mtu_enum_to_int(IB_MTU_1024)) in iboe_get_mtu() 209 else if (mtu >= ib_mtu_enum_to_int(IB_MTU_512)) in iboe_get_mtu() 211 else if (mtu >= ib_mtu_enum_to_int(IB_MTU_256)) in iboe_get_mtu()
|
/linux-3.4.99/net/ipv4/ |
D | ip_forward.c | 48 static bool ip_exceeds_mtu(const struct sk_buff *skb, unsigned int mtu) in ip_exceeds_mtu() argument 50 if (skb->len <= mtu) in ip_exceeds_mtu() 53 if (skb_is_gso(skb) && skb_gso_network_seglen(skb) <= mtu) in ip_exceeds_mtu() 61 unsigned int mtu; in ip_gso_exceeds_dst_mtu() local 66 mtu = dst_mtu(skb_dst(skb)); in ip_gso_exceeds_dst_mtu() 72 return skb_gso_network_seglen(skb) > mtu; in ip_gso_exceeds_dst_mtu()
|
D | xfrm4_output.c | 23 int mtu, ret = 0; in xfrm4_tunnel_check_size() local 33 mtu = dst_mtu(dst); in xfrm4_tunnel_check_size() 34 if (skb->len > mtu) { in xfrm4_tunnel_check_size() 37 inet_sk(skb->sk)->inet_dport, mtu); in xfrm4_tunnel_check_size() 40 ICMP_FRAG_NEEDED, htonl(mtu)); in xfrm4_tunnel_check_size()
|
D | ip_gre.c | 422 dev->mtu = ipgre_tunnel_bind_dev(dev); in ipgre_tunnel_locate() 712 int mtu; in ipgre_tunnel_xmit() local 798 mtu = dst_mtu(&rt->dst) - dev->hard_header_len - tunnel->hlen; in ipgre_tunnel_xmit() 800 mtu = skb_dst(skb) ? dst_mtu(skb_dst(skb)) : dev->mtu; in ipgre_tunnel_xmit() 803 skb_dst(skb)->ops->update_pmtu(skb_dst(skb), mtu); in ipgre_tunnel_xmit() 809 mtu < ntohs(old_iph->tot_len)) { in ipgre_tunnel_xmit() 810 icmp_send(skb, ICMP_DEST_UNREACH, ICMP_FRAG_NEEDED, htonl(mtu)); in ipgre_tunnel_xmit() 819 if (rt6 && mtu < dst_mtu(skb_dst(skb)) && mtu >= IPV6_MIN_MTU) { in ipgre_tunnel_xmit() 824 dst_metric_set(skb_dst(skb), RTAX_MTU, mtu); in ipgre_tunnel_xmit() 828 if (mtu >= IPV6_MIN_MTU && mtu < skb->len - tunnel->hlen + gre_hlen) { in ipgre_tunnel_xmit() [all …]
|
D | ip_output.c | 228 skb_dst(skb)->dev->mtu : dst_mtu(skb_dst(skb)); in ip_skb_dst_mtu() 465 unsigned int mtu, hlen, left, len, ll_rs; in ip_fragment() local 492 mtu = dst_mtu(&rt->dst) - hlen; /* Size of data space */ in ip_fragment() 495 mtu -= nf_bridge_mtu_reduction(skb); in ip_fragment() 510 if (first_len - hlen > mtu || in ip_fragment() 518 if (frag->len > mtu || in ip_fragment() 627 if (len > mtu) in ip_fragment() 628 len = mtu; in ip_fragment() 814 int mtu; in __ip_append_data() local 825 mtu = cork->fragsize; in __ip_append_data() [all …]
|
/linux-3.4.99/drivers/net/hamradio/ |
D | mkiss.c | 64 int mtu; /* Our mtu (to spot changes!) */ member 373 len = dev->mtu * 2; in ax_changedmtu() 390 dev->mtu = ax->mtu; in ax_changedmtu() 424 ax->mtu = dev->mtu + 73; in ax_changedmtu() 440 if (ax->mtu != ax->dev->mtu + 73) /* Someone has been ifconfigging */ in ax_encaps() 443 if (len > ax->mtu) { /* Sigh, shouldn't occur BUT ... */ in ax_encaps() 444 len = ax->mtu; in ax_encaps() 618 len = dev->mtu * 2; in ax_open() 634 ax->mtu = dev->mtu + 73; in ax_open() 681 dev->mtu = AX_MTU; in ax_setup() [all …]
|
/linux-3.4.99/drivers/net/ethernet/ibm/emac/ |
D | core.h | 64 static inline int emac_rx_size(int mtu) in emac_rx_size() argument 66 if (mtu > ETH_DATA_LEN) in emac_rx_size() 78 static inline int emac_rx_skb_size(int mtu) in emac_rx_skb_size() argument 80 int size = max(mtu + EMAC_MTU_OVERHEAD, emac_rx_size(mtu)); in emac_rx_skb_size() 85 static inline int emac_rx_sync_size(int mtu) in emac_rx_sync_size() argument 87 return EMAC_DMA_ALIGN(emac_rx_size(mtu) + 2); in emac_rx_sync_size()
|
/linux-3.4.99/net/caif/ |
D | chnl_net.c | 222 if (skb->len > priv->netdev->mtu) { in chnl_net_start_xmit() 262 int llifindex, headroom, tailroom, mtu; in chnl_net_open() local 303 mtu = min_t(int, dev->mtu, lldev->mtu - (headroom + tailroom)); in chnl_net_open() 304 mtu = min_t(int, GPRS_PDP_MTU, mtu); in chnl_net_open() 305 dev_set_mtu(dev, mtu); in chnl_net_open() 308 if (mtu < 100) { in chnl_net_open() 309 pr_warn("CAIF Interface MTU too small (%d)\n", mtu); in chnl_net_open() 404 dev->mtu = GPRS_PDP_MTU; in ipcaif_net_setup()
|
/linux-3.4.99/drivers/net/ethernet/mellanox/mlx4/ |
D | port.c | 607 u16 mtu, prev_mtu; in mlx4_common_set_port() local 648 mtu = be16_to_cpu(gen_context->mtu); in mlx4_common_set_port() 649 mtu = min_t(int, mtu, dev->caps.eth_mtu_cap[port]); in mlx4_common_set_port() 650 prev_mtu = slave_st->mtu[port]; in mlx4_common_set_port() 651 slave_st->mtu[port] = mtu; in mlx4_common_set_port() 652 if (mtu > master->max_mtu[port]) in mlx4_common_set_port() 653 master->max_mtu[port] = mtu; in mlx4_common_set_port() 654 if (mtu < prev_mtu && prev_mtu == in mlx4_common_set_port() 656 slave_st->mtu[port] = mtu; in mlx4_common_set_port() 657 master->max_mtu[port] = mtu; in mlx4_common_set_port() [all …]
|
/linux-3.4.99/net/ieee802154/ |
D | raw.c | 109 unsigned mtu; in raw_sendmsg() local 132 mtu = dev->mtu; in raw_sendmsg() 133 pr_debug("name = %s, mtu = %u\n", dev->name, mtu); in raw_sendmsg() 135 if (size > mtu) { in raw_sendmsg() 136 pr_debug("size = %Zu, mtu = %u\n", size, mtu); in raw_sendmsg()
|
/linux-3.4.99/net/bridge/ |
D | br_if.c | 284 int mtu = 0; in br_min_mtu() local 289 mtu = ETH_DATA_LEN; in br_min_mtu() 292 if (!mtu || p->dev->mtu < mtu) in br_min_mtu() 293 mtu = p->dev->mtu; in br_min_mtu() 296 return mtu; in br_min_mtu()
|
/linux-3.4.99/drivers/net/ethernet/chelsio/cxgb3/ |
D | xgmac.c | 337 static int rx_fifo_hwm(int mtu) in rx_fifo_hwm() argument 341 hwm = max(MAC_RXFIFO_SIZE - 3 * mtu, (MAC_RXFIFO_SIZE * 38) / 100); in rx_fifo_hwm() 345 int t3_mac_set_mtu(struct cmac *mac, unsigned int mtu) in t3_mac_set_mtu() argument 356 mtu += 14; in t3_mac_set_mtu() 357 if (mtu > 1536) in t3_mac_set_mtu() 358 mtu += 4; in t3_mac_set_mtu() 360 if (mtu > MAX_FRAME_SIZE - 4) in t3_mac_set_mtu() 362 t3_write_reg(adap, A_XGM_RX_MAX_PKT_SIZE + mac->offset, mtu); in t3_mac_set_mtu() 383 V_RXMAXPKTSIZE(mtu)); in t3_mac_set_mtu() 389 V_RXMAXPKTSIZE(mtu)); in t3_mac_set_mtu() [all …]
|
/linux-3.4.99/net/openvswitch/ |
D | vport-netdev.c | 156 int mtu = netdev_vport->dev->mtu; in netdev_send() local 159 if (unlikely(packet_length(skb) > mtu && !skb_is_gso(skb))) { in netdev_send() 162 ovs_dp_name(vport->dp), packet_length(skb), mtu); in netdev_send()
|
/linux-3.4.99/drivers/staging/wlan-ng/ |
D | p80211conv.c | 367 if (payload_length > (netdev->mtu + WLAN_ETHHDR_LEN)) { in skb_p80211_to_ether() 371 payload_length, netdev->mtu + WLAN_ETHHDR_LEN); in skb_p80211_to_ether() 396 if (payload_length > netdev->mtu) { in skb_p80211_to_ether() 400 payload_length, netdev->mtu); in skb_p80211_to_ether() 428 > netdev->mtu) { in skb_p80211_to_ether() 434 sizeof(struct wlan_snap)), netdev->mtu); in skb_p80211_to_ether() 463 if (payload_length > netdev->mtu) { in skb_p80211_to_ether() 467 payload_length, netdev->mtu); in skb_p80211_to_ether()
|
/linux-3.4.99/drivers/net/ethernet/cisco/enic/ |
D | enic_res.c | 69 GET_CONFIG(mtu); in enic_get_vnic_config() 87 if (c->mtu == 0) in enic_get_vnic_config() 88 c->mtu = 1500; in enic_get_vnic_config() 89 c->mtu = min_t(u16, ENIC_MAX_MTU, in enic_get_vnic_config() 91 c->mtu)); in enic_get_vnic_config() 98 enic->mac_addr, c->wq_desc_count, c->rq_desc_count, c->mtu); in enic_get_vnic_config()
|
/linux-3.4.99/drivers/net/ethernet/neterion/vxge/ |
D | vxge-main.h | 93 #define TTI_T1A_TX_UFC_C(mtu) (60 + ((VXGE_HW_MAX_MTU - mtu) / 93)) argument 97 #define TTI_T1A_TX_UFC_D(mtu) (100 + ((VXGE_HW_MAX_MTU - mtu) / 37)) argument 126 #define VXGE_LL_MAX_FRAME_SIZE(dev) ((dev)->mtu + VXGE_HW_MAC_HEADER_MAX_SIZE) 391 int mtu; member
|
/linux-3.4.99/drivers/net/slip/ |
D | slip.c | 128 static int sl_alloc_bufs(struct slip *sl, int mtu) in sl_alloc_bufs() argument 146 len = mtu * 2; in sl_alloc_bufs() 175 sl->mtu = mtu; in sl_alloc_bufs() 219 static int sl_realloc_bufs(struct slip *sl, int mtu) argument 227 int len = mtu * 2; 249 if (mtu > sl->mtu) { 286 sl->mtu = mtu; 287 dev->mtu = mtu; 379 if (len > sl->mtu) { /* Sigh, shouldn't occur BUT ... */ 553 if (new_mtu != dev->mtu) [all …]
|
/linux-3.4.99/drivers/net/wan/ |
D | z85230.c | 797 c->mtu = dev->mtu+64; in z8530_sync_open() 863 c->mtu = dev->mtu+64; in z8530_sync_dma_open() 879 if(c->mtu > PAGE_SIZE/2) in z8530_sync_dma_open() 943 set_dma_count(c->rxdma, c->mtu); in z8530_sync_dma_open() 1058 c->mtu = dev->mtu+64; in z8530_sync_txdma_open() 1069 if(c->mtu > PAGE_SIZE/2) in z8530_sync_txdma_open() 1403 c->mtu=1500; in z8530_channel_load() 1602 ct=c->mtu-get_dma_residue(c->rxdma); in z8530_rx_done() 1617 set_dma_count(c->rxdma, c->mtu); in z8530_rx_done() 1670 c->max = c->mtu; in z8530_rx_done() [all …]
|