Commit Graph

1065334 Commits

Author SHA1 Message Date
Wang Jie
8bee178eae dt-bindings: usb: et7303: add usb role and orientation switch config
Signed-off-by: Wang Jie <dave.wang@rock-chips.com>
Change-Id: I66b4ec8c7d2b05ccfd25bd38e4ffc9aeabda73c5
2022-03-15 16:41:09 +08:00
Wang Jie
1c71e396cf usb: typec: tcpm: add vbus regulator ctrl for et7303
This adds optional vbus control for et7303 Type-C controller.

Signed-off-by: Wang Jie <dave.wang@rock-chips.com>
Change-Id: I7cd324f994962f212ff01dbd2b6073753151bfa9
2022-03-15 16:41:09 +08:00
Tao Huang
35fc84096e dt-bindings: display: media-bus-format: include uapi/linux/media-bus-format.h directly
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ifb9dfa7a0ddbdae804eb570f2af714ed5d623446
2022-03-15 16:40:07 +08:00
Jon Lin
c981b50cb2 mtd: spinand: gigadevice: Support new GD5F1GM7UxG
Change-Id: Ic0c9817afd04d281c614f8043b320857bc0ca4ac
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-03-15 16:39:38 +08:00
Felix Zeng
871ec3d046 ARM: dts: rockchip: rv1106: Add rknpu node
Signed-off-by: Felix Zeng <felix.zeng@rock-chips.com>
Change-Id: I5ae014a2af87a706d3b393cd6df165e14ca63c3b
2022-03-15 16:38:33 +08:00
Cai YiWei
306ddd3e8e ARM: dts: rockchip: add dvbm to isp for rv1106
Change-Id: I2b91a815e7fc7eda99978b0eb114ce7e257c8ec7
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2022-03-15 16:35:51 +08:00
Shawn Lin
2a608e4801 PCI: rockchip: dw: improve L2 support
Wlan devices support for RK platform has changed as the function driver
would cut down the power before host driver take place. So L2 must fail
now. We don't need to waste time for waiting for L2 to happen.

Meanwhile, given that the L2 handshake is a MSG TLP level operation, we
don't need such a long time to wait for timeout, in case some buggy devices
wouldn't support it.

Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Change-Id: I6bd9e54a9ace46c0d44e9f2fcfb1b5ced43136ab
2022-03-15 16:34:03 +08:00
Dingxian Wen
ac0d8ffc8a media: rockchip: hdmirx: Workaround to fix system crashes
1.Hdmirx DMA caused NOC abnormal pending during hot-plug operation,
resulting in system crash.Detect signal change as soon as possible
and reset hdmirx controller in FIQ to avoid hdmirx DMA exception.
2.Add hdmirx DMA reset operation when HDMI is unplugged and hdmirx
DMA is off.

Signed-off-by: Dingxian Wen <shawn.wen@rock-chips.com>
Change-Id: I89dfda97cc0e4a9ac366a87b134762e400675530
2022-03-15 14:38:18 +08:00
Dingxian Wen
c24a7e3c5c arm64: dts: rockchip: rk3588: config interrupt 468 for HDMIRX_HDMI
HDMIRX_HDMI interrupt is handled in FIQ and triggered by software
interrupt 468 in HDMIRX driver.

Change-Id: I9f3abb373198bcb615e7290621d6baa96de21a7f
Signed-off-by: Dingxian Wen <shawn.wen@rock-chips.com>
2022-03-15 14:27:00 +08:00
Chen Shunqing
c4f2304ac6 media: rockchip: hdmirx: fix edid error after resume
Close vdd_log in suspend, cause sram reset.

