# HG changeset patch # User Igor Sysoev # Date 1229546838 0 # Node ID cc13ff6d5c07b1f5bd06f0ce0325521521644a9f # Parent 89ac47d91fc15b05654facd8bf1720556dcc612e remove never used zero copy stuff diff --git a/src/core/ngx_buf.c b/src/core/ngx_buf.c --- a/src/core/ngx_buf.c +++ b/src/core/ngx_buf.c @@ -201,12 +201,6 @@ ngx_chain_update_chains(ngx_chain_t **fr break; } -#if (NGX_HAVE_WRITE_ZEROCOPY) - if ((*busy)->buf->zerocopy_busy) { - break; - } -#endif - if ((*busy)->buf->tag != tag) { *busy = (*busy)->next; continue; diff --git a/src/core/ngx_buf.h b/src/core/ngx_buf.h --- a/src/core/ngx_buf.h +++ b/src/core/ngx_buf.h @@ -51,8 +51,6 @@ struct ngx_buf_s { unsigned last_shadow:1; unsigned temp_file:1; - unsigned zerocopy_busy:1; - /* STUB */ int num; }; diff --git a/src/core/ngx_palloc.h b/src/core/ngx_palloc.h --- a/src/core/ngx_palloc.h +++ b/src/core/ngx_palloc.h @@ -14,7 +14,6 @@ /* * NGX_MAX_ALLOC_FROM_POOL should be (ngx_pagesize - 1), i.e. 4095 on x86. - * On FreeBSD 5.x it allows to use the zero copy sending. * On Windows NT it decreases a number of locked pages in a kernel. */ #define NGX_MAX_ALLOC_FROM_POOL (ngx_pagesize - 1) diff --git a/src/http/modules/ngx_http_charset_filter_module.c b/src/http/modules/ngx_http_charset_filter_module.c --- a/src/http/modules/ngx_http_charset_filter_module.c +++ b/src/http/modules/ngx_http_charset_filter_module.c @@ -541,12 +541,6 @@ ngx_http_charset_body_filter(ngx_http_re break; } -#if (NGX_HAVE_WRITE_ZEROCOPY) - if (b->zerocopy_busy) { - break; - } -#endif - ctx->busy = cl->next; if (b->tag != (ngx_buf_tag_t) &ngx_http_charset_filter_module) { diff --git a/src/http/modules/ngx_http_ssi_filter_module.c b/src/http/modules/ngx_http_ssi_filter_module.c --- a/src/http/modules/ngx_http_ssi_filter_module.c +++ b/src/http/modules/ngx_http_ssi_filter_module.c @@ -935,12 +935,6 @@ ngx_http_ssi_output(ngx_http_request_t * break; } -#if (NGX_HAVE_WRITE_ZEROCOPY) - if (b->zerocopy_busy) { - break; - } -#endif - if (b->shadow) { b->shadow->pos = b->shadow->last; } diff --git a/src/http/modules/ngx_http_sub_filter_module.c b/src/http/modules/ngx_http_sub_filter_module.c --- a/src/http/modules/ngx_http_sub_filter_module.c +++ b/src/http/modules/ngx_http_sub_filter_module.c @@ -465,12 +465,6 @@ ngx_http_sub_output(ngx_http_request_t * break; } -#if (NGX_HAVE_WRITE_ZEROCOPY) - if (b->zerocopy_busy) { - break; - } -#endif - if (b->shadow) { b->shadow->pos = b->shadow->last; } diff --git a/src/os/unix/ngx_freebsd.h b/src/os/unix/ngx_freebsd.h --- a/src/os/unix/ngx_freebsd.h +++ b/src/os/unix/ngx_freebsd.h @@ -14,7 +14,6 @@ ngx_chain_t *ngx_freebsd_sendfile_chain( extern int ngx_freebsd_kern_osreldate; extern int ngx_freebsd_hw_ncpu; extern u_long ngx_freebsd_net_inet_tcp_sendspace; -extern int ngx_freebsd_kern_ipc_zero_copy_send; extern ngx_uint_t ngx_freebsd_sendfile_nbytes_bug; extern ngx_uint_t ngx_freebsd_use_tcp_nopush; diff --git a/src/os/unix/ngx_freebsd_init.c b/src/os/unix/ngx_freebsd_init.c --- a/src/os/unix/ngx_freebsd_init.c +++ b/src/os/unix/ngx_freebsd_init.c @@ -19,9 +19,6 @@ u_long ngx_freebsd_net_inet_tcp_sendspa /* FreeBSD 4.9 */ int ngx_freebsd_machdep_hlt_logical_cpus; -/* FreeBSD 5.0 */ -int ngx_freebsd_kern_ipc_zero_copy_send; - ngx_uint_t ngx_freebsd_sendfile_nbytes_bug; ngx_uint_t ngx_freebsd_use_tcp_nopush; @@ -68,10 +65,6 @@ sysctl_t sysctls[] = { &ngx_freebsd_kern_ipc_somaxconn, sizeof(ngx_freebsd_kern_ipc_somaxconn), 0 }, - { "kern.ipc.zero_copy.send", - &ngx_freebsd_kern_ipc_zero_copy_send, - sizeof(ngx_freebsd_kern_ipc_zero_copy_send), 0 }, - { NULL, NULL, 0, 0 } }; diff --git a/src/os/unix/ngx_os.h b/src/os/unix/ngx_os.h --- a/src/os/unix/ngx_os.h +++ b/src/os/unix/ngx_os.h @@ -13,7 +13,6 @@ #define NGX_IO_SENDFILE 1 -#define NGX_IO_ZEROCOPY 2 typedef ssize_t (*ngx_recv_pt)(ngx_connection_t *c, u_char *buf, size_t size); diff --git a/src/os/win32/ngx_os.h b/src/os/win32/ngx_os.h --- a/src/os/win32/ngx_os.h +++ b/src/os/win32/ngx_os.h @@ -13,7 +13,6 @@ #include #define NGX_IO_SENDFILE 1 -#define NGX_IO_ZEROCOPY 2 typedef ssize_t (*ngx_recv_pt)(ngx_connection_t *c, u_char *buf, size_t size);