Skip to content

Conversation

@dcpleung
Copy link
Member

@dcpleung dcpleung commented May 2, 2025

esp32-mp.c calls z_sched_ipi() so it needs to include ksched.h, as it is no longer included via kernel.h after removal of kernel/internal/smp.h.

esp32-mp.c calls z_sched_ipi() so it needs to include ksched.h,
as it is no longer included via kernel.h after removal of
kernel/internal/smp.h.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
@dcpleung dcpleung marked this pull request as ready for review May 2, 2025 16:45
@github-actions github-actions bot added platform: ESP32 Espressif ESP32 size: XS A PR changing only a single line of code labels May 2, 2025
@nashif
Copy link
Member

nashif commented May 2, 2025

hmm, not liking that, we need a better way of doing this that does not involve including ksched.h which is internal to the kernel, but I can see this being included all over the place, SoCs however should not rely on and call private functons. oh well.

@uLipe
Copy link
Member

uLipe commented May 2, 2025

I agree, it would be different if ipi function had a public function, it seems design violation the calling of z_ prefixed functions even though the SoC layer is something reserved for kernel driver foundation.

But since the IPI is a primitive to support SMP, would cases like this sufficient to export a public version of the IPI function call?

@dcpleung
Copy link
Member Author

dcpleung commented May 5, 2025

This is to fix build breakage. So maybe we can merge this and find a better solution later?

Copy link
Member

@uLipe uLipe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Giving my +1 to fix build, I think before proceed we can open an issue to avoid loosing the track.

@kartben kartben merged commit 1f21bb9 into zephyrproject-rtos:main May 6, 2025
26 checks passed
@dcpleung dcpleung deleted the esp32/mp_fix_z_sched_ipi_include branch May 6, 2025 23:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

platform: ESP32 Espressif ESP32 size: XS A PR changing only a single line of code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Build warning for esp32 on tests/kernel/ipi_cascade/kernel.ipi_cascade.smp

7 participants