[PATCH weston] Remove Raspberry Pi backend and renderer

Pekka Paalanen ppaalanen at gmail.com
Wed Jun 1 10:11:15 UTC 2016


From: Pekka Paalanen <pekka.paalanen at collabora.co.uk>

This patch completely removes the Raspberry Pi backend and the renderer.

The backend and the renderer were written to use the proprietary
DispmanX API available only on the Raspberry Pi, to demonstrate what the
tiny computer is capable of graphics wise. They were also used to
demonstrate how Wayland and Weston in particular could leverage hardware
compositing capabilities that are not OpenGL. The backend was first
added in e8de35c922871bc5b15fbf0436efa233a6db8e41, in 2012.

Since then, the major point has been proven. Over time, support for the
rpi-backend diminished, it started to deteriorate and hinder Weston
development. On May 11, I tried to ask if anyone actually cared about
the rpi-backend, but did not get any votes for keeping it:
https://lists.freedesktop.org/archives/wayland-devel/2016-May/028764.html

The rpi-backend is a good example of how using an API that is only
available for specific hardware, even more so as it is only available
with a proprietary driver stack, is not maintainable in the long run.
Most developers working on Weston either just cannot, or cannot bother
to test things also on the RPi. Breakage creeps in without anyone
noticing. If someone actually notices it, fixing it will require a very
specific environment to be able to test. Also the quality of the
proprietary implementation fluctuated. There are reports that RPi
firmware updates randomly broke Weston, and that nowadays it is very
hard to find a RPi firmware version that you could expect to work with
Weston if Weston itself was not broken. We are not even sure what is
broken nowadays.

This removal does not leave Raspberry Pi users cold (for long), though.
There is serious work going on in implementing a FOSS driver stack for
Raspberry Pi, including modern kernel DRM drivers and Mesa drivers. It
might not be fully there yet, but the plan is to be able to use the
standard DRM-backend of Weston on the RPis. See:
http://dri.freedesktop.org/wiki/VC4/

The rpi-backend had its moments. Now, it needs to go. Good riddance!

Signed-off-by: Pekka Paalanen <pekka.paalanen at collabora.co.uk>
---
 Makefile.am          |   34 -
 README               |    2 -
 configure.ac         |   18 -
 man/weston.ini.man   |    1 -
 src/compositor-rpi.c |  575 ----------------
 src/main.c           |   19 -
 src/rpi-bcm-stubs.h  |  327 ---------
 src/rpi-renderer.c   | 1830 --------------------------------------------------
 src/rpi-renderer.h   |   52 --
 9 files changed, 2858 deletions(-)
 delete mode 100644 src/compositor-rpi.c
 delete mode 100644 src/rpi-bcm-stubs.h
 delete mode 100644 src/rpi-renderer.c
 delete mode 100644 src/rpi-renderer.h

diff --git a/Makefile.am b/Makefile.am
index 00b74e5..8ee9c8d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -328,40 +328,6 @@ nodist_wayland_backend_la_SOURCES =			\
 	protocol/fullscreen-shell-unstable-v1-client-protocol.h
 endif
 
-if ENABLE_RPI_COMPOSITOR
-if INSTALL_RPI_COMPOSITOR
-module_LTLIBRARIES += rpi-backend.la
-else
-noinst_LTLIBRARIES += rpi-backend.la
-endif
-
-rpi_backend_la_LDFLAGS = -module -avoid-version
-rpi_backend_la_LIBADD = $(COMPOSITOR_LIBS)	\
-	$(RPI_COMPOSITOR_LIBS)			\
-	$(RPI_BCM_HOST_LIBS)			\
-	$(INPUT_BACKEND_LIBS)			\
-	libsession-helper.la			\
-	libshared.la
-rpi_backend_la_CFLAGS =				\
-	$(AM_CFLAGS)				\
-	$(COMPOSITOR_CFLAGS)			\
-	$(RPI_COMPOSITOR_CFLAGS)		\
-	$(RPI_BCM_HOST_CFLAGS)
-rpi_backend_la_SOURCES =			\
-	src/compositor-rpi.c			\
-	src/rpi-renderer.c			\
-	src/rpi-renderer.h			\
-	src/rpi-bcm-stubs.h			\
-	shared/helpers.h			\
-	$(INPUT_BACKEND_SOURCES)
-
-if ENABLE_EGL
-rpi_backend_la_LIBADD += $(EGL_LIBS)
-rpi_backend_la_CFLAGS += $(EGL_CFLAGS)
-endif
-
-endif
-
 if ENABLE_HEADLESS_COMPOSITOR
 module_LTLIBRARIES += headless-backend.la
 headless_backend_la_LDFLAGS = -module -avoid-version
diff --git a/README b/README
index 3fdfb37..110a14b 100644
--- a/README
+++ b/README
@@ -138,8 +138,6 @@ would be roughly like this:
 
 - xwayland (depends on X11/xcb libs)
 
-- rpi-backend (depends on DispmanX, libudev, ...)
-
 - fbdev-backend (depends on libudev...)
 
 - rdp-backend (depends on freerdp)
