#include <kunit/test.h>
#include <drm/drm_atomic_helper.h>
#include <drm/drm_framebuffer.h>
#include <drm/drm_modes.h>
#include <drm/drm_rect.h>
static const struct drm_crtc_state crtc_state = …;
struct drm_check_plane_state_test { … };
static int drm_plane_helper_init(struct kunit *test)
{ … }
static void check_src_eq(struct kunit *test, struct drm_plane_state *plane_state,
unsigned int src_x, unsigned int src_y,
unsigned int src_w, unsigned int src_h)
{ … }
static void check_crtc_eq(struct kunit *test, struct drm_plane_state *plane_state,
int crtc_x, int crtc_y,
unsigned int crtc_w, unsigned int crtc_h)
{ … }
static void drm_test_check_plane_state(struct kunit *test)
{ … }
static void drm_check_plane_state_desc(const struct drm_check_plane_state_test *t,
char *desc)
{ … }
static const struct drm_check_plane_state_test drm_check_plane_state_tests[] = …;
KUNIT_ARRAY_PARAM(drm_check_plane_state, drm_check_plane_state_tests, drm_check_plane_state_desc);
static void drm_test_check_invalid_plane_state(struct kunit *test)
{ … }
static const struct drm_check_plane_state_test drm_check_invalid_plane_state_tests[] = …;
KUNIT_ARRAY_PARAM(drm_check_invalid_plane_state, drm_check_invalid_plane_state_tests,
drm_check_plane_state_desc);
static struct kunit_case drm_plane_helper_test[] = …;
static struct kunit_suite drm_plane_helper_test_suite = …;
kunit_test_suite(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;