diff options
Diffstat (limited to 'drivers/ieee1394/nodemgr.c')
-rw-r--r-- | drivers/ieee1394/nodemgr.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/ieee1394/nodemgr.c b/drivers/ieee1394/nodemgr.c index 640d677ae03e..801f60619236 100644 --- a/drivers/ieee1394/nodemgr.c +++ b/drivers/ieee1394/nodemgr.c | |||
@@ -1078,10 +1078,9 @@ static struct unit_directory *nodemgr_process_unit_directory | |||
1078 | /* Logical Unit Number */ | 1078 | /* Logical Unit Number */ |
1079 | if (kv->key.type == CSR1212_KV_TYPE_IMMEDIATE) { | 1079 | if (kv->key.type == CSR1212_KV_TYPE_IMMEDIATE) { |
1080 | if (ud->flags & UNIT_DIRECTORY_HAS_LUN) { | 1080 | if (ud->flags & UNIT_DIRECTORY_HAS_LUN) { |
1081 | ud_child = kmalloc(sizeof(*ud_child), GFP_KERNEL); | 1081 | ud_child = kmemdup(ud, sizeof(*ud_child), GFP_KERNEL); |
1082 | if (!ud_child) | 1082 | if (!ud_child) |
1083 | goto unit_directory_error; | 1083 | goto unit_directory_error; |
1084 | memcpy(ud_child, ud, sizeof(*ud_child)); | ||
1085 | nodemgr_register_device(ne, ud_child, &ne->device); | 1084 | nodemgr_register_device(ne, ud_child, &ne->device); |
1086 | ud_child = NULL; | 1085 | ud_child = NULL; |
1087 | 1086 | ||