| .. | .. |
|---|
| 1136 | 1136 | eth_hdr_len = ntohs(skb->protocol) == ETH_P_8021Q ? |
|---|
| 1137 | 1137 | VLAN_ETH_HLEN : ETH_HLEN; |
|---|
| 1138 | 1138 | if (skb->len <= 60 && |
|---|
| 1139 | | - (lancer_chip(adapter) || skb_vlan_tag_present(skb)) && |
|---|
| 1140 | | - is_ipv4_pkt(skb)) { |
|---|
| 1139 | + (lancer_chip(adapter) || BE3_chip(adapter) || |
|---|
| 1140 | + skb_vlan_tag_present(skb)) && is_ipv4_pkt(skb)) { |
|---|
| 1141 | 1141 | ip = (struct iphdr *)ip_hdr(skb); |
|---|
| 1142 | | - pskb_trim(skb, eth_hdr_len + ntohs(ip->tot_len)); |
|---|
| 1142 | + if (unlikely(pskb_trim(skb, eth_hdr_len + ntohs(ip->tot_len)))) |
|---|
| 1143 | + goto tx_drop; |
|---|
| 1143 | 1144 | } |
|---|
| 1144 | 1145 | |
|---|
| 1145 | 1146 | /* If vlan tag is already inlined in the packet, skip HW VLAN |
|---|