msm: kgsl: add gpu busy stats to sysfs
Signed-off-by: Suman Tatiraju <sumant@codeaurora.org>
diff --git a/drivers/gpu/msm/kgsl_pwrctrl.h b/drivers/gpu/msm/kgsl_pwrctrl.h
index fff5769..c3ade1a 100644
--- a/drivers/gpu/msm/kgsl_pwrctrl.h
+++ b/drivers/gpu/msm/kgsl_pwrctrl.h
@@ -30,6 +30,16 @@
struct platform_device;
+struct kgsl_busy {
+ struct timeval start;
+ struct timeval stop;
+ int on_time;
+ int time;
+ int on_time_old;
+ int time_old;
+ unsigned int no_nap_cnt;
+};
+
struct kgsl_pwrctrl {
int interrupt_num;
int have_irq;
@@ -48,6 +58,7 @@
const char *irq_name;
const char *src_clk_name;
s64 time;
+ struct kgsl_busy busy;
};
void kgsl_pwrctrl_clk(struct kgsl_device *device, int state);