Commit Graph

1073605 Commits

Author SHA1 Message Date
Zefa Chen
10019a5beb media: i2c: sensor driver remove not necessary check of fmt_code in enum_frame_interval
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: I2bafbe067054c30cd4e61740365a59d9ff839ae4
2023-02-10 19:19:52 +08:00
Elaine Zhang
89d5027fb3 clk: rockchip: rk3588: Fix up the dump information of panic
Just dump the valid register.

Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I82d9ab4d0f97b93b9dcfde5a07fbd4f4afb9ab23
2023-02-10 17:15:30 +08:00
Elaine Zhang
3fb264c4e2 soc: rockchip: power-domain: Fix up the dump information of panic
Just dump the valid register.

Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I3c35530d03463d2a5940862d866668a1f51a283c
2023-02-10 17:15:30 +08:00
Finley Xiao
52c9c71ccb clk: rockchip: rk3562: Remove CRYPTO RNG and KLAD clocks
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I35d432561605227b35a1c3b953bfa6c926b1adb8
2023-02-10 16:27:56 +08:00
YouMin Chen
d508911411 arm64: dts: rockchip: Add rk3562 ddr relate node
Signed-off-by: YouMin Chen <cym@rock-chips.com>
Change-Id: Icd2ba1ef071259e50ff4495fb1b78caf02d82cd9
2023-02-10 14:48:40 +08:00
YouMin Chen
c7cb4c1ef8 PM / devfreq: rockchip_dmc: Add support for rk3562
Signed-off-by: YouMin Chen <cym@rock-chips.com>
Change-Id: I839d731812df29a05f339a0ff5d63bf2056a88f2
2023-02-10 14:28:01 +08:00
YouMin Chen
65a05dcbab dt-bindings: devfreq: rockchip_dmc: Add rk3562 support
Signed-off-by: YouMin Chen <cym@rock-chips.com>
Change-Id: I00e209a30918bc69d43d93306a812e10805fe32c
2023-02-10 14:27:01 +08:00
YouMin Chen
1af50cdeaf PM / devfreq: rockchip-dfi: Add support for rk3562 dfi
Signed-off-by: YouMin Chen <cym@rock-chips.com>
Change-Id: Idf016a7ad082771277e6de6a7412d9a7a8e226eb
2023-02-10 14:26:16 +08:00
YouMin Chen
b46525b951 dt-bindings: devfreq: rockchip_dfi: Add rk3562 support
Signed-off-by: YouMin Chen <cym@rock-chips.com>
Change-Id: Ia10308583f88909a2efeb76922ca635f63d6016e
2023-02-10 14:25:48 +08:00
Finley Xiao
001bea88b9 arm64: dts: rockchip: rk3562: Crypto and rng use scmi clock
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: Ia34b1caf94aaa964c71a303130f81ee0d1f5253f
2023-02-10 14:23:11 +08:00
Finley Xiao
c44d1ff0ab clk: rockchip: rk3562: Add clock ids for secure crypto
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: Ic2614c5ff312e6a2b69b481eb5d794c97e6f711e
2023-02-09 20:48:24 +08:00
Jianqun Xu
408861dc07 Revert "ARM: dts: rockchip: delete gpu 100MHz for rk3288"
This reverts commit 25e9b5b53a.

Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
Change-Id: Ifabc3f04113c0b8ebf054df2cbc58c57d4c3925b
2023-02-09 18:23:26 +08:00
Wangqiang Guo
8abf8eba33 media: rockchip: hdmirx: add aviif_chg_irq.
Use aviif_chg_irq interrupts to monitor scenarios where
the TMDS signal is not disconnected but the resolution,
frame rate, color range or image format changes.

Change-Id: I2f6e3d0d734de1c5a8033b00d3b6b14d1815f6ca
Signed-off-by: Wangqiang Guo <kay.guo@rock-chips.com>
2023-02-09 08:21:13 +00:00
Tao Huang
50ae3938ef dma-buf: Rename CONFIG_DMABUF_DEBUG_ADVANCED to CONFIG_RK_DMABUF_DEBUG_ADVANCED
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I7752359d34e1fb579471d915c2e2039229a2defc
2023-02-09 14:21:20 +08:00
Tao Huang
4f0ec7c431 arm64: configs: Renmae CONFIG_DMABUF_DEBUG to CONFIG_RK_DMABUF_DEBUG
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ie808ed8bd8d47e2fbd5734a20ab979a5c240b2e9
2023-02-09 14:21:20 +08:00
Tao Huang
0513facbab dma-buf: Rename CONFIG_DMABUF_DEBUG to CONFIG_RK_DMABUF_DEBUG
To avoid conflicts with upstream config.

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ib24fc9dbd07604a934de53d3b2402ab747bbcadf
2023-02-09 14:21:20 +08:00
Tao Huang
0a51d4a592 soc: rockchip: io-domain: Sync with upstream
Change-Id: I3aa990729e988f08f384a10606cc2cf26d091b8a
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2023-02-09 14:20:37 +08:00
Tao Huang
d1de5fc48f soc: rockchip: bring all rockchip drivers into a submenu
As the number of Rockchip drivers increase, entries in SoC menu looks
scattered with other SoC drivers. Make a submenu for Rockchip drivers
to make it visibly clear while selecting Rockchip SoC specific drivers.

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ia657e184a32c9b28f6ddd585838890ba5ec814cf
2023-02-09 11:39:29 +08:00
Tao Huang
9cd7abdb02 net: wireless: rockchip_wlan: bcmdhd: No include stdarg.h from 5.15
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: If5a6ca39f8fcdc0854a34049f08f90c636b2044c
2023-02-08 19:45:37 +08:00
Tao Huang
7558c3e935 gpio: rockchip: Sync with upstream
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I49a33907327f3c08d613d9c463cd9abaac8dcd92
2023-02-08 19:32:41 +08:00
Tao Huang
bc249ee6f7 soc: rockchip: power-domain: Sync with upstream
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ice950e43affea12912acf5f96d51c52b0c132bfb
2023-02-08 19:20:52 +08:00
Korneliusz Osmenda
a74fc5b70d BACKPORT: FROMLIST: PCI: sysfs: Guard pci_create_sysfs_dev_files with atomic value
There is a race contition seen in rockchip platform which seems expose a long
existing bug in PCI sysfs code.

1. pci_bus_add_device() called pcibios_bus_add_device() or
pci_fixup_device() but have not called pci_create_sysfs_dev_files() yet.
Meanwhile pci_sysfs_init() is running and pci_create_sysfs_dev_files()
was called for newly registered device. In this case function
pci_create_sysfs_dev_files() is called two times, ones from
pci_bus_add_device() and once from pci_sysfs_init().

2. pci_sysfs_init() is called. It first sets sysfs_initialized to 1
which unblock calling pci_create_sysfs_dev_files(). Then another bus
registers new PCI device and calls pci_bus_add_device() which calls
pci_create_sysfs_dev_files() and registers sysfs files. Function
pci_sysfs_init() continues execution and calls function
pci_create_sysfs_dev_files() also for this newly registered device. So
pci_create_sysfs_dev_files() is again called two times.

The call trace looks like:

[    2.822232] [  T143] sysfs: cannot create duplicate filename '/devices/platform/fe170000.pcie/pci0002:20/0002:20:00.0/0002:21:00.0/config'
[    2.822240] [  T143] CPU: 1 PID: 143 Comm: rk-pcie Not tainted 5.10.66 #56
[    2.822245] [  T143] Hardware name: Telpo RK3588 F206 Board (DT)
[    2.822251] [  T143] Call trace:
[    2.822262] [  T143]  dump_backtrace+0x0/0x1c8
[    2.822269] [  T143]  show_stack+0x1c/0x2c
[    2.822276] [  T143]  dump_stack_lvl+0xdc/0x12c
[    2.822282] [  T143]  dump_stack+0x1c/0x64
[    2.822289] [  T143]  sysfs_warn_dup+0x6c/0x8c
[    2.822296] [  T143]  sysfs_create_bin_file+0xe4/0x130
[    2.822303] [  T143]  pci_create_sysfs_dev_files+0x50/0x210
[    2.822310] [  T143]  pci_bus_add_device+0x30/0xac
[    2.822316] [  T143]  pci_bus_add_devices+0x44/0x88
[    2.822321] [  T143]  pci_bus_add_devices+0x70/0x88
[    2.822327] [  T143]  pci_host_probe+0x78/0xb0
[    2.822335] [  T143]  dw_pcie_host_init+0x308/0x3f8
[    2.822340] [  T143]  rk_pcie_really_probe+0x954/0xe04
[    2.822347] [  T143]  kthread+0x13c/0x344
[    2.822353] [  T143]  ret_from_fork+0x10/0x30

There are continuous reporting about this bug[1] can be found here[1].

The above link leads me to the fix[2]. Upstream kernel has contained the fix:
0ad52e381d85eb86906749e2b8073cdc2265844b ("Convert "config" to static attribute")
However there are still corner bugs around directory create. So Bijorn created
a Bugzilla item[3] for it. After a long time, Korneliusz Osmenda pushed a new
patch to fix it. Then we wait for another long period of time without any update.
IMO, [4] is better than other proposes. So just backport the better fix into vendor
tree.

[1] https: //lore.kernel.org/all/m3eebg9puj.fsf@t19.piap.pl/
[2] https: //patchwork.kernel.org/project/linux-pci/patch/20210416205856.3234481-2-kw@linux.com/
[3] Bug: https://bugzilla.kernel.org/show_bug.cgi?id=215515
[4] https: //patchwork.kernel.org/project/linux-pci/patch/4469eba2-188b-aab7-07d1-5c77313fc42f@gmail.com/
Signed-off-by: Korneliusz Osmenda <korneliuszo@gmail.com>
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
[Shawn: backport and reword to explain what happened]
Change-Id: Ib0a54bc2204afa7d9136e8d3156b00ec6aa4d8b3
(cherry-picked from https: //patchwork.kernel.org/project/linux-pci/patch/4469eba2-188b-aab7-07d1-5c77313fc42f@gmail.com/)
2023-02-08 18:48:36 +08:00
Jianqun Xu
9c22724d16 ARM: dts: rockchip: default to disable the rga for rk3288
Set the rga node to be "disabled" defaultly for rk3288.

Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
Change-Id: Idccb5dfd79e7bfd5005307f5fba576df1ff03a0d
2023-02-08 18:47:07 +08:00
Jianqun Xu
bb15bb91c3 Revert "ARM: dts: rockchip: rk3288: Fix reg size for ehci"
This reverts commit 0fce242c01.

Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
Change-Id: I34edb1a073fb977bcd78300fc14ac5d0040d3de6
2023-02-08 18:46:48 +08:00
Jianqun Xu
c8436595e4 ARM: dts: rockchip: rk3288 fix thermal node name to 'soc-thermal'
Fixes: 043ddfca3f ("ARM: dts: rockchip: rk3288: add operating-points-v2 for cpu nodes")

The pvtm driver will find a thermal by name of the thermal node.

This patch fixes a issue as following:
[    5.215126] cpu cpu0: failed to read out thermal zone (-22)
[    5.221562] thermal thermal_zone1: binding zone cpu_thermal with cdev thermal-cpufreq-0 failed:-17

Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
Change-Id: I475e4035ab797f9d374feaddce8fda68af0d522c
2023-02-08 18:44:56 +08:00
Frank Wang
9cce7d5ac8 phy: rockchip: inno-usb2: fix incorrect perip_connected
The U2PHY sent "peripheral connected" extcon message to DWC3 even if
there is no USB cable pluuged when the otg_sm_work is scheduled first
time, this would be resumed DWC3 unexpectedly and cause the DWC3 gadget
to incorrect state. So initialize the perip_connected to false before
send the extcon message to fix it.

This can fix the ADB can not be enumerated when plug the USB cable
in the first time after the system boot up and the below messages
may find in the Kernel log on RK3562-EVB2 board.

[    7.218101] read descriptors
[    7.218191] read strings
[    7.306784] dwc3 fe500000.usb: failed to enable ep0out

Fixes: 00168bb5b5 ("phy: rockchip: inno-usb2: fix otg port with vbus always on")
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Change-Id: I90209f15605d16ca746dd6c44fbaf6d9c1684eaa
2023-02-08 18:04:08 +08:00
Tao Huang
5e0fa7cfef pinctrl/rockchip: Sync with upstream
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I752b6433b1682930eb0e080759334a5a876a5d23
2023-02-08 17:33:34 +08:00
Sugar Zhang
c1770bf251 ASoC: rockchip: sai: Handle HCLK with runtime PM
This patch handle HCLK with runtime PM to save a little
bit of power consumption.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I4ab16fd21d592245a0d0eb2240740f0a90403f0a
2023-02-08 16:38:09 +08:00
Guochun Huang
b6de31a022 phy/rockchip: inno-dsidphy: add support px30s
Change-Id: I275d589f56e5963649aee9397eba3a9994e5901d
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
2023-02-08 16:17:22 +08:00
Guochun Huang
81dbadea25 arm64: dts: rockchip: rk3562-evb: enable dsi display logo
Change-Id: I52d558e9f3d2a857acd461f67bc11152acd0f27e
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
2023-02-08 16:11:49 +08:00
Guochun Huang
411e86fa31 arm64: dts: rockchip: rk3562-android/linux: move display route to innermost dtsi
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
Change-Id: Ibb68db2daab5ded86019a607efde554250d0559b
2023-02-08 16:11:29 +08:00
Guochun Huang
b21ba4394d arm64: dts: rockchip: rk3562: move display route to innermost dtsi
Change-Id: I34471e644d6a2e070cc031e7699489c6fc8632d4
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
2023-02-08 16:11:15 +08:00
Jason Zhu
12609f9226 arm64: dts: rockchip: rk3562-iotest: support rk dsm sound
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: I25ad0e77f03a69ae19e085a20d5cb5ccdee78af4
2023-02-08 16:05:16 +08:00
Jason Zhu
22c0fc4c7d arm64: dts: rockchip: rk3562: change the dsm info
Change the IP name according to the TRM. Delete unused info  and
correct the grf base address.

Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: Ic562db95e504372ace137eaebb679697230a0a6c
2023-02-08 16:05:09 +08:00
Jason Zhu
1d55fcb01f arm64: configs: rockchip_gki: enable CONFIG_SND_SOC_RK_DSM
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: I586e7cd2c142b0b6245039a5177676b765afa1ca
2023-02-08 16:00:39 +08:00
Jason Zhu
a8617a2870 arm64: rockchip_linux_defconfig: enable CONFIG_SND_SOC_RK_DSM
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: Id95110bd1b6a95c89f82432e352fd538303b0896
2023-02-08 15:58:15 +08:00
Jason Zhu
52dfec02ca arm64: configs: rockchip_defconfig: enable CONFIG_SND_SOC_RK_DSM
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: I6e69cd59e64af922ee8608fbbd9454fcf3960e0a
2023-02-08 15:54:03 +08:00
Jason Zhu
a0881c07c2 ASoC: codecs: support rk dsm
Support rockchip Delta-sigma Digital Converter. And
it only has DAC which is a reduced version of rk_codec_digital.

Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: I0444ac99b12ed4d8cfb6df4034392dbd844e2bca
2023-02-08 15:53:10 +08:00
Steven Liu
c115ee06bc arm64: dts: rockchip: rk3562-amp: add rpmsg node
Signed-off-by: Steven Liu <steven.liu@rock-chips.com>
Change-Id: I4a1b1842414042c91a3365161f3baea236f7dc7d
2023-02-08 14:58:28 +08:00
Steven Liu
f8652ea55e rpmsg: rockchip: add rk3562 support
Signed-off-by: Steven Liu <steven.liu@rock-chips.com>
Change-Id: I99b0f06ea787376fe0e2c1098d3d193e2a19859b
2023-02-08 11:51:59 +08:00
David Wu
7c9551becd BACKPORT: iio: adc: rockchip_saradc: add voltage notifier so get referenced voltage once at probe
Add voltage notifier, no need to query regulator voltage for
every saradc read, just get regulator voltage once at probe.

Signed-off-by: David Wu <david.wu@rock-chips.com>
Signed-off-by: Simon Xue <xxm@rock-chips.com>
Reviewed-by: Heiko Stuebner <heiko@sntech.de>
Link: https://lore.kernel.org/r/20210810011007.54066-1-xxm@rock-chips.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
(cherry picked from commit cabd6e9cf2)
Change-Id: I5723398bac6e1349b60f36c0088a49884f0106bb
2023-02-08 09:52:11 +08:00
Finley Xiao
25a24f5d20 clk: rockchip: rk3562: Remove CLK_IGNORE_UNUSED for pclk_intc
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I211d7d8680f73438818b712bc274b51a2c445038
2023-02-08 09:10:12 +08:00
Tao Huang
40b4843899 spi: rockchip: Sync with upstream
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ia25e81a1ac5dca491ff31bd3557eac61bbd0962e
2023-02-07 20:30:52 +08:00
Finley Xiao
721af6e079 arm64: dts: rockchip: rk3562-rk817-tablet-v10: Enable tsadc
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I07edce95737941f071e108e12db2fde6cc05bf3e
2023-02-07 20:27:20 +08:00
Tao Huang
479b4d6851 arm64: dts: rockchip: pinconf: Sync with upstream
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I7cd9c2d2c61ce008efef6781eb59bcaaf7e0164d
2023-02-07 19:59:57 +08:00
Tao Huang
72baf7945d arm64: dts: rockchip: rk3308: Sync with upstream
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I632c4ff0b86275d3d11969377185d48c64dec76c
2023-02-07 19:48:02 +08:00
Wyon Bi
717debc7f2 drm/rockchip: vop2: Use devm_clk_get_optional() in vop2_extend_clk_init()
Silence warning print if didn't have a clock reference in the DT.

Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
Change-Id: I1e6276950e6e582a424daec5b46e51d08d5fe05a
2023-02-07 17:25:59 +08:00
Cai YiWei
c38ee7a65d media: rockchip: isp: version v2.1.0
Change-Id: Ie02dfdad44f9f67a765fe577b609346552a35a59
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2023-02-07 17:14:31 +08:00
Cai YiWei
9f908ad29d media: rockchip: isp: stats buf add application params frame id
Change-Id: Ib343caba3c4e378661d83f0485a9e0a2940367f3
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2023-02-07 17:14:31 +08:00
Jianlong Wang
d6c491185e arm64: configs: px30_linux_defconfig: enable CONFIG_PSTORE
Signed-off-by: Jianlong Wang <jianlong.wang@rock-chips.com>
Change-Id: I00d69aefef747372dcbb42d85638db6189646f05
2023-02-07 17:11:12 +08:00