Commit Graph

862852 Commits

Author SHA1 Message Date
Jason Zhu
e596cd7c88 init: panic the kernel when compare the ramdisk hash failed
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: I362eda9782f661d5faef85a773c358ad26fd4dcd
2021-03-11 12:06:13 +08:00
Jason Zhu
048b3bf402 soc: rockchip: thunderboot_sfc: calculate the ramdisk hash
Open CONFIG_ROCKCHIP_THUNDER_BOOT_CRYPTO to enable it.

Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: If87598ae61c4490bd2dd23cf33ab30827bdc2d27
2021-03-11 12:06:13 +08:00
Jason Zhu
1c9b72894e soc: rockchip: thunderboot_mmc: calculate the ramdisk hash
Open CONFIG_ROCKCHIP_THUNDER_BOOT_CRYPTO to enable it.

Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: I0ff9889417377b9e4f72c12356bf3e86e927f137
2021-03-11 12:06:13 +08:00
Zorro Liu
fd361aa5d3 drm/rockchip: ebc_dev: release version v1.05
speed up the handwriting speed.

Signed-off-by: Zorro Liu <lyx@rock-chips.com>
Change-Id: I4dafb9252067900e6a976d0aed2d5c9a791c1fbe
2021-03-11 12:04:52 +08:00
Liang Chen
cb488e870a arm64: dts: rockchip: delete combphy0 for rk3566
combphy0 is not available on rk3566 SoCs.

Change-Id: Ia68ec8441c2f3d9ac3cd13d55cb784a79f1eeb37
Signed-off-by: Liang Chen <cl@rock-chips.com>
2021-03-11 10:41:06 +08:00
Zhenke Fan
e3a7770782 media: i2c: sc430cs: update gain logic
Signed-off-by: Zhenke Fan <fanzy.fan@rock-chips.com>
Change-Id: I93db6c3acb4f5c664f40b04c4a03afe6e81e4178
2021-03-11 10:21:12 +08:00
Andy Yan
ea7d06c680 drm/rockchip: Add a virtual vop driver
Some times we only want use some of the module
of rockchip vop driver(et: rkmpp some times only
wat to use rockchip drm gem),
the real vop drivers is not needed to load.

Add a virtual vop driver let the rockchip drm launch.

Change-Id: Id6cd14a735eabaf8b4949330d56f77354e50c51c
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
2021-03-10 20:29:05 +08:00
Jason Zhu
a2a7deede1 ARM: dts: rv1126-thunder-boot: enable the crypto
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Change-Id: I375b8beab2ba6054ba13a311ce724e03034ea5d0
2021-03-10 20:16:57 +08:00
Jason Zhu
30192f8985 soc: rockchip: thunderboot_crypto: init version
Add rk_tb_sha256 for thunderboot.

Change-Id: Iff9aba9c1d4c8188e618914bc16a3faefa1b3abd
Signed-off-by: Lin Jinhan <troy.lin@rock-chips.com>
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
2021-03-10 20:13:58 +08:00
Bin Yang
00f6c0f23c arm64: dts: rockchip: add scr node for rk3568
Signed-off-by: Bin Yang <yangbin@rock-chips.com>
Change-Id: If1815a521d7db16867e47de5270b26978bb56e42
2021-03-10 19:48:01 +08:00
Yandong Lin
cb121d3d47 video: rockchip: mpp: fix offset be added repeatedly issue
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: I30db16b843f29c9d07ec3aec0eb99406eca147ed
2021-03-10 19:43:07 +08:00
Huang zhibao
8f61ddb10f input: rc: add support parser power key by rk pwm controller
some chips like 1126,356x support this feature

Signed-off-by: Huang zhibao <hzb@rock-chips.com>
Change-Id: Ia182204a4b3783b63b3cefbd70da8bd7089a9e82
2021-03-10 19:34:04 +08:00
Xu Hongfei
ca19cf66a1 media: platform: isp: don't start ldch asynchronously in multi-isp mode
fix the bug that ldch map error in multi-ISP mode

