mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-11 00:08:50 +00:00
plist: fix PLIST_NODE_INIT to work with debug enabled
It seems that PLIST_NODE_INIT breaks if used and DEBUG_PI_LIST is defined. Since there are no current users of PLIST_NODE_INIT, this has gone undetected. This patch fixes the build issue that enables the DEBUG_PI_LIST later in the series when we use it in init_task.h Signed-off-by: Gregory Haskins <ghaskins@novell.com>
This commit is contained in:
parent
967fc04671
commit
4075134e40
@ -96,6 +96,10 @@ struct plist_node {
|
|||||||
# define PLIST_HEAD_LOCK_INIT(_lock)
|
# define PLIST_HEAD_LOCK_INIT(_lock)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#define _PLIST_HEAD_INIT(head) \
|
||||||
|
.prio_list = LIST_HEAD_INIT((head).prio_list), \
|
||||||
|
.node_list = LIST_HEAD_INIT((head).node_list)
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* PLIST_HEAD_INIT - static struct plist_head initializer
|
* PLIST_HEAD_INIT - static struct plist_head initializer
|
||||||
* @head: struct plist_head variable name
|
* @head: struct plist_head variable name
|
||||||
@ -103,8 +107,7 @@ struct plist_node {
|
|||||||
*/
|
*/
|
||||||
#define PLIST_HEAD_INIT(head, _lock) \
|
#define PLIST_HEAD_INIT(head, _lock) \
|
||||||
{ \
|
{ \
|
||||||
.prio_list = LIST_HEAD_INIT((head).prio_list), \
|
_PLIST_HEAD_INIT(head), \
|
||||||
.node_list = LIST_HEAD_INIT((head).node_list), \
|
|
||||||
PLIST_HEAD_LOCK_INIT(&(_lock)) \
|
PLIST_HEAD_LOCK_INIT(&(_lock)) \
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -116,7 +119,7 @@ struct plist_node {
|
|||||||
#define PLIST_NODE_INIT(node, __prio) \
|
#define PLIST_NODE_INIT(node, __prio) \
|
||||||
{ \
|
{ \
|
||||||
.prio = (__prio), \
|
.prio = (__prio), \
|
||||||
.plist = PLIST_HEAD_INIT((node).plist, NULL), \
|
.plist = { _PLIST_HEAD_INIT((node).plist) }, \
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user