diff options
author | Joe Hattori <[email protected]> | 2024-11-26 10:49:09 +0900 |
---|---|---|
committer | Greg Kroah-Hartman <[email protected]> | 2024-12-04 16:25:54 +0100 |
commit | ef42b906df5c57d0719b69419df9dfd25f25c161 (patch) | |
tree | c2ba634e10adbedc4c64f899b338a376f02b5f0e /tools/testing/selftests/bpf/prog_tests/prog_array_init.c | |
parent | 645d56e4cc74e953284809d096532c1955918a28 (diff) |
usb: typec: anx7411: fix OF node reference leaks in anx7411_typec_switch_probe()
The refcounts of the OF nodes obtained by of_get_child_by_name() calls
in anx7411_typec_switch_probe() are not decremented. Replace them with
device_get_named_child_node() calls and store the return values to the
newly created fwnode_handle fields in anx7411_data, and call
fwnode_handle_put() on them in the error path and in the unregister
functions.
Fixes: e45d7337dc0e ("usb: typec: anx7411: Use of_get_child_by_name() instead of of_find_node_by_name()")
Cc: [email protected]
Signed-off-by: Joe Hattori <[email protected]>
Reviewed-by: Heikki Krogerus <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests/prog_array_init.c')
0 files changed, 0 insertions, 0 deletions