Commit Graph

1080871 Commits

Author SHA1 Message Date
Yu Qiaowei
59b58f06c5 video: rockchip: rga3: refining time-consuming logs
1. Add map/unmap time-consuming
2. Use more intuitive log printing

Change-Id: Id70bc4cce42bb33580ceaf18220fe2454481e78d
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
2023-11-07 17:40:44 +08:00
Yu Qiaowei
0011fa588c video: rockchip: rga3: destroy internal_buffer when user exits
When a user imports the same buffer from multiple threads, relying only
on put to reduce the reference count after the process exits will lead
to memory leaks.

Change-Id: I22e48eb89d23d0d1bc3066048235f1d58ba93511
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
2023-11-07 17:39:57 +08:00
Yu Qiaowei
08092751f1 video: rockchip: rga3: signaled fecne after request commit failed
Change-Id: I32b35bece1b20aa3228d6d4107b0dad1f4ce6c22
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
2023-11-07 17:39:57 +08:00
Wen Zhiwei
d85f16835d UPSTREAM: mmc: dw_mmc: Fix potential null pointer risk
we previously assumed 'host->slot' could be null,
null pointer judgment should be added

Signed-off-by: Wen Zhiwei <wenzhiwei@kylinos.cn>
Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
Link: https://lore.kernel.org/r/20211229023814.53372-1-wenzhiwei@kylinos.cn
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Yifeng Zhao <zyf@rock-chips.com>
(cherry picked from commit 4a835afd80)
Change-Id: Iffade4e1d3ab6ad5bde7b6f05aaf3ce03ba28922
2023-11-07 17:09:44 +08:00
Guochun Huang
16239e4037 drm/rockchip: rk628: vrefresh should not be zero
Change-Id: Ia9bde450208f72aa8f9d5dd77b6086abc715bd5e
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
2023-11-07 16:54:13 +08:00
Guochun Huang
c15b005b73 phy/rockchip: inno-dsidphy: fref and _prediv should not be zero
Change-Id: I51bcc4ca83e176d2c3de82b7dadabd3a409d16b7
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
2023-11-07 16:54:13 +08:00
Guochun Huang
ec130295af drm/rockchip: dsi2: sys_clk and pixel_clk should not be zero
Change-Id: I8a92a1d12093b3562566349707c7ee0308e7d01c
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
2023-11-07 16:54:13 +08:00
Guochun Huang
f16cdb0b9b drm/rockchip: dsi: the bpp should not be zero
Change-Id: I41d4ec692475014951beb3295e912995a2b17d16
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
2023-11-07 16:54:13 +08:00
Cai YiWei
097fce7074 media: rockchip: isp: fix build warning
Change-Id: I44ce213cf48379e496cf47906bcad2cef685b93d
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2023-11-07 16:47:57 +08:00
Huibin Hong
d7c2994c9b soc: rockchip: rk_dmabuf_procfs: check return value of platform_device_register_full()
Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
Change-Id: I2d6b83fd4eba02c587b9af52aa91e6b92618085a
2023-11-07 14:46:12 +08:00
Cai Wenzhong
2182c42cb8 media: i2c: add Maxim Dual GMSL2/GMSL1 to CSI-2 Deserializer driver.
1. maxim deserializer support: max96716/max96718
1.1 local maxim deserlializer depend on CONFIG_VIDEO_DES_MAXIM2C

2. maxim serializer support: max9295/max96715/max96717
2.1 remote max9295 serializer depend on CONFIG_MAXIM2C_SER_MAX9295
2.2 remote max96715 serializer depend on CONFIG_MAXIM2C_SER_MAX96715
2.3 remote max96717 serializer depend on CONFIG_MAXIM2C_SER_MAX96717

