aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ieee1394/nodemgr.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ieee1394/nodemgr.h')
-rw-r--r--drivers/ieee1394/nodemgr.h16
1 files changed, 5 insertions, 11 deletions
diff --git a/drivers/ieee1394/nodemgr.h b/drivers/ieee1394/nodemgr.h
index 0b26616e16c3..b35c1b5c8d86 100644
--- a/drivers/ieee1394/nodemgr.h
+++ b/drivers/ieee1394/nodemgr.h
@@ -44,7 +44,6 @@ struct bus_options {
44 u16 max_rec; /* Maximum packet size node can receive */ 44 u16 max_rec; /* Maximum packet size node can receive */
45}; 45};
46 46
47
48#define UNIT_DIRECTORY_VENDOR_ID 0x01 47#define UNIT_DIRECTORY_VENDOR_ID 0x01
49#define UNIT_DIRECTORY_MODEL_ID 0x02 48#define UNIT_DIRECTORY_MODEL_ID 0x02
50#define UNIT_DIRECTORY_SPECIFIER_ID 0x04 49#define UNIT_DIRECTORY_SPECIFIER_ID 0x04
@@ -59,8 +58,8 @@ struct bus_options {
59 * unit directory for each of these protocols. 58 * unit directory for each of these protocols.
60 */ 59 */
61struct unit_directory { 60struct unit_directory {
62 struct node_entry *ne; /* The node which this directory belongs to */ 61 struct node_entry *ne; /* The node which this directory belongs to */
63 octlet_t address; /* Address of the unit directory on the node */ 62 octlet_t address; /* Address of the unit directory on the node */
64 u8 flags; /* Indicates which entries were read */ 63 u8 flags; /* Indicates which entries were read */
65 64
66 quadlet_t vendor_id; 65 quadlet_t vendor_id;
@@ -79,11 +78,10 @@ struct unit_directory {
79 int length; /* Number of quadlets */ 78 int length; /* Number of quadlets */
80 79
81 struct device device; 80 struct device device;
82
83 struct class_device class_dev; 81 struct class_device class_dev;
84 82
85 struct csr1212_keyval *ud_kv; 83 struct csr1212_keyval *ud_kv;
86 u32 lun; /* logical unit number immediate value */ 84 u32 lun; /* logical unit number immediate value */
87}; 85};
88 86
89struct node_entry { 87struct node_entry {
@@ -106,7 +104,6 @@ struct node_entry {
106 struct hpsb_tlabel_pool *tpool; 104 struct hpsb_tlabel_pool *tpool;
107 105
108 struct device device; 106 struct device device;
109
110 struct class_device class_dev; 107 struct class_device class_dev;
111 108
112 /* Means this node is not attached anymore */ 109 /* Means this node is not attached anymore */
@@ -153,8 +150,8 @@ static inline int hpsb_node_entry_valid(struct node_entry *ne)
153/* 150/*
154 * This will fill in the given, pre-initialised hpsb_packet with the current 151 * This will fill in the given, pre-initialised hpsb_packet with the current
155 * information from the node entry (host, node ID, generation number). It will 152 * information from the node entry (host, node ID, generation number). It will
156 * return false if the node owning the GUID is not accessible (and not modify the 153 * return false if the node owning the GUID is not accessible (and not modify
157 * hpsb_packet) and return true otherwise. 154 * the hpsb_packet) and return true otherwise.
158 * 155 *
159 * Note that packet sending may still fail in hpsb_send_packet if a bus reset 156 * Note that packet sending may still fail in hpsb_send_packet if a bus reset
160 * happens while you are trying to set up the packet (due to obsolete generation 157 * happens while you are trying to set up the packet (due to obsolete generation
@@ -170,16 +167,13 @@ int hpsb_node_write(struct node_entry *ne, u64 addr,
170int hpsb_node_lock(struct node_entry *ne, u64 addr, 167int hpsb_node_lock(struct node_entry *ne, u64 addr,
171 int extcode, quadlet_t *data, quadlet_t arg); 168 int extcode, quadlet_t *data, quadlet_t arg);
172 169
173
174/* Iterate the hosts, calling a given function with supplied data for each 170/* Iterate the hosts, calling a given function with supplied data for each
175 * host. */ 171 * host. */
176int nodemgr_for_each_host(void *__data, int (*cb)(struct hpsb_host *, void *)); 172int nodemgr_for_each_host(void *__data, int (*cb)(struct hpsb_host *, void *));
177 173
178
179int init_ieee1394_nodemgr(void); 174int init_ieee1394_nodemgr(void);
180void cleanup_ieee1394_nodemgr(void); 175void cleanup_ieee1394_nodemgr(void);
181 176
182
183/* The template for a host device */ 177/* The template for a host device */
184extern struct device nodemgr_dev_template_host; 178extern struct device nodemgr_dev_template_host;
185 179