Skip to contentSkip to conversation

Fix dsp related packages for new kernels

PATCH In review Enric Balletbo i Serra 4 participants 7 messages Oct 8, 2014 – Oct 10, 2014 1 message not in the archive

lore
Share & tools
lore
#0 lore raw

cover Fix dsp related packages for new kernels

Hi all,

According to the README I know that probably these packages are unmaintained, but these packages are still used for some of us with newer kernels. This patch series fixes some build problems found when I tried to build this infrastructure with a 3.17 kernel. With these patches I'm able to build and run dsplink examples and gstreamer-ti to encode/decode some videos using the DSP.

If you don't have any inconvenient maybe would be interesting add these patches.

Cheers,

Enric Balletbo i Serra (3):
ti-dmai: Fix build with recent kernels and compilers.
ti-dsplink: Fix irq mismatch for kernel versions greater than 3.7.0.
ti-linuxutils: Fix build problems for kernel up to 3.17

 .../dmai/ti-dmai/remove-unneeded-includes.patch    | 26 ++++++++++
 recipes-ti/dmai/ti-dmai_svn.bb                     |  3 +-
 recipes-ti/dsplink/ti-dsplink.inc                  |  2 +-
 ...splink_1_65_kernel_3_7_0_fix-irq-mismatch.patch | 16 ++++++
 recipes-ti/dsplink/ti-dsplink_1.65.00.03.bb        |  1 +
 recipes-ti/linuxutils/ti-linuxutils.inc            |  2 +-
 .../linuxutils_2_26-cmemk-fixes.patch              | 59 ++++++++++++++++++++++
 .../linuxutils_2_26-sdmak-fixes.patch              | 25 +++++++++
 recipes-ti/linuxutils/ti-linuxutils_2.26.01.02.bb  |  5 +-
 9 files changed, 135 insertions(+), 4 deletions(-)
 create mode 100644 recipes-ti/dmai/ti-dmai/remove-unneeded-includes.patch
 create mode 100644 recipes-ti/dsplink/ti-dsplink/dsplink_1_65_kernel_3_7_0_fix-irq-mismatch.patch
 create mode 100644 recipes-ti/linuxutils/ti-linuxutils/linuxutils_2_26-cmemk-fixes.patch
 create mode 100644 recipes-ti/linuxutils/ti-linuxutils/linuxutils_2_26-sdmak-fixes.patch
Signature · 1 line
1.9.1
#1 lore raw

PATCH 1/3 ti-dmai: Fix build with recent kernels and compilers.

Remove unused includes that only redefine some typedefs already defined in other includes and add the --sysroot flag to fix a linkage problem.

---
 .../dmai/ti-dmai/remove-unneeded-includes.patch    | 26 ++++++++++++++++++++++
 recipes-ti/dmai/ti-dmai_svn.bb                     |  3 ++-
 2 files changed, 28 insertions(+), 1 deletion(-)
 create mode 100644 recipes-ti/dmai/ti-dmai/remove-unneeded-includes.patch
