Commit Graph

1280420 Commits

Author SHA1 Message Date
Tao Huang
d426c0ba92 drm/rockchip: rk618: move from strlcpy with unused retval to strscpy
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Idbc061e99565792b6862a0c0f01e156e41fbe1a9
2025-02-17 19:37:53 +08:00
Tao Huang
0f6c4e8e3f drm/bridge: ite-it6161: move from strlcpy with unused retval to strscpy
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I48b43b7f9ef7f566b3bd87449685968f104ea4ca
2025-02-17 19:37:53 +08:00
Tao Huang
4184ec9569 clk: rockchip: regmap: move from strlcpy with unused retval to strscpy
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: If7d70555f4928df1e25632c79a8a376a5adb6d95
2025-02-17 19:37:53 +08:00
LiuDiMing Lin
49582e84e8 iio: imu: inv_icm42670: add low pass filter bandwidth control
Add sysfs interface to control the low-pass filter bandwidth for both
accelerometer and gyroscope.

Change-Id: I7eb0617476b9aa984276ab5a98f50e32e17d4721
Signed-off-by: LiuDiMing Lin <fenrir.lin@rock-chips.com>
2025-02-17 09:29:14 +00:00
LiuDiMing Lin
6661c2e73f iio: imu: inv_icm42670: get pts and read data in the same interrupt
Change-Id: I5742e31acf6d2c2c73c0b1e802ae38ba6a9fb31e
Signed-off-by: LiuDiMing Lin <fenrir.lin@rock-chips.com>
2025-02-17 09:28:59 +00:00
Ding Wei
a752728b0f arm64: dts: rockchip: rk3528: Add iommu shared bitmask for iep and vdpp
The drivers which use shared iommu, bitmask need xor BIT(DRIVER_TYPE), and DRIVER_TYPE
is defined in mpp_common.h. Such as, avsd、vdpu、iep add vdpp use share iommu, then
bitmask = BIT(DRIVER_VDPU1) | BIT(DRIVER_VDPU2) | BIT(DRIVER_IEP2) | BIT(DRIVER_VDPP).

