Skip to contentSkip to conversation

qemu: Fix building with latest glibc 2.36

PATCH Martin Jansa 2 participants 4 messages Feb 22, 2023 – Feb 23, 2023 1 message not in the archive

lore
Share & tools
lore
#1 lore raw
In reply to a message not in the archive

Hi,

I've seen this build issue on my gentoo builder today with qemu-native, so I've removed the stray cross.patch and sent v2.

Then RP had good question how to reproduce this failure and I've checked when I've updated glibc in gentoo for last time and it was a month ago (and I've rebuilt qemu-native few time since then).

So in the end it was linux-libc-headers upgrade to 6.2 from yesterday (sys-kernel/linux-headers-6.2 in gentoo) which caused this for me (if I downgrade to 6.1 I can build qemu-native again even without this patch).

Joel: Should I send v3 with updated commit message or will you do it?

Regards,

Quoted 239 lines · Martin Jansa via lists.openembedded.org

From: Joel Stanley <[email protected]>

When building native qemu with glibc 2.36 (including latest changes from the glibc stable branch), qemu fails to build:

In file included from /usr/include/linux/btrfs.h:29,

                  from ../qemu-7.2.0/linux-user/syscall.c:165:
 /usr/include/linux/fs.h:50:8: error: redefinition of ‘struct
file_clone_range’
    50 | struct file_clone_range {
       |        ^~~~~~~~~~~~~~~~
 ../qemu-7.2.0/linux-user/syscall.c:129:8: note: originally defined here
   129 | struct file_clone_range {
       |        ^~~~~~~~~~~~~~~~

Backport changes to linux-user that remove the local copy of struct file_clone_range.

Patches from
https://lore.kernel.org/qemu-devel/[email protected]/

---
 meta/recipes-devtools/qemu/qemu.inc           |  2 +
 ...er-add-more-compat-ioctl-definitions.patch | 69 ++++++++++++++++
 ...r-fix-compat-with-glibc-2.36-sys-mou.patch | 78 +++++++++++++++++++
 3 files changed, 149 insertions(+)
 create mode 100644
meta/recipes-devtools/qemu/qemu/0001-Revert-linux-user-add-more-compat-ioctl-definitions.patch
 create mode 100644

meta/recipes-devtools/qemu/qemu/0002-Revert-linux-user-fix-compat-with-glibc-2.36-sys-mou.patch

meta/recipes-devtools/qemu/qemu.inc +0 -0
index 92828e8f2d..1e768b560d 100644
@@ -30,6 +30,8 @@ SRC_URI = "https://download.qemu.org/${BPN}-${PV}.tar.xz
 \
 
 file://0001-contrib-vhost-user-blk-Replace-lseek64-with-lseek.patch \
 
 file://0002-linux-user-Replace-use-of-lfs64-related-functions-an.patch \
 

file://0001-configure-Fix-check-tcg-not-executing-any-tests.patch \

meta/recipes-devtools/qemu/qemu.inc +2 -0
+
 file://0001-Revert-linux-user-add-more-compat-ioctl-definitions.patch \
+
 file://0002-Revert-linux-user-fix-compat-with-glibc-2.36-sys-mou.patch \
            "
 UPSTREAM_CHECK_REGEX = "qemu-(?P<pver>\d+(\.\d+)+)\.tar"

diff --git a/meta/recipes-devtools/qemu/qemu/0001-Revert-linux-user-add-more-compat-ioctl-definitions.patch b/meta/recipes-devtools/qemu/qemu/0001-Revert-linux-user-add-more-compat-ioctl-definitions.patch new file mode 100644
index 0000000000..cd8121fed1
--- /dev/null
+++
b/meta/recipes-devtools/qemu/qemu/0001-Revert-linux-user-add-more-compat-ioctl-definitions.patch

meta/recipes-devtools/qemu/qemu.inc +16 -0
@@ -0,0 +1,69 @@
+From afa96c55f2c270405de8984e2466067bbb44c0e4 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= <[email protected]>
+Date: Tue, 10 Jan 2023 12:49:00 -0500
+Subject: [PATCH] Revert "linux-user: add more compat ioctl definitions"
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This reverts commit c5495f4ecb0cdaaf2e9dddeb48f1689cdb520ca0.
+
+glibc has fixed (in 2.36.9000-40-g774058d729) the problem
+that caused a clash when both sys/mount.h annd linux/mount.h
+are included, and backported this to the 2.36 stable release
+too:
+
+

https://sourceware.org/glibc/wiki/Release/2.36#Usage_of_.3Clinux.2Fmount.h.3E_and_.3Csys.2Fmount.h.3E

meta/recipes-devtools/qemu/qemu.inc +12 -0
+
+It is saner for QEMU to remove the workaround it applied for
+glibc 2.36 and expect distros to ship the 2.36 maint release
+with the fix. This avoids needing to add a further workaround
+to QEMU to deal with the fact that linux/brtfs.h now also pulls
+in linux/mount.h via linux/fs.h since Linux 6.1
+
+Upstream-Status: Backport from v8.0 (master)
+
+Signed-off-by: Daniel P. Berrangé <[email protected]>
+Reviewed-by: Marc-André Lureau <[email protected]>
+Link:

https://lore.kernel.org/r/[email protected]

meta/recipes-devtools/qemu/qemu.inc +41 -0
+Signed-off-by: Joel Stanley <[email protected]>
+---
+ linux-user/syscall.c | 25 -------------------------
+ 1 file changed, 25 deletions(-)
+
+diff --git a/linux-user/syscall.c b/linux-user/syscall.c
+index f95a6161e..510de8edc 100644
+--- a/linux-user/syscall.c
++++ b/linux-user/syscall.c
+@@ -111,31 +111,6 @@
+ #define FS_IOC32_SETFLAGS              _IOW('f', 2, int)
+ #define FS_IOC32_GETVERSION            _IOR('v', 1, int)
+ #define FS_IOC32_SETVERSION            _IOW('v', 2, int)
+-
+-#define BLKGETSIZE64 _IOR(0x12,114,size_t)
+-#define BLKDISCARD _IO(0x12,119)
+-#define BLKIOMIN _IO(0x12,120)
+-#define BLKIOOPT _IO(0x12,121)
+-#define BLKALIGNOFF _IO(0x12,122)
+-#define BLKPBSZGET _IO(0x12,123)
+-#define BLKDISCARDZEROES _IO(0x12,124)
+-#define BLKSECDISCARD _IO(0x12,125)
+-#define BLKROTATIONAL _IO(0x12,126)
+-#define BLKZEROOUT _IO(0x12,127)
+-
+-#define FIBMAP     _IO(0x00,1)
+-#define FIGETBSZ   _IO(0x00,2)
+-
+-struct file_clone_range {
+-        __s64 src_fd;
+-        __u64 src_offset;
+-        __u64 src_length;
+-        __u64 dest_offset;
+-};
+-
+-#define FICLONE         _IOW(0x94, 9, int)
+-#define FICLONERANGE    _IOW(0x94, 13, struct file_clone_range)
+-
+ #else
+ #include <linux/fs.h>
+ #endif

diff --git a/meta/recipes-devtools/qemu/qemu/0002-Revert-linux-user-fix-compat-with-glibc-2.36-sys-mou.patch b/meta/recipes-devtools/qemu/qemu/0002-Revert-linux-user-fix-compat-with-glibc-2.36-sys-mou.patch new file mode 100644
index 0000000000..d754f21ad4
--- /dev/null
+++
b/meta/recipes-devtools/qemu/qemu/0002-Revert-linux-user-fix-compat-with-glibc-2.36-sys-mou.patch

meta/recipes-devtools/qemu/qemu.inc +17 -0
@@ -0,0 +1,78 @@
+From e95c0a42940ca1cf763ca3374b36a9be030039d7 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= <[email protected]>
+Date: Tue, 10 Jan 2023 12:49:01 -0500
+Subject: [PATCH] Revert "linux-user: fix compat with glibc >= 2.36
+ sys/mount.h"
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This reverts commit 3cd3df2a9584e6f753bb62a0028bd67124ab5532.
+
+glibc has fixed (in 2.36.9000-40-g774058d729) the problem
+that caused a clash when both sys/mount.h annd linux/mount.h
+are included, and backported this to the 2.36 stable release
+too:
+
+

https://sourceware.org/glibc/wiki/Release/2.36#Usage_of_.3Clinux.2Fmount.h.3E_and_.3Csys.2Fmount.h.3E

meta/recipes-devtools/qemu/qemu.inc +12 -0
+
+It is saner for QEMU to remove the workaround it applied for
+glibc 2.36 and expect distros to ship the 2.36 maint release
+with the fix. This avoids needing to add a further workaround
+to QEMU to deal with the fact that linux/brtfs.h now also pulls
+in linux/mount.h via linux/fs.h since Linux 6.1
+
+Upstream-Status: Backport from v8.0 (master)
+
+Signed-off-by: Daniel P. Berrangé <[email protected]>
+Reviewed-by: Marc-André Lureau <[email protected]>
+Link:

https://lore.kernel.org/r/[email protected]

meta/recipes-devtools/qemu/qemu.inc +44 -0
+Signed-off-by: Joel Stanley <[email protected]>
+---
+ linux-user/syscall.c | 18 ------------------
+ meson.build          |  2 --
+ 2 files changed, 20 deletions(-)
+
+diff --git a/linux-user/syscall.c b/linux-user/syscall.c
+index 510de8edc..13a67b84b 100644
+--- a/linux-user/syscall.c
++++ b/linux-user/syscall.c
+@@ -95,25 +95,7 @@
+ #include <linux/soundcard.h>
+ #include <linux/kd.h>
+ #include <linux/mtio.h>
+-
+-#ifdef HAVE_SYS_MOUNT_FSCONFIG
+-/*
+- * glibc >= 2.36 linux/mount.h conflicts with sys/mount.h,
+- * which in turn prevents use of linux/fs.h. So we have to
+- * define the constants ourselves for now.
+- */
+-#define FS_IOC_GETFLAGS                _IOR('f', 1, long)
+-#define FS_IOC_SETFLAGS                _IOW('f', 2, long)
+-#define FS_IOC_GETVERSION              _IOR('v', 1, long)
+-#define FS_IOC_SETVERSION              _IOW('v', 2, long)
+-#define FS_IOC_FIEMAP                  _IOWR('f', 11, struct fiemap)
+-#define FS_IOC32_GETFLAGS              _IOR('f', 1, int)
+-#define FS_IOC32_SETFLAGS              _IOW('f', 2, int)
+-#define FS_IOC32_GETVERSION            _IOR('v', 1, int)
+-#define FS_IOC32_SETVERSION            _IOW('v', 2, int)
+-#else
+ #include <linux/fs.h>
+-#endif
+ #include <linux/fd.h>
+ #if defined(CONFIG_FIEMAP)
+ #include <linux/fiemap.h>
+diff --git a/meson.build b/meson.build
+index e44432370..f37ba4114 100644
+--- a/meson.build
++++ b/meson.build
+@@ -2032,8 +2032,6 @@ config_host_data.set('HAVE_OPTRESET',
+                      cc.has_header_symbol('getopt.h', 'optreset'))
+ config_host_data.set('HAVE_IPPROTO_MPTCP',
+                      cc.has_header_symbol('netinet/in.h',

'IPPROTO_MPTCP'))

+-config_host_data.set('HAVE_SYS_MOUNT_FSCONFIG',
+-                     cc.has_header_symbol('sys/mount.h',

'FSCONFIG_SET_FLAG'))
+
+ # has_member
+ config_host_data.set('HAVE_SIGEV_NOTIFY_THREAD_ID', --
2.39.2

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#177573):
https://lists.openembedded.org/g/openembedded-core/message/177573
Mute This Topic: https://lists.openembedded.org/mt/97161162/3617156
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [ [email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

#2 lore raw
Quoted 10 lines · Martin Jansa

Hi,

I've seen this build issue on my gentoo builder today with qemu-native, so I've removed the stray cross.patch and sent v2.

Then RP had good question how to reproduce this failure and I've checked when I've updated glibc in gentoo for last time and it was a month ago (and I've rebuilt qemu-native few time since then).

So in the end it was linux-libc-headers upgrade to 6.2 from yesterday (sys-kernel/linux-headers-6.2 in gentoo) which caused this for me (if I downgrade to 6.1 I can build qemu-native again even without this patch).

Joel: Should I send v3 with updated commit message or will you do it?

Thanks for picking this one up. Please continue the good work.

Cheers,

Joel

Quoted 218 lines

Regards,

Quoted 214 lines · Martin Jansa via lists.openembedded.org

From: Joel Stanley <[email protected]>

When building native qemu with glibc 2.36 (including latest changes from the glibc stable branch), qemu fails to build:

In file included from /usr/include/linux/btrfs.h:29,

                  from ../qemu-7.2.0/linux-user/syscall.c:165:
 /usr/include/linux/fs.h:50:8: error: redefinition of ‘struct file_clone_range’
    50 | struct file_clone_range {
       |        ^~~~~~~~~~~~~~~~
 ../qemu-7.2.0/linux-user/syscall.c:129:8: note: originally defined here
   129 | struct file_clone_range {
       |        ^~~~~~~~~~~~~~~~

Backport changes to linux-user that remove the local copy of struct file_clone_range.

Patches from https://lore.kernel.org/qemu-devel/[email protected]/

---
 meta/recipes-devtools/qemu/qemu.inc           |  2 +
 ...er-add-more-compat-ioctl-definitions.patch | 69 ++++++++++++++++
 ...r-fix-compat-with-glibc-2.36-sys-mou.patch | 78 +++++++++++++++++++
 3 files changed, 149 insertions(+)
 create mode 100644 meta/recipes-devtools/qemu/qemu/0001-Revert-linux-user-add-more-compat-ioctl-definitions.patch
 create mode 100644 meta/recipes-devtools/qemu/qemu/0002-Revert-linux-user-fix-compat-with-glibc-2.36-sys-mou.patch
meta/recipes-devtools/qemu/qemu.inc +2 -0
index 92828e8f2d..1e768b560d 100644
@@ -30,6 +30,8 @@ SRC_URI = "https://download.qemu.org/${BPN}-${PV}.tar.xz \
            file://0001-contrib-vhost-user-blk-Replace-lseek64-with-lseek.patch \
            file://0002-linux-user-Replace-use-of-lfs64-related-functions-an.patch \
            file://0001-configure-Fix-check-tcg-not-executing-any-tests.patch \
+           file://0001-Revert-linux-user-add-more-compat-ioctl-definitions.patch \
+           file://0002-Revert-linux-user-fix-compat-with-glibc-2.36-sys-mou.patch \
            "
 UPSTREAM_CHECK_REGEX = "qemu-(?P<pver>\d+(\.\d+)+)\.tar"
 
meta/recipes-devtools/qemu/qemu/0001-Revert-linux-user-add-more-compat-ioctl-definitions.patch new file +69 -0
new file mode 100644
index 0000000000..cd8121fed1
@@ -0,0 +1,69 @@
+From afa96c55f2c270405de8984e2466067bbb44c0e4 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= <[email protected]>
+Date: Tue, 10 Jan 2023 12:49:00 -0500
+Subject: [PATCH] Revert "linux-user: add more compat ioctl definitions"
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This reverts commit c5495f4ecb0cdaaf2e9dddeb48f1689cdb520ca0.
+
+glibc has fixed (in 2.36.9000-40-g774058d729) the problem
+that caused a clash when both sys/mount.h annd linux/mount.h
+are included, and backported this to the 2.36 stable release
+too:
+
+  https://sourceware.org/glibc/wiki/Release/2.36#Usage_of_.3Clinux.2Fmount.h.3E_and_.3Csys.2Fmount.h.3E
+
+It is saner for QEMU to remove the workaround it applied for
+glibc 2.36 and expect distros to ship the 2.36 maint release
+with the fix. This avoids needing to add a further workaround
+to QEMU to deal with the fact that linux/brtfs.h now also pulls
+in linux/mount.h via linux/fs.h since Linux 6.1
+
+Upstream-Status: Backport from v8.0 (master)
+
+Signed-off-by: Daniel P. Berrangé <[email protected]>
+Reviewed-by: Marc-André Lureau <[email protected]>
+Link: https://lore.kernel.org/r/[email protected]
+Signed-off-by: Joel Stanley <[email protected]>
+---
+ linux-user/syscall.c | 25 -------------------------
+ 1 file changed, 25 deletions(-)
+
+diff --git a/linux-user/syscall.c b/linux-user/syscall.c
+index f95a6161e..510de8edc 100644
+--- a/linux-user/syscall.c
++++ b/linux-user/syscall.c
+@@ -111,31 +111,6 @@
+ #define FS_IOC32_SETFLAGS              _IOW('f', 2, int)
+ #define FS_IOC32_GETVERSION            _IOR('v', 1, int)
+ #define FS_IOC32_SETVERSION            _IOW('v', 2, int)
+-
+-#define BLKGETSIZE64 _IOR(0x12,114,size_t)
+-#define BLKDISCARD _IO(0x12,119)
+-#define BLKIOMIN _IO(0x12,120)
+-#define BLKIOOPT _IO(0x12,121)
+-#define BLKALIGNOFF _IO(0x12,122)
+-#define BLKPBSZGET _IO(0x12,123)
+-#define BLKDISCARDZEROES _IO(0x12,124)
+-#define BLKSECDISCARD _IO(0x12,125)
+-#define BLKROTATIONAL _IO(0x12,126)
+-#define BLKZEROOUT _IO(0x12,127)
+-
+-#define FIBMAP     _IO(0x00,1)
+-#define FIGETBSZ   _IO(0x00,2)
+-
+-struct file_clone_range {
+-        __s64 src_fd;
+-        __u64 src_offset;
+-        __u64 src_length;
+-        __u64 dest_offset;
+-};
+-
+-#define FICLONE         _IOW(0x94, 9, int)
+-#define FICLONERANGE    _IOW(0x94, 13, struct file_clone_range)
+-
+ #else
+ #include <linux/fs.h>
+ #endif
meta/recipes-devtools/qemu/qemu/0002-Revert-linux-user-fix-compat-with-glibc-2.36-sys-mou.patch new file +78 -1
new file mode 100644
index 0000000000..d754f21ad4
@@ -0,0 +1,78 @@
+From e95c0a42940ca1cf763ca3374b36a9be030039d7 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= <[email protected]>
+Date: Tue, 10 Jan 2023 12:49:01 -0500
+Subject: [PATCH] Revert "linux-user: fix compat with glibc >= 2.36
+ sys/mount.h"
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This reverts commit 3cd3df2a9584e6f753bb62a0028bd67124ab5532.
+
+glibc has fixed (in 2.36.9000-40-g774058d729) the problem
+that caused a clash when both sys/mount.h annd linux/mount.h
+are included, and backported this to the 2.36 stable release
+too:
+
+  https://sourceware.org/glibc/wiki/Release/2.36#Usage_of_.3Clinux.2Fmount.h.3E_and_.3Csys.2Fmount.h.3E
+
+It is saner for QEMU to remove the workaround it applied for
+glibc 2.36 and expect distros to ship the 2.36 maint release
+with the fix. This avoids needing to add a further workaround
+to QEMU to deal with the fact that linux/brtfs.h now also pulls
+in linux/mount.h via linux/fs.h since Linux 6.1
+
+Upstream-Status: Backport from v8.0 (master)
+
+Signed-off-by: Daniel P. Berrangé <[email protected]>
+Reviewed-by: Marc-André Lureau <[email protected]>
+Link: https://lore.kernel.org/r/[email protected]
+Signed-off-by: Joel Stanley <[email protected]>
+---
+ linux-user/syscall.c | 18 ------------------
+ meson.build          |  2 --
+ 2 files changed, 20 deletions(-)
+
+diff --git a/linux-user/syscall.c b/linux-user/syscall.c
+index 510de8edc..13a67b84b 100644
+--- a/linux-user/syscall.c
++++ b/linux-user/syscall.c
+@@ -95,25 +95,7 @@
+ #include <linux/soundcard.h>
+ #include <linux/kd.h>
+ #include <linux/mtio.h>
+-
+-#ifdef HAVE_SYS_MOUNT_FSCONFIG
+-/*
+- * glibc >= 2.36 linux/mount.h conflicts with sys/mount.h,
+- * which in turn prevents use of linux/fs.h. So we have to
+- * define the constants ourselves for now.
+- */
+-#define FS_IOC_GETFLAGS                _IOR('f', 1, long)
+-#define FS_IOC_SETFLAGS                _IOW('f', 2, long)
+-#define FS_IOC_GETVERSION              _IOR('v', 1, long)
+-#define FS_IOC_SETVERSION              _IOW('v', 2, long)
+-#define FS_IOC_FIEMAP                  _IOWR('f', 11, struct fiemap)
+-#define FS_IOC32_GETFLAGS              _IOR('f', 1, int)
+-#define FS_IOC32_SETFLAGS              _IOW('f', 2, int)
+-#define FS_IOC32_GETVERSION            _IOR('v', 1, int)
+-#define FS_IOC32_SETVERSION            _IOW('v', 2, int)
+-#else
+ #include <linux/fs.h>
+-#endif
+ #include <linux/fd.h>
+ #if defined(CONFIG_FIEMAP)
+ #include <linux/fiemap.h>
+diff --git a/meson.build b/meson.build
+index e44432370..f37ba4114 100644
+--- a/meson.build
++++ b/meson.build
+@@ -2032,8 +2032,6 @@ config_host_data.set('HAVE_OPTRESET',
+                      cc.has_header_symbol('getopt.h', 'optreset'))
+ config_host_data.set('HAVE_IPPROTO_MPTCP',
+                      cc.has_header_symbol('netinet/in.h', 'IPPROTO_MPTCP'))
+-config_host_data.set('HAVE_SYS_MOUNT_FSCONFIG',
+-                     cc.has_header_symbol('sys/mount.h', 'FSCONFIG_SET_FLAG'))
+
+ # has_member
+ config_host_data.set('HAVE_SIGEV_NOTIFY_THREAD_ID',
--

2.39.2

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#177573): https://lists.openembedded.org/g/openembedded-core/message/177573
Mute This Topic: https://lists.openembedded.org/mt/97161162/3617156
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

#3 lore raw
Quoted 11 lines · Joel Stanley
Quoted 4 lines · Martin Jansa

Hi,

I've seen this build issue on my gentoo builder today with qemu-native,

so I've removed the stray cross.patch and sent v2.

Quoted 2 lines

Then RP had good question how to reproduce this failure and I've checked

when I've updated glibc in gentoo for last time and it was a month ago (and I've rebuilt qemu-native few time since then).

Quoted 1 line
Quoted 8 lines
Quoted 1 line

So in the end it was linux-libc-headers upgrade to 6.2 from yesterday

(sys-kernel/linux-headers-6.2 in gentoo) which caused this for me (if I downgrade to 6.1 I can build qemu-native again even without this patch).

Quoted 2 lines

Joel: Should I send v3 with updated commit message or will you do it?

Thanks for picking this one up. Please continue the good work.

Can you confirm if it was related to glibc upgrade for you or it might be kernel headers like for me and it just looked like glibc related?

#4 lore raw
Quoted 11 lines · Martin Jansa
Quoted 9 lines · Joel Stanley
Quoted 7 lines · Martin Jansa

Hi,

I've seen this build issue on my gentoo builder today with qemu-native, so I've removed the stray cross.patch and sent v2.

Then RP had good question how to reproduce this failure and I've checked when I've updated glibc in gentoo for last time and it was a month ago (and I've rebuilt qemu-native few time since then).

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

So in the end it was linux-libc-headers upgrade to 6.2 from yesterday (sys-kernel/linux-headers-6.2 in gentoo) which caused this for me (if I downgrade to 6.1 I can build qemu-native again even without this patch).

Joel: Should I send v3 with updated commit message or will you do it?

Thanks for picking this one up. Please continue the good work.

Can you confirm if it was related to glibc upgrade for you or it might be kernel headers like for me and it just looked like glibc related?

I pointed the fingers at glibc because of the comments in the qemu revert, but you're probably on the money with kernel headers as /usr/include/linux/fs.h comes from the kernel.

I run Debian testing so while I'm not sure what I changed when, I would have upgraded the kernel headers recently.