98d2cc2b03
drm/amd/display: Change locking of registers when flipping frames.
...
- Introduce GRPH_UPDATE_LOCK around programming surface flip.
- Remove the now unused graphic surface lock.
- Add macros to get and set four registers
- both immediate and H Retrace should not be enabled at the same time
Signed-off-by: Andrew Wong <andrew.wong1@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 >
2017-09-26 17:04:52 -04:00
89e8963036
drm/amd/display: Fix Gamma Adjustment
...
- Gamma correction is not properly copied to the surface after refactor
- Make sure gamma correction is copied with correct retain
Signed-off-by: Amy Zhang <Amy.Zhang@amd.com >
Reviewed-by: Anthony Koo <Anthony.Koo@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:04:48 -04:00
9474980ac4
drm/amd/display: Added timing sync trace.
...
Signed-off-by: Yongqiang Sun <yongqiang.sun@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 >
2017-09-26 17:04:45 -04:00
5ea81b9185
drm/amd/display: fix up construction of scratch_val_ctx
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:04:41 -04:00
922aa1e15e
drm/amd/display: Fix refcount over dc_sink.
...
Retain a dc_sink pointer until a new physical pointer
arrives in case of new display connected.
Signed-off-by: Andrey Grodzovsky <Andrey.Grodzovsky@amd.com >
Reviewed-by: Andrey Grodzovsky <Andrey.Grodzovsky@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:04:38 -04:00
f4c07f88cc
drm/amd/display: avoid apply_clk_constraints for address update
...
- dc_update_surfaces_for_target get called in ISR but apply_clk_constraints allocates memory
Signed-off-by: Tony Cheng <tony.cheng@amd.com >
Reviewed-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:04:34 -04:00
edbd58af69
drm/amd/display: fix indexing bug
...
- is_new_pipe_surface should be addressed with pipe idx, not surface idx
Signed-off-by: Tony Cheng <tony.cheng@amd.com >
Reviewed-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:04:31 -04:00
091a97e542
drm/amd/display: Fix warning. Set MAX_SURFACES to 3
...
Currently we never use more than 2 surfaces in all use cases.
This avoids pushing dc_commit_surfaces_to_target beyond a
stacksize of 1024.
Signed-off-by: Harry Wentland <harry.wentland@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 >
2017-09-26 17:04:28 -04:00
eaf9094475
drm/amd/display: Fix warning in freesync module
...
Signed-off-by: Harry Wentland <harry.wentland@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 >
2017-09-26 17:04:25 -04:00
a33fa99d8b
drm/amd/display: Fix bunch of warnings in DC
...
Some of those are potential bugs
Signed-off-by: Harry Wentland <harry.wentland@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 >
2017-09-26 17:04:17 -04:00
49c07a99b2
drm/amd/display: remove DM_NOT_IMPL messages
...
Some functions like dm_bandwidth_update are placeholders
for future implementations. Right now, they simply
print messages like "DM_NOT_IMPL: dm_bandwidth_update".
This message even though informational, sometimes can
create some confusion for users.
Since these functions are only skeletons for future, we
simply remove the rather un-unecessary messages from these
functions.
Signed-off-by: Arindam Nath <arindam.nath@amd.com >
Reviewed-by: Christian König <christian.koenig@amd.com >
Reviewed-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:04:13 -04:00
e11b86ad7d
drm/amd/display: moving remaining functionality from gpu to dce_clocks
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com >
Reviewed-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:04:10 -04:00
e91dbe3dee
drm/amd/display: Temporarily blocking interlacing mode until it's supported.
...
Signed-off-by: Ding Wang <Ding.Wang@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 >
2017-09-26 17:04:07 -04:00
13625c7bf3
drm/amd/display: create scratch_val_ctx as temp w/a
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@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 >
2017-09-26 17:04:04 -04:00
b007045674
drm/amd/display: use rgb full range as default quantization for non HDMI
...
Refactor the quantization decision to color module.
Add the check if non HDMI, default quantization should be rgb full range.
Signed-off-by: Wenjing Liu <Wenjing.Liu@amd.com >
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com >
Reviewed-by: Anthony Koo <Anthony.Koo@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:04:00 -04:00
85944914f1
drm/amd/display: fix display clock integrated info read
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com >
Reviewed-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:03:13 -04:00
8318a7eb98
drm/amd/display: add newline to generic_reg_wait timeout message
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@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 >
2017-09-26 17:03:04 -04:00
9a70eba7f2
drm/amd/display: consolidate dce8-11.2 display clock code
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@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 >
2017-09-26 17:03:01 -04:00
e9c58bb439
drm/amd/display: remove clocks_state enum
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@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 >
2017-09-26 17:02:58 -04:00
95015be8f4
drm/amd/display: remove get_min_clocks_state
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@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 >
2017-09-26 17:02:55 -04:00
3bad7c5ccf
drm/amd/display: remove store clock state
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@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 >
2017-09-26 17:02:52 -04:00
5d6d185f32
drm/amd/display: restyle display clock calls part 2
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@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 >
2017-09-26 17:02:48 -04:00
1a687574a7
drm/amd/display: restyle display clock calls part 1
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@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 >
2017-09-26 17:02:44 -04:00
00d64d289f
drm/amd/display: remove dead display clock code
...
Signed-off-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@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 >
2017-09-26 17:02:41 -04:00
565968219c
drm/amd/display: Add missing GRPH register definition
...
Signed-off-by: Yongqiang Sun <yongqiang.sun@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 >
2017-09-26 17:02:37 -04:00
197062bf12
drm/amd/display: refactor DCE11 DVVM
...
- move to new programming style
- clean up table to make it obvious what we are programming
Signed-off-by: Tony Cheng <tony.cheng@amd.com >
Reviewed-by: Zeyu Fan <Zeyu.Fan@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:02:31 -04:00
22f050be15
drm/amd/display: fix REG_SET_5 macro
...
Signed-off-by: Roman Li <Roman.Li@amd.com >
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com >
Reviewed-by: Roman Li <Roman.Li@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:02:27 -04:00
f60ea68d43
drm/amd/display: Remove obsolete LATEST_ATOM_BIOS_SUPPORT
...
Signed-off-by: Harry Wentland <harry.wentland@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 >
2017-09-26 17:02:23 -04:00
b32c34ae48
drm/amd/display: Removing extra newline
...
Signed-off-by: Harry Wentland <harry.wentland@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 >
2017-09-26 17:02:19 -04:00
0971d745f6
drm/amd/display: Update rgb limited range csc matrix calculation
...
The issue causes hue adjustment for rgb
limited range color space programmed wrong.
Update calculation formula for rgb limited range
Signed-off-by: Wenjing Liu <Wenjing.Liu@amd.com >
Reviewed-by: Anthony Koo <Anthony.Koo@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:02:14 -04:00
1293b4339f
drm/amd/display: Block 3D Timings
...
- we don't yet support 3D timings in DAL3
- somehow a code path was being executed that resulted in HW programming
for a 3D timing, which caused 3D displays to show half the desktop in one
frame, and the other half of the desktop in the next frame
- blocking all 3D timings in timing generator validation until we
implement proper 3D timing support
Signed-off-by: Joshua Aberback <Joshua.Aberback@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 >
2017-09-26 17:02:07 -04:00
ead964f24e
drm/amd/display: Fix memory corruption issue.
...
temp_flip_context is always same as current_context,
and the current_context will be freed in
dc_commit_targets(), but temp_flip_context will be used in
dc_update_surfaces_for_target().
Signed-off-by: JimQu <Jim.Qu@amd.com >
Reviewed-by: Andrey Grodzovsky <Andrey.Grodzovsky@amd.com >
Acked-by: Harry Wentland <Harry.Wentland@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:02:02 -04:00
8e545104aa
drm/amd/display: Fix bugs causing Hawaii and Bonaire not light up.
...
Signed-off-by: Zeyu Fan <Zeyu.Fan@amd.com >
Acked-by: Jordan Lazare <Jordan.Lazare@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:01:59 -04:00
56bc1c4261
drm/amd/display: Fix hdmi not lighting up on Hawaii.
...
Signed-off-by: Zeyu Fan <Zeyu.Fan@amd.com >
Acked-by: Jordan Lazare <Jordan.Lazare@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:01:54 -04:00
39cc5be276
drm/amd/dc/dm: remove redundant display structs
...
Now that the mc_access functions are gone, we no longer
need separate structs for all the different dce families
in dm.
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:01:44 -04:00
4562236b3b
drm/amd/dc: Add dc display driver (v2)
...
Supported DCE versions: 8.0, 10.0, 11.0, 11.2
v2: rebase against 4.11
Signed-off-by: Harry Wentland <harry.wentland@amd.com >
Acked-by: Alex Deucher <alexander.deucher@amd.com >
Signed-off-by: Alex Deucher <alexander.deucher@amd.com >
2017-09-26 17:01:32 -04:00