gpu: nvgpu: Fix offset of PC sampling field

Fix offset of PM word when changing PC sampling field.

Bug 1517458
Bug 1573150

Change-Id: I2b8489b1d3c05f3a20416fc1a46ac1827f453cbc
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/721032
This commit is contained in:
Terje Bergstrom
2015-03-23 09:48:17 -07:00
committed by Dan Willemsen
parent 38fc3a48a0
commit 9cf345b8be

View File

@@ -984,7 +984,7 @@ static int gr_gm20b_update_pc_sampling(struct channel_gk20a *c,
if (!ctx_ptr)
return -ENOMEM;
v = gk20a_mem_rd32(ctx_ptr, ctxsw_prog_main_image_pm_o());
v = gk20a_mem_rd32(ctx_ptr + ctxsw_prog_main_image_pm_o(), 0);
v &= ~ctxsw_prog_main_image_pm_pc_sampling_m();
v |= ctxsw_prog_main_image_pm_pc_sampling_f(enable);
gk20a_mem_wr32(ctx_ptr + ctxsw_prog_main_image_pm_o(), 0, v);