Commit Graph

1281297 Commits

Author SHA1 Message Date
Tao Huang
688b53c7af pwm: Call pwm_sysfs_init() early when CONFIG_INITCALL_ASYNC=y
rockchip_pwm_driver_init() -> rockchip_pwm_probe() -> devm_pwmchip_add()
-> pwmchip_add() -> pwmchip_sysfs_export()
pwmchip_sysfs_export() depends on pwm_sysfs_init() to init pwm_class.
But rockchip_pwm_driver_init() and pwm_sysfs_init() are both in the same
subsys_initcall level.

Fix this by move pwm_sysfs_init() to the postcore_initcall level.

Change-Id: If865768904be463732a5d2cb9f6ee2e9b333c0b3
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2025-04-21 02:19:49 +00:00
Tao Huang
081aacf209 dmaengine: rockchip-dma: Call rk_pdma_driver_init() early when CONFIG_ROCKCHIP_THUNDER_BOOT=y
Moving rk_pdma_driver_init() to the arch_initcall_sync level.
Before rk3x_i2c_driver_init() etc.

Change-Id: Iafcb84b1537453ffb295bb7722d4455e75657e9c
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2025-04-21 02:19:49 +00:00
Tao Huang
439b8b9cc8 drm/panel: simple: Call panel_simple_init() early when CONFIG_ROCKCHIP_THUNDER_BOOT=y
Moving panel_simple_init() to the rootfs_initcall level.
Before rockchip_drm_init().

Change-Id: If74f0888e0120189b58c8eb96485eb3c9ada7e4f
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2025-04-21 02:19:49 +00:00
Tao Huang
0ec605a383 iommu/rockchip: Call rk_iommu_init() early when CONFIG_ROCKCHIP_THUNDER_BOOT=y
Moving rk_iommu_init() to the subsys_initcall level.
Before rga_init() etc.

Change-Id: I050b96eb93f1fcb0fe12e12cbf95eb778678f44c
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2025-04-21 02:19:49 +00:00
Tao Huang
a22a2f016f regulator: pwm: Call pwm_regulator_driver_init() early when CONFIG_ROCKCHIP_THUNDER_BOOT=y
Regulator init on subsys_initcall_sync level.

Change-Id: I477e8282dfb4582ac29f1b789a286c5d5ed7c60c
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2025-04-21 02:19:49 +00:00
Tao Huang
936063c332 iio: adc: rockchip_saradc: Call rockchip_saradc_driver_init() early when CONFIG_ROCKCHIP_THUNDER_BOOT=y
Moving rockchip_saradc_driver_init() to the fs_initcall level.
Before adc_keys_driver_init().

Change-Id: I63ec4bd84ba1c9bd63359b2efc9559949d6311c7
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2025-04-21 02:19:49 +00:00
Tao Huang
9b4428f7b6 clocksource: Call clocksource_done_booting() early when CONFIG_ROCKCHIP_THUNDER_BOOT=y
Make sure subsys initcall fast.

Change-Id: Ib197b79477afaa6af6b35aeefab53137ee9f6749
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2025-04-21 02:19:49 +00:00
Yu Qiaowei
d4a3012c24 video: rockchip: rga3: remove dependency on CONFIG_IOMMU_IOVA
Since 'CONFIG_IOMMU_IOVA' is often disabled on 32-bit systems, causing
iommu_map API calls to fail, the DMA mapping API is used instead.

Change-Id: I7226ddf6a04e0af4c6b1b029bb5a32ede04c0810
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
2025-04-18 09:11:27 +00:00
Sach Lin
b6558f3a76 media: rockchip: avsp: add support for fbce head offset
Signed-off-by: Sach Lin <sach.lin@rock-chips.com>
Change-Id: Ic72bd2cc5e23af9cac2ee46884da9e0c3b0ea317
2025-04-18 07:49:13 +00:00
Xu Hongfei
4719bd6e80 media: rockchip: fec: add module parameter user_debug
Signed-off-by: Xu Hongfei <xuhf@rock-chips.com>
Change-Id: I1bd315aff2ee527241a29afff557e23531cbc440
2025-04-18 07:39:44 +00:00
Zhang Yubing
6609d45ac5 drm/rockchip: dw-dp: mst mode don't allow external bridge create connector
In mst mode, dptx driver will dynamic create and destroy
connector according to the attach mst device. If a external
bridge is add for dp in mst mode, this bridge is not allow
to create connector.

