Commit Graph

865163 Commits

Author SHA1 Message Date
Zorro Liu
b9ccd4db49 drm/rockchip: ebc_dev: release version v2.05
1.full/a2/du/du4: check part also
2.auto mode use full gc16 waveform to reduce ghosting

Signed-off-by: Zorro Liu <lyx@rock-chips.com>
Change-Id: I3a2156ccecc5d630b1adb2425d647fb8efb090be
2021-07-09 17:09:13 +08:00
Elaine Zhang
94e452359f clk: rockchip: rk3568: add CLK_GATE_NO_SET_RATE flag for some clks
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I222f9038a96071b6e12601e5fe91779721e19a46
2021-07-09 16:23:33 +08:00
Elaine Zhang
c56568e8bf clk: rockchip: add flag CLK_GATE_NO_SET_RATE
Add CLK_GATE_NO_SET_RATE for gate clks not allowed to support setting
rate.

Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: Iddd1c958661f8ff9217b8781426314b0619367db
2021-07-09 16:23:33 +08:00
Yu Qiaowei
d7fb9ec48d video/rockchip: rga2: Modify blend formula
The maximum alpha is 255, but after the product of color and alpha
in the blend formula, the final result is >> 8 (/256) instead of
/255, which will introduce errors.
This fix is that when alpha is 0x80~0xff, then +1.

Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: Ibba964f29a11eb226aa008a0dd5bf89048524b43
2021-07-08 14:42:49 +08:00
Caesar Wang
9e44a98d4c arm64/configs: update rockchip_linux_defconfig
1) Enable rknpu module
2) Enable CONFIG_ARM_ROCKCHIP_DMC_DEBUG=y

Signed-off-by: Caesar Wang <wxt@rock-chips.com>
Change-Id: I7d6a8b1aa5311030e689a19a4712d8b8dc657b09
2021-07-07 15:15:05 +08:00
Zefa Chen
ea02130e2f media: rockchip: cif: remove dummy buffer
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: Ib1cdf85020d37a7a4a06b726fb88597797806411
2021-07-07 09:17:28 +08:00
Zefa Chen
cdead10da7 media: i2c: imx415: support get sony BRL
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: I6045b794e7c482ee63058ded7f654b55c2f604d8
2021-07-06 17:58:16 +08:00
Zefa Chen
506e3e2788 include: uapi/linux/rk-camera-module.h add RKMODULE_GET_SONY_BRL command
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: I55bbf4c5e5163286e1f8c68b1a1734bcefcf2b22
2021-07-06 17:58:12 +08:00
Roger Chen
f412d2e4aa media: i2c: add driver for ov9281@30fps
Signed-off-by: Roger Chen <roger.chen@rock-chips.com>
Change-Id: I78132163e1fba4fb3fb531040df629b347ab0fa4
2021-07-06 17:41:19 +08:00
Sandy Huang
d2fa3651f8 drm/bridge: synopsys: dw-hdmi: add 1024x768p60 to default mode
Some traditional display devices like use 1024x768p60 resolution, so we
add this mode to default mode when parse edid failed.

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: Ibb67898f8b0cc7b98f988a783f8eb4c28aa18359
2021-07-06 16:41:04 +08:00
Sandy Huang
6619bf068a drm/rockchip: add 1024x768p60 to default output mode
Some traditional display devices like use 1024x768p60 resolution,
so we add this mode to default mode when parse edid failed.

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: I0acd1241d84ae65d415f595d6147fed3da0b2f20
2021-07-06 16:41:04 +08:00
Sandy Huang
a5952d0f07 drm/bridge: analogix_dp: add default mode when get edid failed
This will used when product use edp2hdmi or edp2vga output.

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: Idf02a0d1e1bcef579fb3d6117a5e89744bdaac8a
2021-07-06 16:41:04 +08:00
Zefa Chen
8eed8785c4 media: i2c: ov8858 increase vts by add sensor PLL clk
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: I38e65fb4bfa6021b5f8cea3c2314cacf334dda6d
2021-07-06 11:59:57 +08:00
Yifeng Zhao
7b891c4c10 drivers: rk_nand: zftl: fix unexpected gfp: 0x4 (GFP_DMA32) printf
bug:
[    0.980989] rknandbase v1.2 2021-01-07
[    0.981645] rknand fe330000.nandc: rknand_probe clk rate = 148500000
[    0.981862] Unexpected gfp: 0x4 (GFP_DMA32). Fixing up to gfp: 0x6000c0 (GFP_KERNEL). Fix your code!
[    0.981875] CPU: 3 PID: 1 Comm: swapper/0 Not tainted 4.19.193 #35
[    0.981889] Hardware name: Rockchip RK3566 EVB1 DDR4 V10 Board (DT)
[    0.981901] Call trace:
[    0.981921]  dump_backtrace+0x0/0x15c
[    0.981934]  show_stack+0x14/0x1c
[    0.981949]  dump_stack+0xb8/0xf0
[    0.981963]  ___slab_alloc+0x5c4/0x5d8
[    0.981975]  __kmalloc+0x230/0x348
[    0.981989]  ftl_malloc+0x18/0x20
[    0.982002]  rk_ftl_init+0x5c/0x33c
[    0.982017]  rknand_dev_init+0x64/0x3e0
[    0.982028]  rknand_driver_init+0x3c/0x40
[    0.982040]  do_one_initcall+0x90/0x270
[    0.982053]  do_initcall_level+0xbc/0x160
[    0.982064]  do_basic_setup+0x30/0x48
[    0.982074]  kernel_init_freeable+0xb0/0x134
[    0.982085]  kernel_init+0x14/0x290
[    0.982096]  ret_from_fork+0x10/0x18

