Commit Graph

1065200 Commits

Author SHA1 Message Date
Sugar Zhang
77d904ce5f ASoC: rockchip: spdif: Ignore 0hz clk rate
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I491eef9b7729c1a5b0f9d59d5c868e9256a32c19
2022-03-07 10:02:14 +08:00
Guochun Huang
937265ceff phy: rockchip: mipi-dcphy: accurately set mipi channel rate to Kbps/Ksps level
take 1280x720@60Hz which pclk is 74.25Mhz as an example, the dsi
lane rate should set 445500 Kbps/lane(pclk x bpp = lane_rate x lanes)
when mipi work in no video burst pulse/event, therefore the PLL should
output the rate of Kbps/ksps level for normal display.

Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
Change-Id: I63bf5717e2da521b7af18d88c906b86e30a71488
2022-03-07 09:58:05 +08:00
Algea Cao
93010da346 drm/bridge: dw-hdmi-qp: Add cec driver
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
Change-Id: I4dbd69cdebaee8d1ff5231c72d4e1a9c30f9fd36
2022-03-04 19:43:59 +08:00
Liang Chen
242ce2942c arm64: configs: rockchip_linux_defconfig: enable CONFIG_UCLAMP_TASK
Also change UCLAMP_BUCKETS_COUNT to 20 copy form ANDROID-GKI.
Using the default setting 5 means the first bucket contains the
uclamp values from 0 to 19 (in percentage), in this case, if the
uclamp.min setting of a group is under 20, it will fall into this
bucket with other groups that have uclamp.min set to 0, which
increase the possibility of over boost. By setting the bucket
count to 20 will ease this situation, while a uclamp.min greater
than 4 will fall into a different bucket.

Signed-off-by: Liang Chen <cl@rock-chips.com>
Change-Id: I982a81acc303374aaf8defc004d08dd635402771
2022-03-04 18:31:00 +08:00
Liang Chen
a6550cf0bd arm64: configs: rockchip_defconfig: enable CONFIG_UCLAMP_TASK
Also change UCLAMP_BUCKETS_COUNT to 20 copy form ANDROID-GKI.
Using the default setting 5 means the first bucket contains the
uclamp values from 0 to 19 (in percentage), in this case, if the
uclamp.min setting of a group is under 20, it will fall into this
bucket with other groups that have uclamp.min set to 0, which
increase the possibility of over boost. By setting the bucket
count to 20 will ease this situation, while a uclamp.min greater
than 4 will fall into a different bucket.

Change-Id: Ibc6e1cb4358cfd6f9cda784b43d754545b893d7d
Signed-off-by: Liang Chen <cl@rock-chips.com>
2022-03-04 18:31:00 +08:00
Cai YiWei
f98d9b61a7 media: rockchip: isp: fix reg config for multi device
Change-Id: Ida20597e43fd6afeb9cb6a6c2e9a3595074b0d80
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2022-03-04 18:30:27 +08:00
Guochun Huang
7b63068bf0 drm/rockchip: dsi2: accurately set mipi channel rate to Kbps/Ksps level
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
Change-Id: I50e206a8e60c1fa8e1668d2d9fb71e0b161599c9
2022-03-04 18:29:35 +08:00
Zhang Yubing
a1da8104ca drm/rockchip: vop2: change pixelclk calculation method for mipi
Both DP and MIPI get pixelclk from dclk_out as follow:
DP: dclkx_out(DIV)->dpn_pixelclk(MUX)
MIPI:dclkx_out(DIV)->mipi_clk_src(MUX)->mipi_pixelclk(DIV)

When a video port coonect DP, it will calculate dclk rate first,
then dclk out rate, finally dp pixelclk rate. When a video Port
connect to MIPI it will calculate mipi_pixelclk rate first.

The different calculation method may get different dclk rate or
divider ratio. When a video port connect to a DP and MIPI, DP
or MIPI may get the wrong pixel rate. So they need use the same
method to calculate pixelclk.

When A video port connect DP and MIPI, the mipi_pixelclk
is set first, and set the mipi_pixelclk divide value. Then
dp_pixelclk is set, which will modify dclk_out divide value
and cause the mipi_pixelclk change.

