equal
deleted
inserted
replaced
1373 datagram->state = EC_DATAGRAM_TIMED_OUT; |
1373 datagram->state = EC_DATAGRAM_TIMED_OUT; |
1374 master->stats.timeouts++; |
1374 master->stats.timeouts++; |
1375 ec_master_output_stats(master); |
1375 ec_master_output_stats(master); |
1376 |
1376 |
1377 if (unlikely(master->debug_level > 0)) { |
1377 if (unlikely(master->debug_level > 0)) { |
|
1378 unsigned int time_us; |
|
1379 #ifdef EC_HAVE_CYCLES |
|
1380 time_us = (unsigned int) (master->main_device.cycles_poll - |
|
1381 datagram->cycles_sent) * 1000 / cpu_khz; |
|
1382 #else |
|
1383 time_us = (unsigned int) (diff_ms * 1000); |
|
1384 #endif |
1378 EC_DBG("TIMED OUT datagram %08x, index %02X waited %u us.\n", |
1385 EC_DBG("TIMED OUT datagram %08x, index %02X waited %u us.\n", |
1379 (unsigned int) datagram, datagram->index, |
1386 (unsigned int) datagram, datagram->index, time_us); |
1380 #ifdef EC_HAVE_CYCLES |
|
1381 (unsigned int) (master->main_device.cycles_poll |
|
1382 - datagram->cycles_sent) * 1000 / cpu_khz |
|
1383 #else |
|
1384 (unsigned int) (diff_ms * 1000) |
|
1385 #endif |
|
1386 ); |
|
1387 |
|
1388 } |
1387 } |
1389 } |
1388 } |
1390 } |
1389 } |
1391 |
1390 |
1392 master->frames_timed_out = frames_timed_out; |
1391 master->frames_timed_out = frames_timed_out; |