2020-06-23 00:43:30

by Nathan Chancellor

[permalink] [raw]
Subject: [PATCH 0/2] Small fixes around cacheflush.h

Hi all,

These two patches are the culmination of the small discussion here:

https://lore.kernel.org/lkml/CAMuHMdVSduTOi5bUgF9sLQdGADwyL1+qALWsKgin1TeOLGhAKQ@mail.gmail.com/

I have fallen behind on fixing issues so sorry for not sending these
sooner and letting these warnings slip into mainline. Please let me know
if there are any comments or concerns. They are two completely
independent patches so if they need to be routed via separate trees,
that is fine. It was just easier to send them together since they are
dealing with the same problem.

Cheers,
Nathan



2020-06-23 00:45:04

by Nathan Chancellor

[permalink] [raw]
Subject: [PATCH 1/2] media: omap3isp: Remove cacheflush.h

After mm.h was removed from the asm-generic version of cacheflush.h,
s390 allyesconfig shows several warnings of the following nature:

In file included from ./arch/s390/include/generated/asm/cacheflush.h:1,
from drivers/media/platform/omap3isp/isp.c:42:
./include/asm-generic/cacheflush.h:16:42: warning: 'struct mm_struct'
declared inside parameter list will not be visible outside of this
definition or declaration

As Geert and Laurent point out, this driver does not need this header in
the two files that include it. Remove it so there are no warnings.

Fixes: e0cf615d725c ("asm-generic: don't include <linux/mm.h> in cacheflush.h")
Suggested-by: Geert Uytterhoeven <[email protected]>
Suggested-by: Laurent Pinchart <[email protected]>
Signed-off-by: Nathan Chancellor <[email protected]>
---
drivers/media/platform/omap3isp/isp.c | 2 --
drivers/media/platform/omap3isp/ispvideo.c | 1 -
2 files changed, 3 deletions(-)

diff --git a/drivers/media/platform/omap3isp/isp.c b/drivers/media/platform/omap3isp/isp.c
index a4ee6b86663e..b91e472ee764 100644
--- a/drivers/media/platform/omap3isp/isp.c
+++ b/drivers/media/platform/omap3isp/isp.c
@@ -39,8 +39,6 @@
* Troy Laramy <[email protected]>
*/

-#include <asm/cacheflush.h>
-
#include <linux/clk.h>
#include <linux/clkdev.h>
#include <linux/delay.h>
diff --git a/drivers/media/platform/omap3isp/ispvideo.c b/drivers/media/platform/omap3isp/ispvideo.c
index 10c214bd0903..1ac9aef70dff 100644
--- a/drivers/media/platform/omap3isp/ispvideo.c
+++ b/drivers/media/platform/omap3isp/ispvideo.c
@@ -18,7 +18,6 @@
#include <linux/sched.h>
#include <linux/slab.h>
#include <linux/vmalloc.h>
-#include <asm/cacheflush.h>

#include <media/v4l2-dev.h>
#include <media/v4l2-ioctl.h>

base-commit: 27f11fea33608cbd321a97cbecfa2ef97dcc1821
--
2.27.0

2020-06-23 01:23:13

by Laurent Pinchart

[permalink] [raw]
Subject: Re: [PATCH 1/2] media: omap3isp: Remove cacheflush.h

Hi Nathan,

Thank you for the patch.

On Mon, Jun 22, 2020 at 04:47:39PM -0700, Nathan Chancellor wrote:
> After mm.h was removed from the asm-generic version of cacheflush.h,
> s390 allyesconfig shows several warnings of the following nature:
>
> In file included from ./arch/s390/include/generated/asm/cacheflush.h:1,
> from drivers/media/platform/omap3isp/isp.c:42:
> ./include/asm-generic/cacheflush.h:16:42: warning: 'struct mm_struct'
> declared inside parameter list will not be visible outside of this
> definition or declaration
>
> As Geert and Laurent point out, this driver does not need this header in
> the two files that include it. Remove it so there are no warnings.
>
> Fixes: e0cf615d725c ("asm-generic: don't include <linux/mm.h> in cacheflush.h")
> Suggested-by: Geert Uytterhoeven <[email protected]>
> Suggested-by: Laurent Pinchart <[email protected]>
> Signed-off-by: Nathan Chancellor <[email protected]>

Reviewed-by: Laurent Pinchart <[email protected]>

