From 7e1d63f64568e625be73e4f52fb6f0e41c890596 Mon Sep 17 00:00:00 2001 From: Alex Deryskyba Date: Sun, 24 Jul 2016 16:27:59 +0200 Subject: [PATCH] packages/linux-drivers/gpu-aml: Add a package that provides Linux drivers for Mali GPUs found in Amlogic SOCs --- .../gpu-aml/modules-load.d/mali.conf | 1 + packages/linux-drivers/gpu-aml/package.mk | 48 +++++++++++++++++++ 2 files changed, 49 insertions(+) create mode 100644 packages/linux-drivers/gpu-aml/modules-load.d/mali.conf create mode 100644 packages/linux-drivers/gpu-aml/package.mk diff --git a/packages/linux-drivers/gpu-aml/modules-load.d/mali.conf b/packages/linux-drivers/gpu-aml/modules-load.d/mali.conf new file mode 100644 index 0000000000..29c66fc8c8 --- /dev/null +++ b/packages/linux-drivers/gpu-aml/modules-load.d/mali.conf @@ -0,0 +1 @@ +mali diff --git a/packages/linux-drivers/gpu-aml/package.mk b/packages/linux-drivers/gpu-aml/package.mk new file mode 100644 index 0000000000..da12b3096d --- /dev/null +++ b/packages/linux-drivers/gpu-aml/package.mk @@ -0,0 +1,48 @@ +################################################################################ +# This file is part of LibreELEC - https://LibreELEC.tv +# Copyright (C) 2016 Team LibreELEC +# +# LibreELEC is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 2 of the License, or +# (at your option) any later version. +# +# LibreELEC is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with LibreELEC. If not, see . +################################################################################ + +PKG_NAME="gpu-aml" +PKG_REV="1" +PKG_ARCH="arm aarch64" +PKG_LICENSE="GPL" +PKG_SITE="http://openlinux.amlogic.com:8000/download/ARM/gpu/" +PKG_VERSION="r6p1-01rel0-2364187" +PKG_URL="$DISTRO_SRC/$PKG_NAME-$PKG_VERSION.tar.xz" +PKG_DEPENDS_TARGET="toolchain linux" +PKG_NEED_UNPACK="$LINUX_DEPENDS" +PKG_PRIORITY="optional" +PKG_SECTION="driver" +PKG_SHORTDESC="gpu-aml: Linux drivers for Mali GPUs found in Amlogic Meson SoCs" +PKG_LONGDESC="gpu-aml: Linux drivers for Mali GPUs found in Amlogic Meson SoCs" + +PKG_IS_ADDON="no" +PKG_AUTORECONF="no" + +make_target() { + cd mali + LDFLAGS="" make V=1 \ + -C $(kernel_path) M=$ROOT/$PKG_BUILD/mali \ + ARCH=$TARGET_KERNEL_ARCH \ + CROSS_COMPILE=$TARGET_PREFIX \ + CONFIG_MALI400=m CONFIG_MALI450=m +} + +makeinstall_target() { + mkdir -p $INSTALL/lib/modules/$(get_module_dir)/mali + cp *.ko $INSTALL/lib/modules/$(get_module_dir)/mali +}