equal
deleted
inserted
replaced
40 |
40 |
41 #ifndef __EC_DOMAIN_H__ |
41 #ifndef __EC_DOMAIN_H__ |
42 #define __EC_DOMAIN_H__ |
42 #define __EC_DOMAIN_H__ |
43 |
43 |
44 #include <linux/list.h> |
44 #include <linux/list.h> |
45 #include <linux/kobject.h> |
|
46 |
45 |
47 #include "globals.h" |
46 #include "globals.h" |
48 #include "datagram.h" |
47 #include "datagram.h" |
49 #include "master.h" |
48 #include "master.h" |
50 #include "fmmu_config.h" |
49 #include "fmmu_config.h" |
51 |
50 |
52 /*****************************************************************************/ |
51 /*****************************************************************************/ |
53 |
52 |
54 /** |
53 /** EtherCAT domain. |
55 EtherCAT domain. |
54 * |
56 Handles the process data and the therefore needed datagrams of a certain |
55 * Handles the process data and the therefore needed datagrams of a certain |
57 group of slaves. |
56 * group of slaves. |
58 */ |
57 */ |
59 |
|
60 struct ec_domain |
58 struct ec_domain |
61 { |
59 { |
62 struct kobject kobj; /**< kobject. */ |
|
63 struct list_head list; /**< List item. */ |
60 struct list_head list; /**< List item. */ |
64 ec_master_t *master; /**< EtherCAT master owning the domain. */ |
61 ec_master_t *master; /**< EtherCAT master owning the domain. */ |
65 unsigned int index; /**< Index (just a number). */ |
62 unsigned int index; /**< Index (just a number). */ |
66 |
63 |
67 struct list_head fmmu_configs; /**< FMMU configurations contained. */ |
64 struct list_head fmmu_configs; /**< FMMU configurations contained. */ |
79 unsigned long notify_jiffies; /**< Time of last notification. */ |
76 unsigned long notify_jiffies; /**< Time of last notification. */ |
80 }; |
77 }; |
81 |
78 |
82 /*****************************************************************************/ |
79 /*****************************************************************************/ |
83 |
80 |
84 int ec_domain_init(ec_domain_t *, ec_master_t *, unsigned int); |
81 void ec_domain_init(ec_domain_t *, ec_master_t *, unsigned int); |
85 void ec_domain_destroy(ec_domain_t *); |
82 void ec_domain_clear(ec_domain_t *); |
86 |
83 |
87 void ec_domain_add_fmmu_config(ec_domain_t *, ec_fmmu_config_t *); |
84 void ec_domain_add_fmmu_config(ec_domain_t *, ec_fmmu_config_t *); |
88 int ec_domain_finish(ec_domain_t *, uint32_t); |
85 int ec_domain_finish(ec_domain_t *, uint32_t); |
89 |
86 |
90 unsigned int ec_domain_fmmu_count(const ec_domain_t *); |
87 unsigned int ec_domain_fmmu_count(const ec_domain_t *); |