Signed-off-by: Yifeng Zhao <yifeng.zhao@rock-chips.com>
Change-Id: I8fe8eaee13a63e8d6df077ab9d5d004d583f2aa6
2021-07-05 20:17:25 +08:00
Zefa Chen
2a520d73f0 media: add motor driver fp5501 for camera focus/zoom
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: Ia417598fb196e320d82ff03fcfd921d89c6a762b
2021-07-05 15:03:48 +08:00
Steven Liu
e4b2ee8a88 serial: 8250_port: reset LSR DLAB before set MCR
When setting the 16550 serial port baud rate, you need
to configure the UART to loopback mode. After setting
the DLL and DLH, you need to reset the LSR first,
and then configure the MCR to make the UART return
to the normal mode. If you do not reset the LSR
first, an error will occur when the UART RX is still
receiving data.

Signed-off-by: Steven Liu <steven.liu@rock-chips.com>
Change-Id: Ia940b278554ef1d4e7a6c4550fe4a4600407a57e
2021-07-05 10:21:21 +08:00
Finley Xiao
eccf16e835 soc: rockchip: opp_select: Export rockchip_nvmem_cell_read_u8/u16()
Change-Id: I1c231afce31da9f42cd92839540d8dcb675778ce
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2021-07-05 09:42:36 +08:00
Finley Xiao
fcf284298c soc: rockchip: opp_select: Remove non-essential conditions for getting pvtm
Change-Id: I929046fa5c36f9cbc01e30edaa68f9abdfccdfd6
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2021-07-05 09:42:36 +08:00
Frank Wang
a7613ef6cd usb: gadget: f_uac1: adds support for SS and SSP
This adds UAC1 support of SS and SSP speed.

Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Change-Id: I896d9e36f05eef9bb3eacfc56ef7d32aa7c89044
2021-07-05 09:13:32 +08:00
Frank Wang
f7e1cb1a97 usb: gadget: f_uac2: make compatible for windows os
Amend to fix the UAC2 gadget could not be identified on Windows 10 OS.

Fixes: 486bd80e78f4 ("UPSTREAM: usb: f_uac2: adds support for SS and SSP")

Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Change-Id: I992af23ab4ac2740a33621d9c3c47368f5135710
2021-07-05 09:13:32 +08:00
Pawel Laszczak
7ef7c12df7 UPSTREAM: usb: f_uac2: adds support for SS and SSP
Patch adds support of SS and SSP speed.

Signed-off-by: Pawel Laszczak <pawell@cadence.com>
Link: https://lore.kernel.org/r/20210310105216.38202-1-pawell@gli-login.cadence.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Change-Id: Iea75fa1f76f11dfe61bb4dabfdbc09549ad006ea
(cherry picked from commit f8cb3d556b)
2021-07-05 09:13:32 +08:00
Hu Kejun
9b22b07cf5 media: spi: ms41908: zoom/focus use different reback value
Signed-off-by: Hu Kejun <william.hu@rock-chips.com>
Change-Id: I62ad6560bfd5aeb672aed2e5352bdacc68fd75f7
2021-07-02 16:00:42 +08:00
Felix Zeng
56d410da86 arm64: configs: rockchip_defconfig: Enable rknpu module
Signed-off-by: Felix Zeng <felix.zeng@rock-chips.com>
Change-Id: Ie86cfb931e46983875a4ee2adcf5760166bb38e8
2021-07-02 15:54:18 +08:00
Felix Zeng
9a93c881e9 driver: rknpu: Add rknpu driver for rk356x, version: 0.4.2
Signed-off-by: Felix Zeng <felix.zeng@rock-chips.com>
Change-Id: Ia9c19e37024d085010ef4c86a420ed5a9c831915
2021-07-02 15:54:07 +08:00
Felix Zeng
6888c9dac3 arm64: dts: rockchip: rk3568: rknpu: Add rknpu cru reset
Signed-off-by: Felix Zeng <felix.zeng@rock-chips.com>
Change-Id: Ibc546e80e6f82f0e907505a1eec1e9d37231646a
2021-07-02 15:47:47 +08:00
Felix Zeng
c164e7f75d arm64: dts: rockchip: rk3568: rknpu: Add new rknpu compatible with rk3568 target
Signed-off-by: Felix Zeng <felix.zeng@rock-chips.com>
Change-Id: I150aa58dc640cea47d30f89d7fefe500031cd074
2021-07-01 18:06:14 +08:00
Jon Lin
6bf5f1220e Revert "spi: rockchip: Add compatible string for rk3568"
This reverts commit 6a1a1cf4e7.

