diff --git a/drivers/gpu/nvgpu/gp10b/fifo_gp10b.c b/drivers/gpu/nvgpu/gp10b/fifo_gp10b.c index 8c53978bd..ade6ff0a0 100644 --- a/drivers/gpu/nvgpu/gp10b/fifo_gp10b.c +++ b/drivers/gpu/nvgpu/gp10b/fifo_gp10b.c @@ -1,7 +1,7 @@ /* * GP10B fifo * - * Copyright (c) 2015, NVIDIA CORPORATION. All rights reserved. + * Copyright (c) 2015-2016, NVIDIA CORPORATION. All rights reserved. * * This program is free software; you can redistribute it and/or modify it * under the terms and conditions of the GNU General Public License, @@ -122,11 +122,7 @@ static int channel_gp10b_setup_ramfc(struct channel_gk20a *c, gk20a_mem_wr32(inst_ptr, ram_fc_target_w(), pbdma_target_engine_sw_f()); gk20a_mem_wr32(inst_ptr, ram_fc_acquire_w(), - pbdma_acquire_retry_man_2_f() | - pbdma_acquire_retry_exp_2_f() | - pbdma_acquire_timeout_exp_max_f() | - pbdma_acquire_timeout_man_max_f() | - pbdma_acquire_timeout_en_disable_f()); + channel_gk20a_pbdma_acquire_val(c)); gk20a_mem_wr32(inst_ptr, ram_fc_runlist_timeslice_w(), pbdma_runlist_timeslice_timeout_128_f() | diff --git a/drivers/gpu/nvgpu/gp10b/hw_pbdma_gp10b.h b/drivers/gpu/nvgpu/gp10b/hw_pbdma_gp10b.h index d3f97a440..f66fa9345 100644 --- a/drivers/gpu/nvgpu/gp10b/hw_pbdma_gp10b.h +++ b/drivers/gpu/nvgpu/gp10b/hw_pbdma_gp10b.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014-2015, NVIDIA CORPORATION. All rights reserved. + * Copyright (c) 2014-2016, NVIDIA CORPORATION. All rights reserved. * * This program is free software; you can redistribute it and/or modify it * under the terms and conditions of the GNU General Public License, @@ -262,14 +262,34 @@ static inline u32 pbdma_acquire_retry_exp_2_f(void) { return 0x100; } +static inline u32 pbdma_acquire_timeout_exp_f(u32 v) +{ + return (v & 0xf) << 11; +} +static inline u32 pbdma_acquire_timeout_exp_max_v(void) +{ + return 0x0000000f; +} static inline u32 pbdma_acquire_timeout_exp_max_f(void) { return 0x7800; } +static inline u32 pbdma_acquire_timeout_man_f(u32 v) +{ + return (v & 0xffff) << 15; +} +static inline u32 pbdma_acquire_timeout_man_max_v(void) +{ + return 0x0000ffff; +} static inline u32 pbdma_acquire_timeout_man_max_f(void) { return 0x7fff8000; } +static inline u32 pbdma_acquire_timeout_en_enable_f(void) +{ + return 0x80000000; +} static inline u32 pbdma_acquire_timeout_en_disable_f(void) { return 0x0;