gpu: nvgpu: move clean up of jobs to separate worker
authorDeepak Nibade <dnibade@nvidia.com>
Tue, 12 Jan 2016 13:21:37 +0000 (18:21 +0530)
committermobile promotions <svcmobile_promotions@nvidia.com>
Tue, 9 Feb 2016 11:47:21 +0000 (03:47 -0800)
commita4252e3a567e9be24dbaab5924b3efe9f0f5659c
treec09572c43925fad6df33d6cb97fc1d124bd0a80c
parent97adb895c67a1bd07f6b15a74f5d29bbb110a6e1
gpu: nvgpu: move clean up of jobs to separate worker

We currently clean up the jobs in gk20a_channel_update()
which is called from nvhost worker thread

Instead of doing this, schedule another delayed worker thread
clean_up_work to clean up the jobs (with delay of 1 jiffies)

Keep update_gp_get() in channel_update() and not in
delayed worker since this will help in better book
keeping of gp_get

Also, this scheduling will help delay job clean-up so
that more number of jobs are batched for clean up
and hence less time is consumed by worker

Bug 1718092

Change-Id: If3b94b6aab93c92da4cf0d1c74aaba756f4cd838
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/931701
(cherry picked from commit 31d3378067e5d184ab9a7b269f4111a90ac76327)
Reviewed-on: http://git-master/r/931707
GVS: Gerrit_Virtual_Submit
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
drivers/gpu/nvgpu/gk20a/channel_gk20a.c
drivers/gpu/nvgpu/gk20a/channel_gk20a.h