1.Set rk3568 spi node to fall back point
2.Both rk3568 and rv1126's spi is the same design

Change-Id: Ibbb8e4005ad7cd2a6d53eb4c700d657e1f95be7f
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2021-07-01 15:10:47 +08:00
Jon Lin
886073c63b arm64: dts: rockchip: rk3568: Set spi node to fall back point
Both rk3568' spi is compatible with rk3036's spi design.

Change-Id: I952beb57c151e77165db781bc17ec782b6bc62a4
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2021-07-01 14:59:59 +08:00
YouMin Chen
5d1bcbaa40 PM / devfreq: rockchip-dfi: add support lpddr4x
Change-Id: Icd86a458dc9843e80d9206d620a1da6a71adf799
Signed-off-by: YouMin Chen <cym@rock-chips.com>
2021-07-01 14:54:31 +08:00
Guochun Huang
fbc159156c arm64: dts: rockchip: rk3568: rename mipi_dphy to video_phy
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
Change-Id: Ie019c9d27e06328d45920d41c0a065f8bc47588f
2021-07-01 14:35:54 +08:00
Guochun Huang
b797fb0dfa phy/rockchip: inno-video-combo-phy: update for rk356x mipi_dphy
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
Change-Id: I33377ec3d0293a17dc5a231e50906d43dcf74781
2021-07-01 14:35:47 +08:00
Sandy Huang
e728bb617c drm/rockchip: driver: fix sub_dev pointer error
the sub_dev will be update by list_for_each_entry() and return !NULL
error pointer when no found subdev;

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: I8d7db3b66c6c57b986a42cac9ed6eca53b72611e
2021-07-01 10:32:42 +08:00
Wyon Bi
d8a6016ef3 drm/rockchip: analogix_dp: Add support for external bridge
The current output code only supports connection to drm panels.
Add code to support drm bridge, to support connections to
external connectors.

Change-Id: I775244b7183692f07b74123fa43c8bb958525087
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
2021-07-01 09:15:43 +08:00
Weixin Zhou
36b35520b4 input: touchscreen: cyttsp5: fix memory out of bounds write issue
Signed-off-by: Weixin Zhou <zwx@rock-chips.com>
Change-Id: I8d58353b74b96d6014613ae01e8a25643e2a50c9
2021-06-30 19:50:04 +08:00
Wyon Bi
403ae7fd2a drm/rockchip: cdn_dp: Fix link retrain condition
Validate the cached values of link parameters before
attempting to retrain.

Change-Id: Idf4f8a7c2d85109e05dc7e387f46ddeb55cd0a01
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
2021-06-30 18:59:33 +08:00
Wyon Bi
d7b5c81015 phy: rockchip-typec: Fix DP lane config
Split dynamic lane configuration from tcphy_dp_cfg_lane().

Change-Id: Ie4ce3138b30f3f9304daec9a9c582091548c0e60
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
2021-06-30 18:14:47 +08:00
Zheng Yang
3ab5d277d1 drm/bridge: dw-hdmi: fix rgb2yuv csc coeff
According the CEA-861, HDMI outputs the limited range by default.

Change-Id: I06fc1b92ca15e17fd27f3c09f9ced675f686c15f
Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
2021-06-30 17:49:02 +08:00
Zheng Yang
f0c323800d drm/rockchip: dw_hdmi: correct output bus format if unsupported_yuv_input
If unsupported_yuv_input is true, like RK3288, the current logic
will fix the output bus format to MEDIA_BUS_FMT_RGB888_1X24 or
MEDIA_BUS_FMT_RGB101010_1X30, does not changed width the property
hdmi_output_format. This patch fix the issue.

Change-Id: Iddf4182ea8eff066b5f4972c8c3802f7919eb7da
Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
2021-06-30 17:46:58 +08:00
Zorro Liu
a759193144 regulator: xz3216: update drivers to support vsel set
Signed-off-by: Zorro Liu <lyx@rock-chips.com>
Change-Id: Ifd686fb977f9d397d856cf6338499fcbbe674fd2
2021-06-30 11:23:18 +08:00
Dmitry Torokhov
f9560c9c14 cpufreq: interactive: fix policy locking
cpufreq_interactive_speedchange_task() is running as a separate kernel
thread and is calling __cpufreq_driver_target(), which requires callers
to hold policy->rwsem for writing to prevent racing with other parts of
the kernel trying to adjust the frequency, for example kernel thermal
throttling. Let's change the code to take policy->rwsem and while at it
refactor the code a bit.

This was originally 2 changes reviewed at:
	https://chromium-review.googlesource.com/246273
	https://chromium-review.googlesource.com/256120

Change-Id: Icc2d97c6c1b929acd2ee32e8c81d81fd2af778ab
Signed-off-by: Dmitry Torokhov <dtor@chromium.org>
Reviewed-by: Dylan Reid <dgreid@chromium.org>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Dmitry Torokhov <dtor@google.com>
Signed-off-by: Liang Chen <cl@rock-chips.com>
2021-06-30 10:52:20 +08:00
Shawn Lin
a6f921d31f mmc: dw_mmc-rockchip: Always fix ID mode clk request into 375KHz for RK356X
RK356X SoCs only support 375KHz for ID mode, otherwise it will be always
failed to set clk if the first attempt to identify cards.

Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Change-Id: I99ba322b3eeb4c4658869dc88b7a9f303081e12e
2021-06-30 10:40:21 +08:00
Zorro Liu
d6f112ccc1 drm/rockchip: ebc_dev: release version v2.03
1.add 8 pixel align buf process
2.overlay mode use double buf
3.add EPD_DU4 mode

Signed-off-by: Zorro Liu <lyx@rock-chips.com>
Change-Id: I849206c3776e445bff9e3722868ee8cc8b041e4e
2021-06-29 18:43:40 +08:00
Yandong Lin
536c29c220 arm64: dts: rockchip: rk3568: modify rkvdec compatible
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: I0c0d927bd4c995f2be4570a5c2128acbf7f6cc63
2021-06-29 18:22:37 +08:00
Yandong Lin
c2de227bfc dt-bindings: video: mpp: add rk3568 codec properties
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: I53eed4f4f0d444515dcac4c533baa15c8fba6f32
2021-06-29 18:20:25 +08:00
Yandong Lin
c7a7aa3370 video: rockchip: mpp: Fix 3568 cabac/cavlc switch issue
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: Ifd54d76470889e4d76d97cd33b2a4af26c7af6ab
2021-06-29 12:03:37 +08:00
Yifeng Zhao
b0868873db mmc: sdhci-of-dwcmshc: rk3568: do not enable DLL while the clock rate less than 52mhz
The DLL may not be able to lock while the clock rate less than 52mhz.

Signed-off-by: Yifeng Zhao <yifeng.zhao@rock-chips.com>
Change-Id: Ifacc3da516d78f5f242d8b03a60500a7dfe28993
2021-06-28 14:07:03 +08:00
Tao Huang
6770b766b4 regulator: xz3216: Fix gcc this statement may fall through warning
drivers/regulator/xz3216.c: In function 'xz3216_dcdc_set_suspend_mode':
drivers/regulator/xz3216.c:112:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
drivers/regulator/xz3216.c:115:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
drivers/regulator/xz3216.c:165:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
drivers/regulator/xz3216.c:168:3: warning: this statement may fall through [-Wimplicit-fallthrough=]

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I4709021a667a5def61361f27a1675099bcb7b45f
2021-06-28 10:37:59 +08:00
Cai YiWei
ff7380d396 media: rockchip: isp: clear rdbk fifo at dmarx stop
Change-Id: If26ebfa218da49d272c1e4aa0a2e8c7e4361ba5f
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2021-06-25 19:56:17 +08:00
Shunqing Chen
2f3b789905 media: i2c: rk628csi: workround avi packet probabitity error
If read the same value three times,
we think this avi patket is correct.

Signed-off-by: Shunqing Chen <csq@rock-chips.com>
Change-Id: I96154c38a79fe142368a2069175fa58fa2d38b0f
2021-06-25 16:29:58 +08:00
Zhihuan He
3fbe548efa include: linux: rockchip: add share mem page type define
The share mem page type should be corresponded with
smccc call.

Change-Id: I2fc97fc6841e2fd6ed7080d6af2fa2929ae355fb
Signed-off-by: Zhihuan He <huan.he@rock-chips.com>
2021-06-25 09:07:07 +08:00