Signed-off-by: Xu Hongfei <xuhf@rock-chips.com>
Change-Id: I95d88b8db312bdce079974d3a54a3b6b79b0daab
2021-03-10 19:20:23 +08:00
William Wu
a846281fee usb: dwc3: gadget: print device events
This patch prints the reset/disconnect/suspend/wakeup event
for USB developer to check if the USB is reset/disconnted/
suspended/waked from USB PHY.

Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: I889867edc6fd4b4d2fb2927c80d55a850556a8ad
2021-03-10 19:02:23 +08:00
William Wu
69e3769569 usb: gadget: f_uvc: trace uvc control request
This patch add new uvc trace for setup request processing.

1. enable trace
   echo 4 > /sys/module/usb_f_uvc/parameters/trace

2. dump trace
   dmesg

Test on RV1109 EVB with UVC function when streaming on:

[  426.441316] uvcvideo: setup request a1 81 value 0100 index 0003 001a
[  426.450280] uvcvideo: uvc_send_response: req len 26
[  426.450444] uvcvideo: event_setup_out 0, data len 26
[  426.451545] uvcvideo: setup request 21 01 value 0100 index 0003 001a
[  426.460862] uvcvideo: uvc_send_response: req len 26
[  426.461014] uvcvideo: event_setup_out 1, data len 26
[  426.461173] uvcvideo: setup request a1 81 value 0100 index 0003 001a
[  426.485791] uvcvideo: uvc_send_response: req len 26
[  426.486672] uvcvideo: event_setup_out 0, data len 26
[  426.487145] uvcvideo: setup request a1 83 value 0100 index 0003 001a
[  426.496529] uvcvideo: uvc_send_response: req len 26
[  426.496655] uvcvideo: event_setup_out 0, data len 26
[  426.497485] uvcvideo: setup request a1 82 value 0100 index 0003 001a
[  426.506737] uvcvideo: uvc_send_response: req len 26
[  426.507195] uvcvideo: event_setup_out 0, data len 26

Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: If882728e891d033c249e6c466b40d3e2a28bccb6
2021-03-10 19:02:13 +08:00
Zou Dengming
4024ff990d arm64: configs: rockchip_defconfig: Enable CONFIG_VIDEO_GC4C33
Add camera gc4c33 for rk3566 box demo.

Signed-off-by: Zou Dengming <marsow.zou@rock-chips.com>
Change-Id: I561c89ecb385283882f0f3da12ae9c59ce9aeef1
2021-03-09 20:56:53 +08:00
Bin Yang
9773cc5d87 misc: add rockchip SOC smart card reader controller driver
Signed-off-by: Bin Yang <yangbin@rock-chips.com>
Change-Id: I8d3ab66bc6fa7cbb4e8d9b2f2c5c2feee94a045b
2021-03-09 20:51:02 +08:00
Zou Dengming
bf77a65fee arm64: dts: rockchip: rk3566-box-demo-v10: enable mipi camera gc4c33 or gc8034
Change-Id: Id3b8a317f0018d6a044bf95f3e58967ee5113741
Signed-off-by: Zou Dengming <marsow.zou@rock-chips.com>
2021-03-09 20:41:06 +08:00
Rafael J. Wysocki
34da25dd21 UPSTAREM: PM: runtime: Update device status before letting suppliers suspend
Because the PM-runtime status of the device is not updated in
__rpm_callback(), attempts to suspend the suppliers of the given
device triggered by rpm_put_suppliers() called by it may fail.

Fix this by making __rpm_callback() update the device's status to
RPM_SUSPENDED before calling rpm_put_suppliers() if the current
status of the device is RPM_SUSPENDING and the callback just invoked
by it has returned 0 (success).

While at it, modify the code in __rpm_callback() to always check
the device's PM-runtime status under its PM lock.

Change-Id: I801d91afcace8fb70fa92b447d8641cd0cd2b0cc
Link: https://lore.kernel.org/linux-pm/CAPDyKFqm06KDw_p8WXsM4dijDbho4bb6T4k50UqqvR1_COsp8g@mail.gmail.com/
Fixes: 21d5c57b37 ("PM / runtime: Use device links")
Reported-by: Elaine Zhang <zhangqing@rock-chips.com>
Diagnosed-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Tested-by: Elaine Zhang <zhangiqng@rock-chips.com>
Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org>
Cc: 4.10+ <stable@vger.kernel.org> # 4.10+
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
(cherry picked from commit 44cc89f764)
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2021-03-09 20:35:02 +08:00
Jianqun Xu
a594a2bb95 staging: android: ion: add support for ion_protected_heap
Add a new heap named "ion_protected_heap" with heap index as
(ION_HEAP_TYPE_CUSTOM + 1).

