<div dir="ltr">How does this work on non-LPC platforms?</div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Nov 20, 2016 at 8:50 PM, Cyril Bur <span dir="ltr"><<a href="mailto:cyrilbur@gmail.com" target="_blank">cyrilbur@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>
<br>
Apologies, I have been working on this in a bit of a silo and I suspect<br>
a lot of people will be interested to know this work is going on.<br>
<br>
The aim of my work is to provide a simple interface for the host and<br>
the BMC to talk in order for the BMC to give controlled access to the<br>
flash.<br>
<br>
At the moment, the BMC maps the host LPC bus to point to the PNOR<br>
directly. This may be undesirable and presents security concerns. If<br>
the host can be taught to request access to the flash then the BMC<br>
could map the LPC bus into a region of its RAM and (depending on<br>
policy) writes wouldn't get propagated to the actual flash. Policy<br>
details are for later.<br>
<br>
I developed a simple protocol to allow this exchange of information<br>
documented in the README.md file of the userspace test daemon I wrote<br>
to proof of concept this: <a href="https://github.com/cyrilbur-ibm/mboxbridge/tr
ee/newio" rel="noreferrer" target="_blank">https://github.com/cyrilbur-<wbr>ibm/mboxbridge/tr<br>
ee/newio</a> I will no doubt move this somewhere more suitable in due<br>
course.<br>
<br>
I chose to use the MBOX registers on the BMC as they provide a fast<br>
method of data transfer and can raise interrupts on both the host and<br>
BMC.<br>
<br>
The aim of sharing this now is to show that the interface works and<br>
that implementation independent things can start to be integrated into<br>
skiboot and linux. Having said that, I would appreciate any feedback, I<br>
have had my head in this for quite some time please let me know if I've<br>
missed something.<br>
<br>
The implementation is only a proof of concept, some details still need<br>
to be worked out, especially what happens on BMC reboot. I believe the<br>
interface is ok in that respect, just my implementation which is<br>
lacking.<br>
<br>
Do try it out if you want. Of course changes need to be made to the BMC<br>
kernel as well as skiboot:<br>
<a href="https://github.com/cyrilbur-ibm/linux/tree/newio" rel="noreferrer" target="_blank">https://github.com/cyrilbur-<wbr>ibm/linux/tree/newio</a><br>
<a href="https://github.com/cyrilbur-ibm/skiboot/tree/newio" rel="noreferrer" target="_blank">https://github.com/cyrilbur-<wbr>ibm/skiboot/tree/newio</a><br>
<br>
Thanks,<br>
<br>
Cyril<br>
______________________________<wbr>_________________<br>
openbmc mailing list<br>
<a href="mailto:openbmc@lists.ozlabs.org">openbmc@lists.ozlabs.org</a><br>
<a href="https://lists.ozlabs.org/listinfo/openbmc" rel="noreferrer" target="_blank">https://lists.ozlabs.org/<wbr>listinfo/openbmc</a><br>
</blockquote></div><br></div>