Signed-off-by: Chen Shunqing <csq@rock-chips.com>
Change-Id: I72b02b1df0e6df762133fb70faf47a604dd0fa57
2022-03-15 14:24:50 +08:00
Tony Xie
f9a03f5e5c soc: rockchip: sip: support config fiq.
Signed-off-by: Tony Xie <tony.xie@rock-chips.com>
Change-Id: Ie1dab613993b1dc2a54e6c87dbbac9043421b4c7
2022-03-15 14:21:04 +08:00
Yifeng Zhao
ed08d01ec6 mmc: sdhci-of-dwcmshc: configure the TX DLL TAP value for HS400
According to the signal test results, it is recommended
to configure the value of TX DLL TAP as 0x9 for HS400.

Signed-off-by: Yifeng Zhao <yifeng.zhao@rock-chips.com>
Change-Id: I4f999020a2d1c1d415894fb58b63b55f700a1531
2022-03-15 14:10:22 +08:00
Yandong Lin
2d2e264f4c ARM: dts: rockchip: add dvbm/mpp/enc node for rv1106
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: Id464222aa0c41b47be2c8b075d7f5bfa8e43a343
2022-03-15 11:45:12 +08:00
Jon Lin
cd7c4819ab mtd: spi-nor: xtx: Add code
Change-Id: I789d0662cc77f038fd0521749274c3d484a42bfc
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-03-15 11:42:18 +08:00
Jon Lin
a3df8a05a6 mtd: spi-nor: xmc: Support new devices
XM25QH32C, XM25QH64C, XM25QU64C, XM25QH128B, XM25QH128C, XM25QU128C

Change-Id: I3a305f3a7359803c707c7efd7973cfcf1c8a4a32
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-03-15 11:42:18 +08:00
Jon Lin
a5456f1383 mtd: spi-nor: gigadevice: Support gd25q512
Change-Id: I2f0368bffb6002a21126f35eb555909339dcc5ae
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2022-03-15 11:42:18 +08:00
Lin Jinhan
02bd80254d crypto: rockchip: cryptodev_linux: add rsa support
Add new ioctl cmd RIOCCRYPT_RSA_CRYPT for rsa encrypt/decrypt.

Signed-off-by: Lin Jinhan <troy.lin@rock-chips.com>
Change-Id: If92e1a71b1ce4fcf6b414736cf6405a1d7b6334c
2022-03-15 10:34:10 +08:00
Tao Huang
cf394eddf2 usb: typec: tcpm: Fix for GKI
Fixes: b1302e6a83 ("usb: typec: tcpm: add pd handler lock")
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ic0709a80851490a8dca4c53a8e0fa50b18bf0a63
2022-03-15 09:45:57 +08:00
Tao Huang
463bcb6c7f init: Introduce call initcall async
Support call same level initcall async in kthread.
Introduce kernel parameter "initcall_nr_threads" control how many threads.
initcall_nr_threads default is 0, which disable intcall async.
initcall_nr_threads=-1, auto selected the number of threads.

Save boot time about 29ms on rk3126-bnd-d708 board.

Change-Id: I04663d22500bc1d65ca5841fb08e4b57083d6b5e
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2022-03-14 19:37:36 +08:00
Cai YiWei
243508d8ec media: rockchip: isp: fix config of capture_v30
Change-Id: Iaa929ec3f1ca3d469c2b227980ec44e135f0e1a8
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2022-03-14 19:26:51 +08:00
Ding Wei
b6f99be6df iommu/rockchip: fix issue for read the value for the MMU_DTE_ADDR
The register of MMU_DTE_ADDR may effect for delay several us.

Change-Id: I74397a914313d9fe3d7c93de7b94b4b38dc61c7b
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2022-03-14 17:56:48 +08:00
Jianqun Xu
06d55ecd4d ARM: rv1106_defconfig: CONFIG_FORCE_MAX_ZONEORDER = 9
+CONFIG_FORCE_MAX_ZONEORDER=9

