weston: Weston_status_check failed [1/1]

PD#SWPL-175158

Problem:
Weston_status_check failed

Solution:
add header file to modes.c

Verify:
t7

Change-Id: Id1ac050b90064abadac72406e2d4ab20d18aa2b8
Signed-off-by: leng.fang <leng.fang@amlogic.com>
diff --git a/aml-weston/aml-backend.c b/aml-weston/aml-backend.c
index b07ce19..c87ff15 100644
--- a/aml-weston/aml-backend.c
+++ b/aml-weston/aml-backend.c
@@ -202,7 +202,7 @@
 	struct drm_backend* b = to_drm_backend(ec);
 	struct drm_plane* plane_drm = drm_get_weston_plane(b, to_drm_plane(plane));
 	uint32_t crtc_id = 0;
-	weston_log("\n %s %d plane:%p crtc:%p\n", __FUNCTION__, __LINE__, plane_drm, plane_drm->crtc );
+	weston_log("\n %s %d plane:%p crtc:%p\n", __FUNCTION__, __LINE__, plane_drm, plane_drm ? plane_drm->crtc : NULL );
 	if (plane_drm && plane_drm->crtc && plane_drm->state_cur) {
 		crtc_id = plane_drm->crtc->crtc_id;
 		rc= drmModeSetPlane( b->drm.fd,
diff --git a/libweston/backend-drm/modes.c b/libweston/backend-drm/modes.c
index 01f08c1..f32f0a0 100644
--- a/libweston/backend-drm/modes.c
+++ b/libweston/backend-drm/modes.c
@@ -37,6 +37,7 @@
 #ifdef ENABLE_DRM_HELP
 #include "compositor-drm-help.h"
 #endif
+#include "aml-weston/aml-backend.h"
 
 static const char *const aspect_ratio_as_string[] = {
 	[WESTON_MODE_PIC_AR_NONE] = "",