Commit Graph

1072996 Commits

Author SHA1 Message Date
Wang Xiaobin
e2bf2eaab8 ARM: dts: rockchip: rv1103g-rmsl311: remove meta node and use erofs
The layout about meta has been changed and defined in
rv1106-thunder-boot.dtsi.

Signed-off-by: Wang Xiaobin <xb.wang@rock-chips.com>
Change-Id: Ia05c9020dd52b5c6a0e9c94b1e7d799fd65d9d76
2022-10-10 14:20:22 +08:00
Wyon Bi
50bc70c3f6 drm/bridge: analogix_dp: Fix stream valid control
Add DT property 'analogix,force-stream-valid' to DTS node
if want to support vrr.

Fixes: 2abd3af02c ("drm/bridge: analogix_dp: Use video format information from register")
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
Change-Id: Ic4624e4ca3a03322f1d9520a7e3cee0d054c36ee
2022-10-10 11:01:14 +08:00
Zefa Chen
6ab995ba97 media: i2c: SmartSens sensor driver fixed modify fps error
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: Idd09bfac19006e47340660f3f7c0c774240caf42
2022-10-10 11:00:57 +08:00
Jon Lin
a366f684c2 arm64: dts: rockchip: rk3588s: Fix spi driver strength
Except spi2m2 which is used for pmic. all spi change from 33ohm to 40ohm
to avoid overcharge.

Change-Id: Ib1f613b19c1ca9f978c11a7d26422ff66b4b910c
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-10-10 10:56:32 +08:00
Cai YiWei
a34aa766dc media: rockchip: isp: fix scl for unite mode
Change-Id: Ic224cfa5956ed1dea523e608ceed46be0c2dd49c
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2022-10-10 10:07:59 +08:00
Wyon Bi
beaac7714a drm/bridge: analogix_dp: Check link status in loader_protect()
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
Change-Id: I8816a0527eb7a1c1d3a2d7b7480057b888e375e0
2022-10-10 09:00:55 +08:00
Wyon Bi
379474682f drm/rockchip: Add return value to .loader_protect()
Callback loader_protect() maybe failed.

Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
Change-Id: Icb9a25701929c79b94c9a63568a408913e49f87c
2022-10-10 09:00:55 +08:00
Liang Chen
bc2d913a39 soc: rockchip: opp_select: dump current opp state when panic for cpu/ddr
panic log:
cpu cpu6: cur_freq: 1008000000 Hz, volt_vdd: 675000 uV, volt_mem: 675000 uV
cpu cpu4: cur_freq: 408000000 Hz, volt_vdd: 675000 uV, volt_mem: 675000 uV
cpu cpu0: cur_freq: 816000000 Hz, volt_vdd: 675000 uV, volt_mem: 675000 uV
rockchip-dmc dmc: cur_freq: 528000000 Hz, volt_vdd: 675000 uV, volt_mem: 700000 uV

Change-Id: I29ea94cc9deaba0e1d285390312256567708d6ef
Signed-off-by: Liang Chen <cl@rock-chips.com>
2022-10-09 19:53:52 +08:00
David Wu
fda1cfae99 ARM: dts: rockchip: rk3288-evb: Change rgmii clock mode from input to output for gmac
Signed-off-by: David Wu <david.wu@rock-chips.com>
Change-Id: Ia73346adb607744bd037c7b255ba1647678ad77c
2022-10-09 19:43:05 +08:00
Jon Lin
e3354602f7 spi: rockchip: Support rkspi-devN misc devices
Reach controller register in user space by mmap operation, And only do spi
transmission in user space.

Change-Id: I37e22ad04813c2cd10d97324339afc5a11da59bd
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-10-09 19:33:54 +08:00
Jon Lin
77a650e3d0 mtd: spinand: foresee: Support new device
F35SQA512M, F35UQA512M

Change-Id: Ica5e7e1bafd481d7b5c883fd9ab75b8f9599e003
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-10-09 19:30:47 +08:00
Zefa Chen
266443eda9 media: i2c: sc200ai support get config from cmdline for thunderboot
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: I34f1339ebf033122663f0f24cf5b4725948b258e
2022-10-09 17:45:24 +08:00
Cai YiWei
4037c8a769 media: rockchip: isp: drop first output for fast case
Change-Id: I7e303b6307032187a70b5558f2a78ccd6b8f3ca5
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2022-10-09 11:20:42 +08:00
Chen Shunqing
aa33064d9b drm/bridge: dw-hdmi-qp-cec: fix receive message error
Signed-off-by: Chen Shunqing <csq@rock-chips.com>
Change-Id: I741c45dceca7efba896c8892e1ac790b4dffc4e5
2022-10-08 16:16:10 +08:00
Jianwei Fan
9a94f8e080 media: i2c: ov13855: fix power on sequence to avoid i2c communication failed
Signed-off-by: Jianwei Fan <jianwei.fan@rock-chips.com>
Change-Id: I8534e9512cc94bd1af30fa213653d0024900e7e2
2022-10-08 11:07:12 +08:00
Yu Qiaowei
482424b9aa video: rockchip: rga3: support rga2_iommu
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: Ic4d4ad1e4cd6490aa487b272003130eb0504219f
2022-10-08 11:06:52 +08:00
Jianqun Xu
8d29486a15 pinctrl/rockchip: fix rk3308 pinmux error
The GPIO2A2 GPIO2A3 GPIO2C0 GPIO3B2 GPIO3B3 have 3 bits for pinmux, and
have a extra bit to select 2bits or 3bits.

The Rockchip downstream has a soc_data_init to choice 3bits mode, but
the upstream uses 2bits mode.

This patch removes the soc_data_init/re_init and set the soc data init
directly during probe.

Fixes: ae7b9050a3 ("UPSTREAM: pinctrl: rockchip: fix RK3308 pinmux bits")

Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
Change-Id: I57b88c776f86a37e34a38cd7b81e422e0cce2e03
2022-10-08 10:53:23 +08:00
Jianwei Fan
e08caf351a media: i2c: lt7911uxc: add 5K60 support for CPHY
Signed-off-by: Jianwei Fan <jianwei.fan@rock-chips.com>
Change-Id: I223f4e8e87266c4b75d201f4b23e853cfca05964
2022-10-01 16:43:46 +08:00
Elaine Zhang
af14a79ae3 clk: rockchip: rk3588: support aclk_vop_sub_src set parent to aclk_vop_div2_src
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: If493c3918bd8022accf089d69cce4cb93326d9e5
2022-09-30 16:29:15 +08:00
Xing Zheng
98ec188833 ASoC: codecs: rv1106_codec: To clarify the steps of enabling ADC
Signed-off-by: Xing Zheng <zhengxing@rock-chips.com>
Change-Id: I66921b120dc2a7d197c984369ecb261b50d037a0
2022-09-30 16:20:02 +08:00
Zefa Chen
f6886f6606 media: i2c: sc200ai change short exposure max to 404 half-line (3ms)
Change-Id: I3149273398b5fe4e66e90f74a883234d8531f4e7
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
2022-09-30 16:12:56 +08:00
Xu Hongfei
d711b7f541 media: rockchip: isp: remove the judgment that gain turn off if ldch is enabled
Signed-off-by: Xu Hongfei <xuhf@rock-chips.com>
Change-Id: I3dd7679f7052a6c0c76a41b9466a8235053afd5b
2022-09-30 16:07:41 +08:00
Elaine Zhang
c282cc82a1 arm64: dts: rockchip: rk3568: Fixed compatible for the CAN node
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I19b64e7c7fd1a663d3a41479a66cf95eb6ff3f05
2022-09-30 14:45:07 +08:00
Elaine Zhang
aed0776380 net: can: rockchip: canfd: Support extended frames transmit for rk3568
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I097fd66d34b56d9e6104f21da40e5b41bf2b4109
2022-09-30 14:45:07 +08:00
Zefa Chen
ce59362f58 media: rockchip: vicap fixed sof error for rv1126/rk356x in HDR mode
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: I78dd84b17ebbbcde166b3557a80bcfb132065c23
2022-09-30 14:43:57 +08:00
Jon Lin
fa919e9611 pcie: rockchip: dw: Support dmatest
Change-Id: I14bd31839bfb3fe70d8b12b7e3e6efca535028a1
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-09-30 14:43:41 +08:00
Jon Lin
533492f3b5 PCI: rockchip: dw: Add dmatest
Test code of embedded DMA design based on dwc controller.

Show the controller registered with dmatest, and you can assigned the
correspond test_dev for test:
	echo show > ./sys/module/pcie_dw_dmatest/parameters/dmatest

Check the value of the current parameter:
	grep -H . /sys/module/pcie_dw_dmatest/parameters/*

Fix parameter and run the dmatest:
	echo 0 > ./sys/module/pcie_dw_dmatest/parameters/test_dev
	echo 1 > ./sys/module/pcie_dw_dmatest/parameters/chn_en
	echo 1 > ./sys/module/pcie_dw_dmatest/parameters/rw_test
	echo 0x100 > ./sys/module/pcie_dw_dmatest/parameters/size
	echo 0x1 > ./sys/module/pcie_dw_dmatest/parameters/cycles_count
	echo 0x3c000000 > ./sys/module/pcie_dw_dmatest/parameters/local_addr
	echo 0x3c000000 > ./sys/module/pcie_dw_dmatest/parameters/bus_addr
	echo run > ./sys/module/pcie_dw_dmatest/parameters/dmatest

Change-Id: I1b48f849e5e37baec27bc62d2a8cf4945fb40cbc
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-09-30 14:43:41 +08:00
Jon Lin
73635093a1 pcie-dma-trx: update to version 0x4
1.Optimize DMA hook to support multiple independent DMA channels
2.Add interrupt callback to support multiple independent DMA channels

Change-Id: I42a638a4cb9fa61ebc1cd51d4e9f6d6942715fd1
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-09-30 14:43:41 +08:00
Liang Chen
0d01ed0d12 arm64: dts: rockchip: rk3588: set pcfg_pull_up for touch int pin
This patch can save 0.6mA for PMUIO2(3V3).
Tested on RK3588_EVB1_LP4_V10 platform.

Change-Id: If9298b7de5859e8bfd28baf3e1022b71efd78218
Signed-off-by: Liang Chen <cl@rock-chips.com>
2022-09-30 10:33:55 +08:00
Andy Yan
d8b6c8e1f7 drm/rockchip: delay destroy logo fb
Some NVR product want skip-ref-fb, destroy logo
fb after some delay to make sure the plane is
disabled.

Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Change-Id: Ia257a510ea2382b5ee6aa4f65b2fef856687b0bc
2022-09-30 09:25:57 +08:00
ZiHan Huang
fefa0e0325 arm64: dts: rockchip: rk3588-evb1-lp4-v10-ipc-6x-linux.dts: open hdmi0 node
Signed-off-by: ZiHan Huang <zack.huang@rock-chips.com>
Change-Id: I00e2bbd7404b4474a061907cb41bd757223ce0f8
2022-09-29 19:55:24 +08:00
Sandy Huang
48db713cf4 drm/rockchip: vop2: fix win disable failed
Before this commit the following scenario maybe disable win failed:
-> disable win and config done
-> vop fs coming, this time win state is disabled.
-> enable win and config done
-> disable win[the fs haven't come yes, so win state is disabled, this will
skip to disable win and lead to disable win failed]
->fs coming, this time win state is still enabled.

so we add judge win backup register state to avoid disable win failed.

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: Ie08aa141616291fc900313d99fbc07622b5d1a83
2022-09-29 19:51:39 +08:00
Zefa Chen
fb8b382053 media: rockchip: vicap fixed bug for hdr online mode to capture raw
1. fixed bug caysed by commit 75dc121c3a

2. enable dma capture in fs intr, otherwise,
 if enable during vblank will cause VICAP to use the buffer address of last runtime,
 but the buffer is released.

Fixes: 75dc121c3a ("media: rockchip: vicap support wake up buffer with mode of rdbk by isp driver")
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: I51d6e0aaf513dc1e5039980e7643faa7505c271b
2022-09-29 19:43:44 +08:00
Zefa Chen
9b0a2023cc media: rockchip: vicap: thunderboot support HDR mode
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: I85c29687c6bdcfd3adfab9d2de14097a2721433b
2022-09-29 19:43:44 +08:00
Su Yuefu
a868b3f46b media: i2c: updata sc200ai hdr config
Signed-off-by: Su Yuefu <yuefu.su@rock-chips.com>
Change-Id: I028b796c20c17ad8ca1bdb2b1d2ed189106cd06c
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
2022-09-29 17:49:44 +08:00
Su Yuefu
b6601c35fd media: i2c: sc200ai support fastboot
Signed-off-by: Su Yuefu <yuefu.su@rock-chips.com>
Change-Id: I521c53b826c485231aa4c59b310a0352d6cdf428
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
2022-09-29 17:49:15 +08:00
Jon Lin
c39732fb25 mtd: spinand: macronix: Support new devices
MX35UF1GE4AC, MX35UF1GE4AD, MX35UF2GE4AD, MX35UF4GE4AD

Change-Id: Ief8230ac8d37ad28d3253a9bec8786506698c8c3
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-09-29 15:41:17 +08:00
Wangqiang Guo
6feda272d3 media: rockchip: hdmirx: fix some source ced err.
The boundary of different frequency points is set as the default value
to avoid CED interruption being triggered by mistake.

Signed-off-by: Wangqiang Guo <kay.guo@rock-chips.com>
Change-Id: I0b1257586d43e335496e87803628da72bc2a7c0c
2022-09-29 14:57:57 +08:00
Yu Qiaowei
78b085b196 video: rockchip: rga3: rga_image_size_cal supports YUV422 10bit
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: I042a85cc427df7ccd9473c3b49f9d2294160fe67
2022-09-29 14:52:12 +08:00
Jason Zhu
b4dff81bd7 ASoC: rockchip: vad: update cpudai process
The process is "startup->prepare->trigger".

Others, fix the pdm + vad do not work well since use the patch:
'commit 3437162327 ("ASoC: rockchip: pdm: Fix pop noise in the beginning")'

Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: Ifdc40af04695f4082d536b83309c76ed0426fece
2022-09-29 14:41:04 +08:00
Andy Yan
a927626fae drm/rockchip: vop2: Restore lut after VP exit standby
vop2_crtc_load_lut need to sync with vysnc, so we should
make sure the VP exit standby and setting the right dclk,
or we will meet a cfg done timeout:

[drm:vop2_wait_for_fs_by_done_bit_status] *ERROR* wait vp1 done bit
status timeout, vcnt: 0

Fixes: 5aa1d0e08f ("drm/rockchip: vop2: fix double config done at one
frame time")

Change-Id: I66d1e7ba260dc376c7f7ce132dad2212649b31e8
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
2022-09-29 14:40:21 +08:00
Shaohan Yao
b5386fc767 arm64: dts: rockchip: rk3588-evb: Enable pwm fan
Signed-off-by: Shaohan Yao <shaohan.yao@rock-chips.com>
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I5413438ed4d94e358c4ad0826371520cf78e037e
Signed-off-by: Wu Liangqing <wlq@rock-chips.com>
2022-09-29 14:17:20 +08:00
Shaohan Yao
ab64dbf5f0 hwmon: (pwm-fan) Add system monitor notifier
Add support to change fan speed according to temperature,
and force to update pwm state when suspend and resume as
the configuration of pwm is lost.

Signed-off-by: Shaohan Yao <shaohan.yao@rock-chips.com>
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I05b286d1373dd4ace2fb519f4598008b851e4eff
2022-09-29 14:16:27 +08:00
Tao Huang
4f1d178da1 soc: rockchip: rockchip_system_monitor: use IS_REACHABLE instead of IS_ENABLED
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I1726278ab44f17bb204d0c57758952f5f3896d76
2022-09-29 10:02:27 +08:00
Shaohan Yao
cf0e68c8b4 soc: rockchip: rockchip_system_monitor: Add temperature notifier
Signed-off-by: Shaohan Yao <shaohan.yao@rock-chips.com>
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I8152d13f09f9e4f38a1d402ca32ae1e7f4a8585c
2022-09-29 09:38:27 +08:00
Tao Huang
217d03411d power: reset: reboot-mode: Don't miss panic reboot mode
pre_restart will rewrite reboot mode with normal mode when panic.

Fixes: c0b196cd5b ("power: reset: reboot-mode: Register callback for kernel pre restart")
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I8ad03b8f699b9c1a544a46bbdb60d118381d8356
2022-09-29 09:35:41 +08:00
Sugar Zhang
112acab47d ASoC: dmaengine: Fix NULL pointer reference
Unable to handle kernel NULL pointer dereference at virtual address 0000000000000080
Internal error: Oops: 96000005 [#1] PREEMPT SMP
Modules linked in: bcmdhd dhd_static_buf r8168
CPU: 0 PID: 0 Comm: swapper/0 Not tainted 5.10.110 #470
Hardware name: Rockchip RK3588 EVB1 LP4 V10 Board (DT)
pstate: 20400009 (nzCv daif +PAN -UAO -TCO BTYPE=--)
pc : dmaengine_pcm_dma_complete+0x44/0xdc
lr : pl330_tasklet+0xd4/0x2d0
sp : ffffffc01249bdf0
x29: ffffffc01249bdf0 x28: 0000000000000000
x27: ffffff8102c8c608 x26: 0000000000000002
x25: ffffff8102c8c608 x24: ffffff8102d4c600
x23: ffffff81018868c0 x22: ffffff8102c8c618
x21: 0000000000000000 x20: ffffffc010f238ec
x19: ffffff8102c8c560 x18: ffffffc012491048
x17: 0000000000000000 x16: 0000000000000000
x15: 0000000000000000 x14: 000000000007fcc4
x13: 0000000000000004 x12: 0000000a7e22d2ff
x11: 0000000000004007 x10: 0000000000000000
x9 : 0000000000003000 x8 : ffffff8030b7d480
x7 : 000000b2b5593519 x6 : 00000000003033ff
x5 : 0000000000000000 x4 : 0000000000bb82b6
x3 : ffffff8102c90b28 x2 : 0000000000000001
x1 : 0000000000000000 x0 : ffffff8102d4c600
Call trace:
 dmaengine_pcm_dma_complete+0x44/0xdc
 pl330_tasklet+0xd4/0x2d0
 tasklet_action_common+0x11c/0x414
 tasklet_action+0x28/0x38
 _stext+0x108/0x408
 __irq_exit_rcu+0xc0/0xc4
 irq_exit+0x14/0x28
 __handle_domain_irq+0x84/0xd0
 gic_handle_irq+0x78/0x154
 el1_irq+0xe4/0x1c0
 cpuidle_enter_state+0x200/0x3b8
 cpuidle_enter+0x3c/0x58
 cpuidle_idle_call+0x158/0x238
 do_idle+0xac/0xfc
 cpu_startup_entry+0x28/0x2c
 rest_init+0xd8/0xec
 arch_call_rest_init+0x14/0x24
 start_kernel+0x3d8/0x500

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: Ib3d3ac842d3cd249c8cc6f516178031400dbc307
2022-09-29 09:34:51 +08:00
Sugar Zhang
f3fe5ad04b ASoC: rockchip: i2s-tdm: Workaround for Skyworth 8K TVs' Playback
Bring back CLK ASAP after cfg changed to make SINK devices active
on HDMI-PATH-ALWAYS-ON situation, this workaround for some TVs no
sound issue. at the moment, it's 8K@60Hz display situation.

On HDMI-PATH-ALWAYS-ON situation, we almost keep XFER always on,
so, for new data start, suggested to STOP-CLEAR-START to make sure
data aligned.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I56f97d7246cf790ea33a7410eff418baeeecc6d0
2022-09-29 09:31:06 +08:00
Jianqun Xu
bc8ef86861 mm/page_isolation.c: dump page owner if fail to isolate
CMA alloc may failure due to page busy caused by isolated failure,
it's helpful to dump page owner stack for debug.

To use this debug, there should enable PAGE_OWNER debug first by
- CONFIG_PAGE_OWNER=y
- add “page_owner=on” to boot cmdline

then it will shows as following:
 page allocated via order 0, migratetype Movable, gfp_mask 0x6212ca(GFP_HIGHUSER_MOVABLE|__GFP_NOWARN|__GFP_NORETRY)
  get_page_from_freelist+0x1404/0x1920
  __alloc_pages_nodemask+0xf4/0xe90
  __do_page_cache_readahead+0x104/0x1f0
  filemap_fault+0x3d4/0x618
  ext4_filemap_fault+0x30/0x50
  __do_fault+0x50/0x118
  __handle_mm_fault+0x7e4/0xb40
  handle_mm_fault+0xcc/0x1a0
  do_page_fault+0x1f0/0x4a8
  do_translation_fault+0x5c/0x64
  do_mem_abort+0x54/0xf8
  el0_da+0x1c/0x20

Change-Id: I94b02a7c4ce9174f8151e0979e18adba4011c1d2
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2022-09-28 18:10:02 +08:00
William Wu
f537dfe383 USB: quirks: add quirk auto suspend for Sonix webcam
The Sonix webcam (idVendor=0x0c45,idProduct=0x636a)
can't support auto-suspend well on rockchip platforms.
With auto-suspend, the usb mic of the webcam fail to
start capture. So we need to disable auto-suspend for
this Sonix webcam.

Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: Icc59c4fe1fda78be73441dc4320d6d738d031efd
2022-09-28 16:34:26 +08:00