<html><head></head><body><div class="ydp299dcbf2yahoo-style-wrap" style="font-family: Helvetica Neue, Helvetica, Arial, sans-serif; font-size: 13px;"><div id="ydp299dcbf2yiv8742540900"><div><div class="ydp299dcbf2yiv8742540900yahoo-style-wrap" style="font-family:Helvetica Neue, Helvetica, Arial, sans-serif;font-size:13px;"><div dir="ltr" data-setdir="false">Hi Daniel,<br clear="none"><div><br></div><div dir="ltr" data-setdir="false"><span>thank you for your reply. <span>That's what I already suspected.</span></span><br></div><div><br></div><div>I'm waiting to hear back from David about his setup. <span>He seemed quite sure that chainloading works, so I was a bit surprised that neither iPXE nor Grub did work for me on EDK2. <br></span></div><div><span><br></span></div><div><span></span><span></span>Otherwise, I'll fix iPXE myself. </div><div><br></div><div dir="ltr" data-setdir="false">Regards Sebastian<br></div></div><div dir="ltr"><br clear="none"></div><div class="ydp299dcbf2yiv8742540900yahoo_quoted" id="ydp299dcbf2yiv8742540900yahoo_quoted_5616699740">
<div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:13px;color:#26282a;">
<div>
Am Mittwoch, 10. März 2021, 10:59:48 MEZ hat Schwyn Daniel <daniel.schwyn@inf.ethz.ch> Folgendes geschrieben:
</div>
<div><br clear="none"></div>
<div><br clear="none"></div>
</div>
</div></div></div></div></div><div class="yiv8742540900yqt4309346454" id="yiv8742540900yqt62089"><div><div id="yiv8742540900"><style>#yiv8742540900 --
filtered {}
#yiv8742540900 filtered {}
#yiv8742540900 filtered {}
#yiv8742540900 filtered {}
#yiv8742540900
p.yiv8742540900MsoNormal, #yiv8742540900 li.yiv8742540900MsoNormal, #yiv8742540900 div.yiv8742540900MsoNormal
{margin:0cm;font-size:11.0pt;font-family:sans-serif;}
#yiv8742540900 a:link, #yiv8742540900 span.yiv8742540900MsoHyperlink
{color:blue;text-decoration:underline;}
#yiv8742540900 pre
{margin:0cm;font-size:10.0pt;}
#yiv8742540900 span.yiv8742540900HTMLVorformatiertZchn
{font-family:serif;}
#yiv8742540900 span.yiv8742540900E-MailFormatvorlage22
{font-family:sans-serif;color:windowtext;}
#yiv8742540900 .yiv8742540900MsoChpDefault
{font-size:10.0pt;}
#yiv8742540900 filtered {}
#yiv8742540900 div.yiv8742540900WordSection1
{}
#yiv8742540900 </style><div>
<div class="yiv8742540900WordSection1">
<p class="yiv8742540900MsoNormal"><span style="">Hi Sebastian,</span></p>
<p class="yiv8742540900MsoNormal"><span style=""> </span></p>
<p class="yiv8742540900MsoNormal"><span style="" lang="EN-US">I have seen this error before with iPXE when I tried chainloading Hagfish with iPXE on top of U-Boot with EFI support. U-Boot’s EFI support is rather minimalistic so I’m not sure the
cause was the same in my case. Looking at the iPXE source code though it looks to me as if it only supports the EFI_PXE_BASE_CODE_MTFTP_READ_FILE opcode while Hagfish also needs the EFI_PXE_BASE_CODE_MTFTP_GET_FILE_SIZE operation to allocate appropriately
sized buffers for the files it wants to load.</span></p>
<p class="yiv8742540900MsoNormal"><span style="" lang="EN-US"> </span></p>
<p class="yiv8742540900MsoNormal"><span style="" lang="EN-US">Regards,</span></p>
<p class="yiv8742540900MsoNormal"><span style="" lang="EN-US">Daniel</span></p>
<p class="yiv8742540900MsoNormal"><span style="" lang="EN-US"> </span></p>
<div class="yiv8742540900yqt3767717118" id="yiv8742540900yqt96683"><div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm;">
<p class="yiv8742540900MsoNormal"><b><span lang="DE">Von:</span></b><span lang="DE"> Barrelfish-users <barrelfish-users-bounces@lists.inf.ethz.ch>
<b>Im Auftrag von </b>sebastian.scherbel@fau.de<br clear="none">
<b>Gesendet:</b> Dienstag, 2. März 2021 22:56<br clear="none">
<b>An:</b> Cock David <david.cock@inf.ethz.ch><br clear="none">
<b>Cc:</b> barrelfish-users@lists.inf.ethz.ch<br clear="none">
<b>Betreff:</b> Re: [Barrelfish-users] [Barrelfish] Hagfish kernel image structure and latest version</span></p>
</div>
</div>
<p class="yiv8742540900MsoNormal"> </p>
<div>
<div>
<div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;">Hello,</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;">>Hagfish definitely supports chainloading over PXE - that's exactly what it was designed for.</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;">Which bootloaders have you tested? What does your setup look like?</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;">I have tried:</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;">EDK2 -> iPXE -> Hagfish</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><i><span style="font-size:10.0pt;font-family:sans-serif;">iPXE> chain tftp://x.x.x.x/Hagfish_ETHZ.efi</span></i><span style="font-size:10.0pt;font-family:sans-serif;"></span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><i><span style="font-size:10.0pt;font-family:sans-serif;">...<br clear="none">
Hagfish UEFI loader starting<br clear="none">
UEFI vendor: EDK II<br clear="none">
Hagfish loaded at 402D9000, size 147456B, by handle 41839B98<br clear="none">
Could not connect to shell or not enough parameters, assuming PXE boot.<br clear="none">
Connecting to the PXE service that loaded me.<br clear="none">
PXE loader at 403ED660, revision 10000, running<br clear="none">
Loading "hagfish.cfg.10.0.0.10"<br clear="none">
<b>Mtftp: Unsupported, <br clear="none">
file size: Unsupported</b></span></i><span style="font-size:10.0pt;font-family:sans-serif;"></span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;">EDK2 -> Grub2 -> Hagfish</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><i><span style="font-size:10.0pt;font-family:sans-serif;">grub> boot<br clear="none">
Status: 0x0000000E<br clear="none">
Failed to initialize ShellLib, aborting.<br clear="none">
Hagfish UEFI loader starting<br clear="none">
UEFI vendor: EDK II<br clear="none">
Hagfish loaded at 402DA000, size 147456B, by handle 41862A18<br clear="none">
Could not connect to shell or not enough parameters, assuming PXE boot.<br clear="none">
Connecting to the PXE service that loaded me.<br clear="none">
<b>OpenProtocol: Unsupported<br clear="none">
Failed to initialize loader: Load Error</b></span></i><span style="font-size:10.0pt;font-family:sans-serif;"></span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;">> The error there seems to be the UEFI implementation not supporting TFTP - did you compile it in?</span></p>
</div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;">When I load Hagfish directly, everything works fine. On American Megatrends Aptio V and EDK2.</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;"> </span></p>
</div>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;">Regards Sebastian</span></p>
</div>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Am Donnerstag, 28. Januar 2021, 16:36:02 MEZ hat David Cock <<a rel="nofollow noopener noreferrer" shape="rect" ymailto="mailto:david.cock@inf.ethz.ch" target="_blank" href="mailto:david.cock@inf.ethz.ch">david.cock@inf.ethz.ch</a>> Folgendes geschrieben:
</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div id="yiv8742540900">
<div>
<p><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">What you're seeing there is Hagfish trying to load its configuration file over TFTP as it's figured out that it was itself loaded over PXE. The README might be inconsistent
wrt filenames - if in doubt, trust the code. Hagfish definitely supports chainloading over PXE - that's exactly what it was designed for.</span></p>
<p><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">The error there seems to be the UEFI implementation not supporting TFTP - did you compile it in?</span></p>
<p><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">David</span></p>
<div id="yiv8742540900yqtfd48517">
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">On 28/1/21 3:53 pm,
<a rel="nofollow noopener noreferrer" shape="rect" ymailto="mailto:sebastian.scherbel@fau.de" target="_blank" href="mailto:sebastian.scherbel@fau.de">sebastian.scherbel@fau.de</a> wrote:</span></p>
</div>
</div>
</div>
<div id="yiv8742540900yqtfd10124">
<div>
<div>
<div>
<div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Hello,</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">sounds good. I have tried to chainload Hagfish after iPXE. However, loading of the cfg fails on QEMU and on the real hardware with the same error.</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<div>
<p class="yiv8742540900MsoNormal"><i><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Hagfish UEFI loader starting<br clear="none">
UEFI vendor: American Megatrends<br clear="none">
Hagfish loaded at F951D000, size 143360B, by handle F6EA1D18<br clear="none">
Could not connect to shell or not enough parameters, assuming PXE boot.<br clear="none">
Connecting to the PXE service that loaded me.<br clear="none">
PXE loader at F5EE1840, revision 10000, running<br clear="none">
Loading "hagfish.cfg.A.B.C.D"<b> (shouldn't the cfg name be hafish.A.B.C.D.cfg according to the readme?)</b><br clear="none">
<b>Mtftp: Unsupported, </b></span></i><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"></span></p>
<div>
<p class="yiv8742540900MsoNormal"><b><i><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">file size: Unsupported</span></i></b><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"></span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Is this a known bug? Is chainloading unsupported? Your setup is directly booting into Hagfish?</span></p>
</div>
</div>
</div>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Regards Sebastian
</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
</div>
</div>
<div id="yiv8742540900yahoo_quoted_2497327118">
<div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Am Donnerstag, 28. Januar 2021, 14:03:36 MEZ hat David Cock
<a rel="nofollow noopener noreferrer" shape="rect" ymailto="mailto:david.cock@inf.ethz.ch" target="_blank" href="mailto:david.cock@inf.ethz.ch"><david.cock@inf.ethz.ch></a> Folgendes geschrieben:
</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<div id="yiv8742540900">
<div>
<p><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Sebastian,</span></p>
<p><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Hagfish is a custom loader for the Barrelfish CPU driver, which operates under a few unusual assumptions: Mainly, the CPU driver (kernel) itself is not self-relocating, but relies
on the bootloader (Hagfish) to do the relocation for it.</span></p>
<p><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">It would definitely be possible to modify Hagfish to load an arbitrary ELF, however. You'd have to make a few changes in the relocation code to not look for Barrelfish-specific
segments and so on, but there's nothing particularly weird or non-standard about it.</span></p>
<p><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Hagfish is pretty static, and doesn't change much from version to version. We'll update the repository shortly (which we should have done together with the release). Feel free
to ask more specific questions if you decide to use it - we're happy to help.</span></p>
<p><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">David</span></p>
<div id="yiv8742540900yqt90781">
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">On 27/1/21 5:41 pm,
<a rel="nofollow noopener noreferrer" shape="rect" ymailto="mailto:sebastian.scherbel@fau.de" target="_blank" href="mailto:sebastian.scherbel@fau.de">sebastian.scherbel@fau.de</a> wrote:</span></p>
</div>
</div>
</div>
<div id="yiv8742540900yqt19324">
<div>
<div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Hello,</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">I'm a CS student trying to port an research operating system from x86_64 to ARMv8 and stumbled across Hagfish.</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Hagfish should basically be able to load any ELF with its sections into memory with minor modifications? Or is there certain requirement for the kernel image
structure that I didn't notice while reading your publication [1] and skimming the source code?</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">The last commit in the public repository is from March 2017. But in the changelog of your last Barrelfish release from 2020 states "Update Hagfish to latest
version". Have there been any bigger changes or improvements in the meantime?</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">Regards Sebastian</span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"> </span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">[0]
<a rel="nofollow noopener noreferrer" shape="rect" target="_blank" href="https://lists.inf.ethz.ch/pipermail/barrelfish-users/2020-March/001597.html">
https://lists.inf.ethz.ch/pipermail/barrelfish-users/2020-March/001597.html</a></span></p>
</div>
<div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">[1]
<a rel="nofollow noopener noreferrer" shape="rect" target="_blank" href="http://www.barrelfish.org/publications/TN-022-ARMv8.pdf">
http://www.barrelfish.org/publications/TN-022-ARMv8.pdf</a></span></p>
</div>
</div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"><br clear="none">
<br clear="none">
</span></p>
<pre><span style="color:#26282A;">_______________________________________________</span></pre>
<pre><span style="color:#26282A;">Barrelfish-users mailing list</span></pre>
<pre><span style="color:#26282A;"><a rel="nofollow noopener noreferrer" shape="rect" ymailto="mailto:Barrelfish-users@lists.inf.ethz.ch" target="_blank" href="mailto:Barrelfish-users@lists.inf.ethz.ch">Barrelfish-users@lists.inf.ethz.ch</a></span></pre>
<pre><span style="color:#26282A;"><a rel="nofollow noopener noreferrer" shape="rect" target="_blank" href="https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users">https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users</a></span></pre>
</div>
</div>
</div>
<div id="yiv8742540900yqt99156">
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">_______________________________________________<br clear="none">
Barrelfish-users mailing list<br clear="none">
<a rel="nofollow noopener noreferrer" shape="rect" ymailto="mailto:Barrelfish-users@lists.inf.ethz.ch" target="_blank" href="mailto:Barrelfish-users@lists.inf.ethz.ch">Barrelfish-users@lists.inf.ethz.ch</a><br clear="none">
<a rel="nofollow noopener noreferrer" shape="rect" target="_blank" href="https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users">https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users</a></span></p>
</div>
</div>
</div>
</div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;"><br clear="none">
<br clear="none">
</span></p>
<pre><span style="color:#26282A;">_______________________________________________</span></pre>
<pre><span style="color:#26282A;">Barrelfish-users mailing list</span></pre>
<pre><span style="color:#26282A;"><a rel="nofollow noopener noreferrer" shape="rect" ymailto="mailto:Barrelfish-users@lists.inf.ethz.ch" target="_blank" href="mailto:Barrelfish-users@lists.inf.ethz.ch">Barrelfish-users@lists.inf.ethz.ch</a></span></pre>
<pre><span style="color:#26282A;"><a rel="nofollow noopener noreferrer" shape="rect" target="_blank" href="https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users">https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users</a></span></pre>
</div>
</div>
</div>
<p class="yiv8742540900MsoNormal"><span style="font-size:10.0pt;font-family:sans-serif;color:#26282A;">_______________________________________________<br clear="none">
Barrelfish-users mailing list<br clear="none">
<a rel="nofollow noopener noreferrer" shape="rect" ymailto="mailto:Barrelfish-users@lists.inf.ethz.ch" target="_blank" href="mailto:Barrelfish-users@lists.inf.ethz.ch">Barrelfish-users@lists.inf.ethz.ch</a><br clear="none">
<a rel="nofollow noopener noreferrer" shape="rect" target="_blank" href="https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users">https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users</a></span></p></div>
</div>
</div></div></div></div></body></html>