.. | .. |
---|
381 | 381 | } |
---|
382 | 382 | |
---|
383 | 383 | if (hf->flags & GS_CAN_FLAG_OVERFLOW) { |
---|
| 384 | + stats->rx_over_errors++; |
---|
| 385 | + stats->rx_errors++; |
---|
| 386 | + |
---|
384 | 387 | skb = alloc_can_err_skb(netdev, &cf); |
---|
385 | 388 | if (!skb) |
---|
386 | 389 | goto resubmit_urb; |
---|
.. | .. |
---|
388 | 391 | cf->can_id |= CAN_ERR_CRTL; |
---|
389 | 392 | cf->can_dlc = CAN_ERR_DLC; |
---|
390 | 393 | cf->data[1] = CAN_ERR_CRTL_RX_OVERFLOW; |
---|
391 | | - stats->rx_over_errors++; |
---|
392 | | - stats->rx_errors++; |
---|
393 | 394 | netif_rx(skb); |
---|
394 | 395 | } |
---|
395 | 396 | |
---|
.. | .. |
---|
732 | 733 | usb_kill_anchored_urbs(&dev->tx_submitted); |
---|
733 | 734 | atomic_set(&dev->active_tx_urbs, 0); |
---|
734 | 735 | |
---|
| 736 | + dev->can.state = CAN_STATE_STOPPED; |
---|
| 737 | + |
---|
735 | 738 | /* reset the device */ |
---|
736 | 739 | rc = gs_cmd_reset(dev); |
---|
737 | 740 | if (rc < 0) |
---|