summaryrefslogtreecommitdiff
path: root/kernel/sysctl_binary.c
diff options
context:
space:
mode:
authorAlex Williamson <alex.williamson@redhat.com>2020-10-19 07:13:55 -0600
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-10-29 09:03:07 +0100
commit07851a08d88166bb0339e954c05f150f08758407 (patch)
tree1d49427da9427bf697c3f99fea25cae47684d11b /kernel/sysctl_binary.c
parent1a978f44688d1aca08a29982166341880ee9b5e4 (diff)
vfio/pci: Clear token on bypass registration failure
[ Upstream commit 852b1beecb6ff9326f7ca4bc0fe69ae860ebdb9e ] The eventfd context is used as our irqbypass token, therefore if an eventfd is re-used, our token is the same. The irqbypass code will return an -EBUSY in this case, but we'll still attempt to unregister the producer, where if that duplicate token still exists, results in removing the wrong object. Clear the token of failed producers so that they harmlessly fall out when unregistered. Fixes: 6d7425f109d2 ("vfio: Register/unregister irq_bypass_producer") Reported-by: guomin chen <guomin_chen@sina.com> Tested-by: guomin chen <guomin_chen@sina.com> Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'kernel/sysctl_binary.c')
0 files changed, 0 insertions, 0 deletions