Signed-off-by: Cai Wenzhong <cwz@rock-chips.com>
Change-Id: Iff158e3a05927c8e3d2c17e4aa04bfc0fcc86a37
2023-11-07 11:28:01 +08:00
Weiwen Chen
dbf5c36476 media: i2c: sc200ai: get camera param from cam-tb-setup
Signed-off-by: Weiwen Chen <cww@rock-chips.com>
Change-Id: Ie9aae3722e23f72a5381b64583044c86810c61dc
2023-11-07 09:51:00 +08:00
Elaine Zhang
64ab42efa5 net: can: rockchip: use soft reset for bus off
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I8950b7ee8fa677376600599922aa6c40d1af2d0a
2023-11-06 17:15:22 +08:00
Elaine Zhang
9038fae6bd net: can: rockchip: fix rx stuck and timeout
In some special applications, tx has read data from the fifo, rx to read
the fifo is 0 when there is no need to do timeout waiting.

Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I7f4bc88ace026088228396da96d628bebb9e4b94
2023-11-06 17:15:22 +08:00
Elaine Zhang
e903c65661 net: can: rockchip: support Listen-only mode
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I6b566f3f0834ff01e9cff1c1b7ef3934c2e5ec37
2023-11-06 17:15:22 +08:00
Elaine Zhang
4314dcc88f net: can: rockchip: fix tx error in special application
add wait tx req cmd.
fix warning: "BUG! echo_skb %d is occupied!"
disable space_rx_mode when tx req to fix extended frame probability
change standard frame.

Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I0b11d985224682700f43cb155f357b28622dc4be
2023-11-06 17:15:22 +08:00
Cody Xie
ecd2f7a8a0 arm64: dts: rockchip: rk3588-vehicle-evb-v22: Switch to use standalone NCA9539 driver
Change-Id: Iff456e2bf6644185a164fba601e914f19c86effa
Signed-off-by: Cody Xie <cody.xie@rock-chips.com>
2023-11-06 16:18:00 +08:00
Yandong Lin
d9794ef01e video: rockchip: mpp: fix rkvenc2 run crash issue
Calling an interface containing mutex lock after
schedule_preempt_disabled caused the problem.

Call trace:
 dump_backtrace+0xf4/0x118
 show_stack+0x18/0x24
 dump_stack_lvl+0x60/0x7c
 dump_stack+0x18/0x3c
 __schedule_bug+0x6c/0x8c
 __schedule+0x64c/0x9cc
 schedule+0x7c/0xe8
 schedule_preempt_disabled+0x24/0x40
 __mutex_lock+0x224/0xdac
 __mutex_lock_slowpath+0x14/0x24
 mutex_lock+0x40/0xec
 clk_get_rate+0x50/0x134
 rkvenc_run+0x4ec/0x728 [rk_vcodec]
 mpp_task_worker_default+0x2b4/0x494 [rk_vcodec]
 kthread_worker_fn+0x10c/0x244
 kthread+0x104/0x1d4
 ret_from_fork+0x10/0x20

Fixes: ca7fd65693 ("video: rockchip: mpp: rkvenc2: optimize iommu fault handle")
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: I1bceea441495a1c6c94776a648601d670b7a29d2
2023-11-06 16:16:58 +08:00
YouMin Chen
59cc6c2107 arm64: dts: rockchip: rk3588: dmc add SYS_STATUS_DEEP_SUSPEND
Signed-off-by: YouMin Chen <cym@rock-chips.com>
Change-Id: Ia15fc5ce372aeaaef1a009da20e2759f599988bf
2023-11-06 16:09:59 +08:00
YouMin Chen
8abd0d3f68 PM / devfreq: rockchip_dmc: add support SYS_STATUS_DEEP_SUSPEND
Set the frequency of SYS_STATUS_DEEP_SUSPEND to devfreq->suspend_freq,
which is the device frequency set during deep suspend phase.

Signed-off-by: YouMin Chen <cym@rock-chips.com>
Change-Id: Ic33ded5cc6a17335404ef65dd071e856bdf7e598
2023-11-06 16:09:59 +08:00
Zefa Chen
dbcf24dd4c media: rockchip: isp: support change work mode to online with quick stream
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: Ic44728b9e98cb8d15967f3ebdc94ca3d05f7d0e3
2023-11-06 14:25:38 +08:00
Cody Xie
87742febe2 arm64: dts: rockchip: rk3588-vehicle-s66\*maxim\*: Fix pins default pinctrls
Change-Id: Ide7bc019d2599888ee52bc1d257f5ba5a598631d
Signed-off-by: Cody Xie <cody.xie@rock-chips.com>
2023-11-06 14:23:09 +08:00
Cody Xie
ce8fb3bb30 arm64: dts: rockchip: rk3588-vehicle\*maxim\*: Fix pins default pinctrls
Set all default pins to expected input/output values to
prevent glitch during probe.

Change-Id: I29e882f47b8ab1e4d89e29cc1525187a434cba53
Signed-off-by: Cody Xie <cody.xie@rock-chips.com>
2023-11-06 14:23:09 +08:00
Damon Ding
18df0d10b7 backlight: pwm_bl: fix the state check in power-off
If the default-brightness-level is 0 and related pwm
has been enabled in uboot, the pwm_backlight may not
actually be turned off.

Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
Change-Id: I92c0c363a13040e300dd8aa2d40edcad87fa50d0
2023-11-06 14:21:06 +08:00
Finley Xiao
99f2737534 arm64: dts: rockchip: rk3528: Add low temperature config for opp table
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I7f8813c2508bc1eb024f2e2b327dc298bbe5bcb6
2023-11-06 11:35:20 +08:00
David Wu
6a5f6ee5bf net: phy: rk630: Fixed for reboot && ping issue
Fixes: ee144563a5 ("net: phy: rk630: Enable aps && uaps to save power consumption")
Fixes: b67f47f242 ("net: phy: rk630phy: Add adc performance")

