All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1] selftests mount: Fix mount_setattr_test builds failed
@ 2023-03-23 17:28 ` Anh Tuan Phan
  0 siblings, 0 replies; 8+ messages in thread
From: Anh Tuan Phan @ 2023-03-23 17:28 UTC (permalink / raw)
  To: brauner, sforshee, shuah
  Cc: Anh Tuan Phan, linux-fsdevel, linux-kernel-mentees

When compiling selftests with target mount_setattr I encountered some errors with the below messages:
mount_setattr_test.c: In function ‘mount_setattr_thread’:
mount_setattr_test.c:343:16: error: variable ‘attr’ has initializer but incomplete type
  343 |         struct mount_attr attr = {
      |                ^~~~~~~~~~

These errors are might be because of linux/mount.h is not included. This patch resolves that issue.

Signed-off-by: Anh Tuan Phan <tuananhlfc@gmail.com>
---
 tools/testing/selftests/mount_setattr/mount_setattr_test.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tools/testing/selftests/mount_setattr/mount_setattr_test.c b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
index 582669ca38e9..7ca13a924e34 100644
--- a/tools/testing/selftests/mount_setattr/mount_setattr_test.c
+++ b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
@@ -18,6 +18,7 @@
 #include <grp.h>
 #include <stdbool.h>
 #include <stdarg.h>
+#include "linux/mount.h"
 
 #include "../kselftest_harness.h"
 
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v1] selftests mount: Fix mount_setattr_test builds failed
@ 2023-03-23 17:28 ` Anh Tuan Phan
  0 siblings, 0 replies; 8+ messages in thread
From: Anh Tuan Phan @ 2023-03-23 17:28 UTC (permalink / raw)
  To: brauner, sforshee, shuah
  Cc: linux-fsdevel, linux-kernel-mentees, Anh Tuan Phan

When compiling selftests with target mount_setattr I encountered some errors with the below messages:
mount_setattr_test.c: In function ‘mount_setattr_thread’:
mount_setattr_test.c:343:16: error: variable ‘attr’ has initializer but incomplete type
  343 |         struct mount_attr attr = {
      |                ^~~~~~~~~~

These errors are might be because of linux/mount.h is not included. This patch resolves that issue.

Signed-off-by: Anh Tuan Phan <tuananhlfc@gmail.com>
---
 tools/testing/selftests/mount_setattr/mount_setattr_test.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tools/testing/selftests/mount_setattr/mount_setattr_test.c b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
index 582669ca38e9..7ca13a924e34 100644
--- a/tools/testing/selftests/mount_setattr/mount_setattr_test.c
+++ b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
@@ -18,6 +18,7 @@
 #include <grp.h>
 #include <stdbool.h>
 #include <stdarg.h>
+#include "linux/mount.h"
 
 #include "../kselftest_harness.h"
 
-- 
2.34.1

_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH v1] selftests mount: Fix mount_setattr_test builds failed
  2023-03-23 17:28 ` Anh Tuan Phan
@ 2023-03-23 18:07   ` Seth Forshee
  -1 siblings, 0 replies; 8+ messages in thread
From: Seth Forshee @ 2023-03-23 18:07 UTC (permalink / raw)
  To: Anh Tuan Phan; +Cc: brauner, shuah, linux-fsdevel, linux-kernel-mentees