Change-Id: I811baf5116e4c2cd1d12b04ead2054abcccbdffd
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2025-04-18 06:56:14 +00:00
Zhang Yubing
97932bdf73 drm/rockchip: dp_aux_client: parse timing by child node name
The child node may be not parsed by the order config in dts,
it would be better get child node by name to avoid mismatch.

Change-Id: Ibce47f44720f279eb53f063a351d3b859a371fd8
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2025-04-18 14:41:47 +08:00
Su Yuefu
96aab710fb arm64: dts: rockchip: rv1126b-evb2-v10: fixes error of cam reset pin of sc850sl
Signed-off-by: Su Yuefu <yuefu.su@rock-chips.com>
Change-Id: I908e8b1e30b49b2058b0cd00d5075e631be8f0ae
2025-04-18 06:05:21 +00:00
Xu Hongfei
dae6de0d5d media: rockchip: fec: add support for offset and stride configuration
Signed-off-by: Xu Hongfei <xuhf@rock-chips.com>
Change-Id: If1ac6a30be8b4d1a2c60a9696cb1b33122c1f407
2025-04-17 19:34:45 +08:00
Liang Chen
683c36d1db arm64: dts: rockchip: rv1126b: update opp-table for cpu/npu
Adjust pvtm-voltage-sel table of cpu to calibrate cpufreq better.

Change-Id: I36f440eee378b3d6865d6beb148ee3a5677fcb22
Signed-off-by: Liang Chen <cl@rock-chips.com>
2025-04-17 18:23:20 +08:00
Liang Chen
ab74750ff8 clk: rockchip: clk-pvtpll: update cpu/npu pvtpll config for rv1126b
Change-Id: I3a594b18b8c6ced41f13fd6abdc7783b8083612d
Signed-off-by: Liang Chen <cl@rock-chips.com>
2025-04-17 18:23:20 +08:00
Jon Lin
1b882fcf73 PCI: rockchip: dw_ep: Support rockchip,ep-power-independent
sually, RK EP is directly powered by RC, and the entire device
reset switch of EP is controlled by PERST#. If EP is powered
independently, EP will enter the initialization phase independently
of RC. In order to wait for the REFCLK provided by RC to stabilize,
the definition of reset-gpio has been added to identify PERST# gpio
signal translation.

Change-Id: I45f6d176a0a71615ccbbde11f419475ad8600dd3
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2025-04-17 16:38:04 +08:00
Jon Lin
34ba677ded PCI: rockchip: dw-ep: Support setting link_gen
Change-Id: I1b93b04e45a39e93e774a2ade8a00865f1e6f5ed
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2025-04-17 08:31:01 +00:00
Jon Lin
ad8d1ad7f2 PCI: rockchip: dw-ep: Support ltssm fifo debug
Set RK_PCIE_DBG to 1 to enable ltssm fifo debug.

