Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 315711
b: refs/heads/master
c: 88b5870
h: refs/heads/master
i:
  315709: 09ee6f7
  315707: 35cea77
  315703: 492f36c
  315695: c3d259f
  315679: da70f77
  315647: 8df9f2f
v: v3
  • Loading branch information
Ira W. Snyder authored and Marc Kleine-Budde committed Jul 20, 2012
1 parent 161e2aa commit e78ad9f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 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: 9e4d6909a273ada78cf48379e478855bc13ae0cb
refs/heads/master: 88b587039c1ad4e7a981bea3269eeb02a1a2a14b
11 changes: 6 additions & 5 deletions trunk/drivers/net/can/janz-ican3.c
Original file line number Diff line number Diff line change
Expand Up @@ -907,8 +907,8 @@ static void ican3_handle_msglost(struct ican3_dev *mod, struct ican3_msg *msg)
if (skb) {
cf->can_id |= CAN_ERR_CRTL;
cf->data[1] = CAN_ERR_CRTL_RX_OVERFLOW;
stats->rx_over_errors++;
stats->rx_errors++;
stats->rx_bytes += cf->can_dlc;
netif_rx(skb);
}
}
Expand Down Expand Up @@ -982,7 +982,6 @@ static int ican3_handle_cevtind(struct ican3_dev *mod, struct ican3_msg *msg)

dev_dbg(mod->dev, "bus error interrupt\n");
mod->can.can_stats.bus_error++;
stats->rx_errors++;
cf->can_id |= CAN_ERR_PROT | CAN_ERR_BUSERROR;

switch (ecc & ECC_MASK) {
Expand All @@ -1001,8 +1000,12 @@ static int ican3_handle_cevtind(struct ican3_dev *mod, struct ican3_msg *msg)
break;
}

if ((ecc & ECC_DIR) == 0)
if (!(ecc & ECC_DIR)) {
cf->data[2] |= CAN_ERR_PROT_TX;
stats->tx_errors++;
} else {
stats->rx_errors++;
}

cf->data[6] = txerr;
cf->data[7] = rxerr;
Expand All @@ -1028,8 +1031,6 @@ static int ican3_handle_cevtind(struct ican3_dev *mod, struct ican3_msg *msg)
}

mod->can.state = state;
stats->rx_errors++;
stats->rx_bytes += cf->can_dlc;
netif_rx(skb);
return 0;
}
Expand Down

0 comments on commit e78ad9f

Please sign in to comment.