disp: msm: adapt crtc plane and connector atomic functions for multiple SIs

Commit ddac29b ("disp: msm: Pass the full state to crtc plane and connector
atomic functions") pass full state to crtc, plane, and connector atomic
functions and retrieve drm_crtc/plane/connector_state within the atomic
function.
This change puts macros in the callers of atomic functions to handle API
changes between kernel version 5.10 and version 5.15.

Change-Id: I8e710e33f0a149bbfaa54820a7174a05810e2da4
Signed-off-by: Bruce Hoo <bingchua@codeaurora.org>
这个提交包含在:
Bruce Hoo
2021-11-10 12:32:46 +08:00
父节点 a7ee8c6b1e
当前提交 773b0e5b64
修改 4 个文件,包含 58 行新增0 行删除

查看文件

@@ -17,6 +17,7 @@
*/
#include <drm/drm_panel.h>
#include <drm/drm_vblank.h>
#include <linux/version.h>
#include "msm_drv.h"
#include "msm_gem.h"
@@ -419,7 +420,11 @@ static void msm_atomic_helper_commit_modeset_enables(struct drm_device *dev,
crtc->base.id);
if (funcs->atomic_enable)
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 15, 0))
funcs->atomic_enable(crtc, old_state);
#else
funcs->atomic_enable(crtc, old_crtc_state);
#endif
else
funcs->commit(crtc);
}