aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2015-11-03drm/exynos/decon5433: merge different flag fieldsAndrzej Hajda1-31/+30
Driver uses four different fields for internal flags. They can be merged into one. Signed-off-by: Andrzej Hajda <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-11-03drm/exynos/decon5433: add function to set particular register bitsAndrzej Hajda1-50/+19
The driver often sets only particular bits of configuration registers. Using separate function to such action simplifies the code. Signed-off-by: Andrzej Hajda <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-11-03drm/exynos/decon5433: fix timing registers writesAndrzej Hajda1-9/+9
All timing registers should contain values decreased by one. Signed-off-by: Andrzej Hajda <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-11-03drm/exynos/decon5433: add PCLK clockAndrzej Hajda1-10/+11
PCLK clock is used by DECON IP. The patch also replaces magic number with number of clocks in array definition. Signed-off-by: Andrzej Hajda <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos: cleanup name of gem object for exynos_drmJoonyoung Shim6-182/+184
Struct of gem object in exynos_drm driver is struct exynos_drm_gem_obj. It's too long and we can know its meaning of name without _obj postfix. We use several names to variable name of gem object for exynos_drm - exynos_gem_obj, gem_obj and obj. Especially "obj" name can cause misunderstanding with variable name "obj" of struct drm_gem_object. This will clean about name of gem object for exynos_drm as follows. s/struct exynos_drm_gem_obj/struct exynos_drm_gem s/exynos_gem_obj or gem_obj or obj/exynos_gem Signed-off-by: Joonyoung Shim <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos: fix to detach device of iommuJoonyoung Shim1-2/+1
The arm_iommu_detach_device() is a function to detach device of iommu attached by arm_iommu_attach_device(). The exynos-drm uses arm_iommu_attach_device() so it should use arm_iommu_detach_device() to detach device of iommu, not iommu_detach_device(). The drm_release_iommu_mapping() is a function to release mapping of iommu created by arm_iommu_create_mapping(). It is called by exynos_drm_unload() so shouldn't be called by drm_iommu_detach_device(). Signed-off-by: Joonyoung Shim <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos: add cursor plane supportGustavo Padovan7-10/+23
Set one of the planes for each crtc driver as a cursor plane enabled window managers to fully work on exynos. Signed-off-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos: add global macro for the default primary planeGustavo Padovan6-18/+13
Define DEFAULT_WIN as zero to help set the primary plane on all CRTCs. Some CRTCs were defining a variable to store the default window, but that is not necessary as the default (primary) window is always the window zero. Signed-off-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos: fix spelling errorsIngi Kim2-14/+14
This patch fixes spelling errors in drm fimc/gsc inavild -> invaild Signed-off-by: Ingi Kim <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm: exynos: mixer: fix using usleep() in atomic contextTomasz Stanislawski1-1/+1
This patch fixes calling usleep_range() after taking reg_slock using spin_lock_irqsave(). The mdelay() is used instead. Waiting in atomic context is not the best idea in general. Hopefully, waiting occurs only when Video Processor fails to reset correctly. Signed-off-by: Tomasz Stanislawski <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: remove unused fieldAndrzej Hajda1-1/+0
The patch removes unused hdmi_context field. Signed-off-by: Andrzej Hajda <[email protected]> Reviewed-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: improve HDMI/ACR related codeAndrzej Hajda2-68/+32
Simple formula can be used to calculate CTS and N coefficients. Additionaly ACR registers have different offsets for different versions of IP. Signed-off-by: Andrzej Hajda <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: convert container_of macro to inline functionAndrzej Hajda1-6/+9
Inline function is safer than macro, also the name has been changed to be consistent with other inline function encoder_to_hdmi. Signed-off-by: Andrzej Hajda <[email protected]> Reviewed-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: remove deprecated hdmi_resources structureAndrzej Hajda1-59/+46
hdmi_resources structure was filled by old platform data code and is not necessary anymore. The patch removes it at groups together resource related fields in hdmi_context. Signed-off-by: Andrzej Hajda <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: convert to gpiod APIAndrzej Hajda1-23/+14
The patch converts API to gpiod and moves initialization code to hdmi_resources_init. Signed-off-by: Andrzej Hajda <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: simplify clock re-parentingAndrzej Hajda1-4/+0
Driver tries to disable sclk_hdmi during re-parenting, to avoid possible glitches. It is ineffective as the clock is used also by other devices (mixer). Anyway driver works without disabling sclk_hdmi. Signed-off-by: Andrzej Hajda <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: use constant size array for regulatorsAndrzej Hajda1-16/+9
Driver always uses the same number of regulators, so there is no point in dynamic allocation. Signed-off-by: Andrzej Hajda <[email protected]> Reviewed-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: use optional regulator_get for hdmi-enAndrzej Hajda1-13/+11
hdmi-en is an optional regulator so it should be better handled by devm_regulator_get_optional call. Signed-off-by: Andrzej Hajda <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: fix removal orderAndrzej Hajda1-3/+5
DRM device should be destroyed before releasing resources. Signed-off-by: Andrzej Hajda <[email protected]> Reviewed-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: replace all writeb with writelAndrzej Hajda1-3/+3
Registers are 32-bit, even if only lower 8-bits are used. Signed-off-by: Andrzej Hajda <[email protected]> Reviewed-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: simplify HDMI-PHY power sequenceAndrzej Hajda1-85/+8
Currently driver tries to set specific HDMI-PHY registers in three situations: - before reset, - before power off, - after applying HDMI-PHY configuration. First two cases seems to be unnecessary - register contents will be lost anyway. The third case can be merged with HDMI-PHY configuration by fixing the last byte of configuration data. The patch has been tested with following platforms: - exynos4210-universal_c210, - exynos4412-odroidu3, - exynos5422-odroidxu3. Signed-off-by: Andrzej Hajda <[email protected]> Reviewed-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: move PLL stabilization check code to separate functionAndrzej Hajda1-42/+26
The patch moves PLL stabilization check to separate function, adjust timeout parameters and de-duplicates code common for both HW variants. Signed-off-by: Andrzej Hajda <[email protected]> Reviewed-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: use mappings for registers with IP dependent addressAndrzej Hajda2-22/+38
Some registers resides at different offsets depending on device version. This patch adds infrastructure for mapping such registers to proper address based on hdmi_type. It adds also mappings to some registers. Signed-off-by: Andrzej Hajda <[email protected]> Reviewed-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-26drm/exynos/hdmi: remove support for deprecated compatibleAndrzej Hajda1-10/+0
This compatible was marked as deprecated in Jun 2013 and it is not used since then. Additionally its driver data points to wrong pll settings, so it cannot work anyway. Signed-off-by: Andrzej Hajda <[email protected]> Reviewed-by: Gustavo Padovan <[email protected]> Signed-off-by: Inki Dae <[email protected]>
2015-10-23Merge branch 'msm-next' of git://people.freedesktop.org/~robclark/linux into ↵Dave Airlie31-218/+689
drm-next A bit smaller pull this time. Few minor things, plus initial support for msm8996 (snapdragon 820).. Sorry, a bit latish, was hoping to get some 8960/8064 DSI stuff included. But still waiting on the v2 of the patchset (just pending some minor review comments). It would be nice to get the DSI patches merged since it would help some folks trying to get upstream kernel running on n4/n7 and xperia z and wanting to write some more panel drivers. Also, waiting for OCMEM driver to get merged via other trees and then I have a small bit to go along with that to make the gpu actually work on devices w/ OCMEM (snapdragon 800, 805, etc). So maybe a second later pull req, time permitting. * 'msm-next' of git://people.freedesktop.org/~robclark/linux: drm/msm: Remove local fbdev emulation Kconfig option drm/msm/mdp5: Basic support for MDP5 v1.7 (MSM8996) drm/msm/mdp: Add Software Pixel Extension support drm/msm/mdp5: Use the newly introduced enum mdp_component_type drm/msm/hdmi: Add basic HDMI support for msm8996 drm/msm/mdp5: Avoid printing error messages for optional clocks drm/msm: Fix IOMMU clean up path in case msm_iommu_new() fails drm/msm/mdp5: remove the cfg pointer from SMP struct drm/msm/dsi: Updata LNn_CFG4 register settings for 28nm PHY drm: msm: dsi: Don't attempt changing voltage of switches drm/msm: update generated headers
2015-10-22drm/msm: Remove local fbdev emulation Kconfig optionArchit Taneja3-21/+3
DRM_MSM_FBDEV config is used to enable/disable fbdev emulation for the msm kms driver. Replace this with the top level DRM_FBDEV_EMULATION config option where applicable. This also prevents build breaks caused by undefined drm_fb_helper_* functions when legacy fbdev support was disabled. Signed-off-by: Archit Taneja <[email protected]> Signed-off-by: Rob Clark <[email protected]>
2015-10-22drm/msm/mdp5: Basic support for MDP5 v1.7 (MSM8996)Stephane Viau6-14/+133
This change adds the basic MDP5 support for MSM8996. Signed-off-by: Stephane Viau <[email protected]> Signed-off-by: Rob Clark <[email protected]>
2015-10-22drm/msm/mdp: Add Software Pixel Extension supportStephane Viau2-31/+128
In order to produce an image, the scalar needs to be fed extra pixels. These top/bottom/left/right values depend on a various of factors, including resolution, scaling type, phase step and initial phase. Pixel Extension are programmed by hardware in most targets - and can be overwritten by software. For some targets (e.g.: msm8996), software *must* program those registers. In order to ease this computation, let's always use bilinear filters, which are easier to program from kernel. Eventually, all of these values will come down from user space for better quality. Signed-off-by: Stephane Viau <[email protected]> Signed-off-by: Rob Clark <[email protected]>
2015-10-22drm/msm/mdp5: Use the newly introduced enum mdp_component_typeStephane Viau1-12/+13
When calculating phase steps, let's use the same enum mdp_component_type in order to ease the readability; 0/1 indexes are a bit confusing and we now have explicit values to index this type of arrays. Signed-off-by: Stephane Viau <[email protected]> Signed-off-by: Rob Clark <[email protected]>
2015-10-22drm/msm/hdmi: Add basic HDMI support for msm8996Stephane Viau2-3/+17
The HDMI controller is new in MDP5 v1.7. As of now, this change doesn't reflect the novelty and only adds the basics so the probe gets triggered. Signed-off-by: Stephane Viau <[email protected]> Signed-off-by: Rob Clark <[email protected]>
2015-10-22drm/msm/mdp5: Avoid printing error messages for optional clocksStephane Viau2-12/+18
The current behavior is to try to get optional clocks and print a dev_err message in case of failure. This looks rather confusing and may increase with the amount of optional clocks. We may need a cleaner way to handle per-device clocks but in the meantime, let's reduce the amount of dev_err messages during the probe. Signed-off-by: Stephane Viau <[email protected]> Signed-off-by: Rob Clark <[email protected]>
2015-10-22drm/msm: Fix IOMMU clean up path in case msm_iommu_new() failsStephane Viau2-0/+9
msm_iommu_new() can fail and this change makes sure that we detect the failure and free the allocated domain before going any further. Signed-off-by: Stephane Viau <[email protected]> Signed-off-by: Rob Clark <[email protected]>
2015-10-22drm/msm/mdp5: remove the cfg pointer from SMP structStephane Viau2-5/+5
We want to make sure we control all the information being passed down to SMP block. Having access to the cfg pointer here may create bad things in the future. Signed-off-by: Stephane Viau <[email protected]> Signed-off-by: Rob Clark <[email protected]>
2015-10-22drm/msm/dsi: Updata LNn_CFG4 register settings for 28nm PHYHai Li1-4/+2
The current settings for 28nm PHY data lane CFG4 registers do not work with certain panels. This change is to modify them to hw recommended values. Signed-off-by: Hai Li <[email protected]> Signed-off-by: Rob Clark <[email protected]>
2015-10-22drm: msm: dsi: Don't attempt changing voltage of switchesBjorn Andersson2-2/+2
In some configurations the supplies are voltage switches and not LDOs, making the set voltage call to fail. Check with the regulator framework if the supply can change voltage before attempting. Signed-off-by: Bjorn Andersson <[email protected]> Reviewed-by: Archit Taneja <[email protected]> Signed-off-by: Rob Clark <[email protected]>
2015-10-22drm/msm: update generated headersRob Clark14-114/+359
Signed-off-by: Rob Clark <[email protected]>
2015-10-22Merge branch 'drm/next/du' of git://linuxtv.org/pinchartl/fbdev into drm-nextDave Airlie3-8/+38
rcar-du support for r8a7793/4 * 'drm/next/du' of git://linuxtv.org/pinchartl/fbdev: drm: rcar-du: Add support for the R8A7794 DU drm: rcar-du: Add support for the R8A7793 DU
2015-10-22Merge tag 'drm-vc4-next-2015-10-21' of http://github.com/anholt/linux into ↵Dave Airlie15-0/+3014
drm-next This pull request introduces the vc4 driver, for kernel modesetting on the Raspberry Pi (bcm2835/bcm2836 architectures). It currently supports a display plane and cursor on the HDMI output. The driver doesn't do 3D, power management, or overlay planes yet. [airlied: fixup the enable/disable vblank APIs] Acked-by: Daniel Vetter <[email protected]> * tag 'drm-vc4-next-2015-10-21' of http://github.com/anholt/linux: drm/vc4: Allow vblank to be disabled drm/vc4: Use the fbdev_cma helpers drm/vc4: Add KMS support for Raspberry Pi. drm/vc4: Add devicetree bindings for VC4.
2015-10-21drm: rcar-du: Add support for the R8A7794 DULaurent Pinchart3-3/+29
The R8A7794 DU has a fixed output routing configuration with one RGB output per CRTC and thus lacks the RGB output routing register field. Signed-off-by: Laurent Pinchart <[email protected]>
2015-10-21drm: rcar-du: Add support for the R8A7793 DULaurent Pinchart2-6/+10
The R8A7793 DU is identical to the R8A7791 and thus only requires a new DT compatible string. Signed-off-by: Laurent Pinchart <[email protected]>
2015-10-21drm/vc4: Allow vblank to be disabledDerek Foreman1-0/+1
Signed-off-by: Derek Foreman <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2015-10-21drm/vc4: Use the fbdev_cma helpersDerek Foreman3-3/+31
Keep the fbdev_cma pointer around so we can use it on hotplog and close to ensure the frame buffer console is in a useful state. Signed-off-by: Derek Foreman <[email protected]> Signed-off-by: Eric Anholt <[email protected]>
2015-10-21drm/vc4: Add KMS support for Raspberry Pi.Eric Anholt14-0/+2920
This is enough for fbcon and bringing up X using xf86-video-modesetting. It doesn't support the 3D accelerator or power management yet. v2: Drop FB_HELPER select thanks to Archit's patches. Do manual init ordering instead of using the .load hook. Structure registration more like tegra's, but still using the typical "component" code. Drop no-op hooks for atomic_begin and mode_fixup() now that they're optional. Drop sentinel in Makefile. Fix minor style nits I noticed on another reread. v3: Use the new bcm2835 clk driver to manage pixel/HSM clocks instead of having a fixed video mode. Use exynos-style component driver matching instead of devicetree nodes to list the component driver instances. Rename compatibility strings to say bcm2835, and distinguish pv0/1/2. Clean up some h/vsync code, and add in interlaced mode setup. Fix up probe/bind error paths. Use bitops.h macros for vc4_regs.h v4: Include i2c.h, allow building under COMPILE_TEST, drop msleep now that other bugs have been fixed, add timeouts to cpu_relax() loops, rename hpd-gpio to hpd-gpios. Signed-off-by: Eric Anholt <[email protected]> Acked-by: Daniel Vetter <[email protected]>
2015-10-21drm/vc4: Add devicetree bindings for VC4.Eric Anholt1-0/+65
VC4 is the GPU (display and 3D) subsystem present on the 2835 and some other Broadcom SoCs. This binding follows the model of msm, imx, sti, and others, where there is a subsystem node for the whole GPU, with nodes for the individual HW components within it. v2: Extend the commit message, fix several nits from Stephen Warren. v3: Rename the compatibility strings, clean up node names, drop the unnecessary lists of components. Use compatibility strings for choosing CRTC HVS channel numbers. Document the HDMI clock usage. v4: Whitespace fix, expand acronyms, move to display/ instead of gpu/, rename "hpd-gpio" to "hpd-gpios". Signed-off-by: Eric Anholt <[email protected]>
2015-10-20Merge tag 'topic/drm-misc-2015-10-19' of ↵Dave Airlie41-401/+443
git://anongit.freedesktop.org/drm-intel into drm-next More drm-misc for 4.4. - fb refcount fix in atomic fbdev - various locking reworks to reduce drm_global_mutex and dev->struct_mutex - rename docbook to gpu.tmpl and include vga_switcheroo stuff, plus more vga_switcheroo (Lukas Wunner) - viewport check fixes for atomic drivers from Ville - DRM_DEBUG_VBL from Ville - non-contentious header fixes from Mikko Rapeli - small things all over * tag 'topic/drm-misc-2015-10-19' of git://anongit.freedesktop.org/drm-intel: (31 commits) drm/fb-helper: Fix fb refcounting in pan_display_atomic drm/fb-helper: Set plane rotation directly drm: fix mutex leak in drm_dp_get_mst_branch_device drm: Check plane src coordinates correctly during page flip for atomic drivers drm: Check crtc viewport correctly with rotated primary plane on atomic drivers drm: Refactor plane src coordinate checks drm: Swap w/h when converting the mode to src coordidates for a rotated primary plane drm: Don't leak fb when plane crtc coodinates are bad ALSA: hda - Spell vga_switcheroo consistently drm/gem: Use kref_get_unless_zero for the weak mmap references drm/vgem: Drop vgem_drm_gem_mmap drm: Fix return value of drm_framebuffer_init() drm/gem: Use container_of in drm_gem_object_free drm/gem: Check locking in drm_gem_object_unreference drm/gem: Drop struct_mutex requirement from drm_gem_mmap_obj drm/i810_drm.h: include drm/drm.h r128_drm.h: include drm/drm.h savage_drm.h: include <drm/drm.h> gpu/doc: Convert to markdown harder gpu/doc: Add vga_switcheroo documentation ...
2015-10-20Merge tag 'drm-intel-next-2015-10-10' of ↵Dave Airlie63-1748/+2620
git://anongit.freedesktop.org/drm-intel into drm-next - dmc fixes from Animesh (not yet all) for deeper sleep states - piles of prep patches from Ville to make mmio functions type-safe - more fbc work from Paulo all over - w/a shuffling from Arun Siluvery - first part of atomic watermark updates from Matt and Ville (later parts had to be dropped again unfortunately) - lots of patches to prepare bxt dsi support ( Shashank Sharma) - userptr fixes from Chris - audio rate interface between i915/snd_hda plus kerneldoc (Libin Yang) - shrinker improvements and fixes (Chris Wilson) - lots and lots of small patches all over * tag 'drm-intel-next-2015-10-10' of git://anongit.freedesktop.org/drm-intel: (134 commits) drm/i915: Update DRIVER_DATE to 20151010 drm/i915: Partial revert of atomic watermark series drm/i915: Early exit from semaphore_waits_for for execlist mode. drm/i915: Remove wrong warning from i915_gem_context_clean drm/i915: Determine the stolen memory base address on gen2 drm/i915: fix FBC buffer size checks drm/i915: fix CFB size calculation drm/i915: remove pre-atomic check from SKL update_primary_plane drm/i915: don't allocate fbcon from stolen memory if it's too big Revert "drm/i915: Call encoder hotplug for init and resume cases" Revert "drm/i915: Add hot_plug hook for hdmi encoder" drm/i915: use error path drm/i915/irq: Fix misspelled word register in kernel-doc drm/i915/irq: Fix kernel-doc warnings drm/i915: Hook up ring workaround writes at context creation time on Gen6-7. drm/i915: Don't warn if the workaround list is empty. drm/i915: Resurrect golden context on gen6/7 drm/i915/chv: remove pre-production hardware workarounds drm/i915/snb: remove pre-production hardware workaround drm/i915/bxt: Set time interval unit to 0.833us ...
2015-10-20Merge branch 'drm/next/du' of git://linuxtv.org/pinchartl/fbdev into drm-nextDave Airlie3-37/+25
some rcar fixes. * 'drm/next/du' of git://linuxtv.org/pinchartl/fbdev: drm: rcar-du: Fix plane state free in plane reset handler drm: rcar-du: Enable DU0 to DPAD connection on R8A7791 drm: rcar-du: Add dependency on OF drm: rcar-du: Remove obsolete rcar-du-r8a779x platform_device_id entries
2015-10-20drm: rcar-du: Fix plane state free in plane reset handlerLaurent Pinchart1-23/+22
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 rcar_du_plane_atomic_destroy_state() function to destroy the plane state instead of duplicating the code. Signed-off-by: Laurent Pinchart <[email protected]> Reviewed-by: Thierry Reding <[email protected]>
2015-10-20drm: rcar-du: Enable DU0 to DPAD connection on R8A7791Laurent Pinchart1-1/+1
The DPAD RGB output can be driven by both DU0 and DU1 on R8A7791. Mark the DU0 connection as possible. Signed-off-by: Laurent Pinchart <[email protected]>
2015-10-20drm: rcar-du: Add dependency on OFLaurent Pinchart2-11/+2
The driver requires OF support, add a dependency in Kconfig and remove the platform_device_id table that isn't used anymore. Signed-off-by: Laurent Pinchart <[email protected]> Acked-by: Geert Uytterhoeven <[email protected]>