Merge v5.0-rc7 into drm-next
Backmerging for nouveau and imx that needed some fixes for next pulls. Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
@@ -46,7 +46,6 @@ struct meson_crtc {
|
||||
struct drm_crtc base;
|
||||
struct drm_pending_vblank_event *event;
|
||||
struct meson_drm *priv;
|
||||
bool enabled;
|
||||
};
|
||||
#define to_meson_crtc(x) container_of(x, struct meson_crtc, base)
|
||||
|
||||
@@ -82,7 +81,8 @@ static const struct drm_crtc_funcs meson_crtc_funcs = {
|
||||
|
||||
};
|
||||
|
||||
static void meson_crtc_enable(struct drm_crtc *crtc)
|
||||
static void meson_crtc_atomic_enable(struct drm_crtc *crtc,
|
||||
struct drm_crtc_state *old_state)
|
||||
{
|
||||
struct meson_crtc *meson_crtc = to_meson_crtc(crtc);
|
||||
struct drm_crtc_state *crtc_state = crtc->state;
|
||||
@@ -108,20 +108,6 @@ static void meson_crtc_enable(struct drm_crtc *crtc)
|
||||
|
||||
drm_crtc_vblank_on(crtc);
|
||||
|
||||
meson_crtc->enabled = true;
|
||||
}
|
||||
|
||||
static void meson_crtc_atomic_enable(struct drm_crtc *crtc,
|
||||
struct drm_crtc_state *old_state)
|
||||
{
|
||||
struct meson_crtc *meson_crtc = to_meson_crtc(crtc);
|
||||
struct meson_drm *priv = meson_crtc->priv;
|
||||
|
||||
DRM_DEBUG_DRIVER("\n");
|
||||
|
||||
if (!meson_crtc->enabled)
|
||||
meson_crtc_enable(crtc);
|
||||
|
||||
priv->viu.osd1_enabled = true;
|
||||
}
|
||||
|
||||
@@ -153,8 +139,6 @@ static void meson_crtc_atomic_disable(struct drm_crtc *crtc,
|
||||
|
||||
crtc->state->event = NULL;
|
||||
}
|
||||
|
||||
meson_crtc->enabled = false;
|
||||
}
|
||||
|
||||
static void meson_crtc_atomic_begin(struct drm_crtc *crtc,
|
||||
@@ -163,9 +147,6 @@ static void meson_crtc_atomic_begin(struct drm_crtc *crtc,
|
||||
struct meson_crtc *meson_crtc = to_meson_crtc(crtc);
|
||||
unsigned long flags;
|
||||
|
||||
if (crtc->state->enable && !meson_crtc->enabled)
|
||||
meson_crtc_enable(crtc);
|
||||
|
||||
if (crtc->state->event) {
|
||||
WARN_ON(drm_crtc_vblank_get(crtc) != 0);
|
||||
|
||||
|
@@ -75,6 +75,10 @@ static const struct drm_mode_config_funcs meson_mode_config_funcs = {
|
||||
.fb_create = drm_gem_fb_create,
|
||||
};
|
||||
|
||||
static const struct drm_mode_config_helper_funcs meson_mode_config_helpers = {
|
||||
.atomic_commit_tail = drm_atomic_helper_commit_tail_rpm,
|
||||
};
|
||||
|
||||
static irqreturn_t meson_irq(int irq, void *arg)
|
||||
{
|
||||
struct drm_device *dev = arg;
|
||||
@@ -286,6 +290,7 @@ static int meson_drv_bind_master(struct device *dev, bool has_components)
|
||||
drm->mode_config.max_width = 3840;
|
||||
drm->mode_config.max_height = 2160;
|
||||
drm->mode_config.funcs = &meson_mode_config_funcs;
|
||||
drm->mode_config.helper_private = &meson_mode_config_helpers;
|
||||
|
||||
/* Hardware Initialization */
|
||||
|
||||
@@ -408,8 +413,10 @@ static int meson_probe_remote(struct platform_device *pdev,
|
||||
remote_node = of_graph_get_remote_port_parent(ep);
|
||||
if (!remote_node ||
|
||||
remote_node == parent || /* Ignore parent endpoint */
|
||||
!of_device_is_available(remote_node))
|
||||
!of_device_is_available(remote_node)) {
|
||||
of_node_put(remote_node);
|
||||
continue;
|
||||
}
|
||||
|
||||
count += meson_probe_remote(pdev, match, remote, remote_node);
|
||||
|
||||
@@ -428,10 +435,13 @@ static int meson_drv_probe(struct platform_device *pdev)
|
||||
|
||||
for_each_endpoint_of_node(np, ep) {
|
||||
remote = of_graph_get_remote_port_parent(ep);
|
||||
if (!remote || !of_device_is_available(remote))
|
||||
if (!remote || !of_device_is_available(remote)) {
|
||||
of_node_put(remote);
|
||||
continue;
|
||||
}
|
||||
|
||||
count += meson_probe_remote(pdev, &match, np, remote);
|
||||
of_node_put(remote);
|
||||
}
|
||||
|
||||
if (count && !match)
|
||||
|
Reference in New Issue
Block a user