vcsm: VideoCore shared memory service for BCM2835
authorTim Gover <tgover@broadcom.com>
Tue, 22 Jul 2014 14:41:04 +0000 (15:41 +0100)
committerRaspbian kernel package updater <root@raspbian.org>
Sat, 31 Mar 2018 14:44:53 +0000 (15:44 +0100)
commit6139561649e079e75433a4aed55438bc2465eda1
treef898c61813fef4e512e31627d2abcd234e14951b
parent18f780a16ced47402be40e9a3f229c627e271f6e
vcsm: VideoCore shared memory service for BCM2835

Add experimental support for the VideoCore shared memory service.
This allows user processes to allocate memory from VideoCore's
GPU relocatable heap and mmap the buffers. Additionally, the memory
handles can passed to other VideoCore services such as MMAL, OpenMax
and DispmanX

TODO
* This driver was originally released for BCM28155 which has a different
  cache architecture to BCM2835. Consequently, in this release only
  uncached mappings are supported. However, there's no fundamental
  reason which cached mappings cannot be support or BCM2835
* More refactoring is required to remove the typedefs.
* Re-enable the some of the commented out debug-fs statistics which were
  disabled when migrating code from proc-fs.
* There's a lot of code to support sharing of VCSM in order to support
  Android. This could probably done more cleanly or perhaps just
  removed.

Signed-off-by: Tim Gover <timgover@gmail.com>
config: Disable VC_SM for now to fix hang with cutdown kernel

vcsm: Use boolean as it cannot be built as module

On building the bcm_vc_sm as a module we get the following error:

v7_dma_flush_range and do_munmap are undefined in vc-sm.ko.

Fix by making it not an option to build as module

vcsm: Add ioctl for custom cache flushing

vc-sm: Move headers out of arch directory

Signed-off-by: Noralf Trønnes <noralf@tronnes.org>
drivers/char/broadcom/Kconfig
drivers/char/broadcom/Makefile
drivers/char/broadcom/vc_sm/Makefile [new file with mode: 0644]
drivers/char/broadcom/vc_sm/vc_sm_defs.h [new file with mode: 0644]
drivers/char/broadcom/vc_sm/vc_sm_knl.h [new file with mode: 0644]
drivers/char/broadcom/vc_sm/vc_vchi_sm.c [new file with mode: 0644]
drivers/char/broadcom/vc_sm/vc_vchi_sm.h [new file with mode: 0644]
drivers/char/broadcom/vc_sm/vmcs_sm.c [new file with mode: 0644]
include/linux/broadcom/vmcs_sm_ioctl.h [new file with mode: 0644]