615c164da0
Introduces a concept of external buffers, which is a mechanism for creating trace sinks that would receive trace data from MSC buffers and transfer it elsewhere. A external buffer can implement its own window allocation/deallocation if it has to. It must provide a callback that's used to notify it when a window fills up, so that it can then start a DMA transaction from that window 'elsewhere'. This window remains in a 'locked' state and won't be used for storing new trace data until the buffer 'unlocks' it with a provided API call, at which point the window can be used again for storing trace data. This relies on a functional "last block" interrupt, so not all versions of Trace Hub can use this feature, which does not reflect on existing users. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20190705141425.19894-2-alexander.shishkin@linux.intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
43 lines
1.8 KiB
Plaintext
43 lines
1.8 KiB
Plaintext
What: /sys/bus/intel_th/devices/<intel_th_id>-msc<msc-id>/wrap
|
|
Date: June 2015
|
|
KernelVersion: 4.3
|
|
Contact: Alexander Shishkin <alexander.shishkin@linux.intel.com>
|
|
Description: (RW) Configure MSC buffer wrapping. 1 == wrapping enabled.
|
|
|
|
What: /sys/bus/intel_th/devices/<intel_th_id>-msc<msc-id>/mode
|
|
Date: June 2015
|
|
KernelVersion: 4.3
|
|
Contact: Alexander Shishkin <alexander.shishkin@linux.intel.com>
|
|
Description: (RW) Configure MSC operating mode:
|
|
- "single", for contiguous buffer mode (high-order alloc);
|
|
- "multi", for multiblock mode;
|
|
- "ExI", for DCI handler mode;
|
|
- "debug", for debug mode;
|
|
- any of the currently loaded buffer sinks.
|
|
If operating mode changes, existing buffer is deallocated,
|
|
provided there are no active users and tracing is not enabled,
|
|
otherwise the write will fail.
|
|
|
|
What: /sys/bus/intel_th/devices/<intel_th_id>-msc<msc-id>/nr_pages
|
|
Date: June 2015
|
|
KernelVersion: 4.3
|
|
Contact: Alexander Shishkin <alexander.shishkin@linux.intel.com>
|
|
Description: (RW) Configure MSC buffer size for "single" or "multi" modes.
|
|
In single mode, this is a single number of pages, has to be
|
|
power of 2. In multiblock mode, this is a comma-separated list
|
|
of numbers of pages for each window to be allocated. Number of
|
|
windows is not limited.
|
|
Writing to this file deallocates existing buffer (provided
|
|
there are no active users and tracing is not enabled) and then
|
|
allocates a new one.
|
|
|
|
What: /sys/bus/intel_th/devices/<intel_th_id>-msc<msc-id>/win_switch
|
|
Date: May 2019
|
|
KernelVersion: 5.2
|
|
Contact: Alexander Shishkin <alexander.shishkin@linux.intel.com>
|
|
Description: (RW) Trigger window switch for the MSC's buffer, in
|
|
multi-window mode. In "multi" mode, accepts writes of "1", thereby
|
|
triggering a window switch for the buffer. Returns an error in any
|
|
other operating mode or attempts to write something other than "1".
|
|
|