So when calculate the mipi_pixelclk, we calculate the dclk_out
first to avoid the mipi_pixelclk be modified when DP set
dp_pixelclk.

For uboot logo display, Depend on commit from u-boot(branch:
next-dev):
(I6037e12d8b6 drm/rockchip: vop2: change dclk calculate method
for mipi)

Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
Change-Id: I53c3247ce1eb728dad7f480d86b65d3f922ab6d4
2022-03-04 18:04:08 +08:00
Finley Xiao
b8e104fa2d arm64: dts: rockchip: rk3588s: Modify rockchip,pvtm-voltage-sel
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I5b5b75ccba9e90f246db9305758eebe517a278df
2022-03-04 17:55:50 +08:00
Steven Liu
675d82c5d7 pinctrl: rockchip: add rv1106 support
Signed-off-by: Steven Liu <steven.liu@rock-chips.com>
Change-Id: Iae9790f26ab9e657958e1e5e95d6023e829481ca
2022-03-04 17:33:20 +08:00
Liang Chen
666fa6cca7 arm64: dts: rockchip: rk3588s: change cpu dynamic-power-coefficient
Change cpu dynamic-power-coefficient across EAS data.

Change-Id: I06e3d4e8e05d8c42d3d2de74c8369ba51c575e66
Signed-off-by: Liang Chen <cl@rock-chips.com>
2022-03-04 17:23:33 +08:00
Elaine Zhang
80f35f6e2d clk: rockchip: rk3588: modify xin_osc0_func to xin24m
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I626410aff2c9b20bd3a865240c1b42b26b359baa
2022-03-04 16:59:16 +08:00
Lin Jinhan
9b42303f79 crypto: rockchip: fix dma_map_sg/dma_unmap_sg not paired when using dma_fd
dma_fd buffer has been mapped by cryptodev and does not need to
 be mapped again.

Signed-off-by: Lin Jinhan <troy.lin@rock-chips.com>
Change-Id: Ic28bebe3b169dfc4cb1fde4457122277f32294bf
2022-03-04 11:32:07 +08:00
Lin Jinhan
0053651587 crypto: rockchip: cryptodev_linux: added non-multithreaded protection
CRYPTO V1/V2 do not support multi-threading, so it is necessary
 to add a hold mechanism in Cryptodev to prevent abnormal consequences
 caused by multi-threading calls.

Signed-off-by: Lin Jinhan <troy.lin@rock-chips.com>
Change-Id: Ifd5ff6b102c81c8ac44c16f9689d5219c7fa5a56
2022-03-04 10:24:53 +08:00
Wangqiang Guo
dfe02a6b7b arm64: rockchip_defconfig: enable CONFIG_LS_UCS14620
CONFIG_LS_UCS14620 is used to enable light sensor ucs14620
which found on rk3588s tablet rk806 single board.

Signed-off-by: Wangqiang Guo <kay.guo@rock-chips.com>
Change-Id: Ib824361aacd7cf44fb2125f151f85b590c793e2b
2022-03-03 21:37:46 +08:00
Wangqiang Guo
4a628c42c5 arm64: rockchip_defconfig: enable CONFIG_PS_UCS14620
CONFIG_PS_UCS14620 is used to enable proximitily sensor ucs14620
which found on rk3588s tablet rk806 single board.

