Commit Graph

1368844 Commits

Author SHA1 Message Date
Philipp Stanner
1bf30a4565 drm/nouveau: Remove surplus struct member
struct nouveau_channel contains the member 'accel_done' and a forgotten
TODO which hints at that mechanism being removed in the "near future".
Since that variable is read nowhere anymore, this "near future" is now.

Remove the variable and the TODO.

Signed-off-by: Philipp Stanner <phasta@kernel.org>
Link: https://lore.kernel.org/r/20250801074531.79237-2-phasta@kernel.org
Signed-off-by: Danilo Krummrich <dakr@kernel.org>
2025-08-09 13:13:43 +02:00
Seyediman Seyedarab
6510b62fe9 drm/nouveau: replace snprintf() with scnprintf() in nvkm_snprintbf()
snprintf() returns the number of characters that *would* have been
written, which can overestimate how much you actually wrote to the
buffer in case of truncation. That leads to 'data += this' advancing
the pointer past the end of the buffer and size going negative.

Switching to scnprintf() prevents potential buffer overflows and ensures
consistent behavior when building the output string.

Signed-off-by: Seyediman Seyedarab <ImanDevel@gmail.com>
Link: https://lore.kernel.org/r/20250724195913.60742-1-ImanDevel@gmail.com
Signed-off-by: Danilo Krummrich <dakr@kernel.org>
2025-08-09 12:20:46 +02:00
Lizhi Hou
d2b48f2b30 accel/amdxdna: Unify pm and rpm suspend and resume callbacks
The suspend and resume callbacks for pm and runtime pm should be same.
During suspending, it needs to stop all hardware contexts first. And
the hardware contexts will be restarted after the device is resumed.

Reviewed-by: Mario Limonciello (AMD) <superm1@kernel.org>
Reviewed-by: Maciej Falkowski <maciej.falkowski@linux.intel.com>
Signed-off-by: Lizhi Hou <lizhi.hou@amd.com>
Link: https://lore.kernel.org/r/20250803191450.1568851-1-lizhi.hou@amd.com
2025-08-06 10:31:55 -07:00
Joseph Guo
dbdea37add drm: bridge: Add waveshare DSI2DPI unit driver
Waveshare touchscreen consists of a DPI panel and a driver board.
The waveshare driver board consists of ICN6211 and a MCU to
convert DSI to DPI and control the backlight.
This driver treats the MCU and ICN6211 board as a whole unit.
It can support all resolution waveshare DSI2DPI based panel,
the timing table should come from 'panel-dpi' panel in the device tree.

Signed-off-by: Joseph Guo <qijian.guo@nxp.com>
Suggested-by: Liu Ying <victor.liu@nxp.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250806-waveshare-v3-3-fd28e01f064f@nxp.com
2025-08-06 08:49:33 +02:00
Joseph Guo
80b0eb11f8 dt-bindings: display: panel: Add waveshare DPI panel support
Add dt-binding documentation for waveshare DPI panel

Signed-off-by: Joseph Guo <qijian.guo@nxp.com>
Suggested-by: Liu Ying <victor.liu@nxp.com>
Acked-by: Rob Herring (Arm) <robh@kernel.org>
Acked-by: Liu Ying <victor.liu@nxp.com>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250806-waveshare-v3-2-fd28e01f064f@nxp.com
2025-08-06 08:49:33 +02:00
Joseph Guo
01048738d6 dt-bindings: display: bridge: Add waveshare DSI2DPI unit support
Add dt-binding documentation for waveshare DSI2DPI unit

Signed-off-by: Joseph Guo <qijian.guo@nxp.com>
Suggested-by: Liu Ying <victor.liu@nxp.com>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Acked-by: Liu Ying <victor.liu@nxp.com>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250806-waveshare-v3-1-fd28e01f064f@nxp.com
2025-08-06 08:49:32 +02:00
Hugo Villeneuve
cf9710a0a2 drm/panel: sitronix-st7703: fix typo in comments
Fix typo in comments:
    souch -> such.

Signed-off-by: Hugo Villeneuve <hvilleneuve@dimonoff.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250721152818.1891212-1-hugo@hugovil.com
2025-08-04 17:33:45 +02:00
Chen Ni
05efa7f1d1 drm/panel: himax-hx8279: Remove unneeded semicolon
Remove unnecessary semicolons reported by Coccinelle/coccicheck and the
semantic patch at scripts/coccinelle/misc/semicolon.cocci.

Signed-off-by: Chen Ni <nichen@iscas.ac.cn>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250729054214.2264377-1-nichen@iscas.ac.cn
2025-08-04 17:30:03 +02:00
Brigham Campbell
125459e19e drm/panel: novatek-nt35560: Fix invalid return value
Fix bug in nt35560_set_brightness() which causes the function to
erroneously report an error. mipi_dsi_dcs_write() returns either a
negative value when an error occurred or a positive number of bytes
written when no error occurred. The buggy code reports an error under
either condition.

Fixes: 8152c2bfd7 ("drm/panel: Add driver for Sony ACX424AKP panel")
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Brigham Campbell <me@brighamcampbell.com>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250731032343.1258366-2-me@brighamcampbell.com
2025-08-04 17:29:38 +02:00
Svyatoslav Ryhel
fdb4e289d2 drm: panel: Add support for Hydis HV101HD1 MIPI DSI panel
HV101HD1-1E1 is a color active matrix TFT LCD module using amorphous
silicon TFT's (Thin Film Transistors) as an active switching devices. This
module has a 10.1 inch diagonally measured active area with HD resolutions
(1366 horizontal by 768 vertical pixel array).

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Reviewed-by: David Heidelberg <david@ixit.cz>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250717135752.55958-3-clamor95@gmail.com
2025-08-04 17:28:50 +02:00
Svyatoslav Ryhel
bd068333ef dt-bindings: display: panel: Document Hydis HV101HD1 DSI panel
Hydis HV101HD1 is a 2-lane 1366x768 MIPI DSI panel found in ASUS VivoTab RT
TF600T tablet.

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250717135752.55958-2-clamor95@gmail.com
2025-08-04 17:28:49 +02:00
Akhilesh Patil
640d512caa drm: panel: orisetech: improve error handling during probe
Use dev_err_probe() helper as directed by core driver model to handle
driver probe error. Use standard helper defined at drivers/base/core.c
to maintain code consistency.

