diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/list.h | 7 | ||||
| -rw-r--r-- | include/linux/rcupdate.h | 1 | ||||
| -rw-r--r-- | include/linux/torture.h | 2 |
3 files changed, 7 insertions, 3 deletions
diff --git a/include/linux/list.h b/include/linux/list.h index 5183138aa932..5809e9a2de5b 100644 --- a/include/linux/list.h +++ b/include/linux/list.h | |||
| @@ -381,8 +381,11 @@ static inline void list_splice_tail_init(struct list_head *list, | |||
| 381 | * | 381 | * |
| 382 | * Note that if the list is empty, it returns NULL. | 382 | * Note that if the list is empty, it returns NULL. |
| 383 | */ | 383 | */ |
| 384 | #define list_first_entry_or_null(ptr, type, member) \ | 384 | #define list_first_entry_or_null(ptr, type, member) ({ \ |
| 385 | (!list_empty(ptr) ? list_first_entry(ptr, type, member) : NULL) | 385 | struct list_head *head__ = (ptr); \ |
| 386 | struct list_head *pos__ = READ_ONCE(head__->next); \ | ||
| 387 | pos__ != head__ ? list_entry(pos__, type, member) : NULL; \ | ||
| 388 | }) | ||
| 386 | 389 | ||
| 387 | /** | 390 | /** |
| 388 | * list_next_entry - get the next element in list | 391 | * list_next_entry - get the next element in list |
diff --git a/include/linux/rcupdate.h b/include/linux/rcupdate.h index 1aa62e1a761b..321f9ed552a9 100644 --- a/include/linux/rcupdate.h +++ b/include/linux/rcupdate.h | |||
| @@ -334,6 +334,7 @@ void rcu_sched_qs(void); | |||
| 334 | void rcu_bh_qs(void); | 334 | void rcu_bh_qs(void); |
| 335 | void rcu_check_callbacks(int user); | 335 | void rcu_check_callbacks(int user); |
| 336 | void rcu_report_dead(unsigned int cpu); | 336 | void rcu_report_dead(unsigned int cpu); |
| 337 | void rcu_cpu_starting(unsigned int cpu); | ||
| 337 | 338 | ||
| 338 | #ifndef CONFIG_TINY_RCU | 339 | #ifndef CONFIG_TINY_RCU |
| 339 | void rcu_end_inkernel_boot(void); | 340 | void rcu_end_inkernel_boot(void); |
diff --git a/include/linux/torture.h b/include/linux/torture.h index 6685a73736a2..a45702eb3e7b 100644 --- a/include/linux/torture.h +++ b/include/linux/torture.h | |||
| @@ -43,7 +43,7 @@ | |||
| 43 | 43 | ||
| 44 | #define TORTURE_FLAG "-torture:" | 44 | #define TORTURE_FLAG "-torture:" |
| 45 | #define TOROUT_STRING(s) \ | 45 | #define TOROUT_STRING(s) \ |
| 46 | pr_alert("%s" TORTURE_FLAG s "\n", torture_type) | 46 | pr_alert("%s" TORTURE_FLAG " %s\n", torture_type, s) |
| 47 | #define VERBOSE_TOROUT_STRING(s) \ | 47 | #define VERBOSE_TOROUT_STRING(s) \ |
| 48 | do { if (verbose) pr_alert("%s" TORTURE_FLAG " %s\n", torture_type, s); } while (0) | 48 | do { if (verbose) pr_alert("%s" TORTURE_FLAG " %s\n", torture_type, s); } while (0) |
| 49 | #define VERBOSE_TOROUT_ERRSTRING(s) \ | 49 | #define VERBOSE_TOROUT_ERRSTRING(s) \ |