Signed-off-by: Wangqiang Guo <kay.guo@rock-chips.com>
Change-Id: I94a8dd2a4d86f3f1feb201eeb2dc7b3d56601adc
2022-03-03 21:31:59 +08:00
Yu Qiaowei
fdf8b0fb96 video: rockchip: rga3: Remove iommu_api that does not support GKI
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: Ie90b87aa84758644a4696e59a63c48d2fbb8e7b2
2022-03-03 21:03:23 +08:00
Yu Qiaowei
431ced4368 video: rockchip: rga3: Fix hardware support format
1. RGA3 support ARGB/ABGR8888 input.
2. RGA3 support YUV420 packed output.

Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: I7680ed7b0218998f67e0d1ed40cc2ad3690b8572
2022-03-03 21:03:23 +08:00
Yu Qiaowei
5c988d7aa1 video: rockchip: rga3: update rga_debugger
1. Add 'debug' mode in debug node.
2. Fix compilation error when procfs is enabled.

Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: I88bdcad127a726a6b2618d54c2c3958a663bc6d7
2022-03-03 21:03:23 +08:00
Wang Panzhenzhuan
1fa592b341 media: i2c: imx415: fix lock check warning
resolve the warning log below:
[    3.116535][    T1] ------------[ cut here ]------------
[    3.116555][    T1] WARNING: CPU: 4 PID: 1 at
drivers/media/v4l2-core/v4l2-ctrls.c:4435 __v4l2_ctrl_s_ctrl+0x70/0x88
[    3.116562][    T1] Modules linked in:
[    3.116575][    T1] CPU: 4 PID: 1 Comm: swapper/0 Not tainted 5.10.66
[    3.116583][    T1] Hardware name: Rockchip RK3588 EVB1 LP4 V10 Board
(DT)
[    3.116591][    T1] pstate: 60c00009 (nZCv daif +PAN +UAO -TCO
BTYPE=--)
[    3.116598][    T1] pc : __v4l2_ctrl_s_ctrl+0x70/0x88
[    3.116606][    T1] lr : __v4l2_ctrl_s_ctrl+0x3c/0x88
[    3.116612][    T1] sp : ffffffc012d0ba10
[    3.116619][    T1] x29: ffffffc012d0ba10 x28: 0000000000000000
[    3.116631][    T1] x27: 00000000009e0901 x26: ffffffc01155bdb0
[    3.116642][    T1] x25: ffffffc01155c998 x24: ffffff8104b6e100
[    3.116653][    T1] x23: ffffff8104b6e278 x22: ffffff8104b6e400
[    3.116664][    T1] x21: ffffff81044e0000 x20: 0000000000000001
[    3.116675][    T1] x19: ffffff810506b600 x18: ffffffc012d05098
[    3.116686][    T1] x17: 0000000000000000 x16: ffffff8100338000
[    3.116697][    T1] x15: ffffffc012bae000 x14: ffffffc01220eeb0
[    3.116708][    T1] x13: 00000000ffffffff x12: ffffffc0125e0f30
[    3.116719][    T1] x11: 0000000100000002 x10: 00000000000000ff
[    3.116731][    T1] x9 : 0000000000000000 x8 : ffffffc1ed1b9000
[    3.116742][    T1] x7 : ffffffc010cb8ebc x6 : ffffff81003389f8
[    3.116752][    T1] x5 : 0000000000000000 x4 : 0000000000000001
[    3.116763][    T1] x3 : ffffff8104b6e320 x2 : 0000000000000000
[    3.116774][    T1] x1 : ffffff8104b6e468 x0 : 0000000000000000

