diff options
author | Bjorn Andersson <bjorn.andersson@linaro.org> | 2020-01-13 23:57:02 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-01-14 18:36:42 -0800 |
commit | f16a4b26f31f95dddb12cf3c2390906a735203ae (patch) | |
tree | 88a2188c8fb7fc91d2a41ac4ab6ed5e98acbf304 /tools/perf/scripts/python/bin/export-to-postgresql-report | |
parent | 0a7e0d0ef05440db03c3199e84d228db943b237f (diff) |
net: qrtr: Make qrtr_port_lookup() use RCU
The important part of qrtr_port_lookup() wrt synchronization is that the
function returns a reference counted struct qrtr_sock, or fail.
As such we need only to ensure that an decrement of the object's
refcount happens inbetween the finding of the object in the idr and
qrtr_port_lookup()'s own increment of the object.
By using RCU and putting a synchronization point after we remove the
mapping from the idr, but before it can be released we achieve this -
with the benefit of not having to hold the mutex in qrtr_port_lookup().
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/perf/scripts/python/bin/export-to-postgresql-report')
0 files changed, 0 insertions, 0 deletions