]> git.baikalelectronics.ru Git - kernel.git/commit
smc: no consumer update in tasklet context
authorUrsula Braun <ubraun@linux.vnet.ibm.com>
Thu, 7 Dec 2017 12:38:48 +0000 (13:38 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 7 Dec 2017 20:03:12 +0000 (15:03 -0500)
commitc7048887453dc3bbab5919c72894f14a5fa67069
treeadd7c1b65759a1f657da23be97d99b82ef63b3aa
parentc5f15862cf8d4dda9b743d5eeb34d916d233c2b2
smc: no consumer update in tasklet context

The SMC protocol requires to send a separate consumer cursor update,
if it cannot be piggybacked to updates of the producer cursor.
When receiving a blocked signal from the sender, this update is sent
already in tasklet context. In addition consumer cursor updates are
sent after data receival.
Sending of cursor updates is controlled by sequence numbers.
Assuming receiving stray messages the receiver drops updates with older
sequence numbers than an already received cursor update with a higher
sequence number.
Sending consumer cursor updates in tasklet context may result in
wrong order sends and its corresponding drops at the receiver. Since
it is sufficient to send consumer cursor updates once the data is
received, this patch gets rid of the consumer cursor update in tasklet
context to guarantee in-sequence arrival of cursor updates.

Signed-off-by: Ursula Braun <ubraun@linux.vnet.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/smc/smc_cdc.c
net/smc/smc_tx.c