]> git.baikalelectronics.ru Git - kernel.git/commit
can: j1939: add rxtimer for multipacket broadcast session
authorZhang Changzhong <zhangchangzhong@huawei.com>
Wed, 5 Aug 2020 03:50:25 +0000 (11:50 +0800)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Sat, 15 Aug 2020 09:12:58 +0000 (11:12 +0200)
commitcfa7a830ccbc0b349acb780aa926b22aae67f7ff
treec7c9ee5d7a422183dedcd4e6b3c6f6941cdff7d2
parentb111752fd01b188a85da9845b373bda28de9d1ac
can: j1939: add rxtimer for multipacket broadcast session

According to SAE J1939/21 (Chapter 5.12.3 and APPENDIX C), for transmit side
the required time interval between packets of a multipacket broadcast message
is 50 to 200 ms, the responder shall use a timeout of 250ms (provides margin
allowing for the maximumm spacing of 200ms). For receive side a timeout will
occur when a time of greater than 750 ms elapsed between two message packets
when more packets were expected.

So this patch fix and add rxtimer for multipacket broadcast session.

Fixes: 877b9bba3266 ("can: add support of SAE J1939 protocol")
Signed-off-by: Zhang Changzhong <zhangchangzhong@huawei.com>
Link: https://lore.kernel.org/r/1596599425-5534-5-git-send-email-zhangchangzhong@huawei.com
Acked-by: Oleksij Rempel <o.rempel@pengutronix.de>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
net/can/j1939/transport.c