Commit 5e805bb5 authored by Pavel Pisa's avatar Pavel Pisa
Browse files

driver: received extended frame has to be marked by CAN_EFF_FLAG.



Signed-off-by: Pavel Pisa's avatarPavel Pisa <pisa@cmp.felk.cvut.cz>
parent 277bc91d
Pipeline #38995 failed with stage
in 1 minute and 7 seconds
......@@ -682,7 +682,11 @@ static void ctucan_read_rx_frame(struct ctucan_priv *priv, struct canfd_frame *c
unsigned int len;
idw = ctucan_read32(priv, CTUCANFD_RX_DATA);
cf->can_id = (FIELD_GET(REG_FRAME_FORMAT_W_IDE, ffw)) ? idw : ((idw >> 18) & CAN_SFF_MASK);
if (FIELD_GET(REG_FRAME_FORMAT_W_IDE, ffw)) {
cf->can_id = (idw & CAN_EFF_MASK) | CAN_EFF_FLAG;
} else {
cf->can_id = (idw >> 18) & CAN_SFF_MASK;
}
/* BRS, ESI, RTR Flags */
cf->flags = 0;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment