From f2083241f23722207676025abbb45a301d412e69 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Engel?= Date: Thu, 15 Mar 2012 15:05:40 -0400 Subject: target: Use array_zalloc for device_list Turns an order-8 allocation into slab-sized ones, thereby preventing allocation failures with memory fragmentation. This likely saves memory as well, as the slab allocator can pack objects more tightly than the buddy allocator. (nab: Fix lio-core patch fuzz) Signed-off-by: Joern Engel Signed-off-by: Nicholas Bellinger --- include/target/target_core_base.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/target') diff --git a/include/target/target_core_base.h b/include/target/target_core_base.h index fc918a7b7d70..aaccc5f5fc9f 100644 --- a/include/target/target_core_base.h +++ b/include/target/target_core_base.h @@ -629,7 +629,7 @@ struct se_node_acl { spinlock_t stats_lock; /* Used for PR SPEC_I_PT=1 and REGISTER_AND_MOVE */ atomic_t acl_pr_ref_count; - struct se_dev_entry *device_list; + struct se_dev_entry **device_list; struct se_session *nacl_sess; struct se_portal_group *se_tpg; spinlock_t device_list_lock; -- cgit v1.2.3