From 776ab920a7a4d31c6180e7dcb9f3fcea611e92bd Mon Sep 17 00:00:00 2001 From: Lakshmanan M Date: Fri, 7 Oct 2016 14:30:12 +0530 Subject: gpu: nvgpu: Add SW_THRESHOLD policy support Added SW_THRESHOLD policy support for over power protection. JIRA DNVGPU-70 Change-Id: I7a9d202619c997d6cab6fb750db7f3018229b2fd Signed-off-by: Lakshmanan M Reviewed-on: http://git-master/r/1233055 (cherry picked from commit b233c74b9ba4a3802f111757aecf24a27c830fc1) Reviewed-on: http://git-master/r/1241960 Reviewed-by: Terje Bergstrom GVS: Gerrit_Virtual_Submit --- drivers/gpu/nvgpu/pmgr/pwrpolicy.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'drivers/gpu/nvgpu/pmgr/pwrpolicy.h') diff --git a/drivers/gpu/nvgpu/pmgr/pwrpolicy.h b/drivers/gpu/nvgpu/pmgr/pwrpolicy.h index 82289137..008282d3 100644 --- a/drivers/gpu/nvgpu/pmgr/pwrpolicy.h +++ b/drivers/gpu/nvgpu/pmgr/pwrpolicy.h @@ -99,10 +99,20 @@ struct pwr_policy_hw_threshold { u16 low_threshold_value; }; +struct pwr_policy_sw_threshold { + struct pwr_policy_limit super; + u8 threshold_idx; + u8 low_threshold_idx; + bool b_use_low_threshold; + u16 low_threshold_value; + u8 event_id; +}; + union pwr_policy_data_union { struct boardobj boardobj; struct pwr_policy pwrpolicy; struct pwr_policy_hw_threshold hw_threshold; + struct pwr_policy_sw_threshold sw_threshold; } ; #define PMGR_GET_PWR_POLICY(g, policy_idx) \ -- cgit v1.2.2