aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/event_analyzing_sample.py
diff options
context:
space:
mode:
authorNuno Sá <[email protected]>2022-07-15 14:28:49 +0200
committerJonathan Cameron <[email protected]>2022-08-15 22:29:59 +0100
commit79c3e84874c7d14f04ad58313b64955a0d2e9437 (patch)
treeb2bf89e1c5d74bb8b719ba32b99cea8771d9f1b8 /tools/perf/scripts/python/event_analyzing_sample.py
parent15b2ac67859006bace228cbdc8607d0ea0af4e89 (diff)
iio: inkern: only release the device node when done with it
'of_node_put()' can potentially release the memory pointed to by 'iiospec.np' which would leave us with an invalid pointer (and we would still pass it in 'of_xlate()'). Note that it is not guaranteed for the of_node lifespan to be attached to the device (to which is attached) lifespan so that there is (even though very unlikely) the possibility for the node to be freed while the device is still around. Thus, as there are indeed some of_xlate users which do access the node, a race is indeed possible. As such, we can only release the node after we are done with it. Fixes: 17d82b47a215d ("iio: Add OF support") Signed-off-by: Nuno Sá <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jonathan Cameron <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/event_analyzing_sample.py')
0 files changed, 0 insertions, 0 deletions