diff options
| -rw-r--r-- | include/linux/cpumask.h | 15 | ||||
| -rw-r--r-- | include/linux/init.h | 3 | ||||
| -rw-r--r-- | init/main.c | 1 |
3 files changed, 16 insertions, 3 deletions
diff --git a/include/linux/cpumask.h b/include/linux/cpumask.h index a2c819d3c96e..032560295fcb 100644 --- a/include/linux/cpumask.h +++ b/include/linux/cpumask.h | |||
| @@ -272,6 +272,8 @@ static inline void cpumask_clear_cpu(int cpu, struct cpumask *dstp) | |||
| 272 | * @cpu: cpu number (< nr_cpu_ids) | 272 | * @cpu: cpu number (< nr_cpu_ids) |
| 273 | * @cpumask: the cpumask pointer | 273 | * @cpumask: the cpumask pointer |
| 274 | * | 274 | * |
| 275 | * Returns 1 if @cpu is set in @cpumask, else returns 0 | ||
| 276 | * | ||
| 275 | * No static inline type checking - see Subtlety (1) above. | 277 | * No static inline type checking - see Subtlety (1) above. |
| 276 | */ | 278 | */ |
| 277 | #define cpumask_test_cpu(cpu, cpumask) \ | 279 | #define cpumask_test_cpu(cpu, cpumask) \ |
| @@ -282,6 +284,8 @@ static inline void cpumask_clear_cpu(int cpu, struct cpumask *dstp) | |||
| 282 | * @cpu: cpu number (< nr_cpu_ids) | 284 | * @cpu: cpu number (< nr_cpu_ids) |
| 283 | * @cpumask: the cpumask pointer | 285 | * @cpumask: the cpumask pointer |
| 284 | * | 286 | * |
| 287 | * Returns 1 if @cpu is set in old bitmap of @cpumask, else returns 0 | ||
| 288 | * | ||
| 285 | * test_and_set_bit wrapper for cpumasks. | 289 | * test_and_set_bit wrapper for cpumasks. |
| 286 | */ | 290 | */ |
| 287 | static inline int cpumask_test_and_set_cpu(int cpu, struct cpumask *cpumask) | 291 | static inline int cpumask_test_and_set_cpu(int cpu, struct cpumask *cpumask) |
| @@ -294,6 +298,8 @@ static inline int cpumask_test_and_set_cpu(int cpu, struct cpumask *cpumask) | |||
| 294 | * @cpu: cpu number (< nr_cpu_ids) | 298 | * @cpu: cpu number (< nr_cpu_ids) |
| 295 | * @cpumask: the cpumask pointer | 299 | * @cpumask: the cpumask pointer |
| 296 | * | 300 | * |
| 301 | * Returns 1 if @cpu is set in old bitmap of @cpumask, else returns 0 | ||
| 302 | * | ||
| 297 | * test_and_clear_bit wrapper for cpumasks. | 303 | * test_and_clear_bit wrapper for cpumasks. |
| 298 | */ | 304 | */ |
| 299 | static inline int cpumask_test_and_clear_cpu(int cpu, struct cpumask *cpumask) | 305 | static inline int cpumask_test_and_clear_cpu(int cpu, struct cpumask *cpumask) |
| @@ -324,6 +330,8 @@ static inline void cpumask_clear(struct cpumask *dstp) | |||
| 324 | * @dstp: the cpumask result | 330 | * @dstp: the cpumask result |
| 325 | * @src1p: the first input | 331 | * @src1p: the first input |
| 326 | * @src2p: the second input | 332 | * @src2p: the second input |
| 333 | * | ||
| 334 | * If *@dstp is empty, returns 0, else returns 1 | ||
| 327 | */ | 335 | */ |
| 328 | static inline int cpumask_and(struct cpumask *dstp, | 336 | static inline int cpumask_and(struct cpumask *dstp, |
| 329 | const struct cpumask *src1p, | 337 | const struct cpumask *src1p, |
| @@ -365,6 +373,8 @@ static inline void cpumask_xor(struct cpumask *dstp, | |||
| 365 | * @dstp: the cpumask result | 373 | * @dstp: the cpumask result |
| 366 | * @src1p: the first input | 374 | * @src1p: the first input |
| 367 | * @src2p: the second input | 375 | * @src2p: the second input |
| 376 | * | ||
| 377 | * If *@dstp is empty, returns 0, else returns 1 | ||
| 368 | */ | 378 | */ |
| 369 | static inline int cpumask_andnot(struct cpumask *dstp, | 379 | static inline int cpumask_andnot(struct cpumask *dstp, |
| 370 | const struct cpumask *src1p, | 380 | const struct cpumask *src1p, |
| @@ -414,6 +424,8 @@ static inline bool cpumask_intersects(const struct cpumask *src1p, | |||
| 414 | * cpumask_subset - (*src1p & ~*src2p) == 0 | 424 | * cpumask_subset - (*src1p & ~*src2p) == 0 |
| 415 | * @src1p: the first input | 425 | * @src1p: the first input |
| 416 | * @src2p: the second input | 426 | * @src2p: the second input |
| 427 | * | ||
| 428 | * Returns 1 if *@src1p is a subset of *@src2p, else returns 0 | ||
| 417 | */ | 429 | */ |
| 418 | static inline int cpumask_subset(const struct cpumask *src1p, | 430 | static inline int cpumask_subset(const struct cpumask *src1p, |
| 419 | const struct cpumask *src2p) | 431 | const struct cpumask *src2p) |
| @@ -579,9 +591,8 @@ static inline int cpulist_scnprintf(char *buf, int len, | |||
| 579 | } | 591 | } |
| 580 | 592 | ||
| 581 | /** | 593 | /** |
| 582 | * cpulist_parse_user - extract a cpumask from a user string of ranges | 594 | * cpulist_parse - extract a cpumask from a user string of ranges |
| 583 | * @buf: the buffer to extract from | 595 | * @buf: the buffer to extract from |
| 584 | * @len: the length of the buffer | ||
| 585 | * @dstp: the cpumask to set. | 596 | * @dstp: the cpumask to set. |
| 586 | * | 597 | * |
| 587 | * Returns -errno, or 0 for success. | 598 | * Returns -errno, or 0 for success. |
diff --git a/include/linux/init.h b/include/linux/init.h index 6b951095a42f..5e664f671615 100644 --- a/include/linux/init.h +++ b/include/linux/init.h | |||
| @@ -191,6 +191,7 @@ extern bool initcall_debug; | |||
| 191 | * initializes variables that couldn't be statically initialized. | 191 | * initializes variables that couldn't be statically initialized. |
| 192 | * | 192 | * |
| 193 | * This only exists for built-in code, not for modules. | 193 | * This only exists for built-in code, not for modules. |
| 194 | * Keep main.c:initcall_level_names[] in sync. | ||
| 194 | */ | 195 | */ |
| 195 | #define pure_initcall(fn) __define_initcall("0",fn,0) | 196 | #define pure_initcall(fn) __define_initcall("0",fn,0) |
| 196 | 197 | ||
| @@ -280,7 +281,7 @@ void __init parse_early_options(char *cmdline); | |||
| 280 | 281 | ||
| 281 | #else /* MODULE */ | 282 | #else /* MODULE */ |
| 282 | 283 | ||
| 283 | /* Don't use these in modules, but some people do... */ | 284 | /* Don't use these in loadable modules, but some people do... */ |
| 284 | #define early_initcall(fn) module_init(fn) | 285 | #define early_initcall(fn) module_init(fn) |
| 285 | #define core_initcall(fn) module_init(fn) | 286 | #define core_initcall(fn) module_init(fn) |
| 286 | #define postcore_initcall(fn) module_init(fn) | 287 | #define postcore_initcall(fn) module_init(fn) |
diff --git a/init/main.c b/init/main.c index eb72a5c4c844..95316a1b4a76 100644 --- a/init/main.c +++ b/init/main.c | |||
| @@ -725,6 +725,7 @@ static initcall_t *initcall_levels[] __initdata = { | |||
| 725 | __initcall_end, | 725 | __initcall_end, |
| 726 | }; | 726 | }; |
| 727 | 727 | ||
| 728 | /* Keep these in sync with initcalls in include/linux/init.h */ | ||
| 728 | static char *initcall_level_names[] __initdata = { | 729 | static char *initcall_level_names[] __initdata = { |
| 729 | "early", | 730 | "early", |
| 730 | "core", | 731 | "core", |
