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

Re: [PATCH v3 3/3] xen/riscv: initialize .bss section


  • To: Oleksii Kurochko <oleksii.kurochko@xxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • From: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
  • Date: Fri, 3 Mar 2023 10:33:49 +0000
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.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=k5n9hDcHY8X6iwfsyWRmEFEkECkAM83bv2we6AuXx98=; b=ZUJaJtBXkwIZMcXNPvFibRMV3GppyjvoXgMPHXUOZSqk7AWTkfltwoHHE7urmnjZnC0V6dXlyjOHE4WMGQASJyres84YLZz/PD9gEOGPVLqMp/3waQaMHn3561FQMNgpdehK/87bN5Y62quU0lDS0QZ4/Y0cRTMGpJNf1TRWE7vNb/+D0pDF9iQm+kLIA4HZcs5wZa8vDV7qe2eUKCNtuSAlXzSSw/mUsC/tLb6DLlBRrfWEtl1jWDdgnfrpPKb6W2N5fvPmcwWHRihkXehfQtONSLRBoB1NsJlqxzKrj8becz+ucFEqOKzm0Jp8BB7f6WZ88X6wlcoLE7zDJJ8qng==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=IlXaF2zXrXer4eX+9blqpn/8q/1YSRYoOD9wKKBu22XnyLvcEC0mfcuAFr/tOdBfZZMTq3KaAwiVEVR7XBWCQrNJW+2/iLxfWOct4Kb8MtzLjuDSf87PJXnNq8b9GKZhBVNAJbTXD/uZDgio8M19jc3R5r5gVgXQ9KQSx1tJ8WmAUk5WgN1RI8YZ1Ouqzib/jEWdvyDUWaS5dTxMjo3m5kd+gxId1I8/34wlVCOmDdV8DxgT8nCkWW89REYsIknK7c/Bbt+3ok/lhds0bMqyei7ukeU01FefwNzog9YY2LE0kgwFnvWkgJJCQwPdoyXcEI0Hro3kWpTuzHf3X46hHg==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
  • Cc: Jan Beulich <jbeulich@xxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Gianluca Guida <gianluca@xxxxxxxxxxxx>, Bob Eshleman <bobbyeshleman@xxxxxxxxx>, Alistair Francis <alistair.francis@xxxxxxx>, Connor Davis <connojdavis@xxxxxxxxx>
  • Delivery-date: Fri, 03 Mar 2023 10:36:00 +0000
  • Ironport-data: A9a23:JVRhdau5Jl1QB3gtns6aabAIgefnVOJfMUV32f8akzHdYApBsoF/q tZmKTuPOvmPNDOjco0jO9/gphlXv5+EyIRnHQM/qiE0QX5D+JbJXdiXEBz9bniYRiHhoOCLz O1FM4Wdc5pkJpP4jk3wWlQ0hSAkjclkfpKlVKiffHg3HVQ+IMsYoUoLs/YjhYJ1isSODQqIu Nfjy+XSI1bg0DNvWo4uw/vrRChH4bKj6Fv0gnRkPaoQ5ASGzCFMZH4iDfrZw0XQE9E88tGSH 44v/JnhlkvF8hEkDM+Sk7qTWiXmlZaLYGBiIlIPM0STqkAqSh4ai87XB9JFAatjsB2bnsgZ9 Tl4ncfYpTHFnEH7sL91vxFwS0mSNEDdkVPNCSDXXce7lyUqf5ZwqhnH4Y5f0YAwo45K7W9yG fMwMRAMV0DZn/qM0J28Tcl92eA9FM3LI9ZK0p1g5Wmx4fcOZ7nmGv+PwOACmTA6i4ZJAOrUY NcfZXx3dhPcbhZTO1ARTpUjgOOvgXq5eDpdwL6XjfNvvy6Pk0ovjv6xbLI5efTTLSlRtm+eq njL4CLSBRYCOcbE4TGE7mitlqnEmiaTtIc6ReznrKM33Az7Kmo7CEUofgaRq9OAr2WzXt5jI WIY23ElhP1nnKCsZpynN/Gim1aDuhMfQNtRVe4n8gaGyqnTywmcD2kACDVGbbQOpMIwADAny FKNt9foHiB09q2YT2qH8bWZpi/0PjIaRUcAbyIZSQoO4/H4vZo+yBnIS75LC7Wph9f4HTXxx TGiryUkgbgXy8kR2M2T8lHOhTaxrZHhVA8r4R7WWGnj5QR8DKavYIai+FXA7fJNKY+fZlaEt XkA3cOZ6YgmBJWMjzCEQf9LEqug4f2EKxXDjVUpFJ4knxym/HileoJc6S9/P29mN88FfXniZ 0q7hO9KzJpaPX/vaLAtZYu0Up4u1fK4SYijUe3IZN1TZJQ3bBWA4CxleU+X2SbqjVQolqY8f 5ycdK5AEEonNEiu9xLuL8917FPh7npjlAs/mbiTI8yb7Iej
  • Ironport-hdrordr: A9a23:Bh2Ai6u8Dbvg/Degfhw8udUq7skDRtV00zEX/kB9WHVpm6uj+/ xG/c516faQsl0ssR4b9+xoVJPgfZq/z+8X3WBhB9eftWDd0QPDQb2Ki7GSpgEIcBeOlNK1u5 0QFZRWOZndCkV7kNa/wCTQKadY/DBfytHNuQ4J9QYLcT1X
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 03/03/2023 10:24 am, Oleksii Kurochko wrote:
> Signed-off-by: Oleksii Kurochko <oleksii.kurochko@xxxxxxxxx>

Reviewed-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>

> diff --git a/xen/arch/riscv/riscv64/head.S b/xen/arch/riscv/riscv64/head.S
> index adf5d6c74a..8887f0cbd4 100644
> --- a/xen/arch/riscv/riscv64/head.S
> +++ b/xen/arch/riscv/riscv64/head.S
> @@ -18,6 +19,14 @@ ENTRY(start)
>          li      t0, SSTATUS_FS
>          csrc    CSR_SSTATUS, t0
>  
> +        /* Clear the BSS */
> +        la      t3, __bss_start
> +        la      t4, __bss_end
> +.L_clear_bss:
> +        REG_S   zero, (t3)
> +        add     t3, t3, __SIZEOF_POINTER__
> +        bltu    t3, t4, .L_clear_bss

Using t3/t4 is fine, but it would also have been fine to use t0/t1.

~Andrew



 


Rackspace

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