[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [PATCH 8/9] xen/arm: Allow the user to build Xen with USBAN


  • To: Julien Grall <julien@xxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Henry Wang <Henry.Wang@xxxxxxx>
  • Date: Mon, 26 Jun 2023 07:29:48 +0000
  • Accept-language: zh-CN, en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=lfAVLzyyapTdK3kvigyp1nQMe2J5k58O3GqP1opX5nk=; b=ObBk+zhQXhrjRyyupPaZEfAq9vPN5K4xSoHpZztEXn8BsLpyGUMPScbmt9dpwY9Gdd/23dlCYvr5XzqOIA2X/6oCKaDhm1rzlmCbvp26GKKNtXKb17Ifue4pbTUVxUP/3ZxbnHjXu/wawSrKJwwIyTlCATItq+zFjpZcQ85eBfU4WvnXRI08EOxdvshLIoH7IiJ36WOKH6bzxGXWlf2WuO1xS/8o89TtpEqCE3V8LjBwAIVWBLsuKZE8SIzeQYpuXXvVFkfo2sfQMtijnOSD+LhRN48JPozs0qS53Bbu5rds9GbYdqz2aIt3mfcs1tw8M/XaAsJGfjPr4tzVHj+tTg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=I3RwAucSVnx6I7lAUbIrcReGpuYx3Uw42i44wtC9ZS08YtJQUh6c4sKGLFez4KUMk+UHg6hhm70w0ID/7wNH4hjPM2gLfkxOJt35fDJ0OFWW44WwdIkmgJ50aYdFqwDvy2XvNJuCZQ6t4mYatTGVe4ieK1AUUwobIwtlkmnnR4pbTqHHJqMXgwvJTSmoqphIIcObi93PAtCGPeW5zGj9ld7L4Vbdon3bxJrPwciBAe1SnVJBopi18tFL2UML1F3hh/wvir4B+nnrHG1nC9vcGuwTqpLibo7fBbleneX4DCD2z4DvDPNwxjRaSaKXvMFhqJ6uRY3VT5MHCHQVXDGAMg==
  • Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Cc: Luca Fancellu <Luca.Fancellu@xxxxxxx>, "michal.orzel@xxxxxxx" <michal.orzel@xxxxxxx>, Julien Grall <jgrall@xxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Bertrand Marquis <Bertrand.Marquis@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
  • Delivery-date: Mon, 26 Jun 2023 07:30:29 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: true
  • Original-authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Thread-index: AQHZp6aSsRUjsp5X0kuhcvqBjbjyw6+crs2w
  • Thread-topic: [PATCH 8/9] xen/arm: Allow the user to build Xen with USBAN

Hi Julien,

> -----Original Message-----
> From: Julien Grall <julien@xxxxxxx>
> Subject: [PATCH 8/9] xen/arm: Allow the user to build Xen with USBAN

Typo in title: s/USBAN/UBSAN/ and...

> 
> From: Julien Grall <jgrall@xxxxxxxxxx>
> 
> UBSAN has been enabled a few years ago on x86 but was never
> enabled on Arm because the final binary is bigger than 2MB (
> the maximum we can currently handled).
> 
> With the recent rework, it is now possible to grow Xen over 2MB.
> So there is no more roadblock to enable Xen other than increasing
> the reserved area.
> 
> On my setup, for arm32, the final binaray was very close to 4MB.
> Furthermore, one may want to enable USBAN and GCOV which would put

...here also.

> the binary well-over 4MB (both features require for some space).
> Therefore, increase the size to 8MB which should us some margin.
> 
> Signed-off-by: Julien Grall <jgrall@xxxxxxxxxx>

Both typos can be fixed on commit and I think I am good with the
current approach, so:

Reviewed-by: Henry Wang <Henry.Wang@xxxxxxx>

I did a play with UBSAN enabled on FVP (arm64), in my setup,
the result Xen file is 3.7MB:

-rwxrwxr-x  1 xinwan02 xinwan02 3.7M Jun 26 14:47 xen
lrwxrwxrwx  1 xinwan02 xinwan02    3 Jun 26 14:47 xen.efi -> xen
-rwxrwxr-x  1 xinwan02 xinwan02  14M Jun 26 14:47 xen-syms

and the Xen and Dom0 booted fine and I can login Dom0. So
technically:

Tested-by: Henry Wang <Henry.Wang@xxxxxxx>

However, I noticed Xen will print below during the Dom0 boot:
(XEN) 
================================================================================
(XEN) UBSAN: Undefined behaviour in arch/arm/vgic.c:371:15
(XEN) left shift of 1 by 31 places cannot be represented in type 'int'
(XEN) Xen WARN at common/ubsan/ubsan.c:172

Just want to make sure you also noticed this, otherwise maybe you
can include another patch in the series to fix this? Or I can do that
in case you don't have enough bandwidth.

Kind regards,
Henry



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.