* [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure
@ 2023-05-26 23:21 Hardik Garg
2023-05-26 23:23 ` kernel test robot
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Hardik Garg @ 2023-05-26 23:21 UTC (permalink / raw)
To: stable; +Cc: shuah, jeffxu, linux-kselftest, linux-kernel, code, niyelchu
Partially backport v6.3 commit 11f75a01448f ("selftests/memfd: add
tests for MFD_NOEXEC_SEAL MFD_EXEC") to fix an unknown type name
build error.
In some systems, the __u64 typedef is not present due to differences
in system headers, causing compilation errors like this one:
fuse_test.c:64:8: error: unknown type name '__u64'
64 | static __u64 mfd_assert_get_seals(int fd)
This header includes the __u64 typedef which increases the
likelihood of successful compilation on a wider variety of systems.
Signed-off-by: Hardik Garg <hargar@linux.microsoft.com>
---
tools/testing/selftests/memfd/fuse_test.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/testing/selftests/memfd/fuse_test.c b/tools/testing/selftests/memfd/fuse_test.c
index be675002f918..93798c8c5d54 100644
--- a/tools/testing/selftests/memfd/fuse_test.c
+++ b/tools/testing/selftests/memfd/fuse_test.c
@@ -22,6 +22,7 @@
#include <linux/falloc.h>
#include <fcntl.h>
#include <linux/memfd.h>
+#include <linux/types.h>
#include <sched.h>
#include <stdio.h>
#include <stdlib.h>
--
2.25.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure
2023-05-26 23:21 [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure Hardik Garg
@ 2023-05-26 23:23 ` kernel test robot
2023-05-27 1:20 ` Tyler Hicks
2023-05-27 1:21 ` Tyler Hicks
2023-05-28 7:42 ` Greg KH
2 siblings, 1 reply; 6+ messages in thread
From: kernel test robot @ 2023-05-26 23:23 UTC (permalink / raw)
To: Hardik Garg; +Cc: stable, oe-kbuild-all
Hi,
Thanks for your patch.
FYI: kernel test robot notices the stable kernel rule is not satisfied.
Rule: 'Cc: stable@vger.kernel.org' or 'commit <sha1> upstream.'
Subject: [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure
Link: https://lore.kernel.org/stable/20230526232136.255244-1-hargar%40linux.microsoft.com
The check is based on https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
Please ignore this mail if the patch is not relevant for upstream.
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure
2023-05-26 23:23 ` kernel test robot
@ 2023-05-27 1:20 ` Tyler Hicks
2023-05-28 7:40 ` Greg KH
0 siblings, 1 reply; 6+ messages in thread
From: Tyler Hicks @ 2023-05-27 1:20 UTC (permalink / raw)
To: kernel test robot; +Cc: Hardik Garg, stable, oe-kbuild-all
On 2023-05-27 07:23:22, kernel test robot wrote:
> Hi,
>
> Thanks for your patch.
>
> FYI: kernel test robot notices the stable kernel rule is not satisfied.
>
> Rule: 'Cc: stable@vger.kernel.org' or 'commit <sha1> upstream.'
> Subject: [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure
> Link: https://lore.kernel.org/stable/20230526232136.255244-1-hargar%40linux.microsoft.com
>
> The check is based on https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
>
> Please ignore this mail if the patch is not relevant for upstream.
I think Hardik did the right thing here. This is a build failure bug
that's present in stable kernels but was fixed in upstream by an
unrelated commit:
11f75a01448f ("selftests/memfd: add tests for MFD_NOEXEC_SEAL MFD_EXEC")
It wouldn't be right to backport that patch because MFD_NOEXEC_SEAL and
MFD_EXEC weren't introduced until v6.3.
There was an (unmerged) attempt to fix this specific build failure in upstream:
https://lore.kernel.org/all/20211203024706.10094-1-luke.nowakowskikrijger@canonical.com/
Hardik opted to follow what was done upstream in a patch specifically
for the stable tree.
Tyler
>
> --
> 0-DAY CI Kernel Test Service
> https://github.com/intel/lkp-tests/wiki
>
>
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure
2023-05-26 23:21 [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure Hardik Garg
2023-05-26 23:23 ` kernel test robot
@ 2023-05-27 1:21 ` Tyler Hicks
2023-05-28 7:42 ` Greg KH
2 siblings, 0 replies; 6+ messages in thread
From: Tyler Hicks @ 2023-05-27 1:21 UTC (permalink / raw)
To: Hardik Garg
Cc: stable, shuah, jeffxu, linux-kselftest, linux-kernel, niyelchu
On 2023-05-26 16:21:36, Hardik Garg wrote:
> Partially backport v6.3 commit 11f75a01448f ("selftests/memfd: add
> tests for MFD_NOEXEC_SEAL MFD_EXEC") to fix an unknown type name
> build error.
> In some systems, the __u64 typedef is not present due to differences
> in system headers, causing compilation errors like this one:
>
> fuse_test.c:64:8: error: unknown type name '__u64'
> 64 | static __u64 mfd_assert_get_seals(int fd)
>
> This header includes the __u64 typedef which increases the
> likelihood of successful compilation on a wider variety of systems.
>
> Signed-off-by: Hardik Garg <hargar@linux.microsoft.com>
Reviewed-by: Tyler Hicks (Microsoft) <code@tyhicks.com>
Tyler
> ---
> tools/testing/selftests/memfd/fuse_test.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/tools/testing/selftests/memfd/fuse_test.c b/tools/testing/selftests/memfd/fuse_test.c
> index be675002f918..93798c8c5d54 100644
> --- a/tools/testing/selftests/memfd/fuse_test.c
> +++ b/tools/testing/selftests/memfd/fuse_test.c
> @@ -22,6 +22,7 @@
> #include <linux/falloc.h>
> #include <fcntl.h>
> #include <linux/memfd.h>
> +#include <linux/types.h>
> #include <sched.h>
> #include <stdio.h>
> #include <stdlib.h>
> --
> 2.25.1
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure
2023-05-27 1:20 ` Tyler Hicks
@ 2023-05-28 7:40 ` Greg KH
0 siblings, 0 replies; 6+ messages in thread
From: Greg KH @ 2023-05-28 7:40 UTC (permalink / raw)
To: Tyler Hicks; +Cc: kernel test robot, Hardik Garg, stable, oe-kbuild-all
On Fri, May 26, 2023 at 08:20:03PM -0500, Tyler Hicks wrote:
> On 2023-05-27 07:23:22, kernel test robot wrote:
> > Hi,
> >
> > Thanks for your patch.
> >
> > FYI: kernel test robot notices the stable kernel rule is not satisfied.
> >
> > Rule: 'Cc: stable@vger.kernel.org' or 'commit <sha1> upstream.'
> > Subject: [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure
> > Link: https://lore.kernel.org/stable/20230526232136.255244-1-hargar%40linux.microsoft.com
> >
> > The check is based on https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
> >
> > Please ignore this mail if the patch is not relevant for upstream.
>
> I think Hardik did the right thing here. This is a build failure bug
> that's present in stable kernels but was fixed in upstream by an
> unrelated commit:
>
> 11f75a01448f ("selftests/memfd: add tests for MFD_NOEXEC_SEAL MFD_EXEC")
>
> It wouldn't be right to backport that patch because MFD_NOEXEC_SEAL and
> MFD_EXEC weren't introduced until v6.3.
>
> There was an (unmerged) attempt to fix this specific build failure in upstream:
>
> https://lore.kernel.org/all/20211203024706.10094-1-luke.nowakowskikrijger@canonical.com/
>
> Hardik opted to follow what was done upstream in a patch specifically
> for the stable tree.
Yes, this is the right thing to do, you can ignore the bot :)
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure
2023-05-26 23:21 [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure Hardik Garg
2023-05-26 23:23 ` kernel test robot
2023-05-27 1:21 ` Tyler Hicks
@ 2023-05-28 7:42 ` Greg KH
2 siblings, 0 replies; 6+ messages in thread
From: Greg KH @ 2023-05-28 7:42 UTC (permalink / raw)
To: Hardik Garg
Cc: stable, shuah, jeffxu, linux-kselftest, linux-kernel, code,
niyelchu
On Fri, May 26, 2023 at 04:21:36PM -0700, Hardik Garg wrote:
> Partially backport v6.3 commit 11f75a01448f ("selftests/memfd: add
> tests for MFD_NOEXEC_SEAL MFD_EXEC") to fix an unknown type name
> build error.
> In some systems, the __u64 typedef is not present due to differences
> in system headers, causing compilation errors like this one:
>
> fuse_test.c:64:8: error: unknown type name '__u64'
> 64 | static __u64 mfd_assert_get_seals(int fd)
>
> This header includes the __u64 typedef which increases the
> likelihood of successful compilation on a wider variety of systems.
>
> Signed-off-by: Hardik Garg <hargar@linux.microsoft.com>
> ---
> tools/testing/selftests/memfd/fuse_test.c | 1 +
> 1 file changed, 1 insertion(+)
Now queued up, thanks.
greg k-h
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2023-05-28 7:42 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-05-26 23:21 [PATCH 6.1 5.15 5.10 5.4 4.19 4.14] selftests/memfd: Fix unknown type name build failure Hardik Garg
2023-05-26 23:23 ` kernel test robot
2023-05-27 1:20 ` Tyler Hicks
2023-05-28 7:40 ` Greg KH
2023-05-27 1:21 ` Tyler Hicks
2023-05-28 7:42 ` Greg KH
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).