)]}'
{
  "commit": "b4f673bd8dd07c07a773de77af0bc411654d8558",
  "tree": "a9c317ec6be7e277a3f86b839e71d2100ef5cb6f",
  "parents": [
    "6e3b027e12e4236a6470dac435bf74ba66c3befa"
  ],
  "author": {
    "name": "Jes B. Klinke",
    "email": "jbk@chromium.org",
    "time": "Sat Mar 05 17:49:18 2022 -0800"
  },
  "committer": {
    "name": "Timothy Trippel",
    "email": "5633066+timothytrippel@users.noreply.github.com",
    "time": "Thu Mar 24 09:06:45 2022 -0700"
  },
  "message": "[opentitantool] Bootstrapping efficiently via proxy\n\nThe proxy potocol allow issuing SPI commands to a USB debugger\nconnected on a remote machine running opentitansession.  This can be\nuseful for short interactions (e.g. testing TPM functionality), but\nfor bootstrapping by writing an entire image into flash, even the\nslightest round-trip time will causing excruciatingly slow progress.\nThe device may even be sensitive to SPI transaction timing, causing\nthe bootstrapping to fail, if performed with significant latency.\n\nConsidering that opentitansession compiles with all the same library\nfunctions for the SPI bootstrapping protocols as the \"local\"\nopentitantool, it would be much more efficient to transfer the image\nfile to the proxy daemon, and let it break it down into individual SPI\ntransactions.\n\nThis CL does exactly that, by adding code to Bootstrap::update() for\ndetecting when the Transport implementation happens to be a proxy\nstub, and in such case make use of a new \"Transport::proxy_ops()\"\nmethod call to transfer the entire image file to the proxy daemon,\nwhich in turn will invoke the same Bootstrap::update() which this time\nwill detect a non-proxy (USB) Transport implementation, and perform\nSPI operations using it.\n\nSigned-off-by: Jes B. Klinke \u003cjbk@chromium.org\u003e\n\nChange-Id: Icdc4eaa98368aaa3eaca0ce9edee971b29a4961b\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "a0f6afe66bf10a1ca73cd101b9d922808edb3f9b",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/app/mod.rs",
      "new_id": "d4f9ce40c5b1db912ab027b304f238a6e3c80fca",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/app/mod.rs"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "7b99ad13879190c0743cf059c7d672141f5e5684",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/bootstrap/.history_*shell*"
    },
    {
      "type": "modify",
      "old_id": "6b99e1ac6e875376aaa2dc201da766ad709aaf40",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/bootstrap/legacy.rs",
      "new_id": "ea79a1cf632d2494b182e949e9e12761b3a8eb3b",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/bootstrap/legacy.rs"
    },
    {
      "type": "modify",
      "old_id": "b29ba991d9d1d9e6c1bf778d7179e201c0457629",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/bootstrap/mod.rs",
      "new_id": "edb23266c50a4720db5ad2cfbadaec87f0e1ebbd",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/bootstrap/mod.rs"
    },
    {
      "type": "modify",
      "old_id": "386dd2c6daac159125e50bc7c9d4f26c1a3bf5d1",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/bootstrap/primitive.rs",
      "new_id": "f0054657b3f5672f7d9f741ca0720fd0f2b4937f",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/bootstrap/primitive.rs"
    },
    {
      "type": "modify",
      "old_id": "0cea4af8c993775d2165a23e4978c8b4b4de5a1e",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/bootstrap/rescue.rs",
      "new_id": "fa54662169e3db808a6e169c12782e98e64915ca",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/bootstrap/rescue.rs"
    },
    {
      "type": "modify",
      "old_id": "1570751e7e3b4e14b4343ce8ac6ec540fdb9e2a4",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/io/spi.rs",
      "new_id": "e9c5b1282aed379d211a7b75d3e0d497f05d69c2",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/io/spi.rs"
    },
    {
      "type": "modify",
      "old_id": "aae3666147430263eac5e53863b639253a669d6c",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/io/uart.rs",
      "new_id": "5972fd8bbeca7ba1f40432c81ff77556b47b0ac9",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/io/uart.rs"
    },
    {
      "type": "modify",
      "old_id": "3b6cd71d0fa40402f54b39ccde70b4d98dda23b1",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/proxy/handler.rs",
      "new_id": "e0156c19ae748d7b6a62954c866dffea208fb803",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/proxy/handler.rs"
    },
    {
      "type": "modify",
      "old_id": "c4d7a5ea015701829c2ae1731b95b1e10828dddc",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/proxy/protocol.rs",
      "new_id": "9c927c3fd1a446207feda12262b51ee13fcceaa9",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/proxy/protocol.rs"
    },
    {
      "type": "modify",
      "old_id": "0b61705ade1ec2fa7e48c577034ded68417ac324",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/transport/errors.rs",
      "new_id": "b5c797aaf6352c6e4c56026cc3c18eeed26e3079",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/transport/errors.rs"
    },
    {
      "type": "modify",
      "old_id": "cc8f69e5963a5c407b05356368fe24e53d38bfc5",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/transport/mod.rs",
      "new_id": "e3aefbf756d4eb1efde6de64c300763ee872b33c",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/transport/mod.rs"
    },
    {
      "type": "modify",
      "old_id": "a6ea68e14ae16bb05381602f5459e78165e212a1",
      "old_mode": 33188,
      "old_path": "sw/host/opentitanlib/src/transport/proxy/mod.rs",
      "new_id": "3276f73286f566222f8f2172f048ba65133dceb4",
      "new_mode": 33188,
      "new_path": "sw/host/opentitanlib/src/transport/proxy/mod.rs"
    }
  ]
}
