annotate src/os/unix/ngx_setaffinity.h @ 4728:fc62b72f7597 stable-1.2

Merge of r4690: conflicting wildcard server names fix. With previous code wildcard names were added to hash even if conflict was detected. This resulted in identical names in hash and segfault later in ngx_hash_wildcard_init().
author Maxim Dounin <mdounin@mdounin.ru>
date Mon, 02 Jul 2012 16:59:34 +0000
parents f31162fefe01
children 7296b38f6416
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4549
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
1
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
2 /*
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
3 * Copyright (C) Nginx, Inc.
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
4 */
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
5
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
6 #ifndef _NGX_SETAFFINITY_H_INCLUDED_
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
7 #define _NGX_SETAFFINITY_H_INCLUDED_
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
8
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
9
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
10 #if (NGX_HAVE_SCHED_SETAFFINITY || NGX_HAVE_CPUSET_SETAFFINITY)
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
11
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
12 #define NGX_HAVE_CPU_AFFINITY 1
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
13
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
14 void ngx_setaffinity(uint64_t cpu_affinity, ngx_log_t *log);
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
15
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
16 #else
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
17
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
18 #define ngx_setaffinity(cpu_affinity, log)
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
19
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
20 #endif
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
21
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
22
f31162fefe01 worker_cpu_affinity: cleaned up Linux implementation, added FreeBSD support.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
23 #endif /* _NGX_SETAFFINITY_H_INCLUDED_ */