Signed-off-by: Wang Panzhenzhuan <randy.wang@rock-chips.com>
Change-Id: I1ec8de71d644cee4d81e16db7054da21677732bf
2022-03-03 20:18:52 +08:00
Sandy Huang
20cf1fde7c drm/rockchip: vop2: fix cluster alpha error at splice mode
Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: I29564be93e58b73227a9390a93f4d30ff1084456
2022-03-03 20:11:10 +08:00
Ding Wei
8c0bf43f09 arm64: dts: rockchip: rk3588: Add node for avs plus decoder
Change-Id: I3d2a4609fedb0ac27bc0b3b18de6908bbc01928d
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2022-03-03 20:01:06 +08:00
Yandong Lin
2e8bbf3c08 arm64: dts: rockchip: enable av1d iommu for rk3588-nvr
The av1d node is register av1dec_bus not platform bus,
so it no need to set okay status.

Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: Id5ab7c5bf8380221b663730596335e9bda1eb6b2
2022-03-03 20:00:20 +08:00
Yandong Lin
cefea8c402 arm64: dts: rockchip: enable av1d iommu for rk3588 evb/tablet
The av1d node is register av1dec_bus not platform bus,
so it no need to set okay status.

Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Signed-off-by: Simon Xue <xxm@rock-chips.com>
Change-Id: I9c88340d6542c497b3e4b24406db93bd60369fd8
2022-03-03 19:58:48 +08:00
Yandong Lin
c125c678f6 video: rockchip: mpp: support av1 decode
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Signed-off-by: Simon Xue <xxm@rock-chips.com>
Change-Id: I76b54488c9078688ebc9c4df902e6940c95f3594
2022-03-03 19:57:17 +08:00
Herman Chen
e6f26e1367 video: rockchip: mpp: rkenc2: Add core parallel
Enable two core parallel working support.

Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I102d2ff2882041594f089be44e7782c84e103f99
2022-03-03 19:50:56 +08:00
Jon Lin
28d87a7fab mtd: spi-nor: gigadevice: Add support gd25lb512m gd25b512m
Change-Id: Ibaa1807d5bb00627a3c3889f7290b3f8fe5f8f82
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-03-03 18:37:44 +08:00
Zhen Chen
7c3725c8f1 MALI: bifrost: remove a verbose log
Signed-off-by: Zhen Chen <chenzhen@rock-chips.com>
Change-Id: I06184a601d5817d87433cbcde19b39bccc12f774
2022-03-03 18:19:25 +08:00
Finley Xiao
08403c1ceb arm64: dts: rockchip: rk3588s: Modify opp table for cpul
Add pvtpll support for cpul.

Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I8f318e26d9a74f89389256266e78682b93e0c2ce
2022-03-03 18:02:08 +08:00
Finley Xiao
038080da03 arm64: dts: rockchip: rk3588s: Modify npu opp table
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I2ee85bbfe3e48ac90a403094a290ef2cd17fc924
2022-03-03 18:02:03 +08:00
Finley Xiao
44c8771eaa arm64: dts: rockchip: rk3588s: Modify gpu opp table
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: Id3167f3c7b98ee3a004fc0ef6ab7e24a0680d9e6
2022-03-03 18:01:57 +08:00
Finley Xiao
fcfda393ed arm64: dts: rockchip: rk3588s: Modify cpub opp table
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I5d6a2222c03d19f85ec83bdbe4399c0a2e7de9f5
2022-03-03 18:01:50 +08:00
Finley Xiao
816f5aea02 soc: rockchip_system_monitor: Set intermediate rate before change read margin
Improve stability when change read margin.

Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: If283af8895eead5ec8f86cf7f03eca28fc1d2a45
2022-03-03 18:01:38 +08:00
Finley Xiao
1f40ab6977 driver: rknpu: Set intermediate rate before change read margin
Improve stability when change read margin.

Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I36c9258c3a5b87d44416d19d38fc81f3101fb3a4
2022-03-03 18:01:38 +08:00
Finley Xiao
eb26be047e MALI: bifrost: Set intermediate rate before change read margin
Improve stability when change read margin.

Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I0ddb1d00c670cbc8e4c64f999382f1420a86c537
2022-03-03 18:01:38 +08:00
Finley Xiao
c00e3a0e83 cpufreq: rockchip: Set intermediate rate before change read margin
Improve stability when change read margin.

Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I25a4b00c37b05e8de404ffbd9904a5b65288b077
2022-03-03 18:01:38 +08:00
Finley Xiao
45d2158ce7 soc: rockchip: opp_select: Add support to get pvtpll pvtm
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: If718c854bbf752026c259314ed5230026302f0d2
2022-03-03 18:01:38 +08:00
Finley Xiao
f3a5053707 soc: rockchip: opp_select: Implement rockchip_set_read_margin()
Add common APIs to set read margin and set intermediate rate.

Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I8fb1d16f4ca1a9ec0ba80019197a73e56391c14c
2022-03-03 18:01:38 +08:00
Finley Xiao
f5f2d23805 soc: rockchip: opp_select: Implement rockchip_get_read_margin()
In order to get target read margin and scmi clk earlier,
and it will also be used in later submissions.

Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I75bd79dc4963fa0dcc73d7c66a696e1cc0c177b7
2022-03-03 18:01:38 +08:00
Yandong Lin
686e5857b5 arm64: dts: rockchip: add av1d node for rk3588
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: Ica90c91b53524101ae9ae85819f4aea5e1fdfb42
2022-03-03 16:35:24 +08:00
Yandong Lin
323057a650 arm64: configs: rockchip_defconfig: enable av1dec
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: Ie2adbb18eb28a4d1c488fcb4a34b3015ae63cd81
2022-03-03 16:34:46 +08:00
Damon Ding
a2c4bf9e96 drm/rockchip: vop2: add func rockchip_drm_crtc_standby()
In order to modify the logic, check whether the standby
function is supported by (*crtc_standby). And add the
universal function rockchip_drm_crtc_standby().

