<div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-size:small"><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Nov 13, 2020 at 1:44 AM Petr Vorel <<a href="mailto:pvorel@suse.cz">pvorel@suse.cz</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi,<br>
<br>
> On 12. 11. 20 15:21, Cyril Hrubis wrote:<br>
> > Hi!<br>
> > I've looked into the library and what it actually does in this case is<br>
> > that it opens a sysfs file and reads a few bytes from there. I guess<br>
> > that we can even avoid linking the library in this case, since we just<br>
> > want to know a value of the single bit in the SecureBoot file.<br>
<br>
> > The full path is:<br>
<br>
> > /sys/firmware/efi/efivars/SecureBoot-8be4df61-93ca-11d2-aa0d-00e098032b8c<br>
<br>
> Yes, we could read the sysfile directly. But do we want to deal with<br>
> potential compatibility issues and test breakage if the UEFI vars API<br>
> changes in the future? The binary format of those sysfiles is controlled<br>
> by the UEFI Forum, not by kernel devs. The efivars library is available<br>
> on basically all modern distros and we most likely won't do any<br>
> SecureBoot tests on distros that don't have it.<br>
<br>
I also don't see a big deal to use the efivars library.<br></blockquote><div><br></div><div class="gmail_default" style="font-size:small">That's true. I have no objection to the patchset.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">But we always try to avoid the LTP dependency on other libraries, in this point, I agree with Cyril.</div></div><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div>Regards,<br></div><div>Li Wang<br></div></div></div></div>