2005-03-04 13:04:36

by se go

[permalink] [raw]
Subject: TCP ACKs carrying data

Hello,

i got some problems concerning tcp realization in kernel (v 2.4).

i need to make some modifications to tcp to be able to transfer data within ACK segments...(initially their data field is empty)

i suppose i should modify the following functions:

/net/ipv4/tcp_input.c > tcp_ack() - for processing incoming acks, to read data from their data field

and

/net/ipv4/tcp_output.c > tcp_send_ack() - for processing outgoing acks, to put data in them

my questions are:
- am i right in my decision?
- what problems these modifications may cause (i tried to modify and they do cause!... i just cannot understand what they are)
- what functions else i may need to modify?
- how must i modify ACKs to make them do what i want and to make linux kernel correctly treating them.

if you need i can reply the list of modifications i've done.

i'd like to be personally CC'd.


thanks in advance,

Serge Goodenko
Moscow Institute of Physics and Technology
Moscow, Russia


2005-03-04 13:24:51

by Michael Tokarev

[permalink] [raw]
Subject: Re: TCP ACKs carrying data

se go wrote:
> Hello,
>
> i got some problems concerning tcp realization in kernel (v 2.4).
>
> i need to make some modifications to tcp to be able to transfer data within ACK segments...(initially their data field is empty)

I thought it is already here. That is, if the kernel have something
to send at the moment when incoming packet arrives, it sends one
packet out, containing both the ACK for previously received packet
and the data.

Ie, if the app is sending data in both directions, there will be no
(well, almost: initial handshake and final sequence are still unique)
"bare" ACKs, or packets without data.

Or Am I just dreaming? ;)

/mjt