summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorRalph Boehme <slow@samba.org>2018-12-23 09:34:20 +0100
committerStefan Metzmacher <metze@samba.org>2019-01-11 23:11:13 +0100
commit29fc7c7db788b1bb200e3a4019d42c045ad0d582 (patch)
tree25488d6e9e104cdeb77472de14e12638795434cb /source3
parent8074922c267677434e6174a2e74b2b7959762014 (diff)
downloadsamba-29fc7c7db788b1bb200e3a4019d42c045ad0d582.tar.gz
smbd: rename sconn->raw_thread_pool to sconn->pool
This is basically a revert of commit 2be7518ae5a3c046f5fca04ecc83f9f7044eac74. See the discussion in https://lists.samba.org/archive/samba-technical/2018-December/131731.html for the reasoning behind this revert. Signed-off-by: Ralph Boehme <slow@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
Diffstat (limited to 'source3')
-rw-r--r--source3/modules/vfs_aio_pthread.c2
-rw-r--r--source3/modules/vfs_default.c9
-rw-r--r--source3/smbd/globals.h2
-rw-r--r--source3/smbd/process.c2
-rw-r--r--source3/smbd/smb2_query_directory.c4
5 files changed, 9 insertions, 10 deletions
diff --git a/source3/modules/vfs_aio_pthread.c b/source3/modules/vfs_aio_pthread.c
index da1ca534907..c1d1a7d518a 100644
--- a/source3/modules/vfs_aio_pthread.c
+++ b/source3/modules/vfs_aio_pthread.c
@@ -277,7 +277,7 @@ static int open_async(const files_struct *fsp,
subreq = pthreadpool_tevent_job_send(opd,
fsp->conn->user_ev_ctx,
- fsp->conn->sconn->raw_thread_pool,
+ fsp->conn->sconn->pool,
aio_open_worker, opd);
if (subreq == NULL) {
return -1;
diff --git a/source3/modules/vfs_default.c b/source3/modules/vfs_default.c
index 0a07d4069d7..1734361fca9 100644
--- a/source3/modules/vfs_default.c
+++ b/source3/modules/vfs_default.c
@@ -686,7 +686,7 @@ static struct tevent_req *vfswrap_pread_send(struct vfs_handle_struct *handle,
SMBPROFILE_BYTES_ASYNC_SET_IDLE(state->profile_bytes);
subreq = pthreadpool_tevent_job_send(
- state, ev, handle->conn->sconn->raw_thread_pool,
+ state, ev, handle->conn->sconn->pool,
vfs_pread_do, state);
if (tevent_req_nomem(subreq, req)) {
return tevent_req_post(req, ev);
@@ -804,7 +804,7 @@ static struct tevent_req *vfswrap_pwrite_send(struct vfs_handle_struct *handle,
SMBPROFILE_BYTES_ASYNC_SET_IDLE(state->profile_bytes);
subreq = pthreadpool_tevent_job_send(
- state, ev, handle->conn->sconn->raw_thread_pool,
+ state, ev, handle->conn->sconn->pool,
vfs_pwrite_do, state);
if (tevent_req_nomem(subreq, req)) {
return tevent_req_post(req, ev);
@@ -914,8 +914,7 @@ static struct tevent_req *vfswrap_fsync_send(struct vfs_handle_struct *handle,
SMBPROFILE_BYTES_ASYNC_SET_IDLE(state->profile_bytes);
subreq = pthreadpool_tevent_job_send(
- state, ev, handle->conn->sconn->raw_thread_pool,
- vfs_fsync_do, state);
+ state, ev, handle->conn->sconn->pool, vfs_fsync_do, state);
if (tevent_req_nomem(subreq, req)) {
return tevent_req_post(req, ev);
}
@@ -3037,7 +3036,7 @@ static struct tevent_req *vfswrap_getxattrat_send(
subreq = pthreadpool_tevent_job_send(
state,
ev,
- dir_fsp->conn->sconn->raw_thread_pool,
+ dir_fsp->conn->sconn->pool,
vfswrap_getxattrat_do_async,
state);
if (tevent_req_nomem(subreq, req)) {
diff --git a/source3/smbd/globals.h b/source3/smbd/globals.h
index b6dc27d47be..5695663cc66 100644
--- a/source3/smbd/globals.h
+++ b/source3/smbd/globals.h
@@ -943,7 +943,7 @@ struct smbd_server_connection {
} locks;
} smb2;
- struct pthreadpool_tevent *raw_thread_pool;
+ struct pthreadpool_tevent *pool;
struct smbXsrv_client *client;
};
diff --git a/source3/smbd/process.c b/source3/smbd/process.c
index 8e1fceab0aa..0a4106257f5 100644
--- a/source3/smbd/process.c
+++ b/source3/smbd/process.c
@@ -3950,7 +3950,7 @@ void smbd_process(struct tevent_context *ev_ctx,
sconn->msg_ctx = msg_ctx;
ret = pthreadpool_tevent_init(sconn, lp_aio_max_threads(),
- &sconn->raw_thread_pool);
+ &sconn->pool);
if (ret != 0) {
exit_server("pthreadpool_tevent_init() failed.");
}
diff --git a/source3/smbd/smb2_query_directory.c b/source3/smbd/smb2_query_directory.c
index 1a3447c3a82..ab6c3dc788e 100644
--- a/source3/smbd/smb2_query_directory.c
+++ b/source3/smbd/smb2_query_directory.c
@@ -515,7 +515,7 @@ static struct tevent_req *smbd_smb2_query_directory_send(TALLOC_CTX *mem_ctx,
if (state->async_dosmode) {
size_t max_threads;
- max_threads = pthreadpool_tevent_max_threads(conn->sconn->raw_thread_pool);
+ max_threads = pthreadpool_tevent_max_threads(conn->sconn->pool);
state->max_async_dosmode_active = lp_smbd_max_async_dosmode(
SNUM(conn));
@@ -660,7 +660,7 @@ static bool smb2_query_directory_next_entry(struct tevent_req *req)
state->async_dosmode_active++;
outstanding_aio = pthreadpool_tevent_queued_jobs(
- state->fsp->conn->sconn->raw_thread_pool);
+ state->fsp->conn->sconn->pool);
if (outstanding_aio > state->max_async_dosmode_active) {
stop = true;