The protected heap could be used for secure memory, or memory limit.

Change-Id: I080f7d1c8e0516c1e967c3ec6d1c123d5df1867c
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2021-03-09 20:19:43 +08:00
Wu Liangqing
471ad265e4 arm64: dts: rockchip: add rk3566-evb-mipitest-v10 board
Signed-off-by: Wu Liangqing <wlq@rock-chips.com>
Change-Id: Ic46f1db90f10c3f78858ff83875c18dc6eb78822
2021-03-09 19:55:18 +08:00
Liang Chen
a85e12dc3f arm64: dts: rockchip: retrieve sata2 for rk3566
sata0 is not available for rk3566 and sata2 is available.

Change-Id: I901a509d98826dd63788cde49c4a9caae7d0f6f0
Signed-off-by: Liang Chen <cl@rock-chips.com>
2021-03-09 19:49:48 +08:00
Weiwen Chen
1ff461225d ARM: dts: rv1126-evb-v10: fix sdmmc vmmc-supply
Signed-off-by: Weiwen Chen <cww@rock-chips.com>
Change-Id: I197f02279d283d3f788e9e90b9a0e7f27d797093
2021-03-09 19:48:15 +08:00
Elaine Zhang
8bedd31fee clk: rockchip: rk3568: mark hclk_usb as critical clk
gmac1 access to the NIU bus depends on this clock.

Change-Id: I883e39678693f71acdc655004b59c5abc760ad86
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2021-03-09 19:44:42 +08:00
Huang zhibao
3b2532870f arm64: dts: rockchip: rk3566-box: enable dmc
Signed-off-by: Huang zhibao <hzb@rock-chips.com>
Change-Id: I74f28baa6f93d8b85886cfa6b9b338b5f3fbb89e
2021-03-09 19:43:25 +08:00
Andy Yan
a80aeb4d42 drm/rockchip: vop2: Set sdr2hdr_path_en when sdr2hdr enabled
If sdr2hdr_path_en is not set in sdr2hdr mode, the dly may
not match with the delay number list in TRM.

Change-Id: I989df532e42dc071ee78db79c234fa9582b8bccd
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
2021-03-09 11:26:00 +08:00
Andy Yan
47e32bf33c drm/rockchip: vop2: Enable hdr2sdr_tf_update
The vop2 default hdr2sdr tf is not good enough,
update custom hdr2sdr_tf from rk3328.

Test video: LG_BT2020_HDR10_H265_10B_2160P_60F_67M_DDR933M_Chess_HDR.mp4

Change-Id: I60b396558ede14c8b561c0403f36cf480c488edd
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
2021-03-09 11:22:47 +08:00
Huang zhibao
04c5d34e5c arm64: configs: rockchip_linux_defconfig: enable codec es8311
This is needed for rk3568 nvr demo board

Signed-off-by: Huang zhibao <hzb@rock-chips.com>
Change-Id: I63277050860389cfd4b801ac589ba75f7ae46908
2021-03-05 19:30:51 +08:00
Huang zhibao
5a19e46d5c arm64: configs: rockchip_defconfig: enable codec es8311
This is needed for rk3568 nvr demo board

Signed-off-by: Huang zhibao <hzb@rock-chips.com>
Change-Id: Id907c6d783ccdd5d4bcc084c518c3efecadd52d6
2021-03-05 19:27:31 +08:00
Jon Lin
fda4208013 drivers: rkflash: Support new spiflash
1.spinand: MX35UF1GE4AC, MX35UF2GE4AC, GD5F4GQ6RExxG, GD5F4GQ6UExxG,
XT26G01C, XT26G04C, BWJX08K-2Gb, XT26G02C
2.spinor: GD25Q128E, GD25Q256E, GD25Q256B, GD25LQ32E, GD25LQ32E,
W25Q32JW, MX25U3232F, MX25U6432F, MX25U12832F, MX25U25645GZ4I,,
XT25F32BS, XT25F16BS, P25Q64H, P25Q128H, P25Q16H, FM25Q64A, FM25M64C,
FM25M4AA, DS25M4AB