Set max zone order to 9, make the pagelock to be 1MiB size.

Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
Change-Id: If013d2dc092c85c89b325b4c646c814f9cf94fef
2022-03-14 16:22:47 +08:00
William Wu
f14ef60afd phy: rockchip: inno-usb2: set bvalid to high by grf for rv1103
RV1103 doesn't have VBUSDET pin for the usb phy to
detect the USB VBUS, and the default status of bvalid
is inactive(low level), it cause the dwc3 controller
fail to start usb device connection, so it needs to
set bvalid to high by grf for RV1103.

Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: If63c68270c14ff8fa402805a33ce3061f6f796ab
2022-03-14 16:04:46 +08:00
William Wu
7598c25d0b ARM: configs: rv1106-evb.config: Enable usb phy and controller
This patch enable the USB configs for basic device and
host functions.

With this patch, it also enable CONFIG_CONFIGFS_FS because
the USB Gadget F_FS depends on it.

I use size cmd to calculate the increased static memory.

before:
   MODULE                                     BYTES
   kernel/drivers                           1212734
   kernel/fs                                 699540

after:
   MODULE                                     BYTES
   kernel/drivers                           1506379
   kernel/fs                                 712940

And if we disable the CONFIG_DEBUG_FS, it can save 11441 Bytes
for xhci-debugfs driver.

Signed-off-by: William Wu <william.wu@rock-chips.com>
Change-Id: Id23410e66c49fb54663e34a23e09e142d49c7dd9
2022-03-14 16:04:25 +08:00
Ondrej Jirman
7c62ae6c44 BACKPORT: i2c: rk3x: Handle a spurious start completion interrupt flag
In a typical read transfer, start completion flag is being set after
read finishes (notice ipd bit 4 being set):

trasnfer poll=0
i2c start
rk3x-i2c fdd40000.i2c: IRQ: state 1, ipd: 10
i2c read
rk3x-i2c fdd40000.i2c: IRQ: state 2, ipd: 1b
i2c stop
rk3x-i2c fdd40000.i2c: IRQ: state 4, ipd: 33

This causes I2C transfer being aborted in polled mode from a stop completion
handler:

trasnfer poll=1
i2c start
rk3x-i2c fdd40000.i2c: IRQ: state 1, ipd: 10
i2c read
rk3x-i2c fdd40000.i2c: IRQ: state 2, ipd: 0
rk3x-i2c fdd40000.i2c: IRQ: state 2, ipd: 1b
i2c stop
rk3x-i2c fdd40000.i2c: IRQ: state 4, ipd: 13
i2c stop
rk3x-i2c fdd40000.i2c: unexpected irq in STOP: 0x10

Clearing the START flag after read fixes the issue without any obvious
side effects.

This issue was dicovered on RK3566 when adding support for powering
off the RK817 PMIC.

Signed-off-by: Ondrej Jirman <megous@megous.com>
Reviewed-by: John Keeping <john@metanate.com>
Signed-off-by: Wolfram Sang <wsa@kernel.org>
(cherry picked from commit 02fe0fbd8a)
Signed-off-by: David Wu <david.wu@rock-chips.com>
Change-Id: I9cf23d9a9bc9560a421c6fe13a82a6637d8a1432
2022-03-14 15:28:45 +08:00
Shunhua Lan
0260220515 media: rockchip: hdmirx: add hdmirx class for audio info
Signed-off-by: Shunhua Lan <lsh@rock-chips.com>
Change-Id: Ifd4f9cd9e28318f49fdc3da95113819de3775587
2022-03-14 14:18:36 +08:00
Guochun Huang
7cceedfb74 drm/panel: panel-simple: add error message to debug.
in order to directly determine the specific error
location of panel_simple_probe from error message
as follow:

