Skip to content

Commit cb18ecc

Browse files
author
Linus Torvalds
committed
Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: (45 commits) [IPV4]: Restore multipath routing after rt_next changes. [XFRM] IPV6: Fix outbound RO transformation which is broken by IPsec tunnel patch. [NET]: Reorder fields of struct dst_entry [DECNET]: Convert decnet route to use the new dst_entry 'next' pointer [IPV6]: Convert ipv6 route to use the new dst_entry 'next' pointer [IPV4]: Convert ipv4 route to use the new dst_entry 'next' pointer [NET]: Introduce union in struct dst_entry to hold 'next' pointer [DECNET]: fix misannotation of linkinfo_dn [DECNET]: FRA_{DST,SRC} are le16 for decnet [UDP]: UDP can use sk_hash to speedup lookups [NET]: Fix whitespace errors. [NET] XFRM: Fix whitespace errors. [NET] X25: Fix whitespace errors. [NET] WANROUTER: Fix whitespace errors. [NET] UNIX: Fix whitespace errors. [NET] TIPC: Fix whitespace errors. [NET] SUNRPC: Fix whitespace errors. [NET] SCTP: Fix whitespace errors. [NET] SCHED: Fix whitespace errors. [NET] RXRPC: Fix whitespace errors. ...
2 parents c827ba4 + 5ef213f commit cb18ecc

539 files changed

