* TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that sexy?) [not found] ` <20010205225411.E70673@hand.dotat.at> @ 2001-02-05 23:15 ` Dan Kegel 2001-02-05 23:20 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that Alan Cox 2001-02-05 23:24 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that sexy?) Tony Finch 0 siblings, 2 replies; 6+ messages in thread From: Dan Kegel @ 2001-02-05 23:15 UTC (permalink / raw) To: Tony Finch; +Cc: Linus Torvalds, linux-kernel Tony Finch wrote: > > Tony Finch <dot@dotat.at> wrote: > >Linus Torvalds <torvalds@transmeta.com> wrote: > >> > >>Without proper uncorking (and it really shouldn't be that hard to > >>add), TCP_NOPUSH simply can't be used in the generic sense. > > > >It was easy :-) I've put up a patch for FreeBSD that adds proper > >uncorking on my homepage <http://apache.org/~fanf/> in the "Stuff" > >section. > > ... and it has been committed to -CURRENT, too. How very cool. How close is TCP_NOPUSH to behaving identically to TCP_CORK now? If it does behave identically, it might be time to standardize the symbolic name for this option, to make apps more portable between the two OS's. (It'd be nice to also standardize the numeric value, in the interest of making the ABI's more compatible, too.) Here are the definitions in the two OS's at the moment: FreeBSD: netinet/tcp.h (from http://minnie.cs.adfa.oz.au/FreeBSD-srctree/newsrc/netinet/tcp.h.html#TCP_NOPUSH ) /* * User-settable options (used with setsockopt). */ #define TCP_NODELAY 0x01 /* don't delay send to coalesce packets */ #define TCP_MAXSEG 0x02 /* set maximum segment size */ #define TCP_NOPUSH 0x04 /* don't push last block of write */ Linux: netinet/tcp.h: /* * User-settable options (used with setsockopt). */ #define TCP_NODELAY 0x01 /* don't delay send to coalesce packets */ #define TCP_MAXSEG 0x02 /* set maximum segment size */ #define TCP_CORK 0x03 /* control sending of partial frames */ - Dan - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/ ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that 2001-02-05 23:15 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that sexy?) Dan Kegel @ 2001-02-05 23:20 ` Alan Cox 2001-02-05 23:24 ` Dan Kegel ` (2 more replies) 2001-02-05 23:24 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that sexy?) Tony Finch 1 sibling, 3 replies; 6+ messages in thread From: Alan Cox @ 2001-02-05 23:20 UTC (permalink / raw) To: dank; +Cc: Tony Finch, Linus Torvalds, linux-kernel > How close is TCP_NOPUSH to behaving identically to TCP_CORK now? > If it does behave identically, it might be time to standardize > the symbolic name for this option, to make apps more portable > between the two OS's. (It'd be nice to also standardize the > numeric value, in the interest of making the ABI's more compatible, too.) That one isnt practical because of the way the implementations handle boolean options. BSD uses bitmask based option setting for the basic options and Linus uses switch statements - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/ ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that 2001-02-05 23:20 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that Alan Cox @ 2001-02-05 23:24 ` Dan Kegel 2001-02-05 23:49 ` Tony Finch 2001-02-06 18:41 ` kuznet 2 siblings, 0 replies; 6+ messages in thread From: Dan Kegel @ 2001-02-05 23:24 UTC (permalink / raw) To: Alan Cox; +Cc: Tony Finch, Linus Torvalds, linux-kernel Alan Cox wrote: > > > How close is TCP_NOPUSH to behaving identically to TCP_CORK now? > > If it does behave identically, it might be time to standardize > > the symbolic name for this option, to make apps more portable > > between the two OS's. (It'd be nice to also standardize the > > numeric value, in the interest of making the ABI's more compatible, too.) > > That one isnt practical because of the way the implementations handle > boolean options. BSD uses bitmask based option setting for the basic > options and Linus uses switch statements OK, well, at least a common symbolic name could be chosen. - Dan - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/ ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that 2001-02-05 23:20 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that Alan Cox 2001-02-05 23:24 ` Dan Kegel @ 2001-02-05 23:49 ` Tony Finch 2001-02-06 18:41 ` kuznet 2 siblings, 0 replies; 6+ messages in thread From: Tony Finch @ 2001-02-05 23:49 UTC (permalink / raw) To: Alan Cox; +Cc: dank, Linus Torvalds, linux-kernel, Tony Finch Alan Cox <alan@lxorguk.ukuu.org.uk> wrote: >> How close is TCP_NOPUSH to behaving identically to TCP_CORK now? >> If it does behave identically, it might be time to standardize >> the symbolic name for this option, to make apps more portable >> between the two OS's. (It'd be nice to also standardize the >> numeric value, in the interest of making the ABI's more compatible, too.) > >That one isnt practical because of the way the implementations handle >boolean options. BSD uses bitmask based option setting for the basic >options and Linus uses switch statements No, that's only true for some of the socket-level options. For the TCP options there isn't a direct correspondance between the option number and the number of the flag in the PCB. Tony. -- f.a.n.finch fanf@covalent.net dot@dotat.at "Dead! And yet there he stands!" - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/ ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that 2001-02-05 23:20 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that Alan Cox 2001-02-05 23:24 ` Dan Kegel 2001-02-05 23:49 ` Tony Finch @ 2001-02-06 18:41 ` kuznet 2 siblings, 0 replies; 6+ messages in thread From: kuznet @ 2001-02-06 18:41 UTC (permalink / raw) To: Alan Cox; +Cc: linux-kernel Hello! > > How close is TCP_NOPUSH to behaving identically to TCP_CORK now? They have not so much of common. TCP_NOPUSH enables T/TCP and its presense used to mean that T/TCP is possible on this system. Linux headers cannot even contain TCP_NOPUSH. Alexey - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/ ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that sexy?) 2001-02-05 23:15 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that sexy?) Dan Kegel 2001-02-05 23:20 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that Alan Cox @ 2001-02-05 23:24 ` Tony Finch 1 sibling, 0 replies; 6+ messages in thread From: Tony Finch @ 2001-02-05 23:24 UTC (permalink / raw) To: Dan Kegel; +Cc: Linus Torvalds, linux-kernel, Tony Finch Dan Kegel <dank@alumni.caltech.edu> wrote: > >How close is TCP_NOPUSH to behaving identically to TCP_CORK now? They are exactly the same. >If it does behave identically, it might be time to standardize >the symbolic name for this option, to make apps more portable >between the two OS's. (It'd be nice to also standardize the >numeric value, in the interest of making the ABI's more compatible, too.) I wonder if it's a bit late for that now... This reminds me to make sure that FreeBSD's Linux emulation supports TCP_CORK properly. Tony. -- f.a.n.finch fanf@covalent.net dot@dotat.at " ``Well, let's go down and find out who's grave it is.'' ``How?'' ``By going down and finding out!'' " - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/ ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2001-02-06 18:42 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <3A66729E.3E9E3C64@alumni.caltech.edu>
[not found] ` <Pine.LNX.4.10.10101172046170.17109-100000@penguin.transmeta.com>
[not found] ` <20010202013104.A48377@hand.dotat.at>
[not found] ` <20010205225411.E70673@hand.dotat.at>
2001-02-05 23:15 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that sexy?) Dan Kegel
2001-02-05 23:20 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that Alan Cox
2001-02-05 23:24 ` Dan Kegel
2001-02-05 23:49 ` Tony Finch
2001-02-06 18:41 ` kuznet
2001-02-05 23:24 ` TCP_NOPUSH on FreeBSD, TCP_CORK on Linux (was: Is sendfile all that sexy?) Tony Finch
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®