]> xenbits.xensource.com Git - people/dwmw2/xen.git/commitdiff
Arm/GICv2: don't needlessly use xzalloc_bytes()
authorJan Beulich <jbeulich@suse.com>
Thu, 6 Feb 2020 08:53:43 +0000 (09:53 +0100)
committerJan Beulich <jbeulich@suse.com>
Thu, 6 Feb 2020 08:53:43 +0000 (09:53 +0100)
... when plain xzalloc() (which is more type safe) does.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Julien Grall <julien@xen.org>
xen/arch/arm/gic-v2.c

index 256988c665b76fe74ff682c7de45e28ccd5a1066..0f747538dbcddfeb4ba4436a1e2e91da53d1239d 100644 (file)
@@ -969,7 +969,7 @@ static void gicv2_add_v2m_frame_to_list(paddr_t addr, paddr_t size,
               nr_spis, V2M_MAX_SPI - V2M_MIN_SPI + 1);
 
     /* Allocate an entry to record new v2m frame information. */
-    v2m_data = xzalloc_bytes(sizeof(struct v2m_data));
+    v2m_data = xzalloc(struct v2m_data);
     if ( !v2m_data )
         panic("GICv2: Cannot allocate memory for v2m frame\n");