summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrank Livingston2019-08-21 18:04:22 -0500
committerFrank Livingston2019-08-21 18:04:22 -0500
commit494d55190e2bbbc19c42ba4f1ca5469bdb495080 (patch)
treeca48e2a41f152967ecd7590d3c360da81bf53cfc
parent10885254487f51ab3e143b5018b94231ab6f2e6c (diff)
downloadpruss-lld-494d55190e2bbbc19c42ba4f1ca5469bdb495080.tar.gz
pruss-lld-494d55190e2bbbc19c42ba4f1ca5469bdb495080.tar.xz
pruss-lld-494d55190e2bbbc19c42ba4f1ca5469bdb495080.zip
PRSDK-5738:Add Bin's resource table
Signed-off-by: Frank Livingston <frank-livingston@ti.com>
-rw-r--r--example/apps/icssg_pwm/firmware/src/AM654x_PRU.cmd2
-rw-r--r--example/apps/icssg_pwm/firmware/src/main.c1
-rw-r--r--example/apps/icssg_pwm/firmware/src/resource_table_empty.h72
3 files changed, 74 insertions, 1 deletions
diff --git a/example/apps/icssg_pwm/firmware/src/AM654x_PRU.cmd b/example/apps/icssg_pwm/firmware/src/AM654x_PRU.cmd
index b1e992d..a89c42c 100644
--- a/example/apps/icssg_pwm/firmware/src/AM654x_PRU.cmd
+++ b/example/apps/icssg_pwm/firmware/src/AM654x_PRU.cmd
@@ -79,5 +79,5 @@ SECTIONS {
79 .fardata > PRU_DMEM_0_1_LOW, PAGE 1 79 .fardata > PRU_DMEM_0_1_LOW, PAGE 1
80 80
81 .initDataFwRegs > 0x0, PAGE 1 81 .initDataFwRegs > 0x0, PAGE 1
82 82 .resource_table > 0x200, PAGE 1
83} 83}
diff --git a/example/apps/icssg_pwm/firmware/src/main.c b/example/apps/icssg_pwm/firmware/src/main.c
index 2ca14aa..b877781 100644
--- a/example/apps/icssg_pwm/firmware/src/main.c
+++ b/example/apps/icssg_pwm/firmware/src/main.c
@@ -35,6 +35,7 @@
35#include "iepPwmHwRegs.h" 35#include "iepPwmHwRegs.h"
36#include "iepPwm.h" 36#include "iepPwm.h"
37#include "icssg_iep_pwm.h" 37#include "icssg_iep_pwm.h"
38#include "resource_table_empty.h"
38 39
39void main(void) 40void main(void)
40{ 41{
diff --git a/example/apps/icssg_pwm/firmware/src/resource_table_empty.h b/example/apps/icssg_pwm/firmware/src/resource_table_empty.h
new file mode 100644
index 0000000..9d9d20f
--- /dev/null
+++ b/example/apps/icssg_pwm/firmware/src/resource_table_empty.h
@@ -0,0 +1,72 @@
1/*
2 * Copyright (C) 2019 Texas Instruments Incorporated - http://www.ti.com/
3 *
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 *
9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer.
11 *
12 * * Redistributions in binary form must reproduce the above copyright
13 * notice, this list of conditions and the following disclaimer in the
14 * documentation and/or other materials provided with the
15 * distribution.
16 *
17 * * Neither the name of Texas Instruments Incorporated nor the names of
18 * its contributors may be used to endorse or promote products derived
19 * from this software without specific prior written permission.
20 *
21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
23 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
24 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
25 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
26 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
27 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
28 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
29 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 */
33
34/*
35 * ======== resource_table_empty.h ========
36 *
37 * Define the resource table entries for all PRU cores. This will be
38 * incorporated into corresponding base images, and used by the remoteproc
39 * on the host-side to allocated/reserve resources. Note the remoteproc
40 * driver requires that all PRU firmware be built with a resource table.
41 *
42 * This file contains an empty resource table. It can be used either as:
43 *
44 * 1) A template, or
45 * 2) As-is if a PRU application does not need to configure PRU_INTC
46 * or interact with the rpmsg driver
47 *
48 */
49
50#ifndef _RSC_TABLE_PRU_H_
51#define _RSC_TABLE_PRU_H_
52
53#include <stddef.h>
54
55struct my_resource_table {
56 uint32_t ver;
57 uint32_t num;
58 uint32_t reserved[2];
59 uint32_t offset[1]; /* Should match 'num' in actual definition */
60};
61
62#pragma DATA_SECTION(pru_remoteproc_ResourceTable, ".resource_table")
63#pragma RETAIN(pru_remoteproc_ResourceTable)
64struct my_resource_table pru_remoteproc_ResourceTable = {
65 1, /* we're the first version that implements this */
66 0, /* number of entries in the table */
67 0, 0, /* reserved, must be zero */
68 0, /* offset[0] */
69};
70
71#endif /* _RSC_TABLE_PRU_H_ */
72