1 1.1 riastrad =============================================================================== 2 1.1 riastrad TODOs 3 1.1 riastrad =============================================================================== 4 1.1 riastrad 5 1.1 riastrad 1. Base this on drm-next - WIP 6 1.1 riastrad 7 1.1 riastrad 8 1.1 riastrad 2. Cleanup commit history 9 1.1 riastrad 10 1.1 riastrad 11 1.1 riastrad 3. WIP - Drop page flip helper and use DRM's version 12 1.1 riastrad 13 1.1 riastrad 14 1.1 riastrad 4. DONE - Flatten all DC objects 15 1.1 riastrad * dc_stream/core_stream/stream should just be dc_stream 16 1.1 riastrad * Same for other DC objects 17 1.1 riastrad 18 1.1 riastrad "Is there any major reason to keep all those abstractions? 19 1.1 riastrad 20 1.1 riastrad Could you collapse everything into struct dc_stream? 21 1.1 riastrad 22 1.1 riastrad I haven't looked recently but I didn't get the impression there was a 23 1.1 riastrad lot of design around what was public/protected, more whatever needed 24 1.1 riastrad to be used by someone else was in public." 25 1.1 riastrad ~ Dave Airlie 26 1.1 riastrad 27 1.1 riastrad 28 1.1 riastrad 5. DONE - Rename DC objects to align more with DRM 29 1.1 riastrad * dc_surface -> dc_plane_state 30 1.1 riastrad * dc_stream -> dc_stream_state 31 1.1 riastrad 32 1.1 riastrad 33 1.1 riastrad 6. DONE - Per-plane and per-stream validation 34 1.1 riastrad 35 1.1 riastrad 36 1.1 riastrad 7. WIP - Per-plane and per-stream commit 37 1.1 riastrad 38 1.1 riastrad 39 1.1 riastrad 8. WIP - Split pipe_ctx into plane and stream resource structs 40 1.1 riastrad 41 1.1 riastrad 42 1.1 riastrad 9. Attach plane and stream reources to state object instead of validate_context 43 1.1 riastrad 44 1.1 riastrad 45 1.1 riastrad 10. Remove dc_edid_caps and drm_helpers_parse_edid_caps 46 1.1 riastrad * Use drm_display_info instead 47 1.1 riastrad * Remove DC's edid quirks and rely on DRM's quirks (add quirks if needed) 48 1.1 riastrad 49 1.1 riastrad "Making sure you use the sink-specific helper libraries and kernel 50 1.1 riastrad subsystems, since there's really no good reason to have 2nd 51 1.1 riastrad implementation of those in the kernel. Looks likes that's done for mst 52 1.1 riastrad and edid parsing. There's still a bit a midlayer feeling to the edid 53 1.1 riastrad parsing side (e.g. dc_edid_caps and dm_helpers_parse_edid_caps, I 54 1.1 riastrad think it'd be much better if you convert that over to reading stuff 55 1.1 riastrad from drm_display_info and if needed, push stuff into the core). Also, 56 1.1 riastrad I can't come up with a good reason why DC needs all this (except to 57 1.1 riastrad reimplement half of our edid quirk table, which really isn't a good 58 1.1 riastrad idea). Might be good if you put this onto the list of things to fix 59 1.1 riastrad long-term, but imo not a blocker. Definitely make sure new stuff 60 1.1 riastrad doesn't slip in (i.e. if you start adding edid quirks to DC instead of 61 1.1 riastrad the drm core, refactoring to use the core edid stuff was pointless)." 62 1.1 riastrad ~ Daniel Vetter 63 1.1 riastrad 64 1.1 riastrad 65 1.1 riastrad 11. Remove dc/i2caux. This folder can be somewhat misleading. It's basically an 66 1.1 riastrad overy complicated HW programming function for sendind and receiving i2c/aux 67 1.1 riastrad commands. We can greatly simplify that and move it into dc/dceXYZ like other 68 1.1 riastrad HW blocks. 69 1.1 riastrad 70 1.1 riastrad 12. drm_modeset_lock in MST should no longer be needed in recent kernels 71 1.1 riastrad * Adopt appropriate locking scheme 72 1.1 riastrad 73 1.1 riastrad 13. get_modes and best_encoder callbacks look a bit funny. Can probably rip out 74 1.1 riastrad a few indirections, and consider removing entirely and using the 75 1.1 riastrad drm_atomic_helper_best_encoder default behaviour. 76 1.1 riastrad 77 1.1 riastrad 14. core/dc_debug.c, consider switching to the atomic state debug helpers and 78 1.1 riastrad moving all your driver state printing into the various atomic_print_state 79 1.1 riastrad callbacks. There's also plans to expose this stuff in a standard way across all 80 1.1 riastrad drivers, to make debugging userspace compositors easier across different hw. 81 1.1 riastrad 82 1.1 riastrad 15. Move DP/HDMI dual mode adaptors to drm_dp_dual_mode_helper.c. See 83 1.1 riastrad dal_ddc_service_i2c_query_dp_dual_mode_adaptor. 84 1.1 riastrad 85 1.1 riastrad 16. Move to core SCDC helpers (I think those are new since initial DC review). 86 1.1 riastrad 87 1.1 riastrad 17. There's still a pretty massive layer cake around dp aux and DPCD handling, 88 1.1 riastrad with like 3 levels of abstraction and using your own structures instead of the 89 1.1 riastrad stuff in drm_dp_helper.h. drm_dp_helper.h isn't really great and already has 2 90 1.1 riastrad incompatible styles, just means more reasons not to add a third (or well third 91 1.1 riastrad one gets to do the cleanup refactor). 92 1.1 riastrad 93 1.1 riastrad 18. There's a pile of sink handling code, both for DP and HDMI where I didn't 94 1.1 riastrad immediately recognize the standard. I think long term it'd be best for the drm 95 1.1 riastrad subsystem if we try to move as much of that into helpers/core as possible, and 96 1.1 riastrad share it with drivers. But that's a very long term goal, and by far not just an 97 1.1 riastrad issue with DC - other drivers, especially around DP sink handling, are equally 98 1.1 riastrad guilty. 99 1.1 riastrad 100 1.1 riastrad 19. DONE - The DC logger is still a rather sore thing, but I know that the 101 1.1 riastrad DRM_DEBUG stuff just isn't up to the challenges either. We need to figure out 102 1.1 riastrad something that integrates better with DRM and linux debug printing, while not 103 1.1 riastrad being useless with filtering output. dynamic debug printing might be an option. 104 1.1 riastrad 105 1.1 riastrad 20. Use kernel i2c device to program HDMI retimer. Some boards have an HDMI 106 1.1 riastrad retimer that we need to program to pass PHY compliance. Currently that's 107 1.1 riastrad bypassing the i2c device and goes directly to HW. This should be changed. 108 1.1 riastrad 109 1.1 riastrad 21. Remove vector.c from dc/basics. It's used in DDC code which can probably 110 1.1 riastrad be simplified enough to no longer need a vector implementation. 111