Replace vop2_standby() by rockchip_drm_crtc_standby() in
dsi2 driver.

Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
Change-Id: I974780c441fe0e9a8a81f933b3070a727321b589
2022-03-03 16:23:43 +08:00
Ding Wei
418d20a4f1 arm64: dts: rockchip: rk3588: rkvdec2: Set master-handle-irq
Change-Id: Ia5981c8b80b0b66ff05ee3033bbc704e9fd8333c
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2022-03-03 16:20:13 +08:00
Ding Wei
12f76c8580 video: rockchip: mpp: rkvdec2: Trigger reset when iommu pagefault
1. When iommu pagefault, hardware will stop and wait to deal with it.
in order to respond quickly, such as NVR, reset the hardware directly.
2. The iommu handle should be for the current device, not the queue.
and, the mpp_task_dump_hw_reg function is used to dump hardware register
info, it no relation for task.
3. In the mode of link-mode and multi-core, it cannot accurately get task
via queue->running_task, thereforce, it is not suitable to dump task
register here.

Change-Id: Ifed2cbc484997a07ed65c38c16062abe9b9aff81
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2022-03-03 16:14:03 +08:00
Ding Wei
a8e9b2055a video: rockchip: mpp: sip reset for soft-ccu
1. for rk3588, it may hung for when bus error, then, it should
   use sip reset.
2. before reset, it make sure that the clock is on.

Change-Id: I2dd1dc5c4cd273eb8678ceaa29b0e966828f50fd
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2022-03-03 16:13:55 +08:00
Ding Wei
be0296b414 iommu/rockchip: Add pagefault handle callback for device
Change-Id: I6998390ea6e5bf41ab21364cad7471603f8d362f
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2022-03-03 16:06:12 +08:00
Damon Ding
7116c11f51 drm/rockchip: add config options of VOP and VOP2 driver
rv1126 does not support VOP2, so add config options to
reduce memory usage.

./ksize.sh  drivers/gpu/drm/

before ksize: 487941 Bytes
after  kszie: 380303 Bytes
save   about: 107628 Bytes

In addition, improve the format of space and tab, and remove
extra "depends on DRM_ROCKCHIP".

Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
Change-Id: I2b29a543a7e52e4e4b72112980e2c6dc6c6cce92
2022-03-03 15:46:30 +08:00
Simon Xue
b1cec75764 dma-buf: heaps: add rockchip heaps
Change-Id: If7dad5ace1164ff09bc5bc5bbc4589b63b7ac2f6
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2022-03-03 15:13:36 +08:00
Steven Liu
6c93ab7f1d ARM: dts: rockchip: Add gpio aliases for RV1106
Signed-off-by: Steven Liu <steven.liu@rock-chips.com>
Change-Id: Ib32dde644f9079403c37e9e97289682913a5fd8e
2022-03-03 14:19:14 +08:00
David Wu
e39283d8b4 ethernet: stmmac: dwmac-rk: Add gmac support for rv1106
Add constants and callback functions for the dwmac on RV1106 soc.
As can be seen, the base structure is the same,.In addition, there is
an internal phy inside.

Signed-off-by: David Wu <david.wu@rock-chips.com>
Change-Id: I5889a7dd8bdbbbf763a617c5d1aa525454006e39
2022-03-03 14:11:44 +08:00