Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package grub2 for openSUSE:Factory checked 
in at 2023-02-08 17:19:53
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/grub2 (Old)
 and      /work/SRC/openSUSE:Factory/.grub2.new.4462 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "grub2"

Wed Feb  8 17:19:53 2023 rev:281 rq:1063714 version:2.06

Changes:
--------
--- /work/SRC/openSUSE:Factory/grub2/grub2.changes      2023-01-07 
17:16:18.516936867 +0100
+++ /work/SRC/openSUSE:Factory/.grub2.new.4462/grub2.changes    2023-02-08 
17:19:59.357853663 +0100
@@ -1,0 +2,18 @@
+Wed Feb  8 02:24:16 UTC 2023 - Michael Chang <mch...@suse.com>
+
+- Fix nvmf boot device setup (bsc#1207811)
+  * 0001-grub2-Can-t-setup-a-default-boot-device-correctly-on.patch
+
+-------------------------------------------------------------------
+Tue Feb  7 02:11:47 UTC 2023 - Michael Chang <mch...@suse.com>
+
+- Fix unknown filesystem error on disks with 4096 sector size (bsc#1207064)
+  * 0001-grub-core-modify-sector-by-sysfs-as-disk-sector.patch
+
+-------------------------------------------------------------------
+Sat Feb  4 05:57:02 UTC 2023 - Michael Chang <mch...@suse.com>
+
+- Fix GCC 13 build failure (bsc#1201089)
+  * 0002-AUDIT-0-http-boot-tracker-bug.patch
+
+-------------------------------------------------------------------

New:
----
  0001-grub-core-modify-sector-by-sysfs-as-disk-sector.patch
  0001-grub2-Can-t-setup-a-default-boot-device-correctly-on.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ grub2.spec ++++++
--- /var/tmp/diff_new_pack.t6BroP/_old  2023-02-08 17:20:03.513874064 +0100
+++ /var/tmp/diff_new_pack.t6BroP/_new  2023-02-08 17:20:03.537874182 +0100
@@ -478,6 +478,8 @@
 Patch952:       0001-ieee1275-Increase-initially-allocated-heap-from-1-4-.patch
 Patch953:       grub2-increase-crypttab-path-buffer.patch
 Patch954:       0001-grub2-Set-multiple-device-path-for-a-nvmf-boot-devic.patch
+Patch955:       0001-grub-core-modify-sector-by-sysfs-as-disk-sector.patch
+Patch956:       0001-grub2-Can-t-setup-a-default-boot-device-correctly-on.patch
 
 Requires:       gettext-runtime
 %if 0%{?suse_version} >= 1140

++++++ 0001-grub-core-modify-sector-by-sysfs-as-disk-sector.patch ++++++
>From 1eee02bbf2c11167e94f424846ce1de0b6e7fa8e Mon Sep 17 00:00:00 2001
From: Mukesh Kumar Chaurasiya <mchau...@linux.vnet.ibm.com>
Date: Fri, 3 Feb 2023 10:10:43 +0530
Subject: [PATCH] grub-core: modify sector by sysfs as disk sector

The disk sector size provided by sysfs file system considers the
sector size of 512 irrespective of disk sector size, Thus
causing the read by grub to an incorrect offset from what was
originally intended.

Considering the 512 sector size of sysfs data the actual sector
needs to be modified corresponding to disk sector size.

Signed-off-by: Mukesh Kumar Chaurasiya <mchau...@linux.vnet.ibm.com>
---
 grub-core/osdep/linux/hostdisk.c | 15 ++++++++++++---
 1 file changed, 12 insertions(+), 3 deletions(-)

--- a/grub-core/osdep/linux/hostdisk.c
+++ b/grub-core/osdep/linux/hostdisk.c
@@ -199,8 +199,15 @@
 
 #pragma GCC diagnostic ignored "-Wformat-nonliteral"
 
+static inline grub_disk_addr_t
+transform_sector (grub_disk_t disk, grub_disk_addr_t sector)
+{
+  return sector >> (disk->log_sector_size - GRUB_DISK_SECTOR_BITS);
+}
+
 static int
-grub_hostdisk_linux_find_partition (char *dev, grub_disk_addr_t sector)
+grub_hostdisk_linux_find_partition (const grub_disk_t disk, char *dev,
+                                    grub_disk_addr_t sector)
 {
   size_t len = strlen (dev);
   const char *format;
@@ -265,7 +272,8 @@
       if (fstat (fd, &st) < 0
          || !grub_util_device_is_mapped_stat (&st)
          || !grub_util_get_dm_node_linear_info (st.st_rdev, 0, 0, &start))
-       start = grub_util_find_partition_start_os (real_dev);
+       start = transform_sector (disk,
+                                 grub_util_find_partition_start_os (real_dev));
       /* We don't care about errors here.  */
       grub_errno = GRUB_ERR_NONE;
 
@@ -346,7 +354,8 @@
        && strncmp (dev, "/dev/", 5) == 0)
       {
        if (sector >= part_start)
-         is_partition = grub_hostdisk_linux_find_partition (dev, part_start);
+         is_partition = grub_hostdisk_linux_find_partition (disk, dev,
+                                                            part_start);
        else
          *max = part_start - sector;
       }

++++++ 0001-grub2-Can-t-setup-a-default-boot-device-correctly-on.patch ++++++
>From a59b58f6ae327a8f6949991cb5531db01e1ba14d Mon Sep 17 00:00:00 2001
From: Wen Xiong <wenxi...@linux.ibm.com>
Date: Tue, 7 Feb 2023 15:10:15 -0500
Subject: [PATCH] grub2: Can't setup a default boot device correctly on nvme
 device in Beta3

The patch in Bug 200486 - SUSE1205666 - SLES15SP5 Beta1: Setup multiple dev path
 for a nvmf boot device in grub2 caused the issue.  That patch didn't consider
nvme devices carefully.

The new patch will check "nvme-of" instead of "nvme" to call
build_multi_boot_device().

Signed-off-by: Wen Xiong<wenxi...@linux.ibm.com>
---
 grub-core/osdep/unix/platform.c | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/grub-core/osdep/unix/platform.c b/grub-core/osdep/unix/platform.c
index db8fa4b95..fb47c0ffa 100644
--- a/grub-core/osdep/unix/platform.c
+++ b/grub-core/osdep/unix/platform.c
@@ -288,11 +288,15 @@ grub_install_register_ieee1275 (int is_prep, const char 
*install_device,
        }
       *ptr = '\0';
     }
-  else if (grub_strstr(install_device, "nvme"))
-       boot_device =  build_multi_boot_device(install_device);
-  else
+  else {
     boot_device = get_ofpathname (install_device);
 
+    if (grub_strstr(boot_device, "nvme-of")) {
+       free (boot_device);
+       boot_device =  build_multi_boot_device(install_device);
+    }
+  }
+
   if (grub_util_exec ((const char * []){ "nvsetenv", "boot-device",
          boot_device, NULL }))
     {
-- 
2.39.1


++++++ 0002-AUDIT-0-http-boot-tracker-bug.patch ++++++
--- /var/tmp/diff_new_pack.t6BroP/_old  2023-02-08 17:20:03.953876224 +0100
+++ /var/tmp/diff_new_pack.t6BroP/_new  2023-02-08 17:20:03.961876263 +0100
@@ -15,17 +15,17 @@
 untrusted kernel anyway, but it will break trusted boot scenarios, where only
 signed code is allowed to be executed.
 
+v2: Fix GCC 13 build failure (bsc#1201089)
+
 Signed-off-by: Michael Chang <mch...@suse.com>
 ---
  grub-core/net/efi/net.c | 4 +++-
  grub-core/net/http.c    | 5 ++++-
  2 files changed, 7 insertions(+), 2 deletions(-)
 
-diff --git a/grub-core/net/efi/net.c b/grub-core/net/efi/net.c
-index 0bac343b4..5bc604ff0 100644
 --- a/grub-core/net/efi/net.c
 +++ b/grub-core/net/efi/net.c
-@@ -645,8 +645,10 @@ grub_efihttp_chunk_read (grub_file_t file, char *buf,
+@@ -654,8 +654,10 @@
  
        rd = efi_net_interface (read, file, chunk, sz);
  
@@ -37,21 +37,19 @@
  
        if (buf)
        {
-diff --git a/grub-core/net/http.c b/grub-core/net/http.c
-index f182d7b87..5004ecfee 100644
 --- a/grub-core/net/http.c
 +++ b/grub-core/net/http.c
-@@ -31,7 +31,8 @@ GRUB_MOD_LICENSE ("GPLv3+");
+@@ -31,7 +31,8 @@
  
  enum
    {
 -    HTTP_PORT = 80
 +    HTTP_PORT = 80,
-+    HTTP_MAX_CHUNK_SIZE = 0x80000000
++    HTTP_MAX_CHUNK_SIZE = GRUB_INT_MAX
    };
  
  
-@@ -78,6 +79,8 @@ parse_line (grub_file_t file, http_data_t data, char *ptr, 
grub_size_t len)
+@@ -78,6 +79,8 @@
    if (data->in_chunk_len == 2)
      {
        data->chunk_rem = grub_strtoul (ptr, 0, 16);
@@ -60,7 +58,4 @@
        grub_errno = GRUB_ERR_NONE;
        if (data->chunk_rem == 0)
        {
--- 
-2.12.0
-
 

Reply via email to