--- a/master/fsm_foe.c Wed Jan 22 19:02:02 2014 +1300
+++ b/master/fsm_foe.c Wed Mar 05 06:36:18 2014 +1300
@@ -374,7 +374,7 @@
if (!ec_slave_mbox_check(fsm->datagram)) {
// slave did not put anything in the mailbox yet
- if (time_after(datagram->jiffies_received,
+ if (time_after(fsm->datagram->jiffies_received,
fsm->jiffies_start + EC_FSM_FOE_TIMEOUT_JIFFIES)) {
ec_foe_set_tx_error(fsm, FOE_TIMEOUT_ERROR);
EC_SLAVE_ERR(slave, "Timeout while waiting for ack response.\n");
@@ -736,7 +736,7 @@
}
if (!ec_slave_mbox_check(fsm->datagram)) {
- if (time_after(datagram->jiffies_received,
+ if (time_after(fsm->datagram->jiffies_received,
fsm->jiffies_start + EC_FSM_FOE_TIMEOUT_JIFFIES)) {
ec_foe_set_tx_error(fsm, FOE_TIMEOUT_ERROR);
EC_SLAVE_ERR(slave, "Timeout while waiting for ack response.\n");