Skip to content

Commit 0c2b0a4

Browse files
committed
Fix location for TPM simulator /tmp.
1 parent d463f70 commit 0c2b0a4

1 file changed

Lines changed: 29 additions & 4 deletions

File tree

examples/u-boot/README.md

Lines changed: 29 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -90,18 +90,43 @@ make -j4
9090

9191
3. Create TPM directory:
9292
```
93-
mkdir -p ./tmp/mytpm1
93+
mkdir -p /tmp/mytpm1
9494
```
9595

9696
4. Start swtpm (in first terminal):
9797
```
98-
swtpm socket --tpm2 --tpmstate dir=./tmp/mytpm1 --ctrl type=unixio,path=./tmp/mytpm1/swtpm-sock --log level=20
98+
swtpm socket --tpm2 --tpmstate dir=/tmp/mytpm1 --ctrl type=unixio,path=/tmp/mytpm1/swtpm-sock --log level=20
9999
```
100100

101101
5. Start QEMU (in second terminal):
102102
```
103-
qemu-system-aarch64 -machine virt -nographic -cpu cortex-a57 -bios u-boot.bin -chardev socket,id=chrtpm,path=./tmp/mytpm1/swtpm-sock -tpmdev emulator,id=tpm0,chardev=chrtpm -device tpm-tis-device,tpmdev=tpm0
103+
qemu-system-aarch64 -machine virt -nographic -cpu cortex-a57 -bios u-boot.bin -chardev socket,id=chrtpm,path=/tmp/mytpm1/swtpm-sock -tpmdev emulator,id=tpm0,chardev=chrtpm -device tpm-tis-device,tpmdev=tpm0
104104
```
105105

106-
6. Exiting the QEMU:
106+
6. Example output:
107+
108+
```
109+
U-Boot 2025.07-rc1-ge15cbf232ddf-dirty (May 06 2025 - 16:25:56 -0700)
110+
111+
DRAM: 128 MiB
112+
using memory 0x46658000-0x47698000 for malloc()
113+
Core: 52 devices, 15 uclasses, devicetree: board
114+
Flash: 64 MiB
115+
Loading Environment from Flash... *** Warning - bad CRC, using default environment
116+
117+
In: serial,usbkbd
118+
Out: serial,vidconsole
119+
Err: serial,vidconsole
120+
No USB controllers found
121+
Net: eth0: virtio-net#32
122+
123+
Hit any key to stop autoboot: 0
124+
=> tpm help
125+
tpm - Issue a TPMv1.x command
126+
127+
Usage:
128+
tpm cmd args...
129+
```
130+
131+
7. Exiting the QEMU:
107132
Press Ctrl-A followed by X

0 commit comments

Comments
 (0)