xuhuicong [Mon, 21 Mar 2016 07:44:23 +0000 (15:44 +0800)]
video: rockchip: hdmi: v2: modify phy clock rate to reduce tdms clock jitter
set hdmi phy clock as 148.5Mhz when dclk rate over this frequency
Change-Id: I416b2b98fe42fafc45491b66252f245aed0f1364
Signed-off-by: xuhuicong <xhc@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:11:50 +0000 (19:11 +0800)]
FROMLIST: drm: bridge: analogix/dp: Fix the possible dead lock in bridge disable time
It may caused a dead lock if we flush the hpd work in bridge disable time.
The normal flow would like:
IN --> DRM IOCTL
1. Acquire crtc_ww_class_mutex (DRM IOCTL)
IN --> analogix_dp_bridge
2. Acquire hpd work lock (Flush hpd work)
3. HPD work already in idle, no need to run the work function.
OUT <-- analogix_dp_bridge
OUT <-- DRM IOCTL
The dead lock flow would like:
IN --> DRM IOCTL
1. Acquire crtc_ww_class_mutex (DRM IOCTL)
IN --> analogix_dp_bridge
2. Acquire hpd work lock (Flush hpd work)
IN --> analogix_dp_hotplug
IN --> drm_helper_hpd_irq_event
3. Acquire mode_config lock (This lock already have been acquired in previous step 1)
** Dead Lock Now **
It's wrong to flush the hpd work in bridge->disable time, I guess the
original code just want to ensure the delay work must be finish before
encoder disabled.
The flush work in bridge disable time is try to ensure the HPD event
won't be missed before display card disabled, actually we can take a
fast respond way(interrupt thread) to update DRM HPD event to fix the
delay update and possible dead lock.
(am from https://patchwork.kernel.org/patch/
8313001/)
Change-Id: Id7b357de0f497ff8c9f259fe31dc28be34f17083
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:11:37 +0000 (19:11 +0800)]
FROMLIST: drm: bridge: analogix/dp: add panel prepare/unprepare in suspend/resume time
Turn off the panel power in suspend time would help to reduce
power waste.
(am from https://patchwork.kernel.org/patch/
8312971/)
Change-Id: Iac01ac4041a2486e0347ed0377abcc094ab493ea
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:11:29 +0000 (19:11 +0800)]
FROMLIST: drm: bridge: analogix/dp: add edid modes parse in get_modes method
Display Port monitor could support kinds of mode which indicate
in monitor edid, not just one single display resolution which
defined in panel or devivetree property display timing.
Note: Gustavo Padovan try to remove the controller and phy
power on function in bind time at bellow commit:
drm/exynos: do not start enabling DP at bind() phase
But for now driver need to read edid message in .get_modes()
function, so controller must be inited in bind time, so we
need to add controller init back.
(am from https://patchwork.kernel.org/patch/
8312921/)
Change-Id: I32abee21665a7e1470f2898b7fbc925108f9d768
Tested-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:11:20 +0000 (19:11 +0800)]
FROMLIST: drm: bridge: analogix/dp: move hpd detect to connector detect function
This change just make a little clean to make code more like
drm core expect, move hdp detect code from bridge->enable(),
and place them into connector->detect().
Note: Gustavo Padovan try to remove the controller and phy
power on function in bind time at bellow commit:
drm/exynos: do not start enabling DP at bind() phase
But for now the connector status don't hardcode to connected,
need to operate dp phy in .detect function, so we need to revert
parts if Gustavo Padovan's changes, add phy poweron
function in bind time.
(am from https://patchwork.kernel.org/patch/
8312901/)
Change-Id: I0ed1be541210f85883477f1b2a88bd8d57e390d6
Tested-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:11:15 +0000 (19:11 +0800)]
FROMLIST: drm: bridge: analogix/dp: try force hpd after plug in lookup failed
Some edp screen do not have hpd signal, so we can't just return
failed when hpd plug in detect failed.
This is an hardware property, so we need add a devicetree property
"analogix,need-force-hpd" to indicate this sutiation.
(am from https://patchwork.kernel.org/patch/
8313081/)
Change-Id: If99d29936aafd996c98568d6e184aee6d9c8bc47
Acked-by: Rob Herring <robh@kernel.org>
Tested-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:11:05 +0000 (19:11 +0800)]
FROMLIST: drm: bridge: analogix/dp: add max link rate and lane count limit for RK3288
There are some IP limit on rk3288 that only support 4 physical lanes
of 2.7/1.6 Gbps/lane, so seprate them out by device_type flag.
(am from https://patchwork.kernel.org/patch/
8312881/)
Change-Id: Id1432af874eb0a6dec819d7b7e735c1040f4bf5c
Tested-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:10:54 +0000 (19:10 +0800)]
FROMLIST: drm: bridge: analogix/dp: add some rk3288 special registers setting
RK3288 need some special registers setting, we can separate
them out by the dev_type of plat_data.
(am from https://patchwork.kernel.org/patch/
8312861/)
Change-Id: I422216f58a18f2c2fee187b4f19de7b9d0fcd05a
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:10:48 +0000 (19:10 +0800)]
FROMLIST: dt-bindings: add document for rockchip variant of analogix_dp
Rockchip DP driver is a helper driver of analogix_dp coder driver,
so most of the DT property should be descriped in analogix_dp document.
(am from https://patchwork.kernel.org/patch/
8312841/)
Change-Id: If7a422554ac09cd3ed40eac8191369df532c58bf
Acked-by: Rob Herring <robh@kernel.org>
Reviewed-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:10:40 +0000 (19:10 +0800)]
FROMLIST: drm: rockchip: dp: add rockchip platform dp driver
Rockchip have three clocks for dp controller, we leave pclk_edp
to analogix_dp driver control, and keep the sclk_edp_24m and
sclk_edp in platform driver.
(am from https://patchwork.kernel.org/patch/
8615371/)
Change-Id: Ibe22447ab881b7421e999479cbdfd529d183f6b4
Tested-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:10:31 +0000 (19:10 +0800)]
FROMLIST: ARM: dts: exynos/dp: remove some properties that deprecated by analogix_dp driver
After exynos_dp have been split the common IP code into analogix_dp driver,
the analogix_dp driver have deprecated some Samsung platform properties which
could be dynamically parsed from EDID/MODE/DPCD message, so this is an update
for Exynos DTS file for dp-controller.
Beside the backward compatibility is fully preserved, so there are no
bisectability break that make this change in a separate patch.
(am from https://patchwork.kernel.org/patch/
8312821/)
Change-Id: I79adafdb4a086d4a357678282cc653a7e3432da9
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Tested-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:10:26 +0000 (19:10 +0800)]
FROMLIST: dt-bindings: add document for analogix display port driver
Analogix dp driver is split from exynos dp driver, so we just
make an copy of exynos_dp.txt, and then simplify exynos_dp.txt
Beside update some exynos dtsi file with the latest change
according to the devicetree binding documents.
(am from https://patchwork.kernel.org/patch/
8312811/)
Change-Id: Ia1d47783b735868a4f56231660d8309cf9c75923
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:10:11 +0000 (19:10 +0800)]
FROMLIST: drm: bridge: analogix/dp: dynamic parse sync_pol & interlace & dynamic_range
Both hsync/vsync polarity and interlace mode can be parsed from
drm display mode, and dynamic_range and ycbcr_coeff can be judge
by the video code.
But presumably Exynos still relies on the DT properties, so take
good use of mode_fixup() in to achieve the compatibility hacks.
(am from https://patchwork.kernel.org/patch/
8312791/)
Change-Id: Ia7f37daf40fa2d0516d5c44737ad36b5822c6015
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Tested-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Yakir Yang [Mon, 15 Feb 2016 11:10:04 +0000 (19:10 +0800)]
FROMLIST: drm: bridge: analogix/dp: remove duplicate configuration of link rate and link count
link_rate and lane_count already configured in analogix_dp_set_link_train(),
so we don't need to config those repeatly after training finished, just
remove them out.
Beside Display Port 1.2 already support 5.4Gbps link rate, the maximum sets
would change from {1.62Gbps, 2.7Gbps} to {1.62Gbps, 2.7Gbps, 5.4Gbps}.
(am from https://patchwork.kernel.org/patch/
8312771/)
Change-Id: I8cbf7146d70143bb5d30b3fa971e19f034c30e62
Tested-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Heiko Stuebner [Thu, 17 Mar 2016 21:50:00 +0000 (22:50 +0100)]
FROMLIST: drm: bridge: analogix/dp: fix some obvious code style
Fix some obvious alignment problems, like alignment and line
over 80 characters problems, make this easy to be maintained
later.
(am from https://patchwork.kernel.org/patch/
8615381/)
Change-Id: I49198f28156ae5761ba0aa8e8479bbdc963d9b25
Acked-by: Jingoo Han <jingoohan1@gmail.com>
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Tested-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Heiko Stuebner [Mon, 15 Feb 2016 11:09:54 +0000 (19:09 +0800)]
FROMLIST: drm: bridge: analogix/dp: rename register constants
In the original split we kept the register constants intact to keep the
diff small. Still the constants are Analogix-specific, so rename them now.
(am from https://patchwork.kernel.org/patch/
8312781/)
Change-Id: I714d60bc941b7a992dd34d4c0804576bd07ca84d
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Heiko Stuebner [Thu, 17 Mar 2016 21:47:27 +0000 (22:47 +0100)]
FROMLIST: drm: bridge: analogix/dp: split exynos dp driver to bridge directory
Split the dp core driver from exynos directory to bridge directory,
and rename the core driver to analogix_dp_*, rename the platform
code to exynos_dp.
Beside the new analogix_dp driver would export six hooks.
"analogix_dp_bind()" and "analogix_dp_unbind()"
"analogix_dp_suspned()" and "analogix_dp_resume()"
"analogix_dp_detect()" and "analogix_dp_get_modes()"
The bind/unbind symbols is used for analogix platform driver to connect
with analogix_dp core driver. And the detect/get_modes is used for analogix
platform driver to init the connector.
They reason why connector need register in helper driver is rockchip drm
haven't implement the atomic API, but Exynos drm have implement it, so
there would need two different connector helper functions, that's why we
leave the connector register in helper driver.
(am from https://patchwork.kernel.org/patch/
8615401/)
Change-Id: Iad075ae92ba9fa08674fb3d36488f7691909fead
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Carlos Palminha [Mon, 15 Feb 2016 12:58:20 +0000 (12:58 +0000)]
UPSTREAM: drm/exynos: removed optional dummy encoder mode_fixup function.
mode_fixup function for encoder drivers became optional with patch
http://patchwork.freedesktop.org/patch/msgid/
1455106522-32307-1-git-send-email-palminha@synopsys.com
This patch set nukes all the dummy mode_fixup implementations.
(made on top of Daniel topic/drm-misc branch)
(cherry picked from commit
586236251464a9fcf44757f8639e531d8af628f9)
Change-Id: I58ea3c6042f4ceca0bdf0cbac57175fdb53d05b2
Signed-off-by: Carlos Palminha <palminha@synopsys.com>
[danvet: Squash in 2nd exynos patch.]
Link: http://patchwork.freedesktop.org/patch/msgid/3768b670931572de51fca1102efa18d20dd770ee.1455540137.git.palminha@synopsys.com
Link: http://patchwork.freedesktop.org/patch/msgid/4906a9925eebbe55489b1005c449b426a61c09bd.1455540137.git.palminha@synopsys.com
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Javier Martinez Canillas [Fri, 29 Jan 2016 15:09:31 +0000 (12:09 -0300)]
UPSTREAM: drm/exynos: dp: Fix panel and bridge lookup logic
Commit
a9fa852886fd ("drm/exynos: dp: add of_graph dt binding support
for panel") made the Exynos DP DT binding more consistent since the OF
graph could be used to lookup either a panel or a bridge device node.
Before that commit, a panel would be looked up using a phandle and a
bridge using the OF graph which made the DT binding not consistent.
But the patch broke the later case since not finding a panel dev node
would cause the driver's to do a probe deferral instead of attempting
to lookup a bridge device node associated with the remote endpoint.
So instead of returning a -EPROBE_DEFER if a panel is not found, check
if there's a bridge and only do a probe deferral if both aren't found.
(cherry picked from commit
37e110625eeeaba83e8cb763ab7645f0678c6f8e)
Change-Id: If8b66d792447d4e3455f99dc38b04f334b8b65a6
Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
Tested-by: Michal Suchanek <hramrach@gmail.com>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Ville Syrjälä [Tue, 15 Dec 2015 11:21:06 +0000 (12:21 +0100)]
UPSTREAM: drm/exynos: Constify function pointer structs
Moves a bunch of junk to .rodata from .data.
drivers/gpu/drm/exynos/exynosdrm.ko:
-.text 125792
+.text 125788
-.rodata 10972
+.rodata 11748
-.data 6720
+.data 5944
(cherry picked from commit
800ba2b58182e4b0e8dc826a27362d45499068b1)
Change-Id: I8261dbe53224b581a20102253b162cc3a2563b58
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1450178476-26284-19-git-send-email-boris.brezillon@free-electrons.com
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Inki Dae [Thu, 26 Nov 2015 12:34:18 +0000 (21:34 +0900)]
UPSTREAM: drm/exynos: dp: add of_graph dt binding support for panel
This patch adds of_graph dt binding support for panel device
and also keeps the backward compatibility.
i.e.,
The dts file for Exynos5800 based peach pi board
has a panel property so we need to keep the backward compatibility.
Changelog v3:
- bind only one of two nodes outbound - panel or bridge.
Changelog v2:
- return -EINVAL if getting a port node failed.
(cherry picked from commit
a9fa852886fd5a7ccec3b7e9eff75f85072f009c)
Change-Id: Ie300bdc95027269f4a6b0d7fef8d6f0ca4017f06
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Gustavo Padovan [Mon, 2 Nov 2015 11:32:36 +0000 (20:32 +0900)]
UPSTREAM: drm/exynos: add pm_runtime to DP
Let pm_runtime handle the enabling/disabling of the device with
proper refcnt instead of rely on specific flags to track the enabled
state.
Chnagelog v3:
- revive dpms_mode to keep current dpms mode.
Changelog v2:
- no change
(cherry picked from commit
613d3853c2aca6cfd990e8bd0b436833b6c76db6)
Change-Id: Ieac8db078030f9331135ff0bc43a3a41d56d3b62
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Yakir Yang <ykk@rock-chips.com>
Gustavo Padovan [Mon, 2 Nov 2015 11:00:03 +0000 (20:00 +0900)]
UPSTREAM: drm/exynos: do not start enabling DP at bind() phase
The DP device will be properly enabled at the enable() call just
after the bind call finishes.
Changelog v2:
- no change
(cherry picked from commit
07c42703029244fb4b82593b0362d3f99c4268a4)
Change-Id: Id606cf49e9027036d9c7681b23f39681a3db5e87
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Aiyoujun [Fri, 18 Mar 2016 09:09:48 +0000 (17:09 +0800)]
ARM: dts: rk3366-tb: add declaration of smart card reader controller
Change-Id: I6a70ffccabb326bc691fd304db4b9df869530ee0
Signed-off-by: Aiyoujun <ayj@rock-chips.com>
Aiyoujun [Fri, 18 Mar 2016 09:08:03 +0000 (17:08 +0800)]
ARM: configs: rockchip_defconfig: add SOC smart card reader controller.
Change-Id: I505e9c4d23ab23d50e5d31a68b576771ac9dd3c7
Signed-off-by: Aiyoujun <ayj@rock-chips.com>
Aiyoujun [Fri, 18 Mar 2016 09:06:34 +0000 (17:06 +0800)]
dt-bindings: rockchip-scr: add rockchip SOC smart card reader controller.
Change-Id: I735c86c164eef2ea119818abe8afa0dd8ee5647a
Signed-off-by: Aiyoujun <ayj@rock-chips.com>
Aiyoujun [Fri, 18 Mar 2016 09:04:15 +0000 (17:04 +0800)]
ARM: dts: rk3366: add smart card reader controller's resource define.
Change-Id: Icb21dc6b529e2791414f19a915085437332736df
Signed-off-by: Aiyoujun <ayj@rock-chips.com>
Aiyoujun [Fri, 18 Mar 2016 09:03:07 +0000 (17:03 +0800)]
misc: rockchip-scr: add rockchip SOC smart card reader controller driver.
Change-Id: I8d3ab66bc6fa7cbb4e8d9b2f2c5c2feee94a045b
Signed-off-by: Aiyoujun <ayj@rock-chips.com>
Xing Zheng [Fri, 18 Mar 2016 02:58:21 +0000 (10:58 +0800)]
clk: rockchip: update clock controller for the RK3399
Fix some clock reference error.
Change-Id: I0505387160aa4b38753adfb82aabf7fb3b967ada
Signed-off-by: Xing Zheng <zhengxing@rock-chips.com>
Xing Zheng [Fri, 18 Mar 2016 02:54:51 +0000 (10:54 +0800)]
clk: rockchip: update dt-binding header for rk3399 some clock IDs
Add some clock IDs for driver reference them.
Change-Id: I43b2507a58f141f8e04a530b5e43db507097f301
Signed-off-by: Xing Zheng <zhengxing@rock-chips.com>
Liu Ying [Fri, 20 Nov 2015 08:15:30 +0000 (16:15 +0800)]
UPSTREAM: drm/dsi: Add a helper to get bits per pixel of MIPI DSI pixel format
Add a helper that can be used to obtain the number of bits per pixel
corresponding to a given MIPI DSI pixel format. This is useful in
bandwidth calculations, for example.
Change-Id: I03b9f93044ed46a2b999ce82e5623396a6f4d2bc
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
Signed-off-by: Liu Ying <Ying.Liu@freescale.com>
Acked-by: Thierry Reding <treding@nvidia.com>
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
[treding@nvidia.com: add kerneldoc comment and commit message]
Signed-off-by: Thierry Reding <treding@nvidia.com>
(cherry picked from commit
ec26d9e9382f432225d76b3ff1c7f72e21192f7f)
ZhengShunQian [Tue, 19 Jan 2016 07:03:00 +0000 (15:03 +0800)]
UPSTREAM: iommu/rockchip: Reconstruct to support multi slaves
There are some IPs, such as video encoder/decoder, contains 2 slave iommus,
one for reading and the other for writing. They share the same irq and
clock with master.
This patch reconstructs to support this case by making them share the same
Page Directory, Page Tables and even the register operations.
That means every instruction to the reading MMU registers would be
duplicated to the writing MMU and vice versa.
Change-Id: I3fd473898274cffcfb46c907b34bd3a4adc29250
Signed-off-by: ZhengShunQian <zhengsq@rock-chips.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Signed-off-by: Simon <xxm@rock-chips.com>
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
cd6438c5f8446691afa4829fe1a9d7b656204f11)
Marek Szyprowski [Fri, 19 Feb 2016 08:22:44 +0000 (09:22 +0100)]
FROMLIST: iommu: dma-iommu: use common implementation also on ARM architecture
This patch replaces ARM-specific IOMMU-based DMA-mapping implementation
with generic IOMMU DMA-mapping code shared with ARM64 architecture. The
side-effect of this change is a switch from bitmap-based IO address space
management to tree-based code. There should be no functional changes
for drivers, which rely on initialization from generic arch_setup_dna_ops()
interface. Code, which used old arm_iommu_* functions must be updated to
new interface.
To avoid build failed on ARCH arm,we mannually fix the following two files that
to use arch_set_dma_ops API
arch/arm/mach-highbank/highbank.c
arch/arm/mach-mvebu/coherency.c
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Conflicts:
arch/arm/mm/dma-mapping.c
Change-Id: Iffad16a7a511d50cc8e422bc61497f117279c66d
Signed-off-by: Simon <xxm@rock-chips.com>
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(am from https://patchwork.freedesktop.org/patch/74409/)
Marek Szyprowski [Fri, 19 Feb 2016 08:22:43 +0000 (09:22 +0100)]
FROMLIST: iommu: dma-iommu: move IOMMU/DMA-mapping code from ARM64 arch to drivers
This patch moves all the IOMMU-based DMA-mapping code from arch/arm64/mm
to drivers/iommu/dma-iommu-ops.c. This way it can be easily shared with
ARM architecture, which will also use them.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Conflicts:
arch/arm64/mm/dma-mapping.c
Change-Id: I7d56fa5e6e6ef43ae6c9c76035fcf81ee5cb7069
Signed-off-by: Simon <xxm@rock-chips.com>
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(am from https://patchwork.freedesktop.org/patch/74408/)
Roger Chen [Fri, 18 Mar 2016 06:22:06 +0000 (14:22 +0800)]
ARM64: dts: rk3399-tb: add GMAC node for rk3399-tb
Change-Id: I31f984a40bf8e2c04243e47fed7435bd3e400c4c
Signed-off-by: Roger Chen <roger.chen@rock-chips.com>
zhangqing [Mon, 11 Jan 2016 10:36:40 +0000 (02:36 -0800)]
UPSTREAM: dt-bindings: modify document of Rockchip power domains
Modify binding documentation for the power domains
found on Rockchip RK3368 SoCs.
Signed-off-by: zhangqing <zhangqing@rock-chips.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
(cherry picked from git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
master commit
1f164bd5b7dd4a1903c274ca70bf1ab11684db99)
Change-Id: Id6ef1ecfb32ee92e3a339326c1354a60b9028a80
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Roger Chen [Fri, 18 Mar 2016 06:20:23 +0000 (14:20 +0800)]
ARM64: dts: rk3399: add GMAC node for RK3399
Change-Id: I77eed48561b7ca16f77472aa4087e93497f6c010
Signed-off-by: Roger Chen <roger.chen@rock-chips.com>
Roger Chen [Fri, 18 Mar 2016 06:18:03 +0000 (14:18 +0800)]
net: stmmac: dwmac-rk: support RK3399 GMAC driver
Change-Id: Ib584d3526929fa37ae1e701c01971a61188d213b
Signed-off-by: Roger Chen <roger.chen@rock-chips.com>
Huang Jiachai [Thu, 17 Mar 2016 03:37:13 +0000 (11:37 +0800)]
video: rockchip: lcdc: 3366: 480i and 576i need sel dclk div2
Change-Id: Ibc27be643ae33a81d181d9398b362af0ce0c6f03
Signed-off-by: Huang Jiachai <hjc@rock-chips.com>
Huang Jiachai [Wed, 16 Mar 2016 07:14:38 +0000 (15:14 +0800)]
video: rockchip: vop lite: fix lut config error
Change-Id: I201e3bb8a60650259e2de4f3973173039188fe34
Signed-off-by: Huang Jiachai <hjc@rock-chips.com>
Huang Jiachai [Wed, 16 Mar 2016 06:21:57 +0000 (14:21 +0800)]
video: rockchip: vop lite: recover interlace config
Change-Id: I03171fd1546ead16f477cb255f2b1bbc1d20adf8
Signed-off-by: Huang Jiachai <hjc@rock-chips.com>
Huang Jiachai [Tue, 15 Mar 2016 01:10:19 +0000 (09:10 +0800)]
video: rockchip: fb: rename time line name for vop0 and vop1
Change-Id: Ifae7d4fc88dd41ecb659c886237a6d65026fded6
Signed-off-by: Huang Jiachai <hjc@rock-chips.com>
Jianqun Xu [Thu, 17 Mar 2016 07:05:41 +0000 (15:05 +0800)]
ARM64: dts: rockchip: add clk_ignore_unused for rk3399
Change-Id: I2f6faf3807d5c3b347d8b6930cc8f29c56746b2a
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
Huang Jiachai [Mon, 14 Mar 2016 13:01:29 +0000 (21:01 +0800)]
video: rockchip: vop: 3366: writeback function test ok
Change-Id: I560a714a86dad83f277d380c3650d4ed7827d80b
Signed-off-by: Huang Jiachai <hjc@rock-chips.com>
Huang Jiachai [Mon, 14 Mar 2016 13:00:49 +0000 (21:00 +0800)]
video: rockchip: vop lite: add deal with BGR data format
Change-Id: I5cac5cfd6385c5a0aa4152c927053ecd55290031
Signed-off-by: Huang Jiachai <hjc@rock-chips.com>
Huang Jiachai [Mon, 14 Mar 2016 12:58:26 +0000 (20:58 +0800)]
video: rockchip: fb: add BGR data format support
Change-Id: Ia97a20b5ed1e3ab92e31136e0cb60a785b570a65
Signed-off-by: Huang Jiachai <hjc@rock-chips.com>
David Wu [Fri, 11 Dec 2015 14:33:02 +0000 (22:33 +0800)]
i2c: rk3x: add i2c support for rk3399 soc
- new method to caculate i2c timings for rk3399:
There was an timing issue about "repeated start" time at the I2C
controller of version0, controller appears to drop SDA at .875x (7/8)
programmed clk high. On version 1 of the controller, the rule(.875x)
isn't enough to meet tSU;STA
requirements on 100k's Standard-mode. To resolve this issue,
sda_update_config, start_setup_config and stop_setup_config for I2C
timing information are added, new rules are designed to calculate
the timing information at new v1.
- pclk and function clk are separated at rk3399.
- support i2c highspeed mode: 1.7MHz for rk3399
Change-Id: I413455cf94fe7486c40694059e2f0931433992bb
Signed-off-by: David Wu <david.wu@rock-chips.com>
David Wu [Fri, 8 Jan 2016 02:53:28 +0000 (10:53 +0800)]
i2c: rk3x: switch to i2c generic dt parsing
Switch to the new generic functions: i2c_parse_fw_timings().
Change-Id: I14c3bea8e696d0ba5467effba1a157cd86e376d6
Signed-off-by: David Wu <david.wu@rock-chips.com>
Xing Zheng [Thu, 17 Mar 2016 07:28:08 +0000 (15:28 +0800)]
ARM64: dts: rk3399: add support clock assignment for PMUCRU/CRU
Change-Id: I8dc31880a232c1753c0fbfbeb4e3df0d09d7cdb3
Signed-off-by: Xing Zheng <zhengxing@rock-chips.com>
Xing Zheng [Mon, 29 Feb 2016 08:55:07 +0000 (16:55 +0800)]
clk: rockchip: add clock controller for the RK3399
Add the clock tree definition for the new RK3399 SoC.
Change-Id: I1d8755eb7c89bdc56b79644a96a7d3fd8e7fbc4b
Signed-off-by: Xing Zheng <zhengxing@rock-chips.com>
Chris Zhong [Wed, 6 Jan 2016 04:03:56 +0000 (12:03 +0800)]
UPSTREAM: ARM: dts: rockchip: add rk3288 mipi_dsi nodes
Add a mipi_dsi node, and also add mipi_dsi endpoints to vopb and vopl
output port nodes.
Change-Id: I0181ec03b0c944a18391737ea6bb65c5b642a6ea
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
(cherry picked from commit
cab6f070ab53df0fa8a17e95ca7518a8c8e42e69)
Chris Zhong [Wed, 6 Jan 2016 04:03:54 +0000 (12:03 +0800)]
UPSTREAM: Documentation: dt-bindings: Add bindings for rk3288 DW MIPI DSI driver
add device tree bindings for rk3288 specific Synopsys DW MIPI DSI driver
Change-Id: Ie6774d527475889a6eab587e66eda607d1ea2c8b
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Acked-by: Rob Herring <robh@kernel.org>
(cherry picked from commit
a20d86e7f96422d375dfa9ac0fe96ca4ce2aa647)
Chris Zhong [Fri, 20 Nov 2015 08:15:37 +0000 (16:15 +0800)]
UPSTREAM: drm/panel: simple: Add support for BOE TV080WUM-NL0
The BOE TV080WUM-NL0 is an 8.0", 1200x1920 (WUXGA) TFT-LCD panel
connected using four DSI lanes. It can be supported by the simple-panel
driver.
Change-Id: I4fe03fc830332e60997e98b24550801827692501
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
(cherry picked from commit
c8521969dea2b8e10ecbba86e0221e4f63dce921)
Chris Zhong [Fri, 20 Nov 2015 08:15:38 +0000 (16:15 +0800)]
UPSTREAM: dt-bindings: Add BOE TV080WUM-NL0 panel binding
The BOE TV080WUM-NL0 is an 8.0", 1200x1920 (WUXGA) TFT-LCD panel
connected using four DSI lanes.
Change-Id: I963cf860315f86ca64249c8f2064acbba62276b5
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
(cherry picked from commit
86b81f3e17b34e245ee01cf2bd142d12fae125cc)
Chris Zhong [Fri, 20 Nov 2015 08:15:36 +0000 (16:15 +0800)]
UPSTREAM: of: Add vendor prefix for BOE Technology Group
BOE Technology Group Co., Ltd. is a supplier of semiconductor display
technologies, products and services.
Change-Id: Id9a81512f6174770fc1d1282579da902fcdc89b0
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Acked-by: Rob Herring <robh@kernel.org>
[treding@nvidia.com: add commit message, fixup subject]
Signed-off-by: Thierry Reding <treding@nvidia.com>
(cherry picked from commit
27d23b30a561b752f1564d99cb6c8247c78f74f6)
Chris Zhong [Thu, 26 Nov 2015 07:50:16 +0000 (15:50 +0800)]
UPSTREAM: clk: rockchip: add mipidsi clock on rk3288
sclk_mipidsi_24m is the gating of mipi dsi phy.
Change-Id: I15b3e7a17b06397eb825eb2faca37d77732c9a97
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Acked-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
(cherry picked from commit
a2f4c560f18edd2ffe0f15d52ce2be55cff605d2)
Chris Zhong [Thu, 26 Nov 2015 07:50:15 +0000 (15:50 +0800)]
UPSTREAM: clk: rockchip: add id for mipidsi sclk on rk3288
Adds a new id for the sclk supplying the mipidsi on rk3288 socs.
Change-Id: Ifc3b97e4feed01098b483162d6320240d4b44cb3
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
(cherry picked from commit
c6d49fbcfcc44264c31f93866c9a713491e4a5fe)
Zain Wang [Tue, 17 Nov 2015 04:00:45 +0000 (12:00 +0800)]
UPSTREAM: clk: rockchip: add an id for rk3288 crypto clk
Add an id for crypto clk to the binding header, so that it can be called
in other part.
Change-Id: I541f4373cb2753aa74e2183cae82215e31faae44
Signed-off-by: Zain Wang <zain.wang@rock-chips.com>
Acked-by: Michael Turquette <mturquette@baylibre.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
(cherry picked from commit
94d5d6a0fbf33c5fde246b61b8c358cfeeba633f)
xiaoyao [Thu, 17 Mar 2016 09:15:29 +0000 (17:15 +0800)]
ARM64: dts: add eMMC/sdio/sd nodes for rk3399 sdk
Change-Id: Ia8bcfcb8938927cae7c970e2be02466c95ff7021
Signed-off-by: xiaoyao <xiaoyao@rock-chips.com>
David Wu [Wed, 16 Mar 2016 19:41:00 +0000 (03:41 +0800)]
ARM64: dts: rk3399: add pinctrl for uart
Change-Id: I8c48826d789bb48f234aa82014754dd519888d07
Signed-off-by: David Wu <david.wu@rock-chips.com>
David Wu [Wed, 16 Mar 2016 18:43:10 +0000 (02:43 +0800)]
ARM64: dts: rockchip: fix i2c clk for rk3399
Change-Id: I2edcdb4955d9ae5659d2a8f6f5c5e5b089759d9f
Signed-off-by: David Wu <david.wu@rock-chips.com>
David Wu [Wed, 16 Mar 2016 18:33:06 +0000 (02:33 +0800)]
ARM64: dts: rockchip: fix gpio clk error for rk3399
Change-Id: I8efd8007b17cc054a8e0bd20d1ccc89f7cf26ee8
Signed-off-by: David Wu <david.wu@rock-chips.com>
Huang, Tao [Thu, 17 Mar 2016 08:09:09 +0000 (16:09 +0800)]
ARM64: dts: rk3399: add PSCI node
Add PSCI node for RK3399 SoC, and cpu node enable-method property is
set to "psci".
Change-Id: I24f348b379435da88fe33f01e4b726e2e0210a9d
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
Huang, Tao [Thu, 17 Mar 2016 08:02:07 +0000 (16:02 +0800)]
ARM64: dts: rk3399: add pmu node
Change-Id: I1f3226749f66a1c2c61b9aec4fb7acba17e88135
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
Huang, Tao [Thu, 17 Mar 2016 07:55:08 +0000 (15:55 +0800)]
ARM64: dts: rk3399: fix arch timer irq type
Should be low level triggered.
Change-Id: Ie092cac9d262947ffc6294bc71cbb2efe73f3885
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
Jianqun Xu [Thu, 17 Mar 2016 06:58:14 +0000 (14:58 +0800)]
ARM64: dts: rockchip: add wdt0 for rk3399
There are two watchdogs in ALIVE named WDT0 and WDT1, and
one watchdog in PMU named WDT2.
WDT0 can drive CRU to generate global software reset.
Change-Id: Ide47e7e69572d2f2a537b590dc75010cf0f56c51
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
Feng Xiao [Thu, 17 Mar 2016 01:50:36 +0000 (09:50 +0800)]
ARM64: dts: rockchip: rk3399: add cpu dvfs support for tb
Change-Id: I707ebf8b4ba045401ebb3e609d511a8eb0883120
Signed-off-by: Feng Xiao <xf@rock-chips.com>
John Keeping [Tue, 19 Jan 2016 10:46:58 +0000 (10:46 +0000)]
UPSTREAM: drm/atomic-helper: Export framebuffer_changed()
The Rockchip driver cannot use drm_atomic_helper_wait_for_vblanks()
because it has hardware counters for neither vblanks nor scanlines.
In order to simplify re-implementing the functionality for this driver,
export the framebuffer_changed() helper so it can be reused.
Change-Id: I80e2dc3b412d2299e6d97a9421e928dc32a9b63e
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
Signed-off-by: John Keeping <john@metanate.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
(cherry picked from commit
c240906d36653944d5c049df7ce667a7e8bea6ac)
Shawn Lin [Thu, 17 Mar 2016 02:16:01 +0000 (10:16 +0800)]
mmc: sdhci-of-arasan: keep consistent with upstream
This patch manually amend some code to keep local
branch more consistent with upstream.
Change-Id: If705983f84ade4e7cebb45db8a65d34b876c7bef
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Feng Xiao [Wed, 16 Mar 2016 12:31:14 +0000 (20:31 +0800)]
ARM64: dts: rockchip: rk3368: fix cpu get regulator and clock error
we only add the property of regulator and clock to cpu0 and cpu4 node,
but if cpu4~cpu7 is down and then we up cpu5~cpu7, they will can not
get their regulator and clock. So we should add the properties to all
cpu node.
Change-Id: Id601fa3d3d05875f7c68f2a5472dc0eefefb6096
Signed-off-by: Feng Xiao <xf@rock-chips.com>
Shawn Lin [Wed, 16 Mar 2016 08:26:38 +0000 (16:26 +0800)]
ARM64: rockchip_defconfig: enable emmc phy driver
Change-Id: If555e77e60dc64782cc071ec8b78a0fdceaf9173
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Jianhong Chen [Thu, 17 Mar 2016 01:31:58 +0000 (09:31 +0800)]
ARM64: dts: rk3366-tb: disable vdd_arm when deep sleep
Change-Id: Iffce92e3412eeee36b735a8db5fdc08f532c3894
Signed-off-by: Jianhong Chen <chenjh@rock-chips.com>
John Keeping [Thu, 21 Jan 2016 18:19:34 +0000 (18:19 +0000)]
UPSTREAM: drm/rockchip: respect CONFIG_DRM_FBDEV_EMULATION
If DRM_FBDEV_EMULATION is not selected in the config then we can save a
bit of space by not including the framebuffer code.
Change-Id: I57b8888ebed0a0980e04a908116ad843b2fad556
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
Signed-off-by: John Keeping <john@metanate.com>
(cherry picked from commit
f0442df2156a2171e40f1643c60103e6333f4e7e)
Mark Yao [Wed, 23 Sep 2015 04:34:34 +0000 (12:34 +0800)]
UPSTREAM: drm/rockchip: fix wrong pitch/size using on gem
args->pitch and args->size may not be set by userspace, sometimes
userspace only malloc args and not memset args to zero, then
args->pitch and args->size is random, it is very danger to use
pitch/size on gem.
pitch's type is u32, and min_pitch's type is int, example,
pitch is 0xffffffff, then pitch < min_pitch return true, then gem will
alloc very very big bufffer, it would eat all the memory and cause kernel
crash.
Stop using pitch/size from args, calc them from other args.
Change-Id: I867d61bf6bc48a2989ae4d15a819a85a7e38d26f
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
e3c4abdb3bc9b76bedd416ecc5c27633a2f8afed)
John Keeping [Tue, 19 Jan 2016 10:47:00 +0000 (10:47 +0000)]
UPSTREAM: drm/rockchip: explain why we can't wait_for_vblanks
Change-Id: I073cf5b91554a293009a121845ac1bf3b6b3e6ce
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
Signed-off-by: John Keeping <john@metanate.com>
(cherry picked from commit
c9ad1d9946e849ac3d8821d91e136d7fd728dec5)
John Keeping [Tue, 19 Jan 2016 10:46:59 +0000 (10:46 +0000)]
UPSTREAM: drm/rockchip: don't wait for vblank if fb hasn't changed
As commented in drm_atomic_helper_wait_for_vblanks(), userspace relies
on cursor ioctls being unsynced. Converting the rockchip driver to
atomic has significantly impacted cursor performance by making every
cursor update wait for vblank.
By skipping the vblank sync when the framebuffer has not changed (as is
done in drm_atomic_helper_wait_for_vblanks()) we can avoid this for the
common case of moving the cursor and only need to delay the cursor ioctl
when the cursor icon changes.
We cannot add the check on legacy_cursor_update since that results in
the cursor bo being unreferenced while the hardware may still be reading
it. Fully supporting unsynced cursor updates is left for the future
when the atomic helper framework supports async updates.
Change-Id: I4c0e4b51ec7441fb7b7342eac5d4b98f9ca5ee62
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
Signed-off-by: John Keeping <john@metanate.com>
Tested-by: Heiko Stuebner <heiko@sntech.de>
(cherry picked from commit
f2227f469782e55765deacb8ebcc7ec05fe04013)
Andrzej Hajda [Thu, 14 Jan 2016 08:59:02 +0000 (09:59 +0100)]
UPSTREAM: drm/rockchip/dsi: fix handling mipi_dsi_pixel_format_to_bpp result
The function can return negative value so it should be assigned to signed
variable.
The problem has been detected using patch
scripts/coccinelle/tests/unsigned_lesser_than_zero.cocci.
Change-Id: Ide4daa64ce996d125b2f698e6f2d4899591e8065
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
Signed-off-by: Andrzej Hajda <a.hajda@samsung.com>
Reviewed-by: Chris Zhong <zyw@rock-chips.com>
(cherry picked from commit
484bb6c969523aa547d854bb57104339ee4aa800)
Mark Yao [Tue, 12 Jan 2016 08:04:39 +0000 (16:04 +0800)]
UPSTREAM: drm/rockchip: cleanup unnecessary export symbol
Now rockchip_drm_vop.c is build into rockchipdrm.ko, so
no need to export following symbol anymore:
rockchip_drm_dma_attach_device
rockchip_drm_dma_detach_device
rockchip_drm_dma_attach_device
rockchip_drm_dma_detach_device
rockchip_register_crtc_funcs
rockchip_unregister_crtc_funcs
rockchip_fb_get_gem_obj
Change-Id: Ic6cc7cb83efca4f74f1e70e3568abdfb83d2886f
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
63087aae5a7976a4557d16873146eae03948ec74)
John Keeping [Tue, 12 Jan 2016 18:05:18 +0000 (18:05 +0000)]
UPSTREAM: drm/rockchip: vop: fix mask when updating interrupts
Commit
dbb3d94 (drm/rockchip: vop: move interrupt registers into
vop_data) introduced new macros for updating the interrupt control
registers but these always use the mask from the register definition
without refining it for the particular bits that are being changed.
This means that whenever we enable/disable a particular interrupt we end
up disabling all of the others as a side effect.
Change-Id: I3b0f2574315f3655c183c21143b0bca7cdd9f6fa
Signed-off-by: John Keeping <john@metanate.com>
(cherry picked from commit
c7647f8681feeb6c0957e3cf5daed1fbf8b3a5af)
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
Mark Yao [Tue, 12 Jan 2016 07:51:12 +0000 (15:51 +0800)]
UPSTREAM: drm/rockchip: Don't build rockchip_drm_vop as modules
rockchip_drm_vop's module init had moved to rockchip_vop_reg.c
so no need to build rockchip_drm_vop.ko
Change-Id: I36da6a2741a250f3344b9febcd0c74539a861798
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
ce90d092bcd96b646b370121f0f1508270627f98)
Chris Zhong [Wed, 6 Jan 2016 08:12:54 +0000 (16:12 +0800)]
UPSTREAM: drm: rockchip: Support Synopsys DW MIPI DSI
Add support for Synopsys DesignWare MIPI DSI controller which is
embedded in the rk3288 SoCs.
Change-Id: Ic450633c683520361926a676191426349376803e
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Acked-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
84e05408fcfefb9b28050f701e1e94fe9f86804b)
Chris Zhong [Wed, 6 Jan 2016 04:03:53 +0000 (12:03 +0800)]
UPSTREAM: drm/rockchip: return a true clock rate to adjusted_mode
Since the mipi dsi driver need to use the clock of vop to make the
calculation of Blanking. But sometimes the clock driver can not set a
accurate clock_rate for vop, get it by clk_round_rate before mode_set,
so we can get the true value.
Change-Id: I04e6a499763258c2e16a09e3a59cf3a1e4593706
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Acked-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
b59b8de3149736e5094cb786978a1ba8d6d55b34)
Stephen Rothwell [Thu, 31 Dec 2015 02:40:11 +0000 (13:40 +1100)]
UPSTREAM: drm/rockchip: vop: export vop_component_ops to modules
Fixes: a67719d18229 ("drm/rockchip: vop: spilt register related into rockchip_reg_vop.c")
Change-Id: I4c855f65e684c08f8648547dcf16aa657c6ae5db
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Acked-by: Mark Yao <mark.yao@rock-chips.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
(cherry picked from commit
54255e818ef7a5e968c0230bc75649a68932d8ca)
Mark Yao [Tue, 15 Dec 2015 01:57:13 +0000 (09:57 +0800)]
UPSTREAM: drm/rockchip: vop: add rk3036 vop support
RK3036 registers layout is quite difference with rk3288 layout,
The IC design with different framework, rk3036 vop is VOP LITE,
and rk3288 is VOP FULL.
RK3036 support two overlay plane and one hwc plane, max output
resolution is 1080p. it support IOMMU, and its IOMMU same as
rk3288's.
Change-Id: Ib713b252dc6f2d4bffa3183698768c6f23236ccf
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
f7673453506035a904b6fb7a36dd6fb101366cd7)
Mark Yao [Tue, 15 Dec 2015 01:08:43 +0000 (09:08 +0800)]
UPSTREAM: drm/rockchip: vop: spilt scale regsters
There are two version scale control register found on vop,
scale full version found on rk3288, support extension registers.
and scale little version found on rk3036, only support common scale.
Change-Id: Iea1f253f363e062d49390fa51c304a2c109c39c6
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
1194fffbb102b1683bcbfc893df20bbf8a038468)
Mark Yao [Tue, 15 Dec 2015 00:58:26 +0000 (08:58 +0800)]
UPSTREAM: drm/rockchip: vop: spilt register related into rockchip_reg_vop.c
No functional updates. Spilt register related into another file
would be nice to multi vop driver,
Change-Id: I811b12a57b03c24eb420d0c3fa0833f412bd258c
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
a67719d182291bf62c6093545b9af27f0431cbeb)
Mark Yao [Tue, 15 Dec 2015 00:36:55 +0000 (08:36 +0800)]
UPSTREAM: drm/rockchip: vop: move interrupt registers into vop_data
Move interrupt registers into vop_data, so it can use at multi-vop driver
Change-Id: I3183fb3c97e76d58dbdab2f2df34480ee2e74b31
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
dbb3d94444eaa56cb1a6c9790f2fbe14b14310aa)
Mark Yao [Mon, 14 Dec 2015 10:14:36 +0000 (18:14 +0800)]
UPSTREAM: drm/rockchip: vop: merge vop cfg_done into vop_data
Move cfg_done register into vop_data, so it can use at multi-vop driver
Change-Id: Id92d69302a4fc9e28b96099bf0297674f2abfb33
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
0cf33fe33d4e9fdbbdd0b93101b078b03d0ba9b5)
Mark Yao [Mon, 30 Nov 2015 10:41:06 +0000 (18:41 +0800)]
UPSTREAM: drm/rockchip: dw_hdmi: use encoder enable function
encoder.enable is more compatible to atomic api than encoder.prepare/commit
Change-Id: Idacd1c44df94110b4a4b2cc66be9ce0eda8a2ad9
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
a8eef71d38da2bb03e187d3284aac6d3e0540f0f)
Mark Yao [Wed, 16 Dec 2015 10:11:24 +0000 (18:11 +0800)]
UPSTREAM: drm/rockchip: direct config connecter gate and out_mode
Both connecter gate and out_mode are not conflict with mode set
configure. Direct setting connecter gate and out_mode, that allow
connector do rockchip_drm_crtc_mode_config after mode set.
Change-Id: I6f7af59b7cbff2ae55830f31155e34e041cc74f8
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
d0e20d0ebfe40a4eba52bef2e1e03e91fce88528)
Mark Yao [Wed, 16 Dec 2015 10:09:38 +0000 (18:09 +0800)]
UPSTREAM: drm/rockchip: support atomic asynchronous commit
If drm core requests a async commit, rockchip_drm_atomic_commit
will schedule a work task to update later.
Change-Id: I8d35b157b817f2e7f810968e7b18043414cb17e6
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
f32fad51eec51ad816cecdc3723ab443cd69b61f)
Mark Yao [Wed, 16 Dec 2015 10:08:17 +0000 (18:08 +0800)]
UPSTREAM: drm/rockchip: Optimization vop mode set
Rk3288 vop timing registers is immediately register, when configure
timing on display active time, will cause tearing. use dclk reset is
not a good idea to avoid this tearing. we can avoid tearing by using
standby register.
Vop standby register will take effect at end of current frame, and
go back to work immediately when exit standby.
So we can use standby register to protect this context.
Change-Id: Ib65433900c67f9fbd3957c4b0506d6172474e5c2
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
ce3887ed0d996e6353d739e8139b8e5faeb726d5)
Mark Yao [Mon, 30 Nov 2015 10:22:42 +0000 (18:22 +0800)]
UPSTREAM: drm/rockchip: Convert to support atomic API
Rockchip vop not support hw vblank counter, needed check the committed
register if it's really take effect.
Change-Id: Ia291cdf75bc2f7397881f0e5f42debeae1c04f03
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
63ebb9fa7ff06d194362ed4a5d0a31ac7612a89c)
Mark Yao [Mon, 9 Nov 2015 03:33:16 +0000 (11:33 +0800)]
UPSTREAM: drm/rockchip: vop: replace dpms with enable/disable
For vop, power by enable/disable is more suitable then legacy dpms
function, and enable/disable more closely to the new atomic API.
Change-Id: Ief6e31f023a2e2af84aba773edac51fccd487a2c
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
0ad3675d9c8f7c7306c954a9c50dc12385d8a508)
Mark Yao [Mon, 23 Nov 2015 07:21:08 +0000 (15:21 +0800)]
UPSTREAM: drm/rockchip: Use new vblank api drm_crtc_vblank_*
No functional update, drm_vblank_* is the legacy version of
drm_crtc_vblank_*. and use new api make driver more clean.
Change-Id: Ia93ec8124333d59446d1507f7567be2775bea144
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
(cherry picked from commit
b5f7b75503efa5499080e51eb5c085fe1de1970d)
Ville Syrjälä [Tue, 15 Dec 2015 11:21:12 +0000 (12:21 +0100)]
UPSTREAM: drm/rockchip: Constify function pointer structs
Moves a bunch of junk to .rodata from .data.
drivers/gpu/drm/rockchip/dw_hdmi-rockchip.ko:
-.rodata 772
+.rodata 828
-.data 148
+.data 92
drivers/gpu/drm/rockchip/rockchipdrm.ko:
-.rodata 748
+.rodata 760
-.data 448
+.data 436
Change-Id: Ic93fc8d334a51618ea8075b4344983b795c7623e
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1450178476-26284-25-git-send-email-boris.brezillon@free-electrons.com
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
(cherry picked from commit
28c508ece6831e49d36cfa868f2a6c9d9f1c920e)
Ville Syrjälä [Wed, 9 Dec 2015 14:20:18 +0000 (16:20 +0200)]
UPSTREAM: drm: Pass 'name' to drm_encoder_init()
Done with coccinelle for the most part. However, 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.
@@
identifier dev, encoder, funcs;
@@
int drm_encoder_init(struct drm_device *dev,
struct drm_encoder *encoder,
const struct drm_encoder_funcs *funcs,
int encoder_type
+ ,const char *name, int DOTDOTDOT
)
{ ... }
@@
identifier dev, encoder, funcs;
@@
int drm_encoder_init(struct drm_device *dev,
struct drm_encoder *encoder,
const struct drm_encoder_funcs *funcs,
int encoder_type
+ ,const char *name, int DOTDOTDOT
);
@@
expression E1, E2, E3, E4;
@@
drm_encoder_init(E1, E2, E3, E4
+ ,NULL
)
v2: Add ', or NULL...' to @name kernel doc (Jani)
Annotate the function with __printf() attribute (Jani)
Change-Id: Id28ae2a6848fe1bd46905287b68f5d2c61d70039
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
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/1449670818-2966-1-git-send-email-ville.syrjala@linux.intel.com
(cherry picked from commit
13a3d91f17a5f7ed2acd275d18b6acfdb131fb15)
Ville Syrjälä [Wed, 9 Dec 2015 14:19:55 +0000 (16:19 +0200)]
UPSTREAM: 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)
Change-Id: I65fa347937ec17d21ac3fa28ec9c58c3ce97d496
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
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
(cherry picked from commit
b0b3b7951114315d65398c27648705ca1c322faa)
Ville Syrjälä [Wed, 9 Dec 2015 14:19:31 +0000 (16:19 +0200)]
UPSTREAM: drm: Pass 'name' to drm_crtc_init_with_planes()
Done with coccinelle for the most part. However, 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_crtc_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.
@@
identifier dev, crtc, primary, cursor, funcs;
@@
int drm_crtc_init_with_planes(struct drm_device *dev,
struct drm_crtc *crtc,
struct drm_plane *primary, struct drm_plane *cursor,
const struct drm_crtc_funcs *funcs
+ ,const char *name, int DOTDOTDOT
)
{ ... }
@@
identifier dev, crtc, primary, cursor, funcs;
@@
int drm_crtc_init_with_planes(struct drm_device *dev,
struct drm_crtc *crtc,
struct drm_plane *primary, struct drm_plane *cursor,
const struct drm_crtc_funcs *funcs
+ ,const char *name, int DOTDOTDOT
);
@@
expression E1, E2, E3, E4, E5;
@@
drm_crtc_init_with_planes(E1, E2, E3, E4, E5
+ ,NULL
)
v2: Split crtc and plane changes apart
Pass NULL for no-name instead of ""
Leave drm_crtc_init() alone
v3: Add ', or NULL...' to @name kernel doc (Jani)
Annotate the function with __printf() attribute (Jani)
Link: http://patchwork.freedesktop.org/patch/msgid/1449670771-2751-1-git-send-email-ville.syrjala@linux.intel.com
(cherry picked from commit
f98828769c8838f526703ef180b3088a714af2f9)
Change-Id: I8eb2a67b3a01bd0cb49e552f05a5ee5c6ac99d40
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
David Wu [Tue, 15 Mar 2016 18:10:37 +0000 (02:10 +0800)]
ARM64: dts: rockchip: add io-domain support for rk3399-tb
Change-Id: Ib72983eb50c416649a35be4393a889bc72e2457a
Signed-off-by: David Wu <david.wu@rock-chips.com>