aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--net/tipc/name_table.c13
-rw-r--r--net/tipc/name_table.h6
-rw-r--r--net/tipc/subscr.c24
-rw-r--r--net/tipc/subscr.h10
4 files changed, 27 insertions, 26 deletions
diff --git a/net/tipc/name_table.c b/net/tipc/name_table.c
index f0abae93c1f1..89eb5621ebba 100644
--- a/net/tipc/name_table.c
+++ b/net/tipc/name_table.c
@@ -251,8 +251,8 @@ static struct publication *tipc_nameseq_insert_publ(struct name_seq *nseq,
251 u32 type, u32 lower, u32 upper, 251 u32 type, u32 lower, u32 upper,
252 u32 scope, u32 node, u32 port, u32 key) 252 u32 scope, u32 node, u32 port, u32 key)
253{ 253{
254 struct subscription *s; 254 struct tipc_subscription *s;
255 struct subscription *st; 255 struct tipc_subscription *st;
256 struct publication *publ; 256 struct publication *publ;
257 struct sub_seq *sseq; 257 struct sub_seq *sseq;
258 struct name_info *info; 258 struct name_info *info;
@@ -381,7 +381,7 @@ static struct publication *tipc_nameseq_remove_publ(struct name_seq *nseq, u32 i
381 struct sub_seq *sseq = nameseq_find_subseq(nseq, inst); 381 struct sub_seq *sseq = nameseq_find_subseq(nseq, inst);
382 struct name_info *info; 382 struct name_info *info;
383 struct sub_seq *free; 383 struct sub_seq *free;
384 struct subscription *s, *st; 384 struct tipc_subscription *s, *st;
385 int removed_subseq = 0; 385 int removed_subseq = 0;
386 386
387 if (!sseq) 387 if (!sseq)
@@ -448,7 +448,8 @@ found:
448 * sequence overlapping with the requested sequence 448 * sequence overlapping with the requested sequence
449 */ 449 */
450 450
451static void tipc_nameseq_subscribe(struct name_seq *nseq, struct subscription *s) 451static void tipc_nameseq_subscribe(struct name_seq *nseq,
452 struct tipc_subscription *s)
452{ 453{
453 struct sub_seq *sseq = nseq->sseqs; 454 struct sub_seq *sseq = nseq->sseqs;
454 455
@@ -739,7 +740,7 @@ int tipc_nametbl_withdraw(u32 type, u32 lower, u32 ref, u32 key)
739 * tipc_nametbl_subscribe - add a subscription object to the name table 740 * tipc_nametbl_subscribe - add a subscription object to the name table
740 */ 741 */
741 742
742void tipc_nametbl_subscribe(struct subscription *s) 743void tipc_nametbl_subscribe(struct tipc_subscription *s)
743{ 744{
744 u32 type = s->seq.type; 745 u32 type = s->seq.type;
745 struct name_seq *seq; 746 struct name_seq *seq;
@@ -763,7 +764,7 @@ void tipc_nametbl_subscribe(struct subscription *s)
763 * tipc_nametbl_unsubscribe - remove a subscription object from name table 764 * tipc_nametbl_unsubscribe - remove a subscription object from name table
764 */ 765 */
765 766
766void tipc_nametbl_unsubscribe(struct subscription *s) 767void tipc_nametbl_unsubscribe(struct tipc_subscription *s)
767{ 768{
768 struct name_seq *seq; 769 struct name_seq *seq;
769 770
diff --git a/net/tipc/name_table.h b/net/tipc/name_table.h
index c3b0f2c3dbbe..8086b42f92ad 100644
--- a/net/tipc/name_table.h
+++ b/net/tipc/name_table.h
@@ -39,7 +39,7 @@
39 39
40#include "node_subscr.h" 40#include "node_subscr.h"
41 41
42struct subscription; 42struct tipc_subscription;
43struct tipc_port_list; 43struct tipc_port_list;
44 44
45/* 45/*
@@ -100,8 +100,8 @@ struct publication *tipc_nametbl_insert_publ(u32 type, u32 lower, u32 upper,
100 u32 scope, u32 node, u32 ref, u32 key); 100 u32 scope, u32 node, u32 ref, u32 key);
101struct publication *tipc_nametbl_remove_publ(u32 type, u32 lower, 101struct publication *tipc_nametbl_remove_publ(u32 type, u32 lower,
102 u32 node, u32 ref, u32 key); 102 u32 node, u32 ref, u32 key);
103void tipc_nametbl_subscribe(struct subscription *s); 103void tipc_nametbl_subscribe(struct tipc_subscription *s);
104void tipc_nametbl_unsubscribe(struct subscription *s); 104void tipc_nametbl_unsubscribe(struct tipc_subscription *s);
105int tipc_nametbl_init(void); 105int tipc_nametbl_init(void);
106void tipc_nametbl_stop(void); 106void tipc_nametbl_stop(void);
107 107
diff --git a/net/tipc/subscr.c b/net/tipc/subscr.c
index 198371723b41..5bcd1f6e103c 100644
--- a/net/tipc/subscr.c
+++ b/net/tipc/subscr.c
@@ -92,7 +92,7 @@ static u32 htohl(u32 in, int swap)
92 * try to take the lock if the message is rejected and returned! 92 * try to take the lock if the message is rejected and returned!
93 */ 93 */
94 94
95static void subscr_send_event(struct subscription *sub, 95static void subscr_send_event(struct tipc_subscription *sub,
96 u32 found_lower, 96 u32 found_lower,
97 u32 found_upper, 97 u32 found_upper,
98 u32 event, 98 u32 event,
@@ -118,7 +118,7 @@ static void subscr_send_event(struct subscription *sub,
118 * Returns 1 if there is overlap, otherwise 0. 118 * Returns 1 if there is overlap, otherwise 0.
119 */ 119 */
120 120
121int tipc_subscr_overlap(struct subscription *sub, 121int tipc_subscr_overlap(struct tipc_subscription *sub,
122 u32 found_lower, 122 u32 found_lower,
123 u32 found_upper) 123 u32 found_upper)
124 124
@@ -138,7 +138,7 @@ int tipc_subscr_overlap(struct subscription *sub,
138 * Protected by nameseq.lock in name_table.c 138 * Protected by nameseq.lock in name_table.c
139 */ 139 */
140 140
141void tipc_subscr_report_overlap(struct subscription *sub, 141void tipc_subscr_report_overlap(struct tipc_subscription *sub,
142 u32 found_lower, 142 u32 found_lower,
143 u32 found_upper, 143 u32 found_upper,
144 u32 event, 144 u32 event,
@@ -158,7 +158,7 @@ void tipc_subscr_report_overlap(struct subscription *sub,
158 * subscr_timeout - subscription timeout has occurred 158 * subscr_timeout - subscription timeout has occurred
159 */ 159 */
160 160
161static void subscr_timeout(struct subscription *sub) 161static void subscr_timeout(struct tipc_subscription *sub)
162{ 162{
163 struct tipc_port *server_port; 163 struct tipc_port *server_port;
164 164
@@ -205,7 +205,7 @@ static void subscr_timeout(struct subscription *sub)
205 * Called with subscriber port locked. 205 * Called with subscriber port locked.
206 */ 206 */
207 207
208static void subscr_del(struct subscription *sub) 208static void subscr_del(struct tipc_subscription *sub)
209{ 209{
210 tipc_nametbl_unsubscribe(sub); 210 tipc_nametbl_unsubscribe(sub);
211 list_del(&sub->subscription_list); 211 list_del(&sub->subscription_list);
@@ -227,8 +227,8 @@ static void subscr_del(struct subscription *sub)
227static void subscr_terminate(struct subscriber *subscriber) 227static void subscr_terminate(struct subscriber *subscriber)
228{ 228{
229 u32 port_ref; 229 u32 port_ref;
230 struct subscription *sub; 230 struct tipc_subscription *sub;
231 struct subscription *sub_temp; 231 struct tipc_subscription *sub_temp;
232 232
233 /* Invalidate subscriber reference */ 233 /* Invalidate subscriber reference */
234 234
@@ -280,8 +280,8 @@ static void subscr_terminate(struct subscriber *subscriber)
280static void subscr_cancel(struct tipc_subscr *s, 280static void subscr_cancel(struct tipc_subscr *s,
281 struct subscriber *subscriber) 281 struct subscriber *subscriber)
282{ 282{
283 struct subscription *sub; 283 struct tipc_subscription *sub;
284 struct subscription *sub_temp; 284 struct tipc_subscription *sub_temp;
285 int found = 0; 285 int found = 0;
286 286
287 /* Find first matching subscription, exit if not found */ 287 /* Find first matching subscription, exit if not found */
@@ -314,10 +314,10 @@ static void subscr_cancel(struct tipc_subscr *s,
314 * Called with subscriber port locked. 314 * Called with subscriber port locked.
315 */ 315 */
316 316
317static struct subscription *subscr_subscribe(struct tipc_subscr *s, 317static struct tipc_subscription *subscr_subscribe(struct tipc_subscr *s,
318 struct subscriber *subscriber) 318 struct subscriber *subscriber)
319{ 319{
320 struct subscription *sub; 320 struct tipc_subscription *sub;
321 int swap; 321 int swap;
322 322
323 /* Determine subscriber's endianness */ 323 /* Determine subscriber's endianness */
@@ -418,7 +418,7 @@ static void subscr_conn_msg_event(void *usr_handle,
418{ 418{
419 struct subscriber *subscriber = usr_handle; 419 struct subscriber *subscriber = usr_handle;
420 spinlock_t *subscriber_lock; 420 spinlock_t *subscriber_lock;
421 struct subscription *sub; 421 struct tipc_subscription *sub;
422 422
423 /* 423 /*
424 * Lock subscriber's server port (& make a local copy of lock pointer, 424 * Lock subscriber's server port (& make a local copy of lock pointer,
diff --git a/net/tipc/subscr.h b/net/tipc/subscr.h
index 4b06ef6f8401..ef6529c8456f 100644
--- a/net/tipc/subscr.h
+++ b/net/tipc/subscr.h
@@ -37,10 +37,10 @@
37#ifndef _TIPC_SUBSCR_H 37#ifndef _TIPC_SUBSCR_H
38#define _TIPC_SUBSCR_H 38#define _TIPC_SUBSCR_H
39 39
40struct subscription; 40struct tipc_subscription;
41 41
42/** 42/**
43 * struct subscription - TIPC network topology subscription object 43 * struct tipc_subscription - TIPC network topology subscription object
44 * @seq: name sequence associated with subscription 44 * @seq: name sequence associated with subscription
45 * @timeout: duration of subscription (in ms) 45 * @timeout: duration of subscription (in ms)
46 * @filter: event filtering to be done for subscription 46 * @filter: event filtering to be done for subscription
@@ -52,7 +52,7 @@ struct subscription;
52 * @evt: template for events generated by subscription 52 * @evt: template for events generated by subscription
53 */ 53 */
54 54
55struct subscription { 55struct tipc_subscription {
56 struct tipc_name_seq seq; 56 struct tipc_name_seq seq;
57 u32 timeout; 57 u32 timeout;
58 u32 filter; 58 u32 filter;
@@ -64,11 +64,11 @@ struct subscription {
64 struct tipc_event evt; 64 struct tipc_event evt;
65}; 65};
66 66
67int tipc_subscr_overlap(struct subscription *sub, 67int tipc_subscr_overlap(struct tipc_subscription *sub,
68 u32 found_lower, 68 u32 found_lower,
69 u32 found_upper); 69 u32 found_upper);
70 70
71void tipc_subscr_report_overlap(struct subscription *sub, 71void tipc_subscr_report_overlap(struct tipc_subscription *sub,
72 u32 found_lower, 72 u32 found_lower,
73 u32 found_upper, 73 u32 found_upper,
74 u32 event, 74 u32 event,