summaryrefslogtreecommitdiffstats
path: root/drivers/gpu
Commit message (Collapse)AuthorAgeFilesLines
* drm/msm/dsi: One function call less in dsi_init() after error detectionMarkus Elfring2015-08-161-13/+9Star
| | | | | | | | | | | | | | The dsi_destroy() function was called in two cases by the dsi_init() function during error handling even if the passed variable contained a null pointer. * This implementation detail could be improved by adjustments for jump targets according to the Linux coding style convention. * Drop an unnecessary initialisation for the variable "msm_dsi" then. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> [add couple missing ERR_PTR()'s] Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/dsi: Delete an unnecessary check before the function call "dsi_destroy"Markus Elfring2015-08-161-3/+1Star
| | | | | | | | | | The dsi_destroy() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/mdp5: Allocate CTL0/1 for dual DSI single FLUSHHai Li2015-08-164-23/+129
| | | | | | | | | This change takes advantage of a HW feature that synchronize flush operation on CTL1 to CTL0, to keep dual DSI pipes in sync. Signed-off-by: Hai Li <hali@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/mdp5: Allocate CTL for each display interfaceHai Li2015-08-167-79/+80
| | | | | | | | | | | | | In MDP5, CTL contains information of the whole pipeline whose output goes down to a display interface. In various cases, one interface may require 2 CRTCs, but only one CTL. Some interfaces also require to use certain CTLs. Instead of allocating CTL for each active CRTC, this change is to associate a CTL with each interface. Signed-off-by: Hai Li <hali@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/mdp5: Add plane blending operation support for MDP5 (v2)jilai wang2015-08-166-85/+262
| | | | | | | | | | | | This change is to add properties alpha/zpos/blend_mode to mdp5 plane for alpha blending operation to generate the blended output. v1: Initial change v2: Change "premultilied" property to enum (Rob's comment) Signed-off-by: Jilai Wang <jilaiw@codeaurora.org> [Don't actually expose alpha/premultiplied props to userspace yet pending a chance for discussion and some userspace to exercise it] Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm: don't install plane properties on crtcRob Clark2015-08-166-10/+2Star
| | | | | | | | | This was a hold-over from the pre-atomic days and legacy userspace that only understood CRTCs. Fortunately we don't have any properties, so this doesn't change anything. But before we start growing some plane properties, we should fix this. Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/dsi: Report PHY errors only when they really occurArchit Taneja2015-08-161-1/+5
| | | | | | | | | | | | DSI PHY errors are falsely reported whenever a dsi error occurs. This is because DSI_DLN0_PHY_ERR isn't only used as a status register, but also used to mask PHY errors. Currently, we end up reading the mask bits too and therefore always report errors. Ignore the register mask bits and check for only the status/clear bits. Signed-off-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm: Set different display size limitation on each targetHai Li2015-08-165-4/+20
| | | | | | | | | | | | | The maximum output width of one pipeline depends on the LayerMixer's capability. It may be different on each target. Also, MDP5 doesn't have vertical limitation in one frame, as long as the pixel clock can be supported. This change obtains the maximum LM resolution from configuration table and treat it as the whole pipe's limitation for MDP5. The size limit on MDP4 is not changed. Signed-off-by: Hai Li <hali@codeaurora.org>
* drm/msm/hdmi: standardize on lead chip for compatible namesRob Clark2015-08-161-4/+4
| | | | | | | | For all of these devices, msm89xy was the lead chip, so standardize the compatible names to align with convention used by rest of the qcom/msm drivers. Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm: Add support for msm8x94Stephane Viau2015-08-165-32/+129
| | | | | | | | | | | | | | This change adds the MDP and HDMI support for msm8x94. Note that HDMI PHY registers are not being accessed anymore from the driver. Signed-off-by: Stephane Viau <sviau@codeaurora.org> [rename compatible s/8x94/8994/ since preference is to not trust the marketing folks who invent chip #'s but instead name things after the lead chip.. we should rename some 80XY to 89XY to standardize on the lead chip but leave that for another patch. Also, update dt bindings doc] Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/hdmi: remove ->reset() from HDMI PHYStephane Viau2015-08-165-144/+50Star
| | | | | | | | | | | | | | | | | | | | | ->reset() currently only accesses HDMI core registers, and yet it is located in hdmi_phy*. Since no PHY registers are being accessed during ->reset(), it would be better to bring that function in hdmi core module where HDMI core registers are usually being accessed. This will also help for msm8x94 for which no PHY registers accesses are done (->phy_init == NULL) but the HDMI PHY reset from HDMI core still needs to be done. Note: SW_RESET_PLL bit is not written in hdmi_phy_8x60_reset(); this write should not affect anything if the corresponding field is not writable. Signed-off-by: Stephane Viau <sviau@codeaurora.org> [fixed warning about unused 'phy' in hpd_enable() while merging] Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/dsi: Add support for msm8x94Hai Li2015-08-163-0/+150
| | | | | | | | | DSI controller on msm8x94 is version 1.3, which requires different power supplies and works with 20nm DSI PHY. This change is to add the basic support for this version. Signed-off-by: Hai Li <hali@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/dsi: Use pinctrl in DSI driverHai Li2015-08-161-0/+12
| | | | | | | | | Some targets use pinctrl framework to configure some pins. This change allows DSI driver to set default and sleep pinctrl status. Signed-off-by: Hai Li <hali@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/dsi: Rename *dual panel* to *dual DSI*Hai Li2015-08-161-42/+42
| | | | | | | | | The current term of *dual panel* in DSI driver code causes confusion. It is supposed to indicate the panel using two DSI links. Rename it to *dual DSI*. Signed-off-by: Hai Li <hali@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/dsi: Update source PLL selection in DSI PHYHai Li2015-08-163-22/+41
| | | | | | | | | | | | | | The source PLL to be used by each DSI PHY should be decided by DSI manager based on dual DSI information, while the register programming to select PLL is different from one type of PHY to another. This change adds the H/W difference to PHY configuration and updates the interface between DSI manager and PHY. With this change, PLL selection can be supported on different targets. Signed-off-by: Hai Li <hali@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/hdmi: add hdmi hdcp support (V3)jilai wang2015-08-168-8/+1523
| | | | | | | | | | | | Add HDMI HDCP support including HDCP PartI/II/III authentication. V1: Initial Change V2: Address Bjorn&Rob's comments Refactor the authentication process to use single work instead of multiple work for different authentication stages. V3: Update to align with qcom SCM api. Signed-off-by: Jilai Wang <jilaiw@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm: update generated headersRob Clark2015-08-1617-220/+680
| | | | Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm/mdp5: release SMB (shared memory blocks) in various casesWentao Xu2015-08-145-32/+104
| | | | | | | | | | | | | Release all blocks after the pipe is disabled, even when vsync didn't happen in some error cases. Allow requesting SMB multiple times before configuring to hardware, by releasing blocks not programmed to hardware yet for shrinking case. This fixes a potential leak of shared memory pool blocks. Signed-off-by: Wentao Xu <wentaox@codeaurora.org> Tested-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm: change to uninterruptible wait in atomic commitWentao Xu2015-08-144-13/+14
| | | | | | | | | The atomic commit cannot easily undo and return an error once the state is swapped. Change to uninterruptible wait, and ignore the timeout error. Signed-off-by: Wentao Xu <wentaox@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm: mdp4: Fix drm_framebuffer dereference crashArchit Taneja2015-08-141-1/+3
| | | | | | | | mdp4_get_frame_format() can dereference a drm_framebuffer when it's NULL. Call it in mdp4_plane_mode_set only when we know fb is non-NULL. Signed-off-by: Archit Taneja <architt@codeaurora.org> Signed-off-by: Rob Clark <robdclark@gmail.com>
* drm/msm: fix msm_gem_prime_get_sg_table()Rob Clark2015-08-141-2/+6
| | | | | | | We need to return a new sgt, since the caller takes ownership of it. Reported-by: Stanimir Varbanov <svarbanov@mm-sol.com> Signed-off-by: Rob Clark <robdclark@gmail.com>
* Merge tag 'drm-amdkfd-next-fixes-2015-08-05' of ↵Dave Airlie2015-08-143-3/+3
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://people.freedesktop.org/~gabbayo/linux into drm-next Two small bug fixes for the code you pulled for 4.3: - Used a SHIFT define instead of a MASK define to check if a bit is turned on when destroying hqd. Luckily, this is in gfx7 interface file with amdgpu, which was used only for bring-up purposes of amdgpu, so no real effect on a running system - Used a logical AND instead of a bitwise AND operator, when initializing sdma virtual memory when using SDMA queues * tag 'drm-amdkfd-next-fixes-2015-08-05' of git://people.freedesktop.org/~gabbayo/linux: drm/amdkfd: fix bug when initializing sdma vm drm/amdgpu: fix bug when amdkfd destroys hqd
| * drm/amdkfd: fix bug when initializing sdma vmOded Gabbay2015-07-302-2/+2
| | | | | | | | | | | | | | | | | | A logical AND operation was used during mask and shift, instead of a bitwise AND operation. This patch fixes this bug by changing the operation to bitwise AND. Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
| * drm/amdgpu: fix bug when amdkfd destroys hqdOded Gabbay2015-07-301-1/+1
| | | | | | | | | | | | | | | | | | The wrong define was used to check if the hqd is still active v2: Don't use SHIFT as the MASK is already shifted Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
* | Merge branch 'drm-sti-next-atomic-2015-08-11' of ↵Dave Airlie2015-08-1426-1621/+1311Star
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | http://git.linaro.org/people/benjamin.gaignard/kernel into drm-next This serie of patches fix minor bugs around how driver sub-components are bind and planes z-ordering. The main part is about atomic support: using more atomic helpers allow us to simplify the code (~300 lines removed) and to ahve a better match between drm concepts (planes and crtc) and hardware split. [airlied: fixed up conflict in atomic code] * 'drm-sti-next-atomic-2015-08-11' of http://git.linaro.org/people/benjamin.gaignard/kernel: drm/sti: atomic crtc/plane update drm/sti: rename files and functions drm/sti: code clean up drm/sti: fix dynamic z-ordering drm: sti: fix sub-components bind
| * | drm/sti: atomic crtc/plane updateVincent Abriou2015-08-0313-877/+809Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Better fit STI hardware structure. Planes are no more responsible of updating mixer information such as z-order and status. It is now up to the CRTC atomic flush to do it. Plane actions (enable or disable) are performed atomically. Disabling of a plane is synchronize with the vsync event. Signed-off-by: Vincent Abriou <vincent.abriou@st.com> Reviewed-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
| * | drm/sti: rename files and functionsVincent Abriou2015-08-0316-183/+182Star
| | | | | | | | | | | | | | | | | | | | | replace all "sti_drm_" occurences by "sti_" Signed-off-by: Vincent Abriou <vincent.abriou@st.com> Reviewed-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
| * | drm/sti: code clean upVincent Abriou2015-08-0319-886/+713Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Purpose is to simplify the STI driver: - remove layer structure - consider video subdev as part of the compositor (like mixer subdev) - remove useless STI_VID0 and STI_VID1 enum Signed-off-by: Vincent Abriou <vincent.abriou@st.com> Reviewed-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
| * | drm/sti: fix dynamic z-orderingVincent Abriou2015-08-033-20/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Apply the plane depth when the plane is updated. If the depth is different from the previous plane update, the register controlling the plane depth is cleaned and updated with the new depth. Signed-off-by: Vincent Abriou <vincent.abriou@st.com> Reviewed-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
| * | drm: sti: fix sub-components bindBenjamin Gaignard2015-08-033-94/+22Star
| |/ | | | | | | | | | | | | | | | | | | | | Fix misunderstanding in how use component framework. drm_platform_init() is now call only when all the sub-components are register themselves instead of the previous broken two stages mechanism. Update bindings documentation. Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
* | drm/atomic: Use KMS VBLANK APIThierry Reding2015-08-121-2/+2
| | | | | | | | | | | | | | | | | | Instead of using the legacy VBLANK API, use the new KMS API. This is part of an effort to convert all existing users so that the KMS API can be changed to properly use per-CRTC data. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | drm/irq: Document return values more consistentlyThierry Reding2015-08-121-2/+5
| | | | | | | | | | | | | | | | | | Some of the functions are documented inconsistently. Add Returns: sections where missing and use consistent style to describe the return value. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | drm/irq: Make pipe unsigned and name consistentThierry Reding2015-08-121-157/+159
| | | | | | | | | | | | | | | | | | | | | | | | Name all references to the pipe number (CRTC index) consistently to make it easier to distinguish which is a pipe number and which is a pointer to struct drm_crtc. While at it also make all references to the pipe number unsigned because there is no longer any reason why it should ever be negative. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | drm/irq: Check for valid VBLANK before dereferenceThierry Reding2015-08-121-2/+9
| | | | | | | | | | | | | | | | | | | | When accessing the array of per-CRTC VBLANK structures we must always check that the index into the array is valid before dereferencing to avoid crashing. Signed-off-by: Thierry Reding <treding@nvidia.com> [danvet: Squash in my own whitespace ocd fixup in drm_vblank_count.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | drm/irq: Remove negative CRTC index special-caseThierry Reding2015-08-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | The drm_send_vblank_event() function treats negative CRTC indices as meaning that a driver doesn't have proper VBLANK handling. This is the only place where DRM needs negative CRTC indices, so in order to enable subsequent cleanup, remove this special case and replace it by the more obvious check for whether or not VBLANK support was initialized. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | drm/plane: Use consistent data types for format countThierry Reding2015-08-123-4/+4
| | | | | | | | | | | | | | | | Rather than a mix of the the sized uint32_t and signed integer, use an unsized unsigned int to specify the format count. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | vga_switcheroo: Remove unnecessary checksThierry Reding2015-08-121-8/+5Star
| | | | | | | | | | | | | | | | debugfs_remove() gracefully ignores NULL parameters, so the explicit checks can be removed. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | vga_switcheroo: Wrap overly long linesThierry Reding2015-08-121-9/+24
| | | | | | | | | | | | | | | | | | Wrap overly long lines to make checkpatch happy. While at it, also add blank lines after declarations to eliminate additional problems flagged by checkpatch. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | vga_switcheroo: Use pr_fmt()Thierry Reding2015-08-121-13/+18
| | | | | | | | | | | | | | | | | | | | Use pr_fmt() to define the "vga_switcheroo: " prefix that is prepended to all output messages emitted by pr_*() functions. This allows making existing strings much shorter and eliminates a bunch of warnings from checkpatch about lines being overly long. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | vga_switcheroo: Cleanup header commentThierry Reding2015-08-121-9/+9
| | | | | | | | | | | | | | | | The header comment uses a weird combination of formatting styles. Make it consistent. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | vga_switcheroo: Use pr_*() instead of printk()Thierry Reding2015-08-121-12/+12
| | | | | | | | | | | | | | This silences a bunch of checkpatch warnings and makes the code shorter. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | vgaarb: Fix a few checkpatch errors and warningsThierry Reding2015-08-121-42/+60
| | | | | | | | | | | | | | | | | | Wrap overly long lines (offending lines were mostly comments, so trivial to fix up) and a number of other coding style issues pointed out by the checkpatch tool. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | vgaarb: Use vgaarb: prefix consistently in messagesThierry Reding2015-08-121-19/+20
| | | | | | | | | | | | | | | | Define the pr_fmt() macro to causes all messages emitted by pr_*() functions to be prefixed with "vgaarb: ". Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | vgaarb: Stop complaining about absent devicesThierry Reding2015-08-121-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | Some setups do not register a default VGA device, in which case the VGA arbiter will still complain about the (non-existent) PCI device being a non-VGA device. Fix this by making the error message conditional on a default VGA device having been set up. Note that the easy route of erroring out early isn't going to work because otherwise priv->target won't be properly updated. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | drm/atomic: fix null pointer access to mode_fixup callbackInki Dae2015-08-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes null pointer access incurred when encoder driver didn't set its own mode_fixup callback. mode_fixup callback shoudn't be called if the callback of drm_encoder_helper_funcs is NULL. Changelog v2: - change it to else if Signed-off-by: Inki Dae <inki.dae@samsung.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | drm/i915: Use CONFIG_DRM_FBDEV_EMULATIONDaniel Vetter2015-08-117-23/+8Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Instead of our own duplicated one. This fixes a bug in the driver unload code if DRM_FBDEV_EMULATION=n but DRM_I915_FBDEV=y because we try to unregister the nonexistent fbdev drm_framebuffer. Cc: Archit Taneja <architt@codeaurora.org> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reported-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | drm/core: Set mode to NULL when connectors in a set drops to 0.Maarten Lankhorst2015-08-111-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without this when a MST connector is removed drm_atomic_helper_set_config can complain about set->mode && !set->num_connectors. ------------[ cut here ]------------ WARNING: CPU: 2 PID: 2403 at drivers/gpu/drm/drm_atomic_helper.c:1673 drm_atomic_helper_set_config+0x22e/0x420() CPU: 2 PID: 2403 Comm: kms_flip Not tainted 4.2.0-rc5 #4233 Hardware name: NUC5i7RYB, BIOS RYBDWi35.86A.0246.2015.0309.1355 03/09/2015 ffffffff81ac75e8 ffff88004e4ffbf8 ffffffff81714c34 0000000080000000 0000000000000000 ffff88004e4ffc38 ffffffff8107bf81 ffff88004e4ffc48 ffff8800d8ca0690 ffff8800d8d7a080 ffff8800d8cc2290 ffff8800d07bc9f0 Call Trace: [<ffffffff81714c34>] dump_stack+0x4f/0x7b [<ffffffff8107bf81>] warn_slowpath_common+0x81/0xc0 [<ffffffff8107c065>] warn_slowpath_null+0x15/0x20 [<ffffffff813d9e3e>] drm_atomic_helper_set_config+0x22e/0x420 [<ffffffff813da174>] ? drm_atomic_helper_plane_set_property+0x84/0xc0 [<ffffffff813ee101>] drm_mode_set_config_internal+0x61/0x100 [<ffffffff813dc4ed>] restore_fbdev_mode+0xbd/0xe0 [<ffffffff813de1e4>] drm_fb_helper_restore_fbdev_mode_unlocked+0x24/0x70 [<ffffffffc0123d11>] intel_fbdev_restore_mode+0x21/0x80 [i915] [<ffffffffc014bf69>] i915_driver_lastclose+0x9/0x10 [i915] [<ffffffff813e2429>] drm_lastclose+0x29/0x130 [<ffffffff813e2844>] drm_release+0x314/0x500 [<ffffffff81194795>] __fput+0xe5/0x1f0 [<ffffffff811948d9>] ____fput+0x9/0x10 [<ffffffff810968d8>] task_work_run+0x88/0xb0 [<ffffffff8107d53f>] do_exit+0x37f/0xa90 [<ffffffff8127e258>] ? selinux_file_ioctl+0x48/0xc0 [<ffffffff81277dfe>] ? security_file_ioctl+0x3e/0x60 [<ffffffff8107ec80>] do_group_exit+0x40/0xa0 [<ffffffff8107ecef>] SyS_exit_group+0xf/0x10 [<ffffffff8171bdd7>] entry_SYSCALL_64_fastpath+0x12/0x6a ---[ end trace 0daf358c49351567 ]--- Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
* | drm/atomic: Call ww_acquire_done after check phase is completeDaniel Vetter2015-08-111-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | We want to make sure that no one tries to acquire more locks and states, and ww mutexes provide debug facilities for that. So use them. v2: Only call acquire_done when ->atomic_check was successful to avoid falling over an -EDEADLK (spotted by Maarten). Cc: Rob Clark <robdclark@gmail.com> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
* | drm/atomic: Paper over locking WARN in default_state_clearDaniel Vetter2015-08-111-3/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In commit 6f75cea66c8dd043ced282016b21a639af176642 Author: Daniel Vetter <daniel.vetter@ffwll.ch> Date: Wed Nov 19 18:38:07 2014 +0100 drm/atomic: Only destroy connector states with connection mutex held I tried to fix races of atomic commits against connector hot-unplugging. The idea is to ensure lifetimes by holding the connection_mutex long enough. That works for synchronous commits, but not for async ones. For async atomic commit we really need to fix up connector lifetimes for real. But that's a much bigger task, so just add more duct-tape: For cleaning up connector states we currently don't need the connector itself. So NULL it out and remove the locking check. Of course that check was to protect the entire sequence, but the modeset itself should be save since currently DP MST hot-removal does a dpms-off. And that should synchronize with any outstanding async atomic commit. Or at least that's my hope, this is all a giant mess. Reported-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
* | drm/edid: Use ARRAY_SIZE in drm_add_modes_noedidDaniel Vetter2015-08-111-1/+1
| | | | | | | | | | | | | | Spotted while reading code for random reasons. Reviewed-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>