Re: [PATCH] sendfile() and UDP socket

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: David Miller
Date: Sunday, September 21, 2008 - 1:04 am

From: Johann Baudy <johaahn@gmail.com>
Date: Sun, 14 Sep 2008 12:25:56 +0200


Applications which work over datagram protocols must perform their own
segmentation.  It is not like doing a send over a stream protocol like
TCP, where you can use whatever length you want for send calls and
segmentation is done for the application.

If you look, this is what things like NFS using SUNRPC over UDP do.
They have a transmission unit for the data transfer and use that for
each "send".

A sendfile() with length >= 64K is the same as a sendmsg() with such a
length, which is defined as:

	if (len > 0xFFFF)
		return -EMSGSIZE;

So we could technically even return an error for this sendfile() over
UDP case.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] sendfile() and UDP socket, Johann Baudy, (Sun Sep 14, 3:25 am)
Re: [PATCH] sendfile() and UDP socket, Simon Horman, (Mon Sep 15, 9:17 pm)
Re: [PATCH] sendfile() and UDP socket, Simon Horman, (Mon Sep 15, 9:24 pm)
Re: [PATCH] sendfile() and UDP socket, Hirokazu Takahashi, (Tue Sep 16, 5:01 am)
Re: [PATCH] sendfile() and UDP socket, Rémi Denis-Courmont, (Thu Sep 18, 10:31 am)
Re: [PATCH] sendfile() and UDP socket, Hirokazu Takahashi, (Fri Sep 19, 5:28 am)
Re: [PATCH] sendfile() and UDP socket, Rémi Denis-Courmont, (Fri Sep 19, 6:14 am)
Re: [PATCH] sendfile() and UDP socket, David Miller, (Sun Sep 21, 1:04 am)
Re: [PATCH] sendfile() and UDP socket, Evgeniy Polyakov, (Sun Sep 21, 5:21 pm)
Re: [PATCH] sendfile() and UDP socket, David Miller, (Sun Sep 21, 5:44 pm)
Re: [PATCH] sendfile() and UDP socket, Evgeniy Polyakov, (Sun Sep 21, 6:08 pm)
Re: [PATCH] sendfile() and UDP socket, David Miller, (Sun Sep 21, 7:07 pm)
Re: [PATCH] sendfile() and UDP socket, Evgeniy Polyakov, (Sun Sep 21, 9:19 pm)
Re: [PATCH] sendfile() and UDP socket, David Miller, (Sun Sep 21, 9:27 pm)
Re: [PATCH] sendfile() and UDP socket, Evgeniy Polyakov, (Sun Sep 21, 9:40 pm)
Re: [PATCH] sendfile() and UDP socket, David Miller, (Sun Sep 21, 10:06 pm)
Re: [PATCH] sendfile() and UDP socket, Evgeniy Polyakov, (Sun Sep 21, 10:49 pm)
Re: [PATCH] sendfile() and UDP socket, David Miller, (Sun Sep 21, 11:54 pm)
Re: [PATCH] sendfile() and UDP socket, Evgeniy Polyakov, (Mon Sep 22, 12:04 am)
Re: [PATCH] sendfile() and UDP socket, Herbert Xu, (Mon Sep 22, 9:54 pm)
Re: [PATCH] sendfile() and UDP socket, Evgeniy Polyakov, (Mon Sep 22, 11:27 pm)
Re: [PATCH] sendfile() and UDP socket, Herbert Xu, (Tue Sep 23, 12:01 am)
Re: [PATCH] sendfile() and UDP socket, Evgeniy Polyakov, (Tue Sep 23, 12:07 am)
Re: [PATCH] sendfile() and UDP socket, Bill Fink, (Tue Sep 23, 9:53 pm)
Using skb_get() to recycle skbs, Ram.Natarajan, (Thu Sep 25, 6:03 am)
Re: Using skb_get() to recycle skbs, Evgeniy Polyakov, (Thu Sep 25, 7:28 am)