mirror of
https://gitlab.freedesktop.org/mesa/drm.git
synced 2025-12-20 15:10:10 +01:00
exynos: fimg2d: fix return codes
Even if flushing the command buffer doesn't succeed, the G2D calls would still return zero. Fix this by just passing the flush return code. In fact error handling currently ignores the fact that g2d_add_cmd() can fail. This is going to be handled in a later patch. Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Acked-by: Emil Velikov <emil.l.velikov@gmail.com>
This commit is contained in:
parent
47a2de27a0
commit
7da8f07274
1 changed files with 5 additions and 15 deletions
|
|
@ -330,9 +330,7 @@ g2d_solid_fill(struct g2d_context *ctx, struct g2d_image *img,
|
||||||
bitblt.data.fast_solid_color_fill_en = 1;
|
bitblt.data.fast_solid_color_fill_en = 1;
|
||||||
g2d_add_cmd(ctx, BITBLT_COMMAND_REG, bitblt.val);
|
g2d_add_cmd(ctx, BITBLT_COMMAND_REG, bitblt.val);
|
||||||
|
|
||||||
g2d_flush(ctx);
|
return g2d_flush(ctx);
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -415,9 +413,7 @@ g2d_copy(struct g2d_context *ctx, struct g2d_image *src,
|
||||||
rop4.data.unmasked_rop3 = G2D_ROP3_SRC;
|
rop4.data.unmasked_rop3 = G2D_ROP3_SRC;
|
||||||
g2d_add_cmd(ctx, ROP4_REG, rop4.val);
|
g2d_add_cmd(ctx, ROP4_REG, rop4.val);
|
||||||
|
|
||||||
g2d_flush(ctx);
|
return g2d_flush(ctx);
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -527,9 +523,7 @@ g2d_copy_with_scale(struct g2d_context *ctx, struct g2d_image *src,
|
||||||
pt.data.y = dst_y + dst_h;
|
pt.data.y = dst_y + dst_h;
|
||||||
g2d_add_cmd(ctx, DST_RIGHT_BOTTOM_REG, pt.val);
|
g2d_add_cmd(ctx, DST_RIGHT_BOTTOM_REG, pt.val);
|
||||||
|
|
||||||
g2d_flush(ctx);
|
return g2d_flush(ctx);
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -636,9 +630,7 @@ g2d_blend(struct g2d_context *ctx, struct g2d_image *src,
|
||||||
pt.data.y = dst_y + h;
|
pt.data.y = dst_y + h;
|
||||||
g2d_add_cmd(ctx, DST_RIGHT_BOTTOM_REG, pt.val);
|
g2d_add_cmd(ctx, DST_RIGHT_BOTTOM_REG, pt.val);
|
||||||
|
|
||||||
g2d_flush(ctx);
|
return g2d_flush(ctx);
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -766,7 +758,5 @@ g2d_scale_and_blend(struct g2d_context *ctx, struct g2d_image *src,
|
||||||
pt.data.y = dst_y + dst_h;
|
pt.data.y = dst_y + dst_h;
|
||||||
g2d_add_cmd(ctx, DST_RIGHT_BOTTOM_REG, pt.val);
|
g2d_add_cmd(ctx, DST_RIGHT_BOTTOM_REG, pt.val);
|
||||||
|
|
||||||
g2d_flush(ctx);
|
return g2d_flush(ctx);
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue