[Kernel-packages] [Bug 1991790] Re: Disable sv57 as the userspace is not ready

2022-12-07 Thread Ubuntu Kernel Bot
This bug is awaiting verification that the linux-
hwe-5.19/5.19.0-24.25~22.04.1 kernel in -proposed solves the problem.
Please test the kernel and update this bug with the results. If the
problem is solved, change the tag 'verification-needed-jammy' to
'verification-done-jammy'. If the problem still exists, change the tag
'verification-needed-jammy' to 'verification-failed-jammy'.

If verification is not done by 5 working days from today, this fix will
be dropped from the source code, and this bug will be closed.

See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how
to enable and use -proposed. Thank you!


** Tags added: kernel-spammed-jammy-linux-hwe-5.19 verification-needed-jammy

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux-riscv in Ubuntu.
https://bugs.launchpad.net/bugs/1991790

Title:
  Disable sv57 as the userspace is not ready

Status in linux-riscv package in Ubuntu:
  Fix Released

Bug description:
  [ Impact ]

  * Linux 5.18 merged support for 5-level page tables (sv57), and it
    does it such that 5-level page tables are used whenever the
    system supports it.

  * So far only Qemu support sv57, but it breaks Go since Go uses
    too many of the upper bits of pointers to store data, and is not
    yet ready for sv57. It probably breaks other types of software
    using too many bits for this "pointer tagging" technique too.
    At the moment, there is no way to indicate to the kernel to
    downgrade to sv48, so we must patch the kernel:

  diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c
  index 2c4a64e97aec..18a0c70ed313 100644
  --- a/arch/riscv/mm/init.c
  +++ b/arch/riscv/mm/init.c
  @@ -775,6 +775,10 @@ static __init void set_satp_mode(void)
  disable_pgtable_l4();
  }

  +   /* UBUNTU: Force disable sv57 and fallback to sv48 */
  +   if (pgtable_l5_enabled)
  +   disable_pgtable_l5();
  +
  memset(early_pg_dir, 0, PAGE_SIZE);
  memset(early_p4d, 0, PAGE_SIZE);
  memset(early_pud, 0, PAGE_SIZE);

  [ Test Plan ]

  * Build an image with the patched kernel and make sure snapd and
    other Go programs work correctly and that you can compile a
    simple helloworld written in Go.

  [ Where problems could occur ]

  * The patch could be buggy.

  * Qemu will no longer work with > 256 TB of memory.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux-riscv/+bug/1991790/+subscriptions


-- 
Mailing list: https://launchpad.net/~kernel-packages
Post to : kernel-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kernel-packages
More help   : https://help.launchpad.net/ListHelp


[Kernel-packages] [Bug 1991790] Re: Disable sv57 as the userspace is not ready

2022-10-10 Thread Emil Renner Berthing
** Changed in: linux-riscv (Ubuntu)
 Assignee: (unassigned) => Emil Renner Berthing (esmil)

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux-riscv in Ubuntu.
https://bugs.launchpad.net/bugs/1991790

Title:
  Disable sv57 as the userspace is not ready

Status in linux-riscv package in Ubuntu:
  New

Bug description:
  [ Impact ]

  * Linux 5.18 merged support for 5-level page tables (sv57), and it
    does it such that 5-level page tables are used whenever the
    system supports it.

  * So far only Qemu support sv57, but it breaks Go since Go uses
    too many of the upper bits of pointers to store data, and is not
    yet ready for sv57. It probably breaks other types of software
    using too many bits for this "pointer tagging" technique too.
    At the moment, there is no way to indicate to the kernel to
    downgrade to sv48, so we must patch the kernel:

  diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c
  index 2c4a64e97aec..18a0c70ed313 100644
  --- a/arch/riscv/mm/init.c
  +++ b/arch/riscv/mm/init.c
  @@ -775,6 +775,10 @@ static __init void set_satp_mode(void)
  disable_pgtable_l4();
  }

  +   /* UBUNTU: Force disable sv57 and fallback to sv48 */
  +   if (pgtable_l5_enabled)
  +   disable_pgtable_l5();
  +
  memset(early_pg_dir, 0, PAGE_SIZE);
  memset(early_p4d, 0, PAGE_SIZE);
  memset(early_pud, 0, PAGE_SIZE);

  [ Test Plan ]

  * Build an image with the patched kernel and make sure snapd and
    other Go programs work correctly and that you can compile a
    simple helloworld written in Go.

  [ Where problems could occur ]

  * The patch could be buggy.

  * Qemu will no longer work with > 256 TB of memory.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux-riscv/+bug/1991790/+subscriptions