Inspired by,
commit a787e5400a ("driver core: add device probe log helper")

Signed-off-by: Akhilesh Patil <akhilesh@ee.iitb.ac.in>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/aIJagJ/RnhSCtb2t@bhairav-test.ee.iitb.ac.in
2025-08-04 17:28:29 +02:00
Colin Ian King
368ea3f33f drm/panel: Kconfig: Fix spelling mistake "pannel" -> "panel"
There is a spelling mistake in the LEDS_BD2606MVV config. Fix it.

Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250724112358.142351-1-colin.i.king@gmail.com
2025-08-04 17:26:58 +02:00
Kaustabh Chakraborty
47d7953d8e drm: panel: add support for Samsung AMS561RA01 panel with S6E8AA5X01 controller
Samsung AMS561RA01 is an AMOLED panel, using the Samsung S6E8AA5X01 MIPI
DSI controller. Implement a basic panel driver for such panels.

The driver also initializes a backlight device, which works by changing
the panel's gamma values and aid brightness levels appropriately, with
the help of look-up tables acquired from downstream kernel sources.

Signed-off-by: Kaustabh Chakraborty <kauschluss@disroot.org>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250721-panel-samsung-s6e8aa5x01-v5-2-1a315aba530b@disroot.org
2025-08-04 17:26:29 +02:00
Kaustabh Chakraborty
f3e1caef59 dt-bindings: display: panel: document Samsung AMS561RA01 panel with S6E8AA5X01 controller
Samsung AMS561RA01 is an AMOLED panel, using the Samsung S6E8AA5X01 MIPI
DSI panel controller. Document the compatible and devicetree properties
of this hardware. It has a reset GPIO and two voltage regulators.

Acked-by: Conor Dooley <conor.dooley@microchip.com>
Signed-off-by: Kaustabh Chakraborty <kauschluss@disroot.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250721-panel-samsung-s6e8aa5x01-v5-1-1a315aba530b@disroot.org
2025-08-04 17:25:18 +02:00
Paul Kocialkowski
2623278007 drm/panel: simple: Add Olimex LCD-OLinuXino-5CTS support
Add support for the Olimex LCD-OLinuXino-5CTS, a 5-inch TFT LCD panel
with a mode operating at 33.3 MHz.

Signed-off-by: Paul Kocialkowski <paulk@sys-base.io>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250702082230.1291953-2-paulk@sys-base.io
2025-08-04 17:24:24 +02:00
Paul Kocialkowski
1da71a0808 dt-bindings: display: simple: Add Olimex LCD-OLinuXino-5CTS
Add the Olimex LCD-OLinuXino-5CTS, a 5-inch TFT LCD panel.

