]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - ipc/ipcdev.git/blob - packages/ti/ipc/remoteproc/rsc_table_omapl138.h
remoteproc: Use ti.trace.SysMin instead of xdc.runtime.SysMin
[ipc/ipcdev.git] / packages / ti / ipc / remoteproc / rsc_table_omapl138.h
1 /*
2  * Copyright (c) 2011-2018, Texas Instruments Incorporated
3  * All rights reserved.
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 distribution.
15  *
16  * *  Neither the name of Texas Instruments Incorporated nor the names of
17  *    its contributors may be used to endorse or promote products derived
18  *    from this software without specific prior written permission.
19  *
20  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
22  * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
23  * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
24  * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
25  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
26  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
27  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
28  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
29  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
30  * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  */
32 /*
33  *  ======== rsc_table_omapl138.h ========
34  *
35  *  Include this table in each base image, which is read from remoteproc on
36  *  host side.
37  *
38  */
40 #ifndef _RSC_TABLE_OMAPL138_H_
41 #define _RSC_TABLE_OMAPL138_H_
43 #include "rsc_types.h"
45 #define DATA_DA                 0xc3100000
47 #ifndef DATA_SIZE
48 #  define DATA_SIZE  (SZ_1M * 15)
49 #endif
51 #define RPMSG_VRING0_DA         0xc3000000
52 #define RPMSG_VRING1_DA         0xc3004000
54 #define CONSOLE_VRING0_DA       0xc3008000
55 #define CONSOLE_VRING1_DA       0xc300C000
57 #define BUFS0_DA                0xc3040000
58 #define BUFS1_DA                0xc3080000
60 /*
61  * sizes of the virtqueues (expressed in number of buffers supported,
62  * and must be power of 2)
63  */
64 #define RPMSG_VQ0_SIZE          256
65 #define RPMSG_VQ1_SIZE          256
67 #define CONSOLE_VQ0_SIZE        256
68 #define CONSOLE_VQ1_SIZE        256
70 /* flip up bits whose indices represent features we support */
71 #define RPMSG_DSP_FEATURES      1
73 struct my_resource_table {
74     struct resource_table base;
76     UInt32 offset[3];
78     /* rpmsg vdev entry */
79     struct fw_rsc_vdev rpmsg_vdev;
80     struct fw_rsc_vdev_vring rpmsg_vring0;
81     struct fw_rsc_vdev_vring rpmsg_vring1;
83     /* data carveout entry */
84     struct fw_rsc_carveout data_cout;
86     /* trace entry */
87     struct fw_rsc_trace trace;
88 };
90 #define TRACEBUFADDR (UInt32)&ti_trace_SysMin_Module_State_0_outbuf__A
91 #define TRACEBUFSIZE 0x8000
93 #pragma DATA_SECTION(ti_ipc_remoteproc_ResourceTable, ".resource_table")
94 #pragma DATA_ALIGN(ti_ipc_remoteproc_ResourceTable, 4096)
96 struct my_resource_table ti_ipc_remoteproc_ResourceTable = {
97     1, /* we're the first version that implements this */
98     3, /* number of entries in the table */
99     0, 0, /* reserved, must be zero */
100     /* offsets to entries */
101     {
102         offsetof(struct my_resource_table, rpmsg_vdev),
103         offsetof(struct my_resource_table, data_cout),
104         offsetof(struct my_resource_table, trace),
105     },
107     /* rpmsg vdev entry */
108     {
109         TYPE_VDEV, VIRTIO_ID_RPMSG, 0,
110         RPMSG_DSP_FEATURES, 0, 0, 0, 2, { 0, 0 },
111         /* no config data */
112     },
113     /* the two vrings */
114     { RPMSG_VRING0_DA, 4096, RPMSG_VQ0_SIZE, 1, 0 },
115     { RPMSG_VRING1_DA, 4096, RPMSG_VQ1_SIZE, 2, 0 },
117     {
118         TYPE_CARVEOUT, DATA_DA, DATA_DA, DATA_SIZE, 0, 0, "DSP_MEM_DATA",
119     },
121     {
122         TYPE_TRACE, TRACEBUFADDR, TRACEBUFSIZE, 0, "trace:dsp",
123     },
124 };
126 #endif /* _RSC_TABLE_OMAPL138_H_ */