-- 
Mailing list: https://launchpad.net/~kernel-packages
Post to : kernel-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kernel-packages
More help   : https://help.launchpad.net/ListHelp


[Kernel-packages] [Bug 1991790] Re: Disable sv57 as the userspace is not ready

2022-10-10 Thread Emil Renner Berthing
** Description changed:

  [ Impact ]
  
  * Linux 5.18 merged support for 5-level page tables (sv57), and it
    does it such that 5-level page tables are used whenever the
    system supports it.
  
  * So far only Qemu support sv57, but it breaks Go since Go uses
    too many of the upper bits of pointers to store data, and is not
    yet ready for sv57. It probably breaks other types of software
-   using too many bits for this "pointer tagging" technique.
+   using too many bits for this "pointer tagging" technique too.
    At the moment, there is no way to indicate to the kernel to
    downgrade to sv48, so we must patch the kernel:
  
  diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c
  index 2c4a64e97aec..18a0c70ed313 100644
  --- a/arch/riscv/mm/init.c
  +++ b/arch/riscv/mm/init.c
  @@ -775,6 +775,10 @@ static __init void set_satp_mode(void)
  disable_pgtable_l4();
  }
  
  +   /* UBUNTU: Force disable sv57 and fallback to sv48 */
  +   if (pgtable_l5_enabled)
  +   disable_pgtable_l5();
  +
  memset(early_pg_dir, 0, PAGE_SIZE);
  memset(early_p4d, 0, PAGE_SIZE);
  memset(early_pud, 0, PAGE_SIZE);
  
  [ Test Plan ]
  
  * Build an image with the patched kernel and make sure snapd and
-   other Go programs works correctly and that you can compile a
+   other Go programs work correctly and that you can compile a
    simple helloworld written in Go.
  
  [ Where problems could occur ]
  
  * The patch could be buggy.
  
  * Qemu will no longer work with > 256 TB of memory.

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux-riscv in Ubuntu.
https://bugs.launchpad.net/bugs/1991790

Title:
  Disable sv57 as the userspace is not ready

Status in linux-riscv package in Ubuntu:
  New

Bug description:
  [ Impact ]

  * Linux 5.18 merged support for 5-level page tables (sv57), and it
    does it such that 5-level page tables are used whenever the
    system supports it.

  * So far only Qemu support sv57, but it breaks Go since Go uses
    too many of the upper bits of pointers to store data, and is not
    yet ready for sv57. It probably breaks other types of software
    using too many bits for this "pointer tagging" technique too.
    At the moment, there is no way to indicate to the kernel to
    downgrade to sv48, so we must patch the kernel:

  diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c
  index 2c4a64e97aec..18a0c70ed313 100644
  --- a/arch/riscv/mm/init.c
  +++ b/arch/riscv/mm/init.c
  @@ -775,6 +775,10 @@ static __init void set_satp_mode(void)
  disable_pgtable_l4();
  }

  +   /* UBUNTU: Force disable sv57 and fallback to sv48 */
  +   if (pgtable_l5_enabled)
  +   disable_pgtable_l5();
  +
  memset(early_pg_dir, 0, PAGE_SIZE);
  memset(early_p4d, 0, PAGE_SIZE);
  memset(early_pud, 0, PAGE_SIZE);

  [ Test Plan ]

  * Build an image with the patched kernel and make sure snapd and
    other Go programs work correctly and that you can compile a
    simple helloworld written in Go.

  [ Where problems could occur ]

  * The patch could be buggy.

  * Qemu will no longer work with > 256 TB of memory.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux-riscv/+bug/1991790/+subscriptions


-- 
Mailing list: https://launchpad.net/~kernel-packages
Post to : kernel-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kernel-packages
More help   : https://help.launchpad.net/ListHelp


[Kernel-packages] [Bug 1991790] Re: Disable sv57 as the userspace is not ready

2022-10-10 Thread Emil Renner Berthing
** Description changed:

  [ Impact ]
  
