Lines Matching +full:static +full:- +full:trace +full:- +full:id
1 /* SPDX-License-Identifier: GPL-2.0 */
3 * Intel(R) Trace Hub data structures
5 * Copyright (C) 2014-2015 Intel Corporation.
15 /* Devices that generate trace data */
19 /* Switch, the Global Trace Hub (GTH) */
26 * struct intel_th_output - descriptor INTEL_TH_OUTPUT type devices
48 * struct intel_th_drvdata - describes hardware capabilities and quirks
61 #define INTEL_TH_CAP(_th, _cap) ((_th)->drvdata ? (_th)->drvdata->_cap : 0)
64 * struct intel_th_device - device on the intel_th bus
70 * @id: device instance or -1
81 int id; member
96 * intel_th_device_get_resource() - obtain @num'th resource of type @type
101 static inline struct resource *
107 for (i = 0; i < thdev->num_resources; i++) in intel_th_device_get_resource()
108 if (resource_type(&thdev->resource[i]) == type && !num--) in intel_th_device_get_resource()
109 return &thdev->resource[i]; in intel_th_device_get_resource()
120 GTH_CTP, /* Common Trace Port */
122 GTH_PTI, /* MIPI-PTI */
126 * intel_th_output_assigned() - if an output device is assigned to a switch port
131 static inline bool
134 return thdev->type == INTEL_TH_OUTPUT && in intel_th_output_assigned()
135 (thdev->output.port >= 0 || in intel_th_output_assigned()
136 thdev->output.type == GTH_NONE); in intel_th_output_assigned()
140 * struct intel_th_driver - driver for an intel_th_device device
207 static inline struct intel_th_device *
210 struct device *parent = thdev->dev.parent; in to_intel_th_parent()
218 static inline struct intel_th *to_intel_th(const struct intel_th_device *thdev) in to_intel_th()
220 if (thdev->type == INTEL_TH_OUTPUT) in to_intel_th()
223 if (WARN_ON_ONCE(!thdev || thdev->type == INTEL_TH_OUTPUT)) in to_intel_th()
226 return dev_get_drvdata(thdev->dev.parent); in to_intel_th()
261 * struct intel_th - Intel TH controller
270 * @id: this Intel TH controller's device ID in the system
288 int id; member
298 static inline struct intel_th_device *
301 if (thdev->type == INTEL_TH_SWITCH) in to_intel_th_hub()
303 else if (thdev->type == INTEL_TH_OUTPUT) in to_intel_th_hub()
306 return to_intel_th(thdev)->hub; in to_intel_th_hub()
313 /* Global Trace Hub (GTH) */
324 /* Software Trace Hub (STH) [0x4000..0x4fff] */
332 /* Internal MSU trace buffer [0x80000..0x9ffff] */