summaryrefslogtreecommitdiffstats
path: root/include/linux/devfreq-event.h
diff options
context:
space:
mode:
authorLukasz Luba <l.luba@partner.samsung.com>2019-06-05 11:12:34 +0200
committerMyungJoo Ham <myungjoo.ham@samsung.com>2019-08-25 12:44:38 +0900
commit1dd62c66d345a4e5dcfa5a4e81999600515b4309 (patch)
tree09ea3db9c7e22449f57eb6cb1d2b8a1d31168e99 /include/linux/devfreq-event.h
parent0ae9c3213c2ca34f7e7ebad1436267778d37ba9f (diff)
downloadlinux-1dd62c66d345a4e5dcfa5a4e81999600515b4309.tar.gz
linux-1dd62c66d345a4e5dcfa5a4e81999600515b4309.tar.bz2
linux-1dd62c66d345a4e5dcfa5a4e81999600515b4309.zip
PM / devfreq: events: extend events by type of counted data
This patch adds posibility to choose what type of data should be counted by the PPMU counter. Now the type comes from DT where the event has been defined. When there is no 'event-data-type' the default value is used, which is 'read+write data in bytes'. It is needed when you want to know not only read+write data bytes but i.e. only write data in byte, or number of read requests, etc. Signed-off-by: Lukasz Luba <l.luba@partner.samsung.com> Acked-by: Chanwoo Choi <cw00.choi@samsung.com> [Updated property by MyungJoo. data_type --> event_type] Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Diffstat (limited to 'include/linux/devfreq-event.h')
-rw-r--r--include/linux/devfreq-event.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/devfreq-event.h b/include/linux/devfreq-event.h
index 29fc0dd735ae..f14f17f8cb7f 100644
--- a/include/linux/devfreq-event.h
+++ b/include/linux/devfreq-event.h
@@ -78,14 +78,20 @@ struct devfreq_event_ops {
* struct devfreq_event_desc - the descriptor of devfreq-event device
*
* @name : the name of devfreq-event device.
+ * @event_type : the type of the event determined and used by driver
* @driver_data : the private data for devfreq-event driver.
* @ops : the operation to control devfreq-event device.
*
* Each devfreq-event device is described with a this structure.
* This structure contains the various data for devfreq-event device.
+ * The event_type describes what is going to be counted in the register.
+ * It might choose to count e.g. read requests, write data in bytes, etc.
+ * The full supported list of types is present in specyfic header in:
+ * include/dt-bindings/pmu/.
*/
struct devfreq_event_desc {
const char *name;
+ u32 event_type;
void *driver_data;
const struct devfreq_event_ops *ops;