Commit Graph

1276858 Commits

Author SHA1 Message Date
Tao Huang
05f5de1a55 ARM: dts: rockchip: Fix typos in Rockchip copyright notices
There are many cases in which the company name is misspelled.
The patch fixes these typos.

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ie63b5b477dc7183b6360763cb89e5639aaf07d4e
2024-12-09 15:57:01 +08:00
Tao Huang
0cdee0d668 arm64: dts: rockchip: Fix typos in Rockchip copyright notices
There are many cases in which the company name is misspelled.
The patch fixes these typos.

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ia1da04dc12e6e63167447320b4f877e1f4353e12
2024-12-09 15:51:13 +08:00
Zhang Yubing
b11a75fa5b arm64: dts: rockchip: rk3399-evb-ind-lpddr4-linux: dp attach to vopb
Change-Id: I510800fdcc8df280f10f7665f26058e708140086
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-12-06 16:05:10 +08:00
Damon Ding
b7624d1c25 pwm: rockchip: move the clk_osc initialization earlier in probing
With this patch, the error handling of clk_osc initialization
will be more reasonable. Otherwise, the "goto err_pclk" is
meaningless.

Fixes: 19b3f8d830 ("pwm: rockchip: add pwm clk_osc control for wave generator mode")
Change-Id: Ie23ea14eab59f1bb985f3e9d289fe1d0f74545e9
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2024-12-06 15:08:20 +08:00
Damon Ding
1a742dcd1f pwm: rockchip: fix the return value check of .get_biphasic_result()
Without this patch, the pclk may not be disabled if failed to
get biphasic counter result.

Fixes: 7a42db27aa ("pwm: rockchip: support for biphasic counter mode")
Change-Id: I5dd279fb1cbfc493531b95181464e2c7d3a4cea9
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2024-12-06 15:08:20 +08:00
Zhang Yubing
14cf391f07 drm/rockchip: cdn-dp: support get hpd by gpio
DPTX may use tcphy0 or tcphy1. If hardware design support
both tcphy0 and tcphy1, then each phy port need a hpd line.
For example, tcphy0 port use GPIO1B5 and tcphy1 port use
GPIO1B6, it should config dts as follow:
&cdn_dp {
	...
	pinctrl-names = "default";
	pinctrl-0 = <&cnd_dp_hpd>;
	hpd-gpios = <&gpio1 RK_PB5 GPIO_ACTIVE_HIGH>,
		    <&gpio1 RK_PB6 GPIO_ACTIVE_HIGH>;
	phys = <&tcphy0_dp>, <&tcphy1_dp>;
	...
};

&pinctrl {
	...
	dp {
		cdn_dp_hpd: cdn-dp-hpd {
			rockchip,pins = <1 RK_PB5 RK_FUNC_GPIO &pcfg_pull_down>,
					<1 RK_PB6 RK_FUNC_GPIO &pcfg_pull_down>;
		};
	};
	...
};

If only 1 phy port can be used for DPTX, For example, using
tcphy0 and GPIO1B5 as hpd pin. It should config dts as follow:
&cdn_dp {
	...
	pinctrl-names = "default";
	pinctrl-0 = <&cnd_dp_hpd>;
	hpd-gpios = <&gpio1 RK_PB5 GPIO_ACTIVE_HIGH>;
	phys = <&tcphy0_dp>;
	...
};

&pinctrl {
	...
	dp {
		cdn_dp_hpd: cdn-dp-hpd {
			rockchip,pins = <1 RK_PB5 RK_FUNC_GPIO &pcfg_pull_down>;
		};
	};
	...
};

Change-Id: Id1acc428431bb13d7074e9daaab2fcca2ac2782e
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-12-05 19:49:56 +08:00
Zhang Yubing
a19d0c9b36 drm/rockchip: cdn-dp: request firmware lately
If request firmware in bind stage and the driver go into the
unbind process, it will spend some time to wait timeout. It's
better request firmware after all component bind then request
firmware.

