summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2015-06-20drm/exynos: add exynos specific .atomic_commit()Gustavo Padovan
exynos needs to update planes with the crtc enabled (mainly for the FIMD case) so this specific atomic commit changes the order of drm_atomic_helper_commit_modeset_enables() and drm_atomic_helper_commit_planes() to commit planes after we enable crtc and encoders. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: move exynos_drm_crtc_disable()Gustavo Padovan
This is a preparation commit to move exynos_drm_crtc_disable() together with the future exynos_drm_crtc_enable() that will come from the split of exynos_drm_crtc_dpms() callback. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: don't disable unused functions at initGustavo Padovan
Everything starts disabled so we don't really need to disable anything. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Joonyoung Shim <jy0922.shim@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: remove exported functions from exynos_drm_planeGustavo Padovan
Now that no one is using the functions exported by exynos_drm_plane due to the atomic conversion we can make remove some of the them or make them static. v2: remove unused exynos_drm_crtc v3: fix checkpatch error (reported by Joonyoung) Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Joonyoung Shim <jy0922.shim@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: atomic phase 3: convert page flipsGustavo Padovan
PageFlips now use the atomic helper to work through the atomic modesetting API. Async page flips are not supported yet. v2: Add .atomic_begin() step to handle the vblank part we removed from exynos page_flip code. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Joonyoung Shim <jy0922.shim@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: atomic phase 3: use atomic .set_config helperGustavo Padovan
Now that phase 1 and 2 are complete switch .set_config helper to use the atomic one. v2: also remove .prepare() callback v3: remove .mode_set() and .mode_set_base() and encoder's .prepare() callbacks Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Joonyoung Shim <jy0922.shim@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: atomic phase 3: atomic updates of planesGustavo Padovan
Now that phase 1 and 2 are complete we can switch the update/disable_plane callbacks to their atomic version. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Joonyoung Shim <jy0922.shim@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: atomic phase 2: keep track of framebuffer pointerGustavo Padovan
Use drm_atomic_set_fb_for_plane() in the legacy page_flip path to keep track of the framebuffer pointer and reference. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Joonyoung Shim <jy0922.shim@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: atomic phase 2: wire up state reset(), duplicate() and destroy()Gustavo Padovan
Set CRTC, planes and connectors to use the default implementations from the atomic helper library. The helpers will work to keep track of state for each DRM object. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Joonyoung Shim <jy0922.shim@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: use adjusted_mode of crtc_state instead of modeJoonyoung Shim
Handle changes by removing copy from adjusted_mode to mode as using adjusted_mode of crtc_state. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: atomic phase 1: add .mode_set_nofb() callbackGustavo Padovan
The new atomic infrastructure needs the .mode_set_nofb() callback to update CRTC timings before setting any plane. v2: remove WARN_ON(!crtc->state) from mode_set_nofb Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Joonyoung Shim <jy0922.shim@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: atomic phase 1: use drm_plane_helper_disable()Gustavo Padovan
The atomic helper to disable planes also uses the optional .atomic_disable() helper. The unique operation it does is calling .win_disable() Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Joonyoung Shim <jy0922.shim@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: atomic phase 1: use drm_plane_helper_update()Gustavo Padovan
Rip out the check from exynos_update_plane() and create exynos_check_plane() for the check phase enabling use to use the atomic helpers to call our check and update phases when updating planes. Update all users of exynos_update_plane() accordingly to call exynos_check_plane() before. Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Reviewed-by: Joonyoung Shim <jy0922.shim@samsung.com> Tested-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de>y Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-20drm/exynos: fix source data argument for planeJoonyoung Shim
The exynos_update_plane function needs 16.16 fixed point source data. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Reviewed-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2015-06-18Merge branch 'virtio-gpu-drm-next' of git://git.kraxel.org/linux into drm-nextDave Airlie
fixes and virtio-vga support. * 'virtio-gpu-drm-next' of git://git.kraxel.org/linux: virtio-gpu: add locking for vbuf pool drm/virtgpu: initialise fbdev after getting initial display info Add virtio-vga bits.
2015-06-18Merge tag 'drm/panel/for-4.2-rc1' of ↵Dave Airlie
git://anongit.freedesktop.org/tegra/linux into drm-next drm/panel: Changes for v4.2-rc1 This contains fixes for the long-standing build issues that some of the bridge drivers were exposing. Other than that it's mostly cleanup and a couple of new simple panels that are supported. * tag 'drm/panel/for-4.2-rc1' of git://anongit.freedesktop.org/tegra/linux: drm/panel: simple: Add bus format for HannStar HSD100PXN1 drm/panel: simple: Add display timing for HannStar HSD100PXN1 drm/panel: ld9040: Remove useless padding drm/panel: Constify OF match tables drm/bridge: Remove stale ptn3460.h include drm/bridge: ps8622: Include linux/gpio/consumer.h drm/bridge: ptn3460: Include linux/gpio/consumer.h drm/bridge: dw-hdmi: Return number of EDID modes drm/panel: simple: Add support for LG LB070WV8 800x480 7" panel drm/bridge: ptn3460: Pass flags to devm_gpiod_get() drm/bridge: ps8622: Pass flags to devm_gpiod_get() drm/bridge: ptn3460: Fix I2C ID table to match the reported modalias drm/bridge: dw-hdmi: Staticize dw_hdmi_bridge_funcs
2015-06-18Merge tag 'drm/tegra/for-4.2-rc1' of ↵Dave Airlie
git://anongit.freedesktop.org/tegra/linux into drm-next drm/tegra: Changes for v4.2-rc1 This contains a couple of mostly fixes for issues that have crept up in recent versions of linux-next. One issue is that DP AUX transactions of more than 4 bytes will access the wrong FIFO registers and hence become corrupt. Another fix is required to restore functionality of Tegra20 if using the GART. The current code expects the IOMMU aperture to be the complete 4 GiB address space, whereas the GART on Tegra20 only provides a 128 MiB aperture. One more issue with IOMMU support is that on 64-bit ARM, swiotlb is the default IOMMU implementation backing the DMA API. A side-effect of that is that when dma_map_sg() is called to flush caches (yes, this is a bit of a hack, but ARM does not provide a better API), swiotlb will immediately run out of memory because its bounce buffer is too small to make a framebuffer. Finally I've included a mostly cosmetic fix that stores register values in u32 rather than unsigned long to avoid sign-extension issues on 64- bit ARM. This is only a precaution since it hasn't caused any issues (yet). * tag 'drm/tegra/for-4.2-rc1' of git://anongit.freedesktop.org/tegra/linux: drm/tegra: dpaux: Registers are 32-bit drm/tegra: gem: Flush pages after allocation drm/tegra: gem: Take into account IOMMU aperture drm/tegra: dpaux: Fix transfers larger than 4 bytes
2015-06-18Merge branch 'drm/next/du' of git://linuxtv.org/pinchartl/fbdev into drm-nextDave Airlie
rcar-du fixes * 'drm/next/du' of git://linuxtv.org/pinchartl/fbdev: drm: rcar-du: Use the drm atomic state duplication helpers for planes drm: rcar-du: Clean up planes in the error paths of .atomic_commit() drm: rcar-du: Convert rcar_du_encoders_init_one() return value to 0/<0 drm: rcar-du: Clarify error message when encoder initialization fails drm: rcar-du: Fix crash with groups that have less than 9 planes drm: rcar-du: Disable all planes when stopping the CRTC drm: rcar-du: Print the error value when DRM/KMS init fails
2015-06-18Merge tag 'drm-amdkfd-next-fixes-2015-06-16' of ↵Dave Airlie
git://people.freedesktop.org/~gabbayo/linux into drm-next - Dan fixed some range checks in the address watch ioctl impl. - Remove obsolete member from radeon_device structure * tag 'drm-amdkfd-next-fixes-2015-06-16' of git://people.freedesktop.org/~gabbayo/linux: drm/amdkfd: fix some range checks in address watch ioctl drm/radeon: remove obsolete kfd_bo from radeon_device
2015-06-16drm/amdkfd: fix some range checks in address watch ioctlDan Carpenter
buf_size_in_bytes must be large enough to hold ->num_watch_points and watch_mode so I have added a sizeof(int) * 2 to the minimum size. Also we have to subtract sizeof(*args) from the max args_idx limit so that it matches the allocation. Also I changed a > to >= for the last compare. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
2015-06-16drm: rcar-du: Use the drm atomic state duplication helpers for planesLaurent Pinchart
Ensure that the duplicate and destroy plane state operations will always be in sync with the DRM core implementation of the plane state by using the __drm_atomic_helper_plane_duplicate_state() and __drm_atomic_helper_plane_destroy_state() functions designed especially for this purpose. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
2015-06-16drm: rcar-du: Clean up planes in the error paths of .atomic_commit()Laurent Pinchart
When the .atomic_commit() handler fails, clean up planes previoulsy prepared by drm_atomic_helper_prepare_planes() with a call to drm_atomic_helper_cleanup_planes(). Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
2015-06-16drm: rcar-du: Convert rcar_du_encoders_init_one() return value to 0/<0Laurent Pinchart
The function returns 1 on success, and either 0 or a negative error code on failure. As the 0 and negative values don't need to be differentiated by the caller, convert it to the usual scheme of returning 0 on success and a negative error code on failure. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
2015-06-16drm: rcar-du: Clarify error message when encoder initialization failsLaurent Pinchart
A failure to initialize an encoder currently prints an error message in the kernel log without mentioning which encoder failed to initialize. To help debugging initialization issues print the encoder DT node name. This requires moving the error message to the rcar_du_encoders_init_one function and refactoring it slightly. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
2015-06-16drm: rcar-du: Fix crash with groups that have less than 9 planesLaurent Pinchart
Commit 917de180379d ("drm: rcar-du: Implement universal plane support") made the number of planes per group dynamic, but didn't update all loops over the planes array, resulting in out-of-bound accesses on DU instances that have an odd number of CRTCs (such as the R8A7790). Fix it. Fixes: 917de180379d ("drm: rcar-du: Implement universal plane support") Cc: stable@vger.kernel.org Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
2015-06-16drm: rcar-du: Disable all planes when stopping the CRTCLaurent Pinchart
The DSnPR plane configuration registers are updated on vblank, and no vblank will occur once the CRTC is stopped. We thus can't only disable planes right before starting the CRTC as it would start scanning out immediately from old frame buffers until the next vblank. Fix the problem by disabling all planes when stopping the CRTC and wait for the change to take effect. This increases the CRTC stop delay, especially when multiple CRTCs are stopped in one operation as we now wait for one vblank per CRTC. Whether this can be improved needs to be researched. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
2015-06-16drm: rcar-du: Print the error value when DRM/KMS init failsLaurent Pinchart
This helps debugging probe failures. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
2015-06-16virtio-gpu: add locking for vbuf poolDave Airlie
Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2015-06-16drm/virtgpu: initialise fbdev after getting initial display infoDave Airlie
This should avoid issues with the fbdev path trying to render before we've gotten the display info. Signed-off-by: Dave Airlie <airlied@redhat.com> [ kraxel: wait for display-info reply ] Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2015-06-16Add virtio-vga bits.Gerd Hoffmann
2015-06-16drm/radeon: remove obsolete kfd_bo from radeon_deviceOded Gabbay
Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
2015-06-16Merge tag 'omapdrm-4.2-atomic' of ↵Dave Airlie
git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux into drm-next omapdrm atomic modesetting support Atomic modesetting support for omapdrm. " we've had issues with omapdrm for years, which we've not been able to fix properly (like warnings/crashes when unloading modules, page-flips tearing, race issues with fbs). All those problems seem to be gone after this rewrite of omapdrm for atomic modesetting, and the resulting code is much cleaner and more maintainable." * tag 'omapdrm-4.2-atomic' of git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux: (43 commits) drm: omapdrm: new vblank and event handling drm: omapdrm: merge omap_crtc_flush and omap_crtc_atomic_flush drm: omapdrm: add lock for fb pinning drm: omapdrm: if omap_plane_atomic_update fails, disable plane drm: omapdrm: inline omap_plane_setup into update/disable drm: omapdrm: omap_plane_setup() cannot fail, use WARN drm: omapdrm: Don't setup planes manually from CRTC .enable()/.disable() drm: omapdrm: Don't flush CRTC when enabling or disabling it drm: omapdrm: Move encoder setup to encoder operations drm: omapdrm: Simplify DSS power management drm: omapdrm: Remove nested PM get/sync when configuring encoders drm: omapdrm: Support unlinking page flip events prematurely drm: omapdrm: omap_crtc_flush() isn't called with modeset locked drm: omapdrm: Don't get/put dispc in omap_crtc_flush() drm: omapdrm: Make the omap_crtc_flush function static drm: omapdrm: Remove omap_plane enabled field drm: omapdrm: Remove omap_crtc enabled field drm: omapdrm: Move crtc info out of the crtc structure drm: omapdrm: Move plane info and win out of the plane structure drm: omapdrm: Switch crtc and plane set_property to atomic helpers ...
2015-06-12drm: omapdrm: new vblank and event handlingTomi Valkeinen
Rework the crtc event/flip_wait system as follows: - If we enable a crtc (full modeset), we set omap_crtc->pending and register vblank irq. - If we need to set GO bit (page flip), we do the same but also set the GO bit. - On vblank we unregister the irq, clear the 'pending' flag, send vblank event to userspace if crtc->state->event != NULL, and wake up 'pending_wait' wq. - In omap_atomic_complete() we wait for the 'pending' flag to get reset for all enabled crtcs using 'pending_wait' wq. The above ensures that we send the events to userspace in vblank, and that after the wait in omap_atomic_complete() everything for the affected crtcs has been completed. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
2015-06-12drm: omapdrm: merge omap_crtc_flush and omap_crtc_atomic_flushTomi Valkeinen
omap_crtc_atomic_flush() is the only user of omap_crtc_flush(), so just move the code from omap_crtc_flush() to omap_crtc_atomic_flush(). Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
2015-06-12drm: omapdrm: add lock for fb pinningTomi Valkeinen
Before atomic modesetting omap_framebuffer_pin() and omap_framebuffer_unpin() were always called with modesetting locks taken. With atomic modesetting support this is no longer the case, and we need locking to protect the pin_count and the paddr, as multiple threads may pin the same fb concurrently. This patch adds a mutex to struct omap_framebuffer, and uses it in omap_framebuffer_pin() and omap_framebuffer_unpin(). Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
2015-06-12drm: omapdrm: if omap_plane_atomic_update fails, disable planeTomi Valkeinen
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>
2015-06-12drm: omapdrm: inline omap_plane_setup into update/disableTomi Valkeinen
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>
2015-06-12drm: omapdrm: omap_plane_setup() cannot fail, use WARNTomi Valkeinen
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>
2015-06-12drm: omapdrm: Don't setup planes manually from CRTC .enable()/.disable()Laurent Pinchart
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>
2015-06-12drm: omapdrm: Don't flush CRTC when enabling or disabling itLaurent Pinchart
The omap_crtc_flush() call in omap_crtc_enable() and omap_crtc_disable() is a no-op, as the display manager is always disabled at this point. Just remove the function call. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2015-06-12drm: omapdrm: Move encoder setup to encoder operationsLaurent Pinchart
Now that the driver is fully converted to atomic operations, and that the atomic helpers call the operations in the right order, we can move encoder setup to where it belongs, in the encoder operations. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2015-06-12drm: omapdrm: Simplify DSS power managementLaurent Pinchart
Instead of sprinkling dispc_runtime_get() and dispc_runtime_put() calls in various CRTC operations, move all power management code to the atomic commit function. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2015-06-12drm: omapdrm: Remove nested PM get/sync when configuring encodersLaurent Pinchart
The omap_crtc_encoder_setup() function is always called with the DSS enabled. Remove the dispc_runtime_get() and dispc_runtime_put() calls. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2015-06-12drm: omapdrm: Support unlinking page flip events prematurelyLaurent Pinchart
DRM page flip vblank events requested by page flips or atomic commits are created by the DRM core and then passed to driver through CRTC states (for atomic commit) or directly to the page flip handler (for legacy page flips). The events are then kept aside until the page flip completes, at which point drivers queue them for delivery with a call to drm_send_vblank_event(). When a DRM file handle is closed events pending for delivery are cleaned up automatically by the DRM core. Events that have been passed to the driver but haven't completed yet, however, are not handled by the DRM core. Drivers are responsible for destroying them and must not attempt to queue them for delivery. This is usually handled by drivers' preclose() handlers that cancel and destroy page flip events that reference the file handle being closed. With asynchronous atomic updates the story becomes more complex. Several asynchronous atomic updates can be pending, each of them carrying per-CRTC events. As the atomic_commit() operation doesn't receive a file handle context, drivers can't know which file handle a pending update refers to, making it difficult to cancel or wait for completion of updates related to the file handle being closed. It should be noted that cancelling page flips or waiting for atomic updates completion isn't required by the DRM core when closing a file handle. The only requirement is that no event gets queued for delivery after the preclose() operation returns. This can easily be achieved by storing events for atomic commits in a list, unlinking events from the file handle being closed by setting the file_priv field to NULL, and skipping delivery of unlinked events. This logic replaces the page flip cancellation completely. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2015-06-12drm: omapdrm: omap_crtc_flush() isn't called with modeset lockedLaurent Pinchart
When performing asynchronous atomic updates the modeset lock isn't taken around the callers of omap_crtc_flush(). This isn't an issue though, as access to the CRTC is properly serialized. Just drop the warning. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2015-06-12drm: omapdrm: Don't get/put dispc in omap_crtc_flush()Laurent Pinchart
The omap_crtc_flush() function is always called with a reference to the dispc held. Remove unnecessary calls to dispc_runtime_get() and dispc_runtime_put(). Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2015-06-12drm: omapdrm: Make the omap_crtc_flush function staticLaurent Pinchart
The function isn't used outside of its compilation unit, make it static. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2015-06-12drm: omapdrm: Remove omap_plane enabled fieldLaurent Pinchart
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>
2015-06-12drm: omapdrm: Remove omap_crtc enabled fieldLaurent Pinchart
The field tracks the CRTC state to avoid double-enable or -disable. As the DRM atomic core guarantees that the CRTC enable and disable functions won't be called on an already enabled or disabled CRTC, such tracking isn't needed. Remove the enabled field. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2015-06-12drm: omapdrm: Move crtc info out of the crtc structureLaurent Pinchart
The crtc info structure is only used to setup the crtc through the DSS API. Move it from the crtc structure to local variables in omap_crtc_dss_enable(). Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>