History log of /openbmc/linux/drivers/gpu/drm/omapdrm/omap_plane.c (Results 126 – 150 of 184)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# c283400a 05-Nov-2015 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm/omap: move dispc related dss-feat funcs to dispc

omapdrm still uses a few non-dispc functions: dss_feat_get_num_mgrs(),
dss_feat_get_num_ovls() and dss_feat_get_supported_color_mode

drm/omap: move dispc related dss-feat funcs to dispc

omapdrm still uses a few non-dispc functions: dss_feat_get_num_mgrs(),
dss_feat_get_num_ovls() and dss_feat_get_supported_color_modes(). We
want to provide omapdrm a single dispc_ops function pointer struct so
that omapdrm will use either the current omapdss or the new omapdss6
driver depending on the platform.

Those three functions are really dispc functions, but are located in the
dss_features.c for legacy reasons.

This patch adds similar functionss to the dispc, and changes omapdrm to
use those new functions. Underneath the functions still call the
functions from dss_feature.c.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

show more ...


Revision tags: openbmc-20151104-1, v4.3, openbmc-20151102-1, openbmc-20151028-1, v4.3-rc1, v4.2, v4.2-rc8, v4.2-rc7, v4.2-rc6, v4.2-rc5, v4.2-rc4, v4.2-rc3, v4.2-rc2, v4.2-rc1, v4.1, v4.1-rc8, v4.1-rc7, v4.1-rc6
# 728ae8dd 27-May-2015 Laurent Pinchart <laurent.pinchart@ideasonboard.com>

drm: omapdrm: Handle FIFO underflow IRQs internally

As the FIFO underflow IRQ handler just prints an error message to the
kernel log, simplify the code by not registering one IRQ handler

drm: omapdrm: Handle FIFO underflow IRQs internally

As the FIFO underflow IRQ handler just prints an error message to the
kernel log, simplify the code by not registering one IRQ handler per
plane but print the messages directly from the main IRQ handler.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

show more ...


# e43f2c33 02-Dec-2016 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm/omap: fix primary-plane's possible_crtcs

We set the possible_crtc for all planes to "(1 << priv->num_crtcs) - 1",
which is fine as the HW planes can be used fro all crtcs. However, w

drm/omap: fix primary-plane's possible_crtcs

We set the possible_crtc for all planes to "(1 << priv->num_crtcs) - 1",
which is fine as the HW planes can be used fro all crtcs. However, when
we're doing that, we are still incrementing 'num_crtcs', and we'll end
up with bad possible_crtcs, preventing the use of the primary planes.

This patch passes a possible_crtcs mask to plane init function so that
we get correct possible_crtc.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

show more ...


# cfb73f20 10-Jun-2016 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm/omap: print error instead of WARN() if plane setup fails

omap_plane_atomic_update() does WARN_ON() if dispc rejects the given
plane config. Change that to dev_err() to lessen the pos

drm/omap: print error instead of WARN() if plane setup fails

omap_plane_atomic_update() does WARN_ON() if dispc rejects the given
plane config. Change that to dev_err() to lessen the possible spam.

To fix this correctly, the plane setup needs much more work by creating
a check function for dispc setup, so that we could reliably check the
config in atomic_check, instead of only noticing the problem when
programming dispc.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

show more ...


# 70dd2a62 10-Jun-2016 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm/omap: cleanup omap_plane_atomic_check()

Clean up omap_plane_atomic_check() with:

- Check state->fb first. If no fb, return 0.
- use drm_atomic_get_existing_crtc_state() inst

drm/omap: cleanup omap_plane_atomic_check()

Clean up omap_plane_atomic_check() with:

- Check state->fb first. If no fb, return 0.
- use drm_atomic_get_existing_crtc_state() instead of
drm_atomic_get_crtc_state()

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

show more ...


# aaf7642e 10-Jun-2016 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm/omap: fix plane check when crtc is disabled

I sometimes see:

[drm:drm_framebuffer_remove [drm]] *ERROR* failed to reset crtc ed2a6c00
when fb was deleted: -22

which

drm/omap: fix plane check when crtc is disabled

I sometimes see:

[drm:drm_framebuffer_remove [drm]] *ERROR* failed to reset crtc ed2a6c00
when fb was deleted: -22

which comes from drm_framebuffer_remove() when it's disabling the crtc
with zeroed drm_mode_set.

The problem in omap_plane_atomic_check() is that it will use those
zeroed fields to verify if the setup is correct.

This patch makes omap_plane_atomic_check() return 0 if the crtc is
disabled.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

show more ...


# 0da88db1 26-Sep-2016 Ville Syrjälä <ville.syrjala@linux.intel.com>