- sv57 breaks Go since Go uses the upper bits of a pointer to store data,
- and it is not ready for sv57 yet. It probably breaks other type of
- software using this "pointer tagging" technic. The following patch fixes
- this: at the moment, there is no way to indicate to the kernel to
- downgrade to sv48, so we must patch the kernel.
+ * Linux 5.18 merged support for 5-level page tables (sv57), and it
+   does it such that 5-level page tables are used whenever the
+   system supports it.
+ 
+ * So far only Qemu support sv57, but it breaks Go since Go uses
+   too many of the upper bits of pointers to store data, and is not
+   yet ready for sv57. It probably breaks other types of software
+   using too many bits for this "pointer tagging" technique.
+   At the moment, there is no way to indicate to the kernel to
+   downgrade to sv48, so we must patch the kernel:
  
  diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c
  index 2c4a64e97aec..18a0c70ed313 100644
  --- a/arch/riscv/mm/init.c
  +++ b/arch/riscv/mm/init.c
  @@ -775,6 +775,10 @@ static __init void set_satp_mode(void)
- disable_pgtable_l4();
- }
-  
+ disable_pgtable_l4();
+ }
+ 
  +   /* UBUNTU: Force disable sv57 and fallback to sv48 */
  +   if (pgtable_l5_enabled)
  +   disable_pgtable_l5();
  +
- memset(early_pg_dir, 0, PAGE_SIZE);
- memset(early_p4d, 0, PAGE_SIZE);
- memset(early_pud, 0, PAGE_SIZE);
+ memset(early_pg_dir, 0, PAGE_SIZE);
+ memset(early_p4d, 0, PAGE_SIZE);
+ memset(early_pud, 0, PAGE_SIZE);
  
  [ Test Plan ]
  
- Build an image with the new kernel and make sure snapd started
- correctly, or that you can compile a simple helloworld written in Go.
+ * Build an image with the patched kernel and make sure snapd and
+   other Go programs works correctly and that you can compile a
+   simple helloworld written in Go.
  
  [ Where problems could occur ]
  
- The patch could be wrong, but I already built a kernel with it and it
- worked fine.
+ * The patch could be buggy.
+ 
+ * Qemu will no longer work with > 128 PB of memory.

** Description changed:

  [ Impact ]
  
  * Linux 5.18 merged support for 5-level page tables (sv57), and it
-   does it such that 5-level page tables are used whenever the
-   system supports it.
+   does it such that 5-level page tables are used whenever the
+   system supports it.
  
  * So far only Qemu support sv57, but it breaks Go since Go uses
-   too many of the upper bits of pointers to store data, and is not
-   yet ready for sv57. It probably breaks other types of software
-   using too many bits for this "pointer tagging" technique.
-   At the moment, there is no way to indicate to the kernel to
-   downgrade to sv48, so we must patch the kernel:
+   too many of the upper bits of pointers to store data, and is not
+   yet ready for sv57. It probably breaks other types of software
+   using too many bits for this "pointer tagging" technique.
+   At the moment, there is no way to indicate to the kernel to
+   downgrade to sv48, so we must patch the kernel:
  
  diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c
  index 2c4a64e97aec..18a0c70ed313 100644
  --- a/arch/riscv/mm/init.c
  +++ b/arch/riscv/mm/init.c
  @@ -775,6 +775,10 @@ static __init void set_satp_mode(void)
  disable_pgtable_l4();
  }
  
  +   /* UBUNTU: Force disable sv57 and fallback to sv48 */
  +   if (pgtable_l5_enabled)
  +   disable_pgtable_l5();
  +
  memset(early_pg_dir, 0, PAGE_SIZE);
  memset(early_p4d, 0, PAGE_SIZE);
  memset(early_pud, 0, PAGE_SIZE);
  
  [ Test Plan ]
  
  * Build an image with the patched kernel and make sure snapd and
-   other Go programs works correctly and that you can compile a
-   simple helloworld written in Go.
+   other Go programs works correctly and that you can compile a
+   simple helloworld written in Go.
  
  [ Where problems could occur ]
  
  * The patch could be buggy.
  
- * Qemu will no longer work with > 128 PB of memory.
+ * Qemu will no longer work with > 256 TB of memory.

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux-riscv in Ubuntu.
https://bugs.launchpad.net/bugs/1991790

Title:
  Disable sv57 as the userspace is not ready

Status in linux-riscv package in Ubuntu:
  New

Bug description:
  [ Impact ]

  * Linux 5.18 merged support for 5-level page tables (sv57), and it
    does it such that 5-level page tables are used whenever the
    system supports it.

  * So far only Qemu support sv57, but it breaks Go since Go uses
    too many of the upper bits of pointers to store data, and is not
    yet ready for sv57. It probably breaks other types of software
    using too many bits for this "pointer tagging" technique too.
    At the moment, there is no way to indicate to the