mirror of
https://github.com/linux-can/can-utils.git
synced 2026-08-05 06:20:00 +02:00
cangen: update CAN FD check to cope with CAN XL interfaces
The check for CAN FD capable interfaces only checked for CANFD_MTU to enable the generation of CAN FD frame content. As CAN XL capable CAN interfaces are able to handle CAN FD frames too the check has to be extended for CANXL_MTU interfaces. Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
This commit is contained in:
@@ -680,8 +680,8 @@ int main(int argc, char **argv)
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (ifr.ifr_mtu != CANFD_MTU) {
|
||||
printf("CAN interface is not CAN FD capable - sorry.\n");
|
||||
if (ifr.ifr_mtu != CANFD_MTU && ifr.ifr_mtu != CANXL_MTU) {
|
||||
printf("CAN interface is only Classical CAN capable - sorry.\n");
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user