#include <linux/component.h>
#include <linux/mfd/syscon.h>
#include <linux/of.h>
#include <linux/of_graph.h>
#include <linux/platform_device.h>
#include <linux/pm_runtime.h>
#include <linux/regmap.h>
#include <linux/reset.h>
#include <linux/clk.h>
#include <video/of_videomode.h>
#include <video/videomode.h>
#include <drm/display/drm_dp_helper.h>
#include <drm/drm_atomic.h>
#include <drm/drm_atomic_helper.h>
#include <drm/bridge/analogix_dp.h>
#include <drm/drm_of.h>
#include <drm/drm_panel.h>
#include <drm/drm_probe_helper.h>
#include <drm/drm_simple_kms_helper.h>
#include "rockchip_drm_drv.h"
#define RK3288_GRF_SOC_CON6 …
#define RK3288_EDP_LCDC_SEL …
#define RK3399_GRF_SOC_CON20 …
#define RK3399_EDP_LCDC_SEL …
#define HIWORD_UPDATE(val, mask) …
#define PSR_WAIT_LINE_FLAG_TIMEOUT_MS …
struct rockchip_dp_chip_data { … };
struct rockchip_dp_device { … };
static struct rockchip_dp_device *encoder_to_dp(struct drm_encoder *encoder)
{ … }
static struct rockchip_dp_device *pdata_encoder_to_dp(struct analogix_dp_plat_data *plat_data)
{ … }
static int rockchip_dp_pre_init(struct rockchip_dp_device *dp)
{ … }
static int rockchip_dp_poweron(struct analogix_dp_plat_data *plat_data)
{ … }
static int rockchip_dp_powerdown(struct analogix_dp_plat_data *plat_data)
{ … }
static int rockchip_dp_get_modes(struct analogix_dp_plat_data *plat_data,
struct drm_connector *connector)
{ … }
static bool
rockchip_dp_drm_encoder_mode_fixup(struct drm_encoder *encoder,
const struct drm_display_mode *mode,
struct drm_display_mode *adjusted_mode)
{ … }
static void rockchip_dp_drm_encoder_mode_set(struct drm_encoder *encoder,
struct drm_display_mode *mode,
struct drm_display_mode *adjusted)
{ … }
static
struct drm_crtc *rockchip_dp_drm_get_new_crtc(struct drm_encoder *encoder,
struct drm_atomic_state *state)
{ … }
static void rockchip_dp_drm_encoder_enable(struct drm_encoder *encoder,
struct drm_atomic_state *state)
{ … }
static void rockchip_dp_drm_encoder_disable(struct drm_encoder *encoder,
struct drm_atomic_state *state)
{ … }
static int
rockchip_dp_drm_encoder_atomic_check(struct drm_encoder *encoder,
struct drm_crtc_state *crtc_state,
struct drm_connector_state *conn_state)
{ … }
static struct drm_encoder_helper_funcs rockchip_dp_encoder_helper_funcs = …;
static int rockchip_dp_of_probe(struct rockchip_dp_device *dp)
{ … }
static int rockchip_dp_drm_create_encoder(struct rockchip_dp_device *dp)
{ … }
static int rockchip_dp_bind(struct device *dev, struct device *master,
void *data)
{ … }
static void rockchip_dp_unbind(struct device *dev, struct device *master,
void *data)
{ … }
static const struct component_ops rockchip_dp_component_ops = …;
static int rockchip_dp_probe(struct platform_device *pdev)
{ … }
static void rockchip_dp_remove(struct platform_device *pdev)
{ … }
static int rockchip_dp_suspend(struct device *dev)
{ … }
static int rockchip_dp_resume(struct device *dev)
{ … }
static DEFINE_RUNTIME_DEV_PM_OPS(rockchip_dp_pm_ops, rockchip_dp_suspend,
rockchip_dp_resume, NULL);
static const struct rockchip_dp_chip_data rk3399_edp = …;
static const struct rockchip_dp_chip_data rk3288_dp = …;
static const struct of_device_id rockchip_dp_dt_ids[] = …;
MODULE_DEVICE_TABLE(of, rockchip_dp_dt_ids);
struct platform_driver rockchip_dp_driver = …;