Initial commit of OpenSPARC T2 architecture model.
[OpenSPARC-T2-SAM] / legion / docs / readmes / README.service_processor
CommitLineData
920dae64
AT
1#
2# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
3# Use is subject to license terms.
4#
5# ident "@(#)README.service_processor 1.1 06/09/24 SMI"
6#
7#
8# Using the service_processor directive
9#
10
11[-] Introduction
12
13 If you are running legion in parallel with a Service Processor
14 simulation (sp library, stub, co-simulation, etc), you may want
15 legion to wait for some event from the Service Processor before
16 starting to execute instructions. In order to support this, a
17 service_processor directive has been added to legion's config file.
18 Once this directive exists, legion will setup all it's internal
19 state but wait for a global variable (options.sp.poweron) to be
20 set to true before starting to execute any instructions.
21
22[1] How to set this up
23 Add the following to your legion config file:
24
25 system "dumbblue" {
26 service_processor "generic_sp" {} //<<---Add this
27
28 domain (
29 ...
30
31[2] How the SP signals legion to start
32
33 The assumption is that your Service Processor is now somehow
34 connected to legion (shared mem, sockets, sram etc) and that
35 there is some portion of this Service Processor code that runs
36 within legion's address space. Once the poweron event or
37 de-assertion of the reset pin occurs on the Service Processor,
38 the sp code running within legion can set options.sp.poweron
39 to true which will cause the simulation to start executing
40 instructions.
41
42
43[3] Starting Service processor application from within config file
44
45 If there are applications that need to be started at the same
46 time as legion in order to setup the co-simulation environment
47 you can start these application from within the legion config
48 file using the 'xterm' directive withing the service_processor
49 directive as follows:
50
51 system "dumbblue" {
52 service_processor "generic_sp" {
53 xterm "./service_processor_stub &";
54 xterm "./communications_channel &";
55 }
56
57 domain {
58 ...
59
60 The arguments to xterm above are simply passed to a system(2)
61 call within legion. No measures are taken to terminate these
62 processes once legion terminates. That is up to the Service
63 Processor code.