coresight: Re-use same function for similar sysfs register accessors
authorJames Clark <james.clark@arm.com>
Tue, 30 Aug 2022 17:26:11 +0000 (18:26 +0100)
committerMathieu Poirier <mathieu.poirier@linaro.org>
Wed, 31 Aug 2022 16:55:28 +0000 (10:55 -0600)
commit08e9fa5f3663eaab20ea3430023d1dfbf60d29f5
tree6af73141bab067c0afe70892410597f342a60d32
parentb6df1cbb415e543f2908f9c59a8fb20714b86879
coresight: Re-use same function for similar sysfs register accessors

Currently each accessor macro creates an identical function which wastes
space in the text area and pollutes the ftrace function names. Change it
so that the same function is used, but the register to access is passed
in as parameter rather than baked into each function.

Signed-off-by: James Clark <james.clark@arm.com>
Reviewed-by: Mike Leach <mike.leach@linaro.org>
Link: https://lore.kernel.org/r/20220830172614.340962-4-james.clark@arm.com
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
drivers/hwtracing/coresight/coresight-catu.c
drivers/hwtracing/coresight/coresight-core.c
drivers/hwtracing/coresight/coresight-etb10.c
drivers/hwtracing/coresight/coresight-etm3x-sysfs.c
drivers/hwtracing/coresight/coresight-priv.h
drivers/hwtracing/coresight/coresight-replicator.c
drivers/hwtracing/coresight/coresight-stm.c
drivers/hwtracing/coresight/coresight-tmc-core.c