| Age | Commit message (Collapse) | Author |
|
sk_alloc_slab becomes proto_register, that receives a struct proto not necessarily
completely filled, but at least with the proto name, owner and obj_size (aka proto
specific sock size), with this we can remove the struct sock sk_owner and sk_slab,
using sk->sk_prot->{owner,slab} instead.
This patch also makes sk_set_owner not necessary anymore, as at sk_alloc time we
have now access to the struct proto onwer and slab members, so we can bump the
module refcount exactly at sock allocation time.
Another nice "side effect" is that this patch removes the generic sk_cachep slab
cache, making the only last two protocols that used it use just kmalloc, informing
a struct proto obj_size equal to sizeof(struct sock).
Ah, almost forgot that with this patch it is very easy to use a slab cache, as it is
now created at proto_register time, and all protocols need to use proto_register,
so its just a matter of switching the second parameter of proto_register to '1', heck,
this can be done even at module load time with some small additional patch.
Another optimization that will be possible in the future is to move the sk_protocol
and sk_type struct sock members to struct proto, but this has to wait for all protocols
to move completely to sk_prot.
This changeset also introduces /proc/net/protocols, that lists the registered protocols
details, some may seem excessive, but I'd like to keep them while working on further
struct sock hierarchy work and also to realize which protocols are old ones, i.e. that
still use struct proto_ops, etc, yeah, this is a bit of an exaggeration, as all protos
still use struct proto_ops, but in time the idea is to move all to use sk->sk_prot and
make the proto_ops infrastructure be shared among all protos, reducing one level of
indirection.
Signed-off-by: Arnaldo Carvalho de Melo <acme@conectiva.com.br>
Signed-off-by: David S. Miller <davem@davemloft.net>
|
|
tos: int -> 8bit
uc_ttl: int -> 16 bit
cmsg_flags: int -> 16 bit
hdrincl: 8bit -> 1 bit
mc_loop: 8bit -> 1 bit
Saves 12 bytes together with the reordering.
Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
|
|
According to RFC2460, PMTU is set to the IPv6 Minimum Link
MTU (1280) and a fragment header should always be included
after a node receiving Too Big message reporting PMTU is
less than the IPv6 Minimum Link MTU (1280).
Signed-off-by: Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>
|
|
No need for two structs, follow the new inet_sock layout style.
Also introduce inet_sk_copy_descendant, to copy just the inet_sock
descendant specific area from one sock to another.
Signed-off-by: Arnaldo Carvalho de Melo <acme@conectiva.com.br>
Signed-off-by: David S. Miller <davem@davemloft.net>
|
|
With this we can remove all the cut'n'pasted layouts in all inet_sock
derived classes, such as tcp_sock, udp_sock, sctp_sock, etc.
Signed-off-by: Arnaldo Carvalho de Melo <acme@conectiva.com.br>
Signed-off-by: David S. Miller <davem@davemloft.net>
|
|
Yeah, the poor cousins will use this as well :-)
|
|
|
|
ipv6 addresses properly.
|
|
|
|
|
|
|
|
|
|
1. Fix illegal dereference of potentially freed memory in xfrm_policy.c
2. Complete wildcard flow addresses to real ones in xfrm_lookup().
3. Respect optional flag when chacking for input policy.
4. Delete orphaned comments in ip.h.
5. Fix mistakedly freed route in tcp connect.
|
|
|
|
- Import va10-hwchecksum-2.5.36.patch
- Import va11-udpsendfile-2.5.36.patch
- Implement new encapsulation friendly ipv4 output path.
|
|
out of struct sock.
Fix -EFAULT handling in TCP direct user copy handling.
Use struct initializers in IPV6 ndisc code.
|
|
Work done by Arnaldo Carvalho de Melo.
|
|
|