* struct sock size limit?
@ 2002-10-27 5:44 Cheng Jin
2002-10-27 6:18 ` Arnaldo Carvalho de Melo
0 siblings, 1 reply; 2+ messages in thread
From: Cheng Jin @ 2002-10-27 5:44 UTC (permalink / raw)
To: netdev
Hi,
I have been adding members to struct sock (by changing struct tcp_opt) in
linux 2.4.18-3 kernel. I haven't had problems with the kernel until
today. When I added a few more bytes (~ 20 bytes) on top of my old
addition (around 80 bytes), the kernel would crash calling udp_sendmsg
(syslogd initialization). I suspect that there may be some kind of size
limit with struct sock/tcp_opt. The TCP connected state is checked
from within udp_sendmsg (no idea why that is so).
I searched around on google, but didn't find anything on struct sock or
struct tcp_opt. Does anyone know whether the size of struct sock/tcp_opt
is capped?
Thanks a lot,
Cheng
Lab # 626 395 8820
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: struct sock size limit?
2002-10-27 5:44 struct sock size limit? Cheng Jin
@ 2002-10-27 6:18 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 2+ messages in thread
From: Arnaldo Carvalho de Melo @ 2002-10-27 6:18 UTC (permalink / raw)
To: Cheng Jin; +Cc: netdev
Em Sat, Oct 26, 2002 at 10:44:03PM -0700, Cheng Jin escreveu:
> Hi,
>
> I have been adding members to struct sock (by changing struct tcp_opt) in
> linux 2.4.18-3 kernel. I haven't had problems with the kernel until
> today. When I added a few more bytes (~ 20 bytes) on top of my old
> addition (around 80 bytes), the kernel would crash calling udp_sendmsg
beware the data dependencies of struct sock and tcp_tw_bucket, etc, I
bet you're adding new struct members at the start of struct sock, see the
comment in include/net/tcp.h, just above struct tcp_tw_bucket definition...
and also study current include/net/sock.h in 2.5, this thing was all
changed (for the better 8) ).
> (syslogd initialization). I suspect that there may be some kind of size
> limit with struct sock/tcp_opt. The TCP connected state is checked
> from within udp_sendmsg (no idea why that is so).
so look at other protocols such as decnet that also uses the TCP_ state
macros :-) its just reusing those macros.
> I searched around on google, but didn't find anything on struct sock or
> struct tcp_opt. Does anyone know whether the size of struct sock/tcp_opt
> is capped?
>
> Thanks a lot,
>
> Cheng
>
> Lab # 626 395 8820
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-10-27 6:18 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-10-27 5:44 struct sock size limit? Cheng Jin
2002-10-27 6:18 ` Arnaldo Carvalho de Melo
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.