Signed-off-by: Paul Kocialkowski <paulk@sys-base.io>
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250702082230.1291953-1-paulk@sys-base.io
2025-08-04 17:24:23 +02:00
Brigham Campbell
d9c1b06f35 accel/rocket: Fix undeclared const rocket_pm_ops
Fix sparse warning regarding an undeclared const rocket_pm_ops, which is
used in rocket_drv.c.

Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202508030021.uwdr4P08-lkp@intel.com/
Signed-off-by: Brigham Campbell <me@brighamcampbell.com>
Signed-off-by: Tomeu Vizoso <tomeu@tomeuvizoso.net>
Link: https://lore.kernel.org/r/20250802-fix-rockchip-npu-build-v1-2-fb0f0dacb3fe@brighamcampbell.com
2025-08-03 17:40:23 +02:00
Brigham Campbell
218b15a3e9 accel/rocket: Fix Rockchip NPU compilation
Replace DRM_GPU_SCHED_STAT_NOMINAL with GPU_DRM_SCHED_STAT_RESET, in
accordance with commit 0a5dc1b67e ("drm/sched: Rename
DRM_GPU_SCHED_STAT_NOMINAL to DRM_GPU_SCHED_STAT_RESET")

Pass extra parameter to drm_sched_job_init, as required by commit
2956554823 ("drm/sched: Store the drm client_id in drm_sched_fence")

Signed-off-by: Brigham Campbell <me@brighamcampbell.com>
Signed-off-by: Tomeu Vizoso <tomeu@tomeuvizoso.net>
Link: https://lore.kernel.org/r/20250802-fix-rockchip-npu-build-v1-1-fb0f0dacb3fe@brighamcampbell.com
2025-08-03 17:40:23 +02:00
Aleksandrs Vinarskis
82928cc1c2 drm/panel-edp: Add BOE NV140WUM-N64
Timings taken from NV140WUM-N41. It is found in some arm64 laptops,
eg. Asus Zenbook A14 UX3407QA.

The raw edid of the panel is:
00 ff ff ff ff ff ff 00 09 e5 f6 0c 00 00 00 00
10 22 01 04 a5 1e 13 78 07 8e 95 a6 52 4c 9d 26
0f 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 5d 30 80 a0 70 b0 28 40 30 20
36 00 2e bc 10 00 00 1a 00 00 00 fd 00 28 3c 4a
4a 0f 01 0a 20 20 20 20 20 20 00 00 00 fe 00 3d
4c 33 30 20 20 20 20 20 20 20 20 ff 00 00 00 fc
00 4e 56 31 34 30 57 55 4d 2d 4e 36 34 0a 01 f8

70 20 79 02 00 21 00 1d c8 0b 5d 07 80 07 b0 04
88 66 ea 51 cc 74 9d 66 52 0f 02 35 54 40 5e 40
5e 00 44 12 78 22 00 14 7f 5c 02 85 7f 07 9f 00
2f 00 1f 00 af 04 27 00 02 00 05 00 2b 00 0c 27
00 28 3b 00 00 27 00 28 2f 00 00 2e 00 06 00 44
40 5e 40 5e 81 00 1e 72 1a 00 00 03 71 28 3c 00
00 60 ff 60 ff 3c 00 00 00 00 e3 05 04 00 e6 06
01 01 60 60 ff 00 00 00 00 00 00 00 00 00 de 90

Signed-off-by: Aleksandrs Vinarskis <alex.vinarskis@gmail.com>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20250731215635.206702-4-alex.vinarskis@gmail.com
2025-07-31 15:22:08 -07:00
Aleksandrs Vinarskis
d7c2aad125 dt-bindings: display: panel: samsung,atna40ct06: document ATNA40CT06
The Samsung ATNA40CT06 panel is a 14" AMOLED eDP panel. It is
similar to the ATNA33XC20 except that it is larger and has a
different resolution. It is found in some arm64 laptops, eg.
Asus Zenbook A14 UX3407QA.

Raw panel edid:

00 ff ff ff ff ff ff 00 4c 83 0d 42 00 00 00 00
00 22 01 04 b5 1e 13 78 02 0c f1 ae 52 3c b9 23
0c 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 42 3c 80 a0 70 b0 24 40 30 20
88 00 2e bd 10 00 00 1b 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
00 41 54 4e 41 34 30 43 54 30 36 2d 30 20 01 7d

70 20 79 02 00 20 00 0c 4c 83 00 0d 42 00 00 00
00 00 22 00 21 00 1d ca 0b 5e 07 80 07 b0 04 00
e1 fa 51 cb 13 b9 3d d2 0c 01 45 54 40 5e d0 60
18 10 23 78 26 00 09 07 06 03 00 00 00 50 00 00
22 00 14 8d 5a 02 85 7f 07 9f 00 2f 00 1f 00 af
04 23 00 07 00 07 00 81 00 0b e3 05 80 00 e6 06
05 01 74 60 02 2e 00 06 00 45 40 5e d0 60 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 b0 90

Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Aleksandrs Vinarskis <alex.vinarskis@gmail.com>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20250731215635.206702-3-alex.vinarskis@gmail.com
2025-07-31 15:21:37 -07:00
Aleksandrs Vinarskis
d680a7959b dt-bindings: display: panel: samsung,atna40cu11: document ATNA40CU11
The Samsung ATNA40CU11 panel is a 14" AMOLED eDP panel. It is
similar to the ATNA33XC20 except that it is larger and has a
different resolution. It is found in some arm64 laptops, eg.
Asus Zenbook A14 UX3407RA.

Raw panel edid:

00 ff ff ff ff ff ff 00 4c 83 9d 41 00 00 00 00
00 20 01 04 b5 1e 13 78 03 cf d1 ae 51 3e b6 23
0b 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 cb fe 40 64 b0 08 38 77 20 08
88 00 2e bd 10 00 00 1b 00 00 00 fd 00 30 78 da
da 42 01 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fe
00 41 54 4e 41 34 30 43 55 31 31 2d 30 20 01 2a

70 20 79 02 00 20 00 0c 4c 83 00 9d 41 00 00 00
00 00 20 00 21 00 1d b8 0b 6c 07 40 0b 08 07 00
ee ea 50 ec d3 b6 3d 42 0b 01 45 54 40 5e d0 60
18 10 23 78 26 00 09 07 06 03 00 00 00 50 00 00
22 00 14 e7 f3 09 85 3f 0b 63 00 1f 00 07 00 07
07 17 00 07 00 07 00 81 00 1f 73 1a 00 00 03 03
30 78 00 a0 74 02 60 02 78 00 00 00 00 8d e3 05
80 00 e6 06 05 01 74 60 02 00 00 00 00 00 91 90

Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Aleksandrs Vinarskis <alex.vinarskis@gmail.com>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20250731215635.206702-2-alex.vinarskis@gmail.com
2025-07-31 15:21:36 -07:00
Cong Yang
518867b093 drm/panel-edp: Add edp panels used by mt8189 Chromebooks
Add a few generic edp panels used by mt8189 chromebooks, most of
them use the same general enable timing 50ms. For BOE-NV116WHM-N4B and
BOE-NV116WHM-T01 CMN-N140JCA-ELP the enable timing required 80ms. For
CMN-N116BCA-EAK, the enable timing required 200ms and disable timing
required 50ms. For CMN-N116BCL-EAK and CMN-N122JCA-ENK the enable timing
required 80ms and disable timing required 50ms. For TMA-TL140VDMS03-01,
the enable timing required 50ms and the disable timing required 100ms.

AUO B122UAN01.0:
edid-decode (hex):
00 ff ff ff ff ff ff 00 06 af a4 04 00 00 00 00
31 20 01 04 a5 1a 10 78 03 54 c5 9d 54 55 8f 25
22 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 fa 3c 80 b8 70 b0 24 40 10 10
3e 00 06 a4 10 00 00 18 00 00 00 fd 00 28 3c 4b
4b 10 01 0a 20 20 20 20 20 20 00 00 00 fe 00 41
55 4f 0a 20 20 20 20 20 20 20 20 20 00 00 00 fe
00 42 31 32 32 55 41 4e 30 31 2e 30 20 0a 01 7c

AUO B116XAK02.0:
edid-decode (hex):

00 ff ff ff ff ff ff 00 06 af b0 52 00 00 00 00
2e 21 01 04 95 1a 0e 78 03 5b 35 9f 59 55 8e 26
25 50 54 00 00 00 01 01 01 01
01 01 01 01 01 01
01 01 01 01 01 01 5d 1c 56 a0 50 00 19 30 30 20
46 00 00 90 10 00 00 18 00 00 00 fd 00 28 3c 30
30 07 01 0a 20 20 20 20 20 20 00 00 00 fe 00 41
55 4f 0a 20 20 20 20 20 20 20 20 20 00 00 00 fe
00 42 31 31 36 58 41 4b 30 32 2e 30 20 0a 00 bd

AUO B140UAN08.5:
edid-decode (hex):

00 ff ff ff ff ff ff 00 06 af ba 8b 00 00 00 00
10 23 01 04 a5 1e 13 78 03 7c f2 90 57 59 93 29
1d 51 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 26 3d 80 b8 70 b0 28 40 10 10
3e 00 2d bc 10 00 00 18 00 00 00 fd 00 28 3c 4b
4b 10 01 0a 20 20 20 20 20 20 00 00 00 fe 00 41
55 4f 0a 20 20 20 20 20 20 20 20 20 00 00 00 fc
00 42 31 34 30 55 41 4e 30 38 2e 35 20 0a 01 29

70 20 79 02 00 22 00 14 7b 63 02 85 7f 07 b7 00
0f 80 0f 00 af 04 27 00 02 00 0d 00 25 01 09 7b
63 02 7b 63 02 28 3c 80 2b 00 0c 27 00 28 3b 00
00 27 00 28 3b 00 00 81 00 15 74 1a 00 00 03 01
28 3c 00 00 60 51 60 51 3c 00 00 00 00 8d 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 31 90

AUO B140UAX01.2:
edid-decode (hex):

00 ff ff ff ff ff ff 00 06 af ba cd 00 00 00 00
32 23 01 04 a5 1e 13 78 02 ca 31 9b 5c 58 8d 26
21 4f 52 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 60 3f 80 a0 70 b0 64 40 30 20
96 00 2d bc 10 00 00 18 00 00 00 fd 00 28 3c 4e
4e 10 01 0a 20 20 20 20 20 20 00 00 00 fe 00 41
55 4f 0a 20 20 20 20 20 20 20 20 20 00 00 00 fc
00 42 31 34 30 55 41 58 30 31 2e 32 20 0a 00 46

BOE NV116WHM-N4B:
edid-decode (hex):
00 ff ff ff ff ff ff 00 09 e5 45 0d 00 00 00 00
1f 22 01 04 95 1a 0e 78 03 0b 55 9a 5f 58 95 28
1e 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 09 1e 56 dc 50 00 28 30 30 20
36 00 00 90 10 00 00 1a 00 00 00 fd 00 28 3c 30
30 08 01 0a 20 20 20 20 20 20 00 00 00 fe 00 42
4f 45 20 43 51 0a 20 20 20 20 20 20 00 00 00 fc
00 4e 56 31 31 36 57 48 4d 2d 4e 34 42 0a 01 c1

70 20 79 02 00 81 00 15 74 1a 00 00 03 01 28 3c
00 00 4b 51 4b 51 3c 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 65 90

BOE NV116WHM-T01:
edid-decode (hex):

00 ff ff ff ff ff ff 00 09 e5 df 0d 00 00 00 00
01 1c 01 04 95 1a 0e 78 0a 81 15 96 59 5a 9a 29
1f 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 6b 1b 56 64 50 00 1e 30 26 18
44 00 00 90 10 00 00 1a ef 15 56 64 50 00 1e 30
26 18 44 00 00 90 10 00 00 00 00 00 00 fe 00 42
4f 45 20 48 46 0a 20 20 20 20 20 20 00 00 00 fe
00 4e 56 31 31 36 57 48 32 2d 4d 30 30 0a 00 83

CMN N116BCL-EAK:
edid-decode (hex):

00 ff ff ff ff ff ff 00 0d ae 5f 11 00 00 00 00
08 22 01 04 95 1a 0e 78 03 46 a5 9c 5b 53 8b 24
1d 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 e6 1e 56 e2 50 00 3c 30 30 20
a6 00 00 90 10 00 00 1a 00 00 00 fd 00 28 3c 32
32 08 01 0a 20 20 20 20 20 20 00 00 00 fe 00 43
4d 4e 0a 20 20 20 20 20 20 20 20 20 00 00 00 fe
00 4e 31 31 36 42 43 4c 2d 45 41 4b 0a 20 01 9b

70 20 79 02 00 25 01 09 fc 34 01 fc 34 01 28 3c
80 81 00 10 72 1a 00 00 03 01 28 3c 00 00 00 00
00 00 3c 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 2f 90

CMN N122JCA-ENK:
edid-decode (hex):

00 ff ff ff ff ff ff 00 0d ae 4c 12 00 00 00 00
11 20 01 04 a5 1a 10 78 03 0a f5 9e 5c 52 8b 24
1e 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 42 3c 80 a0 70 b0 24 40 30 20
a6 00 06 a4 10 00 00 18 00 00 00 fd 00 28 3c 4a
4a 10 01 0a 20 20 20 20 20 20 00 00 00 fe 00 43
4d 4e 0a 20 20 20 20 20 20 20 20 20 00 00 00 fe
00 4e 31 32 32 4a 43 41 2d 45 4e 4b 0a 20 00 fd

CMN N140JCA-ELP:
edid-decode (hex):
00 ff ff ff ff ff ff 00 0d ae a8 14 00 00 00 00
1d 23 01 04 a5 1e 13 78 03 28 65 97 59 54 8e 27
1e 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 42 3c 80 a0 70 b0 24 40 30 20
a6 00 2d bc 10 00 00 18 00 00 00 fd 00 28 3c 4a
4a 10 01 0a 20 20 20 20 20 20 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
00 4e 31 34 30 4a 43 41 2d 45 4c 50 0a 20 01 c2

70 20 79 02 00 25 01 09 94 5a 02 94 5a 02 28 3c
80 81 00 15 74 1a 00 00 03 01 28 3c 00 00 00 00
00 00 3c 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 aa 90

CMN N116BCA-EAK:
edid-decode (hex):
00 ff ff ff ff ff ff 00 0d ae 02 74 00 00 00 00
2a 22 01 04 95 1a 0e 78 03 67 75 98 59 53 90 27
1c 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 da 1d 56 e2 50 00 20 30 30 20
a6 00 04 8c 10 00 00 1a 00 00 00 fd 00 28 3c 30
30 08 01 0a 20 20 20 20 20 20 00 00 00 fe 00 43
4d 4e 0a 20 20 20 20 20 20 20 20 20 00 00 00 fe
00 4e 31 31 36 42 43 41 2d 45 41 4b 0a 20 00 ba

CSW MNE007QS5-2:
edid-decode (hex):
00 ff ff ff ff ff ff 00 0e 77 62 14 00 00 00 00
10 23 01 04 a5 1e 13 78 03 1c 2e 93 5f 58 95 28
1f 4f 58 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 ea 3d 80 c8 70 b0 2e 40 30 20
36 00 2e bc 10 00 00 1a 00 00 00 fd 00 28 3c 4b
4b 10 01 0a 20 20 20 20 20 20 00 00 00 fe 00 43
53 4f 54 20 54 39 0a 20 20 20 20 20 00 00 00 fc
00 4d 4e 45 30 30 37 51 53 35 2d 32 0a 20 01 8e

70 20 79 02 00 81 00 15 74 1a 00 00 03 01 28 3c
00 00 00 00 00 00 3c 00 00 00 00 80 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 1d 90

CSW MNE007QB2-2:
edid-decode (hex):
00 ff ff ff ff ff ff 00 0e 77 68 14 00 00 00 00
00 23 01 04 a5 1e 13 78 03 90 e0 90 5e 59 86 25
14 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 35 3c 80 a0 70 b0 23 40 30 20
36 00 2d bc 10 00 00 18 00 00 00 fd 00 28 3c 4a
4a 10 01 0a 20 20 20 20 20 20 00 00 00 fc 00 4d
4e 46 33 30 37 51 42 32 2d 32 0a 20 00 00 00 fe
00 43 53 4f 54 20 54 33 0a 20 20 20 20 20 00 9a

TMA TM140VDXP01-04:
edid-decode (hex):

00 ff ff ff ff ff ff 00 51 a1 11 08 00 00 00 00
1a 22 01 04 a5 1e 13 78 03 83 3d 98 5b 57 8d 28
1f 4e 53 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 6d 3d 80 a0 70 b0 3c 40 30 20
36 00 2d bc 10 00 00 1a 00 00 00 10 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 fd 00 28
3c 4c 4c 10 01 0a 20 20 20 20 20 20 00 00 00 fc
00 54 4d 31 34 30 56 44 58 50 30 31 0a 20 01 f7

70 20 79 02 00 25 00 09 41 66 02 41 66 02 28 3c
80 81 00 14 73 1a 00 00 03 01 28 3c 00 00 00 00
00 00 3c 00 00 00 00 8d 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 ae 90

TMA TL140VDMS03-01:
edid-decode (hex):

00 ff ff ff ff ff ff 00 51 a1 94 20 00 00 00 00
0b 23 01 04 a5 1e 13 78 03 47 5a 9e 53 5e 8b 28
23 54 53 00 00 00 01 01 01 01 01 01 01 01 01 01
01 01 01 01 01 01 03 3e 80 a0 70 b0 48 40 30 20
66 0c 2e bd 10 00 00 1e 00 00 00 fd 00 28 3c 4d
4d 10 01 0a 20 20 20 20 20 20 00 00 00 10 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
00 54 4c 31 34 30 56 44 4d 53 30 33 0a 20 01 9c

70 20 79 02 00 20 00 0c 00 00 00 94 20 00 00 00
00 0b 19 00 21 00 1d c8 0b 5d 07 80 07 b0 04 00
48 c9 55 48 a5 90 7b 42 21 02 45 54 00 00 00 00
00 00 12 78 26 00 09 02 00 00 00 00 00 01 00 00
2b 00 06 04 00 28 3b 00 00 81 00 14 73 1a 00 00
03 01 28 3c 00 00 00 00 00 00 3c 00 00 00 00 8d
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 ae 90

Signed-off-by: Cong Yang <yangcong5@huaqin.corp-partner.google.com>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20250731105939.2692654-1-yangcong5@huaqin.corp-partner.google.com
2025-07-31 13:12:13 -07:00
Robert Mader
934452cbb1 drm/vkms: Add writeback encoders as possible clones
Since commit 41b4b11da0 ("drm: Add valid clones check") setting
the `possible_clones` values is a hard requirement for cloning.
`vkms` supports cloning for writeback connectors in order to capture
CRTC content, however that broke with said commit.

Writeback connectors are created on a per-CRTC basis, thus mark
every non-writeback connector that is compatible with a given CRTC
as possible clone - and vice-versa.

Using a default configuration, the corresponding `drm_info` output
changes from:

├───Encoders
│   ├───Encoder 0
│   │   ├───Object ID: 40
│   │   ├───Type: virtual
│   │   ├───CRTCS: {0}
│   │   └───Clones: {0}
│   └───Encoder 1
│       ├───Object ID: 41
│       ├───Type: virtual
│       ├───CRTCS: {0}
│       └───Clones: {1}

into:

├───Encoders
│   ├───Encoder 0
│   │   ├───Object ID: 44
│   │   ├───Type: virtual
│   │   ├───CRTCS: {0}
│   │   └───Clones: {0, 1}
│   └───Encoder 1
│       ├───Object ID: 50
│       ├───Type: virtual
│       ├───CRTCS: {0}
│       └───Clones: {0, 1}

Fixes: dbd9d80c1b ("drm/vkms: Add support for writeback")
Signed-off-by: Robert Mader <robert.mader@collabora.com>
Reviewed-by: Louis Chauvet <louis.chauvet@bootlin.com>
Link: https://lore.kernel.org/r/20250718121442.490634-1-robert.mader@collabora.com
[fixed Fixes line and changed to: to into: to avoid checkpatch warnings]
Signed-off-by: Louis Chauvet <louis.chauvet@bootlin.com>
2025-07-31 16:29:59 +02:00
Svyatoslav Ryhel
55023abe6a drm: bridge: Add support for Solomon SSD2825 RGB/DSI bridge
SSD2825 is a cost-effective MIPI Bridge Chip solution targeting mainly
smartphones. It can convert 24bit RGB interface into 4-lane MIPI-DSI
interface to drive display modules of up to 800 x 1366, while supporting
AMOLED, a-si LCD or LTPS panel technologies for smartphone applications.

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20250730055424.6718-3-clamor95@gmail.com
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
2025-07-31 00:21:31 +03:00
Svyatoslav Ryhel
784c99331c dt-bindings: display: bridge: Document Solomon SSD2825
Add bindings for Solomon SSD2825 MIPI master bridge chip that connects an
application processor with traditional parallel LCD interface and an LCD
driver with MIPI slave interface. The SSD2825 supports both parallel RGB
interface and serial SPI interface.

Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20250730055424.6718-2-clamor95@gmail.com
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
2025-07-31 00:21:31 +03:00
Brigham Campbell
85c23f2890 drm: docs: Update task from drm TODO list
Update TODO item from drm documentation to contain more applicable
information regarding the removal of deprecated MIPI DSI functions and
no longer reference functions which have already been removed from the
kernel.

Reviewed-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Brigham Campbell <me@brighamcampbell.com>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20250722015313.561966-5-me@brighamcampbell.com
2025-07-29 08:31:34 -07:00
Brigham Campbell
79b6bb18f8 drm: Remove unused MIPI write seq and chatty functions
Remove the deprecated mipi_dsi_generic_write_seq() and
mipi_dsi_generic_write_chatty() functions now that they are no longer
used.

Reviewed-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Brigham Campbell <me@brighamcampbell.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20250722015313.561966-4-me@brighamcampbell.com
2025-07-29 08:28:58 -07:00
Brigham Campbell
a6adf47d30 drm/panel: jdi-lpm102a188a: Fix bug and clean up driver
Fix bug in unprepare() which causes the function's return value to be
that of the last mipi "enter sleep mode" command.

Update driver to use the "multi" variant of MIPI functions in order to
facilitate improved error handling and remove the panel's dependency on
deprecated MIPI functions.

Use the new mipi_dsi_dual macro to reduce code duplication.

Reviewed-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Diogo Ivo <diogo.ivo@tecnico.ulisboa.pt>
Tested-by: Diogo Ivo <diogo.ivo@tecnico.ulisboa.pt>
Signed-off-by: Brigham Campbell <me@brighamcampbell.com>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20250722015313.561966-3-me@brighamcampbell.com
2025-07-29 08:28:41 -07:00
Brigham Campbell
d94a2a00d2 drm: Create mipi_dsi_dual* macros
Create mipi_dsi_dual, mipi_dsi_dual_dcs_write_seq_multi, and
mipi_dsi_dual_generic_write_seq_multi macros for panels which are driven
by two parallel serial interfaces. This allows for the reduction of code
duplication in drivers for these panels.

Remove mipi_dsi_dual_dcs_write_seq_multi definition from
panel-novatek-nt36523.c to avoid the duplicate definition. Make novatek
driver pass mipi_dsi_context struct as a pointer.

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: Brigham Campbell <me@brighamcampbell.com>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20250722015313.561966-2-me@brighamcampbell.com
2025-07-29 08:28:08 -07:00
Colin Ian King
33f8f321e7 drm/vmwgfx: fix missing assignment to ts
The assignment to ts is missing on the call to ktime_to_timespec64.
Fix this by adding the missing assignment.

Fixes: db6a94b263 ("drm/vmwgfx: Implement dma_fence_ops properly")
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Reviewed-by: Ian Forbes <ian.forbes@broadcom.com>
Signed-off-by: Zack Rusin <zack.rusin@broadcom.com>
Link: https://lore.kernel.org/r/20250623223526.281398-1-colin.i.king@gmail.com
2025-07-28 08:51:16 -04:00
Tomeu Vizoso
a7352c8494 dt-bindings: npu: rockchip,rknn: Add bindings
Add the bindings for the Neural Processing Unit IP from Rockchip.

v2:
- Adapt to new node structure (one node per core, each with its own
  IOMMU)
- Several misc. fixes from Sebastian Reichel

v3:
- Split register block in its constituent subblocks, and only require
  the ones that the kernel would ever use (Nicolas Frattaroli)
- Group supplies (Rob Herring)
- Explain the way in which the top core is special (Rob Herring)

v4:
- Change required node name to npu@ (Rob Herring and Krzysztof Kozlowski)
- Remove unneeded items: (Krzysztof Kozlowski)
- Fix use of minItems/maxItems (Krzysztof Kozlowski)
- Add reg-names to list of required properties (Krzysztof Kozlowski)
- Fix example (Krzysztof Kozlowski)

v5:
- Rename file to rockchip,rk3588-rknn-core.yaml (Krzysztof Kozlowski)
- Streamline compatible property (Krzysztof Kozlowski)

v6:
- Remove mention to NVDLA, as the hardware is only incidentally related
  (Kever Yang)
- Mark pclk and npu clocks as required by all clocks (Rob Herring)

v7:
- Remove allOf section, not needed now that all nodes require 4 clocks
  (Heiko Stübner)

v8:
- Remove notion of top core (Robin Murphy)

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Tomeu Vizoso <tomeu@tomeuvizoso.net>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Signed-off-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250721-6-10-rocket-v9-6-77ebd484941e@tomeuvizoso.net
2025-07-25 10:07:31 -06:00
Tomeu Vizoso
525ad89dd9 accel/rocket: Add IOCTLs for synchronizing memory accesses
The NPU cores have their own access to the memory bus, and this isn't
cache coherent with the CPUs.

Add IOCTLs so userspace can mark when the caches need to be flushed, and
also when a writer job needs to be waited for before the buffer can be
accessed from the CPU.

Initially based on the same IOCTLs from the Etnaviv driver.

v2:
- Don't break UABI by reordering the IOCTL IDs (Jeff Hugo)

v3:
- Check that padding fields in IOCTLs are zero (Jeff Hugo)

v6:
- Fix conversion logic to make sure we use DMA_BIDIRECTIONAL when needed
  (Lucas Stach)

v8:
- Always sync BOs in both directions (Robin Murphy)

Reviewed-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Tomeu Vizoso <tomeu@tomeuvizoso.net>
Signed-off-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250721-6-10-rocket-v9-5-77ebd484941e@tomeuvizoso.net
2025-07-25 10:04:46 -06:00
Tomeu Vizoso
0810d5ad88 accel/rocket: Add job submission IOCTL
Using the DRM GPU scheduler infrastructure, with a scheduler for each
core.

Userspace can decide for a series of tasks to be executed sequentially
in the same core, so SRAM locality can be taken advantage of.

The job submission code was initially based on Panfrost.

v2:
- Remove hardcoded number of cores
- Misc. style fixes (Jeffrey Hugo)
- Repack IOCTL struct (Jeffrey Hugo)

v3:
- Adapt to a split of the register block in the DT bindings (Nicolas
  Frattaroli)
- Make use of GPL-2.0-only for the copyright notice (Jeff Hugo)
- Use drm_* logging functions (Thomas Zimmermann)
- Rename reg i/o macros (Thomas Zimmermann)
- Add padding to ioctls and check for zero (Jeff Hugo)
- Improve error handling (Nicolas Frattaroli)

v6:
- Use mutexes guard (Markus Elfring)
- Use u64_to_user_ptr (Jeff Hugo)
- Drop rocket_fence (Rob Herring)

v7:
- Assign its own IOMMU domain to each client, for isolation (Daniel
  Stone and Robin Murphy)

v8:
- Use reset lines to reset the cores (Robin Murphy)
- Use the macros to compute the values for the bitfields (Robin Murphy)
- More descriptive name for the IRQ (Robin Murphy)
- Simplify job interrupt handing (Robin Murphy)
- Correctly acquire a reference to the IOMMU (Robin Murphy)
- Specify the size of the embedded structs in the IOCTLs for future
  extensibility (Rob Herring)
- Expose only 32 bits for the address of the regcmd BO (Robin Murphy)

Tested-by: Heiko Stuebner <heiko@sntech.de>
Reviewed-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Signed-off-by: Tomeu Vizoso <tomeu@tomeuvizoso.net>
Signed-off-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250721-6-10-rocket-v9-4-77ebd484941e@tomeuvizoso.net
2025-07-25 10:02:27 -06:00
Tomeu Vizoso
658ebeac33 accel/rocket: Add IOCTL for BO creation
This uses the SHMEM DRM helpers and we map right away to the CPU and NPU
sides, as all buffers are expected to be accessed from both.

v2:
- Sync the IOMMUs for the other cores when mapping and unmapping.

v3:
- Make use of GPL-2.0-only for the copyright notice (Jeff Hugo)

v6:
- Use mutexes guard (Markus Elfring)

v7:
- Assign its own IOMMU domain to each client, for isolation (Daniel
  Stone and Robin Murphy)

v8:
- Correctly acquire a reference to the IOMMU (Robin Murphy)
- Allocate DMA address ourselves with drm_mm (Robin Murphy)
- Use refcount_read (Heiko Stuebner)
- Remove superfluous dma_sync_sgtable_for_device (Robin Murphy)

Reviewed-by: Jeffrey Hugo <quic_jhugo@quicinc.com>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Tomeu Vizoso <tomeu@tomeuvizoso.net>
Signed-off-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250721-6-10-rocket-v9-3-77ebd484941e@tomeuvizoso.net
2025-07-25 10:00:36 -06:00
Tomeu Vizoso
ed98261b41 accel/rocket: Add a new driver for Rockchip's NPU
This initial version supports the NPU as shipped in the RK3588 SoC and
described in the first part of its TRM, in Chapter 36.

This NPU contains 3 independent cores that the driver can submit jobs
to.

This commit adds just hardware initialization and power management.

v2:
- Split cores and IOMMUs as independent devices (Sebastian Reichel)
- Add some documentation (Jeffrey Hugo)
- Be more explicit in the Kconfig documentation (Jeffrey Hugo)
- Remove resets, as these haven't been found useful so far (Zenghui Yu)
- Repack structs (Jeffrey Hugo)
- Use DEFINE_DRM_ACCEL_FOPS (Jeffrey Hugo)
- Use devm_drm_dev_alloc (Jeffrey Hugo)
- Use probe log helper (Jeffrey Hugo)
- Introduce UABI header in a later patch (Jeffrey Hugo)

v3:
- Adapt to a split of the register block in the DT bindings (Nicolas
  Frattaroli)
- Move registers header to its own commit (Thomas Zimmermann)
- Misc. cleanups (Thomas Zimmermann and Jeff Hugo)
- Make use of GPL-2.0-only for the copyright notice (Jeff Hugo)
- PM improvements (Nicolas Frattaroli)

v4:
- Use bulk clk API (Krzysztof Kozlowski)

v6:
- Remove mention to NVDLA, as the hardware is only incidentally related
  (Kever Yang)
- Use calloc instead of GFP_ZERO (Jeff Hugo)
- Explicitly include linux/container_of.h (Jeff Hugo)
- pclk and npu clocks are now needed by all cores (Rob Herring)

v7:
- Assign its own IOMMU domain to each client, for isolation (Daniel
  Stone and Robin Murphy)

v8:
- Kconfig: fix depends to be more explicit about Rockchip, and remove
  superfluous selects (Robin Murphy)
- Use reset lines to reset the cores (Robin Murphy)
- Reference count the module
- Set dma_set_max_seg_size
- Correctly acquire a reference to the IOMMU (Robin Murphy)
- Remove notion of top core (Robin Murphy)

Reviewed-by: Robert Foss <rfoss@kernel.org>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Reviewed-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Signed-off-by: Tomeu Vizoso <tomeu@tomeuvizoso.net>
Signed-off-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250721-6-10-rocket-v9-2-77ebd484941e@tomeuvizoso.net
2025-07-25 09:56:23 -06:00
Tomeu Vizoso
5fc2bfddb0 accel/rocket: Add registers header
A XML file was generated with the data from the TRM, and then this
header was generated from it.

The canonical location for the XML file is the Mesa3D repository.

v3:
- Make use of GPL-2.0-only for the copyright notice (Jeff Hugo)

v8:
- Remove full MIT license blob, to match other files with the same
  licensing arrangement in the kernel

Reviewed-by: Robert Foss <rfoss@kernel.org>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Reviewed-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Signed-off-by: Tomeu Vizoso <tomeu@tomeuvizoso.net>
Signed-off-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250721-6-10-rocket-v9-1-77ebd484941e@tomeuvizoso.net
2025-07-25 09:48:41 -06:00
Carl Vanderlip
c79291f733 MAINTAINERS: Update email address for Carl Vanderlip
Qualcomm is changing open source email address policy.
LKML and other busy mailing lists use the oss.qualcomm.com domain.

Signed-off-by: Carl Vanderlip <carl.vanderlip@oss.qualcomm.com>
Reviewed-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Signed-off-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250721220811.962509-1-carl.vanderlip@oss.qualcomm.com
2025-07-25 09:26:24 -06:00
Chia-I Wu
e48123c607 panthor: dump task pid and comm on gpu errors
It is useful to know which tasks cause gpu errors.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Steven Price <steven.price@arm.com>
Signed-off-by: Steven Price <steven.price@arm.com>
Link: https://lore.kernel.org/r/20250718063816.1452123-4-olvaffe@gmail.com
2025-07-24 13:43:04 +01:00
Chia-I Wu
33b9cb6dcd panthor: save task pid and comm in panthor_group
We would like to report them on gpu errors.

We choose to save the info on panthor_group_create rather than on
panthor_open because, when the two differ, we are more interested in the
task that created the group.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Steven Price <steven.price@arm.com>
Signed-off-by: Steven Price <steven.price@arm.com>
Link: https://lore.kernel.org/r/20250718063816.1452123-3-olvaffe@gmail.com
2025-07-24 13:42:57 +01:00
Chia-I Wu
78ededb610 panthor: set owner field for driver fops
It allows us to get rid of manual try_module_get / module_put.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Steven Price <steven.price@arm.com>
Signed-off-by: Steven Price <steven.price@arm.com>
Link: https://lore.kernel.org/r/20250718063816.1452123-2-olvaffe@gmail.com
2025-07-24 13:42:49 +01:00
Langyan Ye
1511d3c4d2 drm/panel-edp: Add 50ms disable delay for four panels
Add 50ms disable delay for NV116WHM-N49, NV122WUM-N41, and MNC207QS1-1
to satisfy T9+T10 timing. Add 50ms disable delay for MNE007JA1-2
as well, since MNE007JA1-2 copies the timing of MNC207QS1-1.

Specifically, it should be noted that the MNE007JA1-2 panel was added
by someone who did not have the panel documentation, so they simply
copied the timing from the MNC207QS1-1 panel. Adding an extra 50 ms
of delay should be safe.

Fixes: 0547692ac1 ("drm/panel-edp: Add several generic edp panels")
Fixes: 50625eab39 ("drm/edp-panel: Add panel used by T14s Gen6 Snapdragon")
Signed-off-by: Langyan Ye <yelangyan@huaqin.corp-partner.google.com>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20250723072513.2880369-1-yelangyan@huaqin.corp-partner.google.com
2025-07-23 08:59:38 -07:00
Dmitry Baryshkov
92e34a5241 drm/display: bridge-connector: correct CEC bridge pointers in drm_bridge_connector_init
The bridge used in drm_bridge_connector_init() for CEC init does not
correctly point to the required HDMI CEC bridge, which can lead to
errors during CEC initialization.

Fixes: 65a2575a68 ("drm/display: bridge-connector: hook in CEC notifier support")
Fixes: a74288c8de ("drm/display: bridge-connector: handle CEC adapters")
Reported-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Closes: http://lore.kernel.org/r/20250718164156.194702d9@booty/
Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Link: https://lore.kernel.org/r/20250719-fix-cec-bridges-v1-1-a60b1333c87d@oss.qualcomm.com
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
2025-07-23 16:30:26 +03:00
Luca Ceresoli
c571cb70e1 drm/bridge: display-connector: put the bridge obtained by drm_bridge_get_prev_bridge()
The bridge returned by drm_bridge_get_prev_bridge() is refcounted. Put it
when done.

To keep the code clean and future-proof use a scope-based free.

Reviewed-by: Maxime Ripard <mripard@kernel.org>
Link: https://lore.kernel.org/r/20250709-drm-bridge-alloc-getput-drm_bridge_get_prev_bridge-v1-3-34ba6f395aaa@bootlin.com
Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2025-07-23 13:03:53 +02:00
Luca Ceresoli
d4eecb4c24 drm/bridge: select_bus_fmt_recursive(): put the bridge obtained by drm_bridge_get_prev_bridge()
The bridge returned by drm_bridge_get_prev_bridge() is refcounted. Put it
when done.

select_bus_fmt_recursive() has several return points, and ensuring
drm_bridge_put() is always called in the right place would be error-prone
(especially with future changes to the select_bus_fmt_recursive() code) and
make code uglier. Instead use a scope-based free, which is future-proof and
a lot cleaner.

Reviewed-by: Maxime Ripard <mripard@kernel.org>
Link: https://lore.kernel.org/r/20250709-drm-bridge-alloc-getput-drm_bridge_get_prev_bridge-v1-2-34ba6f395aaa@bootlin.com
Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2025-07-23 13:03:53 +02:00
Luca Ceresoli
9b75346e3c drm/bridge: get the bridge returned by drm_bridge_get_prev_bridge()
drm_bridge_get_prev_bridge() returns a bridge pointer that the
caller could hold for a long time. Increment the refcount of the returned
bridge and document it must be put by the caller.

Reviewed-by: Maxime Ripard <mripard@kernel.org>
Link: https://lore.kernel.org/r/20250709-drm-bridge-alloc-getput-drm_bridge_get_prev_bridge-v1-1-34ba6f395aaa@bootlin.com
Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2025-07-23 13:03:53 +02:00
Jacek Lawrynowicz
46c366851a MAINTAINERS: Add new intel_vpu maintainer
Add Karol as a new intel_vpu maintainer.

Reviewed-by: Maciej Falkowski <maciej.falkowski@linux.intel.com>
Reviewed-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>
Signed-off-by: Jacek Lawrynowicz <jacek.lawrynowicz@linux.intel.com>
Link: https://lore.kernel.org/r/20250722100421.500984-1-jacek.lawrynowicz@linux.intel.com
2025-07-23 09:58:06 +02:00
Salah Triki
5982a539cd accel/amdxdna: Delete pci_free_irq_vectors()
The device is managed so pci_free_irq_vectors() is called automatically
no need to do it manually.

Reviewed-by: Jacek Lawrynowicz <jacek.lawrynowicz@linux.intel.com>
Signed-off-by: Salah Triki <salah.triki@gmail.com>
Signed-off-by: Lizhi Hou <lizhi.hou@amd.com>
Link: https://lore.kernel.org/r/aHs8QAfUlFeNp7qL@pc
2025-07-22 09:19:04 -07:00
Lizhi Hou
bd72d4acda accel/amdxdna: Support user space allocated buffer
Enhance DRM_IOCTL_AMDXDNA_CREATE_BO to accept user space allocated
buffer pointer. The buffer pages will be pinned in memory. Unless
the CAP_IPC_LOCK is enabled for the application process, the total
pinned memory can not beyond rlimit_memlock.

Reviewed-by: Jacek Lawrynowicz <jacek.lawrynowicz@linux.intel.com>
Signed-off-by: Lizhi Hou <lizhi.hou@amd.com>
Link: https://lore.kernel.org/r/20250716164414.112091-1-lizhi.hou@amd.com
2025-07-22 08:34:29 -07:00
Luca Ceresoli
956f82e529 drm/probe-helper: put the bridge returned by drm_bridge_chain_get_first_bridge()
The bridge returned by drm_bridge_chain_get_first_bridge() is
refcounted. Put it when done.

Reviewed-by: Maxime Ripard <mripard@kernel.org>
Link: https://lore.kernel.org/r/20250708-drm-bridge-alloc-getput-drm_bridge_chain_get_first_bridge-v9-5-db1ba3df7f58@bootlin.com
Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2025-07-22 13:01:28 +02:00