Change-Id: Id76ddb89fb3478bf96e31513578aab3e6ad22781
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-12-05 19:49:44 +08:00
Zhang Yubing
9ea8299b09 drm/rockchip: cdn-dp: aux unrigster when unbind
Change-Id: If0b20ec236fe110c3d7a257847a16d24722c9baa
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-12-05 14:31:30 +08:00
Zhang Yubing
af36fa1547 drm/rockchip: cdn-dp: config connector fwnode for hotplug
Change-Id: I7dcb65a11fc6f7212bf8107c01dac133730568a4
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-12-05 14:25:33 +08:00
Zhang Yubing
b90a1c7c18 phy: rockchip-typec: support get lane mapping from dtsi
Change-Id: Icd1b9a5a47256c26c2c28a079a71d83a22d29a2c
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-12-05 14:25:33 +08:00
Zhang Yubing
b429b37e75 drm/rockchip: cdn-dp: get extend link caps
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
Change-Id: I353e1cf1eaf9b211c7e8b8f159ff244aa338102a
2024-12-05 14:25:33 +08:00
Wyon Bi
1e00a071b4 drm/rockchip: cdn-dp: ignore firmware fallback mechanism
The firmware fallback machanism will speed more time to wait
the firmware loading if the firmware is no ready. Ignore firmware
fallback mechanism will reduce some time in this case.

Change-Id: I54245832728c956ea67be9f82cf4abd2ed8fbded
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
2024-12-05 14:25:33 +08:00
Wyon Bi
ceaef0c7df drm/rockchip: cdn-dp: Add bus format setting
Change-Id: Id54d3dcf00dc1d535783674d3a57309469d279f3
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
2024-12-05 14:25:33 +08:00
Zhang Yubing
4a36249d53 drm/rockchip: cdn_dp: add set power state
Change-Id: Ib8d06bc8577c38eff2d07e2f794e3748c46f3333
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-12-05 14:25:14 +08:00
Zhang Yubing
eb22f895f4 phy: rockchip-typec: Try to turn the DP PHY on several times
Change-Id: I945abf00bfd2b56600f25a8ee256988790f0a2dc
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-12-04 16:56:51 +08:00
Zhang Yubing
fe586d6d4f clk: rockchip: rk3576: support more pll frequency for display
Change-Id: Id769e353d6916730594df72b4cc4929ab2cfdfb0
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-12-04 12:04:04 +08:00
Huibin Hong
e4778e4c89 ARM: dts: rockchip: rk3506g-evb1-v10: enable uart3 and uart4
uart3 is used as rs485.

Change-Id: Iaa9bb2d1482fb5def856202f0546b2f528995a9a
Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
2024-12-03 17:33:27 +08:00
Jiahang Zheng
cf157fd678 ARM: dts: rockchip: rk3506-evb1: command line add storagemedia=mtd
Change-Id: I2b72cba3daf52430b6a0871f60150ac0b5b95b1e
Signed-off-by: Jiahang Zheng <jiahang.zheng@rock-chips.com>
2024-12-03 17:30:31 +08:00
Cai YiWei
8d891df6ed media: rockchip: isp: fix isp30 unite mode for rk3588
Change-Id: Ie11e8bc01adfe14f386aff1f22382a53606aa170
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2024-12-03 14:30:15 +08:00
Cai YiWei
501e98ac8a media: rockchip: isp: fix bay3d if two readback for isp32
if over resolution specification will need two readback,
first readback need to discard bay3d write data.

Change-Id: I940949109d18f54bde8ebe4650d2abebfe7b1ba8
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2024-12-03 14:30:15 +08:00
Cai YiWei
8a5b96b0af media: rockchip: isp: fix group aov no working for isp32
Change-Id: Ice9d129c32691c1822cd424785dd3f59d2ae74cb
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2024-12-03 14:30:15 +08:00
Cai YiWei
358b83e069 media: rockchip: isp: fix multi sensor with unite mode
large resolution need to divided into left and right
small resolution no need to divided

Change-Id: If0f60d97b90afa7eba306c09b5c56eda7735c5fa
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2024-12-03 14:30:15 +08:00
Cai YiWei
edcefc7318 media: rockchip: isp: add raw filter to procfs debug
BIT(7) for skip raw input update, example:
echo mode=0x80 > /proc/rkisp0-vir0

