An error occurred fetching the project authors.
- 17 May, 2018 1 commit
-
-
Thierry Reding authored
Attaching to and detaching from an IOMMU uses the same code sequence in every driver, so factor it out into separate helpers. Reviewed-by:
Dmitry Osipenko <digetx@gmail.com> Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
- 04 May, 2018 2 commits
-
-
Thierry Reding authored
If an error happens during display controller initialization, the host1x syncpoint previously requested would be leaked. Properly clean up the syncpoint along with the other resources. Reviewed-by:
Dmitry Osipenko <digetx@gmail.com> Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Dmitry Osipenko authored
Remove unneeded iommu_group_get() and add missing iommu_group_put(), correcting IOMMU group refcount. This is a minor correction / cleanup that doesn't really fix anything because Tegra's IOMMU driver are built-in and hence groups refcounting can't hold IOMMU driver from unloading. Signed-off-by:
Dmitry Osipenko <digetx@gmail.com> Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
- 28 Mar, 2018 1 commit
-
-
Wei Yongjun authored
Fixes the following sparse warnings: drivers/gpu/drm/tegra/dc.c:2181:69: warning: Using plain integer as NULL pointer Signed-off-by:
Wei Yongjun <weiyongjun1@huawei.com> Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
- 22 Mar, 2018 1 commit
-
-
Stefan Agner authored
Use tegra124_(primary|overlay)_formats for Tegra124, otherwise the count specified in the Tegra124 SoC info structure will be different from the array size and cause a crash. Fixes: 511c7023 ("drm/tegra: dc: Support more formats") Signed-off-by:
Stefan Agner <stefan@agner.ch> Acked-by:
Marcel Ziswiler <marcel.ziswiler@toradex.com> Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
- 19 Mar, 2018 1 commit
-
-
Thierry Reding authored
Detaching from an IOMMU group multiple times can lead to a crash. This could potentially be fixed in the IOMMU driver, but it's easy to avoid the subsequent detach operations in this driver, so do that as well. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
- 16 Mar, 2018 1 commit
-
-
Thierry Reding authored
Rather than subclass the global atomic state to store the hub display clock and rate, create a private object and store this data in its state. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
- 15 Mar, 2018 2 commits
-
-
Thierry Reding authored
Pass the list of valid format modifiers to planes upon initialization and implement the ->format_mod_supported() callback so that userspace can query for the valid combinations of formats and modifiers. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Dmitry Osipenko authored
Older Tegra's do not support RGBA format for the cursor, but instead overlay plane could be used for it. Since there is no much use for the overlays on a regular desktop and HW-accelerated cursor is much better than a SW cursor, let's dedicate one overlay plane to the mouse cursor. Signed-off-by:
Dmitry Osipenko <digetx@gmail.com> Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
- 15 Feb, 2018 1 commit
-
-
Dhinakaran Pandiyan authored
570e8696 ("drm: Widen vblank count to 64-bits [v3]") changed the return type for drm_crtc_vblank_count() to u64. This could cause potential problems if the return value is used in arithmetic operations with a 32-bit reference HW vblank count. Explicitly typecasting this down to u32 either fixes a potential problem or serves to add clarity in case the implicit typecasting was already correct. Cc: Keith Packard <keithp@keithp.com> Cc: Thierry Reding <treding@nvidia.com> Signed-off-by:
Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com> Reviewed-by:
Keith Packard <keithp@keithp.com> Acked-by:
Thierry Reding <treding@nvidia.com> Signed-off-by:
Rodrigo Vivi <rodrigo.vivi@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20180203051302.9974-6-dhinakaran.pandiyan@intel.com
-
- 08 Jan, 2018 2 commits
-
-
Thierry Reding authored
The first overlay plane can leak if initialization of the second overlay plane fails. Fix this by properly destroying the first overlay plane on error. Suggested-by:
Dmitry Osipenko <digetx@gmail.com> Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Cursor and overlay planes use a possible_crtcs mask based on the DC pipe number. However, DRM requires each bit in the mask to correspond to the index of the CRTC, which will be different from the DC pipe number for a configuration where the first display controller is disabled, or where a deferred probe leads to the first display controller being probed after the first. Suggested-by:
Dmitry Osipenko <digetx@gmail.com> Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
- 21 Dec, 2017 8 commits
-
-
Thierry Reding authored
This implements alpha blending on legacy display controllers (Tegra20, Tegra30 and Tegra114). While it's theoretically possible to support the zpos property to enable userspace to specify the Z-order of each plane individually, this is not currently supported and the same fixed Z- order as previously defined is used. Reverts commit 71835caa ("drm/tegra: fb: Force alpha formats") since the opaque formats are now supported. Reported-by:
Dmitry Osipenko <digetx@gmail.com> Fixes: 7772fdae ("drm/tegra: Support ARGB and ABGR formats") Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Dmitry Osipenko authored
Hardware reset isn't actually broken on Tegra20, but there is a dependency on the first display controller to be taken out of reset for the second to be enabled successfully. Model this dependency using a PM device link. Signed-off-by:
Dmitry Osipenko <digetx@gmail.com> [treding@nvidia.com: minor cleanups, extend commit message] Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Arnd Bergmann authored
The new debugfs registration fails to build when CONFIG_DEBUGFS is disabled, because the drm_crtc structure is lacking a member in that configuration: drivers/gpu/drm/tegra/dc.c: In function 'tegra_dc_late_register': drivers/gpu/drm/tegra/dc.c:1204:28: error: 'struct drm_crtc' has no member named 'debugfs_entry' Without CONFIG_DEBUGFS, the rest of the function already degrades into nothing, so we just avoid the one assignment. Fixes: b95800ee ("drm/tegra: dc: Register debugfs in ->late_register()") Signed-off-by:
Arnd Bergmann <arnd@arndb.de> Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
In order to support IOMMUs more generically and transparently handle the ARM SMMU on Tegra186, move to using groups instead of devices for domain attachment. An IOMMU group is a set of devices that share the same IOMMU domain and is therefore a good match to represent what Tegra DRM needs. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Implement the standard zpos property for planes on Tegra124 and later. Earlier generations have a different blending unit that needs different programming. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
The spinlock is only used to serialize accesses to the DC_CMD_INT_MASK register. However, this register is accesses either with interrupts masked (in tegra_crtc_atomic_enable()) or protected by the vbl_lock and vblank_time_lock spinlocks of the DRM device. Therefore, these accesses don't need any extra serialization and the lock can be removed. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Traditionally, windows were accessed indirectly, through a register selection window that required a global register to be programmed with the index of the window to access. Since the global register could be written from modesetting functions as well as the interrupt handler concurrently, accesses had to be serialized using a lock. Using direct accesses to the window registers the lock can be avoided. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Also, split up formats into per-SoC lists because not all generations support all of them. Note that the list is now exhaustive for all RGB formats, but not for YUV and indexed formats. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
- 13 Dec, 2017 16 commits
-
-
Thierry Reding authored
The SOR found on Tegra186 is very similar to the one found on Tegra210 and earlier. However, due to some changes in the display architecture, some programming sequences have changed and some register have moved around. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
These formats can easily be supported on all generations of Tegra. Note that the XRGB and XBGR formats that we supported were in fact using the ARGB and ABGR Tegra formats. This happened to work in cases where no alpha was being considered. This change is also a fix for those formats. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
The display architecture has changed in several signifcant ways with the new Tegra186 SoC. Display controllers are a completely different design, but have been given a frontend that simulates the register interface for earlier chips. Unfortunately the frontend isn't completely backwards compatible, so the driver needs parameterization to take the changes into account. One big change is that the total number of display controllers has been increased to three. At the same time the number of planes available has remained constant. However, planes can now be freely assigned between the display controllers, giving applications more flexibility in making the best use of the available resources. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
The display architecture has changed in several significant ways with the new Tegra186 SoC. Shared between all display controllers is a set of common resources referred to as the display hub. The hub generates accesses to memory and feeds them into various composition pipelines, each of which being a window that can be assigned to arbitrary heads. Atomic state is subclassed in order to track the global bandwidth requirements and select and adjust the hub clocks appropriately. The plane code is shared to a large degree with earlier SoC generations, except where the programming differs. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Subsequent patches will add support for Tegra186 which has a different architecture and needs different plane code but which can share a lot of code with earlier Tegra support. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Move the display controller state definition to the header file so that it can be referenced by other files. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Both tegra_overlay_plane_funcs is identical to tegra_plane_funcs. Get rid of the duplicate and use one set of function pointers for all planes. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
This function is a simple wrapper around tegra_plane_destroy(), so it can be dropped. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Both tegra_primary_plane_funcs and tegra_cursor_plane_funcs are identical. Get rid of the duplicate and use one set of function pointers for all planes. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
This function is a simple wrapper around tegra_plane_destroy(), so it can be dropped. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Tegra display hardware has GO bits and meets all the requirements to use drm_crtc_arm_vblank_event(). Use it instead and get rid of the hand- rolled implementation. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
There's no reason not to use them, and they already get all the semantics right, so rip out all of the custom code and replace it by the helpers. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Starting with Tegra124, the interface to set the background color (the value generated for pixels that are not sourced from any window) is via a different register. Earlier generations called this the border color. Reverse the feature flag and assume that IP revisions that don't have support for background color will support border color instead. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
The ->late_register() and ->early_unregister() callbacks are called at the right time to make sure userspace only accesses interfaces when it should. Move debugfs registration and unregistration to these callback functions to avoid potential races with userspace. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
Reshuffle some code so that functions are defined closer to where they are used. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
After commit 67e04d1a ("drm/tegra: dc: Trace register accesses"), the debugfs register dump implementation causes excessive stack usage and can result in build warnings. To fix this, move the register definitions into a table and iterate over the table while dumping the registers to debugfs. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
- 20 Nov, 2017 2 commits
-
-
Ville Syrjälä authored
drm_plane_helper_check_update() isn't a transitional helper, so let's rename it to drm_atomic_helper_check_plane_state() and move it into drm_atomic_helper.c. v2: Fix the WARNs about plane_state->crtc matching crtc_state->crtc Cc: Daniel Vetter <daniel@ffwll.ch> Suggested-by:
Daniel Vetter <daniel@ffwll.ch> Signed-off-by:
Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20171101201619.6175-1-ville.syrjala@linux.intel.comReviewed-by:
Daniel Vetter <daniel.vetter@ffwll.ch>
-
Ville Syrjälä authored
drm_plane_helper_check_state() is supposed to do things the atomic way, so it should not be inspecting crtc->enabled. Rather we should be looking at crtc_state->enable. We have a slight complication due to drm_plane_helper_check_update() reusing drm_plane_helper_check_state() for non-atomic drivers. Thus we'll have to pass the crtc_state in manally and construct a fake crtc_state in drm_plane_helper_check_update(). v2: Fix the WARNs about plane_state->crtc matching crtc_state->crtc Signed-off-by:
Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20171101201558.6059-1-ville.syrjala@linux.intel.comReviewed-by:
Daniel Vetter <daniel.vetter@ffwll.ch>
-
- 20 Oct, 2017 2 commits
-
-
Thierry Reding authored
In order for the reset to be applied properly, the module clock must be enabled during the assertion. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-
Thierry Reding authored
When applying the PLL changes from the computed state object, make sure to set the rate of the display controller module clock. Failing to do so can yield to a situation where the parent will be set to the proper pixel clock, but the module clock will be divided down to the rate that is happened to be set to before the parent rate change. Signed-off-by:
Thierry Reding <treding@nvidia.com>
-