Skip to contentSkip to conversation

drm/lima: fix build on MMU-less platform

PATCH In review Qiang Yu 2 participants 4 messages Apr 8, 2019

Subsystems (3)
lore
Share & tools
lore

Qiang Yu

author maintainer
#0 lore raw

PATCH 1/1 drm/lima: fix build on MMU-less platform

Feedback from kbuild robot:
config: sh-allyesconfig (attached as .config)
compiler: sh4-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0 lima_gem.c:(.text+0x6c): undefined reference to `vmf_insert_mixed'

Cc Randy Dunlap <[email protected]>
---
 drivers/gpu/drm/lima/Kconfig    | 2 ++
 drivers/gpu/drm/lima/lima_gem.c | 1 +
 2 files changed, 3 insertions(+)
drivers/gpu/drm/lima/Kconfig +2 -0
index f11314448093..fed2b0863287 100644
@@ -5,6 +5,8 @@ config DRM_LIMA
        tristate "LIMA (DRM support for ARM Mali 400/450 GPU)"
        depends on DRM
        depends on ARM || ARM64 || COMPILE_TEST
+       depends on MMU
+       depends on COMMON_CLK
        select DRM_SCHED
        help
          DRM driver for ARM Mali 400/450 GPUs.
drivers/gpu/drm/lima/lima_gem.c +1 -0
index 2d3cf96f6c58..1d69498bc17e 100644
@@ -1,6 +1,7 @@
 // SPDX-License-Identifier: GPL-2.0 OR MIT
 /* Copyright 2017-2019 Qiang Yu <[email protected]> */
 
+#include <linux/mm.h>
 #include <linux/sync_file.h>
 #include <linux/pfn_t.h>
 
Signature · 6 lines
2.17.1

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#1 lore raw

Hi,

Quoted 7 lines · Qiang Yu

Feedback from kbuild robot:
config: sh-allyesconfig (attached as .config)
compiler: sh4-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0 lima_gem.c:(.text+0x6c): undefined reference to `vmf_insert_mixed'

Cc Randy Dunlap <[email protected]>

You'll need a Fixes tag here, even if on the same release

Quoted 23 lines
---
 drivers/gpu/drm/lima/Kconfig    | 2 ++
 drivers/gpu/drm/lima/lima_gem.c | 1 +
 2 files changed, 3 insertions(+)
drivers/gpu/drm/lima/Kconfig +2 -0
index f11314448093..fed2b0863287 100644
@@ -5,6 +5,8 @@ config DRM_LIMA
        tristate "LIMA (DRM support for ARM Mali 400/450 GPU)"
        depends on DRM
        depends on ARM || ARM64 || COMPILE_TEST
+       depends on MMU
+       depends on COMMON_CLK
        select DRM_SCHED
        help
          DRM driver for ARM Mali 400/450 GPUs.
drivers/gpu/drm/lima/lima_gem.c +0 -0
index 2d3cf96f6c58..1d69498bc17e 100644

drivers/gpu/drm/lima/lima_gem.c line 4

Quoted 4 lines
drivers/gpu/drm/lima/lima_gem.c +1 -0
@@ -1,6 +1,7 @@
 // SPDX-License-Identifier: GPL-2.0 OR MIT
 /* Copyright 2017-2019 Qiang Yu <[email protected]> */
 
+#include <linux/mm.h>

I would have fixed this on a second patch

drivers/gpu/drm/lima/lima_gem.c line 7

Quoted 4 lines
drivers/gpu/drm/lima/lima_gem.c +0 -0
 #include <linux/sync_file.h>
 #include <linux/pfn_t.h>
 

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

author maintainer
#2 lore raw
Quoted 9 lines · Neil Armstrong

Hi,

Quoted 5 lines · Qiang Yu

