Commit Graph

1064738 Commits

Author SHA1 Message Date
Tao Huang
859368fca9 rk: arm: support build Image.gz and Image.lz4
Same as arm64.

Change-Id: If129d04388414ba4acd252a274431710ed8d985b
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2022-01-11 11:14:47 +08:00
Chen Shunqing
31cc8b8472 power: supply: bq25703a: set low power mode when shutdown
Signed-off-by: Chen Shunqing <csq@rock-chips.com>
Change-Id: I0464d5cf36db9b5687247f4bf3bbbf367dd32894
2022-01-10 19:03:49 +08:00
Algea Cao
9f583cf19c drm/rockchip: dw_hdmi: Reset ddc bus when communication error
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
Change-Id: Ia397abda111f20aabff48ccb18ff6b228754d0e1
2022-01-10 19:02:36 +08:00
Sandy Huang
9373efd7fa drm/rockchip: dw_hdmi: correct dsc enable state
only support rgb/yuv444 + DSC

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: Ieb7cdbcb91cb19483f832af4649a189f793cf229
2022-01-10 19:01:23 +08:00
Sandy Huang
f6c851e872 drm/rockchip: vop2: move dsc config done from vop config done to crtc enable
dsc config done only can by config one time when enable, otherwise will
lead to display splash screen.

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: I242d5a992b4981d2fde1b9cdb8aae6ffe9e39c4d
2022-01-10 18:49:53 +08:00
Finley Xiao
56260814ad clk: rockchip: rk3588: Fix sclk dsu src sel
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: Iec446c279f8200b000ebdf8de5e1ee5fcd7cb1a8
2022-01-10 18:48:22 +08:00
Finley Xiao
5db5a4cf85 clk: rockchip: rk3588: Fix pll rate table for 216MHz and 96MHz
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: I06b086dab6f1a6663804f032ad4a3ea905d4bf23
2022-01-10 18:48:22 +08:00
Algea Cao
0f6af0bdd7 drm/rockchip: dw_hdmi: Add delay to prevent HPD status misjudgments
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
Change-Id: Ibdd2395b4e33996c33bc7eb5134ba06d14f89466
2022-01-10 18:44:06 +08:00
Jianqun Xu
13dbe9c775 drm/rockchip: fix error sg_dma_addr for iommu case
Fixes: e68e6d1a35 ("drm/rockchip: add dmabuf sync partial to dma_buf_ops")

Change-Id: I7499f049243b1c5bfe88793cd141730a90aef180
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2022-01-10 18:44:06 +08:00
Wyon bi
d148a5eec2 phy/rockchip: samsung-hdptx: Update config for SI test
Signed-off-by: Wyon bi <bivvy.bi@rock-chips.com>
Change-Id: I3c4170d6130f914632a61185838a669c50c3d4f4
2022-01-10 18:44:06 +08:00
Simon Xue
b0c33de198 soc: rockchip: sip: support get ddr map information
Change-Id: I3d96443d8cdfbd303d0b2dddaae04d508b2ce5f2
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2022-01-10 18:44:06 +08:00
William Wu
7d2237b0ad phy: rockchip: inno-usb2: support type-c vbus detect
For Type-C interface with PD chip (e.g FUSB302), the vbus-det
pin is always pulled up. So the A-valid and B-valid registers
art not change in this case, however, we still want to check
the usb hotplug in otg_sm_work, so let's check the vbus valid
software control registers which are set in typec_switch ops
(e.g udphy_orien_sw_set() on RK3588 Type-C).

Furthermore, schedule the otg_sm_work immediately after phy
init for charger detection before usb enumeration.

Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: I00d2e3e1094e35e9cb34632a9607b372d593e62a
2022-01-10 18:44:06 +08:00
William Wu
a3baf95262 arm64: dts: rockchip: add typec-vbus-det property for rk3588 boards
Add new property "rockchip,typec-vbus-det" for the RK3588 and
RK3588S boards which support Type-C interface and the vbus det
pin is always pulled up.

Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: I0cc1bc339238f41b0dc05c374fa69bf3daeeb42a
2022-01-10 14:30:34 +08:00
William Wu
cf63c93a2b dt-bindings: phy: rockchip-inno-usb2: add typec-vbus-det property
This patch adds "rockchip,typec-vbus-det" property for
Type-C interface with vbusdet pin always pulled up.

Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: Ib56e107456ad32ae6e1b87aaf530070884b71f84
2022-01-10 14:30:27 +08:00
Alex Zhao
0b819948e4 arm64: dts: rockchip: rk3588 boards: add rockchip,skip-scan-in-resume for pcie wifi
Signed-off-by: Alex Zhao <zzc@rock-chips.com>
Change-Id: I8423da5f963264a815be5b3f22f0e69596ac07e6
2022-01-10 14:12:49 +08:00
Wyon bi
09a8ce68b4 arm64: dts: rockchip: rk3588s-tablet: Add regulator-boot-on property to vcc3v3_lcd_edp regulator
Signed-off-by: Wyon bi <bivvy.bi@rock-chips.com>
Change-Id: Ibc5a9c21e4f53bec2cbf4e00b9b97a434deecf38
2022-01-10 14:09:59 +08:00
Andy Yan
b26c5ead68 drm/rockchip: vop2: Fix internal power domain on/off status check when memory bisr enabled
When query vop internal power domain on/off
status from PMU BISR_STS3, 1 is for power up,
0 is for power down, this is different from
the pd status in vop.

Fixes: edf7edcdee29("drm/rockchip: vop2: Check PMU_BISR_STATUS register
for pd status when bisr enabled")
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Change-Id: I25d7dbe777511571e9b156aeafba94a5bdfe26da
2022-01-10 14:08:57 +08:00
Andy Yan
5e364b4473 drm/rockchip: vop2: Add NV21/NV61/NV42 format support
NV21/NV61/NV42 are uv swap format for NV12/NV16/NV24

Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Change-Id: I5bffb542bcaacde38089880e7738ab00e32d27d3
2022-01-10 14:08:34 +08:00
Wyon bi
884b17df32 drm/bridge: analogix_dp: Check return value of analogix_dp_get_max_rx_{bandwidth,lane_count}()
Signed-off-by: Wyon bi <bivvy.bi@rock-chips.com>
Change-Id: I5ab9ddad5afe1ece5da270f59f6ef533540f1cb3
2022-01-10 14:07:24 +08:00
Frank Wang
d9f9fbf0da phy: rockchip: usbdp: add a condition for orien switch registering
Registering orien switch only when "orientation-switch" property
is configured in DT.

Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Change-Id: Ic2701911583d8ad047d596c3c91ba32b56d62fff
2022-01-10 12:04:24 +08:00
Wang Jie
2cea4f2ea6 arm64: dts: rockchip: rk3588s-tablet: add fusb302 interrupt gpio configuration for uboot
The uboot Type-C PD driver needs to poll the interrupt gpio level,
but the uboot code does not have a suitable interface to convert the
attributes of "interrupt-parent" and "interrupts" to standard gpio,
so add int-n-gpios configure for uboot to analyze and use.

Change-Id: Ib415902f11a35f8f8ee141297a53aa80dbb1cbaa
Signed-off-by: Wang Jie <dave.wang@rock-chips.com>
2022-01-10 12:03:33 +08:00
Andy Yan
72de5a560a drm/rockchip: vop2: Add reset dclk support
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Change-Id: I93399f18c083a3b49eb2a096ea48ff43228490e1
2022-01-08 18:24:03 +08:00
Andy Yan
5fdd23a170 arm64: dts: rockchip: rk3588: Add clk reset reference for vop
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Change-Id: Ifc4250e7a90dc9a9088f483ef163ed575ff8e7ad
2022-01-08 18:17:26 +08:00
William Wu
f1636eb0fd usb: dwc3: fix failed to enter suspend
The dwc3 disable wakeup in runtime resume, it prevent
the PM suspend with the following log on RK3588 EVB1:

[   22.910675][ T1886] PM: suspend entry (deep)
......
[   23.059751][ T1886] Hardware name: Rockchip RK3588 EVB1 LP4 V10 Board (DT)
[   23.059759][ T1886] Call trace:
[   23.059782][ T1886]  dump_backtrace+0x0/0x1c8
[   23.059797][ T1886]  show_stack+0x1c/0x2c
[   23.059813][ T1886]  dump_stack_lvl+0xdc/0x12c
[   23.059825][ T1886]  dump_stack+0x1c/0x64
[   23.059840][ T1886]  __pm_stay_awake+0xb0/0xbc
[   23.059856][ T1886]  ep_poll_callback+0x190/0x2e8
[   23.059872][ T1886]  __wake_up_common+0xc8/0x14c
[   23.059884][ T1886]  __wake_up_sync_key+0x80/0xd0
[   23.059900][ T1886]  sock_def_readable+0x44/0x7c
[   23.059915][ T1886]  netlink_broadcast_deliver+0xa0/0xe0
[   23.059928][ T1886]  do_one_broadcast+0x234/0x434
[   23.059940][ T1886]  netlink_broadcast_filtered+0xd8/0x1e0
[   23.059952][ T1886]  netlink_broadcast+0x1c/0x2c
[   23.059966][ T1886]  uevent_net_broadcast_untagged+0xd0/0x138
[   23.059977][ T1886]  kobject_uevent_env+0x3e8/0x404
[   23.059987][ T1886]  kobject_uevent+0x18/0x28
[   23.060001][ T1886]  device_del+0x290/0x488
[   23.060013][ T1886]  device_unregister+0x1c/0x3c
[   23.060025][ T1886]  wakeup_source_sysfs_remove+0x18/0x28
[   23.060036][ T1886]  wakeup_source_unregister+0x8c/0xa8
[   23.060047][ T1886]  device_init_wakeup+0x94/0xf4
[   23.060063][ T1886]  dwc3_runtime_resume+0x28/0x74
[   23.060076][ T1886]  pm_generic_runtime_resume+0x2c/0x44
[   23.060089][ T1886]  genpd_runtime_resume+0x174/0x234
[   23.060099][ T1886]  __rpm_callback+0x80/0x338
[   23.060112][ T1886]  rpm_resume+0x3e4/0x66c
[   23.060125][ T1886]  __pm_runtime_resume+0x54/0x8c
[   23.060137][ T1886]  genpd_prepare+0x70/0x100
[   23.060148][ T1886]  device_prepare+0x74/0x184
[   23.060158][ T1886]  dpm_prepare+0xb8/0x410
[   23.060169][ T1886]  dpm_suspend_start+0x30/0x1e4
[   23.060180][ T1886]  suspend_devices_and_enter+0xc4/0x338
[   23.060191][ T1886]  enter_state+0x12c/0x3f8
[   23.060201][ T1886]  pm_suspend+0x60/0xcc
......
[   23.067765][ T1886] PM: PM: Pending Wakeup Sources: NETLINK
[   23.067780][ T1886] PM: Some devices failed to suspend, or early wake event detected
[   23.092746][ T1886] OOM killer enabled.
[   23.093099][ T1886] Restarting tasks ... done.
[   23.095953][ T1886] [dhd] dhd_pm_callback: action=4, suspend=0, suspend_mode=0
[   23.096644][ T1886] Abort: Pending Wakeup Sources: NETLINK
[   23.097145][ T1886] PM: suspend exit

Actually, we can enable wakeup in runtime resume when usb
connect, so let's fix it.

Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: I7376fe45fbcbc8210db38ed49600f9ffd101607d
2022-01-08 18:03:57 +08:00
Sugar Zhang
88ebea8839 drm/rockchip: dw_hdmi-rockchip: Restore grf config when resume
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: Ic5064f35ab6770298172950258c8b7a632cbac6a
2022-01-08 17:05:26 +08:00
Sandy Huang
ffa7fd92d3 drm/rockchip: vop2: remove VP1 HDR10 support for RK3588
Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: I7b7d353c6ec1016f94d13fff418034412807e20c
2022-01-08 14:50:11 +08:00
Shunhua Lan
a33052cd79 ASoC: es8323: cache sync registers when doing suspend/resume
Signed-off-by: Shunhua Lan <lsh@rock-chips.com>
Change-Id: I88df09eb772fe2d59dc531974859a9b2a081bcbd
2022-01-07 14:02:25 +08:00
Andy Yan
9d6f377603 drm/rockchip: Add a virtual connector driver
Register a virtual drm connector driver to
replace the real hardware connector like HDMI/DP/MIPI.

This can be used for some vop test.

When a virtual connector is enabled, the corresponding
real hardware connector should be disabled.

Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Change-Id: Ic10436e97208cafe3013a4ff800c9b4168bf6e7e
2022-01-07 11:36:18 +08:00
Finley Xiao
b3e993c5f9 soc: rockchip_system_monitor: Add support to parse scmi clk and read margin
Ensure that the device registers system monitor successfully when use
scmi clk or read margin, so that the volt_adjust_mutex is available.

Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Change-Id: Ieecaa763f0c423658259a05d9f843c7860673e44
2022-01-07 11:24:32 +08:00
Wang Panzhenzhuan
88ff21e756 arm64: dts: rockchip: rk3588s-evb1-lp4x-v10-camera: add ov50c40 configs
Signed-off-by: Wang Panzhenzhuan <randy.wang@rock-chips.com>
Change-Id: I8deefe32a3326560b658f2a1b5f8b37e68184bf2
2022-01-07 11:06:31 +08:00
Zhen Chen
3f89b26931 MALI: rockchip: upgrade bifrost DDK to g10p0-01eac0, from g9p0-01eac0
Change-Id: If5e4683a1da37e00eeaa5a16463206f6f45ecfb4
Signed-off-by: Zhen Chen <chenzhen@rock-chips.com>
2022-01-07 11:05:37 +08:00
Shawn Lin
c3ad28a4aa PCI: rockchip: dw: Force reset link for standard RC
If the devices had been used by firmware and the resource had
been assigned to them but not from the kernel. It won't work for all
as not all devices allowed to reassign resource except for reset it.

Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Change-Id: Ica9ff9f52e1099aafdc03ae686788f8d8818ddd0
2022-01-07 10:51:19 +08:00
Weixin Zhou
e0a08d9c40 arm64: dts: rockchip: rk3588 boards: add wakeup-source for rtc hym8563
Signed-off-by: Weixin Zhou <zwx@rock-chips.com>
Change-Id: I84ff00c0089309418c884a5716db40adec48546d
2022-01-07 10:02:16 +08:00
Guillaume Tucker
eb98d6c9f9 UPSTREAM: rtc: hym8563: enable wakeup when applicable
Enable wakeup in the hym8563 driver if the IRQ was successfully
requested or if wakeup-source is set in the devicetree.

As per the description of device_init_wakeup(), it should be enabled
for "devices that everyone expects to be wakeup sources".  One would
expect this to be the case with a real-time clock.

Tested on rk3288-rock2-square, which has an IRQ configured for the
RTC.  As a result, wakeup was enabled during driver initialisation.

Change-Id: I1e0c3f99d38c84ba7e6c15bf8919a3f30289e7ae
Fixes: dcaf038493 ("rtc: add hym8563 rtc-driver")
Reported-by: kernelci.org bot <bot@kernelci.org>
Signed-off-by: Guillaume Tucker <guillaume.tucker@collabora.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Link: https://lore.kernel.org/r/1ea023e2ba50a4dab6e39be93d7de3146af71a60.1604653374.git.guillaume.tucker@collabora.com
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
(cherry picked from commit c56ac7a0f4)
2022-01-07 09:52:39 +08:00
XiaoDong Huang
e5f9e39692 arm64: dts: rockchip: rk3588-rk806-dual: enable vcc_3v3_s3 in suspend
RTC's power is from vcc_3v3_s3.

Change-Id: Id641a9fcb431f107c10ec92ce9b33a78c1e2a494
Signed-off-by: XiaoDong Huang <derrick.huang@rock-chips.com>
2022-01-07 09:51:33 +08:00
Li Huang
7a7e0d4b84 video: rockchip: rga3: Add missing judge for dma_buf
Signed-off-by: Li Huang <putin.li@rock-chips.com>
Change-Id: Icaf9a533ad1ad67b89d502391f6a6f4e31124c51
2022-01-06 14:30:45 +08:00
William Wu
ed0b5065fc phy: rockchip: inno-usb2: fix iddig configuration for rk3588
This patch sets iddig_en to 1 for RK3588 USB3_0 and
USB3_1 by default, then it can handle the id irq in
rockchip_usb2phy_irq() if the mode is USB_DR_MODE_HOST
when the PD_BUS is power off.

Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: Ifee1155c72eead4d9faf74b7808c4dd2f6f719eb
2022-01-06 14:30:01 +08:00
Cai YiWei
f6f8dba33e media: rockchip: isp/ispp to version v1.8.0
Change-Id: Ibabaa8c0f7dfb9f6ad6e75a0f556d8d28a1a13aa
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2022-01-06 14:28:57 +08:00
Cai YiWei
e2353386e7 media: rockchip: isp: fix CSI2RX_DATA_IDS_1 config err
Change-Id: I2c552fd3cc291cbaa62804294752b2054efeaa63
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2022-01-06 14:27:22 +08:00
Algea Cao
3378249bc2 phy: rockchip-samsung-hdptx-hdmi: Deassert hdmi phy rst when probe
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
Change-Id: I4f9e0134e5d7eee48492b397622840f1548fe919
2022-01-06 10:00:21 +08:00
Li Huang
2b456d3acd video: rockchip: rga3: Add support for rga load by hrtimer
Add debugger node to show rga load

Signed-off-by: Li Huang <putin.li@rock-chips.com>
Change-Id: Ie7f5facc94db7ccaef2f61490b6951d0c614cb30
2022-01-05 19:16:37 +08:00
Yu Qiaowei
2777810757 video: rockchip: rga3: When current->mm is not needed, don’t get it.
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: I27b09ff0d0470880897783ef2c4d488e1459df37
2022-01-05 15:49:06 +08:00
Yu Qiaowei
5bfd3a9293 video: rockchip: rga3: Use spin_lock_irq to protect read registers
When the ‘reg’ of the debugger is turned on, since the RGA has been
executed, after turning off the pd in the interrupt, the register
may continue to be read.

Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: Ic23e5e5bfe879ea6879a9322972500988415966d
2022-01-05 15:48:50 +08:00
XiaoDong Huang
85180d359d arm64: dts: rockchip: rk3588-rk806-single: adjust power state in suspend
1. on vdd_log_s0, vcc_3v3_s3.
2. off vdd_ddr_s0, vcc_1v8_s0, vdd_ddr_pll_s0.

Signed-off-by: XiaoDong Huang <derrick.huang@rock-chips.com>
Change-Id: Ife796d82626e2f2c319588b98d1f39d4ba7ad225
2022-01-05 15:35:27 +08:00
Jianqun Xu
8bda65645d dma-buf: dma-buf-cache: fix error condition for cache fail
Fixes: 43d1db61b0 ("dma-buf: dma-buf-cache: fix error case for attach / detach")

Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
Change-Id: Idc5a052bb3c2ee1c3ae45dbeac8d57178595a22f
2022-01-05 15:34:25 +08:00
Guochun Huang
a6a2d02704 phy: rockchip: mipi-dcphy: correct lanes number configuration errors
Change-Id: I05f5fe5605ae3642c386c416557bebafd6e8b8c4
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
2022-01-05 15:33:01 +08:00
Guochun Huang
69afc70624 drm/rockchip: dsi2: standby vop2 before dsi2 change from ds to cmd mode
standby vop2 to ensure dsi2 core not busy when DSI2_MODE_CTRL
change from data stream to command mode.

Change-Id: Id46d1a199ae1b9421b61622dd9fca6dda08c2781
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
2022-01-05 15:33:01 +08:00
shengfei Xu
287dac0f05 arm64: dts: rockchip: rk3588-rk806: fix the spi2_cs1 iomux
relative log:
[    2.257040] rockchip-pinctrl pinctrl: pin gpio0-8 already requested by feb20000.spi; cannot claim for 8-0051
[    2.257046] rockchip-pinctrl pinctrl: pin-8 (8-0051) status -22
[    2.257051] rockchip-pinctrl pinctrl: could not request pin 8 (gpio0-8) from group hym8563-int  on device rockchip-pinctrl
[    2.257056] rtc-hym8563 8-0051: Error applying setting, reverse things back
[    2.257064] rtc-hym8563: probe of 8-0051 failed with error -22
[    2.258247] usbcore: registered new interface driver uvcvideo

Signed-off-by: shengfei Xu <xsf@rock-chips.com>
Change-Id: I132203508f595063a5231a1f69fddbbe1287e0b4
2022-01-05 15:19:11 +08:00
Wu Liangqing
a3fbc69a1e arm64: dts: rockchip: rk3588s-evb1: enabled pwm ir
Signed-off-by: Wu Liangqing <wlq@rock-chips.com>
Change-Id: I80bf9dae575a5dba6c4e67bcef927f78f751b840
2022-01-05 15:18:25 +08:00
Weixin Zhou
499a568090 arm64: dts: rockchip: rk3588s-tablet-rk806-single: adjust some configs
Signed-off-by: Weixin Zhou <zwx@rock-chips.com>
Change-Id: I48b73e8fa5e231c49afee4465040c3c12faee860
2022-01-05 15:07:08 +08:00