Page MenuHomeFreeBSD

D49437.diff
No OneTemporary

D49437.diff

diff --git a/sys/kern/uipc_socket.c b/sys/kern/uipc_socket.c
--- a/sys/kern/uipc_socket.c
+++ b/sys/kern/uipc_socket.c
@@ -592,11 +592,6 @@
/*
* Transfer data from the source to the sink.
- *
- * If "direct" is true, the transfer is done in the context of whichever thread
- * is operating on one of the socket buffers. We do not know which locks are
- * held, so we can only trylock the socket buffers; if this fails, we fall back
- * to the worker thread, which invokes this routine with "direct" set to false.
*/
static void
so_splice_xfer(struct so_splice *sp)
@@ -1638,7 +1633,7 @@
sp->wq_index = atomic_fetchadd_32(&splice_index, 1) %
(mp_maxid + 1);
} while (CPU_ABSENT(sp->wq_index));
- sp->state = SPLICE_IDLE;
+ sp->state = SPLICE_INIT;
TIMEOUT_TASK_INIT(taskqueue_thread, &sp->timeout, 0, so_splice_timeout,
sp);
return (sp);
diff --git a/sys/sys/socketvar.h b/sys/sys/socketvar.h
--- a/sys/sys/socketvar.h
+++ b/sys/sys/socketvar.h
@@ -80,6 +80,7 @@
struct mtx mtx;
unsigned int wq_index;
enum so_splice_state {
+ SPLICE_INIT, /* embryonic state, don't queue work yet */
SPLICE_IDLE, /* waiting for work to arrive */
SPLICE_QUEUED, /* a wakeup has queued some work */
SPLICE_RUNNING, /* currently transferring data */

File Metadata

Mime Type
text/plain
Expires
Sun, Mar 23, 2:47 PM (2 h, 24 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
17269201
Default Alt Text
D49437.diff (1 KB)

Event Timeline