diff options
| author | Hangbin Liu <[email protected]> | 2025-09-05 09:15:33 +0000 |
|---|---|---|
| committer | Paolo Abeni <[email protected]> | 2025-09-11 09:49:19 +0000 |
| commit | 847748fc66d08a89135a74e29362a66ba4e3ab15 (patch) | |
| tree | 7ea317895bccd7085aea1b15fbc5aea0aa9fac97 /drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | |
| parent | hsr: use hsr_for_each_port_rtnl in hsr_port_get_hsr (diff) | |
| download | kernel-847748fc66d08a89135a74e29362a66ba4e3ab15.tar.gz kernel-847748fc66d08a89135a74e29362a66ba4e3ab15.zip | |
hsr: hold rcu and dev lock for hsr_get_port_ndev
hsr_get_port_ndev calls hsr_for_each_port, which need to hold rcu lock.
On the other hand, before return the port device, we need to hold the
device reference to avoid UaF in the caller function.
Suggested-by: Paolo Abeni <[email protected]>
Fixes: 9c10dd8eed74 ("net: hsr: Create and export hsr_get_port_ndev()")
Signed-off-by: Hangbin Liu <[email protected]>
Reviewed-by: Simon Horman <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Paolo Abeni <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c')
0 files changed, 0 insertions, 0 deletions
