There was an error fetching the commit references. Please try again later.
coresight: Fix CTI module refcount leak by making it a helper device
The CTI module has some hard coded refcounting code that has a leak. For example running perf and then trying to unload it fails: perf record -e cs_etm// -a -- ls rmmod coresight_cti rmmod: ERROR: Module coresight_cti is in use The coresight core already handles references of devices in use, so by making CTI a normal helper device, we get working refcounting for free. Reviewed-by:Mike Leach <mike.leach@linaro.org> Signed-off-by:
James Clark <james.clark@arm.com> Signed-off-by:
Suzuki K Poulose <suzuki.poulose@arm.com> Link: https://lore.kernel.org/r/20230425143542.2305069-14-james.clark@arm.com
Showing
- drivers/hwtracing/coresight/coresight-core.c 41 additions, 75 deletionsdrivers/hwtracing/coresight/coresight-core.c
- drivers/hwtracing/coresight/coresight-cti-core.c 28 additions, 24 deletionsdrivers/hwtracing/coresight/coresight-cti-core.c
- drivers/hwtracing/coresight/coresight-cti-sysfs.c 2 additions, 2 deletionsdrivers/hwtracing/coresight/coresight-cti-sysfs.c
- drivers/hwtracing/coresight/coresight-cti.h 2 additions, 2 deletionsdrivers/hwtracing/coresight/coresight-cti.h
- drivers/hwtracing/coresight/coresight-priv.h 2 additions, 2 deletionsdrivers/hwtracing/coresight/coresight-priv.h
- drivers/hwtracing/coresight/coresight-sysfs.c 4 additions, 0 deletionsdrivers/hwtracing/coresight/coresight-sysfs.c
- include/linux/coresight.h 2 additions, 27 deletionsinclude/linux/coresight.h
Please register or sign in to comment