Skip to content

Commit 617d3c7

Browse files
author
Paul Gortmaker
committed
tipc: compress out gratuitous extra carriage returns
Some of the comment blocks are floating in limbo between two functions, or between blocks of code. Delete the extra line feeds between any comment and its associated following block of code, to be consistent with the majority of the rest of the kernel. Also delete trailing newlines at EOF and fix a couple trivial typos in existing comments. This is a 100% cosmetic change with no runtime impact. We get rid of over 500 lines of non-code, and being blank line deletes, they won't even show up as noise in git blame. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
1 parent aad5854 commit 617d3c7

32 files changed

Lines changed: 16 additions & 530 deletions

‎net/tipc/Makefile‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,3 @@ tipc-y += addr.o bcast.o bearer.o config.o \
99
name_distr.o subscr.o name_table.o net.o \
1010
netlink.o node.o node_subscr.o port.o ref.o \
1111
socket.o log.o eth_media.o
12-
13-
# End of file

‎net/tipc/addr.c‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@
4545
*
4646
* Returns 1 if domain address is valid, otherwise 0
4747
*/
48-
4948
int tipc_addr_domain_valid(u32 addr)
5049
{
5150
u32 n = tipc_node(addr);
@@ -66,7 +65,6 @@ int tipc_addr_domain_valid(u32 addr)
6665
*
6766
* Returns 1 if address can be used, otherwise 0
6867
*/
69-
7068
int tipc_addr_node_valid(u32 addr)
7169
{
7270
return tipc_addr_domain_valid(addr) && tipc_node(addr);
@@ -86,7 +84,6 @@ int tipc_in_scope(u32 domain, u32 addr)
8684
/**
8785
* tipc_addr_scope - convert message lookup domain to a 2-bit scope value
8886
*/
89-
9087
int tipc_addr_scope(u32 domain)
9188
{
9289
if (likely(!domain))

‎net/tipc/addr.h‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,6 @@ static inline int in_own_cluster_exact(u32 addr)
5858
/**
5959
* in_own_node - test for node inclusion; <0.0.0> always matches
6060
*/
61-
6261
static inline int in_own_node(u32 addr)
6362
{
6463
return (addr == tipc_own_addr) || !addr;
@@ -67,7 +66,6 @@ static inline int in_own_node(u32 addr)
6766
/**
6867
* in_own_cluster - test for cluster inclusion; <0.0.0> always matches
6968
*/
70-
7169
static inline int in_own_cluster(u32 addr)
7270
{
7371
return in_own_cluster_exact(addr) || !addr;
@@ -79,7 +77,6 @@ static inline int in_own_cluster(u32 addr)
7977
* Needed when address of a named message must be looked up a second time
8078
* after a network hop.
8179
*/
82-
8380
static inline u32 addr_domain(u32 sc)
8481
{
8582
if (likely(sc == TIPC_NODE_SCOPE))

‎net/tipc/bcast.c‎

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@ struct tipc_bcbearer_pair {
7373
* large local variables within multicast routines. Concurrent access is
7474
* prevented through use of the spinlock "bc_lock".
7575
*/
76-
7776
struct tipc_bcbearer {
7877
struct tipc_bearer bearer;
7978
struct tipc_media media;
@@ -92,7 +91,6 @@ struct tipc_bcbearer {
9291
*
9392
* Handles sequence numbering, fragmentation, bundling, etc.
9493
*/
95-
9694
struct tipc_bclink {
9795
struct tipc_link link;
9896
struct tipc_node node;
@@ -169,7 +167,6 @@ static void bclink_update_last_sent(struct tipc_node *node, u32 seqno)
169167
*
170168
* Called with bc_lock locked
171169
*/
172-
173170
struct tipc_node *tipc_bclink_retransmit_to(void)
174171
{
175172
return bclink->retransmit_to;
@@ -182,7 +179,6 @@ struct tipc_node *tipc_bclink_retransmit_to(void)
182179
*
183180
* Called with bc_lock locked
184181
*/
185-
186182
static void bclink_retransmit_pkt(u32 after, u32 to)
187183
{
188184
struct sk_buff *buf;
@@ -200,7 +196,6 @@ static void bclink_retransmit_pkt(u32 after, u32 to)
200196
*
201197
* Node is locked, bc_lock unlocked.
202198
*/
203-
204199
void tipc_bclink_acknowledge(struct tipc_node *n_ptr, u32 acked)
205200
{
206201
struct sk_buff *crs;
@@ -280,7 +275,6 @@ void tipc_bclink_acknowledge(struct tipc_node *n_ptr, u32 acked)
280275
*
281276
* tipc_net_lock and node lock set
282277
*/
283-
284278
void tipc_bclink_update_link_state(struct tipc_node *n_ptr, u32 last_sent)
285279
{
286280
struct sk_buff *buf;
@@ -344,7 +338,6 @@ void tipc_bclink_update_link_state(struct tipc_node *n_ptr, u32 last_sent)
344338
*
345339
* Only tipc_net_lock set.
346340
*/
347-
348341
static void bclink_peek_nack(struct tipc_msg *msg)
349342
{
350343
struct tipc_node *n_ptr = tipc_node_find(msg_destnode(msg));
@@ -365,7 +358,6 @@ static void bclink_peek_nack(struct tipc_msg *msg)
365358
/*
366359
* tipc_bclink_send_msg - broadcast a packet to all nodes in cluster
367360
*/
368-
369361
int tipc_bclink_send_msg(struct sk_buff *buf)
370362
{
371363
int res;
@@ -394,7 +386,6 @@ int tipc_bclink_send_msg(struct sk_buff *buf)
394386
*
395387
* Called with both sending node's lock and bc_lock taken.
396388
*/
397-
398389
static void bclink_accept_pkt(struct tipc_node *node, u32 seqno)
399390
{
400391
bclink_update_last_sent(node, seqno);
@@ -420,7 +411,6 @@ static void bclink_accept_pkt(struct tipc_node *node, u32 seqno)
420411
*
421412
* tipc_net_lock is read_locked, no other locks set
422413
*/
423-
424414
void tipc_bclink_recv_pkt(struct sk_buff *buf)
425415
{
426416
struct tipc_msg *msg = buf_msg(buf);
@@ -588,7 +578,6 @@ u32 tipc_bclink_acks_missing(struct tipc_node *n_ptr)
588578
* Returns 0 (packet sent successfully) under all circumstances,
589579
* since the broadcast link's pseudo-bearer never blocks
590580
*/
591-
592581
static int tipc_bcbearer_send(struct sk_buff *buf,
593582
struct tipc_bearer *unused1,
594583
struct tipc_media_addr *unused2)
@@ -601,7 +590,6 @@ static int tipc_bcbearer_send(struct sk_buff *buf,
601590
* preparation is skipped for broadcast link protocol messages
602591
* since they are sent in an unreliable manner and don't need it
603592
*/
604-
605593
if (likely(!msg_non_seq(buf_msg(buf)))) {
606594
struct tipc_msg *msg;
607595

@@ -618,7 +606,6 @@ static int tipc_bcbearer_send(struct sk_buff *buf,
618606
}
619607

620608
/* Send buffer over bearers until all targets reached */
621-
622609
bcbearer->remains = bclink->bcast_nodes;
623610

624611
for (bp_index = 0; bp_index < MAX_BEARERS; bp_index++) {
@@ -660,7 +647,6 @@ static int tipc_bcbearer_send(struct sk_buff *buf,
660647
/**
661648
* tipc_bcbearer_sort - create sets of bearer pairs used by broadcast bearer
662649
*/
663-
664650
void tipc_bcbearer_sort(void)
665651
{
666652
struct tipc_bcbearer_pair *bp_temp = bcbearer->bpairs_temp;
@@ -671,7 +657,6 @@ void tipc_bcbearer_sort(void)
671657
spin_lock_bh(&bc_lock);
672658

673659
/* Group bearers by priority (can assume max of two per priority) */
674-
675660
memset(bp_temp, 0, sizeof(bcbearer->bpairs_temp));
676661

677662
for (b_index = 0; b_index < MAX_BEARERS; b_index++) {
@@ -687,7 +672,6 @@ void tipc_bcbearer_sort(void)
687672
}
688673

689674
/* Create array of bearer pairs for broadcasting */
690-
691675
bp_curr = bcbearer->bpairs;
692676
memset(bcbearer->bpairs, 0, sizeof(bcbearer->bpairs));
693677

@@ -817,7 +801,6 @@ void tipc_bclink_stop(void)
817801
/**
818802
* tipc_nmap_add - add a node to a node map
819803
*/
820-
821804
void tipc_nmap_add(struct tipc_node_map *nm_ptr, u32 node)
822805
{
823806
int n = tipc_node(node);
@@ -833,7 +816,6 @@ void tipc_nmap_add(struct tipc_node_map *nm_ptr, u32 node)
833816
/**
834817
* tipc_nmap_remove - remove a node from a node map
835818
*/
836-
837819
void tipc_nmap_remove(struct tipc_node_map *nm_ptr, u32 node)
838820
{
839821
int n = tipc_node(node);
@@ -852,7 +834,6 @@ void tipc_nmap_remove(struct tipc_node_map *nm_ptr, u32 node)
852834
* @nm_b: input node map B
853835
* @nm_diff: output node map A-B (i.e. nodes of A that are not in B)
854836
*/
855-
856837
static void tipc_nmap_diff(struct tipc_node_map *nm_a,
857838
struct tipc_node_map *nm_b,
858839
struct tipc_node_map *nm_diff)
@@ -878,7 +859,6 @@ static void tipc_nmap_diff(struct tipc_node_map *nm_a,
878859
/**
879860
* tipc_port_list_add - add a port to a port list, ensuring no duplicates
880861
*/
881-
882862
void tipc_port_list_add(struct tipc_port_list *pl_ptr, u32 port)
883863
{
884864
struct tipc_port_list *item = pl_ptr;
@@ -912,7 +892,6 @@ void tipc_port_list_add(struct tipc_port_list *pl_ptr, u32 port)
912892
* tipc_port_list_free - free dynamically created entries in port_list chain
913893
*
914894
*/
915-
916895
void tipc_port_list_free(struct tipc_port_list *pl_ptr)
917896
{
918897
struct tipc_port_list *item;
@@ -923,4 +902,3 @@ void tipc_port_list_free(struct tipc_port_list *pl_ptr)
923902
kfree(item);
924903
}
925904
}
926-

‎net/tipc/bcast.h‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@
4545
* @count: # of nodes in set
4646
* @map: bitmap of node identifiers that are in the set
4747
*/
48-
4948
struct tipc_node_map {
5049
u32 count;
5150
u32 map[MAX_NODES / WSIZE];
@@ -59,7 +58,6 @@ struct tipc_node_map {
5958
* @next: pointer to next entry in list
6059
* @ports: array of port references
6160
*/
62-
6361
struct tipc_port_list {
6462
int count;
6563
struct tipc_port_list *next;
@@ -77,7 +75,6 @@ void tipc_nmap_remove(struct tipc_node_map *nm_ptr, u32 node);
7775
/**
7876
* tipc_nmap_equal - test for equality of node maps
7977
*/
80-
8178
static inline int tipc_nmap_equal(struct tipc_node_map *nm_a, struct tipc_node_map *nm_b)
8279
{
8380
return !memcmp(nm_a, nm_b, sizeof(*nm_a));

0 commit comments

Comments
 (0)