equal
deleted
inserted
replaced
315 slave's mailbox for a new EoE datagram. |
315 slave's mailbox for a new EoE datagram. |
316 */ |
316 */ |
317 |
317 |
318 void ec_eoe_state_rx_start(ec_eoe_t *eoe /**< EoE handler */) |
318 void ec_eoe_state_rx_start(ec_eoe_t *eoe /**< EoE handler */) |
319 { |
319 { |
320 if (!eoe->slave->online || !eoe->slave->master->device->link_state) |
320 if (!eoe->slave->online || !eoe->slave->master->main_device.link_state) |
321 return; |
321 return; |
322 |
322 |
323 ec_slave_mbox_prepare_check(eoe->slave, &eoe->datagram); |
323 ec_slave_mbox_prepare_check(eoe->slave, &eoe->datagram); |
324 ec_master_queue_datagram(eoe->slave->master, &eoe->datagram); |
324 ec_master_queue_datagram(eoe->slave->master, &eoe->datagram); |
325 eoe->state = ec_eoe_state_rx_check; |
325 eoe->state = ec_eoe_state_rx_check; |
516 { |
516 { |
517 #if EOE_DEBUG_LEVEL > 0 |
517 #if EOE_DEBUG_LEVEL > 0 |
518 unsigned int wakeup = 0; |
518 unsigned int wakeup = 0; |
519 #endif |
519 #endif |
520 |
520 |
521 if (!eoe->slave->online || !eoe->slave->master->device->link_state) |
521 if (!eoe->slave->online || !eoe->slave->master->main_device.link_state) |
522 return; |
522 return; |
523 |
523 |
524 spin_lock_bh(&eoe->tx_queue_lock); |
524 spin_lock_bh(&eoe->tx_queue_lock); |
525 |
525 |
526 if (!eoe->tx_queued_frames || list_empty(&eoe->tx_queue)) { |
526 if (!eoe->tx_queued_frames || list_empty(&eoe->tx_queue)) { |