Commit cfe2a4ca authored by Stephane Grosjean's avatar Stephane Grosjean Committed by Marc Kleine-Budde

can: peak_usb: pcan_usb_pro_encode_msg(): use macros for flags instead of plain integers

This patch replaces the plain integers used for flags in
pcan_usb_pro_encode_msg() by macros which are already defined.

Link: https://lore.kernel.org/r/20210309082128.23125-4-s.grosjean@peak-system.comSigned-off-by: default avatarStephane Grosjean <s.grosjean@peak-system.com>
[mkl: split into two patches]
Signed-off-by: default avatarMarc Kleine-Budde <mkl@pengutronix.de>
parent 27868a8f
......@@ -776,9 +776,9 @@ static int pcan_usb_pro_encode_msg(struct peak_usb_device *dev,
flags = 0;
if (cf->can_id & CAN_EFF_FLAG)
flags |= 0x02;
flags |= PCAN_USBPRO_EXT;
if (cf->can_id & CAN_RTR_FLAG)
flags |= 0x01;
flags |= PCAN_USBPRO_RTR;
pcan_msg_add_rec(&usb_msg, data_type, 0, flags, len, cf->can_id,
cf->data);
......
Markdown is supported
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