Initialize adsp-6.18.31-y#3333
Merged
pamolloy merged 85 commits intoMay 21, 2026
Merged
Conversation
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Co-developed-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Co-developed-by: Arturs Artamonovs <Arturs.Artamonovs@analog.com> Signed-off-by: Arturs Artamonovs <Arturs.Artamonovs@analog.com> Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Co-developed-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Co-developed-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Utsav Agarwal <utsav.agarwal@analog.com>
Signed-off-by: Utsav Agarwal <utsav.agarwal@analog.com>
Co-developed-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Only supports the ADZS-SC589-MINI Co-developed-by: Utsav Agarwal <utsav.agarwal@analog.com> Signed-off-by: Utsav Agarwal <utsav.agarwal@analog.com> Co-developed-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Co-developed-by: UtsavAgarwalADI <utsav.agarwal@analog.com> Signed-off-by: UtsavAgarwalADI <utsav.agarwal@analog.com> Co-developed-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Qasim Ijaz <qasim.ijaz@analog.com> Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Utsav Agarwal <utsav.agarwal@analog.com> Signed-off-by: Arturs Artamonovs <arturs.artamonovs@analog.com>
Co-developed-by: Nathan Barrett-Morrison <nathan.morrison@timesys.com> Signed-off-by: Nathan Barrett-Morrison <nathan.morrison@timesys.com> Co-developed-by: Greg Malysa <greg.malysa@timesys.com> Signed-off-by: Greg Malysa <greg.malysa@timesys.com> Signed-off-by: Utsav Agarwal <Utsav.Agarwal@analog.com> Signed-off-by: Arturs Artamonovs <arturs.artamonovs@analog.com> Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Arturs Artamonovs <arturs.artamonovs@analog.com>
Adding SoC audio support for the following modes: - ASoC (linux only audio) - SHARC ALSA (Hybrid Audio) - SHARC Co-developed-by: Utsav Agarwal <utsav.agarwal@analog.com> Signed-off-by: Utsav Agarwal <utsav.agarwal@analog.com> Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Utsav Agarwal <utsav.agarwal@analog.com>
Enable COMPILE_TEST for ADI system configuration and PADS drivers. This allows these drivers to be built on other architectures for testing purposes, increasing build coverage. Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Reconfiguring the partitions in the SPI and OSPI to remove the DTB partition and give the extra space to the rootfs partition. Signed-off-by: Caleb Ethridge <caleb.ethridge@analog.com>
Remove unused button-led device tree nodes from sc573-ezlite, and sc594-som boards. Signed-off-by: Ozan Durgut <ozndrgt@gmail.com>
Removing these hardcoded bootargs since they are not needed, bootargs are passed from U-boot for ADSP platforms. Signed-off-by: Caleb Ethridge <caleb.ethridge@analog.com>
Always fetch from the official public ADI org, even when forked Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Add COMPILE_TEST to SERIAL_ADI_UART4 so CI build jobs can build the driver. Signed-off-by: Qasim Ijaz <qasim.ijaz@analog.com>
Add the missing MODULE_LICENSE() declaration so CI jobs can build the driver. Signed-off-by: Qasim Ijaz <qasim.ijaz@analog.com>
Remove the explicit .owner assignment from adi_uart4_serial_driver to address the coccicheck warning: "No need to set .owner here. The core will do it." Signed-off-by: Qasim Ijaz <qasim.ijaz@analog.com>
Enable early console support for ADI UART4. Currently it is included in the kernel command line arguments for ADSP Linux but not enabled via Kconfig. This makes it so the ADI UART4 driver selects and enables earlycon support by default and will be available as an early console option during boot. Signed-off-by: Brandon Hurst <brandon.hurst@analog.com>
Add device tree support for SC598 HTOL SBC based on the reference board designs. Signed-off-by: Ozan Durgut <ozan.durgut@analog.com>
The driver allocates struct adi_uart4_serial_port with kzalloc() in probe(), but several probe error paths return after the port has been allocated and published in adi_uart4_serial_ports[] without freeing it. Convert the port allocation to devm_kzalloc() so the memory is device managed meaning it is released automatically on probe failure and device detach. While doing that, route the post allocation probe failures through a common error path so adi_uart4_serial_ports[uartid] is cleared before returning. This avoids leaving a stale global port pointer behind after a failed probe. Also move dev_set_drvdata() to the successful uart_add_one_port() path so drvdata is not set for a port that failed to register. This change: - replaces kzalloc() with devm_kzalloc() in probe() - removes the manual kfree() from the probe error path - removes the manual kfree() from adi_uart4_serial_remove() - converts several direct probe returns to use the common cleanup path - renames out_error_unmap to out_error - propagates the devm_clk_get() error with PTR_ERR() - sets drvdata only after uart_add_one_port() succeeds Signed-off-by: Qasim Ijaz <Qasim.Ijaz@analog.com>
The driver requests TX and RX DMA channels during adi_uart4_serial_probe(), but several probe failure paths return without releasing them. Add a common probe cleanup path that releases any successfully requested DMA channels before returning an error. Ensure that alias lookup failure, allocation failure, and post allocation probe failures go through that cleanup path. Signed-off-by: Qasim Ijaz <Qasim.Ijaz@analog.com>
The driver indexes adi_uart4_serial_ports[] using the serial alias id returned by of_alias_get_id(), but does not verify that the id is within the valid port range. Add a bounds check and reject alias ids greater than or equal to ADI_UART_NR_PORTS before indexing the port array. Signed-off-by: Qasim Ijaz <Qasim.Ijaz@analog.com>
SERIAL_ADI_UART4_CONSOLE selects SERIAL_EARLYCON, but only depended on SERIAL_ADI_UART4. This allowed the UART driver and serial core to be built as modules while earlycon was built into vmlinux, causing a link failure: earlycon.c:(.init.text+0x1e0): undefined reference to `uart_parse_earlycon' Require SERIAL_ADI_UART4=y for console support so earlycon is only enabled when the ADI UART4 driver and serial core are built into the kernel. Signed-off-by: Qasim Ijaz <Qasim.Ijaz@analog.com>
adi_uart4_serial_set_termios() applies new termios settings such as
baud rate, parity and stop bits. Before reprogramming the UART
registers, it waits for any active TX to complete so the settings
are not changed mid transfer.
That wait is done while holding a spin lock with interrupts disabled
via spin_lock_irqsave(). The driver has a safety mechanism in the
loop where it waits for a maximum of 10 ms:
timeout = jiffies + msecs_to_jiffies(10);
while (UART_GET_GCTL(uart) & UCEN && !(UART_GET_LSR(uart) & TEMT))
if (time_after(jiffies, timeout)) {
dev_warn(port->dev,
"timeout waiting for TX buffer empty\n");
break;
}
However this approach is problematic because on single core systems,
jiffies may not advance while interrupts are disabled (jiffies
is advanced through timer interrupts), making the timeout approach
unreliable if TX does not drain for some reason.
To confirm this behaviour on single core systems I wrote a small
program to validate if jiffies was being advanced on the
ADSP-SC589-MINI and it did not while holding the spin lock.
Use readl_poll_timeout_atomic() instead, which is suitable for atomic
contexts and is suitable when timekeeping is disabled.
This fix also removes the duplicated TX empty wait loop which seems
to be an accidental copy+paste issue.
Signed-off-by: Qasim Ijaz <Qasim.Ijaz@analog.com>
… in startup gcc-fanalyzer flagged a NULL dereference on `desc` — dmaengine_prep_dma_cyclic() can return NULL and we just blindly assign desc->callback without checking. While fixing that I noticed all the error paths in adi_uart4_serial_startup() are broken too. Every early return after clk_prepare_enable() leaks the clock, and later failures dont clean up DMA buffers or mappings. Fixed by adding goto-based cleanup like upstream does (same pattern as atmel_serial.c). Each failure point now unwinds exactly what was allocated before it. Also added a dev_err so we actually get a log message if cyclic prep fails. Signed-off-by: Vasileios Bimpikas <Vasileios.Bimpikas@analog.com>
- Remove __init from console_setup/get_options. These get called on rebind via register_console and the code was already freed after boot. - Move clk_prepare_enable from startup() to probe() so the clock is on before uart_add_one_port re-registers the console. Without this, console_putchar spins forever on THRE with the clock gated. - Use timer_delete_sync() instead of timer_delete() to avoid use-after-free if the rx timeout handler is still running when we free the DMA buffer. Signed-off-by: Vasileios Bimpikas <vasileios.bimpikas@analog.com>
Synchronize with a14dd7c on xlnx-main including: - Remove paths-ignore for push and pull request triggers - Add the concurrency group with cancel-in-progress: true to optimize resource usage by cancelling redundant runs - Restrict push events to the analogdevicesinc repository owner - Explicitly define read permission for all build and check jobs - Upload to Cloudsmith, which includes SBOM generation - Use the consolidated summary output from dependency jobs - Switch from assert_labels to assert_job_summary - Remove the unused ref_branch input from the checks job Signed-off-by: Philip Molloy <philip.molloy@analog.com>
Signed-off-by: Philip Molloy <philip.molloy@analog.com>
The generic arm and arm64 builds that intelligently enable Kconfig options based on what is changed fail because of issues with how certain ADSP drivers call into arch specific code. To not block all ADSP defconfigs from building make the SC598 EZ-KIT build independent and enable checks for it rather than the generic ARM build. Signed-off-by: Philip Molloy <philip.molloy@analog.com>
gastmaier
approved these changes
May 21, 2026
ozan956
approved these changes
May 21, 2026
gastmaier
reviewed
May 21, 2026
| ret = icap_get_subdevices(icap); | ||
| if (ret < 0) | ||
| dev_err(&sport->pdev->dev, "Get sharc%d devices error: %d", sharc_core, ret); | ||
| return; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
2nd attempt at #3330 since that went a little sideways with CI/CD work