Lines Matching full:sink

37  * struct coresight_node - elements of a path, from source to sink
389 * ETF devices are tricky... They can be a link or a sink, in coresight_disable_path_from()
391 * selected as a sink it will be configured as a sink, otherwise in coresight_disable_path_from()
470 * ETF devices are tricky... They can be a link or a sink, in coresight_enable_path()
472 * selected as a sink it will be configured as a sink, otherwise in coresight_enable_path()
484 * Sink is the first component turned on. If we in coresight_enable_path()
485 * failed to enable the sink, there are no components in coresight_enable_path()
556 * coresight_get_sink_by_id - returns the sink that matches the id
557 * @id: Id of the sink to match
559 * The name of a sink is unique, whether it is found on the AMBA bus or
561 * a sink.
669 struct coresight_device *sink) in coresight_get_trace_id() argument
672 return coresight_ops(csdev)->trace_id(csdev, mode, sink); in coresight_get_trace_id()
684 struct coresight_device *sink = coresight_get_sink(path); in coresight_path_assign_trace_id() local
690 trace_id = coresight_get_trace_id(nd->csdev, mode, sink); in coresight_path_assign_trace_id()
704 * _coresight_build_path - recursively build a path from a @csdev to a sink.
707 * @sink: The final sink we want in this path.
710 * The tree of Coresight device is traversed until @sink is found.
711 * From there the sink is added to the list along with all the devices that led
712 * to that point - the end result is a list from source to sink. In that list
713 * the source is the first device and the sink the last one.
717 struct coresight_device *sink, in _coresight_build_path() argument
724 /* The sink has been found. Enqueue the element */ in _coresight_build_path()
725 if (csdev == sink) in _coresight_build_path()
728 if (coresight_is_percpu_source(csdev) && coresight_is_percpu_sink(sink) && in _coresight_build_path()
729 sink == per_cpu(csdev_sink, source_ops(csdev)->cpu_id(csdev))) { in _coresight_build_path()
730 if (_coresight_build_path(sink, source, sink, path) == 0) { in _coresight_build_path()
736 /* Not a sink - recursively explore each port found on this element */ in _coresight_build_path()
746 _coresight_build_path(child_dev, source, sink, path) == 0) { in _coresight_build_path()
757 * A path from this element to a sink has been found. The elements in _coresight_build_path()
758 * leading to the sink are already enqueued, all that is left to do in _coresight_build_path()
777 struct coresight_device *sink) in coresight_build_path() argument
782 if (!sink) in coresight_build_path()
791 rc = _coresight_build_path(source, source, sink, path); in coresight_build_path()
823 /* return true if the device is a suitable type for a default sink */
826 /* sink & correct subtype */ in coresight_is_def_sink_type()
835 * coresight_select_best_sink - return the best sink for use as default from
838 * @sink: current best sink.
839 * @depth: search depth where current sink was found.
840 * @new_sink: new sink for comparison with current sink.
841 * @new_depth: search depth where new sink was found.
846 * Where two sinks of equal priority are found, the sink closest to the
849 * return @new_sink & update @depth if better than @sink, else return @sink.
852 coresight_select_best_sink(struct coresight_device *sink, int *depth, in coresight_select_best_sink() argument
857 if (!sink) { in coresight_select_best_sink()
861 sink->subtype.sink_subtype) { in coresight_select_best_sink()
862 /* found better sink */ in coresight_select_best_sink()
865 sink->subtype.sink_subtype) && in coresight_select_best_sink()
867 /* found same but closer sink */ in coresight_select_best_sink()
873 return update ? new_sink : sink; in coresight_select_best_sink()
878 * source to find a suitable default sink.
881 * @depth: [in] search depth of calling dev, [out] depth of found sink.
884 * sink is encountered and return that sink to the original caller.
886 * If current device is a plain sink return that & depth, otherwise recursively
887 * call child connections looking for a sink. Select best possible using
890 * return best sink found, or NULL if not found at this node or child nodes.
907 * Not a sink we want - or possible child sink may be better. in coresight_find_sink()
911 struct coresight_device *child_dev, *sink = NULL; in coresight_find_sink() local
916 sink = coresight_find_sink(child_dev, &child_depth); in coresight_find_sink()
918 if (sink) in coresight_find_sink()
921 sink, in coresight_find_sink()
926 /* return found sink and depth */ in coresight_find_sink()
933 * coresight_find_default_sink: Find a sink suitable for use as a
934 * default sink.
936 * @csdev: starting source to find a connected sink.
938 * Walks connections graph looking for a suitable sink to enable for the
940 * to select the best sink.
942 * If a sink is found, then the default sink for this device is set and
946 * sink.
953 /* look for a default sink if we have not found for this device */ in coresight_find_default_sink()
965 struct coresight_device *sink = data; in coresight_remove_sink_ref() local
968 if (source->def_sink == sink) in coresight_remove_sink_ref()
974 * coresight_clear_default_sink: Remove all default sink references to the
975 * supplied sink.
977 * If supplied device is a sink, then check all the bus devices and clear
978 * out all the references to this sink from the coresight_device def_sink
981 * @csdev: coresight sink - remove references to this from all sources.
1617 struct coresight_device *sink) in coresight_etm_get_trace_id() argument
1630 if (WARN_ON(!sink)) in coresight_etm_get_trace_id()
1633 trace_id = coresight_trace_id_get_cpu_id_map(cpu, &sink->perf_sink_id_map); in coresight_etm_get_trace_id()