diff options
author | Ingo Molnar <mingo@elte.hu> | 2010-07-01 02:49:28 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2010-07-01 03:31:25 -0400 |
commit | 0a54cec0c25cc49e3b68b14c205f1f6cff13f5e1 (patch) | |
tree | eb4e63ee9ae1fcaf9aa53a1668e55c09516052d9 /include/linux | |
parent | ec8c27e04f89a7575ca2c4facb99152e03d6a99c (diff) | |
parent | 980019d74e4b2428362b36a0506519d6d9460800 (diff) |
Merge branch 'linus' into core/rcu
Conflicts:
fs/fs-writeback.c
Merge reason: Resolve the conflict
Note, i picked the version from Linus's tree, which effectively reverts
the fs-writeback.c bits of:
b97181f: fs: remove all rcu head initializations, except on_stack initializations
As the upstream changes to this file changed this code heavily and the
first attempt to resolve the conflict resulted in a non-booting kernel.
It's safer to re-try this portion of the commit cleanly.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/backing-dev.h | 4 | ||||
-rw-r--r-- | include/linux/cgroup.h | 20 | ||||
-rw-r--r-- | include/linux/compiler-gcc.h | 10 | ||||
-rw-r--r-- | include/linux/compiler-gcc4.h | 4 | ||||
-rw-r--r-- | include/linux/drbd.h | 2 | ||||
-rw-r--r-- | include/linux/list.h | 15 | ||||
-rw-r--r-- | include/linux/suspend.h | 26 | ||||
-rw-r--r-- | include/linux/tracepoint.h | 1 |
8 files changed, 59 insertions, 23 deletions
diff --git a/include/linux/backing-dev.h b/include/linux/backing-dev.h index aee5f6ce166e..9ae2889096b6 100644 --- a/include/linux/backing-dev.h +++ b/include/linux/backing-dev.h | |||
@@ -105,8 +105,8 @@ int bdi_register(struct backing_dev_info *bdi, struct device *parent, | |||
105 | int bdi_register_dev(struct backing_dev_info *bdi, dev_t dev); | 105 | int bdi_register_dev(struct backing_dev_info *bdi, dev_t dev); |
106 | void bdi_unregister(struct backing_dev_info *bdi); | 106 | void bdi_unregister(struct backing_dev_info *bdi); |
107 | int bdi_setup_and_register(struct backing_dev_info *, char *, unsigned int); | 107 | int bdi_setup_and_register(struct backing_dev_info *, char *, unsigned int); |
108 | void bdi_start_writeback(struct backing_dev_info *bdi, struct super_block *sb, | 108 | void bdi_start_writeback(struct backing_dev_info *bdi, long nr_pages); |
109 | long nr_pages); | 109 | void bdi_start_background_writeback(struct backing_dev_info *bdi); |
110 | int bdi_writeback_task(struct bdi_writeback *wb); | 110 | int bdi_writeback_task(struct bdi_writeback *wb); |
111 | int bdi_has_dirty_io(struct backing_dev_info *bdi); | 111 | int bdi_has_dirty_io(struct backing_dev_info *bdi); |
112 | void bdi_arm_supers_timer(void); | 112 | void bdi_arm_supers_timer(void); |
diff --git a/include/linux/cgroup.h b/include/linux/cgroup.h index 0c621604baa1..e3d00fdb858d 100644 --- a/include/linux/cgroup.h +++ b/include/linux/cgroup.h | |||
@@ -525,13 +525,21 @@ static inline struct cgroup_subsys_state *cgroup_subsys_state( | |||
525 | return cgrp->subsys[subsys_id]; | 525 | return cgrp->subsys[subsys_id]; |
526 | } | 526 | } |
527 | 527 | ||
528 | static inline struct cgroup_subsys_state *task_subsys_state( | 528 | /* |
529 | struct task_struct *task, int subsys_id) | 529 | * function to get the cgroup_subsys_state which allows for extra |
530 | * rcu_dereference_check() conditions, such as locks used during the | ||
531 | * cgroup_subsys::attach() methods. | ||
532 | */ | ||
533 | #define task_subsys_state_check(task, subsys_id, __c) \ | ||
534 | rcu_dereference_check(task->cgroups->subsys[subsys_id], \ | ||
535 | rcu_read_lock_held() || \ | ||
536 | lockdep_is_held(&task->alloc_lock) || \ | ||
537 | cgroup_lock_is_held() || (__c)) | ||
538 | |||
539 | static inline struct cgroup_subsys_state * | ||
540 | task_subsys_state(struct task_struct *task, int subsys_id) | ||
530 | { | 541 | { |
531 | return rcu_dereference_check(task->cgroups->subsys[subsys_id], | 542 | return task_subsys_state_check(task, subsys_id, false); |
532 | rcu_read_lock_held() || | ||
533 | lockdep_is_held(&task->alloc_lock) || | ||
534 | cgroup_lock_is_held()); | ||
535 | } | 543 | } |
536 | 544 | ||
537 | static inline struct cgroup* task_cgroup(struct task_struct *task, | 545 | static inline struct cgroup* task_cgroup(struct task_struct *task, |
diff --git a/include/linux/compiler-gcc.h b/include/linux/compiler-gcc.h index 73dcf804bc94..0da5b187f124 100644 --- a/include/linux/compiler-gcc.h +++ b/include/linux/compiler-gcc.h | |||
@@ -58,8 +58,12 @@ | |||
58 | * naked functions because then mcount is called without stack and frame pointer | 58 | * naked functions because then mcount is called without stack and frame pointer |
59 | * being set up and there is no chance to restore the lr register to the value | 59 | * being set up and there is no chance to restore the lr register to the value |
60 | * before mcount was called. | 60 | * before mcount was called. |
61 | * | ||
62 | * The asm() bodies of naked functions often depend on standard calling conventions, | ||
63 | * therefore they must be noinline and noclone. GCC 4.[56] currently fail to enforce | ||
64 | * this, so we must do so ourselves. See GCC PR44290. | ||
61 | */ | 65 | */ |
62 | #define __naked __attribute__((naked)) notrace | 66 | #define __naked __attribute__((naked)) noinline __noclone notrace |
63 | 67 | ||
64 | #define __noreturn __attribute__((noreturn)) | 68 | #define __noreturn __attribute__((noreturn)) |
65 | 69 | ||
@@ -85,3 +89,7 @@ | |||
85 | #define _gcc_header(x) __gcc_header(linux/compiler-gcc##x.h) | 89 | #define _gcc_header(x) __gcc_header(linux/compiler-gcc##x.h) |
86 | #define gcc_header(x) _gcc_header(x) | 90 | #define gcc_header(x) _gcc_header(x) |
87 | #include gcc_header(__GNUC__) | 91 | #include gcc_header(__GNUC__) |
92 | |||
93 | #if !defined(__noclone) | ||
94 | #define __noclone /* not needed */ | ||
95 | #endif | ||
diff --git a/include/linux/compiler-gcc4.h b/include/linux/compiler-gcc4.h index 94dea3ffbfa1..fcfa5b9a4317 100644 --- a/include/linux/compiler-gcc4.h +++ b/include/linux/compiler-gcc4.h | |||
@@ -48,6 +48,10 @@ | |||
48 | * unreleased. Really, we need to have autoconf for the kernel. | 48 | * unreleased. Really, we need to have autoconf for the kernel. |
49 | */ | 49 | */ |
50 | #define unreachable() __builtin_unreachable() | 50 | #define unreachable() __builtin_unreachable() |
51 | |||
52 | /* Mark a function definition as prohibited from being cloned. */ | ||
53 | #define __noclone __attribute__((__noclone__)) | ||
54 | |||
51 | #endif | 55 | #endif |
52 | 56 | ||
53 | #endif | 57 | #endif |
diff --git a/include/linux/drbd.h b/include/linux/drbd.h index 30da4ae48972..b8d2516668aa 100644 --- a/include/linux/drbd.h +++ b/include/linux/drbd.h | |||
@@ -53,7 +53,7 @@ | |||
53 | 53 | ||
54 | 54 | ||
55 | extern const char *drbd_buildtag(void); | 55 | extern const char *drbd_buildtag(void); |
56 | #define REL_VERSION "8.3.8rc2" | 56 | #define REL_VERSION "8.3.8" |
57 | #define API_VERSION 88 | 57 | #define API_VERSION 88 |
58 | #define PRO_VERSION_MIN 86 | 58 | #define PRO_VERSION_MIN 86 |
59 | #define PRO_VERSION_MAX 94 | 59 | #define PRO_VERSION_MAX 94 |
diff --git a/include/linux/list.h b/include/linux/list.h index 8392884a2977..5d57a3a1fa1b 100644 --- a/include/linux/list.h +++ b/include/linux/list.h | |||
@@ -544,6 +544,21 @@ static inline void list_splice_tail_init(struct list_head *list, | |||
544 | &pos->member != (head); \ | 544 | &pos->member != (head); \ |
545 | pos = n, n = list_entry(n->member.prev, typeof(*n), member)) | 545 | pos = n, n = list_entry(n->member.prev, typeof(*n), member)) |
546 | 546 | ||
547 | /** | ||
548 | * list_safe_reset_next - reset a stale list_for_each_entry_safe loop | ||
549 | * @pos: the loop cursor used in the list_for_each_entry_safe loop | ||
550 | * @n: temporary storage used in list_for_each_entry_safe | ||
551 | * @member: the name of the list_struct within the struct. | ||
552 | * | ||
553 | * list_safe_reset_next is not safe to use in general if the list may be | ||
554 | * modified concurrently (eg. the lock is dropped in the loop body). An | ||
555 | * exception to this is if the cursor element (pos) is pinned in the list, | ||
556 | * and list_safe_reset_next is called after re-taking the lock and before | ||
557 | * completing the current iteration of the loop body. | ||
558 | */ | ||
559 | #define list_safe_reset_next(pos, n, member) \ | ||
560 | n = list_entry(pos->member.next, typeof(*pos), member) | ||
561 | |||
547 | /* | 562 | /* |
548 | * Double linked lists with a single pointer list head. | 563 | * Double linked lists with a single pointer list head. |
549 | * Mostly useful for hash tables where the two pointer list head is | 564 | * Mostly useful for hash tables where the two pointer list head is |
diff --git a/include/linux/suspend.h b/include/linux/suspend.h index 5e781d824e6d..bc7d6bb4cd8e 100644 --- a/include/linux/suspend.h +++ b/include/linux/suspend.h | |||
@@ -256,22 +256,22 @@ static inline int hibernate(void) { return -ENOSYS; } | |||
256 | static inline bool system_entering_hibernation(void) { return false; } | 256 | static inline bool system_entering_hibernation(void) { return false; } |
257 | #endif /* CONFIG_HIBERNATION */ | 257 | #endif /* CONFIG_HIBERNATION */ |
258 | 258 | ||
259 | #ifdef CONFIG_HIBERNATION_NVS | 259 | #ifdef CONFIG_SUSPEND_NVS |
260 | extern int hibernate_nvs_register(unsigned long start, unsigned long size); | 260 | extern int suspend_nvs_register(unsigned long start, unsigned long size); |
261 | extern int hibernate_nvs_alloc(void); | 261 | extern int suspend_nvs_alloc(void); |
262 | extern void hibernate_nvs_free(void); | 262 | extern void suspend_nvs_free(void); |
263 | extern void hibernate_nvs_save(void); | 263 | extern void suspend_nvs_save(void); |
264 | extern void hibernate_nvs_restore(void); | 264 | extern void suspend_nvs_restore(void); |
265 | #else /* CONFIG_HIBERNATION_NVS */ | 265 | #else /* CONFIG_SUSPEND_NVS */ |
266 | static inline int hibernate_nvs_register(unsigned long a, unsigned long b) | 266 | static inline int suspend_nvs_register(unsigned long a, unsigned long b) |
267 | { | 267 | { |
268 | return 0; | 268 | return 0; |
269 | } | 269 | } |
270 | static inline int hibernate_nvs_alloc(void) { return 0; } | 270 | static inline int suspend_nvs_alloc(void) { return 0; } |
271 | static inline void hibernate_nvs_free(void) {} | 271 | static inline void suspend_nvs_free(void) {} |
272 | static inline void hibernate_nvs_save(void) {} | 272 | static inline void suspend_nvs_save(void) {} |
273 | static inline void hibernate_nvs_restore(void) {} | 273 | static inline void suspend_nvs_restore(void) {} |
274 | #endif /* CONFIG_HIBERNATION_NVS */ | 274 | #endif /* CONFIG_SUSPEND_NVS */ |
275 | 275 | ||
276 | #ifdef CONFIG_PM_SLEEP | 276 | #ifdef CONFIG_PM_SLEEP |
277 | void save_processor_state(void); | 277 | void save_processor_state(void); |
diff --git a/include/linux/tracepoint.h b/include/linux/tracepoint.h index 9a59d1f98cd4..103d1b61aacb 100644 --- a/include/linux/tracepoint.h +++ b/include/linux/tracepoint.h | |||
@@ -14,6 +14,7 @@ | |||
14 | * See the file COPYING for more details. | 14 | * See the file COPYING for more details. |
15 | */ | 15 | */ |
16 | 16 | ||
17 | #include <linux/errno.h> | ||
17 | #include <linux/types.h> | 18 | #include <linux/types.h> |
18 | #include <linux/rcupdate.h> | 19 | #include <linux/rcupdate.h> |
19 | 20 | ||