X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=UDI%2Fdrivers%2Fnet_ne2000%2Fne2000_common.h;h=d4e58aa34fb5326d7d04cf0c3d72f67c6a54a73f;hb=adf8e7862b8375ba1d9b281be50fd5f9938ee662;hp=59801fbb163e3774a17683e010070bcc98666c42;hpb=ba60880472a507ff724595f29830753ec8aad40e;p=tpg%2Facess2.git diff --git a/UDI/drivers/net_ne2000/ne2000_common.h b/UDI/drivers/net_ne2000/ne2000_common.h index 59801fbb..d4e58aa3 100644 --- a/UDI/drivers/net_ne2000/ne2000_common.h +++ b/UDI/drivers/net_ne2000/ne2000_common.h @@ -8,8 +8,14 @@ #ifndef _NE2000_COMMON_H_ #define _NE2000_COMMON_H_ +#define UDI_VERSION 0x101 +#define UDI_PHYSIO_VERSION 0x101 +#define UDI_PCI_VERSION 0x101 +#define UDI_NIC_VERSION 0x101 + #include #include +#include #include #include "ne2000_hw.h" @@ -22,6 +28,7 @@ enum { NE2K_PIO_RX, NE2K_PIO_IRQACK, NE2K_PIO_TX, + N_NE2K_PIO }; typedef struct @@ -39,12 +46,13 @@ typedef struct udi_index_t rx_chan_index; } init; - udi_pio_handle_t pio_handles[4]; + udi_pio_handle_t pio_handles[N_NE2K_PIO]; udi_channel_t interrupt_channel; udi_channel_t rx_channel; udi_channel_t tx_channel; udi_nic_rx_cb_t *rx_next_cb; + udi_nic_rx_cb_t *rx_last_cb; udi_ubit8_t rx_next_page; udi_ubit8_t macaddr[6]; @@ -75,10 +83,15 @@ typedef struct (attr)->attr_type = UDI_ATTR_STRING; \ (attr)->attr_length = (len); \ udi_strncpy_rtrim((char *)(attr)->attr_value, (val), (len)) -#define NE2K_SET_ATTR_STRFMT(attr, name, maxlen, fmt, v...) \ +#define NE2K_SET_ATTR_STRFMT(attr, name, maxlen, fmt, ...) \ udi_strcpy((attr)->attr_name, (name)); \ (attr)->attr_type = UDI_ATTR_STRING; \ - (attr)->attr_length = udi_snprintf((char *)(attr)->attr_value, (maxlen), (fmt) ,## v ) + (attr)->attr_length = udi_snprintf((char *)(attr)->attr_value, (maxlen), (fmt) ,## __VA_ARGS__ ) + +extern udi_usage_ind_op_t ne2k_usage_ind; +extern udi_enumerate_req_op_t ne2k_enumerate_req; +extern udi_devmgmt_req_op_t ne2k_devmgmt_req; +extern udi_final_cleanup_req_op_t ne2k_final_cleanup_req; extern udi_channel_event_ind_op_t ne2k_bus_dev_channel_event_ind; extern udi_bus_bind_ack_op_t ne2k_bus_dev_bus_bind_ack; @@ -97,6 +110,7 @@ extern udi_channel_spawn_call_t ne2k_nd_ctrl_bind__tx_chan_ok; extern udi_channel_spawn_call_t ne2k_nd_ctrl_bind__rx_chan_ok; extern udi_nd_unbind_req_op_t ne2k_nd_ctrl_unbind_req; extern udi_nd_enable_req_op_t ne2k_nd_ctrl_enable_req; +extern udi_pio_trans_call_t ne2k_nd_ctrl_enable_req__trans_done; extern udi_nd_disable_req_op_t ne2k_nd_ctrl_disable_req; extern udi_nd_ctrl_req_op_t ne2k_nd_ctrl_ctrl_req; extern udi_nd_info_req_op_t ne2k_nd_ctrl_info_req;