Change-Id: If2259456e9cc01281cd4e11a6d3338f2a0402357
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2021-03-05 19:19:47 +08:00
Jon Lin
f3dc096419 drivers: rkflash: Support F59L2G81KA and F59L4G81KA
Change-Id: I99cbb82fbad9a678ecd66fc3965e6164ddbd9e7d
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2021-03-05 19:18:25 +08:00
William Wu
51216a597d usb: dwc3: core: init current_dr_role in async probe
During dwc3 probe, it init the current_dr_role in drd_work,
and it must make sure that the current_dr_role is initialized
to DWC3_GCTL_PRTCAP_DEVICE or DWC3_GCTL_PRTCAP_HOST if it
support dule role mode before do async probe.

However, the drd_work and dwc3_rockchip_async_probe are handled
asynchronously, if the drd_work is handled prior to async probe,
it may fail to call dwc3_core_exit from dwc3_runtime_suspend in
async probe because of uninitialized current_dr_role. If this case
happens, the USB 2.0/3.0 PHY power on/off operations are unbalanced.

This patch get the extcon state before do runtime suspend in async
probe, and init the current_dr_role according to the extcon state.

Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: I4d1f7683d3ef3c5580f35be52d28821c47f6457f
2021-03-05 19:15:17 +08:00
Joseph Chen
75304a4856 arm64: dts: rockchip: rk3566-eink: add unified suspend configuration
- It is for lite and mem mode, the ultra mode is not configurable.
- Disable sleep debug msg;

Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: I628aa1da19e2704b382a4a7307566a094daaa63a
2021-03-05 19:14:58 +08:00
Longjian Lin
92c5712760 net/rfkill: bt: donot enable bt irq when bt is off and enable bt sleep
Signed-off-by: Longjian Lin <llj@rock-chips.com>
Change-Id: If6199b0cdf56b24d84e4edca41b561d1740a5f35
2021-03-05 19:14:32 +08:00
Shunqing Chen
c7b608a931 arm64: dts: rockchip: rk356x board: enable route_hdmi
Signed-off-by: Shunqing Chen <csq@rock-chips.com>
Change-Id: I9616a6332cb20c3047bf525a436569f881f71a1c
2021-03-05 14:55:46 +08:00
Tao Huang
8bb5326f25 PM: EM: Call em_debug_init() later when CONFIG_ROCKCHIP_THUNDER_BOOT=y
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I893ea1089cf807d51983d70e9323f4a3b4f2b000
2021-03-05 14:32:22 +08:00
Sandy Huang
a611762d20 drm/rockchp: drv: Added support for more than 4G memory
fix log:

rockchip-drm display-subsystem: swiotlb buffer is full (sz: 262144 bytes)

Change-Id: I05fd8a2674e1e73fb1d35c75c009eacc7ba8a236
Signed-off-by: Sandy Huang <hjc@rock-chips.com>
2021-03-05 14:29:33 +08:00
Zou Dengming
d6e990a143 arm64: dts: rockchip: rk3566-box-demo-v10: correct wake btchip and wake host pins
Signed-off-by: Zou Dengming <marsow.zou@rock-chips.com>
Change-Id: I257e853269fd429d34a5dc6d712183dd6d8517a3
2021-03-05 11:14:46 +08:00
Elaine Zhang
394d2ee04d net: can: rockchip: fix up the receiving filter ID
ID MASK bit is bit[28:0].

Change-Id: Id8202e777c2b9daabe2b06335bfb20bb14cc7469
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2021-03-05 09:28:52 +08:00
Huang zhibao
1ae52baba3 arm64: dts: rockchip: rk3566-box: adjust suspend mode define for box
Signed-off-by: Huang zhibao <hzb@rock-chips.com>
Change-Id: I2cf3b85f0bfc7ed9b369bbedaa19f1776c814598
2021-03-05 09:26:56 +08:00
Huang zhibao
feac441a49 arm64: dts: rockchip: rk3566-box-demo-v10: wlan add reset-gpio
Signed-off-by: Huang zhibao <hzb@rock-chips.com>
Change-Id: I1ca6bc9fbc2de4912715ae79aa9cb4473fd8dac7
2021-03-05 09:26:22 +08:00
Jianqun Xu
94daf32a11 dma-buf: show attached devices name to bufprocs node
console:/ # cat /sys/kernel/debug/dma_buf/bufprocs
surfaceflinger (PID 187) size: 66596
DMA Buffers:
Name            Exp_name                                                        Size (KB)       Alive (sec)     Attached Devices
(null)          ion_alloc-ion_system_heap-218-allocator@4.0-s                   12480           9               display-subsystem       ff9a0000.gpu
(null)          ion_alloc-ion_system_heap-218-allocator@4.0-s                   4               9               ff9a0000.gpu
(null)          ion_alloc-ion_system_heap-218-allocator@4.0-s                   12480           9               display-subsystem       ff9a0000.gpu
(null)          ion_alloc-ion_system_heap-218-allocator@4.0-s                   2288            1               ff9a0000.gpu
(null)          ion_alloc-ion_system_heap-218-allocator@4.0-s                   2288            1               ff9a0000.gpu
(null)          ion_alloc-ion_system_heap-218-allocator@4.0-s                   12288           8               display-subsystem       ff9a0000.gpu    ff9a0000.gpu
(null)          ion_alloc-ion_system_heap-218-allocator@4.0-s                   12480           9               display-subsystem       ff9a0000.gpu
(null)          ion_alloc-ion_system_heap-218-allocator@4.0-s                   12288           8               display-subsystem       ff9a0000.gpu    ff9a0000.gpu

