Skip to content

Commit 0e132ec

Browse files
tunguyen4585kartben
authored andcommitted
drivers: pwm: update variable and marco name in RTD 2.0.1
eMios_Icu_Ip_IndexInChState is changed to eMios_Icu_Ip_u8IndexInChState and EMIOS_ICU_BUS_F is removed in RTD 2.0.1 Signed-off-by: Tu Nguyen Van <tu.nguyenvan@nxp.com>
1 parent 6f4f702 commit 0e132ec

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

drivers/pwm/pwm_nxp_s32_emios.c

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2023-2024 NXP
2+
* Copyright 2023-2025 NXP
33
*
44
* SPDX-License-Identifier: Apache-2.0
55
*/
@@ -32,6 +32,11 @@ LOG_MODULE_REGISTER(LOG_MODULE_NAME, CONFIG_PWM_LOG_LEVEL);
3232
* the HAL over configuration tool due to limitation of the integration
3333
*/
3434
#if EMIOS_PWM_IP_USED
35+
36+
#if defined(CONFIG_SOC_SERIES_S32ZE)
37+
#define eMios_Icu_Ip_IndexInChState eMios_Icu_Ip_u8IndexInChState
38+
#endif
39+
3540
extern uint8 eMios_Pwm_Ip_IndexInChState[EMIOS_PWM_IP_INSTANCE_COUNT][EMIOS_PWM_IP_CHANNEL_COUNT];
3641
#define EMIOS_PWM_MASTER_CHANNEL(channel, bus) \
3742
((bus == EMIOS_PWM_IP_BUS_A) ? 23 : \
@@ -44,7 +49,7 @@ extern uint8 eMios_Icu_Ip_IndexInChState[EMIOS_ICU_IP_INSTANCE_COUNT][EMIOS_ICU_
4449

4550
#define EMIOS_ICU_MASTER_CHANNEL(channel, bus) \
4651
((bus == EMIOS_ICU_BUS_A) ? 23 : \
47-
((bus == EMIOS_ICU_BUS_F) ? 22 : \
52+
(IF_DISABLED(CONFIG_SOC_SERIES_S32ZE, (bus == EMIOS_ICU_BUS_F) ? 22 :) \
4853
((bus == EMIOS_ICU_BUS_DIVERSE) ? ((channel >> 3) * 8) : channel)))
4954

5055
/* We need maximum three edges for measure both period and cycle */
@@ -882,7 +887,9 @@ static DEVICE_API(pwm, pwm_nxp_s32_driver_api) = {
882887
#define EMIOS_ICU_BUS_C EMIOS_ICU_BUS_DIVERSE
883888
#define EMIOS_ICU_BUS_D EMIOS_ICU_BUS_DIVERSE
884889
#define EMIOS_ICU_BUS_E EMIOS_ICU_BUS_DIVERSE
890+
#if !defined(CONFIG_SOC_SERIES_S32ZE)
885891
#define EMIOS_ICU_BUS_F EMIOS_ICU_BUS_F
892+
#endif
886893

887894
#define DIGITAL_FILTER_0 EMIOS_DIGITAL_FILTER_BYPASSED
888895
#define DIGITAL_FILTER_2 EMIOS_DIGITAL_FILTER_02

0 commit comments

Comments
 (0)