Change-Id: If88824e7bb7455006b0cf7ceac5bb901bf76f282
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2025-04-17 08:31:01 +00:00
Jon Lin
e31d0ecd30 PCI: rockchip: dw-ep: Support BAR1 and BAR5 mmap
Change-Id: Ibc34c387ca69ba17d64cc2c91a2be1d6fc2faa22
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2025-04-17 08:31:01 +00:00
Jon Lin
a5ee25a6ff misc: rockchip: pcie-rkep: Support BAR1 and BAR5 mmap
Change-Id: I59983fd9cd0153966eb0f539ae9b082f05dae5b1
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2025-04-17 08:31:01 +00:00
Jon Lin
b730a5ac78 PCI: rockchip: dw-ep: Support link up status double check
Change-Id: I6b1807ea1dce5c05a040823717b50edf7a6109d9
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2025-04-17 08:31:01 +00:00
LongChang Ma
f3dd6b3cc4 media: i2c: sc450ai: adjust 2lane setting vblank value
Signed-off-by: LongChang Ma <chad.ma@rock-chips.com>
Change-Id: Id64fe9ad58a816fb5ba96afc99bbcb6235fc8fc7
2025-04-17 08:25:55 +00:00
Yu Qiaowei
10c09cfd31 video: rockchip: rga3: fix crash caused by vir_addr call in 'mm' debug mode
Change-Id: I16223557d18f5f0bd99f468b34713157897e0f5d
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
2025-04-17 08:23:48 +00:00
Elaine Zhang
06f6ae89f8 clk: rockchip: rv1126b: fix clk_ref_pipephy parent clk
Change-Id: I9f127782afc4846485931733bb22f0384abce2a4
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2025-04-16 12:06:07 +00:00
Damon Ding
856d44d638 pwm: rockchip: use the completion to check whether biphasic result is valid
In some cases, the discontinuous biphasic result may not be valid
after sleeping for specified time due to the interrupt preemption.
Therefore, it may be better to use the completion and set the actual
wait time to the 3/2 of the specified delay time.

Change-Id: Ib7ee5f7ceb53c195178e25d745985577fa8a6c4c
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-04-16 10:15:05 +00:00
Damon Ding
4fcd88017a pwm: rockchip: use the completion to check whether frequency result is valid
In some cases, the frequency result may not be valid after sleeping
for specified time due to the interrupt preemption. Therefore, it may
be better to use the completion and set the actual wait time to the
3/2 of the specified delay time.

Change-Id: I5b9879ff9eaaf41ace5534040e0e47ec9bca7cc0
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-04-16 10:15:05 +00:00
Zitong Cai
a9be2283b5 arm64: dts: rockchip: add rk3588-vehicle-evb-v23-linux
Change-Id: Icf1352cd1f5cf8177e5fc86ac0b9cf312cd7ff94
Signed-off-by: Zitong Cai <zitong.cai@rock-chips.com>
2025-04-16 17:18:21 +08:00
Damon Ding
e1f6d87fc5 drm/bridge: analogix_dp: use &link_train.max_lane_count to determine the &link_train.lane_count
Fixes: a205209330 ("drm/bridge: analogix_dp: Add &link_train.max_link_rate and &link_train.max_lane_count")
Change-Id: I9938e43bd37ddfc93838849c35dd2e76c8d31f0c
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-04-16 08:00:37 +00:00
Xu Hongfei
3a1446746c media: rockchip: fec: add module parameter cache_linesize
mapping between value and mode:
0: 64B
1: 64B
2: 128B(default)
3: 128B

Signed-off-by: Xu Hongfei <xuhf@rock-chips.com>
Change-Id: Ic4bf8ab9486e1fabeedce2b5baeebb8bed6edba8
2025-04-16 07:59:45 +00:00
Damon Ding
14c4d46162 pwm: rockchip: fix the check of disabling process for continuous biphasic counter mode
If the &rockchip_pwm_biphasic_config.enable is set to false in
continuous biphasic counter mode, &rockchip_pwm_chip.biphasic_config
will be set to NULL after &rockchip_pwm_funcs.set_biphasic.

Without this patch, there may be the null pointer exception.

