diff options
Diffstat (limited to 'drivers/firewire/fw-topology.h')
-rw-r--r-- | drivers/firewire/fw-topology.h | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/drivers/firewire/fw-topology.h b/drivers/firewire/fw-topology.h index addb9f8ea776..3c497bb4fae4 100644 --- a/drivers/firewire/fw-topology.h +++ b/drivers/firewire/fw-topology.h | |||
@@ -19,6 +19,11 @@ | |||
19 | #ifndef __fw_topology_h | 19 | #ifndef __fw_topology_h |
20 | #define __fw_topology_h | 20 | #define __fw_topology_h |
21 | 21 | ||
22 | #include <linux/list.h> | ||
23 | #include <linux/slab.h> | ||
24 | |||
25 | #include <asm/atomic.h> | ||
26 | |||
22 | enum { | 27 | enum { |
23 | FW_NODE_CREATED, | 28 | FW_NODE_CREATED, |
24 | FW_NODE_UPDATED, | 29 | FW_NODE_UPDATED, |
@@ -51,26 +56,22 @@ struct fw_node { | |||
51 | struct fw_node *ports[0]; | 56 | struct fw_node *ports[0]; |
52 | }; | 57 | }; |
53 | 58 | ||
54 | static inline struct fw_node * | 59 | static inline struct fw_node *fw_node_get(struct fw_node *node) |
55 | fw_node_get(struct fw_node *node) | ||
56 | { | 60 | { |
57 | atomic_inc(&node->ref_count); | 61 | atomic_inc(&node->ref_count); |
58 | 62 | ||
59 | return node; | 63 | return node; |
60 | } | 64 | } |
61 | 65 | ||
62 | static inline void | 66 | static inline void fw_node_put(struct fw_node *node) |
63 | fw_node_put(struct fw_node *node) | ||
64 | { | 67 | { |
65 | if (atomic_dec_and_test(&node->ref_count)) | 68 | if (atomic_dec_and_test(&node->ref_count)) |
66 | kfree(node); | 69 | kfree(node); |
67 | } | 70 | } |
68 | 71 | ||
69 | void | 72 | struct fw_card; |
70 | fw_destroy_nodes(struct fw_card *card); | 73 | void fw_destroy_nodes(struct fw_card *card); |
71 | |||
72 | int | ||
73 | fw_compute_block_crc(u32 *block); | ||
74 | 74 | ||
75 | int fw_compute_block_crc(u32 *block); | ||
75 | 76 | ||
76 | #endif /* __fw_topology_h */ | 77 | #endif /* __fw_topology_h */ |