diff options
author | Yue Hin Lau <Yuehin.Lau@amd.com> | 2018-04-09 14:46:32 -0400 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2018-05-15 14:43:27 -0400 |
commit | ad019f7b6db893271d13148d6d80001d0c23cdf9 (patch) | |
tree | 91d6b8e59b7d0a1f210ff3d37acb1e422b40b6a4 | |
parent | a47654633596a63f14a9035b9c762f8aaf1e00a3 (diff) |
drm/amd/display: add missing colorspace for set black color
Signed-off-by: Yue Hin Lau <Yuehin.Lau@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Acked-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
-rw-r--r-- | drivers/gpu/drm/amd/display/dc/core/dc_hw_sequencer.c | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_hw_sequencer.c b/drivers/gpu/drm/amd/display/dc/core/dc_hw_sequencer.c index 481f6928a9c0..83d121510ef5 100644 --- a/drivers/gpu/drm/amd/display/dc/core/dc_hw_sequencer.c +++ b/drivers/gpu/drm/amd/display/dc/core/dc_hw_sequencer.c | |||
@@ -208,6 +208,7 @@ void color_space_to_black_color( | |||
208 | case COLOR_SPACE_YCBCR709: | 208 | case COLOR_SPACE_YCBCR709: |
209 | case COLOR_SPACE_YCBCR601_LIMITED: | 209 | case COLOR_SPACE_YCBCR601_LIMITED: |
210 | case COLOR_SPACE_YCBCR709_LIMITED: | 210 | case COLOR_SPACE_YCBCR709_LIMITED: |
211 | case COLOR_SPACE_2020_YCBCR: | ||
211 | *black_color = black_color_format[BLACK_COLOR_FORMAT_YUV_CV]; | 212 | *black_color = black_color_format[BLACK_COLOR_FORMAT_YUV_CV]; |
212 | break; | 213 | break; |
213 | 214 | ||
@@ -216,7 +217,25 @@ void color_space_to_black_color( | |||
216 | black_color_format[BLACK_COLOR_FORMAT_RGB_LIMITED]; | 217 | black_color_format[BLACK_COLOR_FORMAT_RGB_LIMITED]; |
217 | break; | 218 | break; |
218 | 219 | ||
219 | default: | 220 | /** |
221 | * Remove default and add case for all color space | ||
222 | * so when we forget to add new color space | ||
223 | * compiler will give a warning | ||
224 | */ | ||
225 | case COLOR_SPACE_UNKNOWN: | ||
226 | case COLOR_SPACE_SRGB: | ||
227 | case COLOR_SPACE_XR_RGB: | ||
228 | case COLOR_SPACE_MSREF_SCRGB: | ||
229 | case COLOR_SPACE_XV_YCC_709: | ||
230 | case COLOR_SPACE_XV_YCC_601: | ||
231 | case COLOR_SPACE_2020_RGB_FULLRANGE: | ||
232 | case COLOR_SPACE_2020_RGB_LIMITEDRANGE: | ||
233 | case COLOR_SPACE_ADOBERGB: | ||
234 | case COLOR_SPACE_DCIP3: | ||
235 | case COLOR_SPACE_DISPLAYNATIVE: | ||
236 | case COLOR_SPACE_DOLBYVISION: | ||
237 | case COLOR_SPACE_APPCTRL: | ||
238 | case COLOR_SPACE_CUSTOMPOINTS: | ||
220 | /* fefault is sRGB black (full range). */ | 239 | /* fefault is sRGB black (full range). */ |
221 | *black_color = | 240 | *black_color = |
222 | black_color_format[BLACK_COLOR_FORMAT_RGB_FULLRANGE]; | 241 | black_color_format[BLACK_COLOR_FORMAT_RGB_FULLRANGE]; |