--- a/master/fsm_soe.h Thu Jan 10 12:34:58 2013 +0100
+++ b/master/fsm_soe.h Thu Jan 10 17:36:41 2013 +0100
@@ -50,24 +50,25 @@
*/
struct ec_fsm_soe {
ec_slave_t *slave; /**< slave the FSM runs on */
- ec_datagram_t *datagram; /**< datagram used in the state machine */
unsigned int retries; /**< retries upon datagram timeout */
- void (*state)(ec_fsm_soe_t *); /**< CoE state function */
- unsigned long jiffies_start; /**< CoE timestamp. */
+ void (*state)(ec_fsm_soe_t *, ec_datagram_t *); /**< CoE state function */
+ ec_datagram_t *datagram; /**< Datagram used in the previous step. */
+ unsigned long jiffies_start; /**< Timestamp. */
ec_soe_request_t *request; /**< SoE request */
off_t offset; /**< IDN data offset during fragmented write. */
+ size_t fragment_size; /**< Size of the current fragment. */
};
/*****************************************************************************/
-void ec_fsm_soe_init(ec_fsm_soe_t *, ec_datagram_t *);
+void ec_fsm_soe_init(ec_fsm_soe_t *);
void ec_fsm_soe_clear(ec_fsm_soe_t *);
void ec_fsm_soe_transfer(ec_fsm_soe_t *, ec_slave_t *, ec_soe_request_t *);
-int ec_fsm_soe_exec(ec_fsm_soe_t *);
-int ec_fsm_soe_success(ec_fsm_soe_t *);
+int ec_fsm_soe_exec(ec_fsm_soe_t *, ec_datagram_t *);
+int ec_fsm_soe_success(const ec_fsm_soe_t *);
/*****************************************************************************/