kdbus: don't unlink synchronous replies 79/264879/2
authorAdrian Szyndela <adrian.s@samsung.com>
Thu, 30 Sep 2021 06:44:57 +0000 (15:44 +0900)
committerAdrian Szyndela <adrian.s@samsung.com>
Fri, 8 Oct 2021 07:19:41 +0000 (09:19 +0200)
commitf36833053065e3e607e747d40f81cead512565a3
treeb6fff552b2461c5b44719a0314eb81d43801d510
parentcec42e0a4e9704d1f428e96cb4f5e1902a6e2b11
kdbus: don't unlink synchronous replies

When a signal breaks a synchronous call, and a reply is received
before restart is executed, then the reply is unlinked and the restarted
call can't pick it up anymore.

But keeping only interrupted synchronous calls linked is not enough.
If a reply comes just after the signal, before marking the reply structure
as interrupted, then the reply is - again - unlinked and the restarted call
can't pick it up anymore.

This commit leaves all synchronous replies linked.

This way:
- asynchronous calls work as before the changes - replies are unlinked
  by the replier in kdbus_conn_reply();
- replies for synchronous calls are unlinked by the caller in
  kdbus_conn_wait_reply().

Change-Id: I0e3d8f53cf24a0aa8c59244e0768eebeb3fee110
Signed-off-by: Adrian Szyndela <adrian.s@samsung.com>
ipc/kdbus/connection.c