Lines Matching refs:can
23 #include <linux/can/core.h>
24 #include <linux/can/dev.h>
229 struct can_priv can;
810 priv->can.state = CAN_STATE_ERROR_ACTIVE;
812 if (priv->can.restart_ms == 0)
834 if (priv->can.ctrlmode & CAN_CTRLMODE_LOOPBACK) {
837 } else if (priv->can.ctrlmode & CAN_CTRLMODE_LISTENONLY) {
853 priv->can.state = CAN_STATE_ERROR_ACTIVE;
860 struct can_bittiming *bt = &priv->can.bittiming;
866 (priv->can.ctrlmode & CAN_CTRLMODE_3_SAMPLES ?
970 priv->can.state = CAN_STATE_STOPPED;
1002 if (priv->can.state == CAN_STATE_BUS_OFF) {
1116 /* Update can state */
1140 /* Update can state statistics */
1141 switch (priv->can.state) {
1145 priv->can.can_stats.error_warning++;
1150 priv->can.can_stats.error_passive++;
1155 priv->can.state = new_state;
1174 if (priv->can.state == CAN_STATE_BUS_OFF) {
1175 if (priv->can.restart_ms == 0) {
1177 priv->can.can_stats.bus_off++;
1323 /* Allocate can/net device */
1337 priv->can.bittiming_const = &mcp251x_bittiming_const;
1338 priv->can.do_set_mode = mcp251x_do_set_mode;
1339 priv->can.clock.freq = freq / 2;
1340 priv->can.ctrlmode_supported = CAN_CTRLMODE_3_SAMPLES |