diff options
Diffstat (limited to 'meta-ti-bsp/recipes-devtools/gdbc6x/gdbc6x')
-rw-r--r-- | meta-ti-bsp/recipes-devtools/gdbc6x/gdbc6x/0001-libbfd.h-suppress-GCC9-Wstringop-truncation.patch | 28 | ||||
-rw-r--r-- | meta-ti-bsp/recipes-devtools/gdbc6x/gdbc6x/init | 48 |
2 files changed, 76 insertions, 0 deletions
diff --git a/meta-ti-bsp/recipes-devtools/gdbc6x/gdbc6x/0001-libbfd.h-suppress-GCC9-Wstringop-truncation.patch b/meta-ti-bsp/recipes-devtools/gdbc6x/gdbc6x/0001-libbfd.h-suppress-GCC9-Wstringop-truncation.patch new file mode 100644 index 00000000..1cc23b32 --- /dev/null +++ b/meta-ti-bsp/recipes-devtools/gdbc6x/gdbc6x/0001-libbfd.h-suppress-GCC9-Wstringop-truncation.patch | |||
@@ -0,0 +1,28 @@ | |||
1 | From 0aa294e2bbd37a42266e59cb67687e57bfba4a88 Mon Sep 17 00:00:00 2001 | ||
2 | From: Denys Dmytriyenko <denys@ti.com> | ||
3 | Date: Sat, 15 Feb 2020 15:59:37 -0500 | ||
4 | Subject: [PATCH] libbfd.h: suppress GCC9 -Wstringop-truncation | ||
5 | |||
6 | Signed-off-by: Denys Dmytriyenko <denys@ti.com> | ||
7 | --- | ||
8 | gdbc6x/bfd/libbfd.h | 4 ++++ | ||
9 | 1 file changed, 4 insertions(+) | ||
10 | |||
11 | diff --git a/gdbc6x/bfd/libbfd.h b/gdbc6x/bfd/libbfd.h | ||
12 | index 72d3c50..3465f89 100644 | ||
13 | --- a/gdbc6x/bfd/libbfd.h | ||
14 | +++ b/gdbc6x/bfd/libbfd.h | ||
15 | @@ -34,6 +34,10 @@ | ||
16 | #pragma GCC diagnostic ignored "-Wcast-function-type" | ||
17 | #endif | ||
18 | |||
19 | +#if __GNUC__ >= 9 | ||
20 | +#pragma GCC diagnostic ignored "-Wstringop-truncation" | ||
21 | +#endif | ||
22 | + | ||
23 | #include "hashtab.h" | ||
24 | |||
25 | /* Align an address upward to a boundary, expressed as a number of bytes. | ||
26 | -- | ||
27 | 2.7.4 | ||
28 | |||
diff --git a/meta-ti-bsp/recipes-devtools/gdbc6x/gdbc6x/init b/meta-ti-bsp/recipes-devtools/gdbc6x/gdbc6x/init new file mode 100644 index 00000000..90210b82 --- /dev/null +++ b/meta-ti-bsp/recipes-devtools/gdbc6x/gdbc6x/init | |||
@@ -0,0 +1,48 @@ | |||
1 | #!/bin/bash | ||
2 | |||
3 | GDB_DEVICE_NAME='/dev/gdbtty$i' | ||
4 | DSP_FIRMWARE_NAME='/lib/firmware/dra7-dsp$[$i+1]-fw.xe66' | ||
5 | |||
6 | DSP_L2_GLOBAL_OFFSET="40000000" | ||
7 | DSP_L2_GLOBAL_SHIFT="00800000" | ||
8 | |||
9 | case "$1" in | ||
10 | start) | ||
11 | |||
12 | dsp_core_l2_offset=$DSP_L2_GLOBAL_OFFSET | ||
13 | |||
14 | i=0 | ||
15 | while [ -c "`eval echo $GDB_DEVICE_NAME`" ] | ||
16 | do | ||
17 | dsp_firmware=`eval echo $DSP_FIRMWARE_NAME` | ||
18 | |||
19 | if [ -f "`eval echo $DSP_FIRMWARE_NAME`" ] | ||
20 | then | ||
21 | eval echo "Initializing $GDB_DEVICE_NAME based on $DSP_FIRMWARE_NAME ..." | ||
22 | |||
23 | gdb_data_local=`eval readelf -s "$DSP_FIRMWARE_NAME" | \ | ||
24 | grep 'gdb_globalData' | \ | ||
25 | awk '{print $2}'` | ||
26 | |||
27 | echo "gdb_globalData (local) = $gdb_data_local" | ||
28 | printf "gdb_globalData (global) = %X\n" \ | ||
29 | $[0x$gdb_data_local + 0x$dsp_core_l2_offset] | ||
30 | |||
31 | |||
32 | printf "%X\n" $[0x$gdb_data_local + 0x$dsp_core_l2_offset] \ | ||
33 | >> `eval echo $GDB_DEVICE_NAME` | ||
34 | fi | ||
35 | i=$[$i + 1] | ||
36 | dsp_core_l2_offset=`printf "%X" $[0x$dsp_core_l2_offset + 0x$DSP_L2_GLOBAL_SHIFT]` | ||
37 | done | ||
38 | ;; | ||
39 | stop) | ||
40 | # Nothing to be done. | ||
41 | ;; | ||
42 | *) | ||
43 | echo "Usage: $0 {start|stop}" | ||
44 | exit 1 | ||
45 | ;; | ||
46 | esac | ||
47 | |||
48 | |||