On Fri, Mar 24, 2023 at 12:28:59AM +0700, Anh Tuan Phan wrote:
> When compiling selftests with target mount_setattr I encountered some errors with the below messages:
> mount_setattr_test.c: In function ‘mount_setattr_thread’:
> mount_setattr_test.c:343:16: error: variable ‘attr’ has initializer but incomplete type
>   343 |         struct mount_attr attr = {
>       |                ^~~~~~~~~~
> 
> These errors are might be because of linux/mount.h is not included. This patch resolves that issue.
> 
> Signed-off-by: Anh Tuan Phan <tuananhlfc@gmail.com>
> ---
>  tools/testing/selftests/mount_setattr/mount_setattr_test.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/tools/testing/selftests/mount_setattr/mount_setattr_test.c b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
> index 582669ca38e9..7ca13a924e34 100644
> --- a/tools/testing/selftests/mount_setattr/mount_setattr_test.c
> +++ b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
> @@ -18,6 +18,7 @@
>  #include <grp.h>
>  #include <stdbool.h>
>  #include <stdarg.h>
> +#include "linux/mount.h"
>  
>  #include "../kselftest_harness.h"

Oops, I had meant to send this fix before and forgot.

One minor nit. I'd prefer to see angle brackets used for this include,
since the kernel header path is passed using -isystem and angle brackets
are more conventional for system includes. It's also how most other
selftests include kernel headers. But either way:

Acked-by: Seth Forshee (DigitalOcean) <sforshee@kernel.org>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v1] selftests mount: Fix mount_setattr_test builds failed
@ 2023-03-23 18:07   ` Seth Forshee
  0 siblings, 0 replies; 8+ messages in thread
From: Seth Forshee @ 2023-03-23 18:07 UTC (permalink / raw)
  To: Anh Tuan Phan; +Cc: linux-fsdevel, linux-kernel-mentees, brauner, shuah

On Fri, Mar 24, 2023 at 12:28:59AM +0700, Anh Tuan Phan wrote:
> When compiling selftests with target mount_setattr I encountered some errors with the below messages:
> mount_setattr_test.c: In function ‘mount_setattr_thread’:
> mount_setattr_test.c:343:16: error: variable ‘attr’ has initializer but incomplete type
>   343 |         struct mount_attr attr = {
>       |                ^~~~~~~~~~
> 
> These errors are might be because of linux/mount.h is not included. This patch resolves that issue.
> 
> Signed-off-by: Anh Tuan Phan <tuananhlfc@gmail.com>
> ---
>  tools/testing/selftests/mount_setattr/mount_setattr_test.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/tools/testing/selftests/mount_setattr/mount_setattr_test.c b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
> index 582669ca38e9..7ca13a924e34 100644
> --- a/tools/testing/selftests/mount_setattr/mount_setattr_test.c
> +++ b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
> @@ -18,6 +18,7 @@
>  #include <grp.h>
>  #include <stdbool.h>
>  #include <stdarg.h>
> +#include "linux/mount.h"
>  
>  #include "../kselftest_harness.h"

Oops, I had meant to send this fix before and forgot.

One minor nit. I'd prefer to see angle brackets used for this include,
since the kernel header path is passed using -isystem and angle brackets
are more conventional for system includes. It's also how most other
selftests include kernel headers. But either way:

Acked-by: Seth Forshee (DigitalOcean) <sforshee@kernel.org>
_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH v2 1/1] selftests mount: Fix mount_setattr_test builds failed
  2023-03-23 18:07   ` Seth Forshee
@ 2023-03-24  2:14     ` Anh Tuan Phan
  -1 siblings, 0 replies; 8+ messages in thread
From: Anh Tuan Phan @ 2023-03-24  2:14 UTC (permalink / raw)
  To: sforshee; +Cc: linux-fsdevel, shuah, brauner, linux-kernel-mentees, tuananhlfc

When compiling selftests with target mount_setattr I encountered some errors with the below messages:
mount_setattr_test.c: In function ‘mount_setattr_thread’:
mount_setattr_test.c:343:16: error: variable ‘attr’ has initializer but incomplete type
  343 |         struct mount_attr attr = {
      |                ^~~~~~~~~~

These errors might be because of linux/mount.h is not included. This patch resolves that issue.

Signed-off-by: Anh Tuan Phan <tuananhlfc@gmail.com>
---
Thanks for replying so quickly, this is my first patch to the kernel. I
changed the include to use angle bracket as your suggestion.

 tools/testing/selftests/mount_setattr/mount_setattr_test.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tools/testing/selftests/mount_setattr/mount_setattr_test.c b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
index 582669ca38e9..c6a8c732b802 100644
--- a/tools/testing/selftests/mount_setattr/mount_setattr_test.c
+++ b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
@@ -18,6 +18,7 @@
 #include <grp.h>
 #include <stdbool.h>
 #include <stdarg.h>
+#include <linux/mount.h>
 
 #include "../kselftest_harness.h"
 
-- 
2.34.1

_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v2 1/1] selftests mount: Fix mount_setattr_test builds failed
@ 2023-03-24  2:14     ` Anh Tuan Phan
  0 siblings, 0 replies; 8+ messages in thread
