master/ioctl.h
changeset 1516 e3b09f847512
parent 1509 a864688e7de5
child 1526 66edd310830c
equal deleted inserted replaced
1515:e722e0ac5d28 1516:e3b09f847512
    75 #define EC_IOCTL_SLAVE_FOE_WRITE       EC_IOW(0x13, ec_ioctl_slave_foe_t)
    75 #define EC_IOCTL_SLAVE_FOE_WRITE       EC_IOW(0x13, ec_ioctl_slave_foe_t)
    76 #define EC_IOCTL_CONFIG               EC_IOWR(0x14, ec_ioctl_config_t)
    76 #define EC_IOCTL_CONFIG               EC_IOWR(0x14, ec_ioctl_config_t)
    77 #define EC_IOCTL_CONFIG_PDO           EC_IOWR(0x15, ec_ioctl_config_pdo_t)
    77 #define EC_IOCTL_CONFIG_PDO           EC_IOWR(0x15, ec_ioctl_config_pdo_t)
    78 #define EC_IOCTL_CONFIG_PDO_ENTRY     EC_IOWR(0x16, ec_ioctl_config_pdo_entry_t)
    78 #define EC_IOCTL_CONFIG_PDO_ENTRY     EC_IOWR(0x16, ec_ioctl_config_pdo_entry_t)
    79 #define EC_IOCTL_CONFIG_SDO           EC_IOWR(0x17, ec_ioctl_config_sdo_t)
    79 #define EC_IOCTL_CONFIG_SDO           EC_IOWR(0x17, ec_ioctl_config_sdo_t)
       
    80 #ifdef EC_EOE
    80 #define EC_IOCTL_EOE_HANDLER          EC_IOWR(0x18, ec_ioctl_eoe_handler_t)
    81 #define EC_IOCTL_EOE_HANDLER          EC_IOWR(0x18, ec_ioctl_eoe_handler_t)
       
    82 #endif
    81 
    83 
    82 // Application interface
    84 // Application interface
    83 #define EC_IOCTL_REQUEST                EC_IO(0x19)
    85 #define EC_IOCTL_REQUEST                EC_IO(0x19)
    84 #define EC_IOCTL_CREATE_DOMAIN          EC_IO(0x1a)
    86 #define EC_IOCTL_CREATE_DOMAIN          EC_IO(0x1a)
    85 #define EC_IOCTL_CREATE_SLAVE_CONFIG  EC_IOWR(0x1b, ec_ioctl_config_t)
    87 #define EC_IOCTL_CREATE_SLAVE_CONFIG  EC_IOWR(0x1b, ec_ioctl_config_t)
   127 
   129 
   128 typedef struct {
   130 typedef struct {
   129     uint32_t slave_count;
   131     uint32_t slave_count;
   130     uint32_t config_count;
   132     uint32_t config_count;
   131     uint32_t domain_count;
   133     uint32_t domain_count;
       
   134 #ifdef EC_EOE
   132     uint32_t eoe_handler_count;
   135     uint32_t eoe_handler_count;
       
   136 #endif
   133     uint8_t phase;
   137     uint8_t phase;
   134     uint8_t scan_busy;
   138     uint8_t scan_busy;
   135     struct {
   139     struct {
   136         uint8_t address[6];
   140         uint8_t address[6];
   137         uint8_t attached;
   141         uint8_t attached;
   446     uint8_t data[4];
   450     uint8_t data[4];
   447 } ec_ioctl_config_sdo_t;
   451 } ec_ioctl_config_sdo_t;
   448 
   452 
   449 /*****************************************************************************/
   453 /*****************************************************************************/
   450 
   454 
       
   455 #ifdef EC_EOE
       
   456 
   451 typedef struct {
   457 typedef struct {
   452     // input
   458     // input
   453     uint16_t eoe_index;
   459     uint16_t eoe_index;
   454 
   460 
   455     // outputs
   461     // outputs
   461     uint32_t tx_bytes;
   467     uint32_t tx_bytes;
   462     uint32_t tx_rate;
   468     uint32_t tx_rate;
   463     uint32_t tx_queued_frames;
   469     uint32_t tx_queued_frames;
   464     uint32_t tx_queue_size;
   470     uint32_t tx_queue_size;
   465 } ec_ioctl_eoe_handler_t;
   471 } ec_ioctl_eoe_handler_t;
       
   472 
       
   473 #endif
   466 
   474 
   467 /*****************************************************************************/
   475 /*****************************************************************************/
   468 
   476 
   469 typedef struct {
   477 typedef struct {
   470     // inputs
   478     // inputs