equal
deleted
inserted
replaced
63 { |
63 { |
64 ec_master_t *master; /**< EtherCAT master */ |
64 ec_master_t *master; /**< EtherCAT master */ |
65 struct net_device *dev; /**< pointer to the assigned net_device */ |
65 struct net_device *dev; /**< pointer to the assigned net_device */ |
66 uint8_t open; /**< true, if the net_device has been opened */ |
66 uint8_t open; /**< true, if the net_device has been opened */ |
67 struct sk_buff *tx_skb; /**< transmit socket buffer */ |
67 struct sk_buff *tx_skb; /**< transmit socket buffer */ |
68 ec_isr_t isr; /**< pointer to the device's interrupt service routine */ |
68 ec_pollfunc_t poll; /**< pointer to the device's poll function */ |
69 cycles_t cycles_isr; /**< cycles of last ISR call */ |
69 cycles_t cycles_poll; /**< cycles of last poll */ |
70 unsigned long jiffies_isr; /**< jiffies of last ISR call */ |
70 unsigned long jiffies_poll; /**< jiffies of last poll */ |
71 struct module *module; /**< pointer to the device's owning module */ |
71 struct module *module; /**< pointer to the device's owning module */ |
72 uint8_t link_state; /**< device link state */ |
72 uint8_t link_state; /**< device link state */ |
73 unsigned int tx_count; /**< number of frames sent */ |
73 unsigned int tx_count; /**< number of frames sent */ |
74 unsigned int rx_count; /**< number of frames received */ |
74 unsigned int rx_count; /**< number of frames received */ |
75 #ifdef EC_DBG_IF |
75 #ifdef EC_DBG_IF |
78 }; |
78 }; |
79 |
79 |
80 /*****************************************************************************/ |
80 /*****************************************************************************/ |
81 |
81 |
82 int ec_device_init(ec_device_t *, ec_master_t *, struct net_device *, |
82 int ec_device_init(ec_device_t *, ec_master_t *, struct net_device *, |
83 ec_isr_t, struct module *); |
83 ec_pollfunc_t, struct module *); |
84 void ec_device_clear(ec_device_t *); |
84 void ec_device_clear(ec_device_t *); |
85 |
85 |
86 int ec_device_open(ec_device_t *); |
86 int ec_device_open(ec_device_t *); |
87 int ec_device_close(ec_device_t *); |
87 int ec_device_close(ec_device_t *); |
88 |
88 |
89 void ec_device_call_isr(ec_device_t *); |
89 void ec_device_poll(ec_device_t *); |
90 uint8_t *ec_device_tx_data(ec_device_t *); |
90 uint8_t *ec_device_tx_data(ec_device_t *); |
91 void ec_device_send(ec_device_t *, size_t); |
91 void ec_device_send(ec_device_t *, size_t); |
92 |
92 |
93 /*****************************************************************************/ |
93 /*****************************************************************************/ |
94 |
94 |