Change-Id: I6984d6eb191ce6d63c6b9cbf6cc90c0b82ac6613
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2024-12-03 14:30:15 +08:00
Caesar Wang
e7f42c688a arm64: dts: rockchip: Add mmc aliases for rk3576-linux.dtsi
This series in order to have the default MMC alias.

    The mmc default alias:
            mmc0 = &sdhci;
            mmc1 = &sdmmc;
            mmc2 = &sdio;

The Linux OS have the post-build.sh to handle the rootfs,
and export RK_EXTRA_PARTITIONS for setting the PARTITIONS.

Change-Id: Ide2fb3407e4f488ad5e2f26711864cd23dfada54
Signed-off-by: Caesar Wang <wxt@rock-chips.com>
2024-12-03 11:37:15 +08:00
Tao Huang
861574fe12 Revert "rk: add scripts/clang-wrapper.py"
This reverts commit b8f2e67cb1.

Replaced by CONFIG_WERROR.

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I40736915b4bda71aa404ce9b12aacec30ffb275b
2024-12-02 19:22:08 +08:00
Tao Huang
0535dc30b4 Revert "rk: add gcc-wrapper"
This reverts commit e9fa201a63.

Replaced by CONFIG_WERROR.

Change-Id: I19bfd33456be16f52c7d45252f612d8a8961e139
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2024-12-02 19:21:49 +08:00
Jon Lin
9a58cb0abe PCI: rockchip: dw-ep: Detecting ATU features to achieve DWC ATU interface development
Change-Id: I53b48c5318aeeef6c39ea4a72c7f1f703bcb5a8e
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2024-12-02 18:26:08 +08:00
Andy Yan
c6d9d4543e drm/rockchip: vop2: Check the write-back width for VOP version prior rk3588
For VOP of rk3588/68, the writeback width must be align to 16 pixel,
a non-16pixel-aligned width will be round down to 16 pixel aligned
by VOP hardware.

Change-Id: Ide65f67d2435189c25c74b68eedbd1ba5c3e9014
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
2024-12-02 18:25:48 +08:00
Andy Yan
44f022321a UPSTREAM: drm/rockchip: vop: Fix a dereferenced before check warning
The 'state' can't be NULL, we should check crtc_state.

Fix warning:
drivers/gpu/drm/rockchip/rockchip_drm_vop.c:1096
vop_plane_atomic_async_check() warn: variable dereferenced before check
'state' (see line 1077)

Fixes: 5ddb0bd4dd ("drm/atomic: Pass the full state to planes async atomic check and update")
Change-Id: If34ed62e2e890742ce6da73efeb9fa78c530bc95
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Link: https://patchwork.freedesktop.org/patch/msgid/20241021072818.61621-1-andyshrk@163.com
(cherry picked from commit ab1c793f457f740ab7108cc0b1340a402dbf484d)
2024-12-02 18:25:40 +08:00
Sugar Zhang
8fcf0e4c05 ASoC: rockchip: i2s-tdm: Fix WL for TDM mode
TDM FIFO depends on fifos used.

Fixes: b4dce5a43a20 ("ASoC: rockchip: i2s-tdm: Optimize WL for TDM mode")

Change-Id: I04ce9bc55e1dffa8cc04b051d90e35545e06f4e2
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2024-12-02 18:25:22 +08:00
Lin Jianhua
226c44e770 net: wireless: rockchip_wlan: bcmdhd: fixup compile error on aarch32
drivers/net/wireless/rockchip_wlan/rkwifi/bcmdhd/wl_cfg80211.c:7913:1:
error: stack frame size (1448) exceeds limit (1280) in 'wl_cfg80211_add_key' [-Werror,-Wframe-larger-than]

Signed-off-by: Lin Jianhua <linjh@rock-chips.com>
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ie7899827ed313f7eddc853e78474be7e7ac9a756
2024-12-02 18:22:04 +08:00
Jianlong Wang
0de2a2efa4 arm64: dts: rockchip: rk3328: fix usb2phy node name
Fix u-boot error:
Call trace:
 PC:	[< 00235a50 >]  regmap_write+0x4/0x18      drivers/core/regmap.c:142
 LR:	[< 00239704 >]  rk3328_usb2phy_tuning+0x28/0x6c      drivers/phy/phy-rockchip-inno-usb2.c:847

