summaryrefslogtreecommitdiff
path: root/net/dccp
diff options
context:
space:
mode:
authorZhang Changzhong <zhangchangzhong@huawei.com>2020-08-05 11:50:24 +0800
committerMarc Kleine-Budde <mkl@pengutronix.de>2020-08-15 11:12:58 +0200
commit2b8b2e31555cf55ba3680fb28e2b382e168d7ea1 (patch)
tree097e5daa664b45d03ae26b5dfb9c1c475f6d35d0 /net/dccp
parente8b17653088f28a87c81845fa41a2d295a3b458c (diff)
can: j1939: abort multipacket broadcast session when timeout occurs
If timeout occurs, j1939_tp_rxtimer() first calls hrtimer_start() to restart rxtimer, and then calls __j1939_session_cancel() to set session->state = J1939_SESSION_WAITING_ABORT. At next timeout expiration, because of the J1939_SESSION_WAITING_ABORT session state j1939_tp_rxtimer() will call j1939_session_deactivate_activate_next() to deactivate current session, and rxtimer won't be set. But for multipacket broadcast session, __j1939_session_cancel() don't set session->state = J1939_SESSION_WAITING_ABORT, thus current session won't be deactivate and hrtimer_start() is called to start new rxtimer again and again. So fix it by moving session->state = J1939_SESSION_WAITING_ABORT out of if (!j1939_cb_is_broadcast(&session->skcb)) statement. Fixes: 9d71dd0c7009 ("can: add support of SAE J1939 protocol") Signed-off-by: Zhang Changzhong <zhangchangzhong@huawei.com> Link: https://lore.kernel.org/r/1596599425-5534-4-git-send-email-zhangchangzhong@huawei.com Acked-by: Oleksij Rempel <o.rempel@pengutronix.de> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'net/dccp')
0 files changed, 0 insertions, 0 deletions