提交 64c173d3 编写于 作者: T Terje Bergstrom 提交者: Thierry Reding

gpu: host1x: Check INCR opcode correctly

The firewall code used a wrong loop condition (pointer to a
structure) while checking INCR opcode. This patch fixes the code to
use correct loop condition (number of words remaining).
Signed-off-by: NTerje Bergstrom <tbergstrom@nvidia.com>
Signed-off-by: NArto Merilainen <amerilainen@nvidia.com>
Signed-off-by: NThierry Reding <thierry.reding@gmail.com>
上级 604faa7d
...@@ -330,7 +330,7 @@ static int check_incr(struct host1x_firewall *fw) ...@@ -330,7 +330,7 @@ static int check_incr(struct host1x_firewall *fw)
u32 count = fw->count; u32 count = fw->count;
u32 reg = fw->reg; u32 reg = fw->reg;
while (fw) { while (count) {
if (fw->words == 0) if (fw->words == 0)
return -EINVAL; return -EINVAL;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册