Signed-off-by: David Wu <david.wu@rock-chips.com>
Change-Id: I9519024f839e1648570ea98c77d2c22e58b9bc76
2023-11-06 11:34:25 +08:00
Damon Ding
1dfbd3db7b pwm: rockchip: add debugfs to dump regs
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
Change-Id: I2cef534c3cb9c655258f6fc6e66e696b6293307e
2023-11-03 18:44:23 +08:00
Sandy Huang
fb2ea0c6bc drm/rockchip: vop2: fix NULL point when dump regs or active_regs
when vp0 is disabled, the vop2->vps[0].rockchip_crtc.crtc.state is NULL.

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: I93b3ea4f3ddc6076f2105ebcabf7317627b602a3
2023-11-03 09:09:30 +08:00
Hongming Zou
4334bb68c1 arm64: dts: rockchip: rk3308-amp: support ap rpmsg
Change-Id: I0f50eb6e8a4653f4298c499b29168f0031076c7a
Signed-off-by: Hongming Zou <hongming.zou@rock-chips.com>
2023-11-02 10:32:30 +08:00
Weiwen Chen
2deb8446dd ARM: configs: rockchip: enable CONFIG_PWRSEQ_SIMPLE for rv1106-tb-nofastae.config
Signed-off-by: Weiwen Chen <cww@rock-chips.com>
Change-Id: I67caa4711b664174f0192133d5b6280573b72fc1
2023-11-02 09:52:39 +08:00
Finley Xiao
fbce87553e arm64: dts: rockchip: rk3588s: Add hclk for npu opp table
Change-Id: I19d9c380f9bd1ca3bb0a7385f992df75b060f1c1
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2023-11-01 19:10:08 +08:00
Chaoyi Chen
a4ed886f15 drm/rockchip: lvds: using readable connector name when dual lvds enabled
When we enable Dual LVDS, there will be the following
output in the VOP summary node:

$ cat /sys/kernel/debug/dri/0/summary
...
Video Port1: ACTIVE
    Connector: LVDS-1
...

The connector information here is not clear enough. When Dual LVDS is enabled,
both LVDS-0 and LVDS-1 will be enabled (but we will only expose one connector
to user space for operation, which can shield the underlying differences).

In addition, if only LVDS1 is enabled instead of using Dual LVDS,
"LVDS-1" will also be printed here.

In order to express this information more accurately, we will change
the corresponding connector name to "LVDS-DUAL" when using Dual LVDS:

$ cat /sys/kernel/debug/dri/0/summary
...
Video Port1: ACTIVE
    Connector: LVDS-DUAL
...

Change-Id: I9621338c8bdec4b32772c3558d55b5b426d3ccc4
Signed-off-by: Chaoyi Chen <chaoyi.chen@rock-chips.com>
2023-11-01 19:02:38 +08:00
Hongming Zou
510972e61e rpmsg: rockchip: Add Soft IRQ Mode Support
1. Add a way to trigger soft interrupts for rpmsg communication
soft irq refers to reserved irq in shared peripheral interrupt (SPI).

2. Rename rockchip_rpmsg.c to rockchip_rpmsg_mbox.c.

Change-Id: I8007f4b77ba669073db9074e9c19623c37c27fb6
Signed-off-by: Hongming Zou <hongming.zou@rock-chips.com>
2023-11-01 18:12:01 +08:00
Chaoyi Chen
43dfdb1bc3 arm64: dts: rockchip: rk356x-evb: update claa070wp03xg panel timing
Change-Id: I1b2a7fa60bdd73c2a0016044c219540a396992e1
Signed-off-by: Chaoyi Chen <chaoyi.chen@rock-chips.com>
2023-11-01 17:10:35 +08:00
Weiwen Chen
2578958855 ARM: dts: rockchip: update the map of mmc_idmac for rv1106-tb*_mmc
The mmc_idmac run at the address [512KB ~ (2M - 8KB)] which is SPL's
Stack and Heap.
SPL'mmc_idmac use malloc and Kernel reserve this memory.

