diff --git a/flight/PiOS/STM32F10x/pios_i2c.c b/flight/PiOS/STM32F10x/pios_i2c.c index 636188cfc..5abcfaf8e 100644 --- a/flight/PiOS/STM32F10x/pios_i2c.c +++ b/flight/PiOS/STM32F10x/pios_i2c.c @@ -62,7 +62,7 @@ enum i2c_adapter_event { I2C_EVENT_NUM_EVENTS /* Must be last */ }; -static void go_faulted (struct pios_i2c_adapter * i2c_adapter); +static void go_fsm_fault (struct pios_i2c_adapter * i2c_adapter); static void go_stopping (struct pios_i2c_adapter * i2c_adapter); static void go_stopped (struct pios_i2c_adapter * i2c_adapter); static void go_starting (struct pios_i2c_adapter * i2c_adapter); @@ -97,8 +97,8 @@ static void i2c_adapter_inject_event(struct pios_i2c_adapter * i2c_adapter, enum static void i2c_adapter_fsm_init(struct pios_i2c_adapter * i2c_adapter); const static struct i2c_adapter_transition i2c_adapter_transitions[I2C_STATE_NUM_STATES] = { - [I2C_STATE_FAULTED] = { - .entry_fn = go_faulted, + [I2C_STATE_FSM_FAULT] = { + .entry_fn = go_fsm_fault, }, [I2C_STATE_STOPPED] = { @@ -285,7 +285,7 @@ const static struct i2c_adapter_transition i2c_adapter_transitions[I2C_STATE_NUM }, }; -static void go_faulted (struct pios_i2c_adapter * i2c_adapter) +static void go_fsm_fault (struct pios_i2c_adapter * i2c_adapter) { PIOS_DEBUG_Assert(0); } diff --git a/flight/PiOS/inc/pios_i2c_priv.h b/flight/PiOS/inc/pios_i2c_priv.h index 50f6ac6df..4c648c773 100644 --- a/flight/PiOS/inc/pios_i2c_priv.h +++ b/flight/PiOS/inc/pios_i2c_priv.h @@ -43,7 +43,7 @@ struct pios_i2c_adapter_cfg { }; enum i2c_adapter_state { - I2C_STATE_FAULTED = 0, /* Must be zero so undefined transitions land here */ + I2C_STATE_FSM_FAULT = 0, /* Must be zero so undefined transitions land here */ I2C_STATE_STOPPED, I2C_STATE_STOPPING,