kernel: move syscall_handler.h to internal include directory

Move the syscall_handler.h header, used internally only to a dedicated
internal folder that should not be used outside of Zephyr.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
diff --git a/arch/x86/core/userspace.c b/arch/x86/core/userspace.c
index d087674..2b05820 100644
--- a/arch/x86/core/userspace.c
+++ b/arch/x86/core/userspace.c
@@ -6,7 +6,7 @@
 
 #include <zephyr/kernel.h>
 #include <zephyr/sys/speculation.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <kernel_arch_func.h>
 #include <ksched.h>
 #include <x86_mmu.h>
diff --git a/doc/kernel/drivers/index.rst b/doc/kernel/drivers/index.rst
index e835759..c1a3124 100644
--- a/doc/kernel/drivers/index.rst
+++ b/doc/kernel/drivers/index.rst
@@ -235,7 +235,7 @@
 
    #ifdef CONFIG_USERSPACE
 
-   #include <zephyr/syscall_handler.h>
+   #include <zephyr/internal/syscall_handler.h>
 
    int z_vrfy_specific_from_user(const struct device *dev, int bar)
    {
diff --git a/doc/kernel/usermode/syscalls.rst b/doc/kernel/usermode/syscalls.rst
index af16fbd..2b0abcc 100644
--- a/doc/kernel/usermode/syscalls.rst
+++ b/doc/kernel/usermode/syscalls.rst
@@ -271,7 +271,7 @@
 * Any other arguments that have a limited range of valid values.
 
 Verification functions involve a great deal of boilerplate code which has been
-made simpler by some macros in :zephyr_file:`include/zephyr/syscall_handler.h`.
+made simpler by some macros in :zephyr_file:`include/zephyr/internal/syscall_handler.h`.
 Verification functions should be declared using these macros.
 
 Argument Validation
@@ -630,7 +630,7 @@
 ****
 
 Helper macros for creating system call verification functions are provided in
-:zephyr_file:`include/zephyr/syscall_handler.h`:
+:zephyr_file:`include/zephyr/internal/syscall_handler.h`:
 
 * :c:macro:`Z_SYSCALL_OBJ()`
 * :c:macro:`Z_SYSCALL_OBJ_INIT()`
diff --git a/drivers/adc/adc_handlers.c b/drivers/adc/adc_handlers.c
index cf6319a..184368c 100644
--- a/drivers/adc/adc_handlers.c
+++ b/drivers/adc/adc_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/adc.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/kernel.h>
 
 static inline int z_vrfy_adc_channel_setup(const struct device *dev,
diff --git a/drivers/auxdisplay/auxdisplay_handlers.c b/drivers/auxdisplay/auxdisplay_handlers.c
index 8944b3d..70ba310 100644
--- a/drivers/auxdisplay/auxdisplay_handlers.c
+++ b/drivers/auxdisplay/auxdisplay_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/auxdisplay.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_auxdisplay_display_on(const struct device *dev)
 {
diff --git a/drivers/bbram/bbram_handlers.c b/drivers/bbram/bbram_handlers.c
index 1bc20dc..cd173c6 100644
--- a/drivers/bbram/bbram_handlers.c
+++ b/drivers/bbram/bbram_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/bbram.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_bbram_check_invalid(const struct device *dev)
 {
diff --git a/drivers/cache/cache_handlers.c b/drivers/cache/cache_handlers.c
index 99d7cec..299e67b 100644
--- a/drivers/cache/cache_handlers.c
+++ b/drivers/cache/cache_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/cache.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_sys_cache_data_flush_range(void *addr, size_t size)
 {
diff --git a/drivers/can/can_handlers.c b/drivers/can/can_handlers.c
index 7401a7f..6eff631 100644
--- a/drivers/can/can_handlers.c
+++ b/drivers/can/can_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/can.h>
 
 static int z_vrfy_can_calc_timing(const struct device *dev, struct can_timing *res,
diff --git a/drivers/charger/charger_handlers.c b/drivers/charger/charger_handlers.c
index 7b65824..0f2200e 100644
--- a/drivers/charger/charger_handlers.c
+++ b/drivers/charger/charger_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/charger.h>
 
 static inline int z_vrfy_charger_get_prop(const struct device *dev, const charger_prop_t prop,
diff --git a/drivers/console/uart_mux.c b/drivers/console/uart_mux.c
index ba882b0..ca445a1 100644
--- a/drivers/console/uart_mux.c
+++ b/drivers/console/uart_mux.c
@@ -10,7 +10,7 @@
 #include <zephyr/sys/__assert.h>
 #include <zephyr/kernel.h>
 #include <zephyr/init.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/device.h>
 #include <zephyr/drivers/uart.h>
 #include <zephyr/drivers/console/uart_mux.h>
diff --git a/drivers/counter/counter_handlers.c b/drivers/counter/counter_handlers.c
index a493ea0..10cc2b7 100644
--- a/drivers/counter/counter_handlers.c
+++ b/drivers/counter/counter_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/counter.h>
 
 /* For those APIs that just take one argument which is a counter driver
diff --git a/drivers/counter/maxim_ds3231.c b/drivers/counter/maxim_ds3231.c
index 514ddd3..518f989 100644
--- a/drivers/counter/maxim_ds3231.c
+++ b/drivers/counter/maxim_ds3231.c
@@ -1300,7 +1300,7 @@
 
 #ifdef CONFIG_USERSPACE
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 int z_vrfy_maxim_ds3231_get_syncpoint(const struct device *dev,
 				      struct maxim_ds3231_syncpoint *syncpoint)
diff --git a/drivers/dac/dac_handlers.c b/drivers/dac/dac_handlers.c
index aa66606..7db06ae 100644
--- a/drivers/dac/dac_handlers.c
+++ b/drivers/dac/dac_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/dac.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/kernel.h>
 
 static inline int z_vrfy_dac_channel_setup(const struct device *dev,
diff --git a/drivers/dma/dma_handlers.c b/drivers/dma/dma_handlers.c
index 058cbbf..e826b30 100644
--- a/drivers/dma/dma_handlers.c
+++ b/drivers/dma/dma_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/dma.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 /* Both of these APIs are assuming that the drive implementations are checking
  * the validity of the channel ID and returning -errno if it's bogus
diff --git a/drivers/eeprom/eeprom_handlers.c b/drivers/eeprom/eeprom_handlers.c
index 79e00d3..25aee5d 100644
--- a/drivers/eeprom/eeprom_handlers.c
+++ b/drivers/eeprom/eeprom_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/eeprom.h>
 
 static inline int z_vrfy_eeprom_read(const struct device *dev, off_t offset,
diff --git a/drivers/entropy/entropy_handlers.c b/drivers/entropy/entropy_handlers.c
index 7eb4dcb..3bdff1d 100644
--- a/drivers/entropy/entropy_handlers.c
+++ b/drivers/entropy/entropy_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/entropy.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_entropy_get_entropy(const struct device *dev,
 					     uint8_t *buffer,
diff --git a/drivers/espi/espi_handlers.c b/drivers/espi/espi_handlers.c
index d6800fe..ef90547 100644
--- a/drivers/espi/espi_handlers.c
+++ b/drivers/espi/espi_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/espi.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 
 static inline int z_vrfy_espi_config(const struct device *dev,
diff --git a/drivers/flash/flash_handlers.c b/drivers/flash/flash_handlers.c
index 6d63942..d43a788 100644
--- a/drivers/flash/flash_handlers.c
+++ b/drivers/flash/flash_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/flash.h>
 
 static inline int z_vrfy_flash_read(const struct device *dev, off_t offset,
diff --git a/drivers/flash/flash_npcx_fiu_nor.c b/drivers/flash/flash_npcx_fiu_nor.c
index 6b99e83..a1b2d79 100644
--- a/drivers/flash/flash_npcx_fiu_nor.c
+++ b/drivers/flash/flash_npcx_fiu_nor.c
@@ -14,7 +14,7 @@
 #include <soc.h>
 #ifdef CONFIG_USERSPACE
 #include <zephyr/syscall.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #endif
 
 #include "flash_npcx_fiu_qspi.h"
diff --git a/drivers/flash/flash_simulator.c b/drivers/flash/flash_simulator.c
index 7f753b5..51a8afd 100644
--- a/drivers/flash/flash_simulator.c
+++ b/drivers/flash/flash_simulator.c
@@ -481,7 +481,7 @@
 
 #ifdef CONFIG_USERSPACE
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 void *z_vrfy_flash_simulator_get_memory(const struct device *dev,
 				      size_t *mock_size)
diff --git a/drivers/flash/flash_stm32_ex_op.c b/drivers/flash/flash_stm32_ex_op.c
index 1e2d801..37bf738 100644
--- a/drivers/flash/flash_stm32_ex_op.c
+++ b/drivers/flash/flash_stm32_ex_op.c
@@ -11,7 +11,7 @@
 
 #ifdef CONFIG_USERSPACE
 #include <zephyr/syscall.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #endif
 
 #include <soc.h>
diff --git a/drivers/flash/nrf_qspi_nor.c b/drivers/flash/nrf_qspi_nor.c
index e2ce6e6..a499ec6 100644
--- a/drivers/flash/nrf_qspi_nor.c
+++ b/drivers/flash/nrf_qspi_nor.c
@@ -1464,7 +1464,7 @@
 }
 
 #ifdef CONFIG_USERSPACE
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 void z_vrfy_nrf_qspi_nor_xip_enable(const struct device *dev, bool enable)
 {
diff --git a/drivers/fuel_gauge/emul_fuel_gauge_syscall_handlers.c b/drivers/fuel_gauge/emul_fuel_gauge_syscall_handlers.c
index a6b8ce6..2382fca 100644
--- a/drivers/fuel_gauge/emul_fuel_gauge_syscall_handlers.c
+++ b/drivers/fuel_gauge/emul_fuel_gauge_syscall_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/emul_fuel_gauge.h>
 
 /* Emulator syscalls just need to exist as stubs as these are only called by tests. */
diff --git a/drivers/fuel_gauge/fuel_gauge_syscall_handlers.c b/drivers/fuel_gauge/fuel_gauge_syscall_handlers.c
index 6bcd5bd..8fdb29d 100644
--- a/drivers/fuel_gauge/fuel_gauge_syscall_handlers.c
+++ b/drivers/fuel_gauge/fuel_gauge_syscall_handlers.c
@@ -5,7 +5,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/fuel_gauge.h>
 
 static inline int z_vrfy_fuel_gauge_get_prop(const struct device *dev, fuel_gauge_prop_t prop,
diff --git a/drivers/gpio/gpio_handlers.c b/drivers/gpio/gpio_handlers.c
index ce64fc8..019afff 100644
--- a/drivers/gpio/gpio_handlers.c
+++ b/drivers/gpio/gpio_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/gpio.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_gpio_pin_configure(const struct device *port,
 					    gpio_pin_t pin,
diff --git a/drivers/hwinfo/hwinfo_handlers.c b/drivers/hwinfo/hwinfo_handlers.c
index dd411f2..933e849 100644
--- a/drivers/hwinfo/hwinfo_handlers.c
+++ b/drivers/hwinfo/hwinfo_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/hwinfo.h>
 
 ssize_t z_vrfy_hwinfo_get_device_id(uint8_t *buffer, size_t length)
diff --git a/drivers/hwspinlock/hwspinlock_handlers.c b/drivers/hwspinlock/hwspinlock_handlers.c
index a8e6c2a..8fd8c93 100644
--- a/drivers/hwspinlock/hwspinlock_handlers.c
+++ b/drivers/hwspinlock/hwspinlock_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/hwspinlock.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_hwspinlock_trylock(const struct device *dev, uint32_t id)
 {
diff --git a/drivers/i2c/i2c_handlers.c b/drivers/i2c/i2c_handlers.c
index fca385e..1e5a5ee 100644
--- a/drivers/i2c/i2c_handlers.c
+++ b/drivers/i2c/i2c_handlers.c
@@ -6,7 +6,7 @@
 
 #include <zephyr/drivers/i2c.h>
 #include <string.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_i2c_configure(const struct device *dev,
 				       uint32_t dev_config)
diff --git a/drivers/i2s/i2s_handlers.c b/drivers/i2s/i2s_handlers.c
index e556d70..8e331513 100644
--- a/drivers/i2s/i2s_handlers.c
+++ b/drivers/i2s/i2s_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/i2s.h>
 
 
diff --git a/drivers/i3c/i3c_handlers.c b/drivers/i3c/i3c_handlers.c
index e5a52898..2fa8cff 100644
--- a/drivers/i3c/i3c_handlers.c
+++ b/drivers/i3c/i3c_handlers.c
@@ -6,7 +6,7 @@
 
 #include <zephyr/drivers/i3c.h>
 #include <string.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_i3c_do_ccc(const struct device *dev,
 				    struct i3c_ccc_payload *payload)
diff --git a/drivers/ipm/ipm_handlers.c b/drivers/ipm/ipm_handlers.c
index 647f87c..021d80a 100644
--- a/drivers/ipm/ipm_handlers.c
+++ b/drivers/ipm/ipm_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/ipm.h>
 
 static inline int z_vrfy_ipm_send(const struct device *dev, int wait,
diff --git a/drivers/kscan/kscan_handlers.c b/drivers/kscan/kscan_handlers.c
index b2d36ba..663930b 100644
--- a/drivers/kscan/kscan_handlers.c
+++ b/drivers/kscan/kscan_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/kscan.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_kscan_config(const struct device *dev,
 				      kscan_callback_t callback_isr)
diff --git a/drivers/led/led_handlers.c b/drivers/led/led_handlers.c
index a3a37fb..ecffa05 100644
--- a/drivers/led/led_handlers.c
+++ b/drivers/led/led_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/led.h>
 
 static inline int z_vrfy_led_blink(const struct device *dev, uint32_t led,
diff --git a/drivers/mbox/mbox_handlers.c b/drivers/mbox/mbox_handlers.c
index 55b2b01..f09beab 100644
--- a/drivers/mbox/mbox_handlers.c
+++ b/drivers/mbox/mbox_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/mbox.h>
 
 static inline int z_vrfy_mbox_send(const struct mbox_channel *channel,
diff --git a/drivers/peci/peci_handlers.c b/drivers/peci/peci_handlers.c
index 3914701..758806a 100644
--- a/drivers/peci/peci_handlers.c
+++ b/drivers/peci/peci_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/peci.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 
 static inline int z_vrfy_peci_config(const struct device *dev,
diff --git a/drivers/ps2/ps2_handlers.c b/drivers/ps2/ps2_handlers.c
index 71d1181..a63f893 100644
--- a/drivers/ps2/ps2_handlers.c
+++ b/drivers/ps2/ps2_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/ps2.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_ps2_config(const struct device *dev,
 				    ps2_callback_t callback_isr)
diff --git a/drivers/ptp_clock/ptp_clock.c b/drivers/ptp_clock/ptp_clock.c
index ba0d7e3..8f4c3a1 100644
--- a/drivers/ptp_clock/ptp_clock.c
+++ b/drivers/ptp_clock/ptp_clock.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/ptp_clock.h>
 
 #ifdef CONFIG_USERSPACE
diff --git a/drivers/pwm/pwm_handlers.c b/drivers/pwm/pwm_handlers.c
index 9993b24..f615345 100644
--- a/drivers/pwm/pwm_handlers.c
+++ b/drivers/pwm/pwm_handlers.c
@@ -5,7 +5,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/pwm.h>
 
 static inline int z_vrfy_pwm_set_cycles(const struct device *dev,
diff --git a/drivers/retained_mem/retained_mem_handlers.c b/drivers/retained_mem/retained_mem_handlers.c
index 265ae7b..e69b2ee 100644
--- a/drivers/retained_mem/retained_mem_handlers.c
+++ b/drivers/retained_mem/retained_mem_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/retained_mem.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline ssize_t z_vrfy_retained_mem_size(const struct device *dev)
 {
diff --git a/drivers/rtc/rtc_handlers.c b/drivers/rtc/rtc_handlers.c
index a0e9cb3..28c598f 100644
--- a/drivers/rtc/rtc_handlers.c
+++ b/drivers/rtc/rtc_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/rtc.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_rtc_set_time(const struct device *dev, const struct rtc_time *timeptr)
 {
diff --git a/drivers/sensor/sensor_handlers.c b/drivers/sensor/sensor_handlers.c
index cc1bc84..668bf2d 100644
--- a/drivers/sensor/sensor_handlers.c
+++ b/drivers/sensor/sensor_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/sensor.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_sensor_attr_set(const struct device *dev,
 					 enum sensor_channel chan,
diff --git a/drivers/serial/uart_handlers.c b/drivers/serial/uart_handlers.c
index 1dd4dd7..4f2ac83 100644
--- a/drivers/serial/uart_handlers.c
+++ b/drivers/serial/uart_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/uart.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 #define UART_SIMPLE(op_) \
 	static inline int z_vrfy_uart_##op_(const struct device *dev) \
diff --git a/drivers/sip_svc/sip_smc_intel_socfpga.c b/drivers/sip_svc/sip_smc_intel_socfpga.c
index b4db6d4..09d3517 100644
--- a/drivers/sip_svc/sip_smc_intel_socfpga.c
+++ b/drivers/sip_svc/sip_smc_intel_socfpga.c
@@ -11,7 +11,7 @@
 #include <zephyr/drivers/sip_svc/sip_svc_agilex_mailbox.h>
 #include <zephyr/drivers/sip_svc/sip_svc_agilex_smc.h>
 #include <zephyr/drivers/sip_svc/sip_svc_driver.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 #include <zephyr/logging/log.h>
 
diff --git a/drivers/smbus/smbus_handlers.c b/drivers/smbus/smbus_handlers.c
index 0c97978..a2ed656 100644
--- a/drivers/smbus/smbus_handlers.c
+++ b/drivers/smbus/smbus_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/sys/slist.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/smbus.h>
 
 static inline int z_vrfy_smbus_configure(const struct device *dev,
diff --git a/drivers/spi/spi_handlers.c b/drivers/spi/spi_handlers.c
index 7793d6b..dd1a1eb 100644
--- a/drivers/spi/spi_handlers.c
+++ b/drivers/spi/spi_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/spi.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <string.h>
 
 /* This assumes that bufs and buf_copy are copies from the values passed
diff --git a/drivers/usb/bc12/bc12_handlers.c b/drivers/usb/bc12/bc12_handlers.c
index bf7ff8f..bd578ff 100644
--- a/drivers/usb/bc12/bc12_handlers.c
+++ b/drivers/usb/bc12/bc12_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/usb/usb_bc12.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_bc12_set_role(const struct device *dev, enum bc12_role role)
 {
diff --git a/drivers/virtualization/virt_ivshmem_handlers.c b/drivers/virtualization/virt_ivshmem_handlers.c
index bd49b89..d102a56 100644
--- a/drivers/virtualization/virt_ivshmem_handlers.c
+++ b/drivers/virtualization/virt_ivshmem_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/virtualization/ivshmem.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <string.h>
 
 static inline size_t z_vrfy_ivshmem_get_mem(const struct device *dev,
diff --git a/drivers/w1/w1_handlers.c b/drivers/w1/w1_handlers.c
index 5eac465..a22446a 100644
--- a/drivers/w1/w1_handlers.c
+++ b/drivers/w1/w1_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/w1.h>
 
 static inline int z_vrfy_w1_reset_bus(const struct device *dev)
diff --git a/drivers/watchdog/wdt_handlers.c b/drivers/watchdog/wdt_handlers.c
index 2af0785..8afa81c 100644
--- a/drivers/watchdog/wdt_handlers.c
+++ b/drivers/watchdog/wdt_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/drivers/watchdog.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static inline int z_vrfy_wdt_setup(const struct device *dev, uint8_t options)
 {
diff --git a/include/zephyr/syscall_handler.h b/include/zephyr/internal/syscall_handler.h
similarity index 100%
rename from include/zephyr/syscall_handler.h
rename to include/zephyr/internal/syscall_handler.h
diff --git a/kernel/atomic_c.c b/kernel/atomic_c.c
index ef6e759..a9d2765 100644
--- a/kernel/atomic_c.c
+++ b/kernel/atomic_c.c
@@ -37,7 +37,7 @@
  * forbidden.
  */
 #ifdef CONFIG_USERSPACE
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 #define ATOMIC_SYSCALL_HANDLER_TARGET(name) \
 	static inline atomic_val_t z_vrfy_##name(atomic_t *target) \
diff --git a/kernel/condvar.c b/kernel/condvar.c
index e62fd27..edd895e 100644
--- a/kernel/condvar.c
+++ b/kernel/condvar.c
@@ -9,7 +9,7 @@
 #include <zephyr/toolchain.h>
 #include <ksched.h>
 #include <wait_q.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/init.h>
 
 #ifdef CONFIG_OBJ_CORE_CONDVAR
diff --git a/kernel/device.c b/kernel/device.c
index 8a07e4a..399bd7f 100644
--- a/kernel/device.c
+++ b/kernel/device.c
@@ -9,7 +9,7 @@
 #include <zephyr/sys/atomic.h>
 #include <zephyr/sys/iterable_sections.h>
 #include <zephyr/sys/kobject.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/toolchain.h>
 
 /**
diff --git a/kernel/dynamic.c b/kernel/dynamic.c
index 5215e83..3fea6b6 100644
--- a/kernel/dynamic.c
+++ b/kernel/dynamic.c
@@ -11,7 +11,7 @@
 #include <zephyr/logging/log.h>
 #include <zephyr/sys/bitarray.h>
 #include <zephyr/sys/kobject.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 LOG_MODULE_DECLARE(os, CONFIG_KERNEL_LOG_LEVEL);
 
diff --git a/kernel/errno.c b/kernel/errno.c
index 3786681..645597f 100644
--- a/kernel/errno.c
+++ b/kernel/errno.c
@@ -13,7 +13,7 @@
  */
 
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 /*
  * Define _k_neg_eagain for use in assembly files as errno.h is
diff --git a/kernel/events.c b/kernel/events.c
index 513559c..39ca6fd 100644
--- a/kernel/events.c
+++ b/kernel/events.c
@@ -27,7 +27,7 @@
 #include <zephyr/toolchain.h>
 #include <zephyr/sys/dlist.h>
 #include <zephyr/init.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/tracing/tracing.h>
 #include <zephyr/sys/check.h>
 /* private kernel APIs */
diff --git a/kernel/futex.c b/kernel/futex.c
index 360d2a9..f0f5e5a 100644
--- a/kernel/futex.c
+++ b/kernel/futex.c
@@ -8,7 +8,7 @@
 #include <zephyr/kernel_structs.h>
 #include <zephyr/spinlock.h>
 #include <kswap.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/init.h>
 #include <ksched.h>
 
diff --git a/kernel/mmu.c b/kernel/mmu.c
index 8c742bc..6abd934 100644
--- a/kernel/mmu.c
+++ b/kernel/mmu.c
@@ -12,7 +12,7 @@
 #include <mmu.h>
 #include <zephyr/init.h>
 #include <kernel_internal.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/toolchain.h>
 #include <zephyr/linker/linker-defs.h>
 #include <zephyr/sys/bitarray.h>
diff --git a/kernel/msg_q.c b/kernel/msg_q.c
index 3f56c09..1d5f3af 100644
--- a/kernel/msg_q.c
+++ b/kernel/msg_q.c
@@ -21,7 +21,7 @@
 #include <zephyr/sys/dlist.h>
 #include <zephyr/sys/math_extras.h>
 #include <zephyr/init.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <kernel_internal.h>
 #include <zephyr/sys/check.h>
 
diff --git a/kernel/mutex.c b/kernel/mutex.c
index f94fa43..7759ab5 100644
--- a/kernel/mutex.c
+++ b/kernel/mutex.c
@@ -33,7 +33,7 @@
 #include <wait_q.h>
 #include <errno.h>
 #include <zephyr/init.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/tracing/tracing.h>
 #include <zephyr/sys/check.h>
 #include <zephyr/logging/log.h>
diff --git a/kernel/paging/statistics.c b/kernel/paging/statistics.c
index f101768..8a2d3c6 100644
--- a/kernel/paging/statistics.c
+++ b/kernel/paging/statistics.c
@@ -6,7 +6,7 @@
 
 #include <zephyr/kernel.h>
 #include <kernel_internal.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/toolchain.h>
 #include <zephyr/sys/mem_manage.h>
 
diff --git a/kernel/pipes.c b/kernel/pipes.c
index c19b0e5..b3050b6 100644
--- a/kernel/pipes.c
+++ b/kernel/pipes.c
@@ -17,7 +17,7 @@
 #include <ksched.h>
 #include <wait_q.h>
 #include <zephyr/init.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <kernel_internal.h>
 #include <zephyr/sys/check.h>
 
diff --git a/kernel/poll.c b/kernel/poll.c
index 3727a2b..ed0a996 100644
--- a/kernel/poll.c
+++ b/kernel/poll.c
@@ -20,7 +20,7 @@
 #include <kernel_internal.h>
 #include <wait_q.h>
 #include <ksched.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/sys/dlist.h>
 #include <zephyr/sys/util.h>
 #include <zephyr/sys/__assert.h>
diff --git a/kernel/queue.c b/kernel/queue.c
index 095ea07..d86899c 100644
--- a/kernel/queue.c
+++ b/kernel/queue.c
@@ -18,7 +18,7 @@
 #include <wait_q.h>
 #include <ksched.h>
 #include <zephyr/init.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <kernel_internal.h>
 #include <zephyr/sys/check.h>
 
diff --git a/kernel/sched.c b/kernel/sched.c
index 12393c0..e724ccc 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -10,7 +10,7 @@
 #include <wait_q.h>
 #include <kswap.h>
 #include <kernel_arch_func.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/timer/system_timer.h>
 #include <stdbool.h>
 #include <kernel_internal.h>
diff --git a/kernel/sem.c b/kernel/sem.c
index c411d9b..91d6497 100644
--- a/kernel/sem.c
+++ b/kernel/sem.c
@@ -25,7 +25,7 @@
 #include <zephyr/sys/dlist.h>
 #include <ksched.h>
 #include <zephyr/init.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/tracing/tracing.h>
 #include <zephyr/sys/check.h>
 
diff --git a/kernel/stack.c b/kernel/stack.c
index dc6d1a6..5e00b76 100644
--- a/kernel/stack.c
+++ b/kernel/stack.c
@@ -16,7 +16,7 @@
 #include <wait_q.h>
 #include <zephyr/sys/check.h>
 #include <zephyr/init.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <kernel_internal.h>
 
 #ifdef CONFIG_OBJ_CORE_STACK
diff --git a/kernel/thread.c b/kernel/thread.c
index 4a54fd5..31e2563 100644
--- a/kernel/thread.c
+++ b/kernel/thread.c
@@ -17,7 +17,7 @@
 #include <zephyr/sys_clock.h>
 #include <ksched.h>
 #include <wait_q.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <kernel_internal.h>
 #include <kswap.h>
 #include <zephyr/init.h>
diff --git a/kernel/timeout.c b/kernel/timeout.c
index 339bc65..16429bb 100644
--- a/kernel/timeout.c
+++ b/kernel/timeout.c
@@ -8,7 +8,7 @@
 #include <zephyr/spinlock.h>
 #include <ksched.h>
 #include <timeout_q.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/drivers/timer/system_timer.h>
 #include <zephyr/sys_clock.h>
 
diff --git a/kernel/timer.c b/kernel/timer.c
index 1dc60db..bd69e35 100644
--- a/kernel/timer.c
+++ b/kernel/timer.c
@@ -7,7 +7,7 @@
 #include <zephyr/kernel.h>
 
 #include <zephyr/init.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <stdbool.h>
 #include <zephyr/spinlock.h>
 #include <ksched.h>
diff --git a/kernel/userspace.c b/kernel/userspace.c
index f986544..6a4a65a 100644
--- a/kernel/userspace.c
+++ b/kernel/userspace.c
@@ -13,7 +13,7 @@
 #include <zephyr/sys/sys_io.h>
 #include <ksched.h>
 #include <zephyr/syscall.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/device.h>
 #include <zephyr/init.h>
 #include <stdbool.h>
diff --git a/kernel/userspace_handler.c b/kernel/userspace_handler.c
index ec59ca5..ea0d761 100644
--- a/kernel/userspace_handler.c
+++ b/kernel/userspace_handler.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/kernel_structs.h>
 #include <zephyr/toolchain.h>
 
diff --git a/lib/libc/arcmwdt/libc-hooks.c b/lib/libc/arcmwdt/libc-hooks.c
index b7ee5f9..223c740 100644
--- a/lib/libc/arcmwdt/libc-hooks.c
+++ b/lib/libc/arcmwdt/libc-hooks.c
@@ -7,7 +7,7 @@
 
 #include <stdio.h>
 #include <zephyr/sys/libc-hooks.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <string.h>
 #include <zephyr/sys/errno_private.h>
 #include <unistd.h>
diff --git a/lib/libc/minimal/source/stdout/stdout_console.c b/lib/libc/minimal/source/stdout/stdout_console.c
index 8db7528..fd09b87 100644
--- a/lib/libc/minimal/source/stdout/stdout_console.c
+++ b/lib/libc/minimal/source/stdout/stdout_console.c
@@ -8,7 +8,7 @@
 
 #include <stdio.h>
 #include <zephyr/sys/libc-hooks.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <string.h>
 
 static int _stdout_hook_default(int c)
diff --git a/lib/libc/newlib/libc-hooks.c b/lib/libc/newlib/libc-hooks.c
index 1769e32..00ebd86 100644
--- a/lib/libc/newlib/libc-hooks.c
+++ b/lib/libc/newlib/libc-hooks.c
@@ -15,7 +15,7 @@
 #include <zephyr/sys/errno_private.h>
 #include <zephyr/sys/heap_listener.h>
 #include <zephyr/sys/libc-hooks.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/app_memory/app_memdomain.h>
 #include <zephyr/init.h>
 #include <zephyr/sys/sem.h>
diff --git a/lib/libc/picolibc/libc-hooks.c b/lib/libc/picolibc/libc-hooks.c
index 8df622c..ab90ab8 100644
--- a/lib/libc/picolibc/libc-hooks.c
+++ b/lib/libc/picolibc/libc-hooks.c
@@ -14,7 +14,7 @@
 #include <zephyr/sys/util.h>
 #include <zephyr/sys/errno_private.h>
 #include <zephyr/sys/libc-hooks.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/app_memory/app_memdomain.h>
 #include <zephyr/init.h>
 #include <zephyr/sys/sem.h>
diff --git a/lib/os/fdtable.c b/lib/os/fdtable.c
index b261c95..ccb14fa 100644
--- a/lib/os/fdtable.c
+++ b/lib/os/fdtable.c
@@ -20,7 +20,7 @@
 #include <zephyr/kernel.h>
 #include <zephyr/sys/fdtable.h>
 #include <zephyr/sys/speculation.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/sys/atomic.h>
 
 struct fd_entry {
diff --git a/lib/os/mutex.c b/lib/os/mutex.c
index b2284f0..fb18c96 100644
--- a/lib/os/mutex.c
+++ b/lib/os/mutex.c
@@ -6,7 +6,7 @@
 
 #include <zephyr/kernel.h>
 #include <zephyr/sys/mutex.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/kernel_structs.h>
 
 static struct k_mutex *get_k_mutex(struct sys_mutex *mutex)
diff --git a/lib/os/printk.c b/lib/os/printk.c
index 0701f8a..279b706 100644
--- a/lib/os/printk.c
+++ b/lib/os/printk.c
@@ -17,7 +17,7 @@
 #include <stdarg.h>
 #include <zephyr/toolchain.h>
 #include <zephyr/linker/sections.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/logging/log.h>
 #include <zephyr/sys/cbprintf.h>
 #include <zephyr/llext/symbol.h>
diff --git a/lib/os/sem.c b/lib/os/sem.c
index 132a0c8..b01ead5 100644
--- a/lib/os/sem.c
+++ b/lib/os/sem.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/sys/sem.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 #ifdef CONFIG_USERSPACE
 #define SYS_SEM_MINIMUM      0
diff --git a/lib/posix/clock.c b/lib/posix/clock.c
index 51812ed..5074254 100644
--- a/lib/posix/clock.c
+++ b/lib/posix/clock.c
@@ -7,7 +7,7 @@
 #include <errno.h>
 #include <zephyr/posix/time.h>
 #include <zephyr/posix/sys/time.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/spinlock.h>
 
 /*
diff --git a/samples/userspace/prod_consumer/src/app_syscall.c b/samples/userspace/prod_consumer/src/app_syscall.c
index 0f66c54..dc72609 100644
--- a/samples/userspace/prod_consumer/src/app_syscall.c
+++ b/samples/userspace/prod_consumer/src/app_syscall.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/logging/log.h>
 
 LOG_MODULE_REGISTER(app_syscall);
diff --git a/samples/userspace/prod_consumer/src/sample_driver_handlers.c b/samples/userspace/prod_consumer/src/sample_driver_handlers.c
index 8531b2b..1f9dc61 100644
--- a/samples/userspace/prod_consumer/src/sample_driver_handlers.c
+++ b/samples/userspace/prod_consumer/src/sample_driver_handlers.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include "sample_driver.h"
 
 int z_vrfy_sample_driver_state_set(const struct device *dev, bool active)
diff --git a/scripts/build/gen_kobject_list.py b/scripts/build/gen_kobject_list.py
index db274c1..6bd1201 100755
--- a/scripts/build/gen_kobject_list.py
+++ b/scripts/build/gen_kobject_list.py
@@ -724,7 +724,7 @@
 %{
 #include <zephyr/kernel.h>
 #include <zephyr/toolchain.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <string.h>
 %}
 struct k_object;
diff --git a/subsys/logging/log_core.c b/subsys/logging/log_core.c
index 7ba2cde..8f5e33e 100644
--- a/subsys/logging/log_core.c
+++ b/subsys/logging/log_core.c
@@ -18,7 +18,7 @@
 #include <zephyr/sys/iterable_sections.h>
 #include <ctype.h>
 #include <zephyr/logging/log_frontend.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/logging/log_output_dict.h>
 #include <zephyr/logging/log_output_custom.h>
 #include <zephyr/linker/utils.h>
diff --git a/subsys/logging/log_mgmt.c b/subsys/logging/log_mgmt.c
index 08de431..198433f 100644
--- a/subsys/logging/log_mgmt.c
+++ b/subsys/logging/log_mgmt.c
@@ -5,7 +5,7 @@
  */
 #include <zephyr/logging/log_internal.h>
 #include <zephyr/logging/log_ctrl.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/init.h>
 #include <zephyr/logging/log.h>
 #include <zephyr/logging/log_link.h>
diff --git a/subsys/logging/log_msg.c b/subsys/logging/log_msg.c
index 12ca988..a28f1dd 100644
--- a/subsys/logging/log_msg.c
+++ b/subsys/logging/log_msg.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/logging/log_internal.h>
 #include <zephyr/logging/log_ctrl.h>
 #include <zephyr/logging/log_frontend.h>
diff --git a/subsys/mgmt/updatehub/updatehub_handlers.c b/subsys/mgmt/updatehub/updatehub_handlers.c
index 33a0d4a..4d88973 100644
--- a/subsys/mgmt/updatehub/updatehub_handlers.c
+++ b/subsys/mgmt/updatehub/updatehub_handlers.c
@@ -4,7 +4,7 @@
  * SPDX-License-Identifier: Apache-2.0
  */
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/mgmt/updatehub.h>
 
 
diff --git a/subsys/net/ip/net_if.c b/subsys/net/ip/net_if.c
index acf5d62..b5887b1 100644
--- a/subsys/net/ip/net_if.c
+++ b/subsys/net/ip/net_if.c
@@ -12,7 +12,7 @@
 #include <zephyr/kernel.h>
 #include <zephyr/linker/sections.h>
 #include <zephyr/random/random.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <stdlib.h>
 #include <string.h>
 #include <zephyr/net/igmp.h>
diff --git a/subsys/net/ip/utils.c b/subsys/net/ip/utils.c
index 688784f..592d391 100644
--- a/subsys/net/ip/utils.c
+++ b/subsys/net/ip/utils.c
@@ -14,7 +14,7 @@
 
 #include <zephyr/kernel.h>
 #include <stdlib.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/types.h>
 #include <stdbool.h>
 #include <string.h>
diff --git a/subsys/net/l2/ethernet/ethernet.c b/subsys/net/l2/ethernet/ethernet.c
index 97990db..2be3c5f 100644
--- a/subsys/net/l2/ethernet/ethernet.c
+++ b/subsys/net/l2/ethernet/ethernet.c
@@ -20,7 +20,7 @@
 #include <zephyr/net/lldp.h>
 #endif
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 #include "arp.h"
 #include "eth_stats.h"
diff --git a/subsys/net/lib/sockets/getaddrinfo.c b/subsys/net/lib/sockets/getaddrinfo.c
index 2a499dc..2acee27 100644
--- a/subsys/net/lib/sockets/getaddrinfo.c
+++ b/subsys/net/lib/sockets/getaddrinfo.c
@@ -18,7 +18,7 @@
 #include <zephyr/net/net_ip.h>
 #include <zephyr/net/socket.h>
 #include <zephyr/net/socket_offload.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 #if defined(CONFIG_DNS_RESOLVER) || defined(CONFIG_NET_IP)
 #define ANY_RESOLVER
diff --git a/subsys/net/lib/sockets/socketpair.c b/subsys/net/lib/sockets/socketpair.c
index fad4f7a..ca9d78b 100644
--- a/subsys/net/lib/sockets/socketpair.c
+++ b/subsys/net/lib/sockets/socketpair.c
@@ -7,7 +7,7 @@
 #include <zephyr/kernel.h>
 #include <zephyr/net/socket.h>
 #include <zephyr/posix/fcntl.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/sys/__assert.h>
 #include <zephyr/sys/fdtable.h>
 
diff --git a/subsys/net/lib/sockets/sockets.c b/subsys/net/lib/sockets/sockets.c
index ba59cc9..12b8d02 100644
--- a/subsys/net/lib/sockets/sockets.c
+++ b/subsys/net/lib/sockets/sockets.c
@@ -20,7 +20,7 @@
 #else
 #include <zephyr/posix/fcntl.h>
 #endif
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/sys/fdtable.h>
 #include <zephyr/sys/math_extras.h>
 #include <zephyr/sys/iterable_sections.h>
diff --git a/subsys/net/lib/sockets/sockets_can.c b/subsys/net/lib/sockets/sockets_can.c
index 5e05440..d4856a7 100644
--- a/subsys/net/lib/sockets/sockets_can.c
+++ b/subsys/net/lib/sockets/sockets_can.c
@@ -21,7 +21,7 @@
 #include <zephyr/net/net_context.h>
 #include <zephyr/net/net_pkt.h>
 #include <zephyr/net/socket.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/sys/fdtable.h>
 #include <zephyr/net/canbus.h>
 #include <zephyr/net/socketcan.h>
diff --git a/subsys/net/lib/sockets/sockets_misc.c b/subsys/net/lib/sockets/sockets_misc.c
index 9729fca..fcc4283 100644
--- a/subsys/net/lib/sockets/sockets_misc.c
+++ b/subsys/net/lib/sockets/sockets_misc.c
@@ -6,7 +6,7 @@
 
 #include <errno.h>
 #include <zephyr/net/socket.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 int z_impl_zsock_gethostname(char *buf, size_t len)
 {
diff --git a/subsys/net/lib/sockets/sockets_net_mgmt.c b/subsys/net/lib/sockets/sockets_net_mgmt.c
index 91e13ec..11b06b8 100644
--- a/subsys/net/lib/sockets/sockets_net_mgmt.c
+++ b/subsys/net/lib/sockets/sockets_net_mgmt.c
@@ -17,7 +17,7 @@
 #include <zephyr/kernel.h>
 #include <zephyr/sys/util.h>
 #include <zephyr/net/socket.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/sys/fdtable.h>
 #include <zephyr/net/socket_net_mgmt.h>
 #include <zephyr/net/ethernet_mgmt.h>
diff --git a/subsys/net/lib/sockets/sockets_packet.c b/subsys/net/lib/sockets/sockets_packet.c
index 1d3d479..bcf063a 100644
--- a/subsys/net/lib/sockets/sockets_packet.c
+++ b/subsys/net/lib/sockets/sockets_packet.c
@@ -22,7 +22,7 @@
 #include <zephyr/net/net_pkt.h>
 #include <zephyr/net/socket.h>
 #include <zephyr/net/ethernet.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/sys/fdtable.h>
 
 #include "../../ip/net_stats.h"
diff --git a/subsys/net/lib/sockets/sockets_select.c b/subsys/net/lib/sockets/sockets_select.c
index 31c9841..f354fd4 100644
--- a/subsys/net/lib/sockets/sockets_select.c
+++ b/subsys/net/lib/sockets/sockets_select.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/sys/math_extras.h>
 #include <zephyr/net/socket.h>
 #include "sockets_internal.h"
diff --git a/subsys/net/lib/sockets/sockets_tls.c b/subsys/net/lib/sockets/sockets_tls.c
index e0d44b6..14b1de2 100644
--- a/subsys/net/lib/sockets/sockets_tls.c
+++ b/subsys/net/lib/sockets/sockets_tls.c
@@ -19,7 +19,7 @@
 #include <zephyr/sys/util.h>
 #include <zephyr/net/socket.h>
 #include <zephyr/random/random.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/sys/fdtable.h>
 
 /* TODO: Remove all direct access to private fields.
diff --git a/subsys/random/rand32_handlers.c b/subsys/random/rand32_handlers.c
index 5213011..06e45bd 100644
--- a/subsys/random/rand32_handlers.c
+++ b/subsys/random/rand32_handlers.c
@@ -5,8 +5,7 @@
  */
 
 #include <zephyr/random/random.h>
-#include <zephyr/syscall_handler.h>
-
+#include <zephyr/internal/syscall_handler.h>
 
 static inline uint32_t z_vrfy_sys_rand32_get(void)
 {
diff --git a/subsys/rtio/rtio_handlers.c b/subsys/rtio/rtio_handlers.c
index 3be7f2f..39ead48 100644
--- a/subsys/rtio/rtio_handlers.c
+++ b/subsys/rtio/rtio_handlers.c
@@ -7,7 +7,7 @@
 #include <zephyr/kernel.h>
 #include <stdbool.h>
 #include <zephyr/rtio/rtio.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 /**
  * Verify each SQE type operation and its fields ensuring
diff --git a/tests/arch/arm/arm_interrupt/src/arm_interrupt.c b/tests/arch/arm/arm_interrupt/src/arm_interrupt.c
index cf9e341..1bbfe08 100644
--- a/tests/arch/arm/arm_interrupt/src/arm_interrupt.c
+++ b/tests/arch/arm/arm_interrupt/src/arm_interrupt.c
@@ -382,7 +382,7 @@
 }
 
 #if defined(CONFIG_USERSPACE)
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include "test_syscalls.h"
 
 void z_impl_test_arm_user_interrupt_syscall(void)
diff --git a/tests/arch/arm/arm_mem_protect/src/main.c b/tests/arch/arm/arm_mem_protect/src/main.c
index 45e2314..83b96cf 100644
--- a/tests/arch/arm/arm_mem_protect/src/main.c
+++ b/tests/arch/arm/arm_mem_protect/src/main.c
@@ -4,7 +4,7 @@
  */
 
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/ztest.h>
 
 ZTEST_BMEM char user_stack[256];
diff --git a/tests/arch/arm/arm_sw_vector_relay/src/arm_sw_vector_relay.c b/tests/arch/arm/arm_sw_vector_relay/src/arm_sw_vector_relay.c
index c728864..be40074 100644
--- a/tests/arch/arm/arm_sw_vector_relay/src/arm_sw_vector_relay.c
+++ b/tests/arch/arm/arm_sw_vector_relay/src/arm_sw_vector_relay.c
@@ -6,7 +6,7 @@
 
 #include <zephyr/ztest.h>
 #include <zephyr/linker/linker-defs.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/toolchain.h>
 
 #include <cmsis_core.h>
diff --git a/tests/arch/arm/arm_thread_swap/src/arm_syscalls.c b/tests/arch/arm/arm_thread_swap/src/arm_syscalls.c
index 71fd8fc..e32de6c 100644
--- a/tests/arch/arm/arm_thread_swap/src/arm_syscalls.c
+++ b/tests/arch/arm/arm_thread_swap/src/arm_syscalls.c
@@ -29,7 +29,7 @@
 static struct k_thread user_thread;
 static K_THREAD_STACK_DEFINE(user_thread_stack, 1024);
 
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include "test_syscalls.h"
 
 void z_impl_test_arm_user_syscall(void)
diff --git a/tests/arch/common/ramfunc/src/ramfunc.c b/tests/arch/common/ramfunc/src/ramfunc.c
index 7f7bb28..cd55c65 100644
--- a/tests/arch/common/ramfunc/src/ramfunc.c
+++ b/tests/arch/common/ramfunc/src/ramfunc.c
@@ -6,7 +6,7 @@
 
 #include <zephyr/ztest.h>
 #include <zephyr/linker/linker-defs.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 static volatile int test_flag;
 
diff --git a/tests/arch/x86/cpu_scrubs_regs/src/main.c b/tests/arch/x86/cpu_scrubs_regs/src/main.c
index bddcc4f..6c27f73 100644
--- a/tests/arch/x86/cpu_scrubs_regs/src/main.c
+++ b/tests/arch/x86/cpu_scrubs_regs/src/main.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/ztest.h>
 #include "test_syscalls.h"
 
diff --git a/tests/benchmarks/footprints/src/userspace.c b/tests/benchmarks/footprints/src/userspace.c
index 231c427..c4e51cc 100644
--- a/tests/benchmarks/footprints/src/userspace.c
+++ b/tests/benchmarks/footprints/src/userspace.c
@@ -11,7 +11,7 @@
  */
 #include <zephyr/kernel.h>
 #include <ksched.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/app_memory/app_memdomain.h>
 
 #include "footprint.h"
diff --git a/tests/benchmarks/footprints/src/workq.c b/tests/benchmarks/footprints/src/workq.c
index a00afd7..2ad2d01 100644
--- a/tests/benchmarks/footprints/src/workq.c
+++ b/tests/benchmarks/footprints/src/workq.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 #include "footprint.h"
 
diff --git a/tests/kernel/fatal/exception/src/main.c b/tests/kernel/fatal/exception/src/main.c
index 51b3381..79c793e 100644
--- a/tests/kernel/fatal/exception/src/main.c
+++ b/tests/kernel/fatal/exception/src/main.c
@@ -14,7 +14,7 @@
 
 #if defined(CONFIG_USERSPACE)
 #include <zephyr/sys/mem_manage.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include "test_syscalls.h"
 #endif
 
diff --git a/tests/kernel/mem_protect/mem_protect/src/inherit.c b/tests/kernel/mem_protect/mem_protect/src/inherit.c
index fc3cb73..8925535 100644
--- a/tests/kernel/mem_protect/mem_protect/src/inherit.c
+++ b/tests/kernel/mem_protect/mem_protect/src/inherit.c
@@ -5,7 +5,7 @@
  */
 
 #include "mem_protect.h"
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/sys/libc-hooks.h> /* for z_libc_partition */
 
 /* function prototypes */
diff --git a/tests/kernel/mem_protect/mem_protect/src/kobject.c b/tests/kernel/mem_protect/mem_protect/src/kobject.c
index 76ed3f5..7deae8b 100644
--- a/tests/kernel/mem_protect/mem_protect/src/kobject.c
+++ b/tests/kernel/mem_protect/mem_protect/src/kobject.c
@@ -5,7 +5,7 @@
  */
 
 #include "mem_protect.h"
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 /* Kernel objects */
 
diff --git a/tests/kernel/mem_protect/obj_validation/src/main.c b/tests/kernel/mem_protect/obj_validation/src/main.c
index 9cc74a3..bd28b9e 100644
--- a/tests/kernel/mem_protect/obj_validation/src/main.c
+++ b/tests/kernel/mem_protect/obj_validation/src/main.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/ztest.h>
 #include <kernel_internal.h>
 
diff --git a/tests/kernel/mem_protect/syscalls/src/main.c b/tests/kernel/mem_protect/syscalls/src/main.c
index 2e03c40..23d987e 100644
--- a/tests/kernel/mem_protect/syscalls/src/main.c
+++ b/tests/kernel/mem_protect/syscalls/src/main.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/kernel.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <zephyr/ztest.h>
 #include <zephyr/linker/linker-defs.h>
 #include "test_syscalls.h"
diff --git a/tests/kernel/mem_protect/userspace/src/main.c b/tests/kernel/mem_protect/userspace/src/main.c
index 7c0289a..5a23e0c 100644
--- a/tests/kernel/mem_protect/userspace/src/main.c
+++ b/tests/kernel/mem_protect/userspace/src/main.c
@@ -16,7 +16,7 @@
 #include <zephyr/sys/util.h>
 #include <zephyr/sys/barrier.h>
 #include <zephyr/debug/stack.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include "test_syscall.h"
 #include <zephyr/sys/libc-hooks.h> /* for z_libc_partition */
 
diff --git a/tests/kernel/threads/thread_stack/src/main.c b/tests/kernel/threads/thread_stack/src/main.c
index 9a3a01a..19c54a0 100644
--- a/tests/kernel/threads/thread_stack/src/main.c
+++ b/tests/kernel/threads/thread_stack/src/main.c
@@ -6,7 +6,7 @@
 
 #include <zephyr/kernel.h>
 #include <zephyr/ztest.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 #include <kernel_internal.h>
 
 #include "test_syscall.h"
diff --git a/tests/ztest/error_hook/src/main.c b/tests/ztest/error_hook/src/main.c
index 560171a..cba35ce 100644
--- a/tests/ztest/error_hook/src/main.c
+++ b/tests/ztest/error_hook/src/main.c
@@ -5,7 +5,7 @@
  */
 
 #include <zephyr/irq_offload.h>
-#include <zephyr/syscall_handler.h>
+#include <zephyr/internal/syscall_handler.h>
 
 #include <zephyr/ztest.h>
 #include <zephyr/ztest_error_hook.h>