From 013ef3fb62136aab4cb7c997011998894ae04772 Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Tue, 15 Jan 2019 19:50:06 +0100 Subject: [PATCH 1/7] libcec: update cec-framework patch --- .../cec-framework/libcec-0001-PR380.patch | 123 ++++++++++++++---- 1 file changed, 97 insertions(+), 26 deletions(-) diff --git a/packages/devel/libcec/patches/cec-framework/libcec-0001-PR380.patch b/packages/devel/libcec/patches/cec-framework/libcec-0001-PR380.patch index 98565abc0e1..49af7eadf31 100644 --- a/packages/devel/libcec/patches/cec-framework/libcec-0001-PR380.patch +++ b/packages/devel/libcec/patches/cec-framework/libcec-0001-PR380.patch @@ -1,4 +1,4 @@ -From 48255b7d4e1cba1050b8abfbd03be37c0737e832 Mon Sep 17 00:00:00 2001 +From 467cc79fd289403e7d4f6e4e817b906c0c0027dd Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Wed, 6 Sep 2017 17:37:05 +0200 Subject: [PATCH] Add Linux CEC Adapter @@ -9,21 +9,21 @@ Subject: [PATCH] Add Linux CEC Adapter src/libcec/CECTypeUtils.h | 2 + src/libcec/CMakeLists.txt | 2 + src/libcec/adapter/AdapterFactory.cpp | 26 +- - .../Linux/LinuxCECAdapterCommunication.cpp | 367 ++++++++++++++++++ - .../Linux/LinuxCECAdapterCommunication.h | 95 +++++ - .../Linux/LinuxCECAdapterDetection.cpp | 50 +++ - .../adapter/Linux/LinuxCECAdapterDetection.h | 51 +++ + .../Linux/LinuxCECAdapterCommunication.cpp | 438 ++++++++++++++++++ + .../Linux/LinuxCECAdapterCommunication.h | 95 ++++ + .../Linux/LinuxCECAdapterDetection.cpp | 50 ++ + .../adapter/Linux/LinuxCECAdapterDetection.h | 51 ++ src/libcec/cmake/CheckPlatformSupport.cmake | 12 + src/libcec/cmake/DisplayPlatformSupport.cmake | 6 + src/libcec/env.h.in | 3 + - 12 files changed, 629 insertions(+), 2 deletions(-) + 12 files changed, 700 insertions(+), 2 deletions(-) create mode 100644 src/libcec/adapter/Linux/LinuxCECAdapterCommunication.cpp create mode 100644 src/libcec/adapter/Linux/LinuxCECAdapterCommunication.h create mode 100644 src/libcec/adapter/Linux/LinuxCECAdapterDetection.cpp create mode 100644 src/libcec/adapter/Linux/LinuxCECAdapterDetection.h diff --git a/docs/README.linux.md b/docs/README.linux.md -index c59fb806..e8053cca 100644 +index c59fb80..e8053cc 100644 --- a/docs/README.linux.md +++ b/docs/README.linux.md @@ -51,5 +51,11 @@ Pass the argument `-DHAVE_TDA995X_API=1` to the cmake command in the compilation @@ -40,7 +40,7 @@ index c59fb806..e8053cca 100644 See [docs/README.debian.md](README.debian.md). \ No newline at end of file diff --git a/include/cectypes.h b/include/cectypes.h -index 9c918427..2c32e4d9 100644 +index 9c91842..2c32e4d 100644 --- a/include/cectypes.h +++ b/include/cectypes.h @@ -281,6 +281,16 @@ namespace CEC { @@ -69,7 +69,7 @@ index 9c918427..2c32e4d9 100644 } cec_adapter_type; diff --git a/src/libcec/CECTypeUtils.h b/src/libcec/CECTypeUtils.h -index 25c1c6e3..15f9543f 100644 +index 25c1c6e..15f9543 100644 --- a/src/libcec/CECTypeUtils.h +++ b/src/libcec/CECTypeUtils.h @@ -766,6 +766,8 @@ namespace CEC @@ -82,7 +82,7 @@ index 25c1c6e3..15f9543f 100644 return "unknown"; } diff --git a/src/libcec/CMakeLists.txt b/src/libcec/CMakeLists.txt -index 6baee69e..74fe5f37 100644 +index 6baee69..74fe5f3 100644 --- a/src/libcec/CMakeLists.txt +++ b/src/libcec/CMakeLists.txt @@ -89,6 +89,8 @@ set(CEC_HEADERS devices/CECRecordingDevice.h @@ -95,7 +95,7 @@ index 6baee69e..74fe5f37 100644 adapter/AOCEC/AOCECAdapterDetection.h adapter/AOCEC/AOCECAdapterCommunication.h diff --git a/src/libcec/adapter/AdapterFactory.cpp b/src/libcec/adapter/AdapterFactory.cpp -index 91195ea0..323c2724 100644 +index 91195ea..323c272 100644 --- a/src/libcec/adapter/AdapterFactory.cpp +++ b/src/libcec/adapter/AdapterFactory.cpp @@ -58,6 +58,11 @@ @@ -161,14 +161,14 @@ index 91195ea0..323c2724 100644 } diff --git a/src/libcec/adapter/Linux/LinuxCECAdapterCommunication.cpp b/src/libcec/adapter/Linux/LinuxCECAdapterCommunication.cpp new file mode 100644 -index 00000000..878c572f +index 0000000..6a28835 --- /dev/null +++ b/src/libcec/adapter/Linux/LinuxCECAdapterCommunication.cpp -@@ -0,0 +1,367 @@ +@@ -0,0 +1,438 @@ +/* + * This file is part of the libCEC(R) library. + * -+ * libCEC Linux CEC Adapter is Copyright (C) 2017-2018 Jonas Karlman ++ * libCEC Linux CEC Adapter is Copyright (C) 2017-2019 Jonas Karlman + * based heavily on: + * libCEC AOCEC Code is Copyright (C) 2016 Gerald Dachs + * libCEC Exynos Code is Copyright (C) 2014 Valentin Manea @@ -264,6 +264,19 @@ index 00000000..878c572f + return false; + } + ++ uint16_t addr; ++ if (ioctl(m_fd, CEC_ADAP_G_PHYS_ADDR, &addr)) ++ { ++ LIB_CEC->AddLog(CEC_LOG_ERROR, "CLinuxCECAdapterCommunication::Open - ioctl CEC_ADAP_G_PHYS_ADDR failed - errno=%d", errno); ++ Close(); ++ return false; ++ } ++ ++ LIB_CEC->AddLog(CEC_LOG_DEBUG, "CLinuxCECAdapterCommunication::Open - ioctl CEC_ADAP_G_PHYS_ADDR - addr=%04x", addr); ++ ++ if (addr == CEC_PHYS_ADDR_INVALID) ++ LIB_CEC->AddLog(CEC_LOG_WARNING, "CLinuxCECAdapterCommunication::Open - physical address is invalid"); ++ + // Clear existing logical addresses and set the CEC device to the unconfigured state + struct cec_log_addrs log_addrs = {}; + if (ioctl(m_fd, CEC_ADAP_S_LOG_ADDRS, &log_addrs)) @@ -273,6 +286,27 @@ index 00000000..878c572f + return false; + } + ++ LIB_CEC->AddLog(CEC_LOG_DEBUG, "CLinuxCECAdapterCommunication::Open - ioctl CEC_ADAP_S_LOG_ADDRS - log_addr_mask=%04x num_log_addrs=%u", log_addrs.log_addr_mask, log_addrs.num_log_addrs); ++ ++ // Set logical address to unregistered, without any logical address configured no messages is transmitted or received ++ log_addrs = {}; ++ log_addrs.cec_version = CEC_OP_CEC_VERSION_1_4; ++ log_addrs.vendor_id = CEC_VENDOR_PULSE_EIGHT; ++ log_addrs.num_log_addrs = 1; ++ log_addrs.flags = CEC_LOG_ADDRS_FL_ALLOW_UNREG_FALLBACK; ++ log_addrs.log_addr[0] = CEC_LOG_ADDR_UNREGISTERED; ++ log_addrs.primary_device_type[0] = CEC_OP_PRIM_DEVTYPE_SWITCH; ++ log_addrs.log_addr_type[0] = CEC_LOG_ADDR_TYPE_UNREGISTERED; ++ log_addrs.all_device_types[0] = CEC_OP_ALL_DEVTYPE_SWITCH; ++ if (ioctl(m_fd, CEC_ADAP_S_LOG_ADDRS, &log_addrs)) ++ { ++ LIB_CEC->AddLog(CEC_LOG_ERROR, "CLinuxCECAdapterCommunication::Open - ioctl CEC_ADAP_S_LOG_ADDRS failed - errno=%d", errno); ++ Close(); ++ return false; ++ } ++ ++ LIB_CEC->AddLog(CEC_LOG_DEBUG, "CLinuxCECAdapterCommunication::Open - ioctl CEC_ADAP_S_LOG_ADDRS - log_addr_mask=%04x num_log_addrs=%u", log_addrs.log_addr_mask, log_addrs.num_log_addrs); ++ + if (CreateThread()) + return true; + @@ -323,7 +357,7 @@ index 00000000..878c572f + + LIB_CEC->AddLog(CEC_LOG_DEBUG, "CLinuxCECAdapterCommunication::Write - ioctl CEC_TRANSMIT - tx_status=%02x len=%d addr=%02x opcode=%02x", msg.tx_status, msg.len, msg.msg[0], cec_msg_opcode(&msg)); + -+ // The CEC device will already make multiple transmit attempts ++ // The CEC driver will make re-transmission attempts + bRetry = false; + + if (msg.tx_status & CEC_TX_STATUS_OK) @@ -332,9 +366,6 @@ index 00000000..878c572f + if (msg.tx_status & CEC_TX_STATUS_NACK) + return ADAPTER_MESSAGE_STATE_SENT_NOT_ACKED; + -+ if (msg.tx_status & CEC_TX_STATUS_ERROR) -+ bRetry = true; -+ + return ADAPTER_MESSAGE_STATE_ERROR; + } + @@ -352,6 +383,21 @@ index 00000000..878c572f + return false; + } + ++ // TODO: Claiming a logical address will only work when CEC device has a valid physical address ++ ++ // Clear existing logical addresses and set the CEC device to the unconfigured state ++ if (log_addrs.num_log_addrs) ++ { ++ log_addrs = {}; ++ if (ioctl(m_fd, CEC_ADAP_S_LOG_ADDRS, &log_addrs)) ++ { ++ LIB_CEC->AddLog(CEC_LOG_ERROR, "CLinuxCECAdapterCommunication::SetLogicalAddresses - ioctl CEC_ADAP_S_LOG_ADDRS failed - errno=%d", errno); ++ return false; ++ } ++ ++ LIB_CEC->AddLog(CEC_LOG_DEBUG, "CLinuxCECAdapterCommunication::SetLogicalAddresses - ioctl CEC_ADAP_S_LOG_ADDRS - log_addr_mask=%04x num_log_addrs=%u", log_addrs.log_addr_mask, log_addrs.num_log_addrs); ++ } ++ + if (!addresses.IsEmpty()) + { + // NOTE: This can only be configured when num_log_addrs > 0 @@ -414,6 +460,10 @@ index 00000000..878c572f + } + + LIB_CEC->AddLog(CEC_LOG_DEBUG, "CLinuxCECAdapterCommunication::SetLogicalAddresses - ioctl CEC_ADAP_S_LOG_ADDRS - log_addr_mask=%04x num_log_addrs=%u", log_addrs.log_addr_mask, log_addrs.num_log_addrs); ++ ++ if (log_addrs.num_log_addrs && !log_addrs.log_addr_mask) ++ return false; ++ + return true; + } + @@ -471,6 +521,9 @@ index 00000000..878c572f + +void *CLinuxCECAdapterCommunication::Process(void) +{ ++ CTimeout phys_addr_timeout; ++ bool phys_addr_changed = false; ++ uint16_t phys_addr = CEC_INVALID_PHYSICAL_ADDRESS; + fd_set rd_fds; + fd_set ex_fds; + @@ -501,11 +554,29 @@ index 00000000..878c572f + + // TODO: handle ev.state_change.log_addr_mask change + -+ if (!IsStopped() && !(ev.flags & CEC_EVENT_FL_INITIAL_STATE)) -+ m_callback->HandlePhysicalAddressChanged(ev.state_change.phys_addr); ++ phys_addr = ev.state_change.phys_addr; ++ phys_addr_changed = true; ++ ++ if (ev.state_change.phys_addr == CEC_PHYS_ADDR_INVALID) ++ { ++ // Debounce change to invalid physical address with 2 seconds because ++ // EDID refresh and other events may cause short periods of invalid physical address ++ phys_addr_timeout.Init(2000); ++ } ++ else ++ { ++ // Debounce change to valid physical address with 500 ms when no logical address have been claimed ++ phys_addr_timeout.Init(ev.state_change.log_addr_mask ? 0 : 500); ++ } + } + } + ++ if (phys_addr_changed && !phys_addr_timeout.TimeLeft() && !IsStopped()) ++ { ++ phys_addr_changed = false; ++ m_callback->HandlePhysicalAddressChanged(phys_addr); ++ } ++ + if (FD_ISSET(m_fd, &rd_fds)) + { + struct cec_msg msg = {}; @@ -534,7 +605,7 @@ index 00000000..878c572f +#endif diff --git a/src/libcec/adapter/Linux/LinuxCECAdapterCommunication.h b/src/libcec/adapter/Linux/LinuxCECAdapterCommunication.h new file mode 100644 -index 00000000..f4fac87e +index 0000000..f4fac87 --- /dev/null +++ b/src/libcec/adapter/Linux/LinuxCECAdapterCommunication.h @@ -0,0 +1,95 @@ @@ -635,7 +706,7 @@ index 00000000..f4fac87e +#endif diff --git a/src/libcec/adapter/Linux/LinuxCECAdapterDetection.cpp b/src/libcec/adapter/Linux/LinuxCECAdapterDetection.cpp new file mode 100644 -index 00000000..7b72238f +index 0000000..7b72238 --- /dev/null +++ b/src/libcec/adapter/Linux/LinuxCECAdapterDetection.cpp @@ -0,0 +1,50 @@ @@ -691,7 +762,7 @@ index 00000000..7b72238f +#endif diff --git a/src/libcec/adapter/Linux/LinuxCECAdapterDetection.h b/src/libcec/adapter/Linux/LinuxCECAdapterDetection.h new file mode 100644 -index 00000000..f5ea2c47 +index 0000000..f5ea2c4 --- /dev/null +++ b/src/libcec/adapter/Linux/LinuxCECAdapterDetection.h @@ -0,0 +1,51 @@ @@ -747,7 +818,7 @@ index 00000000..f5ea2c47 + +#endif diff --git a/src/libcec/cmake/CheckPlatformSupport.cmake b/src/libcec/cmake/CheckPlatformSupport.cmake -index d9e1e41b..4c60b6db 100644 +index 2d7102f..dacca0f 100644 --- a/src/libcec/cmake/CheckPlatformSupport.cmake +++ b/src/libcec/cmake/CheckPlatformSupport.cmake @@ -9,6 +9,7 @@ @@ -784,7 +855,7 @@ index d9e1e41b..4c60b6db 100644 if (${HAVE_AOCEC_API}) set(LIB_INFO "${LIB_INFO}, AOCEC") diff --git a/src/libcec/cmake/DisplayPlatformSupport.cmake b/src/libcec/cmake/DisplayPlatformSupport.cmake -index 83a778af..f47b1f7b 100644 +index 83a778a..f47b1f7 100644 --- a/src/libcec/cmake/DisplayPlatformSupport.cmake +++ b/src/libcec/cmake/DisplayPlatformSupport.cmake @@ -44,6 +44,12 @@ else() @@ -801,7 +872,7 @@ index 83a778af..f47b1f7b 100644 message(STATUS "AOCEC support: yes") else() diff --git a/src/libcec/env.h.in b/src/libcec/env.h.in -index 456a2e75..71895a86 100644 +index 456a2e7..71895a8 100644 --- a/src/libcec/env.h.in +++ b/src/libcec/env.h.in @@ -76,6 +76,9 @@ From 612db49d61487f459a03d694b6fe0aad64cbe7b5 Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Tue, 15 Jan 2019 19:50:06 +0100 Subject: [PATCH 2/7] libmali: new package --- packages/graphics/libmali/package.mk | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 packages/graphics/libmali/package.mk diff --git a/packages/graphics/libmali/package.mk b/packages/graphics/libmali/package.mk new file mode 100644 index 00000000000..d7c10542601 --- /dev/null +++ b/packages/graphics/libmali/package.mk @@ -0,0 +1,27 @@ +# SPDX-License-Identifier: GPL-2.0-or-later +# Copyright (C) 2019-present Team LibreELEC (https://libreelec.tv) + +PKG_NAME="libmali" +PKG_VERSION="3e06d6226c22d8d69cd5cb4935d040178b0737f6" +PKG_SHA256="dfdcf2b9f55c3ba9a4e723834708edefb5d7bc7596c4cbde8448e1b0410796d7" +PKG_ARCH="arm aarch64" +PKG_LICENSE="nonfree" +PKG_SITE="https://github.com/LibreELEC/libmali" +PKG_URL="https://github.com/LibreELEC/libmali/archive/$PKG_VERSION.tar.gz" +PKG_LONGDESC="OpenGL ES user-space binary for the ARM Mali GPU family" + +PKG_DEPENDS_TARGET="libdrm" + +if [ "$MALI_FAMILY" = "t720" ]; then + PKG_DEPENDS_TARGET+=" wayland" +fi + +PKG_CMAKE_OPTS_TARGET="-DMALI_VARIANT=$MALI_FAMILY" + +if [ -n "$MALI_REVISION" ]; then + PKG_CMAKE_OPTS_TARGET+=" -DMALI_REVISION=$MALI_REVISION" +fi + +if [ "$TARGET_ARCH" = "aarch64" ]; then + PKG_CMAKE_OPTS_TARGET+=" -DMALI_ARCH=aarch64-linux-gnu" +fi From 338ea10332d0a477c7313a3e2da61eeae84e5196 Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Tue, 15 Jan 2019 19:50:06 +0100 Subject: [PATCH 3/7] kodi: simplify gbm platform check --- packages/mediacenter/kodi/package.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/mediacenter/kodi/package.mk b/packages/mediacenter/kodi/package.mk index be16ffd7489..ddcc9e13602 100644 --- a/packages/mediacenter/kodi/package.mk +++ b/packages/mediacenter/kodi/package.mk @@ -190,7 +190,7 @@ configure_package() { PKG_DEPENDS_TARGET="$PKG_DEPENDS_TARGET $KODIPLAYER_DRIVER libinput libxkbcommon" if [ "$KODIPLAYER_DRIVER" = bcm2835-driver ]; then KODI_PLAYER="-DCORE_PLATFORM_NAME=rbpi" - elif [ "$KODIPLAYER_DRIVER" = mesa -o "$KODIPLAYER_DRIVER" = rkmpp ]; then + elif [ "$OPENGLES_SUPPORT" = yes -a "$KODIPLAYER_DRIVER" = "$OPENGLES" ]; then KODI_PLAYER="-DCORE_PLATFORM_NAME=gbm -DGBM_RENDER_SYSTEM=gles" CFLAGS="$CFLAGS -DMESA_EGL_NO_X11_HEADERS" CXXFLAGS="$CXXFLAGS -DMESA_EGL_NO_X11_HEADERS" From 47bc56e99a6ff42f6ac28f4520e04d223aa88adb Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Tue, 15 Jan 2019 19:50:06 +0100 Subject: [PATCH 4/7] Rockchip: use libmali --- projects/Rockchip/options | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/projects/Rockchip/options b/projects/Rockchip/options index f98719b2a8c..4d9e18fab60 100644 --- a/projects/Rockchip/options +++ b/projects/Rockchip/options @@ -33,7 +33,7 @@ OPENGL="no" # OpenGL-ES implementation to use (no / bcm2835-driver / gpu-viv-bin-mx6q) - OPENGLES="mali-rockchip" + OPENGLES="libmali" # include uvesafb support (yes / no) UVESAFB_SUPPORT="no" @@ -53,7 +53,7 @@ KODI_VENDOR="rockchip" # KODI Player implementation to use (default / bcm2835-driver / libfslvpuwrap) - KODIPLAYER_DRIVER="rkmpp" + KODIPLAYER_DRIVER="$OPENGLES" # Modules to install in initramfs for early boot INITRAMFS_MODULES="" From 152f574e35cb6b04d81f71cae892411c807b27ea Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Tue, 15 Jan 2019 19:50:06 +0100 Subject: [PATCH 5/7] mali-rockchip: remove package --- packages/graphics/mali-rockchip/package.mk | 86 ------------------- .../graphics/mali-rockchip/pkgconfig/egl.pc | 12 --- .../graphics/mali-rockchip/pkgconfig/gbm.pc | 12 --- .../mali-rockchip/pkgconfig/glesv2.pc | 12 --- .../mali-rockchip/pkgconfig/wayland-egl.pc | 12 --- 5 files changed, 134 deletions(-) delete mode 100644 packages/graphics/mali-rockchip/package.mk delete mode 100644 packages/graphics/mali-rockchip/pkgconfig/egl.pc delete mode 100644 packages/graphics/mali-rockchip/pkgconfig/gbm.pc delete mode 100644 packages/graphics/mali-rockchip/pkgconfig/glesv2.pc delete mode 100644 packages/graphics/mali-rockchip/pkgconfig/wayland-egl.pc diff --git a/packages/graphics/mali-rockchip/package.mk b/packages/graphics/mali-rockchip/package.mk deleted file mode 100644 index ec9c86e9e26..00000000000 --- a/packages/graphics/mali-rockchip/package.mk +++ /dev/null @@ -1,86 +0,0 @@ -# SPDX-License-Identifier: GPL-2.0-or-later -# Copyright (C) 2017-present Team LibreELEC (https://libreelec.tv) - -PKG_NAME="mali-rockchip" -PKG_VERSION="12daf22c405a4f8faf6cbc4d2e88b85b36dc61d9" -PKG_SHA256="e6004e0f5a8a4aba098d301b3f964e2a9a961bb79f180d55ea6e9e73cd6eb874" -PKG_ARCH="arm aarch64" -PKG_LICENSE="nonfree" -PKG_SITE="https://github.com/rockchip-linux/libmali" -PKG_URL="https://github.com/rockchip-linux/libmali/archive/$PKG_VERSION.tar.gz" -PKG_LONGDESC="mali-rockchip: OpenGL ES user-space binary for the ARM Mali GPU family" -PKG_TOOLCHAIN="manual" - -if [ "$TARGET_ARCH" = "arm" ]; then - PKG_MALI_ARCH="arm-linux-gnueabihf" -elif [ "$TARGET_ARCH" = "aarch64" ]; then - PKG_MALI_ARCH="aarch64-linux-gnu" -fi - -if [ "$DISPLAYSERVER" = "x11" ]; then - PKG_MALI_SUFFIX="" -elif [ "$DISPLAYSERVER" = "weston" ]; then - PKG_MALI_SUFFIX="-wayland" -else - PKG_MALI_SUFFIX="-gbm" -fi - -if [ "$MALI_FAMILY" = "t760" -a "$MALI_REVISION" = "r1p0" ]; then - PKG_MALI_FILE="libmali-midgard-t76x-r14p0-r1p0$PKG_MALI_SUFFIX.so" -elif [ "$MALI_FAMILY" = "t760" ]; then - PKG_MALI_FILE="libmali-midgard-t76x-r14p0-r0p0$PKG_MALI_SUFFIX.so" -elif [ "$MALI_FAMILY" = "t860" ]; then - PKG_MALI_FILE="libmali-midgard-t86x-r14p0$PKG_MALI_SUFFIX.so" -elif [ "$MALI_FAMILY" = "450" ]; then - PKG_MALI_FILE="libmali-utgard-450-r7p0$PKG_MALI_SUFFIX.so" -elif [ "$MALI_FAMILY" = "400" ]; then - PKG_MALI_FILE="libmali-utgard-400-r7p0$PKG_MALI_SUFFIX.so" -else - echo "ERROR: Unknown MALI_FAMILY '$MALI_FAMILY', aborting." - exit 1 -fi - -configure_target() { - if [ ! -f "$PKG_BUILD/lib/$PKG_MALI_ARCH/$PKG_MALI_FILE" ]; then - echo "ERROR: $PKG_MALI_ARCH/$PKG_MALI_FILE does not exist, aborting." - exit 1 - fi -} - -makeinstall_target() { - cd $PKG_BUILD - - mkdir -p $SYSROOT_PREFIX/usr/include - cp -PRv include/EGL $SYSROOT_PREFIX/usr/include - cp -PRv include/GLES $SYSROOT_PREFIX/usr/include - cp -PRv include/GLES2 $SYSROOT_PREFIX/usr/include - if [ "$MALI_FAMILY" = "t760" -o "$MALI_FAMILY" = "t860" ]; then - cp -PRv include/GLES3 $SYSROOT_PREFIX/usr/include - fi - cp -PRv include/KHR $SYSROOT_PREFIX/usr/include - cp -PRv include/gbm.h $SYSROOT_PREFIX/usr/include - - mkdir -p $SYSROOT_PREFIX/usr/lib/pkgconfig - cp -PRv $PKG_DIR/pkgconfig/*.pc $SYSROOT_PREFIX/usr/lib/pkgconfig - if [ "$DISPLAYSERVER" != "weston" ]; then - rm -fv $SYSROOT_PREFIX/usr/lib/pkgconfig/wayland-egl.pc - fi - - mkdir -p $SYSROOT_PREFIX/usr/lib - cp -PRv lib/$PKG_MALI_ARCH/$PKG_MALI_FILE $SYSROOT_PREFIX/usr/lib - ln -sfv $PKG_MALI_FILE $SYSROOT_PREFIX/usr/lib/libmali.so - ln -sfv libmali.so $SYSROOT_PREFIX/usr/lib/libMali.so - ln -sfv libmali.so $SYSROOT_PREFIX/usr/lib/libEGL.so - ln -sfv libmali.so $SYSROOT_PREFIX/usr/lib/libGLESv2.so - ln -sfv libmali.so $SYSROOT_PREFIX/usr/lib/libgbm.so - - mkdir -p $INSTALL/usr/lib - cp -PRv lib/$PKG_MALI_ARCH/$PKG_MALI_FILE $INSTALL/usr/lib - ln -sfv $PKG_MALI_FILE $INSTALL/usr/lib/libmali.so - ln -sfv libmali.so $INSTALL/usr/lib/libMali.so - ln -sfv libmali.so $INSTALL/usr/lib/libEGL.so - ln -sfv libmali.so $INSTALL/usr/lib/libEGL.so.1 - ln -sfv libmali.so $INSTALL/usr/lib/libGLESv2.so - ln -sfv libmali.so $INSTALL/usr/lib/libGLESv2.so.2 - ln -sfv libmali.so $INSTALL/usr/lib/libgbm.so -} diff --git a/packages/graphics/mali-rockchip/pkgconfig/egl.pc b/packages/graphics/mali-rockchip/pkgconfig/egl.pc deleted file mode 100644 index 14da6e33237..00000000000 --- a/packages/graphics/mali-rockchip/pkgconfig/egl.pc +++ /dev/null @@ -1,12 +0,0 @@ -prefix=/usr -exec_prefix=${prefix} -libdir=${prefix}/lib -includedir=${prefix}/include - -Name: egl -Description: ARM Mali implementation of EGL -Version: 1.5 -Requires: -Libs: -L${libdir} -lEGL -Libs.private: -lm -lpthread -Cflags: -I${includedir} diff --git a/packages/graphics/mali-rockchip/pkgconfig/gbm.pc b/packages/graphics/mali-rockchip/pkgconfig/gbm.pc deleted file mode 100644 index 7c990652292..00000000000 --- a/packages/graphics/mali-rockchip/pkgconfig/gbm.pc +++ /dev/null @@ -1,12 +0,0 @@ -prefix=/usr -exec_prefix=${prefix} -libdir=${prefix}/lib -includedir=${prefix}/include - -Name: gbm -Description: Mali GBM library -Requires.private: -Version: 10.4.0 -Libs: -L${libdir} -lgbm -Libs.private: -Cflags: -I${includedir} diff --git a/packages/graphics/mali-rockchip/pkgconfig/glesv2.pc b/packages/graphics/mali-rockchip/pkgconfig/glesv2.pc deleted file mode 100644 index 8bdbf61dc3f..00000000000 --- a/packages/graphics/mali-rockchip/pkgconfig/glesv2.pc +++ /dev/null @@ -1,12 +0,0 @@ -prefix=/usr -exec_prefix=${prefix} -libdir=${prefix}/lib -includedir=${prefix}/include - -Name: glesv2 -Description: ARM Mali implementation of OpenGL ESv2 -Version: 2.0 -Requires: -Libs: -L${libdir} -lGLESv2 -Libs.private: -lm -lpthread -Cflags: -I${includedir} diff --git a/packages/graphics/mali-rockchip/pkgconfig/wayland-egl.pc b/packages/graphics/mali-rockchip/pkgconfig/wayland-egl.pc deleted file mode 100644 index 937fed1d09c..00000000000 --- a/packages/graphics/mali-rockchip/pkgconfig/wayland-egl.pc +++ /dev/null @@ -1,12 +0,0 @@ -prefix=/usr -exec_prefix=${prefix} -libdir=${prefix}/lib -includedir=${prefix}/include - -Name: wayland-egl -Description: Mali EGL library -Requires.private: -Version: 7.10 -Libs: -L${libdir} -lMali -Libs.private: -lm -lpthread -Cflags: -I${includedir} From e1da5b4a93ffd3f158743db83288c7ddea00f857 Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Tue, 15 Jan 2019 19:50:06 +0100 Subject: [PATCH 6/7] rkbin: update to 28b8bbe --- packages/tools/rkbin/package.mk | 6 +++--- projects/Rockchip/bootloader/install | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/tools/rkbin/package.mk b/packages/tools/rkbin/package.mk index 669a8e51664..347756372d2 100644 --- a/packages/tools/rkbin/package.mk +++ b/packages/tools/rkbin/package.mk @@ -2,9 +2,9 @@ # Copyright (C) 2017-present Team LibreELEC (https://libreelec.tv) PKG_NAME="rkbin" -# Version is: Kwiboo/tag:libreelec-120fe36 -PKG_VERSION="120fe36ad34d7026051ecc50840a6a8dc95d759e" -PKG_SHA256="67f052770b44b4c45b537e34abd59065300703feca6a687d378360bfc2458080" +# Version is: Kwiboo/tag:libreelec-28b8bbe +PKG_VERSION="28b8bbe901048fa15e080bd1e6e949801e8991aa" +PKG_SHA256="95757bf9a9bde4d99bb69fa3d8e5ba0bbcfd6637c4712a99b20c45f832eaf504" PKG_ARCH="arm aarch64" PKG_LICENSE="nonfree" PKG_SITE="https://github.com/rockchip-linux/rkbin" diff --git a/projects/Rockchip/bootloader/install b/projects/Rockchip/bootloader/install index 54be2cfe06d..6e183879976 100644 --- a/projects/Rockchip/bootloader/install +++ b/projects/Rockchip/bootloader/install @@ -21,13 +21,13 @@ case "$PKG_SOC" in rk3328) PKG_DATAFILE="$PKG_RKBIN/rk33/rk3328_ddr_786MHz_v1.13.bin" PKG_LOADER="$PKG_RKBIN/rk33/rk3328_miniloader_v2.49.bin" - PKG_BL31="$PKG_RKBIN/rk33/rk3328_bl31_v1.39.bin" + PKG_BL31="$PKG_RKBIN/rk33/rk3328_bl31_v1.40.bin" PKG_LOAD_ADDR="0x200000" ;; rk3399) - PKG_DATAFILE="$PKG_RKBIN/rk33/rk3399_ddr_800MHz_v1.14.bin" + PKG_DATAFILE="$PKG_RKBIN/rk33/rk3399_ddr_800MHz_v1.17.bin" PKG_LOADER="$PKG_RKBIN/rk33/rk3399_miniloader_v1.15.bin" - PKG_BL31="$PKG_RKBIN/rk33/rk3399_bl31_v1.18.elf" + PKG_BL31="$PKG_RKBIN/rk33/rk3399_bl31_v1.23.elf" PKG_LOAD_ADDR="0x200000" ;; *) From a6e2371d14aea2fd7916f75fe61efd4ad48b3f36 Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Tue, 15 Jan 2019 19:50:06 +0100 Subject: [PATCH 7/7] rkmpp: update to f367af4 --- packages/multimedia/rkmpp/package.mk | 4 +- ...-32-bit-mmap-issue-on-64-bit-kernels.patch | 2 +- ...p-0002-disable-unit-tests-by-default.patch | 2 +- ...64d-fix-mpp_buf_slot_get_prop-crash.patch} | 6 +- ...003-h264d-revert-vdpu-fast-mode-code.patch | 140 ------------------ ...atch => rkmpp-0004-m2vd-use-ctx-pts.patch} | 2 +- ...2vd-export-aspect-ratio-information.patch} | 2 +- 7 files changed, 9 insertions(+), 149 deletions(-) rename packages/multimedia/rkmpp/patches/{rkmpp-0004-h264d-fix-mpp_buf_slot_get_prop-crash.patch => rkmpp-0003-h264d-fix-mpp_buf_slot_get_prop-crash.patch} (85%) delete mode 100644 packages/multimedia/rkmpp/patches/rkmpp-0003-h264d-revert-vdpu-fast-mode-code.patch rename packages/multimedia/rkmpp/patches/{rkmpp-0005-m2vd-use-ctx-pts.patch => rkmpp-0004-m2vd-use-ctx-pts.patch} (93%) rename packages/multimedia/rkmpp/patches/{rkmpp-0006-m2vd-export-aspect-ratio-information.patch => rkmpp-0005-m2vd-export-aspect-ratio-information.patch} (98%) diff --git a/packages/multimedia/rkmpp/package.mk b/packages/multimedia/rkmpp/package.mk index fbdff242788..6fbb1f2d1aa 100644 --- a/packages/multimedia/rkmpp/package.mk +++ b/packages/multimedia/rkmpp/package.mk @@ -2,8 +2,8 @@ # Copyright (C) 2017-present Team LibreELEC (https://libreelec.tv) PKG_NAME="rkmpp" -PKG_VERSION="50d2179ff5d271c591f87082ad757aa99ee6501d" -PKG_SHA256="f9bc02d987de47b98aa9c847ca696bf23fedcdd8bed7f1fe8509cc5ba25954ed" +PKG_VERSION="f367af4a37db719dde7a03a09bc0bb977b185a29" +PKG_SHA256="546f74e2e6ef9bbd543778fd39793f552929db2838b518a5c7a51e864756c73f" PKG_ARCH="arm aarch64" PKG_LICENSE="APL" PKG_SITE="https://github.com/rockchip-linux/mpp" diff --git a/packages/multimedia/rkmpp/patches/rkmpp-0001-fix-32-bit-mmap-issue-on-64-bit-kernels.patch b/packages/multimedia/rkmpp/patches/rkmpp-0001-fix-32-bit-mmap-issue-on-64-bit-kernels.patch index 5182af32a7c..d79f9128435 100644 --- a/packages/multimedia/rkmpp/patches/rkmpp-0001-fix-32-bit-mmap-issue-on-64-bit-kernels.patch +++ b/packages/multimedia/rkmpp/patches/rkmpp-0001-fix-32-bit-mmap-issue-on-64-bit-kernels.patch @@ -1,4 +1,4 @@ -From dded8152c718456fc35e4ba8ae42aca9b92509f0 Mon Sep 17 00:00:00 2001 +From 3b9802254aeed9a0708d6c0c6b64c6b94ede3fa5 Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Mon, 29 May 2017 14:08:43 +0200 Subject: [PATCH] fix 32-bit mmap issue on 64-bit kernels diff --git a/packages/multimedia/rkmpp/patches/rkmpp-0002-disable-unit-tests-by-default.patch b/packages/multimedia/rkmpp/patches/rkmpp-0002-disable-unit-tests-by-default.patch index 7b589d65457..bbb26a9e92b 100644 --- a/packages/multimedia/rkmpp/patches/rkmpp-0002-disable-unit-tests-by-default.patch +++ b/packages/multimedia/rkmpp/patches/rkmpp-0002-disable-unit-tests-by-default.patch @@ -1,4 +1,4 @@ -From 0bcf210be37b631039ceef89155538770ccefed7 Mon Sep 17 00:00:00 2001 +From 9e8b370b826e662879fcec9193956ec59a7db331 Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Sun, 24 Jun 2018 11:07:44 +0200 Subject: [PATCH] disable unit tests by default diff --git a/packages/multimedia/rkmpp/patches/rkmpp-0004-h264d-fix-mpp_buf_slot_get_prop-crash.patch b/packages/multimedia/rkmpp/patches/rkmpp-0003-h264d-fix-mpp_buf_slot_get_prop-crash.patch similarity index 85% rename from packages/multimedia/rkmpp/patches/rkmpp-0004-h264d-fix-mpp_buf_slot_get_prop-crash.patch rename to packages/multimedia/rkmpp/patches/rkmpp-0003-h264d-fix-mpp_buf_slot_get_prop-crash.patch index aa82af07f26..c58e86188f5 100644 --- a/packages/multimedia/rkmpp/patches/rkmpp-0004-h264d-fix-mpp_buf_slot_get_prop-crash.patch +++ b/packages/multimedia/rkmpp/patches/rkmpp-0003-h264d-fix-mpp_buf_slot_get_prop-crash.patch @@ -1,4 +1,4 @@ -From 773108dc3584ce325ff4127dbd54a0a935a89bfc Mon Sep 17 00:00:00 2001 +From 57a996a3c2ebf8991216c9084b476254e205c28c Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Fri, 7 Sep 2018 19:53:10 +0200 Subject: [PATCH] [h264d]: fix mpp_buf_slot_get_prop crash @@ -8,10 +8,10 @@ Subject: [PATCH] [h264d]: fix mpp_buf_slot_get_prop crash 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/mpp/codec/dec/h264/h264d_init.c b/mpp/codec/dec/h264/h264d_init.c -index f32c2a77..46f02466 100644 +index cd17776c..acad2ea7 100644 --- a/mpp/codec/dec/h264/h264d_init.c +++ b/mpp/codec/dec/h264/h264d_init.c -@@ -1387,7 +1387,11 @@ static RK_U32 check_ref_dbp_err(H264_DecCtx_t *p_Dec, H264_RefPicInfo_t *pref, R +@@ -1401,7 +1401,11 @@ static RK_U32 check_ref_dbp_err(H264_DecCtx_t *p_Dec, H264_RefPicInfo_t *pref, R for (i = 0; i < MAX_REF_SIZE; i++) { if (pref[i].valid) { MppFrame mframe = NULL; diff --git a/packages/multimedia/rkmpp/patches/rkmpp-0003-h264d-revert-vdpu-fast-mode-code.patch b/packages/multimedia/rkmpp/patches/rkmpp-0003-h264d-revert-vdpu-fast-mode-code.patch deleted file mode 100644 index 4b1852926f4..00000000000 --- a/packages/multimedia/rkmpp/patches/rkmpp-0003-h264d-revert-vdpu-fast-mode-code.patch +++ /dev/null @@ -1,140 +0,0 @@ -From 51c122a2ee9a1f06c6a33bddc0be2db1065bb385 Mon Sep 17 00:00:00 2001 -From: Jonas Karlman -Date: Tue, 7 Aug 2018 18:14:57 +0200 -Subject: [PATCH] [h264d]: revert vdpu fast mode code - ---- - mpp/hal/rkdec/h264d/hal_h264d_vdpu1.c | 18 +++++------------- - mpp/hal/rkdec/h264d/hal_h264d_vdpu2.c | 18 +++++------------- - 2 files changed, 10 insertions(+), 26 deletions(-) - -diff --git a/mpp/hal/rkdec/h264d/hal_h264d_vdpu1.c b/mpp/hal/rkdec/h264d/hal_h264d_vdpu1.c -index 59d1d7dd..35356c2f 100644 ---- a/mpp/hal/rkdec/h264d/hal_h264d_vdpu1.c -+++ b/mpp/hal/rkdec/h264d/hal_h264d_vdpu1.c -@@ -416,7 +416,8 @@ static MPP_RET vdpu1_set_vlc_regs(H264dHalCtx_t *p_hal, - //!< set poc to buffer - { - H264dVdpuRegCtx_t *reg_ctx = (H264dVdpuRegCtx_t *)p_hal->reg_ctx; -- RK_U32 *pocBase = (RK_U32 *)mpp_buffer_get_ptr(reg_ctx->poc_buf); -+ RK_U32 *pocBase = (RK_U32 *)((RK_U8 *)mpp_buffer_get_ptr(reg_ctx->cabac_buf) -+ + VDPU_CABAC_TAB_SIZE); - - //!< set reference reorder poc - for (i = 0; i < 32; i++) { -@@ -620,7 +621,8 @@ static MPP_RET vdpu1_set_asic_regs(H264dHalCtx_t *p_hal, - H264dVdpuRegCtx_t *reg_ctx = (H264dVdpuRegCtx_t *)p_hal->reg_ctx; - if (p_hal->pp->scaleing_list_enable_flag) { - RK_U32 temp = 0; -- RK_U32 *ptr = (RK_U32 *)mpp_buffer_get_ptr(reg_ctx->sclst_buf); -+ RK_U32 *ptr = (RK_U32 *)((RK_U8 *)mpp_buffer_get_ptr(reg_ctx->cabac_buf) -+ + VDPU_CABAC_TAB_SIZE + VDPU_POC_BUF_SIZE); - - for (i = 0; i < 6; i++) { - for (j = 0; j < 4; j++) { -@@ -722,21 +724,15 @@ MPP_RET vdpu1_h264d_init(void *hal, MppHalCfg *cfg) - H264dVdpuRegCtx_t *reg_ctx = (H264dVdpuRegCtx_t *)p_hal->reg_ctx; - //!< malloc buffers - FUN_CHECK(ret = mpp_buffer_get(p_hal->buf_group, -- ®_ctx->cabac_buf, VDPU_CABAC_TAB_SIZE)); -+ ®_ctx->cabac_buf, VDPU_CABAC_TAB_SIZE + VDPU_POC_BUF_SIZE + VDPU_SCALING_LIST_SIZE)); - RK_U32 i = 0; - RK_U32 loop = p_hal->fast_mode ? MPP_ARRAY_ELEMS(reg_ctx->reg_buf) : 1; - for (i = 0; i < loop; i++) { - reg_ctx->reg_buf[i].regs = mpp_calloc_size(void, sizeof(H264dVdpu1Regs_t)); -- FUN_CHECK(ret = mpp_buffer_get(p_hal->buf_group, -- ®_ctx->reg_buf[i].poc, VDPU_POC_BUF_SIZE)); -- FUN_CHECK(ret = mpp_buffer_get(p_hal->buf_group, -- ®_ctx->reg_buf[i].sclst, VDPU_SCALING_LIST_SIZE)); - } - - if (!p_hal->fast_mode) { - reg_ctx->regs = reg_ctx->reg_buf[0].regs; -- reg_ctx->poc_buf = reg_ctx->reg_buf[0].poc; -- reg_ctx->sclst_buf = reg_ctx->reg_buf[0].sclst; - } - //!< copy cabac table bytes - FUN_CHECK(ret = mpp_buffer_write(reg_ctx->cabac_buf, 0, -@@ -771,8 +767,6 @@ MPP_RET vdpu1_h264d_deinit(void *hal) - RK_U32 loop = p_hal->fast_mode ? MPP_ARRAY_ELEMS(reg_ctx->reg_buf) : 1; - for (i = 0; i < loop; i++) { - MPP_FREE(reg_ctx->reg_buf[i].regs); -- mpp_buffer_put(reg_ctx->reg_buf[i].poc); -- mpp_buffer_put(reg_ctx->reg_buf[i].sclst); - } - mpp_buffer_put(reg_ctx->cabac_buf); - MPP_FREE(p_hal->reg_ctx); -@@ -809,8 +803,6 @@ MPP_RET vdpu1_h264d_gen_regs(void *hal, HalTaskInfo *task) - for (i = 0; i < MPP_ARRAY_ELEMS(reg_ctx->reg_buf); i++) { - if (!reg_ctx->reg_buf[i].valid) { - task->dec.reg_index = i; -- reg_ctx->poc_buf = reg_ctx->reg_buf[i].poc; -- reg_ctx->sclst_buf = reg_ctx->reg_buf[i].sclst; - reg_ctx->regs = reg_ctx->reg_buf[i].regs; - reg_ctx->reg_buf[i].valid = 1; - break; -diff --git a/mpp/hal/rkdec/h264d/hal_h264d_vdpu2.c b/mpp/hal/rkdec/h264d/hal_h264d_vdpu2.c -index 7ad44840..71dd9e44 100644 ---- a/mpp/hal/rkdec/h264d/hal_h264d_vdpu2.c -+++ b/mpp/hal/rkdec/h264d/hal_h264d_vdpu2.c -@@ -451,7 +451,8 @@ static MPP_RET set_vlc_regs(H264dHalCtx_t *p_hal, H264dVdpuRegs_t *p_regs) - //!< set poc to buffer - { - H264dVdpuRegCtx_t *reg_ctx = (H264dVdpuRegCtx_t *)p_hal->reg_ctx; -- RK_U32 *ptr = (RK_U32 *)mpp_buffer_get_ptr(reg_ctx->poc_buf); -+ RK_U32 *ptr = (RK_U32 *)((RK_U8 *)mpp_buffer_get_ptr(reg_ctx->cabac_buf) -+ + VDPU_CABAC_TAB_SIZE); - //!< set reference reorder poc - for (i = 0; i < 32; i++) { - if (pp->RefFrameList[i / 2].bPicEntry != 0xff) { -@@ -636,7 +637,8 @@ static MPP_RET set_asic_regs(H264dHalCtx_t *p_hal, H264dVdpuRegs_t *p_regs) - H264dVdpuRegCtx_t *reg_ctx = (H264dVdpuRegCtx_t *)p_hal->reg_ctx; - if (p_hal->pp->scaleing_list_enable_flag) { - RK_U32 temp = 0; -- RK_U32 *ptr = (RK_U32 *)mpp_buffer_get_ptr(reg_ctx->cabac_buf); -+ RK_U32 *ptr = (RK_U32 *)((RK_U8 *)mpp_buffer_get_ptr(reg_ctx->cabac_buf) -+ + VDPU_CABAC_TAB_SIZE + VDPU_POC_BUF_SIZE); - - for (i = 0; i < 6; i++) { - for (j = 0; j < 4; j++) { -@@ -686,21 +688,15 @@ MPP_RET vdpu2_h264d_init(void *hal, MppHalCfg *cfg) - H264dVdpuRegCtx_t *reg_ctx = (H264dVdpuRegCtx_t *)p_hal->reg_ctx; - //!< malloc buffers - FUN_CHECK(ret = mpp_buffer_get(p_hal->buf_group, -- ®_ctx->cabac_buf, VDPU_CABAC_TAB_SIZE)); -+ ®_ctx->cabac_buf, VDPU_CABAC_TAB_SIZE + VDPU_POC_BUF_SIZE + VDPU_SCALING_LIST_SIZE)); - RK_U32 i = 0; - RK_U32 loop = p_hal->fast_mode ? MPP_ARRAY_ELEMS(reg_ctx->reg_buf) : 1; - for (i = 0; i < loop; i++) { - reg_ctx->reg_buf[i].regs = mpp_calloc_size(void, sizeof(H264dVdpuRegs_t)); -- FUN_CHECK(ret = mpp_buffer_get(p_hal->buf_group, -- ®_ctx->reg_buf[i].poc, VDPU_POC_BUF_SIZE)); -- FUN_CHECK(ret = mpp_buffer_get(p_hal->buf_group, -- ®_ctx->reg_buf[i].sclst, VDPU_SCALING_LIST_SIZE)); - } - - if (!p_hal->fast_mode) { - reg_ctx->regs = reg_ctx->reg_buf[0].regs; -- reg_ctx->poc_buf = reg_ctx->reg_buf[0].poc; -- reg_ctx->sclst_buf = reg_ctx->reg_buf[0].sclst; - } - //!< copy cabac table bytes - FUN_CHECK(ret = mpp_buffer_write(reg_ctx->cabac_buf, 0, -@@ -735,8 +731,6 @@ MPP_RET vdpu2_h264d_deinit(void *hal) - RK_U32 loop = p_hal->fast_mode ? MPP_ARRAY_ELEMS(reg_ctx->reg_buf) : 1; - for (i = 0; i < loop; i++) { - MPP_FREE(reg_ctx->reg_buf[i].regs); -- mpp_buffer_put(reg_ctx->reg_buf[i].poc); -- mpp_buffer_put(reg_ctx->reg_buf[i].sclst); - } - mpp_buffer_put(reg_ctx->cabac_buf); - MPP_FREE(p_hal->reg_ctx); -@@ -773,8 +767,6 @@ MPP_RET vdpu2_h264d_gen_regs(void *hal, HalTaskInfo *task) - for (i = 0; i < MPP_ARRAY_ELEMS(reg_ctx->reg_buf); i++) { - if (!reg_ctx->reg_buf[i].valid) { - task->dec.reg_index = i; -- reg_ctx->poc_buf = reg_ctx->reg_buf[i].poc; -- reg_ctx->sclst_buf = reg_ctx->reg_buf[i].sclst; - reg_ctx->regs = reg_ctx->reg_buf[i].regs; - reg_ctx->reg_buf[i].valid = 1; - break; diff --git a/packages/multimedia/rkmpp/patches/rkmpp-0005-m2vd-use-ctx-pts.patch b/packages/multimedia/rkmpp/patches/rkmpp-0004-m2vd-use-ctx-pts.patch similarity index 93% rename from packages/multimedia/rkmpp/patches/rkmpp-0005-m2vd-use-ctx-pts.patch rename to packages/multimedia/rkmpp/patches/rkmpp-0004-m2vd-use-ctx-pts.patch index 8dc27335eff..9ee09016d6c 100644 --- a/packages/multimedia/rkmpp/patches/rkmpp-0005-m2vd-use-ctx-pts.patch +++ b/packages/multimedia/rkmpp/patches/rkmpp-0004-m2vd-use-ctx-pts.patch @@ -1,4 +1,4 @@ -From 6be271fa4bbebae10ec5e680a2d90266eb3d9ea8 Mon Sep 17 00:00:00 2001 +From 087282d7d3fb5b5216acf7d10864ab2a42dd8473 Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Thu, 1 Mar 2018 22:31:47 +0100 Subject: [PATCH] [m2vd]: use ctx pts diff --git a/packages/multimedia/rkmpp/patches/rkmpp-0006-m2vd-export-aspect-ratio-information.patch b/packages/multimedia/rkmpp/patches/rkmpp-0005-m2vd-export-aspect-ratio-information.patch similarity index 98% rename from packages/multimedia/rkmpp/patches/rkmpp-0006-m2vd-export-aspect-ratio-information.patch rename to packages/multimedia/rkmpp/patches/rkmpp-0005-m2vd-export-aspect-ratio-information.patch index c2cd6376327..ed2a4ecc5be 100644 --- a/packages/multimedia/rkmpp/patches/rkmpp-0006-m2vd-export-aspect-ratio-information.patch +++ b/packages/multimedia/rkmpp/patches/rkmpp-0005-m2vd-export-aspect-ratio-information.patch @@ -1,4 +1,4 @@ -From 50c49fe8cdb9b236d27ec2b1d3195ca5121d9677 Mon Sep 17 00:00:00 2001 +From e8b390f2a92a9a5668ed8f00255b75d21f9ce60a Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Sat, 15 Sep 2018 11:24:28 +0200 Subject: [PATCH] [m2vd]: export aspect ratio information