]> git.baikalelectronics.ru Git - kernel.git/commit
nfc: port100: handle command failure cleanly
authorOliver Neukum <oneukum@suse.com>
Thu, 21 Nov 2019 10:37:10 +0000 (11:37 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 21 Nov 2019 19:48:17 +0000 (11:48 -0800)
commitbcac2bd254fcd20753b0d28d153ec3a67255ac9b
treebe2351a27135d97fbc97c2ad6bbce0b5de08c8ca
parent7d90902e6cc706b83631b803548adbe2355aab1c
nfc: port100: handle command failure cleanly

If starting the transfer of a command suceeds but the transfer for the reply
fails, it is not enough to initiate killing the transfer for the
command may still be running. You need to wait for the killing to finish
before you can reuse URB and buffer.

Reported-and-tested-by: syzbot+711468aa5c3a1eabf863@syzkaller.appspotmail.com
Signed-off-by: Oliver Neukum <oneukum@suse.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/nfc/port100.c