|
a |
|
b/src/CS/DC_TOR.ned |
|
|
1 |
//
|
|
|
2 |
// This program is free software: you can redistribute it and/or modify
|
|
|
3 |
// it under the terms of the GNU Lesser General Public License as published by
|
|
|
4 |
// the Free Software Foundation, either version 3 of the License, or
|
|
|
5 |
// (at your option) any later version.
|
|
|
6 |
//
|
|
|
7 |
// This program is distributed in the hope that it will be useful,
|
|
|
8 |
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
9 |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
10 |
// GNU Lesser General Public License for more details.
|
|
|
11 |
//
|
|
|
12 |
// You should have received a copy of the GNU Lesser General Public License
|
|
|
13 |
// along with this program. If not, see http://www.gnu.org/licenses/.
|
|
|
14 |
//
|
|
|
15 |
|
|
|
16 |
// Author: Kewin Rausch <kewin.rausch@create-net.org>
|
|
|
17 |
//
|
|
|
18 |
// NOTES:
|
|
|
19 |
// This module describes a Top of Rack module in the DataCenter use-case.
|
|
|
20 |
//
|
|
|
21 |
// Colors of the IPC reflect the use case layers.
|
|
|
22 |
// Link: https://wiki.ict-pristine.eu/wp2/d21/D21-Datnet-RINA
|
|
|
23 |
|
|
|
24 |
package rina.CS;
|
|
|
25 |
|
|
|
26 |
import rina.DAF.DA.DIFAllocator;
|
|
|
27 |
import rina.DIF.IPCProcess;
|
|
|
28 |
|
|
|
29 |
module DC_TOR
|
|
|
30 |
{
|
|
|
31 |
@display("i=abstract/switch;bgb=177,325");
|
|
|
32 |
@node;
|
|
|
33 |
|
|
|
34 |
int nofInt = default(1);
|
|
|
35 |
|
|
|
36 |
gates:
|
|
|
37 |
inout medium[nofInt];
|
|
|
38 |
|
|
|
39 |
submodules:
|
|
|
40 |
ShimIPC[nofInt]: IPCProcess {
|
|
|
41 |
@display("p=90,255;i=,#800000");
|
|
|
42 |
}
|
|
|
43 |
DCIPC: IPCProcess {
|
|
|
44 |
@display("p=90,151;i=,#008000");
|
|
|
45 |
relay = true;
|
|
|
46 |
}
|
|
|
47 |
difAllocator: DIFAllocator {
|
|
|
48 |
@display("p=90,63;i=,grey");
|
|
|
49 |
}
|
|
|
50 |
connections allowunconnected:
|
|
|
51 |
|
|
|
52 |
// Every IPC Process is connected to its medium and the Relay IPC.
|
|
|
53 |
for i=0..nofInt-1 {
|
|
|
54 |
DCIPC.southIo++ <--> ShimIPC[i].northIo++;
|
|
|
55 |
ShimIPC[i].southIo++ <--> medium[i];
|
|
|
56 |
}
|
|
|
57 |
}
|