diff options
author | Julian Wiedmann | 2019-08-12 16:44:35 +0200 |
---|---|---|
committer | Jakub Kicinski | 2019-08-14 04:26:47 +0200 |
commit | 072f79400032f74917726cf76f4248367ea2b5b8 (patch) | |
tree | 7e4f8f96847681fe921c7f38067c464c8a2f4498 /init | |
parent | sctp: fix the transport error_count check (diff) | |
download | kernel-qcow2-linux-072f79400032f74917726cf76f4248367ea2b5b8.tar.gz kernel-qcow2-linux-072f79400032f74917726cf76f4248367ea2b5b8.tar.xz kernel-qcow2-linux-072f79400032f74917726cf76f4248367ea2b5b8.zip |
s390/qeth: serialize cmd reply with concurrent timeout
Callbacks for a cmd reply run outside the protection of card->lock, to
allow for additional cmds to be issued & enqueued in parallel.
When qeth_send_control_data() bails out for a cmd without having
received a reply (eg. due to timeout), its callback may concurrently be
processing a reply that just arrived. In this case, the callback
potentially accesses a stale reply->reply_param area that eg. was
on-stack and has already been released.
To avoid this race, add some locking so that qeth_send_control_data()
can (1) wait for a concurrently running callback, and (2) zap any
pending callback that still wants to run.
Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Diffstat (limited to 'init')
0 files changed, 0 insertions, 0 deletions