Change-Id: I95b1feaf933cc46c8936db129f9152ead71ed664
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2021-03-04 15:33:04 +08:00
Ziyuan Xu
3f1e1d3358 media: rockchip: isp: import dma API for memory synchronisation for thunderboot
Change-Id: I29b4b4fb381ff6ba4cc7ef203c431ec0b1b6055b
Signed-off-by: Ziyuan Xu <xzy.xu@rock-chips.com>
2021-03-04 15:29:09 +08:00
Ziyuan Xu
41d2151d7a ARM: dts: rv1126-bat-ipc-v10: tune suitable memory for rkisp_thunderboot
The MCU reserves 10 frames raw data for 1080P sensor and about 1MB
header, it's about 32MB memory usage for 1080P on MCU.

Change-Id: I3bed8df0816af789ab4f143725c50e8e43ba12bb
Signed-off-by: Ziyuan Xu <xzy.xu@rock-chips.com>
2021-03-04 10:49:34 +08:00
Sun ChuanHu
3fef22cd18 ARM: dts: rv1126-bat-ipc-v10: make the powers for camera boot-on
Signed-off-by: Sun ChuanHu <aaron.sun@rock-chips.com>
Signed-off-by: Ziyuan Xu <xzy.xu@rock-chips.com>
Change-Id: I20f559edf05715ad89455e9bc579e9008e9c3059
2021-03-04 10:49:34 +08:00
Sun ChuanHu
f5bb84148b ARM: dts: rockchip: remove isp/csi clocks assign for rv1126 thunder_boot_rkisp
The assigned clks take effect off-line capture on MCU, and make MCU
abnormal.

Signed-off-by: Sun ChuanHu <aaron.sun@rock-chips.com>
Signed-off-by: Ziyuan Xu <xzy.xu@rock-chips.com>
Change-Id: Ib41b397afc7dd31a898cef9ccdef7b7c9b162f17
2021-03-04 10:48:31 +08:00
Jianqun Xu
f78fc341ef pinctrl: rockchip: fix error mux route for rk3568 pwm
Change-Id: I40ec6b0de54a6d2a01b0fe2c9dfb679088ce9821
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2021-03-04 10:38:03 +08:00
Jianqun Xu
b3bc336903 staging: android: ion: add 'heaps' debug node
console:/ # cat /sys/kernel/debug/ion/heaps
id      type    name
2       0       ion_system_heap
1       1       ion_system_contig_heap
0       0       ion_secure_heap

Change-Id: I0d798205573eb5a2b3177d51f784bf8c89ab7313
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2021-03-03 19:14:18 +08:00
Sugar Zhang
e603d7d441 ASoC: rockchip: pdm: Fix ret value
Fixes: 93773ea1ee ("ASoC: rockchip: pdm: Add support for path map")
Change-Id: If7bb2c7e08f0e65a010866b2594e360fd4be482a
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2021-03-03 19:13:54 +08:00
Cai YiWei
7e2b98f59d media: rockchip: ispp: image input from user
1.link enable ispp input video
2.set ispp input format
3.ispp output video config and stream on
4.ispp input video config and stream on

Change-Id: I742ebb71ceb87059e269628e8092177178b0ac45
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2021-03-03 19:12:23 +08:00