Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  1) /* SPDX-License-Identifier: GPL-2.0 */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  2) #undef TRACE_SYSTEM
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  3) #define TRACE_SYSTEM kyber
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5) #if !defined(_TRACE_KYBER_H) || defined(TRACE_HEADER_MULTI_READ)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6) #define _TRACE_KYBER_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  8) #include <linux/blkdev.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  9) #include <linux/tracepoint.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) #define DOMAIN_LEN		16
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) #define LATENCY_TYPE_LEN	8
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) TRACE_EVENT(kyber_latency,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) 	TP_PROTO(struct request_queue *q, const char *domain, const char *type,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) 		 unsigned int percentile, unsigned int numerator,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) 		 unsigned int denominator, unsigned int samples),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) 	TP_ARGS(q, domain, type, percentile, numerator, denominator, samples),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) 	TP_STRUCT__entry(
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) 		__field(	dev_t,	dev				)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) 		__array(	char,	domain,	DOMAIN_LEN		)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) 		__array(	char,	type,	LATENCY_TYPE_LEN	)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) 		__field(	u8,	percentile			)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) 		__field(	u8,	numerator			)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) 		__field(	u8,	denominator			)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) 		__field(	unsigned int,	samples			)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) 	),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) 	TP_fast_assign(
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) 		__entry->dev		= disk_devt(dev_to_disk(kobj_to_dev(q->kobj.parent)));
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) 		strlcpy(__entry->domain, domain, sizeof(__entry->domain));
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) 		strlcpy(__entry->type, type, sizeof(__entry->type));
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) 		__entry->percentile	= percentile;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) 		__entry->numerator	= numerator;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) 		__entry->denominator	= denominator;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) 		__entry->samples	= samples;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) 	),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) 	TP_printk("%d,%d %s %s p%u %u/%u samples=%u",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) 		  MAJOR(__entry->dev), MINOR(__entry->dev), __entry->domain,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) 		  __entry->type, __entry->percentile, __entry->numerator,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) 		  __entry->denominator, __entry->samples)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) );
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48) TRACE_EVENT(kyber_adjust,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50) 	TP_PROTO(struct request_queue *q, const char *domain,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51) 		 unsigned int depth),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53) 	TP_ARGS(q, domain, depth),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 54) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 55) 	TP_STRUCT__entry(
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 56) 		__field(	dev_t,	dev			)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 57) 		__array(	char,	domain,	DOMAIN_LEN	)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 58) 		__field(	unsigned int,	depth		)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 59) 	),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 60) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 61) 	TP_fast_assign(
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 62) 		__entry->dev		= disk_devt(dev_to_disk(kobj_to_dev(q->kobj.parent)));
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 63) 		strlcpy(__entry->domain, domain, sizeof(__entry->domain));
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 64) 		__entry->depth		= depth;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 65) 	),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 66) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 67) 	TP_printk("%d,%d %s %u",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 68) 		  MAJOR(__entry->dev), MINOR(__entry->dev), __entry->domain,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 69) 		  __entry->depth)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 70) );
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 71) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 72) TRACE_EVENT(kyber_throttled,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 73) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 74) 	TP_PROTO(struct request_queue *q, const char *domain),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 75) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 76) 	TP_ARGS(q, domain),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 77) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 78) 	TP_STRUCT__entry(
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 79) 		__field(	dev_t,	dev			)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 80) 		__array(	char,	domain,	DOMAIN_LEN	)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 81) 	),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 82) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 83) 	TP_fast_assign(
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 84) 		__entry->dev		= disk_devt(dev_to_disk(kobj_to_dev(q->kobj.parent)));
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 85) 		strlcpy(__entry->domain, domain, sizeof(__entry->domain));
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 86) 	),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 87) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 88) 	TP_printk("%d,%d %s", MAJOR(__entry->dev), MINOR(__entry->dev),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 89) 		  __entry->domain)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 90) );
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 91) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 92) #define _TRACE_KYBER_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 93) #endif /* _TRACE_KYBER_H */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 94) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 95) /* This part must be outside protection */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 96) #include <trace/define_trace.h>