Tony,

EFI is some what simpler than a standard OS, by design. The main reason is 
determinism and the primary goal being to initialize hardware and boot a 
quickly as possible. 

So there are not threads, there is only the main thread. While it is possible 
to run code on the other processor in the systems non of the EFI services work 
on the other processors so this feature is mostly used to test memory, caches, 
or initialize the CPUs.  

What EFI does have is timer events. System calls in EFI are called Boot 
Services and Runtime Services. Protocols are C structure with member functions 
that are named by GUID (UUID) and this is how a driver publishes services. 

So you can use the CreateEvent() Boot Service to associate a call back function 
with an event and SetTimer() Boot Service to set the callback period. 

If you want to runt he shell it would run as the main thread.  The consoles 
that the Shell uses (EFI defines) is produced via Simple Text In and Simple 
Text Out protocols, and one of the active console devices could be a remote 
connection. 

Andrew Fish

The open source EFI networking code lives in:
https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2/MdeModulePkg/Universal/Network/
https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2/NetworkPkg/
https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2/StdLib/

You may find the Drivers Writer Guide useful:
http://sourceforge.net/apps/mediawiki/tianocore/index.php?title=EDK_II_User_Documentation

Most platform use this as the main EFI console, so multiple consoles can be 
supported at one time.
https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2/MdeModulePkg/Universal/Console/ConSplitterDxe/

On Jul 31, 2012, at 9:40 AM, Tonderai Nemarundwe wrote:

> Is it possible to write multi-threaded applications for UEFI? I am trying to 
> write a server app that can execute commands in efi shell and pipe the output 
> to client. Is this possible or does this exist already? . I am more trying to 
> create EFI app that can act in similar manner to telnet. I want to use a 
> remote pc to execute commands in efi shell via network stack. can efi 
> applications invoke other efi applications? are system calls possible in efi 
> environment?
> Thanks
> Tony
> 
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and 
> threat landscape has changed and how IT managers can respond. Discussions 
> will include endpoint security, mobile security and the latest in malware 
> threats. 
> http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/_______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/edk2-devel

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to