1 /*
2 Copyright (c) 2016, Texas Instruments Incorporated - http://www.ti.com/
3 All rights reserved.
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 */
35 /*
36 * ======== ipc.cfg.xs ========
37 */
39 /* root of the configuration object model */
40 var Program = xdc.useModule('xdc.cfg.Program');
41 var cfgArgs = Program.build.cfgArgs;
43 /* configure processor names */
44 var procNameAry = ["HOST", "CORE0"];
45 var MultiProc = xdc.useModule('ti.sdo.utils.MultiProc');
46 MultiProc.setConfig(xdc.global.procName, procNameAry);
48 /* ipc configuration */
49 var Ipc = xdc.useModule('ti.sdo.ipc.Ipc');
50 Ipc.procSync = Ipc.ProcSync_PAIR;
51 Ipc.sr0MemorySetup = true;
53 /* shared region configuration */
54 var SharedRegion = xdc.useModule('ti.sdo.ipc.SharedRegion');
56 /* configure SharedRegion #0 (IPC) */
57 var Sr0Mem = Program.cpu.memoryMap["SR_0"];
59 SharedRegion.setEntryMeta(0,
60 new SharedRegion.Entry({
61 name: "SR_0",
62 base: Sr0Mem.base,
63 len: Sr0Mem.len,
64 ownerProcId: 1,
65 isValid: true,
66 cacheEnable: xdc.global.SR0_cacheEnable
67 })
68 );
70 /* configure SharedRegion #1 (MSMC) */
71 var SrMsmcMem = Program.cpu.memoryMap["SR_MSMC"];
73 SharedRegion.setEntryMeta(1,
74 new SharedRegion.Entry({
75 name: "SR_MSMC",
76 base: SrMsmcMem.base,
77 len: SrMsmcMem.len,
78 ownerProcId: 1,
79 isValid: true,
80 cacheEnable: xdc.global.SrMsmcMem_cacheEnable,
81 createHeap: true
82 })
83 );
85 /* configure SharedRegion #2 (DDR3) */
86 var SrDDr3Mem = Program.cpu.memoryMap["SR_DDR3"];
88 SharedRegion.setEntryMeta(2,
89 new SharedRegion.Entry({
90 name: "SR_DDR3",
91 base: SrDDr3Mem.base,
92 len: SrDDr3Mem.len,
93 ownerProcId: 1,
94 isValid: true,
95 cacheEnable: xdc.global.SrDDr3Mem_cacheEnable,
96 createHeap: true
97 })
98 );