Stack:
       [< 00235a50 >]  regmap_write+0x4/0x18
       [< 00239b24 >]  rockchip_usb2phy_probe+0x234/0x238
       [< 00233b00 >]  device_probe+0x214/0x274
       [< 00234bd4 >]  uclass_get_device_tail+0x1c/0x40
       [< 00234c5c >]  uclass_get_device_by_name+0x2c/0x38
       [< 0023a090 >]  otg_phy_init+0x28/0x144
       [< 0026aa20 >]  usb_gadget_register_driver+0x7c/0xa4
       [< 0026c66c >]  usb_composite_register+0x50/0x74
       [< 0026c9f4 >]  g_dnl_register+0x1c/0x4c
       [< 0020ec00 >]  do_rkusb+0x29c/0x4e0
       [< 0022baf4 >]  cmd_process+0xdc/0x10c
       [< 00214aa4 >]  run_list_real+0x6e4/0x728
       [< 00214c58 >]  parse_stream_outer+0x170/0x66c
       [< 002143a8 >]  parse_string_outer+0xcc/0xe4
       [< 0021495c >]  run_list_real+0x59c/0x728
       [< 00214c58 >]  parse_stream_outer+0x170/0x66c
       [< 0021436c >]  parse_string_outer+0x90/0xe4
       [< 00209d34 >]  do_download+0x24/0x50
       [< 0022baf4 >]  cmd_process+0xdc/0x10c
       [< 00214aa4 >]  run_list_real+0x6e4/0x728
       [< 00214c58 >]  parse_stream_outer+0x170/0x66c
       [< 0021436c >]  parse_string_outer+0x90/0xe4
       [< 00202888 >]  setup_boot_mode+0xc8/0xf0
       [< 0020350c >]  board_late_init+0x1e4/0x424
       [< 00282c0c >]  initcall_run_list+0x58/0x94
       [< 00215b84 >]  board_init_r+0x20/0x24
       [< 00201940 >]  relocation_return+0x4/0x0

Change-Id: I1c931f385548eaa8ba11407a23a7d0c31bb1464b
Signed-off-by: Jianlong Wang <jianlong.wang@rock-chips.com>
2024-12-02 18:21:46 +08:00
Damon Ding
47f3d3f405 ARM: dts: rockchip: rk3506-iotest: change ubi.mtd from 4 to 5
Change-Id: I316b8585cef8ecd1d2661168c7b4226292ba24dd
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2024-12-02 14:23:41 +08:00
Jon Lin
5e5bea18c6 misc: rockchip: pcie-rkep: Support pcie err_handler
Change-Id: I732adc22965ccc99199848bf4315e1511dcb957a
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2024-12-02 11:17:03 +08:00
Elaine Zhang
cd4db37fa4 clk: rockchip: rk3568: remove pwm0 for protect clock
Fixes: e0c790b129 ("clk: rockchip: rk3568: protect pwm clks")
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Change-Id: I45c5a9f502052bf191fe80f11a9b510592a114a0
2024-11-29 19:52:41 +08:00
Jiajian Wu
c7a128313e ASoC: codecs: rk3506: Check substream direction in hw_params and shutdown
Change-Id: I55f5b14123c443d83577807ccbd38660616bf744
Signed-off-by: Jiajian Wu <jair.wu@rock-chips.com>
2024-11-29 15:38:20 +08:00
Jiajian Wu
ff8cc6da8a ARM: dts: rockchip: rk3506g-demo-display-control: Bind loopback to rk730_sound
Change-Id: Ib619e7bd2eab535acba72037722c66bf60f82f59
Signed-off-by: Jiajian Wu <jair.wu@rock-chips.com>
2024-11-29 15:38:18 +08:00
Jiajian Wu
da13072958 ARM: dts: rockchip: rk3506g-evb1-v10: Bind loopback to es8388_sound
Change-Id: I3fefd76a41cd9b53e61f2c144a38a77184ddff10
Signed-off-by: Jiajian Wu <jair.wu@rock-chips.com>
2024-11-29 15:37:58 +08:00
Jiajian Wu
61bf3015b1 ASoC: dt-bindings: rockchip: add property 'mclk-fs-mapping' for multidais
Change-Id: I0259297f6849ebc86abe5513d95d5a227fa5677f
Signed-off-by: Jiajian Wu <jair.wu@rock-chips.com>
2024-11-29 14:31:28 +08:00
Jiajian Wu
5ee0f90b7c ASoC: rockchip: multi-dais: Support set different mclk to dais
Change-Id: I15d8be7980252fa7ac70ff73170c5ae9b812eb63
Signed-off-by: Jiajian Wu <jair.wu@rock-chips.com>
2024-11-29 14:31:28 +08:00
Simon Xue
a780a89108 drm/rockchip: gem: try other IOVA if iommu map failed
We get the same IOVA from DRM mm framework at different times which
finally cause iommu map failed. So let's try other IOVA if iommu map
failed time exceeds the limitation to map as a workaround.