Fixes: 7a42db27aa ("pwm: rockchip: support for biphasic counter mode")
Change-Id: Ie6fb5e3b1c69ae055720716531ddebb64dbf30bf
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-04-16 07:58:15 +00:00
YouMin Chen
1c78e90e9e arm64: dts: rockchip: rk3576: add dmcdbg node
Change-Id: I585f65eb4499148254cd182dbc07f01c9415a8c1
Signed-off-by: YouMin Chen <cym@rock-chips.com>
2025-04-16 07:49:58 +00:00
YouMin Chen
099aace73e arm64: dts: rockchip: rk3588: add dmcdbg node
Change-Id: I3c85a9be7ef20cadbb15156f2c936bf5d1cdf334
Signed-off-by: YouMin Chen <cym@rock-chips.com>
2025-04-16 07:49:58 +00:00
YouMin Chen
03c1fbf979 arm64: dts: rockchip: rk356x: add dmcdbg node
Change-Id: I166e113176f054a07ec4b88f344f76ec3efd8aec
Signed-off-by: YouMin Chen <cym@rock-chips.com>
2025-04-16 07:49:58 +00:00
YouMin Chen
08801283e8 arm64: configs: rockchip_linux_defconfig enable ROCKCHIP_DMC_DEBUG
Change-Id: I8136fe14ba1572300a21700ae4b8efff233ff7ac
Signed-off-by: YouMin Chen <cym@rock-chips.com>
2025-04-16 07:45:48 +00:00
YouMin Chen
478e4ff291 ARM: configs: rockchip_linux_defconfig enable ROCKCHIP_DMC_DEBUG
Change-Id: I59e3c646f09de88e56ce13c65a343bb829f655ca
Signed-off-by: YouMin Chen <cym@rock-chips.com>
2025-04-16 07:45:25 +00:00
YouMin Chen
c065ef4421 soc: rockchip: dmc_debug: move driver and support more rockchip SOCs
Change-Id: I310e53b7e8333a2fff7b69b284fe3e8a8dcd4861
Signed-off-by: Zhihuan He <huan.he@rock-chips.com>
Signed-off-by: YouMin Chen <cym@rock-chips.com>
2025-04-16 15:26:00 +08:00
Liang Chen
625ce41d30 arm64: dts: rockchip: rv1126b: add pvtpll node for isp
Change-Id: I536338f58a62db9c45a43358c6f518d8209b6675
Signed-off-by: Liang Chen <cl@rock-chips.com>
2025-04-16 04:05:11 +00:00
Liang Chen
9a1bda7890 clk: rockchip: clk-pvtpll: add isp pvtpll clk for rv1126b
Change-Id: Ieecb8492e1bb1da918bb486b3097d5356e647a14
Signed-off-by: Liang Chen <cl@rock-chips.com>
2025-04-16 04:03:57 +00:00
Weiwen Chen
79fb79ef7a ARM: configs: rv1126b-ipc.config: update camera sensor
-CONFIG_VIDEO_SC3336=m
-CONFIG_VIDEO_SC530AI=m
+CONFIG_VIDEO_SC450AI=m
+CONFIG_VIDEO_SC850SL=m

Update with cmd:
    make ARCH=arm rv1126b_defconfig
    cp .config tmp.config
    make ARCH=arm rv1126b_defconfig rv1126b-ipc.config
    ./scripts/diffconfig -m tmp.config .config > rv1126b-ipc.config

Signed-off-by: Weiwen Chen <cww@rock-chips.com>
Change-Id: I049cbec04bcee70e9b929c946ba8c88ae8da3a8e
2025-04-16 03:15:42 +00:00
Elaine Zhang
6d253a7dab net: can: rockchip: rk3576: support auto retx cnt setting
Change-Id: Ibe195527e08ed68c1f1262fe4957ab84c4426232
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2025-04-16 02:07:46 +00:00
Zefa Chen
9e061599fe media: rockchip: vicap fixes array out of bounds issue
Change-Id: Iaa4d6562aae6c0b43598253458d52b224246a18b
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
2025-04-16 02:06:34 +00:00
Su Yuefu
bf9e78d287 arm64: dts: rockchip: rv1126b-evb3-v10: fix mclk and dphy error
Signed-off-by: Su Yuefu <yuefu.su@rock-chips.com>
Change-Id: I2dfcc163eb84c5e8cc2b1e55820b9036ff81fbe4
2025-04-16 02:04:06 +00:00
GangGuo Wang
1c80d2ad19 arm64: dts: rockchip: rv1126bp-evb: Add spi nand config in rv1126bp-evb-v14.dts
Signed-off-by: GangGuo Wang <gavin.wang@rock-chips.com>
Change-Id: If631127210307f66dcd852c0e4db2bec66cf2ed3
2025-04-15 12:14:34 +00:00
Zitong Cai
0d044fa811 arm64: dts: rockchip: rk3576-vehicle-evb: Fix the flashing screen issue
After completing the initialization of serdes in uboot, enter the kernel
to perform initialization again

