[PATCH v4 0/4] DRM: allow to use mmuless devices

Benjamin Gaignard benjamin.gaignard at linaro.org
Wed Dec 7 10:06:47 UTC 2016


version 4:
- add documentation about drm_gem_cma_get_unmapped_area()
- introduce FB_PROVIDE_GET_FB_UNMAPPED_AREA configuration flag for get_fb_unmapped_area()
- I have also send the first patch (https://lkml.org/lkml/2016/12/1/308) to make dma_mmap_wc
  works on ARM noMMU platform, assuming that is patch will be accepted there is no more
  needs to call vm_ioremap in cma helpers.

version 3:
- split the original patch in 3 parts, it should be more easy to review like
  this.
- duplicate drm_fb_cma_helper.c and drm_gem_cma_helper.c into nommu version
- add a configuration flag for drm_vm.c 

The purpose of this RFC is to understand what is needed to allow to
write drm/kms drivers for devices without MMU.

There are some MCU platforms, like stm32f4, which don't have MMU
but have hardware display IP where is it possible to implement a
drm/kms driver.

Obviously that start by removing MMU configuration flag from Kconfig.
But while coding the driver for stm32f4 (on discovery board to have enough memory)
we have already identify few other pieces of code that need to be change.
We have been inspired by what already exist in v4l2 where using mmuless devices
is possible.

Since we have only use cma helpers we only have partial view of what could be
needed for other part of drm/kms framework.

Benjamin Gaignard (4):
  nommu: allow mmap when !CONFIG_MMU
  fbmem: add a default get_fb_unmapped_area function
  drm: compile drm_vm.c only when needed
  drm: allow to use mmuless SoC

 Documentation/gpu/drm-mm.rst         | 11 ++++++
 arch/arm/mm/dma-mapping.c            |  3 ++
 drivers/gpu/drm/Kconfig              |  9 +++--
 drivers/gpu/drm/Makefile             |  3 +-
 drivers/gpu/drm/drm_gem_cma_helper.c | 69 ++++++++++++++++++++++++++++++++++++
 drivers/gpu/drm/drm_legacy.h         |  7 ++++
 drivers/gpu/drm/nouveau/Kconfig      |  1 +
 drivers/video/fbdev/Kconfig          |  8 +++++
 drivers/video/fbdev/core/fbmem.c     | 15 ++++++++
 include/drm/drm_gem_cma_helper.h     | 17 +++++++++
 10 files changed, 140 insertions(+), 3 deletions(-)

-- 
1.9.1



More information about the dri-devel mailing list