recipes-ti/dmai/ti-dmai/remove-unneeded-includes.patch new file +26 -0
new file mode 100644
index 0000000..cfd325a
@@ -0,0 +1,26 @@
+Index: a/packages/ti/sdo/dmai/Makefile
+===================================================================
+--- a/packages/ti/sdo/dmai/Makefile
++++ b/packages/ti/sdo/dmai/Makefile
+@@ -107,7 +107,7 @@ XDCPATH	+= $(XDC_INSTALL_DIR)/packages;$
+ 
+ CPP_FLAGS	+= -I$(XDC_INSTALL_DIR)/packages -I$(DMAI_INSTALL_DIR)/packages -I$(CE_INSTALL_DIR)/packages -I$(FC_INSTALL_DIR)/packages -I$(XDAIS_INSTALL_DIR)/packages -I$(CODEC_INSTALL_DIR)/packages -DDmai_Device_$(PLATFORM_DEVICE)
+ 
+-GCC_CPP_FLAGS	+= $(CPP_FLAGS) -I$(LINUXKERNEL_INSTALL_DIR)/include -I$(LINUXKERNEL_INSTALL_DIR)/arch/arm/include -I$(LINUXKERNEL_INSTALL_DIR)/arch/arm/$(PLATFORM_ARCH)/include $(HAVE_AUTOCONFIG) -I$(CMEM_INSTALL_DIR)/packages -I$(LINK_INSTALL_DIR) -DDmai_BuildOs_linux -Dxdc_target_types__=gnu/targets/std.h -I$(LINUXLIBS_INSTALL_DIR)/include -Dxdc_target_name__=arm/GCArmv5T
++GCC_CPP_FLAGS	+= $(CPP_FLAGS) $(HAVE_AUTOCONFIG) -I$(CMEM_INSTALL_DIR)/packages -I$(LINK_INSTALL_DIR) -DDmai_BuildOs_linux -Dxdc_target_types__=gnu/targets/std.h -I$(LINUXLIBS_INSTALL_DIR)/include -Dxdc_target_name__=arm/GCArmv5T
+ C64P_CPP_FLAGS	+= $(CPP_FLAGS) -I$(BIOS_INSTALL_DIR)/packages/ti/bios/include -I$(BIOS_INSTALL_DIR)/packages -DDmai_BuildOs_bios -Dxdc_target__='<ti/targets/std.h>' -I$(CODEGEN_INSTALL_DIR)/include -mv6400+ -pdse225 -eo$(PLATFORM_DEVICE).o$(EXT)
+ 
+ GCC_C_FLAGS	+= $(C_FLAGS) -Wall 
+Index: a/packages/ti/sdo/dmai/apps/Makefile.app
+===================================================================
+--- a/packages/ti/sdo/dmai/apps/Makefile.app
++++ b/packages/ti/sdo/dmai/apps/Makefile.app
+@@ -121,7 +121,7 @@ C64P_C_FLAGS	= $(C_FLAGS)
+ GCC_CPP_FLAGS  	= $(CPP_FLAGS) -I$(LINUXKERNEL_INSTALL_DIR)/include
+ C64P_CPP_FLAGS	= $(CPP_FLAGS) -pdse225 -I$(CODEGEN_INSTALL_DIR)/include -mv6400+ -I$(BIOS_INSTALL_DIR)/packages/ti/bios/include -eo$(PLATFORM_DEVICE).o$(EXT)
+ 
+-GCC_LD_FLAGS	= $(LD_FLAGS) -lpthread -lm -L$(LINUXLIBS_INSTALL_DIR)/lib -lasound
++GCC_LD_FLAGS	= $(LD_FLAGS) -lpthread -lm --sysroot=$(PKG_CONFIG_SYSROOT_DIR) -L$(LINUXLIBS_INSTALL_DIR)/lib -lasound
+ C64P_LD_FLAGS	= $(LD_FLAGS) -z -w -x -c -i$(RTDX_INSTALL_DIR)/packages/ti/rtdx/iom/lib/debug -i$(RTDX_INSTALL_DIR)/packages/ti/rtdx/cio/lib/release -i$(RTDX_INSTALL_DIR)/packages/ti/rtdx/lib/c6000 
+ 
+ SOURCES 	= $(wildcard *.c)
recipes-ti/dmai/ti-dmai_svn.bb +2 -1
index 536bb78..4a91b9b 100644
@@ -12,7 +12,7 @@ LIC_FILES_CHKSUM = "file://dmai_${PV}_License.html;md5=3302f728a5a42f97cabc26a54
 
 # This package has high dependence on kernel, use kernel PR as base and append a local version
 PR = "${MACHINE_KERNEL_PR}"
-PR_append = "o"
+PR_append = "p"
 
 DMAIBRANCH_dm6446     = "trunk"
 DMAIBRANCH_dm6467     = "branches/GITPSP_INT_101009"
@@ -34,6 +34,7 @@ SRCREV               ?= "UNDEFINED_SRCREV"
 
 SRC_URI_append = " file://omap3530-r642-remove-include-videodev.diff;striplevel=3 \
                    file://r642-fix-config-bld.diff;striplevel=3 \
+                   file://remove-unneeded-includes.patch \
                  "
 
 INSANE_SKIP_${PN} = "installed-vs-shipped"
Signature · 1 line
1.9.1
#2 lore raw

PATCH 2/3 ti-dsplink: Fix irq mismatch for kernel versions greater than 3.7.0.

In reply to Enric Balletbo i Serra

Commit 7d7e1eb (ARM: OMAP2+: Prepare for irqs.h removal) and commit ec2c082 (ARM: OMAP2+: Remove hardcoded IRQs and enable SPARSE_IRQ) from kernel updated the way interrupts for OMAP2/3 devices are defined.

Fix irq number as dsplink misses to add the NR_IRQS relative offset.

