<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from rtf -->
<style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<font face="Calibri" size="2"><span style="font-size:10pt;">
<div style="padding-right:5pt;padding-left:5pt;">TCS Confidential<br>

</div>
<div style="margin-top:5pt;"><font face="Times New Roman" size="3"><span style="font-size:12pt;"><br>

</span></font></div>
<div><font face="Times New Roman" size="3"><span style="font-size:12pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Hi C,</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">I was able to build and run the image(for evb-ast2600) with swtpm. Few issues observed,</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<ol style="margin:0;padding-left:36pt;list-style-type:decimal;">
<font face="Calibri" size="2"><span style="font-size:11pt;">
<li>If I run with the flash.img provided in your github link(<a href="https://github.com/legoater/qemu-aspeed-boot/tree/master/images"><font color="#0563C1"><u>https://github.com/legoater/qemu-aspeed-boot/tree/master/images</u></font></a>) everything works
as expected, i.e I get the below output.</li></span></font>
</ol>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b># echo tpm_tis_i2c 0x2e > /sys/bus/i2c/devices/i2c-12/new_device</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>[  182.735902] tpm_tis_i2c 12-002e: 2.0 TPM (device-id 0x1, rev-id 1)</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>[  182.773885] i2c i2c-12: new_device: Instantiated device tpm_tis_i2c at 0x2e</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>#</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>#</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b># cat /sys/class/tpm/tpm0/pcr-sha256/0</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>B804724EA13F52A9072BA87FE8FDCC497DFC9DF9AA15B9088694639C431688E0</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>#</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>#</b></span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<ol start="2" style="margin:0;padding-left:36pt;list-style-type:decimal;">
<font face="Calibri" size="2"><span style="font-size:11pt;">
<li>If I run it with the locally built image, I get this error,</li></span></font>
</ol>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>root@evb-ast2600:~# echo tpm_tis_i2c 0x2e > /sys/bus/i2c/devices/i2c-12/new_device</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>[  174.063597] i2c i2c-12: new_device: Instantiated device tpm_tis_i2c at 0x2e</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>root@evb-ast2600:~# cat /sys/class/tpm/tpm0/pcr-sha256/0</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>cat: can't open '/sys/class/tpm/tpm0/pcr-sha256/0': No such file or directory</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>root@evb-ast2600:~#</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"><b>root@evb-ast2600:~#</b></span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div style="padding-left:36pt;"><font face="Calibri" size="2"><span style="font-size:11pt;">Please do let me know about what has been done to write the values into “<b>/sys/class/tpm/tpm0/pcr-sha256/0</b><b>” . </b></span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Thanks,</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Sandeep. </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">_____________________________________________<br>

<b>From:</b> Sandeep Kumar <br>

<b>Sent:</b> Thursday, April 20, 2023 5:45 PM<br>

<b>To:</b> Cédric Le Goater <clg@kaod.org>; openbmc@lists.ozlabs.org; Ninad Palsule <ninad@linux.ibm.com>; Joel Stanley <jms@jms.id.au>; Andrew Jeffery <andrew@aj.id.au><br>

<b>Subject:</b> RE: Integrating swtpm(as a software TPM) with OpenBMC on Qemu</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Hi C,</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">How to build this image =>  <b>obmc-phosphor-image.rootfs.wic.qcow2</b> ? In openBmc build directory we don’t get this image built. </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Also, remaining image formats used while running on qemu are available in the build directory. i.e fitImage-linux.bin, aspeed-bmc-ibm-rainier.dtb and obmc-phosphor-initramfs.rootfs.cpio.xz . </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Please advise if we have to build openbmc stack in a different way than the standard procedure. We follow the below steps for build,  </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">1. . setup Romulus</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">2. bitbake obmc-phosphor-image</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Thanks,</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Sandeep.</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">-----Original Message-----<br>

From: Sandeep Kumar <br>

Sent: Wednesday, April 19, 2023 3:00 PM<br>

To: Cédric Le Goater <<a href="mailto:clg@kaod.org"><font color="#0563C1"><u>clg@kaod.org</u></font></a>>; <a href="mailto:openbmc@lists.ozlabs.org"><font color="#0563C1"><u>openbmc@lists.ozlabs.org</u></font></a>; Ninad Palsule <<a href="mailto:ninad@linux.ibm.com"><font color="#0563C1"><u>ninad@linux.ibm.com</u></font></a>>;
Joel Stanley <<a href="mailto:jms@jms.id.au"><font color="#0563C1"><u>jms@jms.id.au</u></font></a>>; Andrew Jeffery <<a href="mailto:andrew@aj.id.au"><font color="#0563C1"><u>andrew@aj.id.au</u></font></a>><br>

Subject: RE: Integrating swtpm(as a software TPM) with OpenBMC on Qemu</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Hi C,</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Got it working. Looks like slirp is no longer supported on ubnutu 18.04. have upgraded to a newer version  and is working now.</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Thanks,</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Sandeep. </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">-----Original Message-----</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">From: Cédric Le Goater <<a href="mailto:clg@kaod.org">clg@kaod.org</a>></span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Sent: Wednesday, April 19, 2023 2:26 PM</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">To: Sandeep Kumar <<a href="mailto:sandeep.pkumar@tcs.com">sandeep.pkumar@tcs.com</a>>; <a href="mailto:openbmc@lists.ozlabs.org">openbmc@lists.ozlabs.org</a>; Ninad Palsule <<a href="mailto:ninad@linux.ibm.com">ninad@linux.ibm.com</a>>;
Joel Stanley <<a href="mailto:jms@jms.id.au">jms@jms.id.au</a>>; Andrew Jeffery <<a href="mailto:andrew@aj.id.au">andrew@aj.id.au</a>></span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Subject: Re: Integrating swtpm(as a software TPM) with OpenBMC on Qemu</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">"External email. Open with Caution"</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Hello Sandeep</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">On 4/18/23 09:45, Sandeep Kumar wrote:</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> TCS Confidential</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> Hi C,</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> Built the qemu from your branch. Few issues, *$ ./qemu-system-arm -m</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> 256 -M romulus-bmc -nographic -drive</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> file=./obmc-phosphor-image-romulus.static.mtd,format=raw,if=mtd -net </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> nic -net </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> user,hostfwd=:127.0.0.1:2222-:22,hostfwd=:127.0.0.1:4443-:443,hostfwd=</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> tcp:127.0.0.1:8880-:80,hostfwd=tcp:127.0.0.1:2200-:2200,hostfwd=udp:12</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> 7.0.0.1:6623-:623,hostfwd=udp:127.0.0.1:6664-:664,hostname=qemu*</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> *qemu-system-arm: -net</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> user,hostfwd=:127.0.0.1:2222-:22,hostfwd=:127.0.0.1:4443-:443,hostfwd=</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> tcp:127.0.0.1:8880-:80,hostfwd=tcp:127.0.0.1:2200-:2200,hostfwd=udp:12</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> 7.0.0.1:6623-:623,hostfwd=udp:127.0.0.1:6664-:664,hostname=qemu: </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> network backend 'user' is not compiled into this binary* I didn’t </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> enable the slirp package I guess. So enabled it while running </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> configure, *$ ../configure --enable-slirp*</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> *........*</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> *Run-time dependency slirp found: NO (tried pkgconfig)*</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> *../meson.build:681:2: ERROR: Dependency "slirp" not found, tried</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> pkgconfig* *A full log can be found at </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> /home/tcs/work/sandeep/measured_boot/ibm_qemu/qemu/build/meson-logs/me</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> son-log.txt*</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> *NOTICE: You are using Python 3.6 which is EOL. Starting with v0.62.0, </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> Meson will require Python 3.7 or newer*</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> *ERROR: meson setup failed*</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">> I have already installed slirp locally, but still getting the above error.</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">Did you install the libslirp-dev or libslirp-devel package ?</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;">C.</span></font></div>
<div><font face="Calibri" size="2"><span style="font-size:11pt;"> </span></font></div>
<div><font face="Times New Roman" size="3"><span style="font-size:12pt;"><br>

</span></font></div>
<div style="margin-top:5pt;padding-right:5pt;padding-left:5pt;">TCS Confidential<br>

</div>
</span></font>
<p>=====-----=====-----=====<br>
Notice: The information contained in this e-mail<br>
message and/or attachments to it may contain <br>
confidential or privileged information. If you are <br>
not the intended recipient, any dissemination, use, <br>
review, distribution, printing or copying of the <br>
information contained in this e-mail message <br>
and/or attachments to it are strictly prohibited. If <br>
you have received this communication in error, <br>
please notify us by reply e-mail or telephone and <br>
immediately and permanently delete the message <br>
and any attachments. Thank you</p>

<p></p></body>
</html>