Change-Id: Ic539f4a64d5ed0c9d3f5ac01acf3f0922a2fdc1f
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2024-11-29 14:18:20 +08:00
Tao Huang
2b64d93e09 ARM: configs: rk3506-display.config: Disable CONFIG_ROCKCHIP_DW_MIPI_DSI2
This feature is not available for rk3506.

Change-Id: Ic74e03ee687b91f4fe306e8b57689284dbd73d83
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2024-11-29 14:17:11 +08:00
Jiajian Wu
b89d2d2e66 ASoC: dt-bindings: rockchip: add property 'rockchip,mclk-fs-mapping' for multicodecs
Change-Id: Iffc566092dec8b9fd0391b6ce4327829c67e78c2
Signed-off-by: Jiajian Wu <jair.wu@rock-chips.com>
2024-11-29 14:16:02 +08:00
Jiajian Wu
1952452c5b ASoC: rockchip: multicodecs: Support set different mclk to codecs
Change-Id: I305828159da0c5a1bffc6ee832b3c6c71dbd6354
Signed-off-by: Jiajian Wu <jair.wu@rock-chips.com>
2024-11-29 14:14:51 +08:00
Sugar Zhang
76d3b8c82a ARM: dts: rockchip: rk3502-evb1: Add pinctrl-sleep for SAI1
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: Ibdb38886942e979919d7b1f3eed138379357cb9c
2024-11-29 09:18:48 +08:00
Sugar Zhang
c2f444153a ARM: dts: rockchip: rk3506-pinctrl: Add rm_io_idle pins
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I2d0ed26188932e01342ced7791551bff6ac3bc06
2024-11-29 09:18:16 +08:00
Ye Zhang
766c5f5333 ARM: dts: rockchip: pinconf.dtsi add input enable pull down
Signed-off-by: Ye Zhang <ye.zhang@rock-chips.com>
Change-Id: I584b1d26ad38eff38f2c72ed8d58c4b15c604e7e
2024-11-29 09:17:42 +08:00
Sandy Huang
263ff45dbf drm/rockchip: vop2: Fix compile error on arm32 platform
ld.lld: error: undefined symbol: __udivdi3
>>> referenced by rockchip_drm_vop2.c
>>>
drivers/gpu/drm/rockchip/rockchip_drm_vop2.o:(vop2_plane_atomic_check)
in archive vmlinux.a
>>> did you mean: __udivsi3
>>> defined in: vmlinux.a(arch/arm/lib/lib1funcs.o)

arm-none-linux-gnueabihf-ld: drivers/gpu/drm/rockchip/rockchip_drm_vop2.o: in function
`vop2_calc_dsc_clk':
rockchip_drm_vop2.c:(.text+0x239c): undefined reference to `__aeabi_uldivmod'

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: Iac0b61444cd4d33c62bd8994d0ce7ca1bab7bfa4
2024-11-28 19:18:13 +08:00
Zhen Chen
b2a3a28618 Mali: utgard: Replace calls to dma_fence_ops::signaled with dma_fence_is_signaled()
To address the issue in kernel 6.1 that 'dma_fence_ops::signaled'
is NULL for certain signaled fence instances.

Change-Id: Ie5e03e849947a9cd2b02fd057ebb44878aa2d0b0
Signed-off-by: Zhen Chen <chenzhen@rock-chips.com>
2024-11-28 19:18:13 +08:00
Jon Lin
f965b5da7c mtd: spi-nor: Add macro definition constraints
Change-Id: I3b35faaea4fad132be18940328e7df88ebdb0dbd
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2024-11-28 18:40:31 +08:00