summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorJakub Kicinski <kuba@kernel.org>2022-09-21 23:10:05 +0300
committerJakub Kicinski <kuba@kernel.org>2022-09-22 17:33:17 +0300
commitc31f26c8f69f776759cbbdfb38e40ea91aa0dd65 (patch)
tree3a8a2ac4e7ee88d6dfde72b4b9948c4c2708db81 /tools
parent3aac7ada64d8c26ccc922f1ca966043c0dae88da (diff)
downloadlinux-c31f26c8f69f776759cbbdfb38e40ea91aa0dd65.tar.xz
bnxt: prevent skb UAF after handing over to PTP worker
When reading the timestamp is required bnxt_tx_int() hands over the ownership of the completed skb to the PTP worker. The skb should not be used afterwards, as the worker may run before the rest of our code and free the skb, leading to a use-after-free. Since dev_kfree_skb_any() accepts NULL make the loss of ownership more obvious and set skb to NULL. Fixes: 83bb623c968e ("bnxt_en: Transmit and retrieve packet timestamps") Reviewed-by: Andy Gospodarek <gospo@broadcom.com> Reviewed-by: Michael Chan <michael.chan@broadcom.com> Link: https://lore.kernel.org/r/20220921201005.335390-1-kuba@kernel.org Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'tools')
0 files changed, 0 insertions, 0 deletions