Add a new mode support for HDMI
- support for 1920x1200x60Hz mode. Cleanups - Drop in_bridge_node from exynos_dsi - Use a exynos_dsi object instead of a encoder object as drvdata. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAABAgAGBQJfxcqmAAoJEFc4NIkMQxK4mbcP/iUPnDkevfgt7HK2X3hgLemM aNZqYmrPabkQnv0/mxKUvFkUte5uWZa83nnIKcI33ZHpLzUNKrDmRd6x5UfGZtty aRYrXiPQFSaX8906k/wEQhNzY9v+cEfs02i4K7wzmXtw1HeXjha4PNa1k527nd3X e0fMuDNGwLvOEgwTFgJ9MeNKsOzLDutPvOGinpQeq637fRdRjH+UGRCBmlrr/2X7 q1GHemzXAQYP6InyQ35cy/98hOui3UlnePD7O3ahx0PqX2RlFe0pZC5ttNrl6UE1 5Fnp+jtkjzh1RhiWGGQXEk182kU1/x9Nroi+wd3mfJjjLKtLPpKkF8OZmstgR/Q+ caZiar+jBiLEFNkRWphg2zqipHRBSU7QMZ5rsYU+TjFLPXaWno5JV9oc2f/DrM0i fHUCeUoByyQPv1pcl65YJdfCvUCzSSHWEmkSB5svhqd3tgP2K6paZXHlcttG3M1L obBEzKD6zvGHeXteyyLEjjS7GIzbSYKQmxcjxsROgJEbrq9YI6Aw0BdB1F0fND22 /PohCQXHC7NgwSsEFoa51sm0gET7xR9pbj6MlxWnCNsbrh/qxW3EA7NNrkpX+i5s +m+ynXpeGlZaatkmMz4qUsVlK4QymVB5VM5AMbot/ZhItcCmr6ZRbHrLRO+P+51b mwp5E/XT2aIkOAE6BOrZ =owYY -----END PGP SIGNATURE----- Merge tag 'exynos-drm-next-for-v5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos into drm-next Add a new mode support for HDMI - support for 1920x1200x60Hz mode. Cleanups - Drop in_bridge_node from exynos_dsi - Use a exynos_dsi object instead of a encoder object as drvdata. Signed-off-by: Dave Airlie <airlied@redhat.com> From: Inki Dae <inki.dae@samsung.com> Link: https://patchwork.freedesktop.org/patch/msgid/1606798227-31967-1-git-send-email-inki.dae@samsung.com
This commit is contained in:
commit
207665fd37
|
@ -282,7 +282,6 @@ struct exynos_dsi {
|
||||||
struct list_head transfer_list;
|
struct list_head transfer_list;
|
||||||
|
|
||||||
const struct exynos_dsi_driver_data *driver_data;
|
const struct exynos_dsi_driver_data *driver_data;
|
||||||
struct device_node *in_bridge_node;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#define host_to_dsi(host) container_of(host, struct exynos_dsi, dsi_host)
|
#define host_to_dsi(host) container_of(host, struct exynos_dsi, dsi_host)
|
||||||
|
@ -1684,17 +1683,16 @@ static int exynos_dsi_parse_dt(struct exynos_dsi *dsi)
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
dsi->in_bridge_node = of_graph_get_remote_node(node, DSI_PORT_IN, 0);
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int exynos_dsi_bind(struct device *dev, struct device *master,
|
static int exynos_dsi_bind(struct device *dev, struct device *master,
|
||||||
void *data)
|
void *data)
|
||||||
{
|
{
|
||||||
struct drm_encoder *encoder = dev_get_drvdata(dev);
|
struct exynos_dsi *dsi = dev_get_drvdata(dev);
|
||||||
struct exynos_dsi *dsi = encoder_to_dsi(encoder);
|
struct drm_encoder *encoder = &dsi->encoder;
|
||||||
struct drm_device *drm_dev = data;
|
struct drm_device *drm_dev = data;
|
||||||
|
struct device_node *in_bridge_node;
|
||||||
struct drm_bridge *in_bridge;
|
struct drm_bridge *in_bridge;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
|
@ -1706,10 +1704,12 @@ static int exynos_dsi_bind(struct device *dev, struct device *master,
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
if (dsi->in_bridge_node) {
|
in_bridge_node = of_graph_get_remote_node(dev->of_node, DSI_PORT_IN, 0);
|
||||||
in_bridge = of_drm_find_bridge(dsi->in_bridge_node);
|
if (in_bridge_node) {
|
||||||
|
in_bridge = of_drm_find_bridge(in_bridge_node);
|
||||||
if (in_bridge)
|
if (in_bridge)
|
||||||
drm_bridge_attach(encoder, in_bridge, NULL, 0);
|
drm_bridge_attach(encoder, in_bridge, NULL, 0);
|
||||||
|
of_node_put(in_bridge_node);
|
||||||
}
|
}
|
||||||
|
|
||||||
return mipi_dsi_host_register(&dsi->dsi_host);
|
return mipi_dsi_host_register(&dsi->dsi_host);
|
||||||
|
@ -1718,8 +1718,8 @@ static int exynos_dsi_bind(struct device *dev, struct device *master,
|
||||||
static void exynos_dsi_unbind(struct device *dev, struct device *master,
|
static void exynos_dsi_unbind(struct device *dev, struct device *master,
|
||||||
void *data)
|
void *data)
|
||||||
{
|
{
|
||||||
struct drm_encoder *encoder = dev_get_drvdata(dev);
|
struct exynos_dsi *dsi = dev_get_drvdata(dev);
|
||||||
struct exynos_dsi *dsi = encoder_to_dsi(encoder);
|
struct drm_encoder *encoder = &dsi->encoder;
|
||||||
|
|
||||||
exynos_dsi_disable(encoder);
|
exynos_dsi_disable(encoder);
|
||||||
|
|
||||||
|
@ -1815,7 +1815,7 @@ static int exynos_dsi_probe(struct platform_device *pdev)
|
||||||
if (ret)
|
if (ret)
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
platform_set_drvdata(pdev, &dsi->encoder);
|
platform_set_drvdata(pdev, dsi);
|
||||||
|
|
||||||
pm_runtime_enable(dev);
|
pm_runtime_enable(dev);
|
||||||
|
|
||||||
|
@ -1827,17 +1827,12 @@ static int exynos_dsi_probe(struct platform_device *pdev)
|
||||||
|
|
||||||
err_disable_runtime:
|
err_disable_runtime:
|
||||||
pm_runtime_disable(dev);
|
pm_runtime_disable(dev);
|
||||||
of_node_put(dsi->in_bridge_node);
|
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int exynos_dsi_remove(struct platform_device *pdev)
|
static int exynos_dsi_remove(struct platform_device *pdev)
|
||||||
{
|
{
|
||||||
struct exynos_dsi *dsi = platform_get_drvdata(pdev);
|
|
||||||
|
|
||||||
of_node_put(dsi->in_bridge_node);
|
|
||||||
|
|
||||||
pm_runtime_disable(&pdev->dev);
|
pm_runtime_disable(&pdev->dev);
|
||||||
|
|
||||||
component_del(&pdev->dev, &exynos_dsi_component_ops);
|
component_del(&pdev->dev, &exynos_dsi_component_ops);
|
||||||
|
@ -1847,8 +1842,7 @@ static int exynos_dsi_remove(struct platform_device *pdev)
|
||||||
|
|
||||||
static int __maybe_unused exynos_dsi_suspend(struct device *dev)
|
static int __maybe_unused exynos_dsi_suspend(struct device *dev)
|
||||||
{
|
{
|
||||||
struct drm_encoder *encoder = dev_get_drvdata(dev);
|
struct exynos_dsi *dsi = dev_get_drvdata(dev);
|
||||||
struct exynos_dsi *dsi = encoder_to_dsi(encoder);
|
|
||||||
const struct exynos_dsi_driver_data *driver_data = dsi->driver_data;
|
const struct exynos_dsi_driver_data *driver_data = dsi->driver_data;
|
||||||
int ret, i;
|
int ret, i;
|
||||||
|
|
||||||
|
@ -1878,8 +1872,7 @@ static int __maybe_unused exynos_dsi_suspend(struct device *dev)
|
||||||
|
|
||||||
static int __maybe_unused exynos_dsi_resume(struct device *dev)
|
static int __maybe_unused exynos_dsi_resume(struct device *dev)
|
||||||
{
|
{
|
||||||
struct drm_encoder *encoder = dev_get_drvdata(dev);
|
struct exynos_dsi *dsi = dev_get_drvdata(dev);
|
||||||
struct exynos_dsi *dsi = encoder_to_dsi(encoder);
|
|
||||||
const struct exynos_dsi_driver_data *driver_data = dsi->driver_data;
|
const struct exynos_dsi_driver_data *driver_data = dsi->driver_data;
|
||||||
int ret, i;
|
int ret, i;
|
||||||
|
|
||||||
|
|
|
@ -522,6 +522,15 @@ static const struct hdmiphy_config hdmiphy_5420_configs[] = {
|
||||||
0x54, 0x4B, 0x25, 0x03, 0x00, 0x80, 0x01, 0x80,
|
0x54, 0x4B, 0x25, 0x03, 0x00, 0x80, 0x01, 0x80,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
.pixel_clock = 154000000,
|
||||||
|
.conf = {
|
||||||
|
0x01, 0xD1, 0x20, 0x01, 0x40, 0x30, 0x08, 0xCC,
|
||||||
|
0x8C, 0xE8, 0xC1, 0xD8, 0x45, 0xA0, 0xAC, 0x80,
|
||||||
|
0x08, 0x80, 0x09, 0x84, 0x05, 0x02, 0x24, 0x86,
|
||||||
|
0x54, 0x3F, 0x25, 0x03, 0x00, 0x00, 0x01, 0x80,
|
||||||
|
},
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct hdmiphy_config hdmiphy_5433_configs[] = {
|
static const struct hdmiphy_config hdmiphy_5433_configs[] = {
|
||||||
|
|
Loading…
Reference in New Issue