diff options
author | David Garcia Quintas <dgq@google.com> | 2016-08-29 11:57:40 -0700 |
---|---|---|
committer | David Garcia Quintas <dgq@google.com> | 2016-08-29 11:57:40 -0700 |
commit | 51f066c585cc0516c0e34b0f40849282930de16b (patch) | |
tree | 009cf5dd8670d35dc2d87f37aa8c052b3a7c11f0 /src/core | |
parent | 211f89f888116d36a1c9f9c382f7dbe225136ce7 (diff) | |
parent | 7acd1a790ac035bfb06dc44185bac84b2bb5e4c7 (diff) |
Merge branch 'master' of github.com:grpc/grpc into lb_add_md
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/lib/iomgr/ev_epoll_linux.c | 2 | ||||
-rw-r--r-- | src/core/lib/iomgr/tcp_server_posix.c | 4 |
2 files changed, 5 insertions, 1 deletions
diff --git a/src/core/lib/iomgr/ev_epoll_linux.c b/src/core/lib/iomgr/ev_epoll_linux.c index 02bcbaa10f..27264694d1 100644 --- a/src/core/lib/iomgr/ev_epoll_linux.c +++ b/src/core/lib/iomgr/ev_epoll_linux.c @@ -1353,8 +1353,10 @@ static void pollset_work_and_unlock(grpc_exec_ctx *exec_ctx, gpr_mu_unlock(&pollset->mu); do { + GRPC_SCHEDULING_START_BLOCKING_REGION; ep_rv = epoll_pwait(epoll_fd, ep_ev, GRPC_EPOLL_MAX_EVENTS, timeout_ms, sig_mask); + GRPC_SCHEDULING_END_BLOCKING_REGION; if (ep_rv < 0) { if (errno != EINTR) { gpr_asprintf(&err_msg, diff --git a/src/core/lib/iomgr/tcp_server_posix.c b/src/core/lib/iomgr/tcp_server_posix.c index ea8d241154..2d3f6cf9a7 100644 --- a/src/core/lib/iomgr/tcp_server_posix.c +++ b/src/core/lib/iomgr/tcp_server_posix.c @@ -140,15 +140,17 @@ struct grpc_tcp_server { }; static gpr_once check_init = GPR_ONCE_INIT; -static bool has_so_reuseport; +static bool has_so_reuseport = false; static void init(void) { +#ifndef GPR_MANYLINUX1 int s = socket(AF_INET, SOCK_STREAM, 0); if (s >= 0) { has_so_reuseport = GRPC_LOG_IF_ERROR("check for SO_REUSEPORT", grpc_set_socket_reuse_port(s, 1)); close(s); } +#endif } grpc_error *grpc_tcp_server_create(grpc_closure *shutdown_complete, |