diff --git a/configure.ac b/configure.ac
index 87e67fe..525810f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -208,23 +208,6 @@ if test x$enable_headless_compositor = xyes; then
 fi
 
 
-AC_ARG_ENABLE(rpi-compositor,
-	      AS_HELP_STRING([--disable-rpi-compositor],
-	                     [do not build the Raspberry Pi backend]),,
-	      enable_rpi_compositor=yes)
-AM_CONDITIONAL(ENABLE_RPI_COMPOSITOR, test "x$enable_rpi_compositor" = "xyes")
-have_bcm_host="no"
-if test "x$enable_rpi_compositor" = "xyes"; then
-  AC_DEFINE([BUILD_RPI_COMPOSITOR], [1], [Build the compositor for Raspberry Pi])
-  PKG_CHECK_MODULES(RPI_COMPOSITOR, [libudev >= 136 mtdev >= 1.1.0])
-  PKG_CHECK_MODULES(RPI_BCM_HOST, [bcm_host],
-                    [have_bcm_host="yes"
-                     AC_DEFINE([HAVE_BCM_HOST], [1], [have Raspberry Pi BCM headers])],
-                    [AC_MSG_WARN([Raspberry Pi BCM host libraries not found, will use stubs instead.])])
-fi
-AM_CONDITIONAL(INSTALL_RPI_COMPOSITOR, test "x$have_bcm_host" = "xyes")
-
-
 AC_ARG_ENABLE([fbdev-compositor], [  --enable-fbdev-compositor],,
               enable_fbdev_compositor=yes)
 AM_CONDITIONAL([ENABLE_FBDEV_COMPOSITOR],
@@ -678,7 +661,6 @@ AC_MSG_RESULT([
 	X11 Compositor			${enable_x11_compositor}
 	Wayland Compositor		${enable_wayland_compositor}
 	Headless Compositor		${enable_headless_compositor}
-	RPI Compositor			${enable_rpi_compositor}
 	FBDEV Compositor		${enable_fbdev_compositor}
 	RDP Compositor			${enable_rdp_compositor}
 	Screen Sharing			${enable_screen_sharing}
diff --git a/man/weston.ini.man b/man/weston.ini.man
index d7c4a6f..7aa7810 100644
--- a/man/weston.ini.man
+++ b/man/weston.ini.man
@@ -130,7 +130,6 @@ directory are:
 .BR fbdev-backend.so
 .BR headless-backend.so
 .BR rdp-backend.so
-.BR rpi-backend.so
 .BR wayland-backend.so
 .BR x11-backend.so
 .fi
diff --git a/src/compositor-rpi.c b/src/compositor-rpi.c
deleted file mode 100644
index 75b808e..0000000
diff --git a/src/main.c b/src/main.c
index 3279ac6..475c1d0 100644
--- a/src/main.c
+++ b/src/main.c
@@ -252,9 +252,6 @@ usage(int error_code)
 #if defined(BUILD_RDP_COMPOSITOR)
 			"\t\t\t\trdp-backend.so\n"
 #endif
-#if defined(BUILD_RPI_COMPOSITOR) && defined(HAVE_BCM_HOST)
-			"\t\t\t\trpi-backend.so\n"
-#endif
 #if defined(BUILD_WAYLAND_COMPOSITOR)
 			"\t\t\t\twayland-backend.so\n"
 #endif
@@ -313,18 +310,6 @@ usage(int error_code)
 		"\n");
 #endif
 
-#if defined(BUILD_RPI_COMPOSITOR) && defined(HAVE_BCM_HOST)
-	fprintf(stderr,
-		"Options for rpi-backend.so:\n\n"
-		"  --tty=TTY\t\tThe tty to use\n"
-		"  --single-buffer\tUse single-buffered Dispmanx elements.\n"
-		"  --transform=TR\tThe output transformation, TR is one of:\n"
-		"\tnormal 90 180 270 flipped flipped-90 flipped-180 flipped-270\n"
-		"  --opaque-regions\tEnable support for opaque regions, can be "
-		"very slow without support in the GPU firmware.\n"
-		"\n");
-#endif
-
 #if defined(BUILD_WAYLAND_COMPOSITOR)
 	fprintf(stderr,
 		"Options for wayland-backend.so:\n\n"
@@ -1264,10 +1249,6 @@ load_backend(struct weston_compositor *compositor, const char *backend,
 		return load_x11_backend(compositor, backend, argc, argv, config);
 	else if (strstr(backend, "wayland-backend.so"))
 		return load_wayland_backend(compositor, backend, argc, argv, config);
-#if 0
-	else if (strstr(backend, "rpi-backend.so"))
-		return load_rpi_backend(compositor, backend, argc, argv, config);
-#endif
 
 	return load_backend_old(compositor, backend, argc, argv, config);
 }
diff --git a/src/rpi-bcm-stubs.h b/src/rpi-bcm-stubs.h
deleted file mode 100644
index fa30570..0000000
diff --git a/src/rpi-renderer.c b/src/rpi-renderer.c
deleted file mode 100644
index 33eb67c..0000000
diff --git a/src/rpi-renderer.h b/src/rpi-renderer.h
deleted file mode 100644
index 6370682..0000000
-- 
2.7.3



More information about the wayland-devel mailing list