home *** CD-ROM | disk | FTP | other *** search
/ Unix System Administration Handbook 1997 October / usah_oct97.iso / rfc / 900s / rfc909.txt < prev    next >
Text File  |  1992-09-22  |  210KB  |  7,771 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.  
  16.  
  17.  
  18.  
  19.                          Loader Debugger Protocol
  20.  
  21.  
  22.  
  23.                                   RFC-909
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33.  
  34.                             Christopher Welles
  35.  
  36.                       BBN Communications Corporation
  37.  
  38.  
  39.                               Walter Milliken
  40.  
  41.                              BBN Laboratories
  42.  
  43.  
  44.  
  45.  
  46.                                  July 1984
  47.  
  48. Status of This Memo
  49.  
  50.    This RFC specifies a proposed protocol for the ARPA Internet
  51.    community, and requests discussion and suggestions for
  52.    improvements.  Distribution of this memo is unlimited.
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.                              Table of Contents
  63.  
  64.  
  65.  
  66.  
  67.  
  68.      1   Introduction.......................................... 1
  69.      1.1   Purpose of This Document............................ 1
  70.      1.2   Summary of Features................................. 2
  71.  
  72.      2   General Description................................... 3
  73.      2.1   Motivation.......................................... 3
  74.      2.2   Relation to Other Protocols......................... 4
  75.      2.2.1   Transport Service Requirements.................... 5
  76.  
  77.      3   Protocol Operation.................................... 9
  78.      3.1   Overview............................................ 9
  79.      3.2   Session Management.................................. 9
  80.      3.3   Command Sequencing................................. 10
  81.      3.4   Data Packing and Transmission...................... 10
  82.      3.5   Implementations.................................... 12
  83.  
  84.      4   Commands and Formats................................. 15
  85.      4.1   Packet Format...................................... 15
  86.      4.2   Command Format..................................... 16
  87.      4.2.1   Command Header................................... 16
  88.      4.3   Addressing......................................... 19
  89.      4.3.1   Long Address Format.............................. 20
  90.      4.3.2   Short Address Format............................. 25
  91.  
  92.      5   Protocol Commands.................................... 29
  93.      5.1   HELLO Command...................................... 29
  94.      5.2   HELLO_REPLY........................................ 29
  95.      5.3   SYNCH Command...................................... 33
  96.      5.4   SYNCH_REPLY........................................ 34
  97.      5.5   ABORT Command...................................... 35
  98.      5.6   ABORT_DONE Reply................................... 35
  99.      5.7   ERROR Reply........................................ 36
  100.      5.8   ERRACK Acknowledgement............................. 39
  101.  
  102.      6   Data Transfer Commands............................... 41
  103.      6.1   WRITE Command...................................... 42
  104.      6.2   READ Command....................................... 43
  105.      6.3   READ_DATA Response................................. 45
  106.      6.4   READ_DONE Reply.................................... 47
  107.      6.5   MOVE Command....................................... 48
  108.      6.6   MOVE_DATA Response................................. 50
  109.  
  110.  
  111.  
  112.                                                                 Page i
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.      6.7   MOVE_DONE Reply.................................... 52
  121.      6.8   REPEAT_DATA........................................ 53
  122.      6.9   WRITE_MASK Command (Optional)...................... 54
  123.  
  124.      7   Control Commands..................................... 59
  125.      7.1   START Command...................................... 59
  126.      7.2   STOP Command....................................... 61
  127.      7.3   CONTINUE Command................................... 62
  128.      7.4   STEP Command....................................... 62
  129.      7.5   REPORT Command..................................... 63
  130.      7.6   STATUS Reply....................................... 64
  131.      7.7   EXCEPTION Trap..................................... 66
  132.  
  133.      8   Management Commands.................................. 69
  134.      8.1   CREATE Command..................................... 69
  135.      8.2   CREATE_DONE Reply.................................. 74
  136.      8.3   DELETE Command..................................... 75
  137.      8.4   DELETE_DONE Reply.................................. 76
  138.      8.5   LIST_ADDRESSES Command............................. 76
  139.      8.6   ADDRESS_LIST Reply................................. 77
  140.      8.7   LIST_BREAKPOINTS Command........................... 79
  141.      8.8   BREAKPOINT_LIST Reply.............................. 80
  142.      8.9   LIST_PROCESSES Command............................. 82
  143.      8.10   PROCESS_LIST Reply................................ 83
  144.      8.11   LIST_NAMES Command................................ 84
  145.      8.12   NAME_LIST Reply................................... 85
  146.      8.13   GET_PHYS_ADDR Command............................. 87
  147.      8.14   GOT_PHYS_ADDR Reply............................... 88
  148.      8.15   GET_OBJECT Command................................ 90
  149.      8.16   GOT_OBJECT Reply.................................. 91
  150.  
  151.      9   Breakpoints and Watchpoints.......................... 93
  152.      9.1   BREAKPOINT_DATA Command............................ 95
  153.  
  154.      10   Conditional Commands................................ 99
  155.      10.1   Condition Command Format......................... 100
  156.      10.2   COUNT Conditions................................. 101
  157.      10.3   CHANGED Condition................................ 102
  158.      10.4   COMPARE Condition................................ 103
  159.      10.5   TEST Condition................................... 105
  160.  
  161.      11   Breakpoint Commands................................ 109
  162.      11.1   INCREMENT Command................................ 109
  163.      11.2   INC_COUNT Command................................ 110
  164.      11.3   OR Command....................................... 111
  165.      11.4   SET_PTR Command.................................. 112
  166.      11.5   SET_STATE Command................................ 113
  167.  
  168.  
  169.  
  170.      Page ii
  171.  
  172.  
  173.  
  174.  
  175.  
  176.  
  177.  
  178.      A   Diagram Conventions................................. 115
  179.  
  180.      B   Command Summary..................................... 117
  181.  
  182.      C   Commands, Responses and Replies..................... 121
  183.  
  184.      D   Glossary............................................ 123
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.  
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.  
  203.  
  204.  
  205.  
  206.  
  207.  
  208.  
  209.  
  210.  
  211.  
  212.  
  213.  
  214.  
  215.  
  216.  
  217.  
  218.  
  219.  
  220.  
  221.  
  222.  
  223.  
  224.  
  225.  
  226.  
  227.  
  228.                                                               Page iii
  229.  
  230.  
  231.  
  232.  
  233.  
  234.  
  235.  
  236.                                   FIGURES
  237.  
  238.  
  239.  
  240.  
  241.      1  Relation to Other Protocols............................ 4
  242.      2  Form of Data Exchange Between Layers................... 6
  243.      3  Packing of 16-bit Words............................... 11
  244.      4  Packing of 20-bit Words............................... 12
  245.      5  Network Packet Format................................. 15
  246.      6  LDP Command Header Format............................. 16
  247.      7  Command Classes....................................... 17
  248.      8  Command Types......................................... 18
  249.      9  Long Address Format................................... 20
  250.      10  Long Address Modes................................... 21
  251.      11  Short Address Format................................. 26
  252.      12  Short Address Modes.................................. 27
  253.      13  HELLO Command Format................................. 29
  254.      14  HELLO_REPLY Format................................... 30
  255.      15  System Types......................................... 31
  256.      16  Target Address Codes................................. 31
  257.      17  Feature Levels....................................... 32
  258.      18  Options.............................................. 33
  259.      19  SYNCH Command Format................................. 33
  260.      20  SYNCH_REPLY Format................................... 34
  261.      21  ABORT Command Format................................. 35
  262.      22  ABORT_DONE Reply Format.............................. 36
  263.      23  ERROR Reply Format................................... 37
  264.      24  ERROR Codes.......................................... 38
  265.      25  ERRACK Command Format................................ 40
  266.      26  WRITE Command Format................................. 42
  267.      27  READ Command Format.................................. 44
  268.      28  DATA Response Format................................. 46
  269.      29  READ_DONE Reply Format............................... 47
  270.      30  MOVE Command Format.................................. 49
  271.      31  MOVE_DATA Response Format............................ 51
  272.      32  MOVE_DONE Reply Format............................... 52
  273.      33  REPEAT_DATA Command Format........................... 54
  274.      34  WRITE_MASK Format.................................... 56
  275.      35  START Command Format................................. 60
  276.      36  STOP Command Format.................................. 61
  277.      37  CONTINUE Command Format.............................. 62
  278.      38  STEP Command Format.................................. 63
  279.      39  REPORT Command Format................................ 64
  280.      40  STATUS Reply Format.................................. 65
  281.      41  EXCEPTION Format..................................... 66
  282.      42  CREATE Command Format................................ 70
  283.  
  284.  
  285.  
  286.      Page iv
  287.  
  288.  
  289.  
  290.  
  291.  
  292.  
  293.  
  294.      43  Create Types......................................... 71
  295.      44  CREATE BREAKPOINT Format............................. 71
  296.      45  CREATE MEMORY_OBJECT Format.......................... 73
  297.      46  CREATE_DONE Reply Format............................. 74
  298.      47  DELETE Command Format................................ 75
  299.      48  DELETE_DONE Reply Format............................. 76
  300.      49  LIST_ADDRESSES Command Format........................ 77
  301.      50  ADDRESS_LIST Reply Format............................ 78
  302.      51  LIST_BREAKPOINTS Command Format...................... 80
  303.      52  BREAKPOINT_LIST Reply Format......................... 81
  304.      53  LIST_PROCESSES Command Format........................ 82
  305.      54  PROCESS_LIST Reply Format............................ 84
  306.      55  LIST_NAMES Command Format............................ 85
  307.      56  NAME_LIST Reply Format............................... 86
  308.      57  GET_PHYS_ADDR Command Format......................... 88
  309.      58  GOT_PHYS_ADDR Reply Format........................... 89
  310.      59  GET_OBJECT Command Format............................ 90
  311.      60  GOT_OBJECT Reply Format.............................. 91
  312.      61  Commands to Manipulate Breakpoints................... 93
  313.      62  Breakpoint Conditional Command Lists................. 95
  314.      63  BREAKPOINT_DATA Command Format....................... 96
  315.      64  Breakpoint Data Stream Format........................ 97
  316.      65  Conditional Command Summary.......................... 99
  317.      66  Condition Command Header............................ 101
  318.      67  COUNT Condition Format.............................. 101
  319.      68  CHANGED Condition................................... 102
  320.      69  COMPARE Condition................................... 104
  321.      70  TEST Condition...................................... 106
  322.      71  Breakpoint Command Summary.......................... 109
  323.      72  INCREMENT Command Format............................ 110
  324.      73  INC_COUNT Command Format............................ 111
  325.      74  OR Command Format................................... 111
  326.      75  SET_PTR Command Format.............................. 112
  327.      76  SET_STATE Command Format............................ 113
  328.      77  Sample Diagram...................................... 115
  329.      78  Command Summary..................................... 118
  330.      79  Commands, Responses and Replies..................... 122
  331.  
  332.  
  333.  
  334.  
  335.  
  336.  
  337.  
  338.  
  339.  
  340.  
  341.  
  342.  
  343.  
  344.                                                                 Page v
  345.  
  346.  
  347.  
  348.  
  349.  
  350.  
  351.  
  352.                                  CHAPTER 1
  353.  
  354.  
  355.                                Introduction
  356.  
  357.  
  358.  
  359.           The Loader-Debugger Protocol (LDP) is an  application  layer
  360.      protocol   for  loading, dumping  and  debugging  target machines
  361.      from hosts in a network environment.  This protocol  is  designed
  362.      to  accommodate a variety  of  target  cpu  types.  It provides a
  363.      powerful set of debugging services.  At  the  same  time,  it  is
  364.      structured  so  that  a  simple  subset  may  be  implemented  in
  365.      applications like boot  loading   where efficiency and space  are
  366.      at a premium.
  367.  
  368.  
  369.           The authors would like  to  thank  Dan  Franklin  and  Peter
  370.      Cudhea  for providing many of the ideas on which this protocol is
  371.      based.
  372.  
  373.  
  374.  
  375.  
  376.      1.1  Purpose of This Document
  377.  
  378.           This is a technical specification for the LDP protocol.   It
  379.      is intended to be comprehensive enough to be used by implementors
  380.      of the  protocol.   It  contains  detailed  descriptions  of  the
  381.      formats  and usage of over forty commands.  Readers interested in
  382.      an overview of LDP should read the Summary  of  Features,  below,
  383.      and  skim  Sections  2  through  3.1.   Also  see Appendix B, the
  384.      Command Summary.  The remainder of the document reads  best  when
  385.      accompanied by strong coffee or tea.
  386.  
  387.  
  388.  
  389.  
  390.  
  391.  
  392.  
  393.  
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.  
  401.  
  402.  
  403.                                                                 Page 1
  404.  
  405.  
  406.  
  407.      RFC-909                                                 July 1984
  408.  
  409.  
  410.  
  411.      1.2  Summary of Features
  412.  
  413.           LDP has the following features:
  414.  
  415.           o   commands to perform loading, dumping and debugging
  416.  
  417.           o   support for multiple connections to a single target
  418.  
  419.           o   reliable performance in an internet environment
  420.  
  421.           o   a small protocol subset for target loaders
  422.  
  423.           o   addressing  modes  and  commands  to  support   multiple
  424.               machine types
  425.  
  426.           o   breakpoints and watchpoints  which  run  in  the  target
  427.               machine.
  428.  
  429.  
  430.  
  431.  
  432.  
  433.  
  434.  
  435.  
  436.  
  437.  
  438.  
  439.  
  440.  
  441.  
  442.  
  443.  
  444.  
  445.  
  446.  
  447.  
  448.  
  449.  
  450.  
  451.  
  452.  
  453.  
  454.  
  455.  
  456.  
  457.  
  458.  
  459.  
  460.  
  461.      Page 2
  462.  
  463.  
  464.  
  465.      LDP Specification                             General Description
  466.  
  467.  
  468.  
  469.                                  CHAPTER 2
  470.  
  471.  
  472.                             General Description
  473.  
  474.  
  475.  
  476.      2.1  Motivation
  477.  
  478.           LDP is an  application  protocol  that  provides  a  set  of
  479.      commands  used  by  application programs for loading, dumping and
  480.      debugging target machines across a network.
  481.  
  482.           The goals of this protocol are shown in the following list:
  483.  
  484.  
  485.           o   The protocol should support various processor types  and
  486.               operating  systems.   Overhead  and complexity should be
  487.               minimized for simpler cases.
  488.  
  489.  
  490.           o   The protocol should provide support for applications  in
  491.               which  more  than  one  user  can  debug the same target
  492.               machine.  This implies an underlying transport mechanism
  493.               that supports multiple connections between a host-target
  494.               pair.
  495.  
  496.  
  497.           o   LDP should have a minimal subset of  commands  for  boot
  498.               loading  and dumping.  Target machine implementations of
  499.               these applications are often restricted in the amount of
  500.               code-space  they  may  take.   The  services  needed for
  501.               loading and dumping  should  be  provided  in  a  small,
  502.               easily implemented set of commands.
  503.  
  504.  
  505.           o   There should be a means for communicating exceptions and
  506.               errors from the target LDP process to the host process.
  507.  
  508.  
  509.           o   LDP should allow the application to implement a full set
  510.               of debugging functions without crippling the performance
  511.               of the target's application (i.e., PSN,  PAD,  gateway).
  512.               For  example,  a  breakpoint  mechanism  that  halts the
  513.               target machine while breakpoint commands are  sent  from
  514.               the  host  to the target is of limited usefulness, since
  515.               the target will  be  unable  to  service  the  real-time
  516.  
  517.  
  518.  
  519.                                                                 Page 3
  520.  
  521.  
  522.  
  523.      RFC-909                                                 July 1984
  524.  
  525.  
  526.  
  527.               demands of its application.
  528.  
  529.  
  530.  
  531.      2.2  Relation to Other Protocols
  532.  
  533.           LDP is an application protocol that fits  into  the  layered
  534.      internet  protocol environment. Figure 1 illustrates the place of
  535.      LDP in the protocol hierarchy.
  536.  
  537.  
  538.  
  539.  
  540.  
  541.                   +------------------------------+
  542.                   |              LDP             |        Application
  543.                   +------------------------------+        Layer
  544.                         |                  |
  545.                         |                  |
  546.                         |                  |
  547.                   +---------+          +---------+
  548.                   |   RDP   |    or    |  TCP    |        Transport Layer
  549.                   +---------+          +---------+
  550.                     | or |                |
  551.                     |    |                |
  552.                     |  +--------------------+
  553.                     |  |  Internet Protocol |             Internetwork
  554.                     |  +--------------------+             Layer
  555.                     |              |
  556.                   +------------------------------+
  557.                   |    Network Access Protocol   |        Network Layer
  558.                   +------------------------------+
  559.  
  560.  
  561.                         Relation to Other Protocols
  562.                                  Figure 1
  563.  
  564.  
  565.  
  566.  
  567.  
  568.  
  569.  
  570.  
  571.  
  572.  
  573.  
  574.  
  575.  
  576.  
  577.      Page 4
  578.  
  579.  
  580.  
  581.      LDP Specification                             General Description
  582.  
  583.  
  584.  
  585.      2.2.1  Transport Service Requirements
  586.  
  587.           LDP requires that the underlying transport layer:
  588.  
  589.  
  590.  
  591.           o   allow connections to be opened by specifying  a  network
  592.               (or  internet)  address.   Support  passive  and  active
  593.               opens.
  594.  
  595.           o   for each connection, specify the maximum message size.
  596.  
  597.           o   provide a mechanism for sending and  receiving  messages
  598.               over an open connection.
  599.  
  600.           o   deliver messages reliably and in sequence
  601.  
  602.           o   support multiple connections, and  distinguish  messages
  603.               associated  with  different connections.  This is only a
  604.               requirement where LDP is  expected  to  support  several
  605.               users at the same time.
  606.  
  607.           o   explictly return the outcome (success/failure)  of  each
  608.               request  (open,  send,  receive), and provide a means of
  609.               querying the  status  of  a  connection  (unacknowledged
  610.               message count, etc.).
  611.  
  612.  
  613.           Data is passed from the application program to the LDP  user
  614.      process  in  the  form of commands.  In the case of an LDP server
  615.      process, command responses originate in LDP itself.  Below LDP is
  616.      the  transport  protocol.  The  Reliable  Data  Protocol  (RDP --
  617.      RFC 908) is the recommended transport procotol.  Data  is  passed
  618.      across  the  LDP/RDP interface in the form of messages.  (TCP may
  619.      be used in place of RDP, but it will be  less  efficient  and  it
  620.      will  require  more  resources  to implement.)  An internet layer
  621.      (IP) normally comes between RDP and the network  layer,  but  RDP
  622.      may exchange data packets directly with the network layer.
  623.  
  624.           Figure  2  shows  the  flow  of  data  across  the  protocol
  625.      interfaces:
  626.  
  627.  
  628.  
  629.  
  630.  
  631.  
  632.  
  633.  
  634.  
  635.                                                                 Page 5
  636.  
  637.  
  638.  
  639.      RFC-909                                                 July 1984
  640.  
  641.  
  642.  
  643.  
  644.  
  645.                                +------+
  646.                                |      |
  647.                                |Appli-|
  648.                                |cation|
  649.                                |      |
  650.                                +------+
  651.                                   ^
  652.                        Commands   |
  653.                                   V
  654.                                +------+
  655.                                |      |
  656.                                | LDP  |
  657.                                |      |
  658.                                +------+
  659.                                   ^
  660.                        Messages   |
  661.                                   V
  662.                                +-----+
  663.                                |     |
  664.                                | RDP |
  665.                                |     |
  666.                                +-----+
  667.                                   ^
  668.                        Segments   |
  669.                                   V
  670.                                 +----+
  671.                                 |    |
  672.                                 | IP |
  673.                                 |    |
  674.                                 +----+
  675.                                   ^
  676.                        Datagrams  |
  677.                                   V
  678.                               ?  *     !
  679.                            $  =      ^   +
  680.                              *
  681.                           >    Internet
  682.                             ,            ?
  683.                                  !    )
  684.                               *   %     $
  685.  
  686.  
  687.                    Form of Data Exchange Between Layers
  688.                                  Figure 2
  689.  
  690.  
  691.  
  692.  
  693.      Page 6
  694.  
  695.  
  696.  
  697.      LDP Specification                             General Description
  698.  
  699.  
  700.  
  701.  
  702.  
  703.  
  704.  
  705.  
  706.  
  707.  
  708.  
  709.  
  710.  
  711.  
  712.  
  713.  
  714.  
  715.  
  716.  
  717.  
  718.  
  719.  
  720.  
  721.  
  722.  
  723.  
  724.  
  725.  
  726.  
  727.  
  728.  
  729.  
  730.  
  731.  
  732.  
  733.  
  734.  
  735.  
  736.  
  737.  
  738.  
  739.  
  740.  
  741.  
  742.  
  743.  
  744.  
  745.  
  746.  
  747.  
  748.  
  749.  
  750.  
  751.                                                                 Page 7
  752.  
  753.  
  754.  
  755.      RFC-909                                                 July 1984
  756.  
  757.  
  758.  
  759.  
  760.  
  761.  
  762.  
  763.  
  764.  
  765.  
  766.  
  767.  
  768.  
  769.  
  770.  
  771.  
  772.  
  773.  
  774.  
  775.  
  776.  
  777.  
  778.  
  779.  
  780.  
  781.  
  782.  
  783.  
  784.  
  785.  
  786.  
  787.  
  788.  
  789.  
  790.  
  791.  
  792.  
  793.  
  794.  
  795.  
  796.  
  797.  
  798.  
  799.  
  800.  
  801.  
  802.  
  803.  
  804.  
  805.  
  806.  
  807.  
  808.  
  809.      Page 8
  810.  
  811.  
  812.  
  813.      LDP Specification                              Protocol Operation
  814.  
  815.  
  816.  
  817.                                  CHAPTER 3
  818.  
  819.  
  820.                             Protocol Operation
  821.  
  822.  
  823.  
  824.      3.1  Overview
  825.  
  826.           An LDP session consists  of  an  exchange  of  commands  and
  827.      responses  between an LDP user process and an LDP server process.
  828.      Normally,  the  user  process  resides  on  a  host  machine   (a
  829.      timesharing  computer  used  for network monitoring and control),
  830.      and the server process resides on a  target  machine  (PSN,  PAD,
  831.      gateway,  etc.).   Throughout  this document, host and target are
  832.      used  as  synonyms  for  user   process   and   server   process,
  833.      respectively,  although  in  some implementations (the Butterfly,
  834.      for example) this  correspondence  may  be  reversed.   The  host
  835.      controls  the  session  by  sending commands to the target.  Some
  836.      commands elicit responses, and all commands may elicit  an  error
  837.      reply.
  838.  
  839.           The protocol contains five classes  of  commands:  protocol,
  840.      data  transfer,  management,   control  and breakpoint.  Protocol
  841.      commands are used to verify the command sequencing mechanism  and
  842.      to handle erroneous commands.  Data transfer commands involve the
  843.      transfer of data from one place to another, such  as  for  memory
  844.      examine/deposit,  or  loading.  Management  commands are used for
  845.      creating   and   deleting   objects   (processes,    breakpoints,
  846.      watchpoints,  etc.)  in the target machine.  Control commands are
  847.      used to control the execution of  target  code  and  breakpoints.
  848.      Breakpoint commands are used to control the execution of commands
  849.      inside breakpoints and watchpoints.
  850.  
  851.  
  852.  
  853.      3.2  Session Management
  854.  
  855.           An LDP session consists of a series of commands sent from  a
  856.      host  LDP  to  a  target  LDP,  some  of which may be followed by
  857.      responses from the target.  A session begins when a host opens  a
  858.      transport  connection to a target listening on a well known port.
  859.      LDP uses RDP port number zzz or TCP port number  yyy.   When  the
  860.      connection  has been established, the host sends a HELLO command,
  861.      and the target  replies  with  a  HELLO_REPLY.   The  HELLO_REPLY
  862.      contains  parameters that describe the target's implementation of
  863.      LDP, including protocol  version,  implementation  level,  system
  864.  
  865.  
  866.  
  867.                                                                 Page 9
  868.  
  869.  
  870.  
  871.      RFC-909                                                 July 1984
  872.  
  873.  
  874.  
  875.      type,  and  address format.  The session terminates when the host
  876.      closes the underlying  transport  connection.   When  the  target
  877.      detects  that the transport connection has been closed, it should
  878.      deallocate any resources dedicated to the session.
  879.  
  880.           The target process is the passive partner in an LDP session,
  881.      and  it  waits for the host process to terminate the session.  As
  882.      an implementation consideration, either LDP  or  the   underlying
  883.      transport  protocol  in  the  target  should  have  a  method for
  884.      detecting if the host process  has  died.   Otherwise,   an   LDP
  885.      target  that  supported  only  one  connection  could be rendered
  886.      useless by a host that crashed in the  middle of a session.   The
  887.      problem  of  detecting  half-dead  connections  can be avoided by
  888.      taking a different tack:  the target could allow new  connections
  889.      to  usurp  inactive  connections.  A  connection with no activity
  890.      could be declared 'dead', but would  not  be  usurped  until  the
  891.      connection  resource  was  needed.   However,  this  would  still
  892.      require the transport layer to support two  connection  channels:
  893.      one  to  receive  connection  requests, and another to use for an
  894.      active connection.
  895.  
  896.  
  897.  
  898.  
  899.      3.3  Command Sequencing
  900.  
  901.           Each command sent from the host to the target has a sequence
  902.      number.   The  sequence  number is used by the target to refer to
  903.      the command in normal replies and error replies.  To save  space,
  904.      these  numbers  are  not  actually  included  in  host  commands.
  905.      Instead, each command sent from the host is assigned an  implicit
  906.      sequence  number.   The  sequence  number  starts  at zero at the
  907.      beginning of the LDP  session  and  increases  by  one  for  each
  908.      command sent.  The host and target each keep track of the current
  909.      number.  The SYNCH <sequence number> command may be used  by  the
  910.      host to synchronize the sequence number.
  911.  
  912.  
  913.  
  914.  
  915.  
  916.      3.4  Data Packing and Transmission
  917.  
  918.           The convention for the order of data packing was chosen  for
  919.      its  simplicity:  data  are packed most significant bit first, in
  920.      order of increasing target address, into  eight-bit  octets.  The
  921.      octets of packed data are transmitted in sequential order.
  922.  
  923.  
  924.  
  925.      Page 10
  926.  
  927.  
  928.  
  929.      LDP Specification                              Protocol Operation
  930.  
  931.  
  932.  
  933.           Data are always packed according to the  address  format  of
  934.      the  target  machine.   For  example, in an LDP session between a
  935.      20-bit host and  a  16-bit  target,  16-bit  words  (packed  into
  936.      octets)   are  transmitted  in  both  directions.   For  ease  of
  937.      discussion, targets are treated here  as  if  they  have  uniform
  938.      address  spaces.  In practice, the size of address units may vary
  939.      within a target -- 16-bit macromemory, 32-bit micromemory, 10-bit
  940.      dispatch  memory,  etc.   Data packing between host and target is
  941.      tailored to the units of the current target address space.
  942.  
  943.           Figures showing the packing of data for targets with various
  944.      address  unit  sizes  are given below.  The order of transmission
  945.      with respect to the diagrams is top to bottom.  Bit numbering  in
  946.      the  following diagrams refers to significance in the octet:  bit
  947.      zero  is  the  least  significant  bit  in  an  octet.   For   an
  948.      explanation  of  the bit numbering convention that applies in the
  949.      rest of this document, please see Appendix A.
  950.  
  951.           The packing of data for targets with word lengths  that  are
  952.      multiples   of  8  is  straightforward.   The  following  diagram
  953.      illustrates 16-bit packing:
  954.  
  955.  
  956.  
  957.                           7                               0
  958.                           ---------------------------------
  959.                Octet 0    |      WORD 0 bits 15-08        |
  960.                           ---------------------------------
  961.                Octet 1    |      WORD 0 bits 07-00        |
  962.                           ---------------------------------
  963.                Octet 2    |      WORD 1 bits 15-08        |
  964.                           ---------------------------------
  965.                Octet 3    |      WORD 1 bits 07-00        |
  966.                           ---------------------------------
  967.                                         *
  968.                                         *
  969.                                         *
  970.                           ---------------------------------
  971.                Octet 2n-1 |      WORD n bits 07-00        |
  972.                           ---------------------------------
  973.  
  974.  
  975.                           Packing of 16-bit Words
  976.                                  Figure 3
  977.  
  978.  
  979.  
  980.  
  981.  
  982.  
  983.                                                                Page 11
  984.  
  985.  
  986.  
  987.      RFC-909                                                 July 1984
  988.  
  989.  
  990.  
  991.      Packing  for  targets  with  peculiar  word   lengths   is   more
  992.      complicated.   For  20-bit  machines,  2 words of data are packed
  993.      into  5  octets.   When  an  odd  number  of  20-bit  words   are
  994.      transmitted,  the  partially used octet is included in the length
  995.      of the command, and the octet is padded to the right with zeroes.
  996.  
  997.  
  998.  
  999.                           7                               0
  1000.                           ---------------------------------
  1001.                Octet 0    |      WORD 0 bits 19-12        |
  1002.                           ---------------------------------
  1003.                Octet 1    |      WORD 0 bits 11-04        |
  1004.                           ---------------------------------
  1005.                Octet 2    |  WORD 0 03-00 |  WORD 1 19-16 |
  1006.                           ---------------------------------
  1007.                Octet 3    |      WORD 1 bits 15-08        |
  1008.                           ---------------------------------
  1009.                Octet 4    |      WORD 1 bits 07-00        |
  1010.                           ---------------------------------
  1011.  
  1012.  
  1013.                           Packing of 20-bit Words
  1014.                                  Figure 4
  1015.  
  1016.  
  1017.  
  1018.  
  1019.  
  1020.  
  1021.  
  1022.      3.5  Implementations
  1023.  
  1024.           A subset of LDP commands may be implemented in targets where
  1025.      machine  resources  are  limited and the full capabilities of LDP
  1026.      are  not  needed.  There  are  three  basic  levels   of   target
  1027.      implementations:       LOADER_DUMPER,      BASIC_DEBUGGER     and
  1028.      FULL_DEBUGGER.  The target communicates  its  LDP  implementation
  1029.      level  to the host during session initiation.  The implementation
  1030.      levels are described below:
  1031.  
  1032.  
  1033.  
  1034.  
  1035.  
  1036.  
  1037.  
  1038.  
  1039.  
  1040.  
  1041.      Page 12
  1042.  
  1043.  
  1044.  
  1045.      LDP Specification                              Protocol Operation
  1046.  
  1047.  
  1048.  
  1049.      LOADER_DUMPER
  1050.  
  1051.           Used  for   loading/dumping    of   the   target    machine.
  1052.           Includes   all  protocol   class  commands and replies; data
  1053.           transfer commands READ, WRITE,  MOVE  and  their  responses;
  1054.           control   command   START  and  control  reply    EXCEPTION.
  1055.           Understands at least PHYS_MACRO and HOST  addressing  modes;
  1056.           others if desired.
  1057.  
  1058.      BASIC_DEBUGGER
  1059.  
  1060.           Implements  LOADER_DUMPER  commands,  all  control commands,
  1061.           all  addressing modes appropriate to the target machine, but
  1062.           does  not  have finite state machine  (FSM)  breakpoints  or
  1063.           watchpoints.   Default  breakpoints  are  implemented.   The
  1064.           target understands long addressing mode.
  1065.  
  1066.      FULL_DEBUGGER
  1067.  
  1068.           Implements all commands and addressing modes appropriate  to
  1069.           the   target  machine,  and  includes  breakpoint  commands,
  1070.           conditional commands and BREAKPOINT_DATA.   Watchpoints  are
  1071.           optional.
  1072.  
  1073.  
  1074.  
  1075.  
  1076.  
  1077.  
  1078.  
  1079.  
  1080.  
  1081.  
  1082.  
  1083.  
  1084.  
  1085.  
  1086.  
  1087.  
  1088.  
  1089.  
  1090.  
  1091.  
  1092.  
  1093.  
  1094.  
  1095.  
  1096.  
  1097.  
  1098.  
  1099.                                                                Page 13
  1100.  
  1101.  
  1102.  
  1103.      RFC-909                                                 July 1984
  1104.  
  1105.  
  1106.  
  1107.  
  1108.  
  1109.  
  1110.  
  1111.  
  1112.  
  1113.  
  1114.  
  1115.  
  1116.  
  1117.  
  1118.  
  1119.  
  1120.  
  1121.  
  1122.  
  1123.  
  1124.  
  1125.  
  1126.  
  1127.  
  1128.  
  1129.  
  1130.  
  1131.  
  1132.  
  1133.  
  1134.  
  1135.  
  1136.  
  1137.  
  1138.  
  1139.  
  1140.  
  1141.  
  1142.  
  1143.  
  1144.  
  1145.  
  1146.  
  1147.  
  1148.  
  1149.  
  1150.  
  1151.  
  1152.  
  1153.  
  1154.  
  1155.  
  1156.  
  1157.      Page 14
  1158.  
  1159.  
  1160.  
  1161.      LDP Specification                            Commands and Formats
  1162.  
  1163.  
  1164.  
  1165.                                  CHAPTER 4
  1166.  
  1167.  
  1168.                            Commands and Formats
  1169.  
  1170.  
  1171.  
  1172.      4.1  Packet Format
  1173.  
  1174.           LDP commands are enclosed in RDP transport messages.  An RDP
  1175.      message  may contain more than one command, but each command must
  1176.      fit entirely within a single message.  Network packets containing
  1177.      LDP commands have the format shown in Figure 5.
  1178.  
  1179.  
  1180.                       +----------------+
  1181.                       |  Local Network |
  1182.                       |    Header(s)   |
  1183.                       +----------------+
  1184.                       |   IP Header    |
  1185.                       +----------------+
  1186.                       |   RDP Header   |
  1187.                       +----------------+     +-+
  1188.                       |   LDP Command  |      |
  1189.                       |   Header       |      |
  1190.                       +----------------+      |
  1191.                       |   Optional     |      |
  1192.                       .   LDP          .      | LDP Command
  1193.                       .   Data         .      | Format
  1194.                       |                |      |
  1195.                       +----------------+      |
  1196.                       |   LDP Padding  |      |
  1197.                       +----------------+     +-+
  1198.                       |   Additional   |
  1199.                       .   LDP          .
  1200.                       .   Commands     .
  1201.                       .                .
  1202.                       +----------------+
  1203.  
  1204.  
  1205.                            Network Packet Format
  1206.                                  Figure 5
  1207.  
  1208.  
  1209.  
  1210.  
  1211.  
  1212.  
  1213.  
  1214.  
  1215.                                                                Page 15
  1216.  
  1217.  
  1218.  
  1219.      RFC-909                                                 July 1984
  1220.  
  1221.  
  1222.  
  1223.      4.2  Command Format
  1224.  
  1225.           LDP commands consist of a standard two-word header  followed
  1226.      optionally  by  additional data.  To facilitate parsing of multi-
  1227.      command messages, all commands contain an even number of  octets.
  1228.      Commands that contain an odd number of data octets must be padded
  1229.      with a null octet.
  1230.  
  1231.           The commands defined by the LDP specification  are  intended
  1232.      to  be of universal application to provide a common basis for all
  1233.      implementations.  Command class and type codes from 0 to 63.  are
  1234.      reserved  by the protocol.  Codes above 63. are available for the
  1235.      implementation of target-specific commands.
  1236.  
  1237.  
  1238.  
  1239.  
  1240.      4.2.1  Command Header
  1241.  
  1242.           LDP commands begin with a fixed length header.   The  header
  1243.      specifies the type of command and its length in octets.
  1244.  
  1245.  
  1246.                        0             0 0   1         1
  1247.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  1248.                       +---------------+---------------+
  1249.                     0 |     Command Length (octets)   |
  1250.                       +---------------+---------------+
  1251.                     1 | Command Class | Command Type  |
  1252.                       +---------------+---------------+
  1253.  
  1254.  
  1255.                          LDP Command Header Format
  1256.                                  Figure 6
  1257.  
  1258.  
  1259.      HEADER FIELDS:
  1260.  
  1261.      Command Length
  1262.  
  1263.           The command length gives the total number of octets  in  the
  1264.           command,  including the length field and data, and excluding
  1265.           padding.
  1266.  
  1267.      Command Class
  1268.      Command Type
  1269.  
  1270.  
  1271.  
  1272.  
  1273.      Page 16
  1274.  
  1275.  
  1276.  
  1277.      LDP Specification                            Commands and Formats
  1278.  
  1279.  
  1280.  
  1281.           The command class and type  together  specify  a  particular
  1282.           command.   The  class selects one of six command categories,
  1283.           and the type gives the command within  that  category.   All
  1284.           codes are decimal.  The symbols given in Figures 7 and 8 for
  1285.           command classes and types are used in the remainder of  this
  1286.           document for reference.
  1287.  
  1288.           The command classes that have been defined are:
  1289.  
  1290.  
  1291.                      Command Class  |  Symbol
  1292.                     ----------------+-----------
  1293.                             1       | PROTOCOL
  1294.                             2       | DATA_TRANSFER
  1295.                             3       | CONTROL
  1296.                             4       | MANAGEMENT
  1297.                             5       | BREAKPOINT
  1298.                             6       | CONDITION
  1299.                             7 - 63  | <reserved>
  1300.  
  1301.  
  1302.                               Command Classes
  1303.                                  Figure 7
  1304.  
  1305.  
  1306.           Command  type  codes  are  assigned  in  order  of  expected
  1307.           frequency  of use.  Commands and their responses/replies are
  1308.           numbered  sequentially.   The  command  types,  ordered   by
  1309.           command class, are:
  1310.  
  1311.  
  1312.  
  1313.  
  1314.  
  1315.  
  1316.  
  1317.  
  1318.  
  1319.  
  1320.  
  1321.  
  1322.  
  1323.  
  1324.  
  1325.  
  1326.  
  1327.  
  1328.  
  1329.  
  1330.  
  1331.                                                                Page 17
  1332.  
  1333.  
  1334.  
  1335.      RFC-909                                                 July 1984
  1336.  
  1337.  
  1338.  
  1339.  
  1340.  
  1341.                      Command Class  |  Command Type | Symbol
  1342.                     ----------------+---------------+----------
  1343.                       PROTOCOL      |       1       | HELLO
  1344.                                     |       2       | HELLO_REPLY
  1345.                                     |       3       | SYNCH
  1346.                                     |       4       | SYNCH_REPLY
  1347.                                     |       5       | ERROR
  1348.                                     |       6       | ERRACK
  1349.                                     |       7       | ABORT
  1350.                                     |       8       | ABORT_DONE
  1351.                                     |       9 - 63  | <reserved>
  1352.                                     |               |
  1353.                       DATA_TRANSFER |       1       | WRITE
  1354.                                     |       2       | READ
  1355.                                     |       3       | READ_DONE
  1356.                                     |       4       | READ_DATA
  1357.                                     |       5       | MOVE
  1358.                                     |       6       | MOVE_DONE
  1359.                                     |       7       | MOVE_DATA
  1360.                                     |       8       | REPEAT_DATA
  1361.                                     |       9       | BREAKPOINT_DATA
  1362.                                     |       10      | WRITE_MASK
  1363.                                     |       11 - 63 | <reserved>
  1364.                                     |               |
  1365.                       CONTROL       |       1       | START
  1366.                                     |       2       | STOP
  1367.                                     |       3       | CONTINUE
  1368.                                     |       4       | STEP
  1369.                                     |       5       | REPORT
  1370.                                     |       6       | STATUS
  1371.                                     |       7       | EXCEPTION
  1372.                                     |       8 - 63  | <reserved>
  1373.                                     |               |
  1374.                       MANAGEMENT    |       1       | CREATE
  1375.                                     |       2       | CREATE_DONE
  1376.                                     |       3       | DELETE
  1377.                                     |       4       | DELETE_DONE
  1378.                                     |       5       | LIST_ADDRESSES
  1379.                                     |       6       | ADDRESS_LIST
  1380.                                     |       7       | GET_PHYS_ADDRESS
  1381.                                     |       8       | GOT_PHYS_ADDRESS
  1382.                                     |       9       | GET_OBJECT
  1383.                                     |       10      | GOT_OBJECT
  1384.                                     |       11      | LIST_BREAKPOINTS
  1385.                                     |       12      | BREAKPOINT_LIST
  1386.  
  1387.  
  1388.  
  1389.      Page 18
  1390.  
  1391.  
  1392.  
  1393.      LDP Specification                            Commands and Formats
  1394.  
  1395.  
  1396.  
  1397.                                     |       13      | LIST_NAMES
  1398.                                     |       14      | NAME_LIST
  1399.                                     |       15      | LIST_PROCESSES
  1400.                                     |       16      | PROCESS_LIST
  1401.                                     |       17 - 63 | <reserved>
  1402.                                     |               |
  1403.                       BREAKPOINT    |       1       | INCREMENT
  1404.                                     |       2       | INC_COUNT
  1405.                                     |       3       | OR
  1406.                                     |       4       | SET_PTR
  1407.                                     |       5       | SET_STATE
  1408.                                     |       6 - 63  | <reserved>
  1409.                                     |               |
  1410.                       CONDITION     |       1       | CHANGED
  1411.                                     |       2       | COMPARE
  1412.                                     |       3       | COUNT_EQ
  1413.                                     |       4       | COUNT_GT
  1414.                                     |       5       | COUNT_LT
  1415.                                     |       6       | TEST
  1416.                                     |       7 - 63  | <reserved>
  1417.  
  1418.  
  1419.                                Command Types
  1420.                                  Figure 8
  1421.  
  1422.  
  1423.  
  1424.  
  1425.  
  1426.      4.3  Addressing
  1427.  
  1428.           Addresses are used  in  LDP  commands  to  refer  to  memory
  1429.      locations,  processes,  buffers,  breakpoints and other entities.
  1430.      Many of these entities are machine-dependent; some machines  have
  1431.      named  objects,  some  machines have multiple address spaces, the
  1432.      size of address spaces varies, etc.  The  format  for  specifying
  1433.      addresses  needs  to  be  general  enough  to handle all of these
  1434.      cases.   This  speaks  for  a  large,  hierarchically  structured
  1435.      address  format.   However, the disadvantage of a large format is
  1436.      that it imposes extra overhead on communication with targets that
  1437.      have simpler address schemes.
  1438.  
  1439.           LDP resolves this conflict by employing two address formats:
  1440.      a  short  three-word format for addressing simpler targets, and a
  1441.      long five-word format for others.  Each target LDP is required to
  1442.      implement  at least one of these formats.  At the start of an LDP
  1443.      session, the target specifies the address format(s)  it  uses  in
  1444.  
  1445.  
  1446.  
  1447.                                                                Page 19
  1448.  
  1449.  
  1450.  
  1451.      RFC-909                                                 July 1984
  1452.  
  1453.  
  1454.  
  1455.      the  Flag field of the HELLO_REPLY message.  In each address, the
  1456.      first bit of the mode octet is a format flag:  0  indicates  LONG
  1457.      address format, and 1 indicates SHORT format.
  1458.  
  1459.  
  1460.  
  1461.  
  1462.      4.3.1  Long Address Format
  1463.  
  1464.           The long address format is five words long and consists of a
  1465.      three-word  address  descriptor and a two-word offset (see Figure
  1466.      9). The descriptor specifies an address space to which the offset
  1467.      is applied.  The descriptor is subdivided into several fields, as
  1468.      described below.  The structuring of the descriptor  is  designed
  1469.      to  support  complex  addressing  modes.  For example, on targets
  1470.      with  multiple  processes,  descriptors  may  reference   virtual
  1471.      addresses,  registers,  and  other  entities  within a particular
  1472.      process.
  1473.  
  1474.           The addressing modes defined below are intended as a base to
  1475.      which  target-specific  modes  may be added.  Modes up to 63. are
  1476.      reserved by the protocol.  The range 64. to 127. may be used  for
  1477.      target-specific address modes.
  1478.  
  1479.  
  1480.                Long Format - Format bit is LONG=0
  1481.  
  1482.                 0             0 0   1         1
  1483.                 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  1484.                +-------------------------------+  +-+
  1485.                |0|       Mode  |  Mode Arg     |   |
  1486.                +-------------------------------+   |
  1487.                |                    (31-16)    |   | Descriptor
  1488.                +----          ID            ---+   |
  1489.                |                    (15-0)     |   |
  1490.                +-------------------------------+  +-+
  1491.                |                    (31-16)    |   |
  1492.                +----        Offset          ---+   | Offset
  1493.                |                    (15-0)     |   |
  1494.                +-------------------------------+  +-+
  1495.  
  1496.  
  1497.                             Long Address Format
  1498.                                  Figure 9
  1499.  
  1500.  
  1501.      LONG ADDRESS FIELDS:
  1502.  
  1503.  
  1504.  
  1505.      Page 20
  1506.  
  1507.  
  1508.  
  1509.      LDP Specification                            Commands and Formats
  1510.  
  1511.  
  1512.  
  1513.      Mode
  1514.  
  1515.           The address mode identifies the type of address space  being
  1516.           referenced.   The mode is qualified by the mode argument and
  1517.           the ID field.  Implementation of modes other  than  physical
  1518.           and  host is machine-dependent.  Currently defined modes and
  1519.           the address space they reference are shown in Figure 10.
  1520.  
  1521.  
  1522.           Mode | Symbol               | Address space
  1523.           -----+----------------------+---------------------------
  1524.  
  1525.             0    HOST                   Host
  1526.             1    PHYS_MACRO             Macromemory
  1527.             2    PHYS_MICRO             Micromemory
  1528.             3    PHYS_I/O               I/O space
  1529.             4    PHYS_MACRO_PTR         Macro contains a pointer
  1530.             5    PHYS_REG               Register
  1531.             6    PHYS_REG_OFFSET        Register plus offset
  1532.             7    PHYS_REG_INDIRECT      Register contains address
  1533.                                         of a pointer
  1534.  
  1535.             8    PROCESS_CODE           Process code space
  1536.             9    PROCESS_DATA           Process data space
  1537.            10    PROCESS_DATA_PTR       Process data contains a ptr
  1538.            11    PROCESS_REG            Process virtual register
  1539.            12    PROCESS_REG_OFFSET     Process register plus offset
  1540.            13    PROCESS_REG_INDIRECT   Process register contains
  1541.                                         address of a pointer
  1542.  
  1543.            14    OBJECT_OFFSET          Memory object (queue, pool)
  1544.            15    OBJECT_HEADER          System header for an object
  1545.            16    BREAKPOINT             Breakpoint
  1546.            17    WATCHPOINT             Watchpoint
  1547.            18    BPT_PTR_OFFSET         Breakpoint ptr plus offset
  1548.            19    BPT_PTR_INDIRECT       Breakpoint ptr plus offset
  1549.                                         gives address of a pointer
  1550.            20 -  <reserved>
  1551.            63
  1552.  
  1553.  
  1554.                             Long Address Modes
  1555.                                  Figure 10
  1556.  
  1557.  
  1558.  
  1559.      Mode Argument
  1560.  
  1561.  
  1562.  
  1563.                                                                Page 21
  1564.  
  1565.  
  1566.  
  1567.      RFC-909                                                 July 1984
  1568.  
  1569.  
  1570.  
  1571.           Provides a numeric argument to the  mode  field.   Specifies
  1572.           the  register  in  physical  and  process REG and REG_OFFSET
  1573.           modes.
  1574.  
  1575.      ID Field
  1576.  
  1577.           Identifies a particular process, buffer or object.
  1578.  
  1579.      Offset
  1580.  
  1581.           The offset into the linear  address  space  defined  by  the
  1582.           mode.  The size of the machine word determines the number of
  1583.           significant bits in the offset.   Likewise,  the  addressing
  1584.           units of the target are the units of the offset.
  1585.  
  1586.      The interpretation of the mode argument, ID field and offset  for
  1587.      each address mode is given below:
  1588.  
  1589.      HOST
  1590.  
  1591.           The ID and offset fields are numbers assigned arbitrarily by
  1592.           the  host  side  of the debugger.  These numbers are used in
  1593.           MOVE and MOVE_DATA messages.  MOVE_DATA responses containing
  1594.           this  mode  as the destination are sent by the target to the
  1595.           host.  This may occur in debugging when data is sent to  the
  1596.           host from the target breakpoint.
  1597.  
  1598.      PHYS_MACRO
  1599.  
  1600.           The  offset  contains  the  32-bit  physical  address  of  a
  1601.           location in macromemory.  The mode argument and ID field are
  1602.           not used.   For  example,  mode=PHYS_MACRO  and  offset=1000
  1603.           specifies location 1000 in physical memory.
  1604.  
  1605.      PHYS_MICRO
  1606.  
  1607.           Like PHYS_MACRO, but the location is in micromemory.
  1608.  
  1609.      PHYS_I/O
  1610.  
  1611.           Like PHYS_MACRO, but the location is in I/O space.
  1612.  
  1613.      PHYS_MACRO_PTR
  1614.  
  1615.           The offset contains the address of a pointer in macromemory.
  1616.           The  location  pointed to (the effective address) is also in
  1617.           macromemory.  The mode argument and ID field are unused.
  1618.  
  1619.  
  1620.  
  1621.      Page 22
  1622.  
  1623.  
  1624.  
  1625.      LDP Specification                            Commands and Formats
  1626.  
  1627.  
  1628.  
  1629.      PHYS_REG
  1630.  
  1631.           The mode argument  gives  the  physical  register.   If  the
  1632.           register  is  used by the LDP target process, then the saved
  1633.           copy from  the  previous  context  is  used.   This  comment
  1634.           applies  to  PHYS_REG_OFFSET  mode as well.  The ID field is
  1635.           not used.
  1636.  
  1637.      PHYS_REG_OFFSET
  1638.  
  1639.           The offset is added to the contents of a register  given  as
  1640.           the mode argument.  The result is used as a physical address
  1641.           in macromemory.  ID is unused.
  1642.  
  1643.      PHYS_REG_INDIRECT
  1644.  
  1645.           The register specified in the mode arg contains the  address
  1646.           of  a  pointer in macromemory.  The effective address is the
  1647.           macromemory location specified  in  the  pointer,  plus  the
  1648.           offset.  The ID field is unused.
  1649.  
  1650.      PROCESS_CODE
  1651.  
  1652.           The ID is a process ID, the offset is into  the  code  space
  1653.           for this process.  Mode argument is not used.
  1654.  
  1655.      PROCESS_DATA
  1656.  
  1657.           The ID is a process ID, the offset is into  the  data  space
  1658.           for  this  process.   Mode argument is not used.  On systems
  1659.           that do not distinguish between code and data  space,  these
  1660.           two  modes are equivalent, and reference the virtual address
  1661.           space of the process.
  1662.  
  1663.      PROCESS_DATA_PTR
  1664.  
  1665.           The offset contains the address of a  pointer  in  the  data
  1666.           space  of  the  process  specified  by the ID.  The location
  1667.           pointed to (the effective  address)  is  also  in  the  data
  1668.           space.  The mode argument is not used.
  1669.  
  1670.      PROCESS_REG
  1671.  
  1672.           Accesses the  registers  (and  other  system  data)  of  the
  1673.           process  given  by the ID field.  Mode argument 0 starts the
  1674.           registers.  After the registers, the  mode  argument  is  an
  1675.           offset into the system area for the process.
  1676.  
  1677.  
  1678.  
  1679.                                                                Page 23
  1680.  
  1681.  
  1682.  
  1683.      RFC-909                                                 July 1984
  1684.  
  1685.  
  1686.  
  1687.      PROCESS_REG_OFFSET
  1688.  
  1689.           The offset plus the contents of the register  given  in  the
  1690.           mode  argument specifies a location in the data space of the
  1691.           process specified by the ID.
  1692.  
  1693.      PROCESS_REG_INDIRECT
  1694.  
  1695.           The register specified in the mode arg contains the  address
  1696.           of  a  pointer in the data space of the process given by the
  1697.           ID.  The effective address is the location in  process  data
  1698.           space specified in the pointer, plus the offset.
  1699.  
  1700.      OBJECT_OFFSET (optional)
  1701.  
  1702.           The offset is into the memory space defined by the object ID
  1703.           in   ID.    Recommended  for  remote  control  of  parameter
  1704.           segments.
  1705.  
  1706.      OBJECT_HEADER (optional)
  1707.  
  1708.           The  offset  is  into  the  system  header  for  the  object
  1709.           specified by the ID.  Intended for use with the Butterfly.
  1710.  
  1711.      BREAKPOINT
  1712.  
  1713.           The descriptor specifies a breakpoint.  The offset is  never
  1714.           used,  this  type  is  only used in descriptors referring to
  1715.           breakpoints.  (See Breakpoints and Watchpoints,  below,  for
  1716.           an explanation of breakpoint descriptors.)
  1717.  
  1718.      WATCHPOINT
  1719.  
  1720.           The descriptor specifies a watchpoint.  The offset is  never
  1721.           used,  this  type  is  only used in descriptors referring to
  1722.           watchpoints.  (See Breakpoints and Watchpoints,  below,  for
  1723.           an explanation of watchpoint descriptors).
  1724.  
  1725.      BPT_PTR_OFFSET
  1726.  
  1727.           For  this  mode  and  BPT_PTR_INDIRECT,  the  mode  argument
  1728.           specifies  one  of two breakpoint pointer variables local to
  1729.           the breakpoint in which this address occurs.  These pointers
  1730.           and  the  SET_PTR command which manipulates them provide for
  1731.           an  arbitrary  amount  of  address  indirection.   They  are
  1732.           intended for use in traversing data structures: for example,
  1733.           chasing queues.  In BPT_PTR_OFFSET, the offset is  added  to
  1734.  
  1735.  
  1736.  
  1737.      Page 24
  1738.  
  1739.  
  1740.  
  1741.      LDP Specification                            Commands and Formats
  1742.  
  1743.  
  1744.  
  1745.           the  pointer  variable  to  give  the effective address.  In
  1746.           targets which support multiple processes, the location is in
  1747.           the  data  space of the process given by the ID.  Otherwise,
  1748.           the  location  is  a  physical  address   in   macro-memory.
  1749.           BPT_PTR.*   modes   are   valid   only  in  breakpoints  and
  1750.           watchpoints.
  1751.  
  1752.      BPT_PTR_INDIRECT
  1753.  
  1754.           Like BPT_PTR_OFFSET, except that it uses one more  level  of
  1755.           indirection.    The  pointer  variable  given  by  the  mode
  1756.           argument plus the offset specify an address which points  to
  1757.           the    effective    address.    See   the   description   of
  1758.           BPT_PTR_OFFSET for a discussion of  usage,  limitations  and
  1759.           address space.
  1760.  
  1761.  
  1762.  
  1763.  
  1764.      4.3.2  Short Address Format
  1765.  
  1766.           The  short  address  format   is   intended   for   use   in
  1767.      implementations  where protocol overhead must be minimized.  This
  1768.      format is a subset of the long address format:  it  contains  the
  1769.      same  fields  except  for  the  ID  field.   Therefore, the short
  1770.      addressing format supports only HOST and  PHYS_*  address  modes.
  1771.      Only  the LOADER_DUMPER implementation level commands may be used
  1772.      with the short addressing format.  The short  address  format  is
  1773.      three  words  long,  consisting  of  a 16-bit word describing the
  1774.      address space, and a 32-bit offset.
  1775.  
  1776.  
  1777.  
  1778.  
  1779.  
  1780.  
  1781.  
  1782.  
  1783.  
  1784.  
  1785.  
  1786.  
  1787.  
  1788.  
  1789.  
  1790.  
  1791.  
  1792.  
  1793.  
  1794.  
  1795.                                                                Page 25
  1796.  
  1797.  
  1798.  
  1799.      RFC-909                                                 July 1984
  1800.  
  1801.  
  1802.  
  1803.  
  1804.  
  1805.                     Short Format - Format bit is SHORT=1
  1806.  
  1807.                      0             0 0   1         1
  1808.                      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  1809.                     +-------------------------------+
  1810.                     |1|       Mode  | Mode Argument |
  1811.                     +-------------------------------+  +-+
  1812.                     |                    (31-16)    |   |
  1813.                     +----        Offset          ---+   | Offset
  1814.                     |                    (15-0)     |   |
  1815.                     +-------------------------------+  +-+
  1816.  
  1817.  
  1818.                            Short Address Format
  1819.                                  Figure 11
  1820.  
  1821.  
  1822.      SHORT ADDRESS FIELDS:
  1823.      Mode
  1824.  
  1825.           The high-order  bit  is  1,  indicating  the  short  address
  1826.           format.   A  list  of  the  address modes supported is given
  1827.           below.  The interpretation of the  remaining  fields  is  as
  1828.           described above for the long addressing format.
  1829.  
  1830.  
  1831.  
  1832.  
  1833.  
  1834.  
  1835.  
  1836.  
  1837.  
  1838.  
  1839.  
  1840.  
  1841.  
  1842.  
  1843.  
  1844.  
  1845.  
  1846.  
  1847.  
  1848.  
  1849.  
  1850.  
  1851.  
  1852.  
  1853.      Page 26
  1854.  
  1855.  
  1856.  
  1857.      LDP Specification                            Commands and Formats
  1858.  
  1859.  
  1860.  
  1861.  
  1862.  
  1863.           Mode | Symbol             | Address space
  1864.           -----+--------------------+---------------------------
  1865.  
  1866.             0    HOST                 Host
  1867.             1    PHYS_MACRO           Macro-memory
  1868.             2    PHYS_MICRO           Micro-memory
  1869.             3    PHYS_I/O             I/O space
  1870.             4    PHYS_MACRO_PTR       Macro contains a pointer
  1871.             5    PHYS_REG             Register
  1872.             6    PHYS_REG_OFFSET      Register plus offset
  1873.             7    PHYS_REG_INDIRECT    Register contains address
  1874.                                       of a pointer
  1875.             8 -
  1876.             32   <reserved>
  1877.  
  1878.  
  1879.                             Short Address Modes
  1880.                                  Figure 12
  1881.  
  1882.  
  1883.  
  1884.  
  1885.  
  1886.  
  1887.  
  1888.  
  1889.  
  1890.  
  1891.  
  1892.  
  1893.  
  1894.  
  1895.  
  1896.  
  1897.  
  1898.  
  1899.  
  1900.  
  1901.  
  1902.  
  1903.  
  1904.  
  1905.  
  1906.  
  1907.  
  1908.  
  1909.  
  1910.  
  1911.                                                                Page 27
  1912.  
  1913.  
  1914.  
  1915.      RFC-909                                                 July 1984
  1916.  
  1917.  
  1918.  
  1919.  
  1920.  
  1921.  
  1922.  
  1923.  
  1924.  
  1925.  
  1926.  
  1927.  
  1928.  
  1929.  
  1930.  
  1931.  
  1932.  
  1933.  
  1934.  
  1935.  
  1936.  
  1937.  
  1938.  
  1939.  
  1940.  
  1941.  
  1942.  
  1943.  
  1944.  
  1945.  
  1946.  
  1947.  
  1948.  
  1949.  
  1950.  
  1951.  
  1952.  
  1953.  
  1954.  
  1955.  
  1956.  
  1957.  
  1958.  
  1959.  
  1960.  
  1961.  
  1962.  
  1963.  
  1964.  
  1965.  
  1966.  
  1967.  
  1968.  
  1969.      Page 28
  1970.  
  1971.  
  1972.  
  1973.      LDP Specification                               Protocol Commands
  1974.  
  1975.  
  1976.  
  1977.                                  CHAPTER 5
  1978.  
  1979.  
  1980.                              Protocol Commands
  1981.  
  1982.  
  1983.  
  1984.           Protocol  commands  are  used  for   error   handling,   for
  1985.      synchronizing  the command sequence number, and for communicating
  1986.      protocol implementation parameters.  Every protocol command has a
  1987.      corresponding  reply.   All  protocol  commands are sent from the
  1988.      host  to  the  target,  with  replies  flowing  in  the  opposite
  1989.      direction.
  1990.  
  1991.  
  1992.  
  1993.  
  1994.      5.1  HELLO Command
  1995.  
  1996.           The HELLO command is sent by the host to signal the start of
  1997.      an LDP session.  The target responds with HELLO_REPLY.
  1998.  
  1999.  
  2000.                        0             0 0   1         1
  2001.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2002.                       +---------------+---------------+
  2003.                     0 |               4               |
  2004.                       +---------------+---------------+
  2005.                     1 |   PROTOCOL    |    HELLO      |
  2006.                       +---------------+---------------+
  2007.  
  2008.  
  2009.                            HELLO Command Format
  2010.                                  Figure 13
  2011.  
  2012.  
  2013.  
  2014.  
  2015.  
  2016.  
  2017.      5.2  HELLO_REPLY
  2018.  
  2019.           A HELLO_REPLY is sent by the target in response to the HELLO
  2020.      command  at  the  start of an LDP session.  This reply is used to
  2021.      inform the host about the  target's implementation of LDP.
  2022.  
  2023.  
  2024.  
  2025.  
  2026.  
  2027.                                                                Page 29
  2028.  
  2029.  
  2030.  
  2031.      RFC-909                                                 July 1984
  2032.  
  2033.  
  2034.  
  2035.  
  2036.  
  2037.                        0             0 0   1         1
  2038.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2039.                       +---------------+---------------+
  2040.                     0 |               10              |
  2041.                       +---------------+---------------+
  2042.                     1 |    PROTOCOL   |   HELLO_REPLY |
  2043.                       +---------------+---------------+
  2044.                     2 |   LDP Version |  System Type  |
  2045.                       +---------------+---------------+
  2046.                     3 |   Options |W|S| Implementation|
  2047.                       +---------------+---------------+
  2048.                     4 | Address Code  |    Reserved   |
  2049.                       +---------------+---------------+
  2050.  
  2051.  
  2052.                             HELLO_REPLY Format
  2053.                                  Figure 14
  2054.  
  2055.  
  2056.  
  2057.      HELLO_REPLY FIELDS:
  2058.  
  2059.      LDP Version
  2060.  
  2061.           The  target's  LDP  protocol  version.    If   the   current
  2062.           host  protocol  version  does not agree  with  the  target's
  2063.           protocol  version,  the  host may terminate the session,  or
  2064.           may  continue it, at the discretion of the implementor.  The
  2065.           current version number is 2.
  2066.  
  2067.      System Type
  2068.  
  2069.           The type of system running on the target.  This is used as a
  2070.           check  against what the host thinks the target is.  The host
  2071.           is expected to have a table  of  target  system  types  with
  2072.           information  about  target  address  spaces, target-specific
  2073.           commands and addressing modes, and so forth.
  2074.  
  2075.           Currently defined system types are shown in Figure 15.  This
  2076.           list  includes  some  systems normally thought of as 'hosts'
  2077.           (e.g. C70, VAX), for implementations where targets  actively
  2078.           initiate and direct a load of themselves.
  2079.  
  2080.  
  2081.  
  2082.  
  2083.  
  2084.  
  2085.      Page 30
  2086.  
  2087.  
  2088.  
  2089.      LDP Specification                               Protocol Commands
  2090.  
  2091.  
  2092.  
  2093.  
  2094.  
  2095.              Code |  System       |  Description
  2096.           --------+---------------+---------------------------
  2097.                1     C30_16_BIT      BBN 16-bit C30
  2098.                2     C30_20_BIT      BBN 20-bit C30
  2099.                3     H316            Honeywell-316
  2100.                4     BUTTERFLY       BBN Butterfly
  2101.                5     PDP-11          DEC PDP-11
  2102.                6     C10             BBN C10
  2103.                7     C50             BBN C50
  2104.                8     PLURIBUS        BBN Pluribus
  2105.                9     C70             BBN C70
  2106.               10     VAX             DEC VAX
  2107.               11     MACINTOSH       Apple MacIntosh
  2108.  
  2109.  
  2110.                                System Types
  2111.                                  Figure 15
  2112.  
  2113.  
  2114.      Address Code
  2115.  
  2116.           The address code indicates which LDP address  format(s)  the
  2117.           target is prepared to use.  Address codes are show in Figure
  2118.           16.
  2119.  
  2120.  
  2121.            Address Code |  Symbol       | Description
  2122.           --------------+---------------+-----------------------------
  2123.  
  2124.                 1         LONG_ADDRESS    Five word address format.
  2125.                                           Supports all address modes
  2126.                                           and commands.
  2127.  
  2128.                 2         SHORT_ADDRESS   Three word address format.
  2129.                                           Supports only physical and
  2130.                                           host address modes.  Only
  2131.                                           the LOADER_DUMPER set of
  2132.                                           commands are supported.
  2133.  
  2134.  
  2135.                            Target Address Codes
  2136.                                  Figure 16
  2137.  
  2138.  
  2139.      Implementation
  2140.  
  2141.  
  2142.  
  2143.                                                                Page 31
  2144.  
  2145.  
  2146.  
  2147.      RFC-909                                                 July 1984
  2148.  
  2149.  
  2150.  
  2151.           The implementation level   specifies   which   features   of
  2152.           the   protocol   are  implemented  in the target.  There are
  2153.           three levels of protocol implementation.  These  levels  are
  2154.           intended to correspond to the three most likely applications
  2155.           of LDP:  simple loading and dumping,  basic  debugging,  and
  2156.           full  debugging.   (Please see Implementations, above, for a
  2157.           detailed description of implementation  levels.)  There  are
  2158.           are  also several optional features that are not included in
  2159.           any particular level.
  2160.  
  2161.           Implementation levels are cumulative, that is,  each  higher
  2162.           level  includes  the  features  of all previous levels.  The
  2163.           levels are shown in Figure 17.
  2164.  
  2165.  
  2166.  
  2167.           Feature Level |  Symbol       | Description
  2168.           --------------+---------------+-----------------------------
  2169.                  1        LOADER_DUMPER   Loader/dumper subset of LDP
  2170.                  2        BASIC_DEBUGGER  Control commands, CREATE
  2171.                  3        FULL_DEBUGGER   FSM breakpoints
  2172.  
  2173.  
  2174.                               Feature Levels
  2175.                                  Figure 17
  2176.  
  2177.  
  2178.  
  2179.      Options
  2180.  
  2181.           The options field (see  Figure  18)  is  an  eight-bit  flag
  2182.           field.   Bit  flags  are  used to indicate if the target has
  2183.           implemented particular optional commands.  Not all  optional
  2184.           commands  are  referenced  in  this  field.  Commands  whose
  2185.           implementation   depends  on  target  machine  features  are
  2186.           omitted.   The  LDP  application is expected to 'know' about
  2187.           target features that are  not  intrinsic  to  the  protocol.
  2188.           Examples  of  target-dependent  commands  are  commands that
  2189.           refer to named objects (CREATE, LIST_NAMES).
  2190.  
  2191.  
  2192.  
  2193.  
  2194.  
  2195.  
  2196.  
  2197.  
  2198.  
  2199.  
  2200.  
  2201.      Page 32
  2202.  
  2203.  
  2204.  
  2205.      LDP Specification                               Protocol Commands
  2206.  
  2207.  
  2208.  
  2209.  
  2210.  
  2211.                 Mask |  Symbol     | Description
  2212.                ------+-------------+---------------+-----------------
  2213.                  1     STEP          The STEP command is implemented
  2214.                  2     WATCHPOINTS   Watchpoints are implemented
  2215.  
  2216.  
  2217.                                   Options
  2218.                                  Figure 18
  2219.  
  2220.  
  2221.  
  2222.  
  2223.  
  2224.  
  2225.      5.3  SYNCH Command
  2226.  
  2227.           The SYNCH command is sent by the host  to  the  target.  The
  2228.      target  responds  with  a  SYNCH_REPLY.   The SYNCH - SYNCH_REPLY
  2229.      exchange serves two functions: it synchronizes the host-to-target
  2230.      implicit sequence number and acts as a cumulative acknowledgement
  2231.      of the receipt and execution of  all  host  commands  up  to  the
  2232.      SYNCH.
  2233.  
  2234.  
  2235.  
  2236.                        0             0 0   1         1
  2237.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2238.                       +---------------+---------------+
  2239.                     0 |               6               |
  2240.                       +---------------+---------------+
  2241.                     1 |   PROTOCOL    |    SYNCH      |
  2242.                       +---------------+---------------+
  2243.                     2 |       Sequence Number         |
  2244.                       +---------------+---------------+
  2245.  
  2246.  
  2247.                            SYNCH Command Format
  2248.                                  Figure 19
  2249.  
  2250.  
  2251.  
  2252.      SYNCH FIELDS:
  2253.  
  2254.      Sequence Number
  2255.  
  2256.  
  2257.  
  2258.  
  2259.                                                                Page 33
  2260.  
  2261.  
  2262.  
  2263.      RFC-909                                                 July 1984
  2264.  
  2265.  
  2266.  
  2267.           The sequence number of this command.  If this  is  not  what
  2268.           the  target  is  expecting,  the target will reset to it and
  2269.           respond with an ERROR reply.
  2270.  
  2271.  
  2272.  
  2273.  
  2274.      5.4  SYNCH_REPLY
  2275.  
  2276.           A SYNCH_REPLY is sent by the target in reponse  to  a  valid
  2277.      SYNCH  command.   A SYNCH command is valid if its sequence number
  2278.      agrees  with  the  sequence  number  the  target  is   expecting.
  2279.      Otherwise, the target will reset its sequence number to the SYNCH
  2280.      command and send an ERROR reply.
  2281.  
  2282.  
  2283.                        0             0 0   1         1
  2284.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2285.                       +---------------+---------------+
  2286.                     0 |               6               |
  2287.                       +---------------+---------------+
  2288.                     1 |   PROTOCOL    |  SYNCH_REPLY  |
  2289.                       +---------------+---------------+
  2290.                     2 |       Sequence Number         |
  2291.                       +---------------+---------------+
  2292.  
  2293.  
  2294.                             SYNCH_REPLY Format
  2295.                                  Figure 20
  2296.  
  2297.  
  2298.  
  2299.      SYNCH_REPLY FIELDS:
  2300.  
  2301.      Sequence Number
  2302.  
  2303.           The sequence number of  the  SYNCH  command  to  which  this
  2304.           SYNCH_REPLY is the response.
  2305.  
  2306.  
  2307.  
  2308.  
  2309.  
  2310.  
  2311.  
  2312.  
  2313.  
  2314.  
  2315.  
  2316.  
  2317.      Page 34
  2318.  
  2319.  
  2320.  
  2321.      LDP Specification                               Protocol Commands
  2322.  
  2323.  
  2324.  
  2325.      5.5  ABORT Command
  2326.  
  2327.           The ABORT command is sent from the host to abort all pending
  2328.      operations  at  the target.  The target responds with ABORT_DONE.
  2329.      This is primarily intended to stop large data transfers from  the
  2330.      target.  A likely application would be during a debugging session
  2331.      when the user types an interrupt to abort  a  large  printout  of
  2332.      data  from  the  target.   The ABORT command has no effect on any
  2333.      breakpoints or watchpoints that may be enabled in the target.
  2334.  
  2335.           As a practical matter, the ABORT command may be difficult to
  2336.      implement  on  some  targets.   Its  ability to interrupt command
  2337.      processing on the target depends on the target being able to look
  2338.      ahead at incoming commands and receive an out-of-band signal from
  2339.      the host.  However, the effect of an ABORT  may  be  achieved  by
  2340.      simply closing and reopening the transport connection.
  2341.  
  2342.  
  2343.                        0             0 0   1         1
  2344.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2345.                       +---------------+---------------+
  2346.                     0 |               4               |
  2347.                       +---------------+---------------+
  2348.                     1 |   PROTOCOL    |    ABORT      |
  2349.                       +---------------+---------------+
  2350.  
  2351.  
  2352.                            ABORT Command Format
  2353.                                  Figure 21
  2354.  
  2355.  
  2356.  
  2357.  
  2358.  
  2359.  
  2360.      5.6  ABORT_DONE Reply
  2361.  
  2362.           The ABORT_DONE reply is sent from the target to the host  in
  2363.      response to an ABORT command.  This indicates that the target has
  2364.      terminated all  operations  that  were  pending  when  the  ABORT
  2365.      command  was  received.  The sequence number of the ABORT command
  2366.      is included in the reply.
  2367.  
  2368.  
  2369.  
  2370.  
  2371.  
  2372.  
  2373.  
  2374.  
  2375.                                                                Page 35
  2376.  
  2377.  
  2378.  
  2379.      RFC-909                                                 July 1984
  2380.  
  2381.  
  2382.  
  2383.  
  2384.  
  2385.                        0             0 0   1         1
  2386.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2387.                       +---------------+---------------+
  2388.                     0 |               4               |
  2389.                       +---------------+---------------+
  2390.                     1 |   PROTOCOL    |    ABORT_DONE |
  2391.                       +---------------+---------------+
  2392.                     2 |       Sequence Number         |
  2393.                       +---------------+---------------+
  2394.  
  2395.  
  2396.                           ABORT_DONE Reply Format
  2397.                                  Figure 22
  2398.  
  2399.  
  2400.  
  2401.      ABORT_DONE FIELDS:
  2402.  
  2403.      Sequence Number
  2404.  
  2405.           The sequence number of the ABORT command that elicited  this
  2406.           reply.   This  enables   the  host  to  distinguish  between
  2407.           replies to multiple aborts.
  2408.  
  2409.  
  2410.  
  2411.  
  2412.  
  2413.      5.7  ERROR Reply
  2414.  
  2415.           The ERROR reply is sent by the target in response to  a  bad
  2416.      command.   The  ERROR  reply  gives  the  sequence  number of the
  2417.      offending command and a reason code.  The target ignores  further
  2418.      commands   until  an  ERRACK command is received.  The reason for
  2419.      ignoring commands is that the  proper  operation  of  outstanding
  2420.      commands  may  be  predicated  on  the execution of the erroneous
  2421.      command.
  2422.  
  2423.  
  2424.  
  2425.  
  2426.  
  2427.  
  2428.  
  2429.  
  2430.  
  2431.  
  2432.  
  2433.      Page 36
  2434.  
  2435.  
  2436.  
  2437.      LDP Specification                               Protocol Commands
  2438.  
  2439.  
  2440.  
  2441.  
  2442.  
  2443.                        0             0 0   1         1
  2444.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2445.                       +---------------+---------------+
  2446.                     0 |        Command Length         |
  2447.                       +---------------+---------------+
  2448.                     1 |   PROTOCOL    |    ERROR      |
  2449.                       +---------------+---------------+
  2450.                     2 |   Command Sequence Number     |
  2451.                       +---------------+---------------+
  2452.                     3 |          Error code           |
  2453.                       +---------------+---------------+
  2454.                     4 |       Optional Data           |
  2455.                       +---------------+---------------+
  2456.                                       *
  2457.                                       *
  2458.                                       *
  2459.                       +---------------+---------------+
  2460.                     n |       Optional Data           |
  2461.                       +---------------+---------------+
  2462.  
  2463.                             ERROR Reply Format
  2464.                                  Figure 23
  2465.  
  2466.  
  2467.      ERROR Reply FIELDS:
  2468.  
  2469.      Command Sequence Number
  2470.  
  2471.           The implicit sequence number of the erroneous command.
  2472.  
  2473.      Error Code
  2474.  
  2475.           A code specifying what error has taken place.  The currently
  2476.           defined codes are shown in Figure 24.
  2477.  
  2478.  
  2479.  
  2480.  
  2481.  
  2482.  
  2483.  
  2484.  
  2485.  
  2486.  
  2487.  
  2488.  
  2489.  
  2490.  
  2491.                                                                Page 37
  2492.  
  2493.  
  2494.  
  2495.      RFC-909                                                 July 1984
  2496.  
  2497.  
  2498.  
  2499.  
  2500.  
  2501.                     Error Code |  Symbol
  2502.                     -----------+------------------------
  2503.                         1         BAD_COMMAND
  2504.                         2         BAD_ADDRESS_MODE
  2505.                         3         BAD_ADDRESS_ID
  2506.                         4         BAD_ADDRESS_OFFSET
  2507.                         5         BAD_CREATE_TYPE
  2508.                         6         NO_RESOURCES
  2509.                         7         NO_OBJECT
  2510.                         8         OUT_OF_SYNCH
  2511.                         9         IN_BREAKPOINT
  2512.  
  2513.  
  2514.                                 ERROR Codes
  2515.                                  Figure 24
  2516.  
  2517.  
  2518.           An explanation of each of these error codes follows:
  2519.           BAD_COMMAND
  2520.  
  2521.                The command was not meaningful to the  target  machine.
  2522.                This includes commands that are valid but unimplemented
  2523.                in this target.  Also, the command  was  not  valid  in
  2524.                this context.  For example, a command given by the host
  2525.                that  is  only  legal  in  a   breakpoint   (e.g.   IF,
  2526.                SET_STATE).
  2527.  
  2528.           BAD_ADDRESS_MODE <offending-address>
  2529.  
  2530.                The mode of an address given  in  the  command  is  not
  2531.                meaningful  to  this  target  system.   For  example, a
  2532.                PROCESS address mode on a target that does not  support
  2533.                multi-processing.
  2534.  
  2535.           BAD_ADDRESS_ID <offending-address>
  2536.  
  2537.                The ID field of an  address  didn't  correspond  to  an
  2538.                appropriate  thing.  For example, for a PROCESS address
  2539.                mode, the ID of a non-existent process.
  2540.  
  2541.           BAD_ADDRESS_OFFSET <offending-address>
  2542.  
  2543.                The offset field of the address was outside  the  legal
  2544.                range  for the thing addressed.  For example, an offset
  2545.                of 200,000 in PHYS_MACRO mode on a target with  64K  of
  2546.  
  2547.  
  2548.  
  2549.      Page 38
  2550.  
  2551.  
  2552.  
  2553.      LDP Specification                               Protocol Commands
  2554.  
  2555.  
  2556.  
  2557.                macro-memory.
  2558.  
  2559.           BAD_CREATE_TYPE
  2560.  
  2561.                The object type in a CREATE command was unknown.
  2562.  
  2563.           NO_RESOURCES
  2564.  
  2565.                A CREATE  command  failed  due  to  lack  of  necessary
  2566.                resources.
  2567.  
  2568.           NO_OBJECT
  2569.  
  2570.                A GET_OBJECT command failed to find the named object.
  2571.  
  2572.           OUT_OF_SYNCH
  2573.  
  2574.                The sequence  number  of  the  SYNCH  command  was  not
  2575.                expected  by the target.  The target has resynchronized
  2576.                to it.
  2577.  
  2578.           IN_BREAKPOINT <breakpoint-descriptor> <breakpoint-sequence#>
  2579.                <reason-code> [<optional-info>]
  2580.  
  2581.                An error occurred within  a  breakpoint  command  list.
  2582.                The given 16-bit sequence-number refers to the sequence
  2583.                number  of  the  CREATE  command   that   created   the
  2584.                breakpoint,  while  breakpoint-sequence#  refers to the
  2585.                sequence number of the command  within  the  breakpoint
  2586.                given by <breakpoint-descriptor>.
  2587.  
  2588.  
  2589.  
  2590.  
  2591.      5.8  ERRACK Acknowledgement
  2592.  
  2593.           An  ERRACK  is sent by the host  in  response  to  an  ERROR
  2594.      reply  from  the  target.  The ERRACK is used to acknowledge that
  2595.      the host has received the ERROR reply.
  2596.  
  2597.  
  2598.  
  2599.  
  2600.  
  2601.  
  2602.  
  2603.  
  2604.  
  2605.  
  2606.  
  2607.                                                                Page 39
  2608.  
  2609.  
  2610.  
  2611.      RFC-909                                                 July 1984
  2612.  
  2613.  
  2614.  
  2615.  
  2616.  
  2617.                        0             0 0   1         1
  2618.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2619.                       +---------------+---------------+
  2620.                     0 |               4               |
  2621.                       +---------------+---------------+
  2622.                     1 |   PROTOCOL    |    ERRACK     |
  2623.                       +---------------+---------------+
  2624.  
  2625.  
  2626.                            ERRACK Command Format
  2627.                                  Figure 25
  2628.  
  2629.  
  2630.  
  2631.  
  2632.  
  2633.  
  2634.  
  2635.  
  2636.  
  2637.  
  2638.  
  2639.  
  2640.  
  2641.  
  2642.  
  2643.  
  2644.  
  2645.  
  2646.  
  2647.  
  2648.  
  2649.  
  2650.  
  2651.  
  2652.  
  2653.  
  2654.  
  2655.  
  2656.  
  2657.  
  2658.  
  2659.  
  2660.  
  2661.  
  2662.  
  2663.  
  2664.  
  2665.      Page 40
  2666.  
  2667.  
  2668.  
  2669.      LDP Specification                          Data Transfer Commands
  2670.  
  2671.  
  2672.  
  2673.                                  CHAPTER 6
  2674.  
  2675.  
  2676.                           Data Transfer Commands
  2677.  
  2678.  
  2679.  
  2680.           Data transfer commands  transfer data between the  host  and
  2681.      the  target.  These commands are used for loading and dumping the
  2682.      target, and examining and depositing  locations  on  the  target.
  2683.      The  READ  command  reads  data from the target, the MOVE command
  2684.      moves data within the  target  or  from  the  target  to  another
  2685.      entity,  and  the  WRITE  command  writes  data  to  the  target.
  2686.      REPEAT_DATA makes copies of a pattern to  the  target  --  it  is
  2687.      useful  for  zeroing memory.  WRITE_MASK writes data with a mask,
  2688.      and is intended for modifying target  parameter tables.
  2689.  
  2690.           Data transmitted to  and from the target always  contains  a
  2691.      target  address.   In  writes  to the target, this is used as the
  2692.      destination of the data.  In reads from the  target,  the  target
  2693.      address  is  used by the host to identify where in the target the
  2694.      data came from.  In addition, the  MOVE  command  may  contain  a
  2695.      'host'  address  as  its  destination;  this  permits the host to
  2696.      further discriminate between possible sources of  data  from  the
  2697.      target -- from different breakpoints, debugging windows, etc.
  2698.  
  2699.           A read request to  the  target  may  generate  one  or  more
  2700.      response  messages.   In  particular,  responses  to requests for
  2701.      large amounts of data -- core  dumps,  for  example  --  must  be
  2702.      broken  up into multiple messages, if the block of data requested
  2703.      plus the LDP header exceeds the transport layer message size.
  2704.  
  2705.           In commands which contain data (WRITE, READ_DATA,  MOVE_DATA
  2706.      and REPEAT_DATA), if there are an odd number of data octets, then
  2707.      a  null octet is appended.  This is so that the next  command  in
  2708.      the  message,  if  any, will begin on an even octet.  The command
  2709.      length is the sum of the number of octets in the  command  header
  2710.      and  the  number  of octets of data, excluding the null octet, if
  2711.      any.
  2712.  
  2713.           The addressing formats which may be used with data  transfer
  2714.      commands  are  specified for each LDP session at the start of the
  2715.      session by the target  in  the  HELLO_REPLY  response.   See  the
  2716.      section  entitled  'Addressing',  above, for a description of LDP
  2717.      addressing formats and modes.   In  the  command  diagrams  given
  2718.      below,  the  short  addressing  format  is  illustrated.  For LDP
  2719.      sessions using long addressing, addresses are  five  words  long,
  2720.  
  2721.  
  2722.  
  2723.                                                                Page 41
  2724.  
  2725.  
  2726.  
  2727.      RFC-909                                                 July 1984
  2728.  
  2729.  
  2730.  
  2731.      instead of three words, as shown here.  In both addressing modes,
  2732.      descriptors are three words and offsets are two words.
  2733.  
  2734.  
  2735.  
  2736.      6.1  WRITE Command
  2737.  
  2738.           The WRITE command is used to send octets of  data  from  the
  2739.      host  to  the  target.  This command specifies the address in the
  2740.      target where the data is to be stored, followed by  a  stream  of
  2741.      data  octets.   If  the  data  stream  contains  an odd number of
  2742.      octets, then a  null octet is appended so that the next  command,
  2743.      if  any,  will  begin  on  an even octet.  Since LDP must observe
  2744.      message size limitations  imposed  by  the  underlying  transport
  2745.      layer,  a  single  logical  write  may  need to be broken up into
  2746.      multiple WRITEs in separate transport messages.
  2747.  
  2748.  
  2749.  
  2750.                        0             0 0   1         1
  2751.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2752.                       +---------------+---------------+
  2753.                     0 |        Command Length         |
  2754.                       +---------------+---------------+
  2755.                     1 | DATA_TRANSFER |    WRITE      |
  2756.                       +---------------+---------------+
  2757.                     2 |                               |
  2758.                       +--          Target           --+
  2759.                     3 |            Start              |
  2760.                       +--          Address          --+
  2761.                     4 |                               |
  2762.                       +---------------+---------------+
  2763.                     5 |  Data Octet   |  Data Octet   |
  2764.                       +---------------+---------------+
  2765.                                       *
  2766.                                       *
  2767.                                       *
  2768.                       +---------------+---------------+
  2769.                     n |  Data Octet   | Data or Null  |
  2770.                       +---------------+---------------+
  2771.  
  2772.  
  2773.                            WRITE Command Format
  2774.                                  Figure 26
  2775.  
  2776.  
  2777.  
  2778.  
  2779.  
  2780.  
  2781.      Page 42
  2782.  
  2783.  
  2784.  
  2785.      LDP Specification                          Data Transfer Commands
  2786.  
  2787.  
  2788.  
  2789.      WRITE FIELDS:
  2790.  
  2791.      Command Length
  2792.  
  2793.           The command  length  gives  the  number  of  octets  in  the
  2794.           command,  including  data  octets, but excluding the padding
  2795.           octet, if any.
  2796.  
  2797.      Target Start Address
  2798.  
  2799.           This is the address to begin storing  data  in  the  target.
  2800.           The  length  of the data to be stored may be inferred by the
  2801.           target from the command length.  An illegal address or range
  2802.           will generate an ERROR reply.
  2803.  
  2804.      Data Octets
  2805.  
  2806.           Octets of data to be stored in the target.  Data are  packed
  2807.           according  to  the packing convention described above.  Ends
  2808.           with a null octet if there are an odd number of data octets.
  2809.  
  2810.  
  2811.  
  2812.  
  2813.  
  2814.      6.2  READ Command
  2815.  
  2816.           The host uses the READ command  to   ask   the   target   to
  2817.      send  back  a contiguous block of data.  The data is specified by
  2818.      a target starting address and a count.  The  target  returns  the
  2819.      data  in  one or more READ_DATA commands, which give the starting
  2820.      address (in the target) of each segment of returned  data.   When
  2821.      the  transfer  is completed, the target sends a READ_DONE command
  2822.      to the host.
  2823.  
  2824.  
  2825.  
  2826.  
  2827.  
  2828.  
  2829.  
  2830.  
  2831.  
  2832.  
  2833.  
  2834.  
  2835.  
  2836.  
  2837.  
  2838.  
  2839.                                                                Page 43
  2840.  
  2841.  
  2842.  
  2843.      RFC-909                                                 July 1984
  2844.  
  2845.  
  2846.  
  2847.  
  2848.  
  2849.                        0             0 0   1         1
  2850.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2851.                       +---------------+---------------+
  2852.                     0 |               14              |
  2853.                       +---------------+---------------+
  2854.                     1 | DATA_TRANSFER |    READ       |
  2855.                       +---------------+---------------+
  2856.                     2 |                               |
  2857.                       +--          Target           --+
  2858.                     3 |            Start              |
  2859.                       +--          Address          --+
  2860.                     4 |                               |
  2861.                       +---------------+---------------+
  2862.                     5 |            Address            |
  2863.                       +--          Unit             --+
  2864.                     6 |            Count              |
  2865.                       +---------------+---------------+
  2866.  
  2867.  
  2868.                             READ Command Format
  2869.                                  Figure 27
  2870.  
  2871.  
  2872.  
  2873.      READ FIELDS:
  2874.  
  2875.      Target Start Address
  2876.  
  2877.           The starting address of the requested block of target  data.
  2878.           The  target  sends an ERROR reply if the starting address is
  2879.           illegal, if the ending address computed from the sum of  the
  2880.           start  and the count is illegal, or if holes are encountered
  2881.           in the middle of the range.
  2882.  
  2883.      Address Unit Count
  2884.  
  2885.           The count of the number  of  target  indivisibly-addressable
  2886.           units  to be transferred.  For example, if the address space
  2887.           is PHYS_MACRO, a count of two and a start  address  of  1000
  2888.           selects the contents of locations 1000 and 1001.  'Count' is
  2889.           used instead of 'length' to avoid the problem of determining
  2890.           units  the  length  should be denominated in (octets, words,
  2891.           etc.).  The size and type of the unit will vary depending on
  2892.           the address space selected by the target start address.  The
  2893.           target should  reply  with  an  error  (if  it  is  able  to
  2894.  
  2895.  
  2896.  
  2897.      Page 44
  2898.  
  2899.  
  2900.  
  2901.      LDP Specification                          Data Transfer Commands
  2902.  
  2903.  
  2904.  
  2905.           determine  in  advance of a transfer) if the inclusive range
  2906.           of addresses specified by the start address  and  the  count
  2907.           contains an illegal or nonexistent address.
  2908.  
  2909.  
  2910.  
  2911.  
  2912.  
  2913.      6.3  READ_DATA Response
  2914.  
  2915.           The target uses the  READ_DATA  response  to  transmit  data
  2916.      requested  by  a  host  READ  command.   One  or  more  READ_DATA
  2917.      responses  may  be  needed  to  fulfill  a  given  READ  command,
  2918.      depending  on  the  size  of  the  data  block  requested and the
  2919.      transport layer message size  limits.   Each  READ_DATA  response
  2920.      gives the target starting address of its segment of data.  If the
  2921.      response contains an odd number of data octets, the  target  ends
  2922.      the response with a null octet.
  2923.  
  2924.  
  2925.  
  2926.  
  2927.  
  2928.  
  2929.  
  2930.  
  2931.  
  2932.  
  2933.  
  2934.  
  2935.  
  2936.  
  2937.  
  2938.  
  2939.  
  2940.  
  2941.  
  2942.  
  2943.  
  2944.  
  2945.  
  2946.  
  2947.  
  2948.  
  2949.  
  2950.  
  2951.  
  2952.  
  2953.  
  2954.  
  2955.                                                                Page 45
  2956.  
  2957.  
  2958.  
  2959.      RFC-909                                                 July 1984
  2960.  
  2961.  
  2962.  
  2963.  
  2964.  
  2965.                        0             0 0   1         1
  2966.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  2967.                       +---------------+---------------+
  2968.                     0 |        Command Length         |
  2969.                       +---------------+---------------+
  2970.                     1 | DATA_TRANSFER |    READ_DATA  |
  2971.                       +---------------+---------------+
  2972.                     2 |                               |
  2973.                       +--          Target           --+
  2974.                     3 |            Start              |
  2975.                       +--          Address          --+
  2976.                     4 |                               |
  2977.                       +---------------+---------------+  +-+
  2978.                     5 |  Data Octet   |  Data Octet   |   |
  2979.                       +---------------+---------------+   |
  2980.                                       *                   |
  2981.                                       *                   | Data
  2982.                                       *                   |
  2983.                       +---------------+---------------+   |
  2984.                     n |  Data Octet   | Data or Null  |   |
  2985.                       +---------------+---------------+  +-+
  2986.  
  2987.  
  2988.                            DATA Response Format
  2989.                                  Figure 28
  2990.  
  2991.  
  2992.  
  2993.      READ_DATA FIELDS:
  2994.  
  2995.      Command Length
  2996.  
  2997.           The command  length  gives  the  number  of  octets  in  the
  2998.           command,  including  data  octets, but excluding the padding
  2999.           octet, if any.  The host can calculate  the  length  of  the
  3000.           data  by  subtracting  the  header  length  from the command
  3001.           length.  Since the target address may be either three  words
  3002.           (short format) or five words (long format), the address mode
  3003.           must be checked to determine which is being used.
  3004.  
  3005.      Target Start Address
  3006.  
  3007.           This is the starting address of the  data  segment  in  this
  3008.           message.  The host may infer the length of the data from the
  3009.           command length.  The address format (short or long)  is  the
  3010.  
  3011.  
  3012.  
  3013.      Page 46
  3014.  
  3015.  
  3016.  
  3017.      LDP Specification                          Data Transfer Commands
  3018.  
  3019.  
  3020.  
  3021.           same as on the initial READ command.
  3022.  
  3023.      Data Octets
  3024.  
  3025.           Octets of data from the target.  Data are  packed  according
  3026.           to the packing convention described above.  Ends with a null
  3027.           octet if there are an odd number of data octets.
  3028.  
  3029.  
  3030.  
  3031.  
  3032.  
  3033.      6.4  READ_DONE Reply
  3034.  
  3035.           The target sends a READ_DONE reply to the host after it  has
  3036.      finished  transferring  the  data  requested  by  a READ command.
  3037.      READ_DONE specifies the sequence number of the READ command.
  3038.  
  3039.  
  3040.                        0             0 0   1         1
  3041.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  3042.                       +---------------+---------------+
  3043.                     0 |               6               |
  3044.                       +---------------+---------------+
  3045.                     1 | DATA_TRANSFER |    READ_DONE  |
  3046.                       +---------------+---------------+
  3047.                     2 |      READ Sequence Number     |
  3048.                       +---------------+---------------+
  3049.  
  3050.  
  3051.                           READ_DONE Reply Format
  3052.                                  Figure 29
  3053.  
  3054.  
  3055.  
  3056.      READ_DONE FIELDS:
  3057.  
  3058.      READ Sequence Number
  3059.  
  3060.           The sequence number of the READ command this is a reply to.
  3061.  
  3062.  
  3063.  
  3064.  
  3065.  
  3066.  
  3067.  
  3068.  
  3069.  
  3070.  
  3071.                                                                Page 47
  3072.  
  3073.  
  3074.  
  3075.      RFC-909                                                 July 1984
  3076.  
  3077.  
  3078.  
  3079.      6.5  MOVE Command
  3080.  
  3081.           The MOVE command is sent by the host to move a block of data
  3082.      from  the  target  to  a  specified destination.  The destination
  3083.      address may specify a location in the target, in the host, or  in
  3084.      another  target  (for loading one target from another).  The data
  3085.      is specified by a target starting address  and  an  address  unit
  3086.      count.   The  target sends an ERROR reply if the starting address
  3087.      is illegal, if the ending address computed from the  sum  of  the
  3088.      start  and  the  count is illegal, or if holes are encountered in
  3089.      the middle of the range.  If the MOVE destination is  off-target,
  3090.      the  target  moves the data in one or MOVE_DATAs.  Other commands
  3091.      arriving at the target during the transfer should be processed in
  3092.      a  timely fashion, particularly the ABORT command.  When the data
  3093.      has been moved,  the  target  sends  a  MOVE_DONE  to  the  host.
  3094.      However,   a  MOVE  within  a  breakpoint  will  not  generate  a
  3095.      MOVE_DONE.
  3096.  
  3097.           A MOVE with a host destination differs from a READ  in  that
  3098.      it contains a host address.  This field is specified  by the host
  3099.      in the MOVE command and copied by the target into the  responding
  3100.      MOVE_DATA(s).   The   address   may   be  used  by  the  host  to
  3101.      differentiate data returned from multiple  MOVE  requests.   This
  3102.      information   may  be  useful  in  breakpoints,  in  multi-window
  3103.      debugging  and  in  communication  with  targets  with   multiple
  3104.      processors.   For example, the host sends the MOVE command to the
  3105.      target to  be  executed  during  a breakpoint.  The ID  field  in
  3106.      the  host address might be an index into a host breakpoint table.
  3107.      When the breakpoint executes,  the  host  would  use  the  ID  to
  3108.      associate the returning MOVE_DATA with this breakpoint.
  3109.  
  3110.  
  3111.  
  3112.  
  3113.  
  3114.  
  3115.  
  3116.  
  3117.  
  3118.  
  3119.  
  3120.  
  3121.  
  3122.  
  3123.  
  3124.  
  3125.  
  3126.  
  3127.  
  3128.  
  3129.      Page 48
  3130.  
  3131.  
  3132.  
  3133.      LDP Specification                          Data Transfer Commands
  3134.  
  3135.  
  3136.  
  3137.  
  3138.  
  3139.                        0             0 0   1         1
  3140.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  3141.                       +---------------+---------------+
  3142.                     0 |        Command Length         |
  3143.                       +---------------+---------------+
  3144.                     1 | DATA_TRANSFER |    MOVE       |
  3145.                       +---------------+---------------+
  3146.                     2 |                               |
  3147.                       +--          Source           --+
  3148.                     3 |            Start              |
  3149.                       +--          Address          --+
  3150.                     4 |                               |
  3151.                       +---------------+---------------+
  3152.                     5 |            Address            |
  3153.                       +--          Unit             --+
  3154.                     6 |            Count              |
  3155.                       +---------------+---------------+
  3156.                     7 |                               |
  3157.                       +--          Destination      --+
  3158.                     8 |            Start              |
  3159.                       +--          Address          --+
  3160.                     9 |                               |
  3161.                       +---------------+---------------+
  3162.  
  3163.  
  3164.                             MOVE Command Format
  3165.                                  Figure 30
  3166.  
  3167.  
  3168.  
  3169.      MOVE  FIELDS:
  3170.  
  3171.      Source Start Address
  3172.  
  3173.           The starting address of the requested block of target  data.
  3174.           An illegal address type will generate an error reply.
  3175.  
  3176.      Address Unit Count
  3177.  
  3178.           The count of the number  of  target  indivisibly-addressable
  3179.           units  to be transferred.  For example, if the address space
  3180.           is PHYS_MACRO, a count of two and a start  address  of  1000
  3181.           selects the contents of locations 1000 and 1001.  'Count' is
  3182.           used instead of 'length' to avoid the problem of determining
  3183.           units  the  length  should be denominated in (octets, words,
  3184.  
  3185.  
  3186.  
  3187.                                                                Page 49
  3188.  
  3189.  
  3190.  
  3191.      RFC-909                                                 July 1984
  3192.  
  3193.  
  3194.  
  3195.           etc.).  The size and type of the unit will vary depending on
  3196.           the address space selected by the target start address.  The
  3197.           target should  reply  with  an  error  (if  it  is  able  to
  3198.           determine  in  advance of a transfer) if the inclusive range
  3199.           of addresses specified by the start address  and  the  count
  3200.           contains an illegal or nonexistent address.
  3201.  
  3202.      Destination Address
  3203.  
  3204.           The destination of the MOVE.  If the address space is on the
  3205.           target,  the address unit size should agree with that of the
  3206.           source address space.  If the address  mode  is  HOST,   the
  3207.           values  and  interpretations of the remaining address fields
  3208.           are   arbitrary,   and   are   determined   by   the    host
  3209.           implementation.    For  example,  the  mode  argument  might
  3210.           specify a table (breakpoint, debugging window, etc.) and the
  3211.           ID field an index into the table.
  3212.  
  3213.  
  3214.  
  3215.  
  3216.  
  3217.  
  3218.      6.6  MOVE_DATA Response
  3219.  
  3220.           The target uses the MOVE_DATA  responses  to  transmit  data
  3221.      requested  by  a  host  MOVE  command.   One  or  more  MOVE_DATA
  3222.      responses  may  be  needed  to  fulfill  a  given  MOVE  command,
  3223.      depending  on  the  size  of  the  data  block  requested and the
  3224.      transport layer message size  limits.   Each  MOVE_DATA  response
  3225.      gives the target starting address of its segment of data.  If the
  3226.      response contains an odd number of data octets, the target should
  3227.      end the response with a null octet.
  3228.  
  3229.  
  3230.  
  3231.  
  3232.  
  3233.  
  3234.  
  3235.  
  3236.  
  3237.  
  3238.  
  3239.  
  3240.  
  3241.  
  3242.  
  3243.  
  3244.  
  3245.      Page 50
  3246.  
  3247.  
  3248.  
  3249.      LDP Specification                          Data Transfer Commands
  3250.  
  3251.  
  3252.  
  3253.  
  3254.  
  3255.                        0             0 0   1         1
  3256.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  3257.                       +---------------+---------------+
  3258.                     0 |        Command Length         |
  3259.                       +---------------+---------------+
  3260.                     1 | DATA_TRANSFER |    MOVE_DATA  |
  3261.                       +---------------+---------------+
  3262.                     2 |                               |
  3263.                       +--          Source           --+
  3264.                     3 |            Start              |
  3265.                       +--          Address          --+
  3266.                     4 |                               |
  3267.                       +---------------+---------------+
  3268.                     5 |                               |
  3269.                       +--          Destination      --+
  3270.                     6 |            Start              |
  3271.                       +--          Address          --+
  3272.                     7 |                               |
  3273.                       +---------------+---------------+    +-+
  3274.                     8 |  Data Octet   |  Data Octet   |     |
  3275.                       +---------------+---------------+     |
  3276.                                       *                     |
  3277.                                       *                     | Data
  3278.                                       *                     |
  3279.                       +---------------+---------------+     |
  3280.                     n |  Data Octet   | Data or Null  |     |
  3281.                       +---------------+---------------+    +-+
  3282.  
  3283.  
  3284.                          MOVE_DATA Response Format
  3285.                                  Figure 31
  3286.  
  3287.  
  3288.  
  3289.      MOVE_DATA FIELDS:
  3290.  
  3291.      Command Length
  3292.  
  3293.           The command  length  gives  the  number  of  octets  in  the
  3294.           command,  including  data  octets, but excluding the padding
  3295.           octet, if any.
  3296.  
  3297.      Source Start Address
  3298.  
  3299.           This is the starting address of the  data  segment  in  this
  3300.  
  3301.  
  3302.  
  3303.                                                                Page 51
  3304.  
  3305.  
  3306.  
  3307.      RFC-909                                                 July 1984
  3308.  
  3309.  
  3310.  
  3311.           message.   The  host  may  infer length of the data from the
  3312.           command length.
  3313.  
  3314.      Destination Address
  3315.  
  3316.           The destination address copied from the  MOVE  command  that
  3317.           initiated this transfer.  In the case of HOST MOVEs, this is
  3318.           used by the host to identify the source of the data.
  3319.  
  3320.      Data Octets
  3321.  
  3322.           Octets of data from the target.  Data are  packed  according
  3323.           to the packing convention described above.  Ends with a null
  3324.           octet if there are an odd number of data octets.
  3325.  
  3326.  
  3327.  
  3328.  
  3329.  
  3330.      6.7  MOVE_DONE Reply
  3331.  
  3332.           The target sends a MOVE_DONE reply to the host after it  has
  3333.      finished  transferring  the  data  requested  by  a MOVE command.
  3334.      MOVE_DONE specifies the sequence number of the MOVE command.
  3335.  
  3336.  
  3337.                        0             0 0   1         1
  3338.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  3339.                       +---------------+---------------+
  3340.                     0 |               6               |
  3341.                       +---------------+---------------+
  3342.                     1 | DATA_TRANSFER |    MOVE_DONE  |
  3343.                       +---------------+---------------+
  3344.                     2 |      MOVE Sequence Number     |
  3345.                       +---------------+---------------+
  3346.  
  3347.  
  3348.                           MOVE_DONE Reply Format
  3349.                                  Figure 32
  3350.  
  3351.  
  3352.  
  3353.      MOVE_DONE FIELDS:
  3354.  
  3355.      MOVE Sequence Number
  3356.  
  3357.           The sequence number of the MOVE command this is a reply to.
  3358.  
  3359.  
  3360.  
  3361.      Page 52
  3362.  
  3363.  
  3364.  
  3365.      LDP Specification                          Data Transfer Commands
  3366.  
  3367.  
  3368.  
  3369.      6.8  REPEAT_DATA
  3370.  
  3371.           The REPEAT_DATA command is sent by the host to write  copies
  3372.      of  a  specified  pattern  into  the  target.   This  provides an
  3373.      efficient way of zeroing target memory  and  initializing  target
  3374.      data  structures.   The  command  specifies  the  target starting
  3375.      address, the number of copies of the pattern to be  made,  and  a
  3376.      stream of octets that constitutes the pattern.
  3377.  
  3378.           This command differs from the other data  transfer  commands
  3379.      in  that  the effect of a REPEAT_DATA with a large pattern cannot
  3380.      be duplicated by sending the data in smaller chunks over  several
  3381.      commands.   Therefore,  the maximum size of a pattern that can be
  3382.      copied with REPEAT_DATA will depend on the message size limits of
  3383.      the transport layer.
  3384.  
  3385.  
  3386.  
  3387.                        0             0 0   1         1
  3388.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  3389.                       +---------------+---------------+
  3390.                     0 |        Command Length         |
  3391.                       +---------------+---------------+
  3392.                     1 | DATA_TRANSFER | REPEAT_DATA   |
  3393.                       +---------------+---------------+
  3394.                     2 |                               |
  3395.                       +--          Target           --+
  3396.                     3 |            Start              |
  3397.                       +--          Address          --+
  3398.                     4 |                               |
  3399.                       +---------------+---------------+
  3400.                     6 |         Repeat Count          |
  3401.                       +---------------+---------------+  +-+
  3402.                     7 |  Data Octet   |  Data Octet   |   |
  3403.                       +---------------+---------------+   |
  3404.                                       *                   |
  3405.                                       *                   | Pattern
  3406.                                       *                   |
  3407.                       +---------------+---------------+   |
  3408.                     n |  Data Octet   | Data or Null  |   |
  3409.                       +---------------+---------------+  +-+
  3410.  
  3411.  
  3412.                         REPEAT_DATA Command Format
  3413.                                  Figure 33
  3414.  
  3415.  
  3416.  
  3417.  
  3418.  
  3419.                                                                Page 53
  3420.  
  3421.  
  3422.  
  3423.      RFC-909                                                 July 1984
  3424.  
  3425.  
  3426.  
  3427.      REPEAT_DATA FIELDS:
  3428.  
  3429.      Command Length
  3430.  
  3431.           The command  length  gives  the  number  of  octets  in  the
  3432.           command, including data octets in the pattern, but excluding
  3433.           the padding octet, if any.
  3434.  
  3435.      Target Start Address
  3436.  
  3437.           This is the starting address where the  first  copy  of  the
  3438.           pattern  should be written in the target.  Successive copies
  3439.           of the  pattern  are  made  contiguously  starting  at  this
  3440.           address.
  3441.  
  3442.      Repeat Count
  3443.  
  3444.           The repeat count specifies  the  number  of  copies  of  the
  3445.           pattern that should be made in the target.  The repeat count
  3446.           should be greater than zero.
  3447.  
  3448.      Pattern
  3449.  
  3450.           The pattern to be copied into  the  target,  packed  into  a
  3451.           stream  of octets.  Data are packed according to the packing
  3452.           convention described above.  Ends with a null octet if there
  3453.           are an odd number of data octets.
  3454.  
  3455.  
  3456.  
  3457.  
  3458.  
  3459.      6.9  WRITE_MASK Command (Optional)
  3460.  
  3461.           The host sends a WRITE_MASK command to the target  to  write
  3462.      one  or  more  masked  values.   The  command  uses an address to
  3463.      specify a target base location, followed by one or  more  offset-
  3464.      mask-value triplets.  Each triplet gives an offset from the base,
  3465.      a value, and a mask indicating which bits in the location at  the
  3466.      offset are to be changed.
  3467.  
  3468.           This optional command is intended for use in controlling the
  3469.      target  by changing locations in a table.  For example, it may be
  3470.      used  to  change  entries  in  a  target  parameter  table.   The
  3471.      operation  of  modifying a specified location with a masked value
  3472.      is intended to be atomic.  In other words, another target process
  3473.      should  not be able to access the location to be modified between
  3474.  
  3475.  
  3476.  
  3477.      Page 54
  3478.  
  3479.  
  3480.  
  3481.      LDP Specification                          Data Transfer Commands
  3482.  
  3483.  
  3484.  
  3485.      the start and the end of the modification.
  3486.  
  3487.  
  3488.  
  3489.  
  3490.  
  3491.  
  3492.  
  3493.  
  3494.  
  3495.  
  3496.  
  3497.  
  3498.  
  3499.  
  3500.  
  3501.  
  3502.  
  3503.  
  3504.  
  3505.  
  3506.  
  3507.  
  3508.  
  3509.  
  3510.  
  3511.  
  3512.  
  3513.  
  3514.  
  3515.  
  3516.  
  3517.  
  3518.  
  3519.  
  3520.  
  3521.  
  3522.  
  3523.  
  3524.  
  3525.  
  3526.  
  3527.  
  3528.  
  3529.  
  3530.  
  3531.  
  3532.  
  3533.  
  3534.  
  3535.                                                                Page 55
  3536.  
  3537.  
  3538.  
  3539.      RFC-909                                                 July 1984
  3540.  
  3541.  
  3542.  
  3543.  
  3544.  
  3545.                        0             0 0   1         1
  3546.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  3547.                       +---------------+---------------+
  3548.                     0 |        Command Length         |
  3549.                       +---------------+---------------+
  3550.                     1 | DATA_TRANSFER | WRITE_MASK    |
  3551.                       +---------------+---------------+
  3552.                     2 |                               |
  3553.                       +--          Target           --+
  3554.                     3 |            Base               |
  3555.                       +--          Address          --+
  3556.                     4 |                               |
  3557.                       +---------------+---------------+   +-+
  3558.                     5 |                               |    |
  3559.                       +--          Offset           --+    |
  3560.                     6 |                               |    |
  3561.                       +---------------+---------------+    | Offset-Mask-Value
  3562.                     7 |                               |    | Triplet
  3563.                       +--          Mask             --+    |
  3564.                     8 |                               |    |
  3565.                       +---------------+---------------+    |
  3566.                     9 |                               |    |
  3567.                       +--          Value            --+    |
  3568.                     10|                               |    |
  3569.                       +---------------+---------------+   +-+
  3570.                                       *
  3571.                                       *
  3572.                                       *
  3573.                       +---------------+---------------+   +-+
  3574.                       |                               |    |
  3575.                       +--          Offset           --+    |
  3576.                       |                               |    |
  3577.                       +---------------+---------------+    | Offset-Mask-Value
  3578.                       |                               |    | Triplet
  3579.                       +--          Mask             --+    |
  3580.                       |                               |    |
  3581.                       +---------------+---------------+    |
  3582.                       |                               |    |
  3583.                       +--          Value            --+    |
  3584.                       |                               |    |
  3585.                       +---------------+---------------+   +-+
  3586.  
  3587.  
  3588.                              WRITE_MASK Format
  3589.                                  Figure 34
  3590.  
  3591.  
  3592.  
  3593.      Page 56
  3594.  
  3595.  
  3596.  
  3597.      LDP Specification                          Data Transfer Commands
  3598.  
  3599.  
  3600.  
  3601.      WRITE_MASK FIELDS:
  3602.  
  3603.      Command Length
  3604.  
  3605.           The command  length  gives  the  number  of  octets  in  the
  3606.           command.  The number of offset-value pairs may be calculated
  3607.           from this, since the command  header  is  either  10  or  12
  3608.           octets  long  (short  or  long  address  format),  and  each
  3609.           offset-mask-value triplet is 12 octets long.
  3610.  
  3611.      Target Base Address
  3612.  
  3613.           Specifies the target location to which the offset  is  added
  3614.           to yield the location to be modified.
  3615.  
  3616.      Offset
  3617.  
  3618.           An offset to be added to the base to select a location to be
  3619.           modified.
  3620.      Mask
  3621.  
  3622.           Specifies which bits in the value are to be copied into  the
  3623.           location.
  3624.      Value
  3625.  
  3626.           A value to be stored at the specified offset from the  base.
  3627.           The  set  bits in the mask determine which bits in the value
  3628.           are applied to the location.  The following  algorithm  will
  3629.           achieve  the  intended result:  take the one's complement of
  3630.           the mask and AND it with the location, leaving the result in
  3631.           the  location.   Then AND the mask and the value, and OR the
  3632.           result into the location.
  3633.  
  3634.  
  3635.  
  3636.  
  3637.  
  3638.  
  3639.  
  3640.  
  3641.  
  3642.  
  3643.  
  3644.  
  3645.  
  3646.  
  3647.  
  3648.  
  3649.  
  3650.  
  3651.                                                                Page 57
  3652.  
  3653.  
  3654.  
  3655.      RFC-909                                                 July 1984
  3656.  
  3657.  
  3658.  
  3659.  
  3660.  
  3661.  
  3662.  
  3663.  
  3664.  
  3665.  
  3666.  
  3667.  
  3668.  
  3669.  
  3670.  
  3671.  
  3672.  
  3673.  
  3674.  
  3675.  
  3676.  
  3677.  
  3678.  
  3679.  
  3680.  
  3681.  
  3682.  
  3683.  
  3684.  
  3685.  
  3686.  
  3687.  
  3688.  
  3689.  
  3690.  
  3691.  
  3692.  
  3693.  
  3694.  
  3695.  
  3696.  
  3697.  
  3698.  
  3699.  
  3700.  
  3701.  
  3702.  
  3703.  
  3704.  
  3705.  
  3706.  
  3707.  
  3708.  
  3709.      Page 58
  3710.  
  3711.  
  3712.  
  3713.      LDP Specification                                Control Commands
  3714.  
  3715.  
  3716.  
  3717.                                  CHAPTER 7
  3718.  
  3719.  
  3720.                              Control Commands
  3721.  
  3722.  
  3723.  
  3724.           Control commands are used to control the execution of target
  3725.      code,  breakpoints  and  watchpoints.  They are also used to read
  3726.      and report  the  state  of  these  objects.   The  object  to  be
  3727.      controlled  or reported on is specified with a descriptor.  Valid
  3728.      descriptor modes include PHYS_* (for some commands) PROCESS_CODE,
  3729.      BREAKPOINT  and  WATCHPOINT.   Control  commands which change the
  3730.      state of the target are START, STOP, CONTINUE and  STEP.   REPORT
  3731.      requests  a  STATUS  report  on  a target object.  EXCEPTION is a
  3732.      spontaneous report on an  object,  used  to  report  asynchronous
  3733.      events such as hardware traps.  The host may verify the action of
  3734.      a START, STOP, STEP or CONTINUE command by following  it  with  a
  3735.      REPORT command.
  3736.  
  3737.  
  3738.  
  3739.  
  3740.      7.1  START Command
  3741.  
  3742.           The START command is sent by the host to start execution  of
  3743.      a  specified  object  in  the  target.  For targets which support
  3744.      multiple processes, a PROCESS_CODE address specifies the  process
  3745.      to  be  started.  Otherwise, one of the  PHYS_* modes may specify
  3746.      a location  in  macro-memory  where  execution  is  to  continue.
  3747.      Applied  to  a  breakpoint or watchpoint, START sets the value of
  3748.      the object's state variable, and activates the  breakpoint.   The
  3749.      breakpoint counter and pointer variables are initialized to zero.
  3750.  
  3751.  
  3752.  
  3753.  
  3754.  
  3755.  
  3756.  
  3757.  
  3758.  
  3759.  
  3760.  
  3761.  
  3762.  
  3763.  
  3764.  
  3765.  
  3766.  
  3767.                                                                Page 59
  3768.  
  3769.  
  3770.  
  3771.      RFC-909                                                 July 1984
  3772.  
  3773.  
  3774.  
  3775.  
  3776.  
  3777.                        0             0 0   1         1
  3778.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  3779.                       +---------------+---------------+
  3780.                     0 |               14              |
  3781.                       +---------------+---------------+
  3782.                     1 |   CONTROL     |     START     |
  3783.                       +---------------+---------------+  +-+
  3784.                     2 |    Mode       |     0         |   |
  3785.                       +---------------+---------------+   |
  3786.                     3 |                               |   |
  3787.                       +--            ID             --+   |
  3788.                     4 |              Field            |   |  Address
  3789.                       +-------------------------------+   |
  3790.                     5 |                               |   |
  3791.                       +--            Offset         --+   |
  3792.                     6 |                               |   |
  3793.                       +-------------------------------+  +-+
  3794.  
  3795.  
  3796.                            START Command Format
  3797.                                  Figure 35
  3798.  
  3799.  
  3800.  
  3801.      START FIELDS:
  3802.  
  3803.      Address
  3804.  
  3805.           The descriptor specifies the object to be started.   If  the
  3806.           mode  is  PROCESS_CODE,  ID  specifies  the  process  to  be
  3807.           started, and offset gives the  process  virtual  address  to
  3808.           start at.  If the mode is PHYS_*, execution of the target is
  3809.           continued at the specified address.
  3810.  
  3811.           For modes of BREAKPOINT and WATCHPOINT, the offset specifies
  3812.           the  new  value  of the FSM state variable.  This is for FSM
  3813.           breakpoints and watchpoints.
  3814.  
  3815.  
  3816.  
  3817.  
  3818.  
  3819.  
  3820.  
  3821.  
  3822.  
  3823.  
  3824.  
  3825.      Page 60
  3826.  
  3827.  
  3828.  
  3829.      LDP Specification                                Control Commands
  3830.  
  3831.  
  3832.  
  3833.      7.2  STOP Command
  3834.  
  3835.           The STOP command is sent by the host to stop execution of  a
  3836.      specified  object  in  the  target.   A  descriptor specifies the
  3837.      object. Applied to a breakpoint or watchpoint,  STOP  deactivates
  3838.      it.   The  breakpoint/watchpoint may be re-activated by issuing a
  3839.      START or a CONTINUE command for it.
  3840.  
  3841.  
  3842.                        0             0 0   1         1
  3843.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  3844.                       +---------------+---------------+
  3845.                     0 |               10              |
  3846.                       +---------------+---------------+
  3847.                     1 |   CONTROL     |     STOP      |
  3848.                       +---------------+---------------+  +-+
  3849.                     2 |    Mode       |     0         |   |
  3850.                       +---------------+---------------+   |
  3851.                     3 |                               |   |  Descriptor
  3852.                       +--            ID             --+   |
  3853.                     4 |              Field            |   |
  3854.                       +-------------------------------+  +-+
  3855.  
  3856.  
  3857.                             STOP Command Format
  3858.                                  Figure 36
  3859.  
  3860.  
  3861.  
  3862.      STOP FIELDS:
  3863.  
  3864.      Descriptor
  3865.  
  3866.           The  descriptor  specifies  the  object  to  be  stopped  or
  3867.           disarmed.  If the mode is PROCESS_CODE, the ID specifies the
  3868.           process to be stopped.
  3869.  
  3870.           For  modes  of  BREAKPOINT  and  WATCHPOINT,  the  specified
  3871.           breakpoint  or  watchpoint  is  deactivated.   It may be re-
  3872.           activated by a CONTINUE or START command.
  3873.  
  3874.  
  3875.  
  3876.  
  3877.  
  3878.  
  3879.  
  3880.  
  3881.  
  3882.  
  3883.                                                                Page 61
  3884.  
  3885.  
  3886.  
  3887.      RFC-909                                                 July 1984
  3888.  
  3889.  
  3890.  
  3891.      7.3  CONTINUE Command
  3892.  
  3893.           The CONTINUE command is sent by the host to resume execution
  3894.      of  a specified object in the target.  A descriptor specifies the
  3895.      object. Applied to a breakpoint or watchpoint, CONTINUE activates
  3896.      it.
  3897.  
  3898.  
  3899.                        0             0 0   1         1
  3900.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  3901.                       +---------------+---------------+
  3902.                     0 |               10              |
  3903.                       +---------------+---------------+
  3904.                     1 |   CONTROL     |     CONTINUE  |
  3905.                       +---------------+---------------+  +-+
  3906.                     2 |    Mode       |     0         |   |
  3907.                       +---------------+---------------+   |
  3908.                     3 |                               |   |  Descriptor
  3909.                       +--            ID             --+   |
  3910.                     4 |              Field            |   |
  3911.                       +-------------------------------+  +-+
  3912.  
  3913.  
  3914.                           CONTINUE Command Format
  3915.                                  Figure 37
  3916.  
  3917.  
  3918.  
  3919.      CONTINUE FIELDS:
  3920.  
  3921.      Descriptor
  3922.  
  3923.           The descriptor specifies the object to be resumed or  armed.
  3924.           If the mode is PROCESS_CODE, the ID specifies the process to
  3925.           be resumed.
  3926.  
  3927.           For  modes  of  BREAKPOINT  and  WATCHPOINT,  the  specified
  3928.           breakpoint or watchpoint is armed.
  3929.  
  3930.  
  3931.  
  3932.      7.4  STEP Command
  3933.  
  3934.           The STEP command is sent by the  host  to  the  target.   It
  3935.      requests   the  execution  of  one  instruction  (or  appropriate
  3936.      operation) in the object specified by the descriptor.
  3937.  
  3938.  
  3939.  
  3940.  
  3941.      Page 62
  3942.  
  3943.  
  3944.  
  3945.      LDP Specification                                Control Commands
  3946.  
  3947.  
  3948.  
  3949.  
  3950.  
  3951.                        0             0 0   1         1
  3952.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  3953.                       +---------------+---------------+
  3954.                     0 |               10              |
  3955.                       +---------------+---------------+
  3956.                     1 |   CONTROL     |     STEP      |
  3957.                       +---------------+---------------+  +-+
  3958.                     2 |    Mode       |     0         |   |
  3959.                       +---------------+---------------+   |
  3960.                     3 |                               |   |  Descriptor
  3961.                       +--            ID             --+   |
  3962.                     4 |              Field            |   |
  3963.                       +-------------------------------+  +-+
  3964.  
  3965.  
  3966.                             STEP Command Format
  3967.                                  Figure 38
  3968.  
  3969.  
  3970.      STEP FIELDS:
  3971.  
  3972.      Descriptor
  3973.  
  3974.           The descriptor specifies the object to be stepped.   If  the
  3975.           mode is PROCESS_CODE, the ID specifies a process.
  3976.  
  3977.  
  3978.  
  3979.      7.5  REPORT Command
  3980.  
  3981.           The REPORT command is sent by the host to request  a  status
  3982.      report on a specified target object.  The status is returned in a
  3983.      STATUS reply.
  3984.  
  3985.  
  3986.  
  3987.  
  3988.  
  3989.  
  3990.  
  3991.  
  3992.  
  3993.  
  3994.  
  3995.  
  3996.  
  3997.  
  3998.  
  3999.                                                                Page 63
  4000.  
  4001.  
  4002.  
  4003.      RFC-909                                                 July 1984
  4004.  
  4005.  
  4006.  
  4007.  
  4008.  
  4009.                        0             0 0   1         1
  4010.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4011.                       +---------------+---------------+
  4012.                     0 |               10              |
  4013.                       +---------------+---------------+
  4014.                     1 |   CONTROL     |     REPORT    |
  4015.                       +---------------+---------------+  +-+
  4016.                     2 |    Mode       |     0         |   |
  4017.                       +---------------+---------------+   |
  4018.                     3 |                               |   |  Descriptor
  4019.                       +--            ID             --+   |
  4020.                     4 |              Field            |   |
  4021.                       +-------------------------------+  +-+
  4022.  
  4023.  
  4024.                            REPORT Command Format
  4025.                                  Figure 39
  4026.  
  4027.  
  4028.      REPORT FIELDS:
  4029.  
  4030.      Descriptor
  4031.  
  4032.           The descriptor specifies  the  object  for  which  a  STATUS
  4033.           report  is  requested.   For  a mode of PROCESS_CODE, the ID
  4034.           specifies a process.  Other valid modes are  PHYS_MACRO,  to
  4035.           query  the  status of the target application, and BREAKPOINT
  4036.           and WATCHPOINT,  to  get  the  status  of  a  breakpoint  or
  4037.           watchpoint.
  4038.  
  4039.  
  4040.  
  4041.      7.6  STATUS Reply
  4042.  
  4043.           The target sends a STATUS reply  in  response  to  a  REPORT
  4044.      command  from  the  host.   STATUS gives the state of a specified
  4045.      object.  For example, it may tell  whether  a  particular  target
  4046.      process is running or stopped.
  4047.  
  4048.  
  4049.  
  4050.  
  4051.  
  4052.  
  4053.  
  4054.  
  4055.  
  4056.  
  4057.      Page 64
  4058.  
  4059.  
  4060.  
  4061.      LDP Specification                                Control Commands
  4062.  
  4063.  
  4064.  
  4065.  
  4066.  
  4067.                        0             0 0   1         1
  4068.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4069.                       +---------------+---------------+
  4070.                     0 |         Command Length        |
  4071.                       +---------------+---------------+
  4072.                     1 |   CONTROL     |     STATUS    |
  4073.                       +---------------+---------------+  +-+
  4074.                     2 |    Mode       |     0         |   |
  4075.                       +---------------+---------------+   |
  4076.                     3 |                               |   |  Descriptor
  4077.                       +--            ID             --+   |
  4078.                     4 |              Field            |   |
  4079.                       +-------------------------------+  +-+
  4080.                     5 |              Status           |
  4081.                       +-------------------------------+  +-+
  4082.                                       *                   |
  4083.                                       *                   |
  4084.                                       *                   |  Other Data
  4085.                       +-------------------------------+   |
  4086.                     n |        Other Data             |   |
  4087.                       +-------------------------------+  +-+
  4088.  
  4089.  
  4090.                             STATUS Reply Format
  4091.                                  Figure 40
  4092.  
  4093.  
  4094.      STATUS FIELDS:
  4095.  
  4096.      Descriptor
  4097.  
  4098.           The descriptor specifies the object whose  status  is  being
  4099.           given.  If the mode is PROCESS_CODE, then the ID specifies a
  4100.           process.  If the mode is PHYS_MACRO, then the status is that
  4101.           of the target application.
  4102.  
  4103.      Status
  4104.  
  4105.           The status code describes the status of the object.   Status
  4106.           codes  are  0=STOPPED  and  1=RUNNING.   For breakpoints and
  4107.           watchpoints, STOPPED means disarmed and RUNNING means armed.
  4108.  
  4109.      Other Data
  4110.  
  4111.           For breakpoints and watchpoints, Other Data  consists  of  a
  4112.  
  4113.  
  4114.  
  4115.                                                                Page 65
  4116.  
  4117.  
  4118.  
  4119.      RFC-909                                                 July 1984
  4120.  
  4121.  
  4122.  
  4123.           16-bit  word  giving  the  current  value  of  the FSM state
  4124.           variable.
  4125.  
  4126.  
  4127.  
  4128.  
  4129.      7.7  EXCEPTION Trap
  4130.  
  4131.           An EXCEPTION is a spontaneous message sent from  the  target
  4132.      indicating   a   target-machine   exception   associated  with  a
  4133.      particular object. The object is specified by an address.
  4134.  
  4135.  
  4136.                        0             0 0   1         1
  4137.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4138.                       +---------------+---------------+
  4139.                     0 |         Command Length        |
  4140.                       +---------------+---------------+
  4141.                     1 |   CONTROL     |   EXCEPTION   |
  4142.                       +---------------+---------------+  +-+
  4143.                     2 |    Mode       |     0         |   |
  4144.                       +---------------+---------------+   |
  4145.                     3 |                               |   |
  4146.                       +--            ID             --+   |
  4147.                     4 |              Field            |   |  Address
  4148.                       +-------------------------------+   |
  4149.                     5 |                               |   |
  4150.                       +--            Offset         --+   |
  4151.                     6 |                               |   |
  4152.                       +-------------------------------+  +-+
  4153.                     7 |              Type             |
  4154.                       +-------------------------------+  +-+
  4155.                                       *                   |
  4156.                                       *                   |
  4157.                                       *                   |  Other Data
  4158.                       +-------------------------------+   |
  4159.                     n |        Other Data             |   |
  4160.                       +-------------------------------+  +-+
  4161.  
  4162.  
  4163.                              EXCEPTION Format
  4164.                                  Figure 41
  4165.  
  4166.  
  4167.      EXCEPTION FIELDS:
  4168.  
  4169.      Address
  4170.  
  4171.  
  4172.  
  4173.      Page 66
  4174.  
  4175.  
  4176.  
  4177.      LDP Specification                                Control Commands
  4178.  
  4179.  
  4180.  
  4181.           The address specifies the object the exception is for.
  4182.  
  4183.      Type
  4184.  
  4185.           The type of exception.  Values are target-dependent.
  4186.  
  4187.      Other Data
  4188.  
  4189.           Values are target-dependent.
  4190.  
  4191.  
  4192.  
  4193.  
  4194.  
  4195.  
  4196.  
  4197.  
  4198.  
  4199.  
  4200.  
  4201.  
  4202.  
  4203.  
  4204.  
  4205.  
  4206.  
  4207.  
  4208.  
  4209.  
  4210.  
  4211.  
  4212.  
  4213.  
  4214.  
  4215.  
  4216.  
  4217.  
  4218.  
  4219.  
  4220.  
  4221.  
  4222.  
  4223.  
  4224.  
  4225.  
  4226.  
  4227.  
  4228.  
  4229.  
  4230.  
  4231.                                                                Page 67
  4232.  
  4233.  
  4234.  
  4235.      RFC-909                                                 July 1984
  4236.  
  4237.  
  4238.  
  4239.  
  4240.  
  4241.  
  4242.  
  4243.  
  4244.  
  4245.  
  4246.  
  4247.  
  4248.  
  4249.  
  4250.  
  4251.  
  4252.  
  4253.  
  4254.  
  4255.  
  4256.  
  4257.  
  4258.  
  4259.  
  4260.  
  4261.  
  4262.  
  4263.  
  4264.  
  4265.  
  4266.  
  4267.  
  4268.  
  4269.  
  4270.  
  4271.  
  4272.  
  4273.  
  4274.  
  4275.  
  4276.  
  4277.  
  4278.  
  4279.  
  4280.  
  4281.  
  4282.  
  4283.  
  4284.  
  4285.  
  4286.  
  4287.  
  4288.  
  4289.      Page 68
  4290.  
  4291.  
  4292.  
  4293.      LDP Specification                             Management Commands
  4294.  
  4295.  
  4296.  
  4297.                                  CHAPTER 8
  4298.  
  4299.  
  4300.                             Management Commands
  4301.  
  4302.  
  4303.  
  4304.           Management commands are used to  control  resources  in  the
  4305.      target  machine.   There  are  two kinds of commands:  those that
  4306.      interrogate the remote machine about resources,  and  those  that
  4307.      allocate  and  free  resources.  There are management commands to
  4308.      create,  list  and  delete  breakpoints.    All   commands   have
  4309.      corresponding  replies  which  include the sequence number of the
  4310.      request command.  Failing requests produce ERROR replies.
  4311.  
  4312.           There are  two  resource  allocation  commands,  CREATE  and
  4313.      DELETE,  which  create  and delete objects in the remote machine.
  4314.      There are a number of listing commands for listing a  variety  of
  4315.      target objects -- breakpoints, watchpoints, processes, and names.
  4316.      The amount of data returned  by  listing  commands  may  vary  in
  4317.      length,  depending  on the state of the target.  If a list is too
  4318.      large to fit in a single message, the  target  will  send  it  in
  4319.      several  list  replies.   A  flag in each reply specifies whether
  4320.      more messages are to follow.
  4321.  
  4322.  
  4323.  
  4324.  
  4325.      8.1  CREATE Command
  4326.  
  4327.           The CREATE command is sent from the host to  the  target  to
  4328.      create  a target object.  If the CREATE is successful, the target
  4329.      returns  a  CREATE_DONE  reply,  which  contains   a   descriptor
  4330.      associated  with  the  CREATEd object.  The types of objects that
  4331.      may be specified in  a  CREATE  include  breakpoints,  processes,
  4332.      memory  objects  and  descriptors.   All  are optional except for
  4333.      breakpoints.
  4334.  
  4335.  
  4336.  
  4337.  
  4338.  
  4339.  
  4340.  
  4341.  
  4342.  
  4343.  
  4344.  
  4345.  
  4346.  
  4347.                                                                Page 69
  4348.  
  4349.  
  4350.  
  4351.      RFC-909                                                 July 1984
  4352.  
  4353.  
  4354.  
  4355.  
  4356.  
  4357.                        0             0 0   1         1
  4358.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4359.                       +---------------+---------------+
  4360.                     0 |        Command Length         |
  4361.                       +---------------+---------------+
  4362.                     1 | MANAGEMENT    |     CREATE    |
  4363.                       +---------------+---------------+
  4364.                     2 |           Create Type         |
  4365.                       +---------------+---------------+   +-+
  4366.                                       *                    |
  4367.                                       *                    |  Create
  4368.                                       *                    |  Arguments
  4369.                       +---------------+---------------+    |
  4370.                     n |         Create Arguments      |    |
  4371.                       +---------------+---------------+   +-+
  4372.  
  4373.  
  4374.                            CREATE Command Format
  4375.                                  Figure 42
  4376.  
  4377.  
  4378.  
  4379.      CREATE FIELDS:
  4380.  
  4381.      Create Type
  4382.  
  4383.           The type of object to be created.  Arguments vary  with  the
  4384.           type.   Currently defined types are shown in Figure 43.  All
  4385.           are optional except for BREAKPOINT.
  4386.  
  4387.  
  4388.                     Create Type  |  Symbol
  4389.                     -------------+----------------
  4390.  
  4391.                        0            BREAKPOINT
  4392.                        1            WATCHPOINT
  4393.                        2            PROCESS
  4394.                        3            MEMORY_OBJECT
  4395.                        4            DESCRIPTOR
  4396.  
  4397.  
  4398.                                Create Types
  4399.                                  Figure 43
  4400.  
  4401.  
  4402.  
  4403.  
  4404.  
  4405.      Page 70
  4406.  
  4407.  
  4408.  
  4409.      LDP Specification                             Management Commands
  4410.  
  4411.  
  4412.  
  4413.      Create Arguments
  4414.  
  4415.           Create arguments depend on the type of object being created.
  4416.           The formats for each type of object are described below.
  4417.  
  4418.  
  4419.  
  4420.                        0             0 0   1         1
  4421.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4422.                       +---------------+---------------+
  4423.                     0 |               22              |
  4424.                       +---------------+---------------+
  4425.                     1 |   MANAGEMENT  |     CREATE    |
  4426.                       +---------------+---------------+
  4427.                     2 |           BREAKPOINT          |
  4428.                       +---------------+---------------+  +-+
  4429.                     3 |    Mode       | Mode Argument |   |
  4430.                       +---------------+---------------+   |
  4431.                     4 |                               |   |
  4432.                       +--            ID             --+   |  Create
  4433.                     5 |              Field            |   |  BREAKPOINT
  4434.                       +-------------------------------+   |  Arguments
  4435.                     6 |                               |   |
  4436.                       +--            Offset         --+   |
  4437.                     7 |                               |   |
  4438.                       +-------------------------------+   |
  4439.                     8 |        Maximum States         |   |
  4440.                       +---------------+---------------+   |
  4441.                     9 |        Maximum Size           |   |
  4442.                       +---------------+---------------+   |
  4443.                     10|     Maximum Local Variables   |   |
  4444.                       +---------------+---------------+  +-+
  4445.  
  4446.  
  4447.                          CREATE BREAKPOINT Format
  4448.                                  Figure 44
  4449.  
  4450.  
  4451.  
  4452.      BREAKPOINT and WATCHPOINT
  4453.  
  4454.           The format  is the same for  CREATE  BREAKPOINT  and  CREATE
  4455.           WATCHPOINT.   In  the following discussion, 'breakpoint' may
  4456.           be taken to mean either breakpoint or watchpoint.
  4457.  
  4458.           The address is the location where the breakpoint  is  to  be
  4459.           set.   In  the  case of watchpoints it is the location to be
  4460.  
  4461.  
  4462.  
  4463.                                                                Page 71
  4464.  
  4465.  
  4466.  
  4467.      RFC-909                                                 July 1984
  4468.  
  4469.  
  4470.  
  4471.           watched.  Valid modes are any  PHYS_*  mode  that  addresses
  4472.           macro-memory,  PROCESS_CODE for breakpoints and PROCESS_DATA
  4473.           for watchpoints.
  4474.  
  4475.           'Maximum states' is the number of states  the  finite  state
  4476.           machine  for  this  breakpoint  will  have.  A value of zero
  4477.           indicates a default breakpoint, for  targets  which  do  not
  4478.           implement finite state machine (FSM) breakpoints.  A default
  4479.           breakpoint is the same as an FSM with one  state  consisting
  4480.           of  a  STOP  and a REPORT command for the process containing
  4481.           the breakpoint.
  4482.  
  4483.           'Maximum  size'  is  the  total  size,  in  octets,  of  the
  4484.           breakpoint  data  to  be sent via subsequent BREAKPOINT_DATA
  4485.           commands.  This is the size of the data only, and  does  not
  4486.           include the LDP command headers and breakpoint descriptors.
  4487.  
  4488.           'Maximum local variables' is the number of 32-bit  longs  to
  4489.           reserve  for  local variables for this breakpoint.  Normally
  4490.           this value will be zero.
  4491.  
  4492.      PROCESS
  4493.  
  4494.           Creates a new process.  Arguments are target-dependent.
  4495.  
  4496.  
  4497.  
  4498.  
  4499.  
  4500.  
  4501.  
  4502.  
  4503.  
  4504.  
  4505.  
  4506.  
  4507.  
  4508.  
  4509.  
  4510.  
  4511.  
  4512.  
  4513.  
  4514.  
  4515.  
  4516.  
  4517.  
  4518.  
  4519.  
  4520.  
  4521.      Page 72
  4522.  
  4523.  
  4524.  
  4525.      LDP Specification                             Management Commands
  4526.  
  4527.  
  4528.  
  4529.  
  4530.  
  4531.                        0             0 0   1         1
  4532.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4533.                       +---------------+---------------+
  4534.                     0 |        Command Length         |
  4535.                       +---------------+---------------+
  4536.                     1 |   MANAGEMENT  |     CREATE    |
  4537.                       +---------------+---------------+
  4538.                     2 |         MEMORY_OBJECT         |
  4539.                       +---------------+---------------+
  4540.                     3 |         Object Size           |
  4541.                       +---------------+---------------+
  4542.                     4 |           Name Size           |
  4543.                       +-------------------------------+  +-+
  4544.                     5 |    Name char  |  Name char    |   |
  4545.                       +-------------------------------+   |
  4546.                                       *                   |  Object
  4547.                                       *                   |  Name
  4548.                                       *                   |
  4549.                       +---------------+---------------+   |
  4550.                     n | 0 or Name char|       0       |   |
  4551.                       +---------------+---------------+  +-+
  4552.  
  4553.  
  4554.                         CREATE MEMORY_OBJECT Format
  4555.                                  Figure 45
  4556.  
  4557.  
  4558.  
  4559.  
  4560.      MEMORY_OBJECT
  4561.  
  4562.           Creates an object of size Object Size, with the given  name.
  4563.           Object  Size  is in target dependent units.  The name may be
  4564.           the null string for unnamed objects.  Name  Size  gives  the
  4565.           number  of  characters  in  Object  Name,  and must be even.
  4566.           Always ends with a null octect.
  4567.  
  4568.      DESCRIPTOR
  4569.  
  4570.           Used for obtaining descriptors from IDs  on  target  systems
  4571.           where  IDs  are  longer  than  32  bits.   There is a single
  4572.           argument, Long ID, whose length is target dependent.
  4573.  
  4574.  
  4575.  
  4576.  
  4577.  
  4578.  
  4579.                                                                Page 73
  4580.  
  4581.  
  4582.  
  4583.      RFC-909                                                 July 1984
  4584.  
  4585.  
  4586.  
  4587.      8.2  CREATE_DONE Reply
  4588.  
  4589.           The target sends a CREATE_DONE reply to the host in response
  4590.      to  a successful CREATE command.  The reply contains the sequence
  4591.      number of the CREATE request, and a  descriptor  for  the  object
  4592.      created.   This  descriptor  is  used  by the host to specify the
  4593.      object in subsequent commands referring to  it.   Commands  which
  4594.      refer  to  created  objects  include  LIST_* commands, DELETE and
  4595.      BREAKPOINT_DATA.  For example, to delete a  CREATEd  object,  the
  4596.      host  sends  a  DELETE  command  that  specifies  the  descriptor
  4597.      returned by the CREATE_DONE reply.
  4598.  
  4599.  
  4600.  
  4601.                        0             0 0   1         1
  4602.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4603.                       +---------------+---------------+
  4604.                     0 |               12              |
  4605.                       +---------------+---------------+
  4606.                     1 |   MANAGEMENT  |  CREATE_DONE  |
  4607.                       +---------------+---------------+
  4608.                     2 |     Create Sequence Number    |
  4609.                       +---------------+---------------+  +-+
  4610.                     3 |    Mode       | Mode Argmuent |   |
  4611.                       +---------------+---------------+   |  Created
  4612.                     4 |                               |   |  Object
  4613.                       +--            ID             --+   |  Descriptor
  4614.                     5 |              Field            |   |
  4615.                       +---------------+---------------+  +-+
  4616.  
  4617.  
  4618.                          CREATE_DONE Reply Format
  4619.                                  Figure 46
  4620.  
  4621.  
  4622.  
  4623.      CREATE_DONE FIELDS:
  4624.  
  4625.      Create Sequence Number
  4626.  
  4627.           The sequence number of the CREATE command to which  this  is
  4628.           the reply.
  4629.  
  4630.      Created Object Descriptor
  4631.  
  4632.           A descriptor assigned by the target to the  created  object.
  4633.           The  contents  of  the  descriptor  fields  are  arbitrarily
  4634.  
  4635.  
  4636.  
  4637.      Page 74
  4638.  
  4639.  
  4640.  
  4641.      LDP Specification                             Management Commands
  4642.  
  4643.  
  4644.  
  4645.           assigned by the target at its convenience.  The host  treats
  4646.           the  descriptor  as  a unitary object, used for referring to
  4647.           the created object in subsequent commands.
  4648.  
  4649.  
  4650.  
  4651.  
  4652.      8.3  DELETE Command
  4653.  
  4654.           The host sends a DELETE command to remove an object  created
  4655.      by  an  earlier  CREATE  command.   The  object  to be deleted is
  4656.      specified  with  a  descriptor.   The  descriptor  is  from   the
  4657.      CREATE_DONE reply to the original CREATE command.
  4658.  
  4659.  
  4660.  
  4661.                        0             0 0   1         1
  4662.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4663.                       +---------------+---------------+
  4664.                     0 |               10              |
  4665.                       +---------------+---------------+
  4666.                     1 |   MANAGEMENT  |    DELETE     |
  4667.                       +---------------+---------------+  +-+
  4668.                     2 |    Mode       | Mode Argument |   |
  4669.                       +---------------+---------------+   |
  4670.                     3 |                               |   |  Created
  4671.                       +--            ID             --+   |  Object
  4672.                     4 |              Field            |   |  Descriptor
  4673.                       +---------------+---------------+  +-+
  4674.  
  4675.  
  4676.                            DELETE Command Format
  4677.                                  Figure 47
  4678.  
  4679.  
  4680.  
  4681.      DELETE FIELDS:
  4682.  
  4683.           Created Object Descriptor
  4684.  
  4685.           Specifies the object to be deleted.  This is the  descriptor
  4686.           that  was returned by the target in the CREATE_DONE reply to
  4687.           the original CREATE command.
  4688.  
  4689.  
  4690.  
  4691.  
  4692.  
  4693.  
  4694.  
  4695.                                                                Page 75
  4696.  
  4697.  
  4698.  
  4699.      RFC-909                                                 July 1984
  4700.  
  4701.  
  4702.  
  4703.      8.4  DELETE_DONE Reply
  4704.  
  4705.           The target sends a DELETE_DONE reply to the host in response
  4706.      to  a successful DELETE command.  The reply contains the sequence
  4707.      number of the DELETE request.
  4708.  
  4709.  
  4710.  
  4711.                        0             0 0   1         1
  4712.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4713.                       +---------------+---------------+
  4714.                     0 |               6               |
  4715.                       +---------------+---------------+
  4716.                     1 |   MANAGEMENT  | DELETE_DONE   |
  4717.                       +---------------+---------------+
  4718.                     2 |     Delete Sequence Number    |
  4719.                       +---------------+---------------+
  4720.  
  4721.  
  4722.                          DELETE_DONE Reply Format
  4723.                                  Figure 48
  4724.  
  4725.  
  4726.  
  4727.      DELETE_DONE FIELDS:
  4728.  
  4729.      Request Sequence Number
  4730.  
  4731.           The sequence number of the DELETE command to which  this  is
  4732.           the reply.
  4733.  
  4734.  
  4735.  
  4736.  
  4737.  
  4738.      8.5  LIST_ADDRESSES Command
  4739.  
  4740.           The host sends a LIST_ADDRESSES command to request a list of
  4741.      valid address ranges for a specified object.  The object is given
  4742.      by a descriptor.  Typical objects are a target  process,  or  the
  4743.      target   physical   machine.    The   target   responds  with  an
  4744.      ADDRESS_LIST reply.  This command is used for obtaining the  size
  4745.      of dynamic address spaces and for determining dump ranges.
  4746.  
  4747.  
  4748.  
  4749.  
  4750.  
  4751.  
  4752.  
  4753.      Page 76
  4754.  
  4755.  
  4756.  
  4757.      LDP Specification                             Management Commands
  4758.  
  4759.  
  4760.  
  4761.  
  4762.  
  4763.                        0             0 0   1         1
  4764.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4765.                       +---------------+---------------+
  4766.                     0 |               10              |
  4767.                       +---------------+---------------+
  4768.                     1 |   MANAGEMENT  | LIST_ADDRESSES|
  4769.                       +---------------+---------------+  +-+
  4770.                     2 |    Mode       | Mode Argument |   |
  4771.                       +---------------+---------------+   |  Object
  4772.                     3 |                               |   |  Descriptor
  4773.                       +--            ID             --+   |
  4774.                     4 |              Field            |   |
  4775.                       +---------------+---------------+  +-+
  4776.  
  4777.  
  4778.                        LIST_ADDRESSES Command Format
  4779.                                  Figure 49
  4780.  
  4781.  
  4782.  
  4783.      LIST_ADDRESSES FIELDS:
  4784.  
  4785.           Object Descriptor
  4786.  
  4787.           Specifies the object whose address ranges are to be  listed.
  4788.           Valid  modes  include  PHYS_MACRO, PHYS_MICRO, PROCESS_CODE,
  4789.           and PROCESS_DATA.
  4790.  
  4791.  
  4792.  
  4793.  
  4794.  
  4795.  
  4796.      8.6  ADDRESS_LIST Reply
  4797.  
  4798.           The target sends  an  ADDRESS_LIST  reply  to  the  host  in
  4799.      response  to  a  successful  LIST_ADDRESSES  command.   The reply
  4800.      contains the sequence number of the LIST_ADDRESSES  request,  the
  4801.      descriptor  of  the  object being listed, and a list of the valid
  4802.      address ranges within the  object.
  4803.  
  4804.  
  4805.  
  4806.  
  4807.  
  4808.  
  4809.  
  4810.  
  4811.                                                                Page 77
  4812.  
  4813.  
  4814.  
  4815.      RFC-909                                                 July 1984
  4816.  
  4817.  
  4818.  
  4819.  
  4820.  
  4821.                        0             0 0   1         1
  4822.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4823.                       +---------------+---------------+
  4824.                     0 |        Command Length         |
  4825.                       +---------------+---------------+
  4826.                     1 |   MANAGEMENT  | ADDRESS_LIST  |
  4827.                       +---------------+---------------+
  4828.                     2 |      List Sequence Number     |
  4829.                       +---------------+---------------+
  4830.                     3 |   Flags     |M| Item Count    |
  4831.                       +---------------+---------------+
  4832.                     4 |                               |
  4833.                       +--                           --+
  4834.                     5 |          Descriptor           |
  4835.                       +--                           --+
  4836.                     6 |                               |
  4837.                       +---------------+---------------+  +-+
  4838.                     7 |                               |   |
  4839.                       +--        First Address      --+   | First
  4840.                     8 |                               |   | Address
  4841.                       +-------------------------------+   | Range
  4842.                     9 |                               |   |
  4843.                       +--         Last Address      --+   |
  4844.                     10|                               |   |
  4845.                       +-------------------------------+  +-+
  4846.                                       *
  4847.                                       *
  4848.                                       *
  4849.                       +---------------+---------------+  +-+
  4850.                       |                               |   |
  4851.                       +--        First Address      --+   | Last
  4852.                       |                               |   | Address
  4853.                       +-------------------------------+   | Range
  4854.                       |                               |   |
  4855.                       +--         Last Address      --+   |
  4856.                       |                               |   |
  4857.                       +-------------------------------+  +-+
  4858.  
  4859.  
  4860.                          ADDRESS_LIST Reply Format
  4861.                                  Figure 50
  4862.  
  4863.  
  4864.  
  4865.  
  4866.  
  4867.  
  4868.  
  4869.      Page 78
  4870.  
  4871.  
  4872.  
  4873.      LDP Specification                             Management Commands
  4874.  
  4875.  
  4876.  
  4877.      ADDRESS_LIST FIELDS:
  4878.  
  4879.      List Sequence Number
  4880.  
  4881.           The sequence number of the LIST_ADDRESSES command  to  which
  4882.           this is the reply.
  4883.  
  4884.      Flags
  4885.  
  4886.           If M=1, the  address  list  is  continued  in  one  or  more
  4887.           subsequent  ADDRESS_LIST replies.  If M=0, this is the final
  4888.           ADDRESS_LIST.
  4889.  
  4890.      Item Count
  4891.  
  4892.           The number of address ranges described in this command.
  4893.  
  4894.      Descriptor
  4895.  
  4896.           The descriptor of the object being listed.
  4897.  
  4898.      Address Range
  4899.  
  4900.           Each address range is composed of a pair of 32-bit addresses
  4901.           which  give  the  first and last addresses of the range.  If
  4902.           there are 'holes' in the address space of the  object,  then
  4903.           multiple  address  ranges will be used to describe the valid
  4904.           address space.
  4905.  
  4906.  
  4907.  
  4908.  
  4909.  
  4910.  
  4911.      8.7  LIST_BREAKPOINTS Command
  4912.  
  4913.           The host sends a LIST_BREAKPOINTS command to request a  list
  4914.      of  all  breakpoints associated with the current connection.  The
  4915.      target replies with BREAKPOINT_LIST.
  4916.  
  4917.  
  4918.  
  4919.  
  4920.  
  4921.  
  4922.  
  4923.  
  4924.  
  4925.  
  4926.  
  4927.                                                                Page 79
  4928.  
  4929.  
  4930.  
  4931.      RFC-909                                                 July 1984
  4932.  
  4933.  
  4934.  
  4935.  
  4936.  
  4937.                        0             0 0   1         1
  4938.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4939.                       +---------------+---------------+
  4940.                     0 |               4               |
  4941.                       +---------------+---------------+
  4942.                     1 |   MANAGEMENT  |LIST_BREAKPOINTS
  4943.                       +---------------+---------------+
  4944.  
  4945.  
  4946.                       LIST_BREAKPOINTS Command Format
  4947.                                  Figure 51
  4948.  
  4949.  
  4950.  
  4951.  
  4952.  
  4953.  
  4954.  
  4955.      8.8  BREAKPOINT_LIST Reply
  4956.  
  4957.           The target sends a BREAKPOINT_LIST  reply  to  the  host  in
  4958.      response  to  a LIST_BREAKPOINTS command.  The reply contains the
  4959.      sequence number of the LIST_BREAKPOINTS request, and  a  list  of
  4960.      all  breakpoints  associated  with  the  current connection.  The
  4961.      descriptor and address of each breakpoint are listed.
  4962.  
  4963.  
  4964.  
  4965.  
  4966.  
  4967.  
  4968.  
  4969.  
  4970.  
  4971.  
  4972.  
  4973.  
  4974.  
  4975.  
  4976.  
  4977.  
  4978.  
  4979.  
  4980.  
  4981.  
  4982.  
  4983.  
  4984.  
  4985.      Page 80
  4986.  
  4987.  
  4988.  
  4989.      LDP Specification                             Management Commands
  4990.  
  4991.  
  4992.  
  4993.  
  4994.  
  4995.                        0             0 0   1         1
  4996.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  4997.                       +---------------+---------------+
  4998.                     0 |        Command Length         |
  4999.                       +---------------+---------------+
  5000.                     1 |   MANAGEMENT  |BREAKPOINT_LIST|
  5001.                       +---------------+---------------+
  5002.                     2 |      List Sequence Number     |
  5003.                       +---------------+---------------+
  5004.                     3 |   Flags     |M| Item Count    |
  5005.                       +---------------+---------------+  +-+
  5006.                     4 |    Mode       |     0         |   |
  5007.                       +---------------+---------------+   |
  5008.                     5 |                               |   |  Breakpoint
  5009.                       +--            ID             --+   |  Descriptor
  5010.                     6 |              Field            |   |
  5011.                       +---------------+---------------+  +-+
  5012.                     7 |    Mode       | Mode Argument |   |
  5013.                       +---------------+---------------+   |
  5014.                     8 |                               |   |
  5015.                       +--            ID             --+   |  Breakpoint
  5016.                     9 |              Field            |   |  Address
  5017.                       +-------------------------------+   |
  5018.                     10|                               |   |
  5019.                       +--            Offset         --+   |
  5020.                     11|                               |   |
  5021.                       +-------------------------------+  +-+
  5022.                                       *                   |  Additional
  5023.                                       *                   |  Descriptor-Address
  5024.                                       *                   |  Pairs
  5025.                                                          +-+
  5026.  
  5027.  
  5028.                        BREAKPOINT_LIST Reply Format
  5029.                                  Figure 52
  5030.  
  5031.  
  5032.      BREAKPOINT_LIST FIELDS:
  5033.  
  5034.      List Sequence Number
  5035.  
  5036.           The sequence number of the LIST_BREAKPOINTS command to which
  5037.           this is the reply.
  5038.  
  5039.      Flags
  5040.  
  5041.  
  5042.  
  5043.                                                                Page 81
  5044.  
  5045.  
  5046.  
  5047.      RFC-909                                                 July 1984
  5048.  
  5049.  
  5050.  
  5051.           If M=1, the breakpoint list is  continued  in  one  or  more
  5052.           subsequent  BREAKPOINT_LIST  replies.   If  M=0, this is the
  5053.           final BREAKPOINT_LIST.
  5054.  
  5055.      Item Count
  5056.  
  5057.           The number of breakpoints described in this list.
  5058.  
  5059.      Breakpoint Descriptor
  5060.  
  5061.           A descriptor assigned by  the  target  to  this  breakpoint.
  5062.           Used   by   the   host   to   specify   this  breakpoint  in
  5063.           BREAKPOINT_DATA and DELETE commands.
  5064.  
  5065.      Breakpoint Address
  5066.  
  5067.           The address at which this breakpoint is set.
  5068.  
  5069.  
  5070.  
  5071.  
  5072.  
  5073.  
  5074.      8.9  LIST_PROCESSES Command
  5075.  
  5076.           The host sends a LIST_PROCESSES command to request a list of
  5077.      descriptors  for all processes on the target.  The target replies
  5078.      with PROCESS_LIST.
  5079.  
  5080.  
  5081.                        0             0 0   1         1
  5082.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  5083.                       +---------------+---------------+
  5084.                     0 |               4               |
  5085.                       +---------------+---------------+
  5086.                     1 |   MANAGEMENT  |LIST_PROCESSES |
  5087.                       +---------------+---------------+
  5088.  
  5089.  
  5090.                        LIST_PROCESSES Command Format
  5091.                                  Figure 53
  5092.  
  5093.  
  5094.  
  5095.  
  5096.  
  5097.  
  5098.  
  5099.  
  5100.  
  5101.      Page 82
  5102.  
  5103.  
  5104.  
  5105.      LDP Specification                             Management Commands
  5106.  
  5107.  
  5108.  
  5109.      8.10  PROCESS_LIST Reply
  5110.  
  5111.           The target  sends  a  PROCESS_LIST  reply  to  the  host  in
  5112.      response  to  a  LIST_PROCESSES  command.  The reply contains the
  5113.      sequence number of the LIST_PROCESSES request, and a list of  all
  5114.      processes  in  the  target.  For each process, a descriptor and a
  5115.      target-dependent amount of process data are given.
  5116.  
  5117.  
  5118.  
  5119.                        0             0 0   1         1
  5120.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  5121.                       +---------------+---------------+
  5122.                     0 |        Command Length         |
  5123.                       +---------------+---------------+
  5124.                     1 |   MANAGEMENT  | PROCESS_LIST  |
  5125.                       +---------------+---------------+
  5126.                     2 |      List Sequence Number     |
  5127.                       +---------------+---------------+
  5128.                     3 |   Flags     |M| Item Count    |
  5129.                       +---------------+---------------+  +-+
  5130.                     4 | PROCESS_CODE  |     0         |   |
  5131.                       +---------------+---------------+   |
  5132.                     5 |                               |   |  Process
  5133.                       +--            ID             --+   |  Descriptor
  5134.                     6 |              Field            |   |
  5135.                       +---------------+---------------+  +-+
  5136.                     7 |       Process data count      |   |
  5137.                       +---------------+---------------+   |
  5138.                     8 |  Process data |  Process data |   |
  5139.                       +-------------------------------+   |  Process
  5140.                                       *                   |  Data
  5141.                                       *                   |
  5142.                                       *                   |
  5143.                       +---------------+---------------+   |
  5144.                     n |  Process data |  Process data |   |
  5145.                       +-------------------------------+  +-+
  5146.                                       *                   |  Additional
  5147.                                       *                   |  Descriptor-Data
  5148.                                       *                   |  Pairs
  5149.                                                          +-+
  5150.  
  5151.  
  5152.                          PROCESS_LIST Reply Format
  5153.                                  Figure 54
  5154.  
  5155.  
  5156.  
  5157.  
  5158.  
  5159.                                                                Page 83
  5160.  
  5161.  
  5162.  
  5163.      RFC-909                                                 July 1984
  5164.  
  5165.  
  5166.  
  5167.      PROCESS_LIST FIELDS:
  5168.  
  5169.      List Sequence Number
  5170.  
  5171.           The sequence number of the LIST_PROCESSES command  to  which
  5172.           this is the reply.
  5173.  
  5174.      Flags
  5175.  
  5176.           If M=1, the  process  list  is  continued  in  one  or  more
  5177.           subsequent  PROCESS_LIST replies.  If M=0, this is the final
  5178.           PROCESS_LIST.
  5179.  
  5180.      Item Count
  5181.  
  5182.           The number of processes described in this  list.   For  each
  5183.           process  there  is  a  descriptor  and  a variable number of
  5184.           octets of process data.
  5185.  
  5186.      Process Descriptor
  5187.  
  5188.           A descriptor assigned by the target to this  process.   Used
  5189.           by the host to specify this PROCESS in a DELETE command.
  5190.  
  5191.      Process Data Count
  5192.  
  5193.           Number of octets of process data for this process.  Must  be
  5194.           even.
  5195.  
  5196.      Process Data
  5197.  
  5198.           Target-dependent information about this process.  Number  of
  5199.           octets is given by the process data count.
  5200.  
  5201.  
  5202.  
  5203.  
  5204.  
  5205.  
  5206.      8.11  LIST_NAMES Command
  5207.  
  5208.           The host sends a LIST_NAMES command to  request  a  list  of
  5209.      available names as strings.  The target replies with NAME_LIST.
  5210.  
  5211.  
  5212.  
  5213.  
  5214.  
  5215.  
  5216.  
  5217.      Page 84
  5218.  
  5219.  
  5220.  
  5221.      LDP Specification                             Management Commands
  5222.  
  5223.  
  5224.  
  5225.  
  5226.  
  5227.                        0             0 0   1         1
  5228.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  5229.                       +---------------+---------------+
  5230.                     0 |               4               |
  5231.                       +---------------+---------------+
  5232.                     1 |   MANAGEMENT  | LIST_NAMES    |
  5233.                       +---------------+---------------+
  5234.  
  5235.  
  5236.                          LIST_NAMES Command Format
  5237.                                  Figure 55
  5238.  
  5239.  
  5240.  
  5241.  
  5242.  
  5243.  
  5244.  
  5245.      8.12  NAME_LIST Reply
  5246.  
  5247.           The target sends a NAME_LIST reply to the host  in  response
  5248.      to  a LIST_NAMES command.  The reply contains the sequence number
  5249.      of the LIST_NAMES request, and a list of  all  target  names,  as
  5250.      strings.
  5251.  
  5252.  
  5253.  
  5254.  
  5255.  
  5256.  
  5257.  
  5258.  
  5259.  
  5260.  
  5261.  
  5262.  
  5263.  
  5264.  
  5265.  
  5266.  
  5267.  
  5268.  
  5269.  
  5270.  
  5271.  
  5272.  
  5273.  
  5274.  
  5275.                                                                Page 85
  5276.  
  5277.  
  5278.  
  5279.      RFC-909                                                 July 1984
  5280.  
  5281.  
  5282.  
  5283.  
  5284.  
  5285.                        0             0 0   1         1
  5286.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  5287.                       +---------------+---------------+
  5288.                     0 |        Command Length         |
  5289.                       +---------------+---------------+
  5290.                     1 |   MANAGEMENT  | NAME_LIST     |
  5291.                       +---------------+---------------+
  5292.                     2 |      List Sequence Number     |
  5293.                       +---------------+---------------+
  5294.                     3 |   Flags     |M| Item Count    |
  5295.                       +---------------+---------------+  +-+
  5296.                     4 |           Name Size           |   |
  5297.                       +---------------+---------------+   |
  5298.                     5 |  Name Char    |   Name Char   |   |  Name
  5299.                       +---------------+---------------+   |  String
  5300.                                       *                   |
  5301.                                       *                   |
  5302.                                       *                   |
  5303.                       +---------------+---------------+   |
  5304.                     n | 0 or Name Char|       0       |   |
  5305.                       +---------------+---------------+  +-+
  5306.                                       *                   |  Additional
  5307.                                       *                   |  Name
  5308.                                       *                   |  Strings
  5309.                                                          +-+
  5310.  
  5311.  
  5312.                           NAME_LIST Reply Format
  5313.                                  Figure 56
  5314.  
  5315.  
  5316.  
  5317.      NAME_LIST FIELDS:
  5318.  
  5319.      List Sequence Number
  5320.  
  5321.           The sequence number of the LIST_NAMES command to which  this
  5322.           is the reply.
  5323.  
  5324.  
  5325.  
  5326.  
  5327.  
  5328.  
  5329.  
  5330.  
  5331.  
  5332.  
  5333.      Page 86
  5334.  
  5335.  
  5336.  
  5337.      LDP Specification                             Management Commands
  5338.  
  5339.  
  5340.  
  5341.      Flags
  5342.  
  5343.           If M=1, the name list is continued in one or more subsequent
  5344.           NAME_LIST replies.  If M=0, this is the final NAME_LIST.
  5345.  
  5346.      Item Count
  5347.  
  5348.           The number of name strings in this list.  Each  name  string
  5349.           consists  of  a character count and a null-terminated string
  5350.           of characters.
  5351.  
  5352.      Name Size
  5353.  
  5354.           The number of octets in this name string.  Must be even.
  5355.  
  5356.      Name Characters
  5357.  
  5358.           A string of octets composing the name.   Ends  with  a  null
  5359.           octet.   The  number  of  characters must be even, so if the
  5360.           terminating null comes on an  odd  octet,  another  null  is
  5361.           appended.
  5362.  
  5363.  
  5364.  
  5365.  
  5366.  
  5367.  
  5368.      8.13  GET_PHYS_ADDR Command
  5369.  
  5370.           The host sends a GET_PHYS_ADDR command to convert an address
  5371.      into physical form.  The target returns the physical address in a
  5372.      GOT_PHYS_ADDR  reply.   For  example,  the  host  could  send   a
  5373.      GET_PHYS_ADDR  command  containing a register-offset address, and
  5374.      the target would return the physical address derived from this in
  5375.      a GOT_PHYS_ADDR reply.
  5376.  
  5377.  
  5378.  
  5379.  
  5380.  
  5381.  
  5382.  
  5383.  
  5384.  
  5385.  
  5386.  
  5387.  
  5388.  
  5389.  
  5390.  
  5391.                                                                Page 87
  5392.  
  5393.  
  5394.  
  5395.      RFC-909                                                 July 1984
  5396.  
  5397.  
  5398.  
  5399.  
  5400.  
  5401.                        0             0 0   1         1
  5402.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  5403.                       +---------------+---------------+
  5404.                     0 |               14              |
  5405.                       +---------------+---------------+
  5406.                     1 |   MANAGEMENT  | GET_PHYS_ADDR |
  5407.                       +---------------+---------------+  +-+
  5408.                     2 |    Mode       | Mode Argument |   |
  5409.                       +---------------+---------------+   |
  5410.                     3 |              ID               |   |
  5411.                       +--            Field          --+   |
  5412.                     4 |                               |   |  Address
  5413.                       +---------------+---------------+   |
  5414.                     5 |                               |   |
  5415.                       +--            Offset         --+   |
  5416.                     6 |                               |   |
  5417.                       +---------------+---------------+  +-+
  5418.  
  5419.  
  5420.                        GET_PHYS_ADDR Command Format
  5421.                                  Figure 57
  5422.  
  5423.  
  5424.  
  5425.      GET_PHYS_ADDR FIELDS:
  5426.  
  5427.      Address
  5428.  
  5429.           The address to be converted to a physical address.  The mode
  5430.           may    be   one   of   PHYS_REG_OFFSET,   PHYS_REG_INDIRECT,
  5431.           PHYS_MACRO_PTR, any OBJECT_* mode, and  any  PROCESS_*  mode
  5432.           except for PROCESS_REG.
  5433.  
  5434.  
  5435.  
  5436.  
  5437.  
  5438.  
  5439.      8.14  GOT_PHYS_ADDR Reply
  5440.  
  5441.           The target sends  a  GOT_PHYS_ADDR  reply  to  the  host  in
  5442.      response  to  a  successful  GET_PHYS_ADDR  command.   The  reply
  5443.      contains the sequence number of the  GET_PHYS_ADDR  request,  and
  5444.      the specified address converted into a physical address.
  5445.  
  5446.  
  5447.  
  5448.  
  5449.      Page 88
  5450.  
  5451.  
  5452.  
  5453.      LDP Specification                             Management Commands
  5454.  
  5455.  
  5456.  
  5457.  
  5458.                        0             0 0   1         1
  5459.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  5460.                       +---------------+---------------+
  5461.                     0 |               16              |
  5462.                       +---------------+---------------+
  5463.                     1 |   MANAGEMENT  | GOT_PHYS_ADDR |
  5464.                       +---------------+---------------+
  5465.                     2 |      Get  Sequence Number     |
  5466.                       +---------------+---------------+  +-+
  5467.                     3 | PHYS_MACRO    |      0        |   |
  5468.                       +---------------+---------------+   |
  5469.                     4 |                               |   |
  5470.                       +--             0             --+   |
  5471.                     5 |                               |   |  Address
  5472.                       +---------------+---------------+   |
  5473.                     6 |                               |   |
  5474.                       +--            Offset         --+   |
  5475.                     7 |                               |   |
  5476.                       +---------------+---------------+  +-+
  5477.  
  5478.  
  5479.                         GOT_PHYS_ADDR Reply Format
  5480.                                  Figure 58
  5481.  
  5482.  
  5483.  
  5484.      GOT_PHYS_ADDR FIELDS:
  5485.  
  5486.      Get Sequence Number
  5487.  
  5488.           The sequence number of the GET_PHYS_ADDR  command  to  which
  5489.           this is the reply.
  5490.  
  5491.      Address
  5492.  
  5493.           The address resulting from translating the address given  in
  5494.           the  GET_PHYS_ADDR command into a physical address.  Mode is
  5495.           always PHYS_MACRO and ID and mode argument are always  zero.
  5496.           Offset gives the 32-bit physical address.
  5497.  
  5498.  
  5499.  
  5500.  
  5501.  
  5502.  
  5503.  
  5504.  
  5505.  
  5506.  
  5507.                                                                Page 89
  5508.  
  5509.  
  5510.  
  5511.      RFC-909                                                 July 1984
  5512.  
  5513.  
  5514.  
  5515.      8.15  GET_OBJECT Command
  5516.  
  5517.           The host sends a GET_OBJECT command to convert a name string
  5518.      into  a  descriptor.   The  target  returns  the  descriptor in a
  5519.      GOT_OBJECT reply.  Intended for use in finding control  parameter
  5520.      objects.
  5521.  
  5522.  
  5523.  
  5524.                        0             0 0   1         1
  5525.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  5526.                       +---------------+---------------+
  5527.                     0 |        Command Length         |
  5528.                       +---------------+---------------+
  5529.                     1 |   MANAGEMENT  | GET_OBJECT    |
  5530.                       +---------------+---------------+  +-+
  5531.                     2 |           Name Size           |   |
  5532.                       +---------------+---------------+   |
  5533.                     3 |  Name Char    |   Name Char   |   |  Name
  5534.                       +---------------+---------------+   |  String
  5535.                                       *                   |
  5536.                                       *                   |
  5537.                                       *                   |
  5538.                       +---------------+---------------+   |
  5539.                     n | 0 or Name Char|       0       |   |
  5540.                       +---------------+---------------+  +-+
  5541.  
  5542.  
  5543.                          GET_OBJECT Command Format
  5544.                                  Figure 59
  5545.  
  5546.  
  5547.  
  5548.      GET_OBJECT FIELDS:
  5549.  
  5550.      Name String
  5551.  
  5552.           The name of an object.
  5553.  
  5554.      Name Size
  5555.  
  5556.           The number of octets in this name string.  Must be even.
  5557.  
  5558.      Name Characters
  5559.  
  5560.           A string of octets composing the name.   Ends  with  a  null
  5561.           octet.   The  number  of  characters must be even, so if the
  5562.  
  5563.  
  5564.  
  5565.      Page 90
  5566.  
  5567.  
  5568.  
  5569.      LDP Specification                             Management Commands
  5570.  
  5571.  
  5572.  
  5573.           terminating null comes on an  odd  octet,  another  null  is
  5574.           appended.
  5575.  
  5576.  
  5577.  
  5578.  
  5579.  
  5580.  
  5581.      8.16  GOT_OBJECT Reply
  5582.  
  5583.           The target sends a GOT_OBJECT reply to the host in  response
  5584.      to  a  successful  GET_OBJECT  command.   The  reply contains the
  5585.      sequence number of the  GET_OBJECT  request,  and  the  specified
  5586.      object name converted into a descriptor.
  5587.  
  5588.  
  5589.  
  5590.                        0             0 0   1         1
  5591.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  5592.                       +---------------+---------------+
  5593.                     0 |               12              |
  5594.                       +---------------+---------------+
  5595.                     1 |   MANAGEMENT  | GOT_OBJECT    |
  5596.                       +---------------+---------------+
  5597.                     2 |      Get  Sequence Number     |
  5598.                       +---------------+---------------+  +-+
  5599.                     3 | Mode          | Mode Argument |   |
  5600.                       +---------------+---------------+   |
  5601.                     4 |                               |   |
  5602.                       +--             ID            --+   |  Object
  5603.                     5 |                               |   |  Descriptor
  5604.                       +---------------+---------------+  +-+
  5605.  
  5606.  
  5607.                           GOT_OBJECT Reply Format
  5608.                                  Figure 60
  5609.  
  5610.  
  5611.  
  5612.      GOT_OBJECT FIELDS:
  5613.  
  5614.      Get Sequence Number
  5615.  
  5616.           The sequence number of the GET_OBJECT command to which  this
  5617.           is the reply.
  5618.  
  5619.      Descriptor
  5620.  
  5621.  
  5622.  
  5623.                                                                Page 91
  5624.  
  5625.  
  5626.  
  5627.      RFC-909                                                 July 1984
  5628.  
  5629.  
  5630.  
  5631.           The  descriptor  of  the  object  named  in  the  GET_OBJECT
  5632.           command.
  5633.  
  5634.  
  5635.  
  5636.  
  5637.  
  5638.  
  5639.  
  5640.  
  5641.  
  5642.  
  5643.  
  5644.  
  5645.  
  5646.  
  5647.  
  5648.  
  5649.  
  5650.  
  5651.  
  5652.  
  5653.  
  5654.  
  5655.  
  5656.  
  5657.  
  5658.  
  5659.  
  5660.  
  5661.  
  5662.  
  5663.  
  5664.  
  5665.  
  5666.  
  5667.  
  5668.  
  5669.  
  5670.  
  5671.  
  5672.  
  5673.  
  5674.  
  5675.  
  5676.  
  5677.  
  5678.  
  5679.  
  5680.  
  5681.      Page 92
  5682.  
  5683.  
  5684.  
  5685.      LDP Specification                     Breakpoints and Watchpoints
  5686.  
  5687.  
  5688.  
  5689.                                  CHAPTER 9
  5690.  
  5691.  
  5692.                         Breakpoints and Watchpoints
  5693.  
  5694.  
  5695.  
  5696.           Breakpoints  and   watchpoints   are   used   in   debugging
  5697.      applications.   Each  breakpoint or watchpoint is associated with
  5698.      one debugger connection and one address.  When  a  breakpoint  or
  5699.      watchpoint is triggered, the target executes one or more commands
  5700.      associated with it.  A breakpoint is triggered when  its  address
  5701.      is  executed.   A  watchpoint  is  triggered  when its address is
  5702.      modified.  The same mechanism is used for structuring  breakpoint
  5703.      and  watchpoint  commands.  For brevity's sake, 'breakpoint' will
  5704.      be used in the remainder of this document to refer  to  either  a
  5705.      breakpoint or a watchpoint.
  5706.  
  5707.           The commands used by the host to manipulate breakpoints  are
  5708.      given in Figure 61, in the order in which they are normally used.
  5709.      All commands are sent from the  host  to  the  target,  and  each
  5710.      specifies the descriptor of a breakpoint.
  5711.  
  5712.  
  5713.       Command               Description
  5714.      ---------------------+------------------------------------
  5715.  
  5716.       CREATE                Create a breakpoint
  5717.       BREAKPOINT_DATA       Send commands to be executed in an
  5718.                             FSM breakpoint
  5719.       START                 Activate a breakpoint, set state
  5720.                             and initialize breakpoint variables
  5721.       STOP                  Deactivate a breakpoint
  5722.       CONTINUE              Activate a breakpoint
  5723.       LIST_BREAKPOINTS      List all breakpoints
  5724.       REPORT                Report the status of a breakpoint
  5725.       DELETE                Delete a breakpoint
  5726.  
  5727.  
  5728.                     Commands to Manipulate Breakpoints
  5729.                                  Figure 61
  5730.  
  5731.  
  5732.  
  5733.  
  5734.  
  5735.  
  5736.  
  5737.  
  5738.  
  5739.                                                                Page 93
  5740.  
  5741.  
  5742.  
  5743.      RFC-909                                                 July 1984
  5744.  
  5745.  
  5746.  
  5747.           There are two kinds of breakpoints:  default breakpoints and
  5748.      finite state machine (FSM) breakpoints.  They differ in their use
  5749.      of commands.
  5750.  
  5751.           Default breakpoints  do  not  contain  any  commands.   When
  5752.      triggered,  a  default  breakpoint stops the target object (i.e.,
  5753.      target process or application) it is located in.  A STATUS report
  5754.      on  the  stopped  object is sent to the host.  At this point, the
  5755.      host may send further commands to debug the target.
  5756.  
  5757.           An FSM breakpoint has one or more conditional command lists,
  5758.      organized into a finite state machine.  When an FSM breakpoint is
  5759.      created, the total number of states is specified.  The host  then
  5760.      sends commands (using BREAKPOINT_DATA) to be associated with each
  5761.      state.  The target maintains a state variable for the breakpoint,
  5762.      which  determines  which  command  list  will  be executed if the
  5763.      breakpoint is triggered.  When  the  breakpoint  is  created  its
  5764.      state  variable is initialized to zero (zero is the first state).
  5765.      A breakpoint command, SET_STATE, may be used within a  breakpoint
  5766.      to  change  the  value  of  the state variable.  A REPORT command
  5767.      applied to a breakpoint descriptor returns its  address,  whether
  5768.      it is armed or disarmed, and the value of its state variable.
  5769.  
  5770.           Commands valid in breakpoints include all  implemented  data
  5771.      transfer and control commands, a set of conditional commands, and
  5772.      a set of breakpoint commands.  The conditional commands  and  the
  5773.      breakpoint  commands  act on a set of local breakpoint variables.
  5774.      The  breakpoint  variables  consist  of  the  state  variable,  a
  5775.      counter,  and  two  pointer  variables.  The conditional commands
  5776.      control the execution of breakpoint command lists  based  on  the
  5777.      contents  of  one  of  the  breakpoint variables.  The breakpoint
  5778.      commands are used to set the value of the  breakpoint  variables:
  5779.      SET_STATE  sets  the  state  variable,  SET_PTR  sets  one of the
  5780.      pointer  variables,  and  INC_COUNT  increments  the   breakpoint
  5781.      counter.   There may be implementation restrictions on the number
  5782.      of breakpoints, the number of states, the number  of  conditions,
  5783.      and  the  size  of  the  command  lists.  Management commands and
  5784.      protocol commands are forbidden in breakpoints.
  5785.  
  5786.           In FSM breakpoints, the execution of commands is  controlled
  5787.      as  follows.   When  a  breakpoint is triggered, the breakpoint's
  5788.      state  variable  selects  a  particular  state.   One   or   more
  5789.      conditional  command  lists  is  associated  with  this state.  A
  5790.      conditional  command  list  consists  of  a  list  of  conditions
  5791.      followed  by  a  list  of  commands  which  are  executed  if the
  5792.      condition list is satisfied.  The debugger starts a breakpoint by
  5793.      executing  the  first  of  these lists.  If the condition list is
  5794.  
  5795.  
  5796.  
  5797.      Page 94
  5798.  
  5799.  
  5800.  
  5801.      LDP Specification                     Breakpoints and Watchpoints
  5802.  
  5803.  
  5804.  
  5805.      satisfied, the debugger executes the associated command list  and
  5806.      leaves the breakpoint.  If the condition list fails, the debugger
  5807.      skips  to  the  next  conditional  command  list.   This  process
  5808.      continues  until  the  debugger  either  encounters  a successful
  5809.      condition list, or exhausts all the conditional command lists for
  5810.      the  state.   The  relationship  of commands, lists and states is
  5811.      shown in Figure 62 (IFs,  THENs  and  ELSEs  are  used  below  to
  5812.      clarify  the  logical structure within a state; they are not part
  5813.      of the protocol).
  5814.  
  5815.  
  5816.                     State 0
  5817.                             IF <condition list 0>
  5818.                                THEN <command list 0>
  5819.  
  5820.                             ELSE IF <condition list 1>
  5821.                                THEN <command list 1>
  5822.  
  5823.                             *
  5824.                             *
  5825.                             *
  5826.  
  5827.                             ELSE IF <condition list n>
  5828.                                 THEN <command list n>
  5829.  
  5830.                             ELSE <exit>
  5831.                       *
  5832.                       *
  5833.                       *
  5834.                     State n
  5835.  
  5836.  
  5837.                    Breakpoint Conditional Command Lists
  5838.                                  Figure 62
  5839.  
  5840.  
  5841.  
  5842.  
  5843.  
  5844.      9.1  BREAKPOINT_DATA Command
  5845.  
  5846.           BREAKPOINT_DATA is a data transfer command used by the  host
  5847.      to  send  commands to be executed in breakpoints and watchpoints.
  5848.      The command  specifies  the  descriptor  of  the   breakpoint  or
  5849.      watchpoint, and a stream of commands to be appended to the end of
  5850.      the  breakpoint's  command  list.   BREAKPOINT_DATA  is   applied
  5851.      sequentially  to  successive  breakpoint  states,  and successive
  5852.  
  5853.  
  5854.  
  5855.                                                                Page 95
  5856.  
  5857.  
  5858.  
  5859.      RFC-909                                                 July 1984
  5860.  
  5861.  
  5862.  
  5863.      command lists within each state.  Multiple  BREAKPOINT_DATAs  may
  5864.      be  sent  for a given breakpoint.  Breaks between BREAKPOINT_DATA
  5865.      commands may occur anywhere within the data stream,  even  within
  5866.      individual  commands  in the data.  Sufficient space to store the
  5867.      data must have been allocated by the maximum size  field  in  the
  5868.      CREATE BREAKPOINT/WATCHPOINT command.
  5869.  
  5870.  
  5871.                   0             0 0   1         1
  5872.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  5873.                  +---------------+---------------+
  5874.                0 |        Command Length         |
  5875.                  +---------------+---------------+
  5876.                1 | DATA_TRANSFER |BREAKPOINT_DATA|
  5877.                  +---------------+---------------+  +-+
  5878.                2 |    Mode       | Mode Argument |   |
  5879.                  +---------------+---------------+   |  Breakpoint or
  5880.                3 |                               |   |  Watchpoint
  5881.                  +--            ID             --+   |  Descriptor
  5882.                4 |              Field            |   |
  5883.                  +-------------------------------+  +-+
  5884.                5 |     Data      |  Data         |   |
  5885.                  +-------------------------------+   |
  5886.                                  *                   |
  5887.                                  *                   |  Data
  5888.                                  *                   |
  5889.                  +---------------+---------------+   |
  5890.                n |     Data      |  Data or 0    |   |
  5891.                  +---------------+---------------+  +-+
  5892.  
  5893.  
  5894.                       BREAKPOINT_DATA Command Format
  5895.                                  Figure 63
  5896.  
  5897.  
  5898.      BREAKPOINT_DATA FIELDS:
  5899.  
  5900.      Command Length
  5901.  
  5902.           Total length of this  command  in  octets,  including  data,
  5903.           excluding the final padding octet, if any.
  5904.  
  5905.      Data
  5906.  
  5907.           A stream of data  to  be  appended  to  the  data  for  this
  5908.           breakpoint  or  watchpoint.  This stream has the form of one
  5909.           or more states, each  containing  one  or  more  conditional
  5910.  
  5911.  
  5912.  
  5913.      Page 96
  5914.  
  5915.  
  5916.  
  5917.      LDP Specification                     Breakpoints and Watchpoints
  5918.  
  5919.  
  5920.  
  5921.           command lists.  The first BREAKPOINT_DATA command sent for a
  5922.           breakpoint contains data starting with state zero.  The data
  5923.           for  each  state  starts with the state size.  A conditional
  5924.           command list is composed of two parts: a condition list, and
  5925.           a command list.  Each list begins with a word that gives its
  5926.           size in octets.
  5927.  
  5928.  
  5929.  
  5930.           <state 0 size>
  5931.                    <condition list 0 size> <condition list 0>
  5932.                    <command list 0 size>   <command list 0>
  5933.                               *
  5934.                               *
  5935.                               *
  5936.                    <condition list n size> <condition list n>
  5937.                    <command list n size>   <command list n>
  5938.           <state 1 size>
  5939.                             <etc>
  5940.                *
  5941.                *
  5942.                *
  5943.           <state n size>
  5944.  
  5945.  
  5946.                        Breakpoint Data Stream Format
  5947.                                  Figure 64
  5948.  
  5949.  
  5950.  
  5951.  
  5952.  
  5953.  
  5954.  
  5955.  
  5956.  
  5957.  
  5958.  
  5959.  
  5960.  
  5961.  
  5962.  
  5963.  
  5964.  
  5965.  
  5966.  
  5967.  
  5968.  
  5969.  
  5970.  
  5971.                                                                Page 97
  5972.  
  5973.  
  5974.  
  5975.      RFC-909                                                 July 1984
  5976.  
  5977.  
  5978.  
  5979.      Sizes
  5980.  
  5981.           All sizes are stored in 16-bit words, and include their  own
  5982.           length.   The state size gives the total number of octets of
  5983.           breakpoint data for the  state.   The  condition  list  size
  5984.           gives  the total octets of breakpoint data for the following
  5985.           condition list.  A condition list size  of  2  indicates  an
  5986.           empty  condition  list:  in  this case the following command
  5987.           list is executed unconditionally.   The  command  list  size
  5988.           gives  the total octets of breakpoint data for the following
  5989.           command list.
  5990.  
  5991.      Lists
  5992.  
  5993.           Condition  and  command  lists  come  in  pairs.   When  the
  5994.           breakpoint  occurs,  the condition list controls whether the
  5995.           following command list should be executed.  A condition list
  5996.           consists  of one or more commands from the CONDITION command
  5997.           class.  A command list consists one or  more  LDP  commands.
  5998.           Valid   commands  are  any  commands  from  the  BREAKPOINT,
  5999.           DATA_TRANSFER or CONTROL command classes.
  6000.  
  6001.  
  6002.  
  6003.  
  6004.  
  6005.  
  6006.  
  6007.  
  6008.  
  6009.  
  6010.  
  6011.  
  6012.  
  6013.  
  6014.  
  6015.  
  6016.  
  6017.  
  6018.  
  6019.  
  6020.  
  6021.  
  6022.  
  6023.  
  6024.  
  6025.  
  6026.  
  6027.  
  6028.  
  6029.      Page 98
  6030.  
  6031.  
  6032.  
  6033.      LDP Specification                            Conditional Commands
  6034.  
  6035.  
  6036.  
  6037.                                 CHAPTER 10
  6038.  
  6039.  
  6040.                            Conditional Commands
  6041.  
  6042.  
  6043.  
  6044.           Conditional commands are used in breakpoints to control  the
  6045.      execution  of  breakpoint  commands.   One  or more conditions in
  6046.      sequence form a condition list.  If a condition list is satisfied
  6047.      (evaluates  to  TRUE),  the  breakpoint  command list immediately
  6048.      following it is  executed.   (See  Breakpoints  and  Watchpoints,
  6049.      above,  for a discussion of the logic flow in conditional/command
  6050.      lists.) Conditional commands perform tests  on  local  breakpoint
  6051.      variables,  and  other  locations.   Each  condition evaluates to
  6052.      either  TRUE  or  FALSE.   Figure  65  contains  a   summary   of
  6053.      conditional commands:
  6054.  
  6055.  
  6056.       Command                       Description
  6057.      -----------------------------+------------------------------------
  6058.  
  6059.      CHANGED <loc>                  Determine if a location has changed
  6060.      COMPARE <loc1> <mask> <loc2>   Compare two locations, using a mask
  6061.      COUNT_[EQ | GT | LT] <value>   Compare the counter to a value
  6062.      TEST  <loc> <mask> <value>     Compare a location to a value
  6063.  
  6064.  
  6065.                         Conditional Command Summary
  6066.                                  Figure 65
  6067.  
  6068.  
  6069.      The rules for forming and evaluating condition lists are:
  6070.  
  6071.  
  6072.      o   consecutive conditions have an implicit logical  AND  between
  6073.          them.  A sequence of such conditions is called an 'and_list'.
  6074.          and_lists are delimited by an OR command and by  the  end  of
  6075.          the condition list.
  6076.  
  6077.      o   the breakpoint OR command may be inserted between any pair of
  6078.          conditions
  6079.  
  6080.      o   AND takes precedence over OR
  6081.  
  6082.      o   nested condition lists are not supported.  A  condition  list
  6083.          is simply one or more and_lists, separated by ORs.
  6084.  
  6085.  
  6086.  
  6087.                                                                Page 99
  6088.  
  6089.  
  6090.  
  6091.      RFC-909                                                 July 1984
  6092.  
  6093.  
  6094.  
  6095.      o   the condition list is evaluated in sequence  until  either  a
  6096.          TRUE  and_list  is found (condition list <- TRUE), or the end
  6097.          of the condition list is reached (condition list  <-  FALSE).
  6098.          An and_list is TRUE if all its conditions are TRUE.
  6099.  
  6100.      The distillation of these rules into BNF is:
  6101.  
  6102.          <condition_list> :== <and_list>  [OR <and_list>]*
  6103.          <and_list>       :== <condition> [AND <condition>]*
  6104.          <condition>      :== CHANGED | COMPARE | COUNT | TEST
  6105.  
  6106.          where:  OR  is a breakpoint command
  6107.                  AND is implicit for any pair of consecutive conditions
  6108.  
  6109.      For example, the following condition list, with one  command  per
  6110.      line,
  6111.  
  6112.          COUNT_EQ 1
  6113.          OR
  6114.          COUNT_GT 10
  6115.          COUNT_LT 20
  6116.  
  6117.      evaluates to:
  6118.  
  6119.          (COUNT = 1) OR (COUNT > 10  AND COUNT < 20)
  6120.  
  6121.      and will cause the command list that follows it to be executed if
  6122.      the counter is equal to one, or is between 10 and 20.
  6123.  
  6124.  
  6125.  
  6126.  
  6127.      10.1  Condition Command Format
  6128.  
  6129.           Condition  commands  start  with  the  standard   four-octet
  6130.      command  header.   The high-order bit of the command type byte is
  6131.      used as a negate flag:  if this bit is set, the boolean value  of
  6132.      the  condition  is  negated.   This flag applies to one condition
  6133.      only, and not to other conditions in the condition list.
  6134.  
  6135.  
  6136.  
  6137.  
  6138.  
  6139.  
  6140.  
  6141.  
  6142.  
  6143.  
  6144.  
  6145.      Page 100
  6146.  
  6147.  
  6148.  
  6149.      LDP Specification                            Conditional Commands
  6150.  
  6151.  
  6152.  
  6153.  
  6154.  
  6155.                   0             0 0   1         1
  6156.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6157.                  +---------------+---------------+
  6158.                0 |        Command Length         |
  6159.                  +---------------+---------------+
  6160.                1 | CONDITION     |N|    Type     |
  6161.                  +---------------+---------------+
  6162.  
  6163.  
  6164.                          Condition Command Header
  6165.                                  Figure 66
  6166.  
  6167.  
  6168.  
  6169.  
  6170.  
  6171.  
  6172.      10.2  COUNT Conditions
  6173.  
  6174.           The COUNT conditions (COUNT_EQ, COUNT_GT and  COUNT_LT)  are
  6175.      used to compare the breakpoint counter to a specified value.  The
  6176.      counter is set to zero when the breakpoint  is  STARTed,  and  is
  6177.      incremented  by  the INC_COUNT breakpoint command.  The format is
  6178.      the same for the COUNT_EQ, COUNT_GT and COUNT_LT conditions.
  6179.  
  6180.  
  6181.                   0             0 0   1         1
  6182.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6183.                  +---------------+---------------+
  6184.                0 |               8               |
  6185.                  +---------------+---------------+
  6186.                1 | CONDITION     |N|  Type       |
  6187.                  +---------------+---------------+
  6188.                2 |                               |
  6189.                  +--          Value            --+
  6190.                3 |                               |
  6191.                  +---------------+---------------+
  6192.  
  6193.  
  6194.                           COUNT Condition Format
  6195.                                  Figure 67
  6196.  
  6197.  
  6198.      COUNT_* Condition FIELDS:
  6199.  
  6200.  
  6201.  
  6202.  
  6203.                                                               Page 101
  6204.  
  6205.  
  6206.  
  6207.      RFC-909                                                 July 1984
  6208.  
  6209.  
  6210.  
  6211.      Type
  6212.  
  6213.           One of COUNT_EQ, COUNT_LT and COUNT_GT.   The  condition  is
  6214.           TRUE  if  the  breakpoint  counter  is  [EQ  |  LT | GT] the
  6215.           specified value.
  6216.  
  6217.      Value
  6218.  
  6219.           A 32-bit value to be compared to the counter.
  6220.  
  6221.  
  6222.  
  6223.  
  6224.  
  6225.      10.3  CHANGED Condition
  6226.  
  6227.           The CHANGED  condition  is  TRUE  if  the  contents  of  the
  6228.      specified   location  have  changed  since  the  last  time  this
  6229.      breakpoint occurred.  Only one location may be specified  as  the
  6230.      object   of  CHANGED  conditions  per  breakpoint.   The  CHANGED
  6231.      condition is always FALSE the first time the breakpoint occurs.
  6232.  
  6233.  
  6234.                   0             0 0   1         1
  6235.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6236.                  +---------------+---------------+
  6237.                0 |              14               |
  6238.                  +---------------+---------------+
  6239.                1 | CONDITION     |N|  CHANGED    |
  6240.                  +---------------+---------------+
  6241.                2 |                               |
  6242.                  +--                           --+
  6243.                3 |            Address            |
  6244.                  +--                           --+
  6245.                4 |                               |
  6246.                  +--                           --+
  6247.                5 |                               |
  6248.                  +--                           --+
  6249.                6 |                               |
  6250.                  +---------------+---------------+
  6251.  
  6252.  
  6253.                              CHANGED Condition
  6254.                                  Figure 68
  6255.  
  6256.  
  6257.  
  6258.  
  6259.  
  6260.  
  6261.      Page 102
  6262.  
  6263.  
  6264.  
  6265.      LDP Specification                            Conditional Commands
  6266.  
  6267.  
  6268.  
  6269.      CHANGED FIELDS:
  6270.  
  6271.      Address
  6272.  
  6273.           The full 5-word address of the location to be tested by  the
  6274.           CHANGED command.
  6275.  
  6276.  
  6277.  
  6278.  
  6279.      10.4  COMPARE Condition
  6280.  
  6281.           The COMPARE condition compares two locations using  a  mask.
  6282.      The condition is TRUE if (<loc1> & <mask>) = (<loc2> & <mask>).
  6283.  
  6284.  
  6285.  
  6286.  
  6287.  
  6288.  
  6289.  
  6290.  
  6291.  
  6292.  
  6293.  
  6294.  
  6295.  
  6296.  
  6297.  
  6298.  
  6299.  
  6300.  
  6301.  
  6302.  
  6303.  
  6304.  
  6305.  
  6306.  
  6307.  
  6308.  
  6309.  
  6310.  
  6311.  
  6312.  
  6313.  
  6314.  
  6315.  
  6316.  
  6317.  
  6318.  
  6319.                                                               Page 103
  6320.  
  6321.  
  6322.  
  6323.      RFC-909                                                 July 1984
  6324.  
  6325.  
  6326.  
  6327.  
  6328.  
  6329.                   0             0 0   1         1
  6330.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6331.                  +---------------+---------------+
  6332.                0 |              28               |
  6333.                  +---------------+---------------+
  6334.                1 | CONDITION     |N|  COMPARE    |
  6335.                  +---------------+---------------+
  6336.                2 |                               |
  6337.                  +--                           --+
  6338.                3 |            Address 1          |
  6339.                  +--                           --+
  6340.                4 |                               |
  6341.                  +--                           --+
  6342.                5 |                               |
  6343.                  +--                           --+
  6344.                6 |                               |
  6345.                  +---------------+---------------+
  6346.                7 |                               |
  6347.                  +--          Mask             --+
  6348.                8 |                               |
  6349.                  +-------------------------------+
  6350.                9 |                               |
  6351.                  +--                           --+
  6352.                10|            Address 2          |
  6353.                  +--                           --+
  6354.                11|                               |
  6355.                  +--                           --+
  6356.                12|                               |
  6357.                  +--                           --+
  6358.                13|                               |
  6359.                  +-------------------------------+
  6360.  
  6361.                              COMPARE Condition
  6362.                                  Figure 69
  6363.  
  6364.  
  6365.  
  6366.  
  6367.  
  6368.  
  6369.  
  6370.  
  6371.  
  6372.  
  6373.  
  6374.  
  6375.  
  6376.  
  6377.      Page 104
  6378.  
  6379.  
  6380.  
  6381.      LDP Specification                            Conditional Commands
  6382.  
  6383.  
  6384.  
  6385.      COMPARE FIELDS:
  6386.  
  6387.      Address 1
  6388.      Address 2
  6389.  
  6390.           The 5-word addresses of the locations to be compared.
  6391.  
  6392.      Mask
  6393.  
  6394.           A 32-bit mask specifying which bits in the locations  should
  6395.           be compared.
  6396.  
  6397.  
  6398.  
  6399.  
  6400.  
  6401.  
  6402.      10.5  TEST Condition
  6403.  
  6404.           The TEST condition is used to compare a location to a value,
  6405.      using  a  mask.   The  condition  is  TRUE  if (<loc> & <mask>) =
  6406.      <value>.
  6407.  
  6408.  
  6409.  
  6410.  
  6411.  
  6412.  
  6413.  
  6414.  
  6415.  
  6416.  
  6417.  
  6418.  
  6419.  
  6420.  
  6421.  
  6422.  
  6423.  
  6424.  
  6425.  
  6426.  
  6427.  
  6428.  
  6429.  
  6430.  
  6431.  
  6432.  
  6433.  
  6434.  
  6435.                                                               Page 105
  6436.  
  6437.  
  6438.  
  6439.      RFC-909                                                 July 1984
  6440.  
  6441.  
  6442.  
  6443.  
  6444.  
  6445.                   0             0 0   1         1
  6446.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6447.                  +---------------+---------------+
  6448.                0 |              22               |
  6449.                  +---------------+---------------+
  6450.                1 | CONDITION     |N|  TEST       |
  6451.                  +---------------+---------------+
  6452.                2 |                               |
  6453.                  +--                           --+
  6454.                3 |            Address            |
  6455.                  +--                           --+
  6456.                4 |                               |
  6457.                  +--                           --+
  6458.                5 |                               |
  6459.                  +--                           --+
  6460.                6 |                               |
  6461.                  +---------------+---------------+
  6462.                7 |                               |
  6463.                  +--          Mask             --+
  6464.                8 |                               |
  6465.                  +-------------------------------+
  6466.                9 |                               |
  6467.                  +--          Value            --+
  6468.                10|                               |
  6469.                  +-------------------------------+
  6470.  
  6471.                               TEST Condition
  6472.                                  Figure 70
  6473.  
  6474.  
  6475.      TEST FIELDS:
  6476.  
  6477.      Address
  6478.  
  6479.           The 5-word address of the location to  be  compared  to  the
  6480.           value.
  6481.  
  6482.      Mask
  6483.  
  6484.           A 32-bit mask specifying which bits in the  location  should
  6485.           be compared.
  6486.  
  6487.      Value
  6488.  
  6489.           A 32-bit value to compare to the masked location.
  6490.  
  6491.  
  6492.  
  6493.      Page 106
  6494.  
  6495.  
  6496.  
  6497.      LDP Specification                            Conditional Commands
  6498.  
  6499.  
  6500.  
  6501.  
  6502.  
  6503.  
  6504.  
  6505.  
  6506.  
  6507.  
  6508.  
  6509.  
  6510.  
  6511.  
  6512.  
  6513.  
  6514.  
  6515.  
  6516.  
  6517.  
  6518.  
  6519.  
  6520.  
  6521.  
  6522.  
  6523.  
  6524.  
  6525.  
  6526.  
  6527.  
  6528.  
  6529.  
  6530.  
  6531.  
  6532.  
  6533.  
  6534.  
  6535.  
  6536.  
  6537.  
  6538.  
  6539.  
  6540.  
  6541.  
  6542.  
  6543.  
  6544.  
  6545.  
  6546.  
  6547.  
  6548.  
  6549.  
  6550.  
  6551.                                                               Page 107
  6552.  
  6553.  
  6554.  
  6555.      RFC-909                                                 July 1984
  6556.  
  6557.  
  6558.  
  6559.  
  6560.  
  6561.  
  6562.  
  6563.  
  6564.  
  6565.  
  6566.  
  6567.  
  6568.  
  6569.  
  6570.  
  6571.  
  6572.  
  6573.  
  6574.  
  6575.  
  6576.  
  6577.  
  6578.  
  6579.  
  6580.  
  6581.  
  6582.  
  6583.  
  6584.  
  6585.  
  6586.  
  6587.  
  6588.  
  6589.  
  6590.  
  6591.  
  6592.  
  6593.  
  6594.  
  6595.  
  6596.  
  6597.  
  6598.  
  6599.  
  6600.  
  6601.  
  6602.  
  6603.  
  6604.  
  6605.  
  6606.  
  6607.  
  6608.  
  6609.      Page 108
  6610.  
  6611.  
  6612.  
  6613.      LDP Specification                             Breakpoint Commands
  6614.  
  6615.  
  6616.  
  6617.                                 CHAPTER 11
  6618.  
  6619.  
  6620.                             Breakpoint Commands
  6621.  
  6622.  
  6623.  
  6624.           Breakpoint commands are used to set the value of  breakpoint
  6625.      variables.   These commands are only valid within breakpoints and
  6626.      watchpoints.  They are sent from the host to the target  as  data
  6627.      in  BREAKPOINT_DATA  commands.   Figure  71 contains a summary of
  6628.      breakpoint commands:
  6629.  
  6630.  
  6631.       Command                  Description
  6632.      ------------------------+-------------------------------------
  6633.  
  6634.      INCREMENT <location>      Increment the specified location
  6635.      INC_COUNT                 Increment the breakpoint counter
  6636.      OR                        OR two breakpoint condition lists
  6637.      SET_PTR <n> <location>    Set pointer <n> to the contents of
  6638.                                <location>
  6639.      SET_STATE <n>             Set the breakpoint state variable
  6640.                                to <n>
  6641.  
  6642.  
  6643.                         Breakpoint Command Summary
  6644.                                  Figure 71
  6645.  
  6646.  
  6647.  
  6648.  
  6649.  
  6650.  
  6651.      11.1  INCREMENT Command
  6652.  
  6653.           The INCREMENT command increments the contents of a specified
  6654.      location.  The location may be in any address space writable from
  6655.      LDP.
  6656.  
  6657.  
  6658.  
  6659.  
  6660.  
  6661.  
  6662.  
  6663.  
  6664.  
  6665.  
  6666.  
  6667.                                                               Page 109
  6668.  
  6669.  
  6670.  
  6671.      RFC-909                                                 July 1984
  6672.  
  6673.  
  6674.  
  6675.  
  6676.  
  6677.                   0             0 0   1         1
  6678.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6679.                  +---------------+---------------+
  6680.                0 |               14              |
  6681.                  +---------------+---------------+
  6682.                1 | BREAKPOINT    |  INCREMENT    |
  6683.                  +---------------+---------------+
  6684.                2 |                               |
  6685.                  +--                           --+
  6686.                3 |            Address            |
  6687.                  +--                           --+
  6688.                4 |                               |
  6689.                  +--                           --+
  6690.                5 |                               |
  6691.                  +--                           --+
  6692.                6 |                               |
  6693.                  +---------------+---------------+
  6694.  
  6695.  
  6696.                          INCREMENT Command Format
  6697.                                  Figure 72
  6698.  
  6699.  
  6700.      INCREMENT FIELDS:
  6701.  
  6702.      Address
  6703.  
  6704.           The full address of the location whose contents  are  to  be
  6705.           incremented.
  6706.  
  6707.  
  6708.  
  6709.  
  6710.      11.2  INC_COUNT Command
  6711.  
  6712.           The INC_COUNT command  increments  the  breakpoint  counter.
  6713.      There  is  one  counter  variable  for  each   breakpoint.  It is
  6714.      initialized to zero when the breakpoint is created,  when  it  is
  6715.      armed  with  the START command, and whenever the breakpoint state
  6716.      changes.  The counter is tested by the COUNT_* conditions.
  6717.  
  6718.  
  6719.  
  6720.  
  6721.  
  6722.  
  6723.  
  6724.  
  6725.      Page 110
  6726.  
  6727.  
  6728.  
  6729.      LDP Specification                             Breakpoint Commands
  6730.  
  6731.  
  6732.  
  6733.  
  6734.  
  6735.                   0             0 0   1         1
  6736.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6737.                  +---------------+---------------+
  6738.                0 |               4               |
  6739.                  +---------------+---------------+
  6740.                1 | BREAKPOINT    |  INC_COUNT    |
  6741.                  +---------------+---------------+
  6742.  
  6743.  
  6744.                          INC_COUNT Command Format
  6745.                                  Figure 73
  6746.  
  6747.  
  6748.  
  6749.  
  6750.  
  6751.  
  6752.      11.3  OR Command
  6753.  
  6754.           The OR command delineates  two  and_lists  in  a  breakpoint
  6755.      condition  list.   A  condition  list  is  TRUE  if any of the OR
  6756.      separated and_lists in it are TRUE.  A breakpoint condition  list
  6757.      may  contain  zero,  one  or,  many  OR commands.  See 'Condition
  6758.      Commands' for an explanation of condition lists.
  6759.  
  6760.  
  6761.  
  6762.                   0             0 0   1         1
  6763.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6764.                  +---------------+---------------+
  6765.                0 |               4               |
  6766.                  +---------------+---------------+
  6767.                1 | BREAKPOINT    |      OR       |
  6768.                  +---------------+---------------+
  6769.  
  6770.  
  6771.                              OR Command Format
  6772.                                  Figure 74
  6773.  
  6774.  
  6775.  
  6776.  
  6777.  
  6778.  
  6779.  
  6780.  
  6781.  
  6782.  
  6783.                                                               Page 111
  6784.  
  6785.  
  6786.  
  6787.      RFC-909                                                 July 1984
  6788.  
  6789.  
  6790.  
  6791.      11.4  SET_PTR Command
  6792.  
  6793.           The SET_PTR command loads the specified  breakpoint  pointer
  6794.      with  the  contents of a location.  The pointer variables and the
  6795.      SET_PTR command are intended to provide a primitive but unlimited
  6796.      indirect    addressing   capability.    Two   addressing   modes,
  6797.      BPT_PTR_OFFSET and BPT_PTR_INDIRECT, are used for referencing the
  6798.      breakpoint  pointers.   For example, to follow a linked list, use
  6799.      SET_PTR to load a pointer with the start of the  list,  then  use
  6800.      successive  SET_PTR  commands with addressing mode BPT_PTR_OFFSET
  6801.      to get successive elements.
  6802.  
  6803.  
  6804.  
  6805.                   0             0 0   1         1
  6806.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6807.                  +---------------+---------------+
  6808.                0 |               16              |
  6809.                  +---------------+---------------+
  6810.                1 | BREAKPOINT    |  SET_PTR      |
  6811.                  +---------------+---------------+
  6812.                2 |            Pointer            |
  6813.                  +---------------+---------------+
  6814.                3 |                               |
  6815.                  +--                           --+
  6816.                4 |            Address            |
  6817.                  +--                           --+
  6818.                5 |                               |
  6819.                  +--                           --+
  6820.                6 |                               |
  6821.                  +--                           --+
  6822.                7 |                               |
  6823.                  +---------------+---------------+
  6824.  
  6825.  
  6826.                           SET_PTR Command Format
  6827.                                  Figure 75
  6828.  
  6829.  
  6830.      SET_PTR FIELDS:
  6831.  
  6832.      Pointer
  6833.  
  6834.           The pointer to be changed.  Allowable values are 0 and 1.
  6835.  
  6836.      Address
  6837.  
  6838.  
  6839.  
  6840.  
  6841.      Page 112
  6842.  
  6843.  
  6844.  
  6845.      LDP Specification                             Breakpoint Commands
  6846.  
  6847.  
  6848.  
  6849.           The full address of the location whose contents  are  to  be
  6850.           loaded into the given pointer variable.
  6851.  
  6852.  
  6853.  
  6854.  
  6855.  
  6856.      11.5  SET_STATE Command
  6857.  
  6858.           The SET_STATE command sets the breakpoint state variable  to
  6859.      the  specified  value.   This  is  the  only method of changing a
  6860.      breakpoint's state from within  a  breakpoint.  The  breakpoint's
  6861.      state  may  be  also be changed by a START command from the host.
  6862.      The state variable is initialized to zero when the breakpoint  is
  6863.      created.
  6864.  
  6865.  
  6866.                   0             0 0   1         1
  6867.                   0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6868.                  +---------------+---------------+
  6869.                0 |               6               |
  6870.                  +---------------+---------------+
  6871.                1 | BREAKPOINT    |  SET_STATE    |
  6872.                  +---------------+---------------+
  6873.                2 |         State Value           |
  6874.                  +-------------------------------+
  6875.  
  6876.  
  6877.                          SET_STATE Command Format
  6878.                                  Figure 76
  6879.  
  6880.  
  6881.      SET_STATE FIELDS:
  6882.  
  6883.      State Value
  6884.  
  6885.           The new value for the breakpoint state variable.   Must  not
  6886.           be  greater  than  the  maximum state value specified in the
  6887.           CREATE BREAKPOINT command that created this breakpoint.
  6888.  
  6889.  
  6890.  
  6891.  
  6892.  
  6893.  
  6894.  
  6895.  
  6896.  
  6897.  
  6898.  
  6899.                                                               Page 113
  6900.  
  6901.  
  6902.  
  6903.      RFC-909                                                 July 1984
  6904.  
  6905.  
  6906.  
  6907.  
  6908.  
  6909.  
  6910.  
  6911.  
  6912.  
  6913.  
  6914.  
  6915.  
  6916.  
  6917.  
  6918.  
  6919.  
  6920.  
  6921.  
  6922.  
  6923.  
  6924.  
  6925.  
  6926.  
  6927.  
  6928.  
  6929.  
  6930.  
  6931.  
  6932.  
  6933.  
  6934.  
  6935.  
  6936.  
  6937.  
  6938.  
  6939.  
  6940.  
  6941.  
  6942.  
  6943.  
  6944.  
  6945.  
  6946.  
  6947.  
  6948.  
  6949.  
  6950.  
  6951.  
  6952.  
  6953.  
  6954.  
  6955.  
  6956.  
  6957.      Page 114
  6958.  
  6959.  
  6960.  
  6961.      LDP Specification                             Diagram Conventions
  6962.  
  6963.  
  6964.  
  6965.                                 APPENDIX A
  6966.  
  6967.  
  6968.                             Diagram Conventions
  6969.  
  6970.  
  6971.  
  6972.           Command and message diagrams are used in  this  document  to
  6973.      illustrate  the  format  of these entities.   Words are listed in
  6974.      order of transmission down the page.   The  first  word  is  word
  6975.      zero.   Bits within a word run left to right, most significant to
  6976.      least.   However,   following  a  convention  observed  in  other
  6977.      protocol  documents,  bits are numbered in order of transmission;
  6978.      the most significant bit in a word is transmitted first.  The bit
  6979.      labelled '0' is the most significant bit.
  6980.  
  6981.  
  6982.  
  6983.                        0             0 0   1         1
  6984.                        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
  6985.                       +---------------+---------------+
  6986.                     0 |M|                           |L|
  6987.                       +---------------+---------------+
  6988.                     1 | Most Sig Octet| Least S. Octet|
  6989.                       +---------------+---------------+
  6990.  
  6991.                       M = most significant bit in word zero,
  6992.                           transmitted first
  6993.                       L = least significant bit in word zero,
  6994.                           transmitted last
  6995.  
  6996.  
  6997.                               Sample Diagram
  6998.                                  Figure 77
  6999.  
  7000.  
  7001.  
  7002.  
  7003.  
  7004.  
  7005.  
  7006.  
  7007.  
  7008.  
  7009.  
  7010.  
  7011.  
  7012.  
  7013.  
  7014.  
  7015.                                                               Page 115
  7016.  
  7017.  
  7018.  
  7019.      RFC-909                                                 July 1984
  7020.  
  7021.  
  7022.  
  7023.  
  7024.  
  7025.  
  7026.  
  7027.  
  7028.  
  7029.  
  7030.  
  7031.  
  7032.  
  7033.  
  7034.  
  7035.  
  7036.  
  7037.  
  7038.  
  7039.  
  7040.  
  7041.  
  7042.  
  7043.  
  7044.  
  7045.  
  7046.  
  7047.  
  7048.  
  7049.  
  7050.  
  7051.  
  7052.  
  7053.  
  7054.  
  7055.  
  7056.  
  7057.  
  7058.  
  7059.  
  7060.  
  7061.  
  7062.  
  7063.  
  7064.  
  7065.  
  7066.  
  7067.  
  7068.  
  7069.  
  7070.  
  7071.  
  7072.  
  7073.      Page 116
  7074.  
  7075.  
  7076.  
  7077.      LDP Specification                                 Command Summary
  7078.  
  7079.  
  7080.  
  7081.                                 APPENDIX B
  7082.  
  7083.  
  7084.                               Command Summary
  7085.  
  7086.  
  7087.  
  7088.           The following table lists all non-breakpoint LDP commands in
  7089.      alphabetical order, with a brief description of each.
  7090.  
  7091.  
  7092.  
  7093.  
  7094.  
  7095.  
  7096.  
  7097.  
  7098.  
  7099.  
  7100.  
  7101.  
  7102.  
  7103.  
  7104.  
  7105.  
  7106.  
  7107.  
  7108.  
  7109.  
  7110.  
  7111.  
  7112.  
  7113.  
  7114.  
  7115.  
  7116.  
  7117.  
  7118.  
  7119.  
  7120.  
  7121.  
  7122.  
  7123.  
  7124.  
  7125.  
  7126.  
  7127.  
  7128.  
  7129.  
  7130.  
  7131.                                                               Page 117
  7132.  
  7133.  
  7134.  
  7135.      RFC-909                                                 July 1984
  7136.  
  7137.  
  7138.  
  7139.  
  7140.  
  7141.                             Sender
  7142.      Command            | Host Target | Function
  7143.      -------------------+-------------+---------------------------
  7144.  
  7145.      ABORT                 X            Abort outstanding commands
  7146.      ABORT_DONE                  X      Acknowledge ABORT
  7147.      ADDRESS_LIST                X      Return valid address ranges
  7148.      BREAKPOINT_DATA       X            Send breakpoint commands
  7149.      BREAKPOINT_LIST             X      Return list of breakpoints
  7150.      CONTINUE              X            Resume execution
  7151.      CREATE                X            Create target object
  7152.      CREATE_DONE                 X      Acknowledge CREATE
  7153.      DELETE                X            Delete target object
  7154.      DELETE_DONE                 X      Acknowledge DELETE
  7155.      EXCEPTION                   X      Report target exception
  7156.      ERROR                       X      Report error with a host command
  7157.      ERRACK                X            Acknowledge ERROR
  7158.      GET_OBJECT            X            Get object descriptor from name
  7159.      GET_PHYS_ADDRESS      X            Get address in physical form
  7160.      GOT_OBJECT                  X      Return object descriptor
  7161.      GOT_PHYS_ADDRESS            X      Return physical address
  7162.      HELLO                 X            Initiate LDP session
  7163.      HELLO_REPLY                 X      Return LDP parameters
  7164.      LIST_ADDRESSES        X            Request valid address ranges
  7165.      LIST_BREAKPOINTS      X            Request breakpoint list
  7166.      LIST_NAMES            X            Request name list
  7167.      LIST_PROCESSES        X            Request process list
  7168.      MOVE                  X            Read data from target
  7169.      MOVE_DONE                   X      Acknowledge MOVE completion
  7170.      MOVE_DATA                   X      Send data request by MOVE
  7171.      NAME_LIST                   X      Return name list
  7172.      PROCESS_LIST                X      Return process list
  7173.      READ                  X            Read data from target
  7174.      READ_DATA                   X      Return data requested by READ
  7175.      READ_DONE                   X      Acknowledge READ completion
  7176.      REPEAT_DATA           X            Write copies of data
  7177.      REPORT                X            Request status of object
  7178.      START                 X            Start target object
  7179.      STATUS                      X      Return status of object
  7180.      STEP                  X            Step execution of target object
  7181.      STOP                  X            Stop target object
  7182.      SYNCH                 X            Check sequence number
  7183.      SYNCH_REPLY                 X      Confirm sequence number
  7184.      WRITE                 X            Write data
  7185.      WRITE_MASK            X            Write data with mask
  7186.  
  7187.  
  7188.  
  7189.      Page 118
  7190.  
  7191.  
  7192.  
  7193.      LDP Specification                                 Command Summary
  7194.  
  7195.  
  7196.  
  7197.                               Command Summary
  7198.                                  Figure 78
  7199.  
  7200.  
  7201.  
  7202.  
  7203.  
  7204.  
  7205.  
  7206.  
  7207.  
  7208.  
  7209.  
  7210.  
  7211.  
  7212.  
  7213.  
  7214.  
  7215.  
  7216.  
  7217.  
  7218.  
  7219.  
  7220.  
  7221.  
  7222.  
  7223.  
  7224.  
  7225.  
  7226.  
  7227.  
  7228.  
  7229.  
  7230.  
  7231.  
  7232.  
  7233.  
  7234.  
  7235.  
  7236.  
  7237.  
  7238.  
  7239.  
  7240.  
  7241.  
  7242.  
  7243.  
  7244.  
  7245.  
  7246.  
  7247.                                                               Page 119
  7248.  
  7249.  
  7250.  
  7251.      RFC-909                                                 July 1984
  7252.  
  7253.  
  7254.  
  7255.  
  7256.  
  7257.  
  7258.  
  7259.  
  7260.  
  7261.  
  7262.  
  7263.  
  7264.  
  7265.  
  7266.  
  7267.  
  7268.  
  7269.  
  7270.  
  7271.  
  7272.  
  7273.  
  7274.  
  7275.  
  7276.  
  7277.  
  7278.  
  7279.  
  7280.  
  7281.  
  7282.  
  7283.  
  7284.  
  7285.  
  7286.  
  7287.  
  7288.  
  7289.  
  7290.  
  7291.  
  7292.  
  7293.  
  7294.  
  7295.  
  7296.  
  7297.  
  7298.  
  7299.  
  7300.  
  7301.  
  7302.  
  7303.  
  7304.  
  7305.      Page 120
  7306.  
  7307.  
  7308.  
  7309.      LDP Specification                 Commands, Responses and Replies
  7310.  
  7311.  
  7312.  
  7313.                                 APPENDIX C
  7314.  
  7315.  
  7316.                       Commands, Responses and Replies
  7317.  
  7318.  
  7319.  
  7320.           The following table shows the relationship between commands,
  7321.      responses  and  replies.   Commands are sent from the host to the
  7322.      target.  Some commands elicit responses and/or replies  from  the
  7323.      target.   Responses  and  replies are sent from the target to the
  7324.      host.  The distinction between them is that the target sends only
  7325.      one  reply  to  a  command,  but  may  send  multiple  responses.
  7326.      Responses always contain data, whereas replies may or may not.
  7327.  
  7328.  
  7329.  
  7330.  
  7331.  
  7332.  
  7333.  
  7334.  
  7335.  
  7336.  
  7337.  
  7338.  
  7339.  
  7340.  
  7341.  
  7342.  
  7343.  
  7344.  
  7345.  
  7346.  
  7347.  
  7348.  
  7349.  
  7350.  
  7351.  
  7352.  
  7353.  
  7354.  
  7355.  
  7356.  
  7357.  
  7358.  
  7359.  
  7360.  
  7361.  
  7362.  
  7363.                                                               Page 121
  7364.  
  7365.  
  7366.  
  7367.      RFC-909                                                 July 1984
  7368.  
  7369.  
  7370.  
  7371.  
  7372.  
  7373.  
  7374.           Command            | Response     | Reply
  7375.           -------------------+--------------+------------------
  7376.  
  7377.           ABORT                               ABORT_DONE
  7378.           BREAKPOINT_DATA
  7379.           CONTINUE
  7380.           CREATE                              CREATE_DONE
  7381.           DELETE                              DELETE_DONE
  7382.           GET_OBJECT                          GOT_OBJECT
  7383.           GET_PHYS_ADDRESS                    GOT_PHYS_ADDRESS
  7384.           HELLO                               HELLO_REPLY
  7385.           LIST_ADDRESSES                      ADDRESS_LIST
  7386.           LIST_BREAKPOINTS                    BREAKPOINT_LIST
  7387.           LIST_NAMES                          NAME_LIST
  7388.           LIST_PROCESSES                      PROCESS_LIST
  7389.           MOVE               MOVE_DATA        MOVE_DONE
  7390.           READ               READ_DATA        READ_DONE
  7391.           REPEAT_DATA
  7392.           REPORT                              STATUS
  7393.           START
  7394.           STEP
  7395.           STOP
  7396.           SYNCH                               SYNCH_REPLY
  7397.           WRITE
  7398.           WRITE_MASK
  7399.  
  7400.  
  7401.                       Commands, Responses and Replies
  7402.                                  Figure 79
  7403.  
  7404.  
  7405.  
  7406.  
  7407.  
  7408.  
  7409.  
  7410.  
  7411.  
  7412.  
  7413.  
  7414.  
  7415.  
  7416.  
  7417.  
  7418.  
  7419.  
  7420.  
  7421.      Page 122
  7422.  
  7423.  
  7424.  
  7425.      LDP Specification                                        Glossary
  7426.  
  7427.  
  7428.  
  7429.                                 APPENDIX D
  7430.  
  7431.  
  7432.                                  Glossary
  7433.  
  7434.  
  7435.  
  7436.  
  7437.      FSM
  7438.  
  7439.           Finite  state  machine.   Commands  of  each  breakpoint  or
  7440.           watchpoint   are  implemented  as  part  of  a  finite state
  7441.           machine.  A list of breakpoint commands is  associated  with
  7442.           each state.  There are several breakpoint commands to change
  7443.           from one state to another.
  7444.      host
  7445.  
  7446.           The 'host' in an LDP session is the  timesharing  system  on
  7447.           which the user process runs.
  7448.  
  7449.  
  7450.      long
  7451.  
  7452.           A long is a 32-bit quantity.
  7453.  
  7454.      octet
  7455.  
  7456.           An octet is an eight-bit quantity.
  7457.  
  7458.      RDP
  7459.  
  7460.           The  Reliable  Data  Protocol  (RDP) is  a  transport  layer
  7461.           protocol designed as a low-overhead alternative to TCP.  RDP
  7462.           is a connection oriented protocol  that  provides  reliable,
  7463.           sequenced message delivery.
  7464.  
  7465.      server process
  7466.  
  7467.           The LDP server process is the passive participant in an  LDP
  7468.           session.   The  server  process  usually resides on a target
  7469.           machine such as a PAD, PSN or gateway.  The  server  process
  7470.           waits for a user process to initiate a session, and responds
  7471.           to commands from the user  process.   In  response  to  user
  7472.           commands, the server may perform services on the target like
  7473.           reading and writing memory locations or setting breakpoints.
  7474.           'Server'  is  sometimes  employed as a shorthand for 'server
  7475.           process'.
  7476.  
  7477.  
  7478.  
  7479.                                                               Page 123
  7480.  
  7481.  
  7482.  
  7483.      RFC-909                                                 July 1984
  7484.  
  7485.  
  7486.  
  7487.      target
  7488.  
  7489.           The 'target' in an LDP session is the PSN,  PAD  or  gateway
  7490.           that  is  being  loaded,  dumped  or  debugged  by the host.
  7491.           Normally, LDP will be implemented in the target as a  server
  7492.           process.     However,   in   some   targets   with   strange
  7493.           requirements, notably the Butterfly, the target LDP may be a
  7494.           user process.
  7495.  
  7496.  
  7497.      user process
  7498.  
  7499.           The LDP user process is the active  participant  in  an  LDP
  7500.           session.   The  user  process  initiates  and terminates the
  7501.           session and sends commands  to  the  server  process   which
  7502.           control  the session.  The user process usually resides on a
  7503.           timesharing host and is  driven  by  a  higher-level  entity
  7504.           (e.g., an application program like an interactive debugger).
  7505.           'User' is  sometimes  employed  as  a  shorthand  for  'user
  7506.           process'.
  7507.  
  7508.  
  7509.      word
  7510.  
  7511.           A word is a sixteen-bit quantity.
  7512.  
  7513.  
  7514.  
  7515.  
  7516.  
  7517.  
  7518.  
  7519.  
  7520.  
  7521.  
  7522.  
  7523.  
  7524.  
  7525.  
  7526.  
  7527.  
  7528.  
  7529.  
  7530.  
  7531.  
  7532.  
  7533.  
  7534.  
  7535.  
  7536.  
  7537.      Page 124
  7538.  
  7539.  
  7540.  
  7541.  
  7542.  
  7543.  
  7544.  
  7545.                                    INDEX
  7546.  
  7547.  
  7548.  
  7549.  
  7550.  
  7551.      ABORT command............................................ 35
  7552.      ABORT_DONE reply......................................... 36
  7553.      address.............................................. 60, 66
  7554.      address descriptor....................................... 20
  7555.      address format................................... 19, 25, 31
  7556.      address ID............................................... 22
  7557.      address mode......................................... 20, 22
  7558.      address mode argument.................................... 21
  7559.      address offset........................................... 20
  7560.      addressing............................................... 19
  7561.      ADDRESS_LIST reply................................... 76, 77
  7562.      BASIC_DEBUGGER....................................... 12, 32
  7563.      breakpoint... 9, 13, 57, 60, 71, 79, 92, 93, 95, 96, 99, 107
  7564.      breakpoint commands.......................... 9, 94, 95, 107
  7565.      breakpoint counter........................ 94, 100, 101, 110
  7566.      breakpoint data...................................... 97, 99
  7567.      breakpoint state variable........................... 94, 107
  7568.      breakpoint variables..................................... 94
  7569.      BREAKPOINT_DATA command..................... 73, 94, 95, 107
  7570.      BREAKPOINT_LIST reply................................ 79, 80
  7571.      CHANGED condition....................................... 102
  7572.      command class............................................ 16
  7573.      command length field..................................... 16
  7574.      COMPARE Condition....................................... 103
  7575.      condition command header................................ 101
  7576.      conditional commands................................. 94, 99
  7577.      CONTINUE command......................................... 62
  7578.      control commands...................................... 9, 57
  7579.      COUNT condition.................................... 110, 111
  7580.      COUNT_EQ condition...................................... 101
  7581.      COUNT_GT condition...................................... 101
  7582.      COUNT_LT condition...................................... 101
  7583.      CREATE command............................... 69, 70, 73, 75
  7584.      create types............................................. 70
  7585.      CREATE_DONE reply.................................... 73, 75
  7586.      data octets...................................... 43, 47, 52
  7587.      data packing............................................. 10
  7588.      data transfer commands................................ 9, 41
  7589.      data transmission........................................ 10
  7590.      datagrams................................................. 5
  7591.      debugging.............................................. 1, 3
  7592.  
  7593.  
  7594.  
  7595.                                                               Page 125
  7596.  
  7597.  
  7598.  
  7599.  
  7600.  
  7601.  
  7602.  
  7603.      default breakpoint................................... 71, 92
  7604.      DELETE command....................................... 73, 75
  7605.      DELETE_DONE reply........................................ 75
  7606.      descriptor........... 20, 57, 61, 62, 63, 64, 65, 73, 75, 93
  7607.      dumping................................................... 3
  7608.      ERRACK............................................... 10, 39
  7609.      ERROR codes.............................................. 38
  7610.      ERROR reply.......................................... 37, 67
  7611.      EXCEPTION trap........................................... 66
  7612.      finite state machine................................. 60, 93
  7613.      FSM breakpoint................................... 71, 92, 94
  7614.      FULL-DEBUGGER............................................ 12
  7615.      FULL_DEBUGGER............................................ 32
  7616.      gateway................................................ 3, 9
  7617.      GET_OBJECT command................................... 89, 91
  7618.      GET_PHYS_ADDR command................................ 87, 88
  7619.      GOT_OBJECT reply..................................... 89, 91
  7620.      GOT_PHYS_ADDR reply.................................. 87, 88
  7621.      HELLO command......................................... 9, 29
  7622.      HELLO_REPLY....................................... 9, 19, 30
  7623.      host descriptor.......................................... 41
  7624.      implementation....................................... 12, 31
  7625.      INC_COUNT command......................... 94, 107, 110, 111
  7626.      INCREMENT command....................................... 109
  7627.      internet.................................................. 5
  7628.      internet protocols........................................ 4
  7629.      IP........................................................ 5
  7630.      LDP command formats...................................... 15
  7631.      LDP header........................................... 15, 16
  7632.      LDP Version.............................................. 30
  7633.      LIST commands............................................ 73
  7634.      LIST_ADDRESSES command............................... 76, 77
  7635.      LIST_BREAKPOINTS command............................. 79, 80
  7636.      LIST_NAMES command................................... 84, 85
  7637.      LIST_PROCESSES command................................... 82
  7638.      LOADER_DUMPER........................................ 12, 32
  7639.      loading................................................ 1, 3
  7640.      long address format...................................... 20
  7641.      management commands...................................... 67
  7642.      memory object............................................ 73
  7643.      MOVE command................................. 22, 41, 47, 49
  7644.      MOVE sequence number..................................... 52
  7645.      MOVE_DATA response................................... 22, 51
  7646.      MOVE_DONE reply.......................................... 52
  7647.      NAME_LIST reply...................................... 84, 85
  7648.      offset............................................... 20, 22
  7649.      OR command.............................................. 111
  7650.  
  7651.  
  7652.  
  7653.      Page 126
  7654.  
  7655.  
  7656.  
  7657.  
  7658.  
  7659.  
  7660.  
  7661.      PAD.................................................... 3, 9
  7662.      pattern.................................................. 54
  7663.      PHYS_ADDRESS............................................. 57
  7664.      PHYS_MACRO............................................... 60
  7665.      PROCESS.................................................. 57
  7666.      PROCESS_CODE............................................. 60
  7667.      PROCESS_LIST reply....................................... 82
  7668.      protocol commands......................................... 9
  7669.      PSN.................................................... 3, 9
  7670.      RDP................................................... 5, 15
  7671.      READ command..................................... 41, 43, 44
  7672.      READ sequence number..................................... 47
  7673.      READ_DATA response................................... 45, 46
  7674.      READ_DONE reply.......................................... 47
  7675.      repeat count............................................. 54
  7676.      REPEAT_DATA command.................................. 41, 53
  7677.      REPORT command................................... 63, 64, 94
  7678.      sequence number...................................... 10, 39
  7679.      session................................................... 9
  7680.      SET_PTR command................................ 94, 111, 112
  7681.      SET_STATE command.............................. 94, 107, 113
  7682.      short address format..................................... 25
  7683.      START command........................................ 59, 60
  7684.      STATUS reply..................................... 64, 65, 94
  7685.      STEP command......................................... 62, 63
  7686.      STOP command......................................... 60, 61
  7687.      SYNCH.................................................... 10
  7688.      SYNCH command............................................ 33
  7689.      SYNCH_REPLY.............................................. 34
  7690.      system type.............................................. 30
  7691.      target start address......................... 43, 44, 46, 54
  7692.      transport................................................. 9
  7693.      watchpoint.......... 13, 57, 60, 71, 92, 93, 95, 96, 99, 107
  7694.      WRITE command........................................ 41, 42
  7695.      WRITE_MASK command....................................... 56
  7696.  
  7697.  
  7698.  
  7699.  
  7700.  
  7701.  
  7702.  
  7703.  
  7704.  
  7705.  
  7706.  
  7707.  
  7708.  
  7709.  
  7710.  
  7711.                                                               Page 127
  7712.  
  7713.  
  7714.  
  7715.  
  7716.  
  7717.  
  7718.  
  7719.  
  7720.  
  7721.  
  7722.  
  7723.  
  7724.  
  7725.  
  7726.  
  7727.  
  7728.  
  7729.  
  7730.  
  7731.  
  7732.  
  7733.  
  7734.  
  7735.  
  7736.  
  7737.  
  7738.  
  7739.  
  7740.  
  7741.  
  7742.  
  7743.  
  7744.  
  7745.  
  7746.  
  7747.  
  7748.  
  7749.  
  7750.  
  7751.  
  7752.  
  7753.  
  7754.  
  7755.  
  7756.  
  7757.  
  7758.  
  7759.  
  7760.  
  7761.  
  7762.  
  7763.  
  7764.  
  7765.  
  7766.  
  7767.  
  7768.  
  7769.      Page 128
  7770.  
  7771.