From: Anh Tuan Phan @ 2023-03-24  2:14 UTC (permalink / raw)
  To: sforshee; +Cc: brauner, linux-fsdevel, linux-kernel-mentees, shuah, tuananhlfc

When compiling selftests with target mount_setattr I encountered some errors with the below messages:
mount_setattr_test.c: In function ‘mount_setattr_thread’:
mount_setattr_test.c:343:16: error: variable ‘attr’ has initializer but incomplete type
  343 |         struct mount_attr attr = {
      |                ^~~~~~~~~~

These errors might be because of linux/mount.h is not included. This patch resolves that issue.

Signed-off-by: Anh Tuan Phan <tuananhlfc@gmail.com>
---
Thanks for replying so quickly, this is my first patch to the kernel. I
changed the include to use angle bracket as your suggestion.

 tools/testing/selftests/mount_setattr/mount_setattr_test.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tools/testing/selftests/mount_setattr/mount_setattr_test.c b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
index 582669ca38e9..c6a8c732b802 100644
--- a/tools/testing/selftests/mount_setattr/mount_setattr_test.c
+++ b/tools/testing/selftests/mount_setattr/mount_setattr_test.c
@@ -18,6 +18,7 @@
 #include <grp.h>
 #include <stdbool.h>
 #include <stdarg.h>
+#include <linux/mount.h>
 
 #include "../kselftest_harness.h"
 
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH v2 1/1] selftests mount: Fix mount_setattr_test builds failed
  2023-03-24  2:14     ` Anh Tuan Phan
@ 2023-03-27  8:00       ` Christian Brauner
  -1 siblings, 0 replies; 8+ messages in thread
From: Christian Brauner @ 2023-03-27  8:00 UTC (permalink / raw)
  To: Anh Tuan Phan; +Cc: sforshee, linux-fsdevel, linux-kernel-mentees, shuah

On Fri, Mar 24, 2023 at 09:14:15AM +0700, Anh Tuan Phan wrote:
> When compiling selftests with target mount_setattr I encountered some errors with the below messages:
> mount_setattr_test.c: In function ‘mount_setattr_thread’:
> mount_setattr_test.c:343:16: error: variable ‘attr’ has initializer but incomplete type
>   343 |         struct mount_attr attr = {
>       |                ^~~~~~~~~~
> 
> These errors might be because of linux/mount.h is not included. This patch resolves that issue.
> 
> Signed-off-by: Anh Tuan Phan <tuananhlfc@gmail.com>
> ---

I think Seth already acked this. This can go via the selftest tree,
Acked-by: Christian Brauner <brauner@kernel.org>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v2 1/1] selftests mount: Fix mount_setattr_test builds failed
@ 2023-03-27  8:00       ` Christian Brauner
  0 siblings, 0 replies; 8+ messages in thread
From: Christian Brauner @ 2023-03-27  8:00 UTC (permalink / raw)
  To: Anh Tuan Phan; +Cc: linux-fsdevel, shuah, linux-kernel-mentees, sforshee

On Fri, Mar 24, 2023 at 09:14:15AM +0700, Anh Tuan Phan wrote:
> When compiling selftests with target mount_setattr I encountered some errors with the below messages:
> mount_setattr_test.c: In function ‘mount_setattr_thread’:
> mount_setattr_test.c:343:16: error: variable ‘attr’ has initializer but incomplete type
>   343 |         struct mount_attr attr = {
>       |                ^~~~~~~~~~
> 
> These errors might be because of linux/mount.h is not included. This patch resolves that issue.
> 
> Signed-off-by: Anh Tuan Phan <tuananhlfc@gmail.com>
> ---

I think Seth already acked this. This can go via the selftest tree,
Acked-by: Christian Brauner <brauner@kernel.org>
_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2023-03-27  8:00 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-23 17:28 [PATCH v1] selftests mount: Fix mount_setattr_test builds failed Anh Tuan Phan
2023-03-23 17:28 ` Anh Tuan Phan
2023-03-23 18:07 ` Seth Forshee
2023-03-23 18:07   ` Seth Forshee
2023-03-24  2:14   ` [PATCH v2 1/1] " Anh Tuan Phan
2023-03-24  2:14     ` Anh Tuan Phan
2023-03-27  8:00     ` Christian Brauner
2023-03-27  8:00       ` Christian Brauner

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.