diff options
| author | Tobias Jakobi <tjakobi@math.uni-bielefeld.de> | 2015-05-06 08:10:22 -0400 |
|---|---|---|
| committer | Inki Dae <daeinki@gmail.com> | 2015-05-19 09:50:54 -0400 |
| commit | 5b1d5bc690a9666b375496f5d680278f19687bc4 (patch) | |
| tree | e03e69779fdf3bc893d08485cc6126ca55399b67 /drivers/gpu | |
| parent | c0734fbaf49512dc62d544875bd9a4192329ce01 (diff) | |
drm/exynos: 'win' is always unsigned
The index for the hardware layer is always >=0. Previous
code that also used -1 as special index is now gone.
Also apply this to 'ch_enabled' (decon/fimd), since the
variable is on the same line (and is again always unsigned).
Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de>
Reviewed-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Diffstat (limited to 'drivers/gpu')
| -rw-r--r-- | drivers/gpu/drm/exynos/exynos7_drm_decon.c | 2 | ||||
| -rw-r--r-- | drivers/gpu/drm/exynos/exynos_drm_fimd.c | 7 | ||||
| -rw-r--r-- | drivers/gpu/drm/exynos/exynos_mixer.c | 7 |
3 files changed, 9 insertions, 7 deletions
diff --git a/drivers/gpu/drm/exynos/exynos7_drm_decon.c b/drivers/gpu/drm/exynos/exynos7_drm_decon.c index 3d00df76220d..6714e5b193ea 100644 --- a/drivers/gpu/drm/exynos/exynos7_drm_decon.c +++ b/drivers/gpu/drm/exynos/exynos7_drm_decon.c | |||
| @@ -91,7 +91,7 @@ static void decon_wait_for_vblank(struct exynos_drm_crtc *crtc) | |||
| 91 | 91 | ||
| 92 | static void decon_clear_channel(struct decon_context *ctx) | 92 | static void decon_clear_channel(struct decon_context *ctx) |
| 93 | { | 93 | { |
| 94 | int win, ch_enabled = 0; | 94 | unsigned int win, ch_enabled = 0; |
| 95 | 95 | ||
| 96 | DRM_DEBUG_KMS("%s\n", __FILE__); | 96 | DRM_DEBUG_KMS("%s\n", __FILE__); |
| 97 | 97 | ||
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c b/drivers/gpu/drm/exynos/exynos_drm_fimd.c index d704f2ba7179..a0edab833148 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c | |||
| @@ -215,7 +215,7 @@ static void fimd_wait_for_vblank(struct exynos_drm_crtc *crtc) | |||
| 215 | DRM_DEBUG_KMS("vblank wait timed out.\n"); | 215 | DRM_DEBUG_KMS("vblank wait timed out.\n"); |
| 216 | } | 216 | } |
| 217 | 217 | ||
| 218 | static void fimd_enable_video_output(struct fimd_context *ctx, int win, | 218 | static void fimd_enable_video_output(struct fimd_context *ctx, unsigned int win, |
| 219 | bool enable) | 219 | bool enable) |
| 220 | { | 220 | { |
| 221 | u32 val = readl(ctx->regs + WINCON(win)); | 221 | u32 val = readl(ctx->regs + WINCON(win)); |
| @@ -228,7 +228,8 @@ static void fimd_enable_video_output(struct fimd_context *ctx, int win, | |||
| 228 | writel(val, ctx->regs + WINCON(win)); | 228 | writel(val, ctx->regs + WINCON(win)); |
| 229 | } | 229 | } |
| 230 | 230 | ||
| 231 | static void fimd_enable_shadow_channel_path(struct fimd_context *ctx, int win, | 231 | static void fimd_enable_shadow_channel_path(struct fimd_context *ctx, |
| 232 | unsigned int win, | ||
| 232 | bool enable) | 233 | bool enable) |
| 233 | { | 234 | { |
| 234 | u32 val = readl(ctx->regs + SHADOWCON); | 235 | u32 val = readl(ctx->regs + SHADOWCON); |
| @@ -243,7 +244,7 @@ static void fimd_enable_shadow_channel_path(struct fimd_context *ctx, int win, | |||
| 243 | 244 | ||
| 244 | static void fimd_clear_channel(struct fimd_context *ctx) | 245 | static void fimd_clear_channel(struct fimd_context *ctx) |
| 245 | { | 246 | { |
| 246 | int win, ch_enabled = 0; | 247 | unsigned int win, ch_enabled = 0; |
| 247 | 248 | ||
| 248 | DRM_DEBUG_KMS("%s\n", __FILE__); | 249 | DRM_DEBUG_KMS("%s\n", __FILE__); |
| 249 | 250 | ||
diff --git a/drivers/gpu/drm/exynos/exynos_mixer.c b/drivers/gpu/drm/exynos/exynos_mixer.c index 285e1569e6ad..8874c1fcb3ab 100644 --- a/drivers/gpu/drm/exynos/exynos_mixer.c +++ b/drivers/gpu/drm/exynos/exynos_mixer.c | |||
| @@ -333,7 +333,8 @@ static void mixer_cfg_rgb_fmt(struct mixer_context *ctx, unsigned int height) | |||
| 333 | mixer_reg_writemask(res, MXR_CFG, val, MXR_CFG_RGB_FMT_MASK); | 333 | mixer_reg_writemask(res, MXR_CFG, val, MXR_CFG_RGB_FMT_MASK); |
| 334 | } | 334 | } |
| 335 | 335 | ||
| 336 | static void mixer_cfg_layer(struct mixer_context *ctx, int win, bool enable) | 336 | static void mixer_cfg_layer(struct mixer_context *ctx, unsigned int win, |
| 337 | bool enable) | ||
| 337 | { | 338 | { |
| 338 | struct mixer_resources *res = &ctx->mixer_res; | 339 | struct mixer_resources *res = &ctx->mixer_res; |
| 339 | u32 val = enable ? ~0 : 0; | 340 | u32 val = enable ? ~0 : 0; |
| @@ -379,7 +380,7 @@ static void mixer_stop(struct mixer_context *ctx) | |||
| 379 | usleep_range(10000, 12000); | 380 | usleep_range(10000, 12000); |
| 380 | } | 381 | } |
| 381 | 382 | ||
| 382 | static void vp_video_buffer(struct mixer_context *ctx, int win) | 383 | static void vp_video_buffer(struct mixer_context *ctx, unsigned int win) |
| 383 | { | 384 | { |
| 384 | struct mixer_resources *res = &ctx->mixer_res; | 385 | struct mixer_resources *res = &ctx->mixer_res; |
| 385 | unsigned long flags; | 386 | unsigned long flags; |
| @@ -511,7 +512,7 @@ fail: | |||
| 511 | return -ENOTSUPP; | 512 | return -ENOTSUPP; |
| 512 | } | 513 | } |
| 513 | 514 | ||
| 514 | static void mixer_graph_buffer(struct mixer_context *ctx, int win) | 515 | static void mixer_graph_buffer(struct mixer_context *ctx, unsigned int win) |
| 515 | { | 516 | { |
| 516 | struct mixer_resources *res = &ctx->mixer_res; | 517 | struct mixer_resources *res = &ctx->mixer_res; |
| 517 | unsigned long flags; | 518 | unsigned long flags; |
