#include <linux/clk.h>
#include <linux/pm_runtime.h>
#include <video/videomode.h>
#include <drm/drm_atomic.h>
#include <drm/drm_atomic_helper.h>
#include <drm/drm_crtc.h>
#include <drm/drm_framebuffer.h>
#include <drm/drm_print.h>
#include <drm/drm_probe_helper.h>
#include <drm/drm_vblank.h>
#include "malidp_drv.h"
#include "malidp_hw.h"
static enum drm_mode_status malidp_crtc_mode_valid(struct drm_crtc *crtc,
const struct drm_display_mode *mode)
{ … }
static void malidp_crtc_atomic_enable(struct drm_crtc *crtc,
struct drm_atomic_state *state)
{ … }
static void malidp_crtc_atomic_disable(struct drm_crtc *crtc,
struct drm_atomic_state *state)
{ … }
static const struct gamma_curve_segment { … } segments[MALIDP_COEFFTAB_NUM_COEFFS] = …;
#define DE_COEFTAB_DATA(a, b) …
static void malidp_generate_gamma_table(struct drm_property_blob *lut_blob,
u32 coeffs[MALIDP_COEFFTAB_NUM_COEFFS])
{ … }
static int malidp_crtc_atomic_check_gamma(struct drm_crtc *crtc,
struct drm_crtc_state *state)
{ … }
static int malidp_crtc_atomic_check_ctm(struct drm_crtc *crtc,
struct drm_crtc_state *state)
{ … }
static int malidp_crtc_atomic_check_scaling(struct drm_crtc *crtc,
struct drm_crtc_state *state)
{ … }
static int malidp_crtc_atomic_check(struct drm_crtc *crtc,
struct drm_atomic_state *state)
{ … }
static const struct drm_crtc_helper_funcs malidp_crtc_helper_funcs = …;
static struct drm_crtc_state *malidp_crtc_duplicate_state(struct drm_crtc *crtc)
{ … }
static void malidp_crtc_destroy_state(struct drm_crtc *crtc,
struct drm_crtc_state *state)
{ … }
static void malidp_crtc_reset(struct drm_crtc *crtc)
{ … }
static int malidp_crtc_enable_vblank(struct drm_crtc *crtc)
{ … }
static void malidp_crtc_disable_vblank(struct drm_crtc *crtc)
{ … }
static const struct drm_crtc_funcs malidp_crtc_funcs = …;
int malidp_crtc_init(struct drm_device *drm)
{ … }