api: Fix narrowing conversion C++ compilation warning in Z_TIMEOUT_TICKS
api: Fix narrowing conversion C++ compilation warning in Z_TIMEOUT_TICKS

Assignement in Z_TIMEOUT_TICKS macro causes narrowing
conversion warning in Z_TIMEOUT_TICKS.
Explicit cast to type of ticks field makes compiler happy.

Fixes #26369

Signed-off-by: Artur Lipowski <b02bd794c0cdf498f4a5ca4ac8598fd118f4ff97@hidglobal.com>

galak/zephyr,zephyrproject-rtos/zephyr,finikorg/zephyr,galak/zephyr,galak/zephyr,zephyrproject-rtos/zephyr,galak/zephyr,zephyrproject-rtos/zephyr,Vudentz/zephyr,finikorg/zephyr,zephyrproject-rtos/zephyr,finikorg/zephyr,Vudentz/zephyr,finikorg/zephyr,nashif/zephyr,Vudentz/zephyr,nashif/zephyr,Vudentz/zephyr,nashif/zephyr,nashif/zephyr,finikorg/zephyr,Vudentz/zephyr,nashif/zephyr,zephyrproject-rtos/zephyr,galak/zephyr,Vudentz/zephyr