Commit 4833c953 authored by Amitkumar Karwar's avatar Amitkumar Karwar Committed by Kalle Valo

rsi: use enum for FSM states

Currently macros are used for FSM states. We will replace
it with enum so that new state can be added easily without
worrying about macro value.
Signed-off-by: default avatarAmitkumar Karwar <amit.karwar@redpinesignals.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent d2d18317
...@@ -31,13 +31,15 @@ ...@@ -31,13 +31,15 @@
#define FSM_ZONE BIT(7) /* For State Machine Msgs */ #define FSM_ZONE BIT(7) /* For State Machine Msgs */
#define ISR_ZONE BIT(8) /* For Interrupt Msgs */ #define ISR_ZONE BIT(8) /* For Interrupt Msgs */
#define FSM_CARD_NOT_READY 0 enum RSI_FSM_STATES {
#define FSM_BOOT_PARAMS_SENT 1 FSM_CARD_NOT_READY,
#define FSM_EEPROM_READ_MAC_ADDR 2 FSM_BOOT_PARAMS_SENT,
#define FSM_RESET_MAC_SENT 3 FSM_EEPROM_READ_MAC_ADDR,
#define FSM_RADIO_CAPS_SENT 4 FSM_RESET_MAC_SENT,
#define FSM_BB_RF_PROG_SENT 5 FSM_RADIO_CAPS_SENT,
#define FSM_MAC_INIT_DONE 6 FSM_BB_RF_PROG_SENT,
FSM_MAC_INIT_DONE
};
extern u32 rsi_zone_enabled; extern u32 rsi_zone_enabled;
extern __printf(2, 3) void rsi_dbg(u32 zone, const char *fmt, ...); extern __printf(2, 3) void rsi_dbg(u32 zone, const char *fmt, ...);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment