Font Size: a A A

Research And Design On Performance Analyzing And Function Testing Of Firmware API Based On UEFI

Posted on:2011-11-13Degree:MasterType:Thesis
Country:ChinaCandidate:Y F WangFull Text:PDF
GTID:2178360305455189Subject:Computer software and theory
Abstract/Summary:PDF Full Text Request
UEFI, which is Unified Extensible Firmware Interface,is the system specification ofnew generation BIOS platform. It defines a new interface module between the firmwareand operating system, and the interface not only include the platform related information,butalsocanbootanoperatingsystemandloadapplications,andsuppliesruntimeservices.IntheUEFIopen-sourcecommunity(www.tianocore.org),therearefouropen-sourceprojectsrelatedtotheUEFIBIOS.TheyareEFIDevKit(EDK),EDKII,EFIShellandEFIToolKit. EDK II (EFI Development Kit) is an open-source released framework of EFIBIOS,includingaseriesofdevelopingexamplesandlotsofbasicAPIfunctions,itsuppliesan library class, that is Module Development Environment'MdePkg', this library classincludesalloftheAPIs, whichiscalledapplicationinterface.Andso,analyzingandtestingon the functions of API Library functions of Module Development Environment canguarantee the stability and quality of the development to its largest extent. Besides, in theprocess of designing the analyzing and testing flow, we can see that UEFI have anadvantage over BIOS within the field of Programing. With the further spreading of UEFIBIOS, more and more OEM, as well as individual, will use the API functions supplied bylibrary classes, to develop some other new functions based on UEFI BIOS or operatingsystem. However, in our present UEFI, whether the functions supplied by MdePkg arecorrectandstableneedsustosetupaframework,totestingitonthewhole.MDE, the shortage of'Module Development Environment', embedded in EDK IIdeveloping environment. In the package of MDE, MdePkg is designed by developers, thefunctionofwhichis tohelpusers developtheirownmodules inEDK IIinfrastructure.Andat thesametime,it cansupplyaverystableplatform that cancompatiblewithUEFIandPISpecification, to help developers develop UEFI drivers, UEFI applications and UEFIoperating system loader, UEFI diagnose, and also silicon modules that are compatible withUEFI Platform Initalization. So, the task of testing the stability and correctness of MdePkgisquiteimportant,foritdeterminesthequalityofdevelopment.In this paper, I finished the functional analyzing and testing of 44 library classes in MDE on DXE phase, such as: whether the executing process is stable, whether thefunctions supplied by MDE is correct, and also whether can be executed correctly on theappointed platform. Due to the interoperability between different platforms, the libraryclasses that need testing can run successfully on different platform (IA32, X64, and IA64etc.), so possess good stability and robustness. But in my paper, I finally finish the settingup of testing framework of MDE library on NT 32-based platform, and the designing,writing and testing of the test cases of all library classes in MDE, on IA32 platform basedonUEFIBIOS.Specificallyspeking,thispaperachievesthefollowingresearchoutputs:Firstly, Research on EDK II development framework, as well as the function of MDEPackage.This paper is focus on supplying an environment to test the firmware API of MDElibrary, and this APIs exist in EDK II package. That is to say, MDE package is embeddedin EDK II developing framework. So, setting up the testing framework of EDK II MdePkgisthefirststepinmypaper.EDKII(EFIDevelopmentKit)isanopensourcedreleasing-frameworkbasedonUEFIBIOS, it is responsible to supply with a good building and edition-tracing environment fordevelopingUEFIandPI. InEDK II, aseries ofdevelopingcases and44 firmware APIs areincluded. And essentially, it is a container that is used to load source codes and samples ofdrivers. In this paper, the intent is to finish the performance analyzing and function testingof44libraryclasses in MDEpackage duringthe phase of DXEbased, suchas: whether theprocess of executing is stable, whether the functions supplied by MDE Package can workproperly, and whether the functions can be executed stably on the needed platformarchitecture. And due to the interoperabilitybetween different platforms, the libraryclassesthat need testing can run successfully on different platform (IA32, X64, and IA64 etc.), sopossess good stability and robustness. But in my paper, I finally finish the setting up oftestingframeworkofMDElibraryonNT32-basedplatform,andthedesigning,writingandtesting of the test cases of all library classes in MDE, on IA32 platform based on UEFIBIOS.Secondly, the whole Architecture Framework'MdeTestPkg'of testing the developingframework'MdePkg'inEDKIIAfter getting familiar with EDKII framework, I need to set up the testing frameworkof MDE library MdePkg. The testing framework of MDE library is MdeTestPkg, thefunction of which is testing the function of library functions in MdePkg through the interfacebetweenProxyandTestcase.MDE (Module Development Environment) is a package in EDK and EDK II, thenameofwhichisMdePkg.So,analyzingandtestingthefirmwareAPIsofMDEcanensurethe stability and quality of the development extremely. Besides, the whole designingprocess of analyzing and testing, we can see the advantage of UEFI to LegacyBIOS in theprogram designing. And with the further spreading of UEFI BIOS, more and more OEMmanufacturer, enen individual, will use the function of this firmware APIs supplied by theMDE library classes, to develop other new function based on the firmware hardware oroperating system. But, for firmware of the current platform, whether the function of MDElibraryisstableandcorrectneedsustosetupatestingframework,totestitonthewhole.Thirdly, designing test cases in MdeTestPkg, to analyze and test the function of MDElibrary.The testing framewok of EDK II MdePkg is designed in MdeTesPkg. A libraryinstance is an implementation of one or more library classes. A library implementationmayoptionallyconsume one or more other libraryclasses and mayalso optionallyproducea constructor and/or a destructor function. The call semantics for the library instanceconstructors and destructors varywith module type. A libraryinstance is also designed tolink with a specific set of Module Types. If a library instance is declared to be a ModuleTypeofBase,thenitcanbelinkedwithamoduleofanytype.For each libraryin MdePkg, there is a correspondingtestinglibraryin the directoryofMdeTestPkg\TestCase; Likewise, there is a corresponding Proxy library in the directoryofMdeTestPkg\Proxy. So, in order to design a test case correctly in MdeTestPkg, we need toalterthefilesunderMdeTestPkg\TestCaseandMdeTestPkg\Proxyatthesametime.And generally speaking, the basis that this paper rely on can be summed up from thefollowing aspects: the analyzing and understanding of UEFI BIOS, the researching ofglobal framework of EDK II based on UEFI, and the focus is setting up the testingframework of MDE library, and designing the testcases of MDE library in MdeTestPkgduringthephaseofDXE.Besides, the paper introduce the testing framework MdeTestPkg and test cases under"MdeTestPkg"directory designed at the stage of PEI and Runtime,and based onX64-architectureplatformtoanalyzeandtesttheMDElibrary.
Keywords/Search Tags:UEFI BIOS, Module Development Environment, Proxy Drivers, Test Case, EDK II, TreeOrganization, EFIShell
PDF Full Text Request
Related items