Change-Id: I689c30f55d9e259e5adaa95029f7523026cbed0a
Signed-off-by: Zitong Cai <zitong.cai@rock-chips.com>
2025-04-15 09:46:50 +00:00
Zitong Cai
360ebad14a arm64: dts: rockchip: rk3576-vehicle-evb-v20.dts: Fix the flashing screen issue
After completing the initialization of serdes in uboot, enter the kernel
to perform initialization again

Change-Id: Ia603bd2b8892f1647d0c0fa37f38e1422f78a6b3
Signed-off-by: Zitong Cai <zitong.cai@rock-chips.com>
2025-04-15 09:46:08 +00:00
Caesar Wang
f7e3e42816 ARM: configs: Enable CONFIG_DRM_IGNORE_IOTCL_PERMIT for rv1126b-display.config
Change-Id: I6f60a766963ab11bba3866550c12ae0a4dc4c5f7
Signed-off-by: Caesar Wang <wxt@rock-chips.com>
2025-04-15 09:38:37 +00:00
Cai YiWei
6b1fd4927d media: rockchip: isp: fix isp32 lite stats error
error info
WARNING: CPU: 3 PID: 422 at drivers/media/common/videobuf2/videobuf2-core.c:2035 __vb2_queue_cancel+0x1f8/0x260
Modules linked in: bcmdhd(O)
CPU: 3 PID: 422 Comm: binder:422_2 Tainted: G        W  O       6.1.118 #390
Hardware name: Rockchip RK3562 EVB2 DDR4 V10 Board (DT)
pstate: 60400005 (nZCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : __vb2_queue_cancel+0x1f8/0x260
lr : __vb2_queue_cancel+0x38/0x260
sp : ffffffc00c3dbb60
x29: ffffffc00c3dbb60 x28: 0000000000000013 x27: ffffffc00c3dbcd0
x26: ffffffc0097266d8 x25: ffffff804b310e40 x24: ffffff800ff09a00
x23: ffffff80054f8538 x22: ffffff80054ee228 x21: ffffff80054ee228
x20: ffffff800ff09a00 x19: ffffff80054eded0 x18: ffffffc00bce1070
x17: 6e696d6165727473 x16: ffffffffffffffff x15: 0000000000000004
x14: ffffffc009ffc980 x13: 0000000000003fff x12: 0000000000000003
x11: 0000000000000000 x10: 0000000000000001 x9 : 32e96f8e48c96c00
x8 : 0000000000000001 x7 : 205b5d3038393739 x6 : 372e33303738205b
x5 : ffffffc00c3dba30 x4 : 0000000000000000 x3 : 0000000000000000
x2 : 0000000000000001 x1 : 0000000000000000 x0 : 0000000000000000
Call trace:
 __vb2_queue_cancel+0x1f8/0x260
 vb2_core_streamoff+0x28/0xac
 vb2_ioctl_streamoff+0x84/0xb8
 v4l_streamoff+0x24/0x30
 __video_do_ioctl+0x2d8/0x3f0
 video_usercopy+0x418/0x9ac
 video_ioctl2+0x18/0x24
 v4l2_ioctl+0x4c/0x5c
 __arm64_sys_ioctl+0x90/0xc8
 invoke_syscall+0x40/0x104
 el0_svc_common+0xbc/0x168
 do_el0_svc+0x1c/0x28
 el0_svc+0x1c/0x68
 el0t_64_sync_handler+0x68/0xb4
 el0t_64_sync+0x164/0x168

Change-Id: Ic508f9f077333f951f396dc5ca05563238a5797c
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2025-04-15 09:07:15 +00:00
Xu Hongfei
ba50a2503c media: rockchip: fec: set the header offset for FBCE output
Signed-off-by: Xu Hongfei <xuhf@rock-chips.com>
Change-Id: Ib768695f7c75a95ad5779b95349aa34af64268d1
2025-04-15 08:20:30 +00:00
Xu Hongfei
7d79c22357 media: rockchip: fec: add frame timeout info to procfs
Signed-off-by: Xu Hongfei <xuhf@rock-chips.com>
Change-Id: Iafd172580d8ad04ecfc36d6bf361350536975ccb
2025-04-15 08:20:30 +00:00