瀏覽代碼

drm/ast: fix value check in cbr_scan2

this is a typo vs the ums driver, fix to check correct value.

Found initially by Coverity.

Reported-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie 11 年之前
父節點
當前提交
a82049b1f1
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/gpu/drm/ast/ast_post.c

+ 1 - 1
drivers/gpu/drm/ast/ast_post.c

@@ -572,7 +572,7 @@ static u32 cbr_scan2(struct ast_private *ast)
 		for (loop = 0; loop < CBR_PASSNUM2; loop++) {
 		for (loop = 0; loop < CBR_PASSNUM2; loop++) {
 			if ((data = cbr_test2(ast)) != 0) {
 			if ((data = cbr_test2(ast)) != 0) {
 				data2 &= data;
 				data2 &= data;
-				if (!data)
+				if (!data2)
 					return 0;
 					return 0;
 				break;
 				break;
 			}
 			}