[PATCH v2] coresight: trbe: Hide enable_sink sysfs file

James Clark james.clark at linaro.org
Tue Aug 11 02:10:53 PDT 2026



On 11/08/2026 10:04, Leo Yan wrote:
> On Fri, Aug 07, 2026 at 11:13:22AM +0100, James Clark wrote:
>> TRBE doesn't support sysfs mode, but the enable_sink file can still be
>> successfully written to enable the device, and only attempting to enable
>> the source would later fail.
>>
>> Avoid misleading users by adding a flag that devices can use to hide
>> either the enable_sink or enable_source files, and set it for TRBE.
>>
>> Don't set it for ETE as it's possible that ETE could appear on the
>> legacy bus and work with sysfs, and writing to enable_source already
>> reports EINVAL if the device doesn't support sysfs mode.
> 
> It is a pity that we cannot determine from the ETE registers whether ETE
> is connected to the legacy bus or TRBE.
> 

We could determine it from the device tree. A path has to be built or 
you can't use it on the legacy bus either. Maybe we can do a more 
general change in the future to hide the flag for any non-connected CPU 
source.

>> Signed-off-by: James Clark <james.clark at linaro.org>
> 
> Reviewed-by: Leo Yan <leo.yan at arm.com>




More information about the linux-arm-kernel mailing list