Lines changed: 9052 additions & 9047 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎include/net/dn_route.h‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,9 +68,10 @@ extern void dn_rt_cache_flush(int delay);
6868
struct dn_route {
6969
union {
7070
struct dst_entry dst;
71-
struct dn_route *rt_next;
7271
} u;
7372

73+
struct flowi fl;
74+
7475
__le16 rt_saddr;
7576
__le16 rt_daddr;
7677
__le16 rt_gateway;
@@ -80,8 +81,6 @@ struct dn_route {
8081

8182
unsigned rt_flags;
8283
unsigned rt_type;
83-
84-
struct flowi fl;
8584
};
8685

8786
extern void dn_route_init(void);

‎include/net/dst.h‎

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,7 @@ struct sk_buff;
3737

3838
struct dst_entry
3939
{
40-
struct dst_entry *next;
41-
atomic_t __refcnt; /* client references */
42-
int __use;
40+
struct rcu_head rcu_head;
4341
struct dst_entry *child;
4442
struct net_device *dev;
4543
short error;
@@ -50,7 +48,6 @@ struct dst_entry
5048
#define DST_NOPOLICY 4
5149
#define DST_NOHASH 8
5250
#define DST_BALANCED 0x10
53-
unsigned long lastuse;
5451
unsigned long expires;
5552

5653
unsigned short header_len; /* more space at head required */
@@ -75,8 +72,16 @@ struct dst_entry
7572
#endif
7673

7774
struct dst_ops *ops;
78-
struct rcu_head rcu_head;
7975

76+
unsigned long lastuse;
77+
atomic_t __refcnt; /* client references */
78+
int __use;
79+
union {
80+
struct dst_entry *next;
81+
struct rtable *rt_next;
82+
struct rt6_info *rt6_next;
83+
struct dn_route *dn_next;
84+
};
8085
char info[0];
8186
};
8287

‎include/net/ip6_fib.h‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,6 @@ struct rt6_info
8383
{
8484
union {
8585
struct dst_entry dst;
86-
struct rt6_info *next;
8786
} u;
8887

8988
struct inet6_dev *rt6i_idev;

‎include/net/route.h‎

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,11 @@ struct rtable
5353
union
5454
{
5555
struct dst_entry dst;
56-
struct rtable *rt_next;
5756
} u;
5857

58+
/* Cache lookup keys */
59+
struct flowi fl;
60+
5961
struct in_device *idev;
6062

6163
unsigned rt_flags;
@@ -69,9 +71,6 @@ struct rtable
6971
/* Info on neighbour */
7072
__be32 rt_gateway;
7173

72-
/* Cache lookup keys */
73-
struct flowi fl;
74-
7574
/* Miscellaneous cached information */
7675
__be32 rt_spec_dst; /* RFC1122 specific destination */
7776
struct inet_peer *peer; /* long-living peer info */

‎net/802/fc.c‎

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
22
* NET3: Fibre Channel device handling subroutines
3-
*
3+
*
44
* This program is free software; you can redistribute it and/or
55
* modify it under the terms of the GNU General Public License
66
* as published by the Free Software Foundation; either version
@@ -31,18 +31,18 @@
3131
#include <net/arp.h>
3232

3333
/*
34-
* Put the headers on a Fibre Channel packet.
34+
* Put the headers on a Fibre Channel packet.
3535
*/
36-
36+
3737
static int fc_header(struct sk_buff *skb, struct net_device *dev,
3838
unsigned short type,
39-
void *daddr, void *saddr, unsigned len)
39+
void *daddr, void *saddr, unsigned len)
4040
{
4141
struct fch_hdr *fch;
4242
int hdr_len;
4343

44-
/*
45-
* Add the 802.2 SNAP header if IP as the IPv4 code calls
44+
/*
45+
* Add the 802.2 SNAP header if IP as the IPv4 code calls
4646
* dev->hard_header directly.
4747
*/
4848
if (type == ETH_P_IP || type == ETH_P_ARP)
@@ -60,28 +60,28 @@ static int fc_header(struct sk_buff *skb, struct net_device *dev,
6060
else
6161
{
6262
hdr_len = sizeof(struct fch_hdr);
63-
fch = (struct fch_hdr *)skb_push(skb, hdr_len);
63+
fch = (struct fch_hdr *)skb_push(skb, hdr_len);
6464
}
6565

6666
if(saddr)
6767
memcpy(fch->saddr,saddr,dev->addr_len);
6868
else
6969
memcpy(fch->saddr,dev->dev_addr,dev->addr_len);
7070

71-
if(daddr)
71+
if(daddr)
7272
{
7373
memcpy(fch->daddr,daddr,dev->addr_len);
7474
return(hdr_len);
7575
}
7676
return -hdr_len;
7777
}
78-
78+
7979
/*
8080
* A neighbour discovery of some species (eg arp) has completed. We
8181
* can now send the packet.
8282
*/
83-
84-
static int fc_rebuild_header(struct sk_buff *skb)
83+
84+
static int fc_rebuild_header(struct sk_buff *skb)
8585
{
8686
struct fch_hdr *fch=(struct fch_hdr *)skb->data;
8787
struct fcllc *fcllc=(struct fcllc *)(skb->data+sizeof(struct fch_hdr));
@@ -100,7 +100,7 @@ static void fc_setup(struct net_device *dev)
100100
{
101101
dev->hard_header = fc_header;
102102
dev->rebuild_header = fc_rebuild_header;
103-
103+
104104
dev->type = ARPHRD_IEEE802;
105105
dev->hard_header_len = FC_HLEN;
106106
dev->mtu = 2024;

‎net/802/fddi.c‎

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
* Mark Evans, <evansmp@uhura.aston.ac.uk>
1616
* Florian La Roche, <rzsfl@rz.uni-sb.de>
1717
* Alan Cox, <gw4pts@gw4pts.ampr.org>
18-
*
18+
*
1919
* This program is free software; you can redistribute it and/or
2020
* modify it under the terms of the GNU General Public License
2121
* as published by the Free Software Foundation; either version
@@ -25,7 +25,7 @@
2525
* Alan Cox : New arp/rebuild header
2626
* Maciej W. Rozycki : IPv6 support
2727
*/
28-
28+
2929
#include <linux/module.h>
3030
#include <asm/system.h>
3131
#include <linux/types.h>
@@ -57,7 +57,7 @@ static int fddi_header(struct sk_buff *skb, struct net_device *dev,
5757
{
5858
int hl = FDDI_K_SNAP_HLEN;
5959
struct fddihdr *fddi;
60-
60+
6161
if(type != ETH_P_IP && type != ETH_P_IPV6 && type != ETH_P_ARP)
6262
hl=FDDI_K_8022_HLEN-3;
6363
fddi = (struct fddihdr *)skb_push(skb, hl);
@@ -74,7 +74,7 @@ static int fddi_header(struct sk_buff *skb, struct net_device *dev,
7474
}
7575

7676
/* Set the source and destination hardware addresses */
77-
77+
7878
if (saddr != NULL)
7979
memcpy(fddi->saddr, saddr, dev->addr_len);
8080
else
@@ -95,7 +95,7 @@ static int fddi_header(struct sk_buff *skb, struct net_device *dev,
9595
* (or in future other address resolution) has completed on
9696
* this sk_buff. We now let ARP fill in the other fields.
9797
*/
98-
98+
9999
static int fddi_rebuild_header(struct sk_buff *skb)
100100
{
101101
struct fddihdr *fddi = (struct fddihdr *)skb->data;
@@ -105,7 +105,7 @@ static int fddi_rebuild_header(struct sk_buff *skb)
105105
/* Try to get ARP to resolve the header and fill destination address */
106106
return arp_find(fddi->daddr, skb);
107107
else
108-
#endif
108+
#endif
109109
{
110110
printk("%s: Don't know how to resolve type %04X addresses.\n",
111111
skb->dev->name, ntohs(fddi->hdr.llc_snap.ethertype));
@@ -120,19 +120,19 @@ static int fddi_rebuild_header(struct sk_buff *skb)
120120
* up. It's used to fill in specific skb fields and to set
121121
* the proper pointer to the start of packet data (skb->data).
122122
*/
123-
123+
124124
__be16 fddi_type_trans(struct sk_buff *skb, struct net_device *dev)
125125
{
126126
struct fddihdr *fddi = (struct fddihdr *)skb->data;
127127
__be16 type;
128-
128+
129129
/*
130130
* Set mac.raw field to point to FC byte, set data field to point
131131
* to start of packet data. Assume 802.2 SNAP frames for now.
132132
*/
133133

134134
skb->mac.raw = skb->data; /* point to frame control (FC) */
135-
135+
136136
if(fddi->hdr.llc_8022_1.dsap==0xe0)
137137
{
138138
skb_pull(skb, FDDI_K_8022_HLEN-3);
@@ -143,17 +143,17 @@ __be16 fddi_type_trans(struct sk_buff *skb, struct net_device *dev)
143143
skb_pull(skb, FDDI_K_SNAP_HLEN); /* adjust for 21 byte header */
144144
type=fddi->hdr.llc_snap.ethertype;
145145
}
146-
146+
147147
/* Set packet type based on destination address and flag settings */
148-
148+
149149
if (*fddi->daddr & 0x01)
150150
{
151151
if (memcmp(fddi->daddr, dev->broadcast, FDDI_K_ALEN) == 0)
152152
skb->pkt_type = PACKET_BROADCAST;
153153
else
154154
skb->pkt_type = PACKET_MULTICAST;
155155
}
156-
156+
157157
else if (dev->flags & IFF_PROMISC)
158158
{
159159
if (memcmp(fddi->daddr, dev->dev_addr, FDDI_K_ALEN))
@@ -187,7 +187,7 @@ static void fddi_setup(struct net_device *dev)
187187
dev->addr_len = FDDI_K_ALEN;
188188
dev->tx_queue_len = 100; /* Long queues on FDDI */
189189
dev->flags = IFF_BROADCAST | IFF_MULTICAST;
190-
190+
191191
memset(dev->broadcast, 0xFF, FDDI_K_ALEN);
192192
}
193193

‎net/802/hippi.c‎

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
#include <asm/system.h>
4040

4141
/*
42-
* Create the HIPPI MAC header for an arbitrary protocol layer
42+
* Create the HIPPI MAC header for an arbitrary protocol layer
4343
*
4444
* saddr=NULL means use device source address
4545
* daddr=NULL means leave destination address (eg unresolved arp)
@@ -104,8 +104,8 @@ static int hippi_rebuild_header(struct sk_buff *skb)
104104
/*
105105
* Only IP is currently supported
106106
*/
107-
108-
if(hip->snap.ethertype != __constant_htons(ETH_P_IP))
107+
108+
if(hip->snap.ethertype != __constant_htons(ETH_P_IP))
109109
{
110110
printk(KERN_DEBUG "%s: unable to resolve type %X addresses.\n",skb->dev->name,ntohs(hip->snap.ethertype));
111111
return 0;
@@ -122,11 +122,11 @@ static int hippi_rebuild_header(struct sk_buff *skb)
122122
/*
123123
* Determine the packet's protocol ID.
124124
*/
125-
125+
126126
__be16 hippi_type_trans(struct sk_buff *skb, struct net_device *dev)
127127
{
128128
struct hippi_hdr *hip;
129-
129+
130130
hip = (struct hippi_hdr *) skb->data;
131131

132132
/*
@@ -173,10 +173,10 @@ static int hippi_neigh_setup_dev(struct net_device *dev, struct neigh_parms *p)
173173
{
174174
/* Never send broadcast/multicast ARP messages */
175175
p->mcast_probes = 0;
176-
176+
177177
/* In IPv6 unicast probes are valid even on NBMA,
178178
* because they are encapsulated in normal IPv6 protocol.
179-
* Should be a generic flag.
179+
* Should be a generic flag.
180180
*/
181181
if (p->tbl->family != AF_INET6)
182182
p->ucast_probes = 0;
@@ -193,7 +193,7 @@ static void hippi_setup(struct net_device *dev)
193193
dev->hard_header_parse = NULL;
194194
dev->hard_header_cache = NULL;
195195
dev->header_cache_update = NULL;
196-
dev->neigh_setup = hippi_neigh_setup_dev;
196+
dev->neigh_setup = hippi_neigh_setup_dev;
197197

198198
/*
199199
* We don't support HIPPI `ARP' for the time being, and probably
@@ -210,9 +210,9 @@ static void hippi_setup(struct net_device *dev)
210210

211211
/*
212212
* HIPPI doesn't support broadcast+multicast and we only use
213-
* static ARP tables. ARP is disabled by hippi_neigh_setup_dev.
213+
* static ARP tables. ARP is disabled by hippi_neigh_setup_dev.
214214
*/
215-
dev->flags = 0;
215+
dev->flags = 0;
216216
}
217217

218218
/**

‎net/802/psnap.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ module_exit(snap_exit);
117117
*/
118118
struct datalink_proto *register_snap_client(unsigned char *desc,
119119
int (*rcvfunc)(struct sk_buff *,
120-
struct net_device *,
120+
struct net_device *,
121121
struct packet_type *,
122122
struct net_device *))
123123
{

0 commit comments

Comments
 (0)