---
 recipes-ti/dsplink/ti-dsplink.inc                        |  2 +-
 .../dsplink_1_65_kernel_3_7_0_fix-irq-mismatch.patch     | 16 ++++++++++++++++
 recipes-ti/dsplink/ti-dsplink_1.65.00.03.bb              |  1 +
 3 files changed, 18 insertions(+), 1 deletion(-)
 create mode 100644 recipes-ti/dsplink/ti-dsplink/dsplink_1_65_kernel_3_7_0_fix-irq-mismatch.patch
recipes-ti/dsplink/ti-dsplink.inc +1 -1
index fa1c9dd..78b53cf 100644
@@ -21,7 +21,7 @@ PROVIDES += "ti-dsplink-examples"
 
 # This package builds a kernel module, use kernel PR as base and append a local version
 PR = "${MACHINE_KERNEL_PR}"
-PR_append = "j"
+PR_append = "h"
 
 S = "${WORKDIR}/dsplink_linux_${PV}"
 
recipes-ti/dsplink/ti-dsplink/dsplink_1_65_kernel_3_7_0_fix-irq-mismatch.patch new file +16 -0
new file mode 100644
index 0000000..787c22e
@@ -0,0 +1,16 @@
+Index: dsplink_linux_1_65_00_03/dsplink/gpp/src/osal/Linux/2.6.18/isr.c
+===================================================================
+--- dsplink_linux_1_65_00_03.orig/dsplink/gpp/src/osal/Linux/2.6.18/isr.c
++++ dsplink_linux_1_65_00_03/dsplink/gpp/src/osal/Linux/2.6.18/isr.c
+@@ -286,7 +286,11 @@ ISR_Create (IN  IsrProc             fnIS
+ 
+         if (DSP_SUCCEEDED (status)) {
+             (*isrObj)->signature = SIGN_ISR       ;
++#if LINUX_VERSION_CODE < KERNEL_VERSION(3,7,0)
+             (*isrObj)->irq       = intObj->intId  ;
++#else
++            (*isrObj)->irq       = intObj->intId + NR_IRQS ;
++#endif
+             (*isrObj)->enabled   = FALSE          ;
+             (*isrObj)->dspId     = intObj->dspId  ;
+             (*isrObj)->checkFunc = intObj->checkFunc  ;
recipes-ti/dsplink/ti-dsplink_1.65.00.03.bb +1 -0
index 1d6fb00..2606cfc 100644
@@ -9,6 +9,7 @@ PV_DL_PATH = "DSPLink/${PV_major}/${PV}/${PV_dot}"
 
 SRC_URI += "file://dsplink-BKL-fix.patch \
             file://0001-remove-check-for-make-version-3.85-works-fine.patch \
+            file://dsplink_1_65_kernel_3_7_0_fix-irq-mismatch.patch \
            "
 
 SRC_URI[dsplinktarball.md5sum] = "1bda596b631bd2f517edc70f6be4f2ca"
Signature · 1 line
1.9.1
#3 lore raw

PATCH 3/3 ti-linuxutils: Fix build problems for kernel up to 3.17

In reply to Enric Balletbo i Serra

Add to patches to fix the build of cmemk and sdmak kernel modules.

---
 recipes-ti/linuxutils/ti-linuxutils.inc            |  2 +-
 .../linuxutils_2_26-cmemk-fixes.patch              | 59 ++++++++++++++++++++++
 .../linuxutils_2_26-sdmak-fixes.patch              | 25 +++++++++
 recipes-ti/linuxutils/ti-linuxutils_2.26.01.02.bb  |  5 +-
 4 files changed, 89 insertions(+), 2 deletions(-)
 create mode 100644 recipes-ti/linuxutils/ti-linuxutils/linuxutils_2_26-cmemk-fixes.patch
 create mode 100644 recipes-ti/linuxutils/ti-linuxutils/linuxutils_2_26-sdmak-fixes.patch
recipes-ti/linuxutils/ti-linuxutils.inc +1 -1
index dba485b..c8f9320 100644
@@ -15,7 +15,7 @@ require recipes-ti/includes/ti-staging.inc
 PR = "${MACHINE_KERNEL_PR}"
 
 #This is a kernel module, don't set PR directly
-MACHINE_KERNEL_PR_append = "e"
+MACHINE_KERNEL_PR_append = "f"
 
 inherit module
 
recipes-ti/linuxutils/ti-linuxutils/linuxutils_2_26-cmemk-fixes.patch new file +59 -0

59 lines not on this page · raw message

recipes-ti/linuxutils/ti-linuxutils/linuxutils_2_26-sdmak-fixes.patch new file +25 -0
new file mode 100644
index 0000000..5ec85fc
@@ -0,0 +1,25 @@
+Index: linuxutils_2_26_01_02/packages/ti/sdo/linuxutils/sdma/src/module/sdmak.c
+===================================================================
+--- linuxutils_2_26_01_02.orig/packages/ti/sdo/linuxutils/sdma/src/module/sdmak.c
++++ linuxutils_2_26_01_02/packages/ti/sdo/linuxutils/sdma/src/module/sdmak.c
+@@ -44,7 +44,7 @@
+ #include <mach/hardware.h>
+ #include <mach/dma.h>
+ #include <mach/tc.h>
+-#else
++#elif LINUX_VERSION_CODE < KERNEL_VERSION(3,7,0)
+ #include <plat/hardware.h>
+ #include <plat/dma.h>
+ #include <plat/tc.h>
+@@ -97,6 +97,11 @@
+ 
+ #endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,18) */
+ 
++#ifndef OMAP_DMA_NO_DEVICE
++#include <linux/omap-dma.h>
++#define OMAP_DMA_NO_DEVICE	0
++#endif
++
+ #include "../interface/sdma.h"
+ 
+ struct channel {
recipes-ti/linuxutils/ti-linuxutils_2.26.01.02.bb +4 -1
index 75a32da..1a56d1d 100644
@@ -1,6 +1,9 @@
 require ti-linuxutils.inc
 
-SRC_URI += "file://linuxutils-BKL-fix-2.patch"
+SRC_URI += "file://linuxutils-BKL-fix-2.patch \
+			file://linuxutils_2_26-cmemk-fixes.patch \
+			file://linuxutils_2_26-sdmak-fixes.patch \
+	"
 
 PE = "1"
 PV = "2_26_01_02"
Signature · 1 line
1.9.1
#4 lore raw
In reply to Enric Balletbo i Serra
Quoted 9 lines · Enric Balletbo i Serra

Hi all,

According to the README I know that probably these packages are unmaintained, but these packages are still used for some of us with newer kernels. This patch series fixes some build problems found when I tried to build this infrastructure with a 3.17 kernel. With these patches I'm able to build and run dsplink examples and gstreamer-ti to encode/decode some videos using the DSP.

If you don't have any inconvenient maybe would be interesting add these patches.

Thanks for the patches! Can you please provide a bit more details about the HW platform you are using these on. Also, we are slowly updating other components in meta-ti, that touch DSP, like IPC, etc. - please let us know if any of the new changes affect the old components or break anything for you. I can't guarantee we'd be able to fix or support older platforms within new components right away, but at least we should be able to preserve old versions of the required components for as long as they work. Please keep in touch. Thanks!

Signature · 1 line
Denys
Quoted 28 lines

Enric Balletbo i Serra (3):
ti-dmai: Fix build with recent kernels and compilers.
ti-dsplink: Fix irq mismatch for kernel versions greater than 3.7.0.
ti-linuxutils: Fix build problems for kernel up to 3.17

 .../dmai/ti-dmai/remove-unneeded-includes.patch    | 26 ++++++++++
 recipes-ti/dmai/ti-dmai_svn.bb                     |  3 +-
 recipes-ti/dsplink/ti-dsplink.inc                  |  2 +-
 ...splink_1_65_kernel_3_7_0_fix-irq-mismatch.patch | 16 ++++++
 recipes-ti/dsplink/ti-dsplink_1.65.00.03.bb        |  1 +
 recipes-ti/linuxutils/ti-linuxutils.inc            |  2 +-
 .../linuxutils_2_26-cmemk-fixes.patch              | 59 ++++++++++++++++++++++
 .../linuxutils_2_26-sdmak-fixes.patch              | 25 +++++++++
 recipes-ti/linuxutils/ti-linuxutils_2.26.01.02.bb  |  5 +-
 9 files changed, 135 insertions(+), 4 deletions(-)
 create mode 100644 recipes-ti/dmai/ti-dmai/remove-unneeded-includes.patch
 create mode 100644 recipes-ti/dsplink/ti-dsplink/dsplink_1_65_kernel_3_7_0_fix-irq-mismatch.patch
 create mode 100644 recipes-ti/linuxutils/ti-linuxutils/linuxutils_2_26-cmemk-fixes.patch
 create mode 100644 recipes-ti/linuxutils/ti-linuxutils/linuxutils_2_26-sdmak-fixes.patch
Signature · 7 lines
1.9.1

-- 
_______________________________________________
meta-ti mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-ti
#5 lore raw
Quoted 11 lines · Denys Dmytriyenko
Quoted 9 lines · Enric Balletbo i Serra

Hi all,

According to the README I know that probably these packages are unmaintained, but these packages are still used for some of us with newer kernels. This patch series fixes some build problems found when I tried to build this infrastructure with a 3.17 kernel. With these patches I'm able to build and run dsplink examples and gstreamer-ti to encode/decode some videos using the DSP.

If you don't have any inconvenient maybe would be interesting add these patches.

Quoted 7 lines

Thanks for the patches! Can you please provide a bit more details about the HW platform you are using these on. Also, we are slowly updating other components in meta-ti, that touch DSP, like IPC, etc. - please let us know if any of the new changes affect the old components or break anything for you. I can't guarantee we'd be able to fix or support older platforms within new components right away, but at least we should be able to preserve old versions of the required components for as long as they work. Please keep in touch. Thanks!

Yes please don't remove the old versions, they are still useful. Actually it's incredbile they still work with just some patching. The only "problem" right now is that those components are soft-float only.

For the record i tested these patches on an igep proton (omap3530) and igep com module (dm3730).

Enrico

A message that is not in the archive (sent off-list or not yet received): CAFqH_51CqB6xkqYVQeT2xN=TwM2QkP59nEmEvEZBbf0bvcCfMw@mail.gmail.com

#7 lore raw

Hi Denys,

2014-10-09 9:17 GMT+02:00 Enric Balletbò i Serra <[email protected]>:

Quoted 23 lines

Hi Denys,

2014-10-08 20:05 GMT+02:00 Denys Dmytriyenko <[email protected]>:

Quoted 19 lines · Enric Balletbo i Serra
Quoted 9 lines

Hi all,

According to the README I know that probably these packages are unmaintained, but these packages are still used for some of us with newer kernels. This patch series fixes some build problems found when I tried to build this infrastructure with a 3.17 kernel. With these patches I'm able to build and run dsplink examples and gstreamer-ti to encode/decode some videos using the DSP.

If you don't have any inconvenient maybe would be interesting add these patches.

Thanks for the patches! Can you please provide a bit more details about the HW platform you are using these on. Also, we are slowly updating other components in meta-ti, that touch DSP, like IPC, etc. - please let us know if any of the new changes affect the old components or break anything for you. I can't guarantee we'd be able to fix or support older platforms within new components right away, but at least we should be able to preserve old versions of the required components for as long as they work. Please keep in touch. Thanks!

The hardware that I'm using for test is the IGEPv2 board, is an OMAP3-based board with a DM3730 processor very similar to beagleboard xm. The patches work in this board and if I don't made anything wrong are not intrusive.

Could you provide, apart of beagleboard, which machines should have support for these DSP components in order to try to compile for these platforms and assure that I'm not breaking anything ?

Cheers,
Enric

Quoted 38 lines
Quoted 38 lines

--
Denys

Quoted 20 lines

Enric Balletbo i Serra (3):
ti-dmai: Fix build with recent kernels and compilers.
ti-dsplink: Fix irq mismatch for kernel versions greater than 3.7.0.
ti-linuxutils: Fix build problems for kernel up to 3.17

 .../dmai/ti-dmai/remove-unneeded-includes.patch    | 26 ++++++++++
 recipes-ti/dmai/ti-dmai_svn.bb                     |  3 +-
 recipes-ti/dsplink/ti-dsplink.inc                  |  2 +-
 ...splink_1_65_kernel_3_7_0_fix-irq-mismatch.patch | 16 ++++++
 recipes-ti/dsplink/ti-dsplink_1.65.00.03.bb        |  1 +
 recipes-ti/linuxutils/ti-linuxutils.inc            |  2 +-
 .../linuxutils_2_26-cmemk-fixes.patch              | 59 ++++++++++++++++++++++
 .../linuxutils_2_26-sdmak-fixes.patch              | 25 +++++++++
 recipes-ti/linuxutils/ti-linuxutils_2.26.01.02.bb  |  5 +-
 9 files changed, 135 insertions(+), 4 deletions(-)
 create mode 100644 recipes-ti/dmai/ti-dmai/remove-unneeded-includes.patch
 create mode 100644 recipes-ti/dsplink/ti-dsplink/dsplink_1_65_kernel_3_7_0_fix-irq-mismatch.patch
 create mode 100644 recipes-ti/linuxutils/ti-linuxutils/linuxutils_2_26-cmemk-fixes.patch
 create mode 100644 recipes-ti/linuxutils/ti-linuxutils/linuxutils_2_26-sdmak-fixes.patch
Quoted 8 lines

--
1.9.1

--
_______________________________________________
meta-ti mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-ti

--
_______________________________________________
meta-ti mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-ti