mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-23 07:12:09 +00:00
rxrpc: Fix call timer
Fix the call timer in the following ways: (1) If call->resend_at or call->ack_at are before or equal to the current time, then ignore that timeout. (2) If call->expire_at is before or equal to the current time, then don't set the timer at all (possibly we should queue the call). (3) Don't skip modifying the timer if timer_pending() is true. This indicates that the timer is working, not that it has expired and is running/waiting to run its expiry handler. Also call rxrpc_set_timer() to start the call timer going rather than calling add_timer(). Signed-off-by: David Howells <dhowells@redhat.com>
This commit is contained in:
parent
be8aa33806
commit
01a88f7f6b
2 changed files with 16 additions and 13 deletions
|
@ -199,8 +199,8 @@ static void rxrpc_start_call_timer(struct rxrpc_call *call)
|
|||
call->expire_at = expire_at;
|
||||
call->ack_at = expire_at;
|
||||
call->resend_at = expire_at;
|
||||
call->timer.expires = expire_at;
|
||||
add_timer(&call->timer);
|
||||
call->timer.expires = expire_at + 1;
|
||||
rxrpc_set_timer(call);
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue