diff options
author | Richard Zhao <rizhao@nvidia.com> | 2016-08-12 20:10:28 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2016-08-18 18:03:54 -0400 |
commit | 198b895a881ca067a2411b7367579cb1d594ab5a (patch) | |
tree | 90e667382a589de9ba4d97bf511ca6bd42efe03c /drivers/gpu/nvgpu/gk20a/fifo_gk20a.c | |
parent | deffbf8ee2017d4ea804f35946673dd0f6e0fcf2 (diff) |
gpu: nvgpu: use force_reset_ch in ch wdt handler
- let force_reset_ch pass down err code
- force_reset_ch callback can cover vgpu too.
Bug 1776876
JIRA VFND-2151
Change-Id: I48f7890294c6455247198e0cab5f21f83f61f0e1
Signed-off-by: Richard Zhao <rizhao@nvidia.com>
Reviewed-on: http://git-master/r/1202255
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/fifo_gk20a.c')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/fifo_gk20a.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/fifo_gk20a.c b/drivers/gpu/nvgpu/gk20a/fifo_gk20a.c index b025f4d6..bd31656f 100644 --- a/drivers/gpu/nvgpu/gk20a/fifo_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/fifo_gk20a.c | |||
@@ -1746,7 +1746,8 @@ void gk20a_fifo_recover(struct gk20a *g, u32 __engine_ids, | |||
1746 | } | 1746 | } |
1747 | 1747 | ||
1748 | /* force reset channel and tsg (if it's part of one) */ | 1748 | /* force reset channel and tsg (if it's part of one) */ |
1749 | int gk20a_fifo_force_reset_ch(struct channel_gk20a *ch, bool verbose) | 1749 | int gk20a_fifo_force_reset_ch(struct channel_gk20a *ch, |
1750 | u32 err_code, bool verbose) | ||
1750 | { | 1751 | { |
1751 | struct tsg_gk20a *tsg = NULL; | 1752 | struct tsg_gk20a *tsg = NULL; |
1752 | struct channel_gk20a *ch_tsg = NULL; | 1753 | struct channel_gk20a *ch_tsg = NULL; |
@@ -1759,8 +1760,7 @@ int gk20a_fifo_force_reset_ch(struct channel_gk20a *ch, bool verbose) | |||
1759 | 1760 | ||
1760 | list_for_each_entry(ch_tsg, &tsg->ch_list, ch_entry) { | 1761 | list_for_each_entry(ch_tsg, &tsg->ch_list, ch_entry) { |
1761 | if (gk20a_channel_get(ch_tsg)) { | 1762 | if (gk20a_channel_get(ch_tsg)) { |
1762 | gk20a_set_error_notifier(ch_tsg, | 1763 | gk20a_set_error_notifier(ch_tsg, err_code); |
1763 | NVGPU_CHANNEL_RESETCHANNEL_VERIF_ERROR); | ||
1764 | gk20a_channel_put(ch_tsg); | 1764 | gk20a_channel_put(ch_tsg); |
1765 | } | 1765 | } |
1766 | } | 1766 | } |
@@ -1768,8 +1768,7 @@ int gk20a_fifo_force_reset_ch(struct channel_gk20a *ch, bool verbose) | |||
1768 | mutex_unlock(&tsg->ch_list_lock); | 1768 | mutex_unlock(&tsg->ch_list_lock); |
1769 | gk20a_fifo_recover_tsg(g, ch->tsgid, verbose); | 1769 | gk20a_fifo_recover_tsg(g, ch->tsgid, verbose); |
1770 | } else { | 1770 | } else { |
1771 | gk20a_set_error_notifier(ch, | 1771 | gk20a_set_error_notifier(ch, err_code); |
1772 | NVGPU_CHANNEL_RESETCHANNEL_VERIF_ERROR); | ||
1773 | gk20a_fifo_recover_ch(g, ch->hw_chid, verbose); | 1772 | gk20a_fifo_recover_ch(g, ch->hw_chid, verbose); |
1774 | } | 1773 | } |
1775 | 1774 | ||