summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorMark Fasheh <mfasheh@suse.com>2008-06-16 16:28:00 -0700
committerMark Fasheh <mfasheh@suse.com>2008-06-16 16:28:00 -0700
commit5d861bc19381ad7168c25940c32a55efe64b3685 (patch)
tree8d53d61974b306e0abd1c46d3ae91c20d68ccaa4 /drivers
parent3028d93193026a07dc869d9f6a909c5afe49ddcf (diff)
parentba0b6f47636117a48ba953ece3d28e2cf5a673df (diff)
Merge branch 'configfs_next' into linux-next
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/netconsole.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/net/netconsole.c b/drivers/net/netconsole.c
index 665341e43055..387a13395015 100644
--- a/drivers/net/netconsole.c
+++ b/drivers/net/netconsole.c
@@ -585,8 +585,9 @@ static struct config_item_type netconsole_target_type = {
* Group operations and type for netconsole_subsys.
*/
-static struct config_item *make_netconsole_target(struct config_group *group,
- const char *name)
+static int make_netconsole_target(struct config_group *group,
+ const char *name,
+ struct config_item **new_item)
{
unsigned long flags;
struct netconsole_target *nt;
@@ -598,7 +599,7 @@ static struct config_item *make_netconsole_target(struct config_group *group,
nt = kzalloc(sizeof(*nt), GFP_KERNEL);
if (!nt) {
printk(KERN_ERR "netconsole: failed to allocate memory\n");
- return NULL;
+ return -ENOMEM;
}
nt->np.name = "netconsole";
@@ -615,7 +616,8 @@ static struct config_item *make_netconsole_target(struct config_group *group,
list_add(&nt->list, &target_list);
spin_unlock_irqrestore(&target_list_lock, flags);
- return &nt->item;
+ *new_item = &nt->item;
+ return 0;
}
static void drop_netconsole_target(struct config_group *group,