> ---
> drivers/media/platform/omap3isp/isp.c | 2 --
> drivers/media/platform/omap3isp/ispvideo.c | 1 -
> 2 files changed, 3 deletions(-)
>
> diff --git a/drivers/media/platform/omap3isp/isp.c b/drivers/media/platform/omap3isp/isp.c
> index a4ee6b86663e..b91e472ee764 100644
> --- a/drivers/media/platform/omap3isp/isp.c
> +++ b/drivers/media/platform/omap3isp/isp.c
> @@ -39,8 +39,6 @@
> * Troy Laramy <[email protected]>
> */
>
> -#include <asm/cacheflush.h>
> -
> #include <linux/clk.h>
> #include <linux/clkdev.h>
> #include <linux/delay.h>
> diff --git a/drivers/media/platform/omap3isp/ispvideo.c b/drivers/media/platform/omap3isp/ispvideo.c
> index 10c214bd0903..1ac9aef70dff 100644
> --- a/drivers/media/platform/omap3isp/ispvideo.c
> +++ b/drivers/media/platform/omap3isp/ispvideo.c
> @@ -18,7 +18,6 @@
> #include <linux/sched.h>
> #include <linux/slab.h>
> #include <linux/vmalloc.h>
> -#include <asm/cacheflush.h>
>
> #include <media/v4l2-dev.h>
> #include <media/v4l2-ioctl.h>
>
> base-commit: 27f11fea33608cbd321a97cbecfa2ef97dcc1821

--
Regards,

Laurent Pinchart

2020-06-23 06:18:55

by Christoph Hellwig

[permalink] [raw]
Subject: Re: [PATCH 1/2] media: omap3isp: Remove cacheflush.h

Looks good,

Reviewed-by: Christoph Hellwig <[email protected]>

2020-06-23 06:24:40

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: Re: [PATCH 1/2] media: omap3isp: Remove cacheflush.h

Em Mon, 22 Jun 2020 16:47:39 -0700
Nathan Chancellor <[email protected]> escreveu:

> After mm.h was removed from the asm-generic version of cacheflush.h,
> s390 allyesconfig shows several warnings of the following nature:
>
> In file included from ./arch/s390/include/generated/asm/cacheflush.h:1,
> from drivers/media/platform/omap3isp/isp.c:42:
> ./include/asm-generic/cacheflush.h:16:42: warning: 'struct mm_struct'
> declared inside parameter list will not be visible outside of this
> definition or declaration
>
> As Geert and Laurent point out, this driver does not need this header in
> the two files that include it. Remove it so there are no warnings.
>
> Fixes: e0cf615d725c ("asm-generic: don't include <linux/mm.h> in cacheflush.h")
> Suggested-by: Geert Uytterhoeven <[email protected]>
> Suggested-by: Laurent Pinchart <[email protected]>
> Signed-off-by: Nathan Chancellor <[email protected]>

Reviewed-by: Mauro Carvalho Chehab <[email protected]>

> ---
> drivers/media/platform/omap3isp/isp.c | 2 --
> drivers/media/platform/omap3isp/ispvideo.c | 1 -
> 2 files changed, 3 deletions(-)
>
> diff --git a/drivers/media/platform/omap3isp/isp.c b/drivers/media/platform/omap3isp/isp.c
> index a4ee6b86663e..b91e472ee764 100644
> --- a/drivers/media/platform/omap3isp/isp.c
> +++ b/drivers/media/platform/omap3isp/isp.c
> @@ -39,8 +39,6 @@
> * Troy Laramy <[email protected]>
> */
>
> -#include <asm/cacheflush.h>
> -
> #include <linux/clk.h>
> #include <linux/clkdev.h>
> #include <linux/delay.h>
> diff --git a/drivers/media/platform/omap3isp/ispvideo.c b/drivers/media/platform/omap3isp/ispvideo.c
> index 10c214bd0903..1ac9aef70dff 100644
> --- a/drivers/media/platform/omap3isp/ispvideo.c
> +++ b/drivers/media/platform/omap3isp/ispvideo.c
> @@ -18,7 +18,6 @@
> #include <linux/sched.h>
> #include <linux/slab.h>
> #include <linux/vmalloc.h>
> -#include <asm/cacheflush.h>
>
> #include <media/v4l2-dev.h>
> #include <media/v4l2-ioctl.h>
>
> base-commit: 27f11fea33608cbd321a97cbecfa2ef97dcc1821



Thanks,
Mauro