Change-Id: Ifc8de7422eaa11ba33e9f5e93e4f4b094207a72e
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2025-02-17 08:42:18 +00:00
Tao Huang
50dac60158 video: rockchip: mpp: Fix missing prototypes
drivers/video/rockchip/mpp/hack/mpp_rkvdec2_hack_rk3568.c:677:6: error: no previous prototype for function 'rkvdec2_3568_hack_data_setup' [-Werror,-Wmissing-prototypes]
drivers/video/rockchip/mpp/hack/mpp_rkvdec2_hack_rk3568.c:703:6: error: no previous prototype for function 'rkvdec2_3568_hack_fix' [-Werror,-Wmissing-prototypes]
drivers/video/rockchip/mpp/hack/mpp_rkvdec2_link_hack_rk3568.c:184:6: error: no previous prototype for function 'rkvdec2_3568_hack_fix_link' [-Werror,-Wmissing-prototypes]
drivers/video/rockchip/mpp/hack/mpp_rkvdec2_link_hack_rk3568.c:189:6: error: no previous prototype for function 'rkvdec2_link_hack_data_setup' [-Werror,-Wmissing-prototypes]

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Idf6d3b4602ba2c7f8313e6335908ce0870f7f89b
2025-02-16 17:31:04 +08:00
Tao Huang
c7e6ad2ebd soc: rockchip: fiq_debugger: Fix missing prototypes
drivers/soc/rockchip/fiq_debugger/fiq_debugger_arm64.c:45:6: error: no previous prototype for function 'fiq_debugger_dump_regs_aarch32' [-Werror,-Wmissing-prototypes]
drivers/soc/rockchip/fiq_debugger/fiq_debugger_arm64.c:64:6: error: no previous prototype for function 'fiq_debugger_dump_regs_aarch64' [-Werror,-Wmissing-prototypes]

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ie44867116113a460c55e6884f51c3671854d7aa2
2025-02-16 17:24:45 +08:00
Tao Huang
f303a7ae61 input: touchscreen: parade: Fix missing prototypes
drivers/input/touchscreen/parade/pt_core.c:10623:5: error: no previous prototype for function '_pt_request_pip2_enter_bl' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:10872:5: error: no previous prototype for function '_pt_pip2_file_open' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:10920:5: error: no previous prototype for function '_pt_pip2_file_close' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:10968:5: error: no previous prototype for function '_pt_pip2_file_erase' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:11039:5: error: no previous prototype for function '_pt_pip2_file_read' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:11081:5: error: no previous prototype for function '_pt_read_us_file' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:11174:5: error: no previous prototype for function '_pt_request_pip2_bin_hdr' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:11312:5: error: no previous prototype for function '_pt_pip2_file_get_stats' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:11381:5: error: no previous prototype for function '_pt_pip2_file_seek_offset' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:11436:5: error: no previous prototype for function '_pt_pip2_file_crc' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:11484:5: error: no previous prototype for function 'pt_pip2_ping_test' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:611:6: error: no previous prototype for function 'pt_toggle_err_gpio' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:634:6: error: no previous prototype for function '_pt_request_toggle_err_gpio' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:6667:5: error: no previous prototype for function '_pt_request_active_pip_protocol' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:8465:13: error: no previous prototype for function 'pt_irq' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:9064:5: error: no previous prototype for function 'pt_pip2_exit_bl_' [-Werror,-Wmissing-prototypes]
drivers/input/touchscreen/parade/pt_core.c:9201:5: error: no previous prototype for function 'pt_pip2_exit_bl' [-Werror,-Wmissing-prototypes]

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ic932fcb8acec2084d36812ac82d6a877ff5a7ca7
2025-02-16 17:20:44 +08:00
Tao Huang
cadbe57dae input: sensors: gyro: ewtsa: Fix missing prototypes
drivers/input/sensors/gyro/ewtsa.c:281:6: error: no previous prototype for function 'gyro_dev_reset' [-Werror,-Wmissing-prototypes]

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I95932a5cfbb38cd0f5019d965accfd3d07f79000
2025-02-16 17:07:36 +08:00
Tao Huang
36aa04158c cpufreq: interactive: Fix missing prototypes
drivers/cpufreq/cpufreq_interactive.c:1372:5: error: no previous prototype for function 'cpufreq_interactive_init' [-Werror,-Wmissing-prototypes]
drivers/cpufreq/cpufreq_interactive.c:1463:6: error: no previous prototype for function 'cpufreq_interactive_exit' [-Werror,-Wmissing-prototypes]
drivers/cpufreq/cpufreq_interactive.c:1498:5: error: no previous prototype for function 'cpufreq_interactive_start' [-Werror,-Wmissing-prototypes]
drivers/cpufreq/cpufreq_interactive.c:1525:6: error: no previous prototype for function 'cpufreq_interactive_stop' [-Werror,-Wmissing-prototypes]
drivers/cpufreq/cpufreq_interactive.c:1543:6: error: no previous prototype for function 'cpufreq_interactive_limits' [-Werror,-Wmissing-prototypes]

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I83452d8e7acb41ff4a33a0f9c261208e72c8dad9
2025-02-16 17:03:38 +08:00
Tao Huang
262ca119bb clk: rockchip: rv1106: use rk_dump_cru
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I8883e40bdac895eb5732086ca6a2a2d2483b7b40
2025-02-16 16:59:07 +08:00
Tao Huang
e63a35287a clk: rockchip: rv1126: use rk_dump_cru
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I57cbb13a3932019d5f3ed0e9ff0004445859568f
2025-02-16 16:57:48 +08:00
Tao Huang
83b8c79513 clk: rockchip: rk1808: use rk_dump_cru
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ie722a46cda47673804c0d7ae65d80b8dfab5eeca
2025-02-16 16:54:19 +08:00
Tao Huang
ba2bbad231 clk: rockchip: rk3399: use rk_dump_cru
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Id2c9d84d3ca6a6444fdec0bc2f37b3a9216f1b74
2025-02-16 16:52:54 +08:00
Guochun Huang
042b41bb3c drm/rockchip: dsi2: disable BTA during auto calculation training
when DSI operates in auto calculation mode,it sends a dsc read
get_scanline request to the peripheral devices to automatically
calculate phy_max_rd_time_auto during the auto calculation training.
However,if the peripheral devices,such as a bridge chip or some panel,
lack the capability to respond to read-back requests,they cannot respond
to the DSI host’s BTA,leading to the signal control not being properly
returned to the DSI host,Therefore,the BTA function should be disabled
in such case.

Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
Change-Id: Iddac487ade3de49e73594e92ad2f7b537ddf2335
2025-02-16 06:51:15 +00:00
Wesley Yao
0e331cdb70 iio: dac: rockchip-flexbus-dac: Set fb0_isr after init_completion
Prevent panic caused by the completion not being initialized when the
interrupt is triggered.