BUG:
[    2.055658] rockchip-drm display-subsystem: bound ff900000.vop (ops
vop_component_ops)
[    2.055791] rockchip-vop ff8f0000.vop: missing rockchip,grf property
[    2.056148] rockchip-drm display-subsystem: bound ff8f0000.vop (ops
vop_component_ops)
[    2.056505] [drm:rockchip_dp_bind] *ERROR* failed to find panel
[    2.056732] rockchip-drm display-subsystem: failed to bind
ff970000.edp (ops rockchip_dp_component_ops): -517
[    2.057374] rockchip-drm display-subsystem: master bind failed: -517

Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
Change-Id: I2ceeaa9fac3834ad0c4b2bc0a4d8ab79050dfd8b
2022-03-12 19:32:59 +08:00
Lin Jinhan
23c9526f86 crypto: rockchip: v2: akcipher: prevent input data overflow
Signed-off-by: Lin Jinhan <troy.lin@rock-chips.com>
Change-Id: I39442e8e8ad1897b454da451090fbe867d6b26d6
2022-03-12 17:19:57 +08:00
Lin Jinhan
1e2b2b5aec crypto: rockchip: v2: akcipher: drop sign and verify
For kernel 5.10, the interface functions of sign and
 verify have changed and are not mandatory.

Signed-off-by: Lin Jinhan <troy.lin@rock-chips.com>
Change-Id: I2b94eaeaa5d0d3dd99ba86dd418338d9502c8aa5
2022-03-12 17:19:57 +08:00
吴良清
6e8b377f6d Revert "Revert "arm64: dts: rockchip: rk3588-android: enabled dmc""
This reverts commit de8062f2c3.

Change-Id: I061d2738aed267263f02f494b1663fb8d8a0e5db
Signed-off-by: Wu Liangqing <wlq@rock-chips.com>
2022-03-12 16:57:59 +08:00
Jianwei Fan
d079e65435 media: i2c: imx214: adapt to kernel-5.10 and add 4lane mode support
Signed-off-by: Jianwei Fan <jianwei.fan@rock-chips.com>
Change-Id: I05129ea47403f173fda55ddc4ccccc9fce5791f8
2022-03-12 16:49:51 +08:00
Sugar Zhang
d27ca5b359 drm/bridge: synopsys: dw-hdmi-qp: Fix audio infoframe
AUDI_CONTENTS0: { RSV, HB2, HB1, RSV }
AUDI_CONTENTS1: { PB3, PB2, PB1, PB0 }
AUDI_CONTENTS2: { PB7, PB6, PB5, PB4 }

PB0: CheckSum
PB1: | CT3    | CT2  | CT1  | CT0  | F13  | CC2 | CC1 | CC0 |
PB2: | F27    | F26  | F25  | SF2  | SF1  | SF0 | SS1 | SS0 |
PB3: | F37    | F36  | F35  | F34  | F33  | F32 | F31 | F30 |
PB4: | CA7    | CA6  | CA5  | CA4  | CA3  | CA2 | CA1 | CA0 |
PB5: | DM_INH | LSV3 | LSV2 | LSV1 | LSV0 | F52 | F51 | F50 |
PB6~PB10: Reserved

AUDI_CONTENTS0 default value defined by HDMI specification,
and shall only be changed for debug purposes.
So, we only configure payload byte from PB0~PB7(2 word total).

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: Idfbb34ff7f7069af4e73c6995f32eefa798a9450
2022-03-12 16:29:28 +08:00
Sugar Zhang
ea0f840194 drm/bridge: synopsys: dw-hdmi-qp: Fix channel status
* LPCM: BPCUV insertion by hw
* NLPCM/HBR: BPCUV insertion from stream

when BPCUV is from stream, we should not enable hw channel
status override which will replace CS with the hw one.
This fixes DD+ bitstream.

