Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 299522
b: refs/heads/master
c: 5c699fb
h: refs/heads/master
v: v3
  • Loading branch information
Tomasz Gregorek authored and David S. Miller committed Apr 13, 2012
1 parent 1a24ac1 commit bb342b2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c9be48dc8bb22f1f6e6ff1560b2b28e925a0b815
refs/heads/master: 5c699fb7d88d360023f3b3f5291cbf5b59883a1b
9 changes: 6 additions & 3 deletions trunk/net/caif/chnl_net.c
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ static int chnl_recv_cb(struct cflayer *layr, struct cfpkt *pkt)
skb->protocol = htons(ETH_P_IPV6);
break;
default:
kfree_skb(skb);
priv->netdev->stats.rx_errors++;
return -EINVAL;
}
Expand Down Expand Up @@ -220,14 +221,16 @@ static int chnl_net_start_xmit(struct sk_buff *skb, struct net_device *dev)

if (skb->len > priv->netdev->mtu) {
pr_warn("Size of skb exceeded MTU\n");
kfree_skb(skb);
dev->stats.tx_errors++;
return -ENOSPC;
return NETDEV_TX_OK;
}

if (!priv->flowenabled) {
pr_debug("dropping packets flow off\n");
kfree_skb(skb);
dev->stats.tx_dropped++;
return NETDEV_TX_BUSY;
return NETDEV_TX_OK;
}

if (priv->conn_req.protocol == CAIFPROTO_DATAGRAM_LOOP)
Expand All @@ -242,7 +245,7 @@ static int chnl_net_start_xmit(struct sk_buff *skb, struct net_device *dev)
result = priv->chnl.dn->transmit(priv->chnl.dn, pkt);
if (result) {
dev->stats.tx_dropped++;
return result;
return NETDEV_TX_OK;
}

/* Update statistics. */
Expand Down

0 comments on commit bb342b2

Please sign in to comment.