drm/omap: Use per-plane rotation property

The global mode_config.rotation_property is going away, switch over to
per-plane rotation_property.

Not sure I got the annoying crtc ro

drm/omap: Use per-plane rotation property

The global mode_config.rotation_property is going away, switch over to
per-plane rotation_property.

Not sure I got the annoying crtc rotation_property handling right.
Might work, or migth not.

v2: Drop the BIT()
Don't create rotation property twice for each primary plane

Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
Cc: Rob Clark <robdclark@gmail.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
[danvet: Add comment per discussion between Tomi&Ville.]
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/1474907460-10717-8-git-send-email-ville.syrjala@linux.intel.com

show more ...


# 18391ec0 26-Sep-2016 Ville Syrjälä <ville.syrjala@linux.intel.com>

drm/omap: Set rotation property initial value to BIT(DRM_ROTATE_0) insted of 0

0 isn't a valid rotation property value, so let's set the initial value
of the property to BIT(DRM_ROTATE_0

drm/omap: Set rotation property initial value to BIT(DRM_ROTATE_0) insted of 0

0 isn't a valid rotation property value, so let's set the initial value
of the property to BIT(DRM_ROTATE_0) instead.

v2: Drop the BIT()

Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
Cc: Rob Clark <robdclark@gmail.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/1474907460-10717-7-git-send-email-ville.syrjala@linux.intel.com

show more ...


# bd2ef25d 26-Sep-2016 Ville Syrjälä <ville.syrjala@linux.intel.com>

drm: Add drm_rotation_90_or_270()

We have intel_rotation_90_or_270() in i915 to check if the rotation is
90 or 270 degrees. Similar checks are elsewhere in drm, so let's move
the hel

drm: Add drm_rotation_90_or_270()

We have intel_rotation_90_or_270() in i915 to check if the rotation is
90 or 270 degrees. Similar checks are elsewhere in drm, so let's move
the helper into a central place and use it everwhere.

v2: Drop the BIT()
Convert all new intel_rotation_90_or_270() calls
Deal with superfluous code shuffling

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> (v1)
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/1474907460-10717-2-git-send-email-ville.syrjala@linux.intel.com

show more ...


# 1832040d 18-Aug-2016 Chris Wilson <chris@chris-wilson.co.uk>

drm: Allow drivers to modify plane_state in prepare_fb/cleanup_fb

The drivers have to modify the atomic plane state during the prepare_fb
callback so they track allocations, reservations

drm: Allow drivers to modify plane_state in prepare_fb/cleanup_fb

The drivers have to modify the atomic plane state during the prepare_fb
callback so they track allocations, reservations and dependencies for
this atomic operation involving this fb. In particular, how else do we
set the plane->fence from the framebuffer!

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/20160818180017.20508-1-chris@chris-wilson.co.uk

show more ...


# 31ad61e4 29-Jul-2016 Joonas Lahtinen <joonas.lahtinen@linux.intel.com>

drm: BIT(DRM_ROTATE_?) -> DRM_ROTATE_?

Only property creation uses the rotation as an index, so convert the
to figure the index when needed.

v2: Use the new defines to build the

drm: BIT(DRM_ROTATE_?) -> DRM_ROTATE_?

Only property creation uses the rotation as an index, so convert the
to figure the index when needed.

v2: Use the new defines to build the _MASK defines (Sean)

Cc: intel-gfx@lists.freedesktop.org
Cc: linux-arm-msm@vger.kernel.org
Cc: freedreno@lists.freedesktop.org
Cc: malidp@foss.arm.com
Cc: David Airlie <airlied@linux.ie>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Liviu Dudau <Liviu.Dudau@arm.com>
Cc: Sean Paul <seanpaul@chromium.org>
Acked-by: Liviu Dudau <Liviu.Dudau@arm.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> (v1)
Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Link: http://patchwork.freedesktop.org/patch/msgid/1469771405-17653-1-git-send-email-joonas.lahtinen@linux.intel.com

show more ...


# 2f701695 09-May-2016 Daniel Vetter <daniel.vetter@ffwll.ch>

drm: Drop plane argument from __drm_atomic_helper_plane_destroy_state

It's unused, and really this helper should only look at the state
structure and nothing else.

v2: Fix commi

drm: Drop plane argument from __drm_atomic_helper_plane_destroy_state

It's unused, and really this helper should only look at the state
structure and nothing else.

v2: Fix commit message (Laurent).

v3: Rebase onto mtk driver merge.

Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Thierry Reding <thierry.reding@gmail.com>
Cc: Eric Anholt <eric@anholt.net>
Cc: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Cc: Inki Dae <inki.dae@samsung.com>
Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
Cc: Mark Yao <mark.yao@rock-chips.com>
Acked-by: Thierry Reding <thierry.reding@gmail.com>
Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/1462804451-15318-2-git-send-email-daniel.vetter@ffwll.ch

show more ...


# bfeece55 27-Aug-2015 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm/omap: check if rotation is supported before commit

omapdrm is missing a check on the validity of the rotation property.
This leads to omapdrm possibly trying to use rotation on non-r

drm/omap: check if rotation is supported before commit

omapdrm is missing a check on the validity of the rotation property.
This leads to omapdrm possibly trying to use rotation on non-rotateable
framebuffer, which causes the overlay setup to fail.

This patch adds the necessary check to omap_plane_atomic_check().

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

show more ...


# f8ef29ee 14-Dec-2015 Laurent Pinchart <laurent.pinchart@ideasonboard.com>

drm: omapdrm: Fix plane state free in plane reset handler

The plane reset handler frees the plane state and allocates a new
default state, but when doing so attempt to free the plane sta

drm: omapdrm: Fix plane state free in plane reset handler

The plane reset handler frees the plane state and allocates a new
default state, but when doing so attempt to free the plane state using
the base plane state pointer instead of casting it to the
driver-specific state object that has been allocated. Fix it by using
the omap_plane_atomic_destroy_state() function to destroy the plane
state instead of duplicating the code.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
[tomi.valkeinen@ti.com: move of the func into separate patch]
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

show more ...


# e07323cf 15-Dec-2015 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm: omapdrm: move omap_plane_reset()

Move omap_plane_reset() function to avoid forward declarations in the
next patch.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>


# b0b3b795 09-Dec-2015 Ville Syrjälä <ville.syrjala@linux.intel.com>

drm: Pass 'name' to drm_universal_plane_init()

Done with coccinelle for the most part. It choked on
msm/mdp/mdp5/mdp5_plane.c like so:
"BAD:!!!!! enum drm_plane_type type;"
No i

drm: Pass 'name' to drm_universal_plane_init()

Done with coccinelle for the most part. It choked on
msm/mdp/mdp5/mdp5_plane.c like so:
"BAD:!!!!! enum drm_plane_type type;"
No idea how to deal with that, so I just fixed that up
by hand.

Also it thinks '...' is part of the semantic patch, so I put an
'int DOTDOTDOT' placeholder in its place and got rid of it with
sed afterwards.

I didn't convert drm_plane_init() since passing the varargs through
would mean either cpp macros or va_list, and I figured we don't
care about these legacy functions enough to warrant the extra pain.

@@
typedef uint32_t;
identifier dev, plane, possible_crtcs, funcs, formats, format_count, type;
@@
int drm_universal_plane_init(struct drm_device *dev,
struct drm_plane *plane,
unsigned long possible_crtcs,
const struct drm_plane_funcs *funcs,
const uint32_t *formats,
unsigned int format_count,
enum drm_plane_type type
+ ,const char *name, int DOTDOTDOT
)
{ ... }

@@
identifier dev, plane, possible_crtcs, funcs, formats, format_count, type;
@@
int drm_universal_plane_init(struct drm_device *dev,
struct drm_plane *plane,
unsigned long possible_crtcs,
const struct drm_plane_funcs *funcs,
const uint32_t *formats,
unsigned int format_count,
enum drm_plane_type type
+ ,const char *name, int DOTDOTDOT
);

@@
expression E1, E2, E3, E4, E5, E6, E7;
@@
drm_universal_plane_init(E1, E2, E3, E4, E5, E6, E7
+ ,NULL
)

v2: Split crtc and plane changes apart
Pass NUL for no-name instead of ""
Leave drm_plane_init() alone
v3: Add ', or NULL...' to @name kernel doc (Jani)
Annotate the function with __printf() attribute (Jani)

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/1449670795-2853-1-git-send-email-ville.syrjala@linux.intel.com

show more ...


# 14152c8d 01-Oct-2015 Joonas Lahtinen <joonas.lahtinen@linux.intel.com>

drm: Use DRM_ROTATE_MASK and DRM_REFLECT_MASK

Avoid magic numbers and use the introduced defines.

Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Joonas Lahtine

drm: Use DRM_ROTATE_MASK and DRM_REFLECT_MASK

Avoid magic numbers and use the introduced defines.

Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>

show more ...


# 844f9111 02-Sep-2015 Maarten Lankhorst <maarten.lankhorst@linux.intel.com>

drm/atomic: Make prepare_fb/cleanup_fb only take state, v3.

This removes the need to separately track fb changes i915.
That will be done as a separate commit, however.

Changes s

drm/atomic: Make prepare_fb/cleanup_fb only take state, v3.

This removes the need to separately track fb changes i915.
That will be done as a separate commit, however.

Changes since v1:
- Add dri-devel to cc.
- Fix a check in intel's prepare and cleanup fb to take rotation
into account.
Changes since v2:
- Split out i915 changes to a separate commit.

Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
[danvet: Squash in msm fixup from Maarten.]
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>

show more ...


# c423bc85 16-Jun-2015 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm/omap: check that plane is inside crtc

DRM allows planes to be partially off-screen, but DSS hardware does not.
This patch adds the necessary check to reject plane configs if the plan

drm/omap: check that plane is inside crtc

DRM allows planes to be partially off-screen, but DSS hardware does not.
This patch adds the necessary check to reject plane configs if the plane
is not fully inside the crtc.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

show more ...


# 794a65ff 29-May-2015 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm: omapdrm: if omap_plane_atomic_update fails, disable plane

omap_plane_atomic_update() calls dispc_ovl_setup(), which can fail (but
shouldn't). To make the code a bit more robust, mak

drm: omapdrm: if omap_plane_atomic_update fails, disable plane

omap_plane_atomic_update() calls dispc_ovl_setup(), which can fail (but
shouldn't). To make the code a bit more robust, make sure the plane gets
disabled if dispc_ovl_setup() fails, as otherwise we might get illegal
HW configuration leading to error interrupts.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

show more ...


# 11ffd031 29-May-2015 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm: omapdrm: inline omap_plane_setup into update/disable

At the moment we have omap_plane_setup() function which handles both
enabling (and configuring) and disabling the plane. With at

drm: omapdrm: inline omap_plane_setup into update/disable

At the moment we have omap_plane_setup() function which handles both
enabling (and configuring) and disabling the plane. With atomic
modesetting we have separate hooks for plane enable/config and disable.

This patch moves the code from omap_plane_setup() to
omap_plane_atomic_update() and omap_plane_atomic_disable().

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

show more ...


# d9157dfd 29-May-2015 Tomi Valkeinen <tomi.valkeinen@ti.com>

drm: omapdrm: omap_plane_setup() cannot fail, use WARN

With atomic modesetting, omap_plane_setup()'s return value is ignored as
the functions using it cannot fail. dispc_ovl_setup(), cal

drm: omapdrm: omap_plane_setup() cannot fail, use WARN

With atomic modesetting, omap_plane_setup()'s return value is ignored as
the functions using it cannot fail. dispc_ovl_setup(), called by
omap_plane_setup(), can fail (but shouldn't).

Instead of returning an error from omap_plane_setup() which gets
ignored, return void and use WARN if dispc_ovl_setup() fails.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

show more ...


# 0dce4d75 27-May-2015 Laurent Pinchart <laurent.pinchart@ideasonboard.com>

drm: omapdrm: Don't setup planes manually from CRTC .enable()/.disable()

Planes setup is handled by the DRM core through the atomic helpers,
there's no need to duplicate the code in the

drm: omapdrm: Don't setup planes manually from CRTC .enable()/.disable()

Planes setup is handled by the DRM core through the atomic helpers,
there's no need to duplicate the code in the CRTC .enable() and
.disable() operations.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

show more ...


Revision tags: v4.1-rc5, v4.1-rc4, v4.1-rc3, v4.1-rc2, v4.1-rc1, v4.0, v4.0-rc7, v4.0-rc6, v4.0-rc5, v4.0-rc4, v4.0-rc3
# edc72557 06-Mar-2015 Laurent Pinchart <laurent.pinchart@ideasonboard.com>

drm: omapdrm: Remove omap_plane enabled field

The field tracks the plane state to avoid double-enable or -disable.
This isn't required anymore, as

- the DRM atomic core guarante

drm: omapdrm: Remove omap_plane enabled field

The field tracks the plane state to avoid double-enable or -disable.
This isn't required anymore, as

- the DRM atomic core guarantees that the plane atomic_update and
atomic_disable functions will never be called on an enabled/disabled
plane

- the CRTC enable/disable operations that enable/disable the plane are
already guarded against double enable/disable

We can thus remove the enabled field completely. The
omap_plane_set_enable() function then becomes a wrapper around
omap_plane_setup() which can be called directly.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

show more ...


# fb730c9b 06-Mar-2015 Laurent Pinchart <laurent.pinchart@ideasonboard.com>

drm: omapdrm: Move plane info and win out of the plane structure

The plane info and win structures are only used to setup the plane
through the DSS API. Move them from the plane structur

drm: omapdrm: Move plane info and win out of the plane structure

The plane info and win structures are only used to setup the plane
through the DSS API. Move them from the plane structure to local
variables in omap_plane_setup().

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>

show more ...


12345678