when BPCUV generated from HW, PBIT_FORCE_EN should be set
for Parity bit calculated internally.
This fixes no sound on some display devices.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I3aa0390d9dd7d217853394c74576749c36b84720
2022-03-12 16:29:22 +08:00
Sugar Zhang
974a88ba65 arm64: dts: rockchip: rk3588: Add DCLKx for hdmi nodes
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: If7e1be0e59bd2234e32769e06bc767b4a6fc2112
2022-03-12 16:29:15 +08:00
Algea Cao
de16913c3b drm/rockchip: dw_hdmi: Make sure dclk is enabled when set audio registers
Change-Id: Idb62c2c9ea0d75d7090ec3e35c7742b0d42b3e43
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2022-03-12 16:29:07 +08:00
Algea Cao
c14ae13e54 drm/rockchip: vop2: Save crtc id in rockchip_crtc_state
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
Change-Id: Iadcf16d59241f4915421f5c3937d4abe0a9bc304
2022-03-12 16:28:59 +08:00
Algea Cao
f0b4873247 drm/bridge: dw-hdmi-qp: Send AVI/DRMI packet once per field
Increasing the sending frequency of infoframe improves
compatibility.

Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
Change-Id: I095495d8d6641e7263de6cf2d3359f645aac2d6b
2022-03-12 16:19:30 +08:00
Algea Cao
4acfe816a6 drm/bridge: dw-hdmi-qp: Enable cec when resume
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
Change-Id: I670ac19b14725e575c8a194a9cbf1fd96560d764
2022-03-12 16:18:49 +08:00
Zefa Chen
179381a7c5 phy: rockchip: csi2-dphy: fixed err path register only for rv1106
Fixes: f31433ff94 ("phy: rockchip: csi2-dphy: support rv1106")
Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com>
Change-Id: Id4ad47f5fa5eb279b428216b3d568d7f3405819b
2022-03-12 16:08:21 +08:00
Yu Qiaowei
3289e323f8 video: rockchip: rga3: Fixup pr_err for debug info to pr_info
Update driver version to 1.2.5

Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: Ic34b2dd0f351906cd05f08db3e43052c0ab6f07f
2022-03-12 16:02:31 +08:00
Yu Qiaowei
76c47e9eea video: rockchip: rga3: fixup scale error on win1
even multiples of 128 (act w/h) require a scaling factor -1

Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: I5e7d68088fb1eceb7a57729ce9f87886a3b9fbaf
2022-03-12 16:02:31 +08:00
Yu Qiaowei
9a9d2d4903 video: rockchip: rga3: update register print
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: Ic707e77ac4eb3757e7299c9fe27ab2bd4bfef55e
2022-03-12 16:02:31 +08:00
Yu Qiaowei
c7123b7112 video: rockchip: rga3: Fix 1106 RGA2 CSC output exception
Default configuration Y_clip[0,255] UV_clip[0,255].

Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: I2134fa5fc179a6e86d73b11a632236b6859cc056
2022-03-12 16:02:31 +08:00
Yu Qiaowei
e3e16782ac video: rockchip: rga3: support early interruption
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: I4cbd31d9088b789dffc215ce891cfcaa08a8b0bf
2022-03-12 16:02:31 +08:00
Yu Qiaowei
43375c377b video: rockchip: rga3: RGA2 support OSD
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: Ib649bbdf4b7b41b9bb93323b9004ca5e17577ec5
2022-03-12 16:02:31 +08:00
Yu Qiaowei
4bb8b324f2 video: rockchip: rga3: RGA2 support YUV HDS/VDS
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: I03f909f4d52bb8c5bd6c0607064f9075a4865cd7
2022-03-12 16:02:31 +08:00
Yu Qiaowei
06622a5859 video: rockchip: rga3: support Yin_Yout mode
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: Ia94e4e58575eabcc122390ad126a1c5d9e6f468e
2022-03-12 16:02:31 +08:00
Yu Qiaowei
943b11ebfa video: rockchip: rga3: RGA2 Support mosaic
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: Ib79b211c76bc0f547e597a9dbeb94726b3766983
2022-03-12 16:02:31 +08:00
Yu Qiaowei
e95866de6e video: rockchip: rga3: Support to judge the hardware information of 1106
Signed-off-by: Yu Qiaowei <cerf.yu@rock-chips.com>
Change-Id: I42f77a95d18e9e16e08194c1011114fe69a2ede4
2022-03-12 16:02:31 +08:00
Chen Shunqing
64faa64356 media: rockchip: hdmirx: set phy to low power mode
Signed-off-by: Chen Shunqing <csq@rock-chips.com>
Change-Id: I28c90d43029c1c0d71e4c7686a84fc086be8742f
2022-03-12 15:20:49 +08:00