Change-Id: I375d38505e1375983e74eadcf957b1d928bee355
Signed-off-by: Wesley Yao <wesley.yao@rock-chips.com>
2025-02-15 14:26:23 +08:00
Wesley Yao
483595ae11 iio: adc: rockchip-flexbus-adc: Set fb1_isr after init_completion
Prevent panic caused by the completion not being initialized when the
interrupt is triggered.

Change-Id: I797b0ea28a1b04744b0a64d77c00bd5590987420
Signed-off-by: Wesley Yao <wesley.yao@rock-chips.com>
2025-02-15 14:26:23 +08:00
Zhang Yubing
5209cde33a rockchip/drm: drv: use upstream method to get crtc for encoder
Here are exist a drm framework api to get crtc for encoder. It's
better to use drm framework api which will also reduce work when
kernel upgrade in the future. To compatible with GKI, moving these
api in the rockchip_drm_drv.c.

The upstream commit has been merge in linux kernel 6.4 and the
commit info as follow:
Commit: 7b9a9e35e4 ("drm: add helper functions to retrieve old and new crtc")
Patchwork: https://patchwork.freedesktop.org/patch/524718/
Link: https://lore.kernel.org/r/1677774797-31063-2-git-send-email-quic_vpolimer@quicinc.com

Change-Id: I1d36e22e3389a372e5aadbf8d55410c643f2a005
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2025-02-14 11:16:11 +00:00
Damon Ding
4cb1325d1a drm/rockchip: analogix_dp: add the comments for parameters format_yuv and max_bpc
Fixes: a7620fa846 ("drm/rockchip: analogix_dp: add support for color format yuv444/yuv422")
Change-Id: I9f7f498f8c3cf6399142430a9ee984c0f110c2b8
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-02-14 10:28:31 +00:00
Aurelien Jarno
c982349ece UPSTREAM: Revert "mmc: dw_mmc: Fix IDMAC operation with pages bigger than 4K"
The commit 8396c793ffdf ("mmc: dw_mmc: Fix IDMAC operation with pages
bigger than 4K") increased the max_req_size, even for 4K pages, causing
various issues:
- Panic booting the kernel/rootfs from an SD card on Rockchip RK3566
- Panic booting the kernel/rootfs from an SD card on StarFive JH7100
- "swiotlb buffer is full" and data corruption on StarFive JH7110

At this stage no fix have been found, so it's probably better to just
revert the change.

This reverts commit 8396c793ffdf28bb8aee7cfe0891080f8cab7890.

Change-Id: I2d48fd9cf412726cf578ed141e1ebafc20856e8f
Cc: stable@vger.kernel.org
Cc: Sam Protsenko <semen.protsenko@linaro.org>
Fixes: 8396c793ffdf ("mmc: dw_mmc: Fix IDMAC operation with pages bigger than 4K")
Closes: https://lore.kernel.org/linux-mmc/614692b4-1dbe-31b8-a34d-cb6db1909bb7@w6rz.net/
Closes: https://lore.kernel.org/linux-mmc/CAC8uq=Ppnmv98mpa1CrWLawWoPnu5abtU69v-=G-P7ysATQ2Pw@mail.gmail.com/
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Message-ID: <20241110114700.622372-1-aurelien@aurel32.net>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Yu Zheng <yu.zheng@rock-chips.com>
(cherry picked from commit 1635e407a4a64d08a8517ac59ca14ad4fc785e75)
2025-02-14 17:42:40 +08:00
Shawn Lin
2c48d055bc mmc: dw_mmc-rockchip: Add memory clock auto-gating support
Per design recommendation, memory clock could be gate if no transfer is
on-flight which could help save power. This feature is introduced along
with internal phase support. This patch enables the feature.

Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Change-Id: I36b90a17742da63f229e61167277bbbdc676695b
2025-02-14 09:28:12 +00:00
Sugar Zhang
fb7c7cd51d ALSA: info: Fix memleak on bind/unbind situation
Fixes: fa7c9cc3cb ("ALSA: info: Fix potential deadlock at disconnection")

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I8fcd099745b6a193fdca362a445331a0ff663706
2025-02-14 02:43:34 +00:00
Huang zhibao
7b9bbf0f0e input: rc: Unify the process of requesting irq for PWM v1-v4
The irq for PWM v1-v3 used to be exclusively associated with oneshot
mode.

Signed-off-by: Huang zhibao <hzb@rock-chips.com>
Change-Id: I6bdb8a176929965675b96ef8310f5f0097a339d6
2025-02-13 08:49:11 +00:00
Zhihuan He
17d414b998 ARM: dts: rockchip: rk3506: Fix coding style for dsmc node
Change-Id: I0b7b65fc6bec0f9edd6cb76a2daac0e3bbde0de9
Signed-off-by: Zhihuan He <huan.he@rock-chips.com>
2025-02-13 07:42:10 +00:00
Zhihuan He
49b1e1b320 memory: rockchip: dsmc: Fix conditional compilation for multiple platforms
Change-Id: Ie6e574c3a95aa7c467b3706c3dfb02ed2306efe3
Signed-off-by: Zhihuan He <huan.he@rock-chips.com>
2025-02-13 07:35:59 +00:00
Ye Zhang
6b0986d083 arm64: dts: rockchip: rk3576: update interrupts for GPIO
Signed-off-by: Ye Zhang <ye.zhang@rock-chips.com>
Change-Id: Idf24facbf72f80d8cda1299b6e7e7bb017ff3b11
2025-02-13 11:12:24 +08:00
Zhang Yubing
35fa27dbcf usb: typec: tcpci_husb311: tcpm reset when resume with dp alt mode
For some Type-C to DP Adapter, It need reset tcpm state when resume
To avoid some thing wrong with display appear.

Change-Id: Ie23d62ded05cdbc438cd354c5b886ddc45210b42
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2025-02-13 03:06:00 +00:00
Zain Wang
684040993b power: supply: charger: add sc89601 charger driver
Change-Id: I504f598906fda580401bddf4cc7b33af633a8762
Signed-off-by: Zain Wang <wzz@rock-chips.com>
2025-02-13 03:02:16 +00:00
Weixin Zhou
a6e74a930c soc: rockchip: pm_config: fix virtual poweroff for gki
Change-Id: Ic43d8beb893493302e2b2738afbd529e47f346f0
Signed-off-by: Weixin Zhou <zwx@rock-chips.com>
2025-02-13 02:54:13 +00:00
Elaine Zhang
acacadfb54 can: rk3576_canfd: move devm_request_irq to the end of probe
move devm_request_irq() to the end of this function to
make sure rcan and napi is initialized.

Change-Id: I160447fe4f45dedffde9c97f1aa1df536baccb77
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2025-02-11 12:03:07 +00:00
Andy Yan
e7b6ef1e32 drm/rockchip: vvop: Rename to vkms
This driver simulate includes not only the display controller but
also the connector and encoder, name it to vkms as how vmwgfx/amd
name this kind of driver.

Change-Id: If56614c41973549e2120912c91569af27820b15d
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
2025-02-11 11:34:13 +00:00
Chaoyi Chen
48980901a1 drm/rockchip: vop: Add dclk rate count for RK3576
RK3576 supports calculating the exact dclk from the known hclk rate.

Change-Id: I06f3f59118bc6627b9bb92d0e9aedf1848e5c72c
Signed-off-by: Chaoyi Chen <chaoyi.chen@rock-chips.com>
2025-02-11 11:28:12 +00:00
Algea Cao
ff7af21e33 drm/rockchip: dw_hdmi: Support get hdr10 plus vsdb
Add drm property HDR10_PLUS_VSDB that hdr10 plus data
in edid:

struct hdr10_plus_vsdb {
	u8 application_version;
	u8 full_frame_peak_luminance_index;
	u8 peak_luminance_index;
};

Change-Id: I464cb67e0d9784df905bf34fd8472f80a6b98296
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
2025-02-11 11:25:09 +00:00
San Mehat
734aea1cce ARM: process: Add display of memory around registers when displaying regs.
This is extremely useful in diagnosing remote crashes, and is based heavily
on original work by <md@google.com>.

Signed-off-by: San Mehat <san@google.com>
Cc: Michael Davidson <md@google.com>

[ARM] process: Use uber-safe probe_kernel_address() to read mem when dumping.

This prevents the dump from taking pagefaults / external aborts.

Signed-off-by: San Mehat <san@google.com>
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Change-Id: I7586677c4ea0e064b5a38c7972102db3b5771500
2025-02-11 11:24:40 +00:00
Damon Ding
a8677e8afa drm/rockchip: vop2: remove the plane number check in vop2_plane_mask_check()
The &vop2_data.nr_layers represents the max number of planes that can
be assigned to one VP. Therefore, when checking the max plane number for
VOP2, it may be incorrect to use the &vop2_data.nr_layers.

And the comparison of assigned plane_mask with &vop2_data.plane_mask_base
can already confirm whether every plane has been assigned to one of all
the VPs.

Fixes: 00424a589d ("drm/rockchip: vop2: add support to assign plane mask by default")
Change-Id: I9c2056dea42897150ef155c7e6fd0ad3a43c8132
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-02-11 11:20:02 +00:00
Damon Ding
57231d9636 drm/rockchip: vop2: rename plane name conversion functions and move them more forward
Since &vop2_win.plane_id means the unique plane id based on the
initialization order of planes in vop2_win_init(), it may be better
to rename vop2_plane_id_to_string() to vop2_plane_phys_id_to_string()
based on the definition of &vop2_win.phys_id.

And the movement can help to make more plane related logs more
readable.

Change-Id: If5d362817fc147cbd3a21f67ea44a8c0814899df
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-02-11 11:19:58 +00:00
Damon Ding
12f0cb6431 drm/rockchip: vop2: not to create plane_mask property of CRTC for VOP3
RK3528/RK3562/RK3576 use the VOP3 architecture, which supports
flexible switching of planes between different VPs. User can switch
planes between different CRTCs based on the &drm_plane.possible_crtcs
in userspace, so the 'PLANE_MASK' property is not required.

Change-Id: Icbd75bc4602fcfd69a10f2be9f5a8375bd7f2abe
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-02-11 11:19:50 +00:00
Damon Ding
591e580fcd drm/rockchip: vop2: add cycles_per_pixel check for both rgb and mcu interfaces
The RGB interface also supports formats that have multiple cycles per
pixel, such as MEDIA_BUS_FMT_RGB888_3X8, MEDIA_BUS_FMT_RGB565_2X8_LE,
and so on. And the &drm_display_mode.crtc_clock should be multiplied by
the return value of rockchip_drm_get_cycles_per_pixel().

Fixes: 3cb261be89 ("drm/rockchip: drv: fix the dclk calculation of mcu interface")
Change-Id: Idbb6f6ef2ac17dc0dd63d67519733dbd1e29e9dd
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-02-11 16:35:45 +08:00
Damon Ding
825560b30c drm/rockchip: vop: add cycles_per_pixel check for both rgb and mcu interfaces
The RGB interface also supports formats that have multiple cycles per
pixel, such as MEDIA_BUS_FMT_RGB888_3X8, MEDIA_BUS_FMT_RGB565_2X8_LE,
and so on. And the &drm_display_mode.crtc_clock should be multiplied by
the return value of rockchip_drm_get_cycles_per_pixel().

Fixes: 3cb261be89 ("drm/rockchip: drv: fix the dclk calculation of mcu interface")
Change-Id: I85c0168ccfaedbf5566a2c6b8f86e881fbc93ad0
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-02-11 16:28:47 +08:00
Cai YiWei
e6270f2d22 media: rockchip: isp: fix bilinear scale no output if unite mode
Change-Id: Ic8ea66fdde4b139d961803e16fab2481dd72355a
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2025-02-11 06:10:32 +00:00
Tao Huang
596e50f65e Revert "Wifi: add rtl8723au & rtl8723bu wifi support."
This reverts commit 522c0bb37a.

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I92b585b8eff58cd585717d0dffda7701f1875a5e
2025-02-11 06:09:47 +00:00
Algea Cao
cbb33e40aa drm/rockchip: vop2: Ensure rk3576 sharp/post-scaler/split are mutually exclusive
VOP sharp/post-scaler/split use the same line buffer.
They must be mutually exclusive, otherwise the picture
will display abnormally.

Change-Id: Ia8e7877826bf2a4484a4060ea4d704a2edc611c3
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
2025-02-10 12:19:47 +00:00
Ding Wei
8f25f9d7c3 arm64: dts: rockchip: rk3528: Add iommu shared bitmask for avsd and vdpu
Change-Id: I42807997f85e9e43c2a7f490fd9af7c87b30fec6
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2025-02-10 16:15:29 +08:00
Ding Wei
a6943befb9 video: rockchip: mpp: fix share iommu issue for rk3528 on Arch32
Issue:
1. On arm32 platform iommu use the mapping->domain, while use the
   group->domain on arm64 platform.
2. __iommu_attach_group use group->default to judge whether new device
   in kernel 5.10 branch, while use group->domain in kernel 6.1 branch.
   For this change, when two devices share the iommu, the first device
   attach success, while the second device failed in kernel 6.1 branch.

Method:
1. Set driver_managed_dma=true to ensure that during the IOMMU probe
phase,
   even if attach group failed, the mapping will not be released.
2. After the IOMMU probe succeeds, record info->domain=mapping->domain
and
   detach it, ensuring that group->domain is set to NULL. This prevents
the
   next device which sharing the IOMMU, not return -EBUSY when attach
the
   group.
3. Before hardware running, the shared IOMMU should check whether the
   device has been switched. If so, it needs to attach the current
   device's info->domain.
4. When removing a shared IOMMU, it must also ensure that group->domain
   corresponds to the current device.

Change-Id: If0fec01a0bcf9c49850129bfa5ac28484fece9a2
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2025-02-10 16:15:29 +08:00
Tao Huang
f346f25228 Revert "power: add universal charger driver support"
This reverts commit 9f2ddf5a0c.

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I56ad273f1da0a8d55a0e53a010a3b3c680212e7f
2025-02-10 06:15:48 +00:00
Simon Xue
e5ecfb7289 iio: adc: rockchip_saradc: fix crash cause by saradc
fix the crash caused by interrupt occurring before info->last_chan is ready

Change-Id: I6a57d49d5af6fb35708e009c33422ad936af0d3f
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2025-02-10 06:15:15 +00:00
Simon Xue
bb5e238d4f iio: adc: rockchip_saradc: fix the variable naming conflict
fix the variable naming conflict with "lock" when CONFIG_ROCKCHIP_SARADC_TEST_CHN enabled

Change-Id: I9f2925fb6e4be642cacf8e5d5c764e33d13b9cc4
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2025-02-10 06:15:15 +00:00
Damon Ding
3ae279210e drm/bridge: analogix_dp: add support for ASSR mode
According to the eDP v1.3 chapter 3.6 Table 3-15, Alternative
Scramble Seed Reset(ASSR) is a recommended way for eDP Sink devices
to support Display Authentication and Content Protection as Method
3a, while Method 1 HDCP is normally not expected in an eDP Sink
device.

In addition, the ASSR support capability should be the bit 0 of
DPCD register 0000Dh according to the eDP v1.4 'Revision History'
table 2:

......
Table 3-4: Corrected reference to DPCD Address 0000Dh, bit 0 (was bit 4)
......

Change-Id: Iafad97755fd4c9e688c47164d099b290af905036
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
2025-02-10 06:10:07 +00:00
Abel Vesa
8281b215f4 UPSTREAM: phy: Add Embedded DisplayPort and DisplayPort submodes
In some cases, a DP PHY needs to be configured to work in eDP mode.
So add submodes for both DP and eDP so they can be used by the
controllers for specifying the mode the PHY should be configured in.

Change-Id: I130b491edcf2624697489b18a3ab24add535840f
Signed-off-by: Abel Vesa <abel.vesa@linaro.org>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Link: https://lore.kernel.org/r/20240324-x1e80100-phy-edp-compatible-refactor-v5-1-a0db5f3150bc@linaro.org
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
(cherry picked from commit 368d67dab4cc4a3ffd39fbd062b2f5796cdbb37b)
2025-02-10 06:10:07 +00:00