24 Apr, 2008
1 commit
-
Plan C: we can follow the Al Viro's proposal about %n like in this patch.
The same applies to udp, fib (the /proc/net/route file), rt_cache and
sctp debug. This is minus ~150-200 bytes for each.Signed-off-by: Pavel Emelyanov
Signed-off-by: David S. Miller
18 Apr, 2008
1 commit
-
According to RFC4960 7.2.2,
When all of the data transmitted by the sender has
been acknowledged by the recerver, partial_bytes_acked is initialized to 0.This patch conforms to rfc requirement.
Without this fix, cwnd might be error incremented.Signed-off-by: Gui Jianfeng
Acked-by: Vlad Yasevich
Signed-off-by: David S. Miller
14 Apr, 2008
1 commit
-
Conflicts:
drivers/net/ehea/ehea_main.c
drivers/net/wireless/iwlwifi/Kconfig
drivers/net/wireless/rt2x00/rt61pci.c
net/ipv4/inet_timewait_sock.c
net/ipv6/raw.c
net/mac80211/ieee80211_sta.c
13 Apr, 2008
7 commits
-
The 'asoc' parameter to sctp_cmd_hb_timer_update() is unused, and
we can remove it.Signed-off-by: Gui Jianfeng
Signed-off-by: Vlad Yasevich
Signed-off-by: David S. Miller -
Replacing (almost) all invocations of list_for_each() with
list_for_each_entry() tightens up the code and allows for the deletion
of numerous list iterator variables that are no longer necessary.Signed-off-by: Robert P. J. Day
Signed-off-by: Vlad Yasevich
Signed-off-by: David S. Miller -
Recently I posted a patch to add some informational items to
/proc/net/sctp/assocs. All the information is correct, but because
of how the seqfile show operation is laid out, some of the formatting
is backwards. This patch corrects that formatting, so that the new
information appears at the end of each line, rather than in the middle.Signed-off-by: Neil Horman
Signed-off-by: Vlad Yasevich
Signed-off-by: David S. Miller -
All IP addresses that are present in a system are duplicated on
struct sctp_sockaddr_entry. They are linked in the global list
called sctp_local_addr_list. And this struct unions IPv4 and IPv6
addresses.So, there can be rare case, when a sockaddr_in.sin_addr coincides
with the corresponding part of the sockaddr_in6 and the notifier
for IPv4 will carry away an IPv6 entry.The fix is to check the family before comparing the addresses.
Signed-off-by: Pavel Emelyanov
Signed-off-by: Vlad Yasevich
Signed-off-by: David S. Miller -
Fix 3 warnings about discarding const qualifiers:
net/sctp/ulpevent.c:862: warning: passing argument 1 of 'sctp_event2skb' discards qualifiers from pointer target type
net/sctp/sm_statefuns.c:4393: warning: passing argument 1 of 'SCTP_ASOC' discards qualifiers from pointer target type
net/sctp/socket.c:5874: warning: passing argument 1 of 'cmsg_nxthdr' discards qualifiers from pointer target typeSigned-off-by: Vlad Yasevich
Signed-off-by: David S. Miller -
When receiving an error length INIT-ACK during COOKIE-WAIT,
a 0-vtag ABORT will be responsed. This action violates the
protocol apparently. This patch achieves the following things.
1 If the INIT-ACK contains all the fixed parameters, use init-tag
recorded from INIT-ACK as vtag.
2 If the INIT-ACK doesn't contain all the fixed parameters,
just reflect its vtag.Signed-off-by: Gui Jianfeng
Signed-off-by: Vlad Yasevich
Signed-off-by: David S. Miller -
RFC 4890 has the following text:
The HMAC algorithm based on SHA-1 MUST be supported and
included in the HMAC-ALGO parameter.As a result, we need to check in sctp_verify_param() that HMAC_SHA1 is
present in the list. If not, we should probably treat this as a
protocol violation.It should also be a protocol violation if the HMAC parameter is empty.
Signed-off-by: Wei Yongjun
Signed-off-by: Vlad Yasevich
Signed-off-by: David S. Miller
10 Apr, 2008
4 commits
-
Signed-off-by: YOSHIFUJI Hideaki
Signed-off-by: David S. Miller -
Signed-off-by: Gui Jianfeng
Signed-off-by: David S. Miller -
Should not count it if the allocation of the object
is failed.Signed-off-by: Li Zefan
Signed-off-by: David S. Miller -
Should not count it if the allocation of this object
failed.Signed-off-by: Li Zefan
Signed-off-by: David S. Miller
04 Apr, 2008
4 commits
-
This is a generic requirement, so make inet_ctl_sock_create namespace
aware and create a inet_ctl_sock_destroy wrapper around
sk_release_kernel.Signed-off-by: Denis V. Lunev
Acked-by: Arnaldo Carvalho de Melo
Signed-off-by: David S. Miller -
All upper protocol layers are already use sock internally.
Signed-off-by: Denis V. Lunev
Acked-by: Arnaldo Carvalho de Melo
Signed-off-by: David S. Miller -
Signed-off-by: Denis V. Lunev
Acked-by: Arnaldo Carvalho de Melo
Signed-off-by: David S. Miller -
sk->sk_proc->(un)hash is noop right now, so the unification is correct.
Signed-off-by: Denis V. Lunev
Acked-by: Arnaldo Carvalho de Melo
Signed-off-by: David S. Miller
29 Mar, 2008
1 commit
-
An uppercut - do not use the pcounter on struct proto.
Signed-off-by: Pavel Emelyanov
Acked-by: Eric Dumazet
Signed-off-by: David S. Miller
28 Mar, 2008
1 commit
-
With a was number of callsites sctp_add_cmd_sf wrapper bloats
kernel by some amount. Due to unlikely tracking allyesconfig,
with the initial result were around ~7kB (thus caught my
attention) while a non-debug config produced only ~2.3kB effect.I (ij) proposed first a patch to uninline it but Vlad responded
with a patch that removed the only sctp_add_cmd call which is
wrapped by sctp_add_cmd_sf (I wasn't sure if I could do that).
I did minor cleanup to Vlad's patch.Signed-off-by: Ilpo Järvinen
Signed-off-by: Vlad Yasevich
Signed-off-by: David S. Miller
26 Mar, 2008
2 commits
-
Introduce per-sock inlines: sock_net(), sock_net_set()
and per-inet_timewait_sock inlines: twsk_net(), twsk_net_set().
Without CONFIG_NET_NS, no namespace other than &init_net exists.
Let's explicitly define them to help compiler optimizations.Signed-off-by: YOSHIFUJI Hideaki
-
Introduce per-net_device inlines: dev_net(), dev_net_set().
Without CONFIG_NET_NS, no namespace other than &init_net exists.
Let's explicitly define them to help compiler optimizations.Signed-off-by: YOSHIFUJI Hideaki
25 Mar, 2008
1 commit
-
Signed-off-by: YOSHIFUJI Hideaki
24 Mar, 2008
2 commits
-
sctp_datamsg_free and sctp_datamsg_track are just aliases for
sctp_datamsg_put and sctp_chunk_hold, respectively.Saves 32 Bytes on x86.
Signed-off-by: Florian Westphal
Signed-off-by: David S. Miller -
133886 2004 220 136110 213ae sctp.new/sctp.o
134018 2004 220 136242 21432 sctp.old/sctp.oSigned-off-by: Florian Westphal
Signed-off-by: David S. Miller
21 Mar, 2008
2 commits
-
There is a race is SCTP between the loading of the module
and the access by the socket layer to the protocol functions.
In particular, a list of addresss that SCTP maintains is
not initialized prior to the registration with the protosw.
Thus it is possible for a user application to gain access
to SCTP functions before everything has been initialized.
The problem shows up as odd crashes during connection
initializtion when we try to access the SCTP address list.The solution is to refactor how we do registration and
initialize the lists prior to registering with the protosw.
Care must be taken since the address list initialization
depends on some other pieces of SCTP initialization. Also
the clean-up in case of failure now also needs to be refactored.Signed-off-by: Vlad Yasevich
Acked-by: Sridhar Samudrala
Signed-off-by: David S. Miller
18 Mar, 2008
3 commits
-
Conflicts:
drivers/net/wireless/rt2x00/rt2x00dev.c
net/8021q/vlan_dev.c -
Signed-off-by: Al Viro
Signed-off-by: David S. Miller -
Signed-off-by: Al Viro
Signed-off-by: David S. Miller
12 Mar, 2008
1 commit
-
Since the lists are circular, we need to explicitely tag
the address to be deleted since we might end up freeing
the list head instead. This fixes some interesting SCTP
crashes.Signed-off-by: Chidambar 'ilLogict' Zinnoury
Signed-off-by: Vlad Yasevich
Signed-off-by: David S. Miller
06 Mar, 2008
6 commits
-
__FUNCTION__ is gcc-specific, use __func__
Signed-off-by: Harvey Harrison
Signed-off-by: David S. Miller -
(Anonymous) unions can help us to avoid ugly casts.
A common cast it the (struct rtable *)skb->dst one.
Defining an union like :
union {
struct dst_entry *dst;
struct rtable *rtable;
};
permits to use skb->rtable in place.Signed-off-by: Eric Dumazet
Signed-off-by: David S. Miller -
Brings max_burst socket option set/get into line with the latest ietf
socket extensions api draft, while maintaining backwards
compatibility.Signed-off-by: Neil Horman
Signed-off-by: Vlad Yasevich
Signed-off-by: David S. Miller -
If an address family is not listed in "Supported Address Types"
parameter(INIT Chunk), but the packet is sent by that family, this
address family should be considered as supported by peer. Otherwise,
an error condition will occur. For instance, if kernel receives an
IPV6 SCTP INIT chunk with "Support Address Types" parameter which
indicates just supporting IPV4 Address family. Kernel will reply an
IPV6 SCTP INIT ACK packet, but the source ipv6 address in ipv6 header
will be vacant. This is not correct.refer to RFC4460 as following:
IMPLEMENTATION NOTE: If an SCTP endpoint lists in the 'Supported
Address Types' parameter either IPv4 or IPv6, but uses the other
family for sending the packet containing the INIT chunk, or if it
also lists addresses of the other family in the INIT chunk, then
the address family that is not listed in the 'Supported Address
Types' parameter SHOULD also be considered as supported by the
receiver of the INIT chunk. The receiver of the INIT chunk SHOULD
NOT respond with any kind of error indication.Here is a fix to comply to RFC.
Signed-off-by: Gui Jianfeng
Acked-by: Vlad Yasevich
Signed-off-by: David S. Miller -
Conflicts:
net/mac80211/rc80211_pid_algo.c
-
Add an netns parameter to ip6_route_output. That will allow to access
to the right routing table for outgoing traffic.Signed-off-by: Daniel Lezcano
Signed-off-by: Benjamin Thery
Signed-off-by: David S. Miller
04 Mar, 2008
2 commits
-
Since most users of ipv6_get_saddr() pass non-NULL as
dst argument, use ipv6_dev_get_saddr() directly.Signed-off-by: YOSHIFUJI Hideaki
-
sctp_association->hbinterval is unsigned long. Replace %8d with %8lu.
Signed-off-by: Denis V. Lunev
Signed-off-by: David S. Miller
01 Mar, 2008
1 commit
-
RFC 3873 specifies several MIB objects that can't be obtained by the
current data set exported by /proc/sys/net/sctp/assoc. This patch
adds the missing pieces of data that allow us to compute all the
objects in the sctpAssocTable object.Signed-off-by: Neil Horman
Signed-off-by: Vlad Yasevich
Signed-off-by: David S. Miller