summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-postgresql.py
diff options
context:
space:
mode:
authorMd Haris Iqbal <haris.iqbal@cloud.ionos.com>2020-08-11 12:27:22 +0300
committerJason Gunthorpe <jgg@nvidia.com>2020-08-24 19:44:53 +0300
commitbaa5b28b7a474f66a511ebf71a2ade510652a2f6 (patch)
tree1eeebe9d40c079bbbca4c8b5824f986f95420d33 /tools/perf/scripts/python/export-to-postgresql.py
parentd012a7190fc1fd72ed48911e77ca97ba4521bccd (diff)
downloadlinux-baa5b28b7a474f66a511ebf71a2ade510652a2f6.tar.xz
RDMA/rtrs-srv: Replace device_register with device_initialize and device_add
There are error cases when we will call free_srv before device kobject is initialized; in such cases calling put_device generates the following warning: kobject: '(null)' (000000009f5445ed): is not initialized, yet kobject_put() is being called. So call device_initialize() only once when the server is allocated. If we end up calling put_srv() and subsequently free_srv(), our call to put_device() would result in deletion of the obj. Call device_add() later when we actually have a connection. Correspondingly, call device_del() instead of device_unregister() when srv->dev_ref falls to 0. Fixes: 9cb837480424 ("RDMA/rtrs: server: main functionality") Link: https://lore.kernel.org/r/20200811092722.2450-1-haris.iqbal@cloud.ionos.com Suggested-by: Jason Gunthorpe <jgg@nvidia.com> Signed-off-by: Md Haris Iqbal <haris.iqbal@cloud.ionos.com> Reviewed-by: Jack Wang <jinpu.wang@cloud.ionos.com> Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions