Hi Stefan,

I just wanted to confirm that your observations and findings are correct. That
is the interface you have to use. Then it is up to your component to provide
the right payload for ATF.

Good luck,
Matthias.

On [13-07-2020 11:25], Stefan Kalkowski wrote:
> Hello Matthias,
> 
> thank you for your reply. See my comment inline below.
> 
> On Fri, Jul 10, 2020 at 08:58:57PM +0200, Matthias Lange wrote:
> > Hi Stefan,
> > 
> > On [09-07-2020 22:37], Stefan Kalkowski wrote:
> > > Dear l4-hackers,
> > > 
> > > I've seen that Fiasco.OC provides support for the i.MX8 SoC universe.
> > > I'm curious about whether the kernel provides any means to access the
> > > ARM Trusted Firmware (ATF) in general? (especially regarding the
> > > vendor-specific calls for powering different peripheral domains). I've
> > > seen some kind of platform control privilege for cpu powering if I
> > > understood it correctly. Is there something more generic available?
> > 
> > Fiasco.OC uses the PSCI interface to boot secondary cores. Via the platform
> > control capability it is possible for a userspace component to trigger 
> > system
> > shutdown and reset. I am not a 100% sure about suspend / resume.
> > 
> > Apart from that there is no further support or usage in the kernel.
> > 
> > Accessing other ATF services should be done in userspace I would say. Maybe
> > you can help me to understand what your platform driver is supposed to do?
> 
> Exactly, that is what the platform driver is about, powering
> peripheral device domains, like PCI-x or USB, configuring clocks etc.
> as a userland component.
> 
> However, accessing the ATF via a 'smc' call is a privileged only
> instruction. That is why I was asking for a generic 'smc' tunnel, or
> similar.
> 
> My colleague Christian Helmuth refered me to this commit:
> 
>   
> https://github.com/kernkonzept/fiasco/commit/d52cf4a33742faea752e6b6e493b21d99de3a1e4#diff-c92ec6b15ac25b493c76a28007d9003f
> 
> I guess this is what I was looking for. I assume this special initial
> Smc kobject is part of the roottask's initially mapped capabilities?
> Which would be fine for me, and is exactly what I was looking for.
> 
> I had no time until now to dive deeply into the current kernel
> interface, but needed to decide where to locate something like the
> `smc` calling interface in the most generic fashion to fit more than
> one kernel. That is why I asked you for help/reference. I think now I
> got the picture.
> 
> Best regards
> Stefan
> 
> > Regards,
> > Matthias.
> > 
> > > I'm asking, because right now I write a platform driver for Genode
> > > running on the i.MX 8M with focus on the base-hw kernel. But if
> > > there is a way I would like to support Fiasco.OC as well.
> > > 
> > > Thank you in advance for any clearing up & best regards
> > > Stefan
> > > 
> > > -- 
> > > Stefan Kalkowski
> > > Genode labs
> > > 
> > > https://github.com/skalk | https://genode.org
> > > 
> > > _______________________________________________
> > > l4-hackers mailing list
> > > l4-hackers@os.inf.tu-dresden.de
> > > http://os.inf.tu-dresden.de/mailman/listinfo/l4-hackers
> > 
> > _______________________________________________
> > l4-hackers mailing list
> > l4-hackers@os.inf.tu-dresden.de
> > http://os.inf.tu-dresden.de/mailman/listinfo/l4-hackers
> 
> -- 
> Stefan Kalkowski
> Genode labs
> 
> https://github.com/skalk | https://genode.org
> 
> _______________________________________________
> l4-hackers mailing list
> l4-hackers@os.inf.tu-dresden.de
> http://os.inf.tu-dresden.de/mailman/listinfo/l4-hackers

-- 
Matthias Lange                      phone: +49 (0) 351-41 888 614
Senior Operating Systems Engineer

matthias.la...@kernkonzept.com      Kernkonzept GmbH
https://www.kernkonzept.com         Buchenstraße 16b
https://twitter.com/kernkonzept     01097 Dresden

Geschäftsführer: Dr.-Ing. Michael Hohmuth
Registergericht: Amtsgericht Dresden
Handelsregister: HRB 31129

_______________________________________________
l4-hackers mailing list
l4-hackers@os.inf.tu-dresden.de
http://os.inf.tu-dresden.de/mailman/listinfo/l4-hackers

Reply via email to