netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Splice on blocking TCP sockets again..
@ 2009-09-30  0:48 Jason Gunthorpe
  2009-09-30  4:54 ` Eric Dumazet
  2009-09-30  6:37 ` Volker Lendecke
  0 siblings, 2 replies; 10+ messages in thread
From: Jason Gunthorpe @ 2009-09-30  0:48 UTC (permalink / raw)
  To: Eric Dumazet, netdev; +Cc: David S. Miller, Volker Lendecke

Eric,

I saw your patch from January regarding splicing on blocking sockets,
and I wondered what ever happened to it?

http://lkml.org/lkml/2009/1/13/507

It doesn't look like it has been applied.. I see the patch thread died
at davem's comments?

I have run into exactly the same problem as Samba, where I'd like the
TCP socket to be blocking, and the pipe to be non blocking ...

As it stands, 
  splice(socket,0,pipe,0,128*1024,SPLICE_F_MOVE); 
causes a random endless block and
  splice(socket,0,pipe,0,128*1024,SPLICE_F_MOVE | SPLICE_F_NONBLOCK);
will return 0 immediately if the TCP buffer is empty.

FWIW, it looks like samba has a splice code now, but doesn't enable it
due to this issue?

http://git.samba.org/?p=samba.git;a=history;f=source3/lib/recvfile.c;h=ea0159642137390a0f7e57a123684e6e63e47581;hb=HEAD

Thanks,
Jason

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2009-10-02 18:05 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-09-30  0:48 Splice on blocking TCP sockets again Jason Gunthorpe
2009-09-30  4:54 ` Eric Dumazet
2009-09-30  5:40   ` Jason Gunthorpe
2009-09-30  5:51     ` Eric Dumazet
2009-09-30  6:00       ` Eric Dumazet
2009-09-30  6:19         ` Eric Dumazet
2009-10-01 22:17         ` Jason Gunthorpe
2009-09-30  6:37 ` Volker Lendecke
2009-10-02 17:10   ` Jason Gunthorpe
2009-10-02 18:05     ` Eric Dumazet

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).