Feedback from kbuild robot:
config: sh-allyesconfig (attached as .config)
compiler: sh4-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0 lima_gem.c:(.text+0x6c): undefined reference to `vmf_insert_mixed'

Quoted 5 lines
Quoted 2 lines
Cc Randy Dunlap <[email protected]>

You'll need a Fixes tag here, even if on the same release

So like this?

Fixes a1d2a6339961 ("drm/lima: driver for ARM Mali4xx GPUs")
Quoted 26 lines
Quoted 26 lines
---
 drivers/gpu/drm/lima/Kconfig    | 2 ++
 drivers/gpu/drm/lima/lima_gem.c | 1 +
 2 files changed, 3 insertions(+)
drivers/gpu/drm/lima/Kconfig +2 -0
index f11314448093..fed2b0863287 100644
@@ -5,6 +5,8 @@ config DRM_LIMA
        tristate "LIMA (DRM support for ARM Mali 400/450 GPU)"
        depends on DRM
        depends on ARM || ARM64 || COMPILE_TEST
+       depends on MMU
+       depends on COMMON_CLK
        select DRM_SCHED
        help
          DRM driver for ARM Mali 400/450 GPUs.
drivers/gpu/drm/lima/lima_gem.c +0 -0
index 2d3cf96f6c58..1d69498bc17e 100644
@@ -1,6 +1,7 @@
 // SPDX-License-Identifier: GPL-2.0 OR MIT
 /* Copyright 2017-2019 Qiang Yu <[email protected]> */
 
Quoted 3 lines

drivers/gpu/drm/lima/lima_gem.c line 4

Quoted 1 line
drivers/gpu/drm/lima/lima_gem.c +1 -0
+#include <linux/mm.h>

I would have fixed this on a second patch

This is suggested by Randy, I expect it's also part of the fix for build fail when MMU-less platform, MMU platform is OK. Should I still separate it?

Thanks,
Qiang

Quoted 5 lines

drivers/gpu/drm/lima/lima_gem.c line 7

Quoted 5 lines
drivers/gpu/drm/lima/lima_gem.c +0 -0
 #include <linux/sync_file.h>
 #include <linux/pfn_t.h>
 

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#3 lore raw
Quoted 10 lines · Qiang Yu
Quoted 9 lines · Neil Armstrong

Hi,

Quoted 5 lines · Qiang Yu

Feedback from kbuild robot:
config: sh-allyesconfig (attached as .config)
compiler: sh4-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0 lima_gem.c:(.text+0x6c): undefined reference to `vmf_insert_mixed'

Quoted 7 lines
Quoted 5 lines
Quoted 2 lines
Cc Randy Dunlap <[email protected]>

You'll need a Fixes tag here, even if on the same release

So like this?

Fixes a1d2a6339961 ("drm/lima: driver for ARM Mali4xx GPUs")

Yes

Quoted 27 lines
Quoted 27 lines
Quoted 27 lines
---
 drivers/gpu/drm/lima/Kconfig    | 2 ++
 drivers/gpu/drm/lima/lima_gem.c | 1 +
 2 files changed, 3 insertions(+)
drivers/gpu/drm/lima/Kconfig +2 -0
index f11314448093..fed2b0863287 100644
@@ -5,6 +5,8 @@ config DRM_LIMA
        tristate "LIMA (DRM support for ARM Mali 400/450 GPU)"
        depends on DRM
        depends on ARM || ARM64 || COMPILE_TEST
+       depends on MMU
+       depends on COMMON_CLK
        select DRM_SCHED
        help
          DRM driver for ARM Mali 400/450 GPUs.
drivers/gpu/drm/lima/lima_gem.c +0 -0
index 2d3cf96f6c58..1d69498bc17e 100644
@@ -1,6 +1,7 @@
 // SPDX-License-Identifier: GPL-2.0 OR MIT
 /* Copyright 2017-2019 Qiang Yu <[email protected]> */
 
Quoted 6 lines
Quoted 3 lines

drivers/gpu/drm/lima/lima_gem.c line 4

Quoted 1 line
drivers/gpu/drm/lima/lima_gem.c +1 -0
+#include <linux/mm.h>

I would have fixed this on a second patch

This is suggested by Randy, I expect it's also part of the fix for build fail when MMU-less platform, MMU platform is OK. Should I still separate it?

Yes but one fixes the Kconfig and another fixes the code, TBH it's fine for me, maybe daniel or someone else can give a feedback about this.

Quoted 9 lines

Thanks,
Qiang

Quoted 5 lines
Quoted 5 lines
drivers/gpu/drm/lima/lima_gem.c +0 -0
 #include <linux/sync_file.h>
 #include <linux/pfn_t.h>
 

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel