aboutsummaryrefslogtreecommitdiffstats
path: root/net/tipc/link.h
diff options
context:
space:
mode:
Diffstat (limited to 'net/tipc/link.h')
-rw-r--r--net/tipc/link.h36
1 files changed, 22 insertions, 14 deletions
diff --git a/net/tipc/link.h b/net/tipc/link.h
index 55812e87ca1e..9df7fa4d3bdd 100644
--- a/net/tipc/link.h
+++ b/net/tipc/link.h
@@ -41,6 +41,10 @@
41#include "msg.h" 41#include "msg.h"
42#include "node.h" 42#include "node.h"
43 43
44/* TIPC-specific error codes
45*/
46#define ELINKCONG EAGAIN /* link congestion <=> resource unavailable */
47
44/* Out-of-range value for link sequence numbers 48/* Out-of-range value for link sequence numbers
45 */ 49 */
46#define INVALID_LINK_SEQ 0x10000 50#define INVALID_LINK_SEQ 0x10000
@@ -105,7 +109,7 @@ struct tipc_stats {
105 * @peer_bearer_id: bearer id used by link's peer endpoint 109 * @peer_bearer_id: bearer id used by link's peer endpoint
106 * @bearer_id: local bearer id used by link 110 * @bearer_id: local bearer id used by link
107 * @tolerance: minimum link continuity loss needed to reset link [in ms] 111 * @tolerance: minimum link continuity loss needed to reset link [in ms]
108 * @continuity_interval: link continuity testing interval [in ms] 112 * @cont_intv: link continuity testing interval
109 * @abort_limit: # of unacknowledged continuity probes needed to reset link 113 * @abort_limit: # of unacknowledged continuity probes needed to reset link
110 * @state: current state of link FSM 114 * @state: current state of link FSM
111 * @fsm_msg_cnt: # of protocol messages link FSM has sent in current state 115 * @fsm_msg_cnt: # of protocol messages link FSM has sent in current state
@@ -146,7 +150,7 @@ struct tipc_link {
146 u32 peer_bearer_id; 150 u32 peer_bearer_id;
147 u32 bearer_id; 151 u32 bearer_id;
148 u32 tolerance; 152 u32 tolerance;
149 u32 continuity_interval; 153 unsigned long cont_intv;
150 u32 abort_limit; 154 u32 abort_limit;
151 int state; 155 int state;
152 u32 fsm_msg_cnt; 156 u32 fsm_msg_cnt;
@@ -196,28 +200,32 @@ struct tipc_port;
196struct tipc_link *tipc_link_create(struct tipc_node *n_ptr, 200struct tipc_link *tipc_link_create(struct tipc_node *n_ptr,
197 struct tipc_bearer *b_ptr, 201 struct tipc_bearer *b_ptr,
198 const struct tipc_media_addr *media_addr); 202 const struct tipc_media_addr *media_addr);
199void tipc_link_delete_list(unsigned int bearer_id, bool shutting_down); 203void tipc_link_delete_list(struct net *net, unsigned int bearer_id,
204 bool shutting_down);
200void tipc_link_failover_send_queue(struct tipc_link *l_ptr); 205void tipc_link_failover_send_queue(struct tipc_link *l_ptr);
201void tipc_link_dup_queue_xmit(struct tipc_link *l_ptr, struct tipc_link *dest); 206void tipc_link_dup_queue_xmit(struct tipc_link *l_ptr, struct tipc_link *dest);
202void tipc_link_reset_fragments(struct tipc_link *l_ptr); 207void tipc_link_reset_fragments(struct tipc_link *l_ptr);
203int tipc_link_is_up(struct tipc_link *l_ptr); 208int tipc_link_is_up(struct tipc_link *l_ptr);
204int tipc_link_is_active(struct tipc_link *l_ptr); 209int tipc_link_is_active(struct tipc_link *l_ptr);
205void tipc_link_purge_queues(struct tipc_link *l_ptr); 210void tipc_link_purge_queues(struct tipc_link *l_ptr);
206struct sk_buff *tipc_link_cmd_config(const void *req_tlv_area, 211struct sk_buff *tipc_link_cmd_config(struct net *net, const void *req_tlv_area,
207 int req_tlv_space, 212 int req_tlv_space, u16 cmd);
208 u16 cmd); 213struct sk_buff *tipc_link_cmd_show_stats(struct net *net,
209struct sk_buff *tipc_link_cmd_show_stats(const void *req_tlv_area, 214 const void *req_tlv_area,
210 int req_tlv_space); 215 int req_tlv_space);
211struct sk_buff *tipc_link_cmd_reset_stats(const void *req_tlv_area, 216struct sk_buff *tipc_link_cmd_reset_stats(struct net *net,
217 const void *req_tlv_area,
212 int req_tlv_space); 218 int req_tlv_space);
213void tipc_link_reset_all(struct tipc_node *node); 219void tipc_link_reset_all(struct tipc_node *node);
214void tipc_link_reset(struct tipc_link *l_ptr); 220void tipc_link_reset(struct tipc_link *l_ptr);
215void tipc_link_reset_list(unsigned int bearer_id); 221void tipc_link_reset_list(struct net *net, unsigned int bearer_id);
216int tipc_link_xmit_skb(struct sk_buff *skb, u32 dest, u32 selector); 222int tipc_link_xmit_skb(struct net *net, struct sk_buff *skb, u32 dest,
217int tipc_link_xmit(struct sk_buff_head *list, u32 dest, u32 selector); 223 u32 selector);
218int __tipc_link_xmit(struct tipc_link *link, struct sk_buff_head *list); 224int tipc_link_xmit(struct net *net, struct sk_buff_head *list, u32 dest,
219u32 tipc_link_get_max_pkt(u32 dest, u32 selector); 225 u32 selector);
220void tipc_link_bundle_rcv(struct sk_buff *buf); 226int __tipc_link_xmit(struct net *net, struct tipc_link *link,
227 struct sk_buff_head *list);
228void tipc_link_bundle_rcv(struct net *net, struct sk_buff *buf);
221void tipc_link_proto_xmit(struct tipc_link *l_ptr, u32 msg_typ, int prob, 229void tipc_link_proto_xmit(struct tipc_link *l_ptr, u32 msg_typ, int prob,
222 u32 gap, u32 tolerance, u32 priority, u32 acked_mtu); 230 u32 gap, u32 tolerance, u32 priority, u32 acked_mtu);
223void tipc_link_push_packets(struct tipc_link *l_ptr); 231void tipc_link_push_packets(struct tipc_link *l_ptr);