Signed-off-by: Weiwen Chen <cww@rock-chips.com>
Change-Id: I267759d6acd1137a19e0e5d534c481b8f579b1ee
2023-11-01 17:10:18 +08:00
Ziyuan Xu
d5ec07e871 ARM: dts: rockchip: add clock refs for rv1106-tb*_mmc
Signed-off-by: Ziyuan Xu <xzy.xu@rock-chips.com>
Change-Id: I1d4a94a3ba522fcb4d9ff44be0d8324a813fd81d
2023-11-01 17:09:40 +08:00
Ziyuan Xu
b908341ad3 soc: rockchip: thunderboot_mmc: enable clk_emmc before accessing
Avoid the *clk_emmc* are disabled by *unused_off* when the ramdisk is
too large.

Signed-off-by: Ziyuan Xu <xzy.xu@rock-chips.com>
Change-Id: I38b6f33ab55fbb65781ee266237382c977848e68
2023-11-01 17:07:49 +08:00
Andy Yan
14fe560ebd drm/rockchip: vop: check for valid sdr2hdr eoth
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Change-Id: I8de0881df1c49f3b7365dbd6b33a716cd746ad98
2023-11-01 11:22:00 +08:00
Andy Yan
3f00c490d3 drm/rockchip: vop2: make sure the bpp is not zero
The bpp should not be a zero value.

Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Change-Id: I1a1f9214087639f63c101d0d5c68ee470c852649
2023-11-01 11:22:00 +08:00
LiuDiMing Lin
4fec67500f ARM: rv1106-evb.config: enable CONFIG VIDEO SC450AI/SC401AI/SC200AI
Signed-off-by: LiuDiMing Lin <fenrir.lin@rock-chips.com>
Change-Id: I8541cd64556eca8f958a4becc43ac22c4253789a
2023-10-31 20:13:33 +08:00
LiuDiMing Lin
6aef36d7b6 ARM: dts: rockchip: rv1106-evb-cam: add sc450ai/sc401ai/sc200ai
Signed-off-by: LiuDiMing Lin <fenrir.lin@rock-chips.com>
Change-Id: I3349cb999e9a204e76ad883e25af85c1762c6866
2023-10-31 20:13:25 +08:00
LiuDiMing Lin
ef1fb629c5 media: i2c: add sc450ai support
Signed-off-by: LiuDiMing Lin <fenrir.lin@rock-chips.com>
Change-Id: Id8e49af4fe64557238a226da6abbb6b80d849a44
2023-10-31 20:13:13 +08:00
Zefa Chen
ccc60a6249 media: rockchip: vicap support to do reset in online mode
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: Ibea46658e5d9a41b4f5685838230321e9b71032e
Signed-off-by: Mingwei Yan <mingwei.yan@rock-chips.com>
2023-10-31 20:11:26 +08:00
Mingwei Yan
5c222a001f media: rockchip: isp support to do reset in online mode
Signed-off-by: Mingwei Yan <mingwei.yan@rock-chips.com>
Change-Id: I32a2aa91258130a69ec09e5743e27f8c85279322
Signed-off-by: Mingwei Yan <mingwei.yan@rock-chips.com>
2023-10-31 20:11:26 +08:00
Sugar Zhang
a86b62fb9b arm64: dts: rockchip: rk3588 boards: Fix bitclock-inversion
simple-audio-card,bitclock-inversion is a boolean property.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I2f69c4fd79b6f2b2cc06d69f720671227901482c
2023-10-31 20:11:04 +08:00
Sugar Zhang
1e839d738b arm64: dts: rockchip: rk356x boards: Fix bitclock-inversion
simple-audio-card,bitclock-inversion is a boolean property.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: Ic8f1028e97a29e0af257a860be9b2022511c7a9a
2023-10-31 20:10:46 +08:00
Sugar Zhang
6131b1b779 arm64: dts: rockchip: rk3528 boards: Fix bitclock-inversion
simple-audio-card,bitclock-inversion is a boolean property.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I019257ca1585bcb0c531589bc8a8205842cff00d
2023-10-31 20:10:24 +08:00
Sugar Zhang
e3f6c3e4c5 arm64: dts: rockchip: rk3399-tve1205g: Fix bitclock-inversion
simple-audio-card,bitclock-inversion is a boolean property.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I7a9d17eebe4b5037f3976a8b70e5bef44d24cdd3
2023-10-31 20:09:18 +08:00
Sugar Zhang
0f41d6c903 arm64: dts: rockchip: rk3326-evb: Fix bitclock-inversion
simple-audio-card,bitclock-inversion is a boolean property.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I141b6edcfbcbdafffed1d29b2b9273ac461e894e
2023-10-31 20:08:48 +08:00
Herman Chen
a1410c65b3 video: rockchip: mpp: Add uapi header
Change-Id: Id419e6a57adaf37371be8757b2435db0cffe7350
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2023-10-31 20:04:37 +08:00