Commit Graph

11346 Commits

Author SHA1 Message Date
jljusten 4b1bf81c20 MdeModulePkg: Add PEI USB drivers and related PPIs
Signed-off-by: jljusten
Reviewed-by: mdkinney
Reviewed-by: geekboy15a

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11901 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 23:30:55 +00:00
jcarsey 366f81a016 Clarify that the shared variables of the shell protocols are properly named.
This removes the non-shared gEfiShellProtocol and gEfiShellParametersProtocol and renames the shared version to those names.

This removes the m-versions of those protocol pointers.

signed-off-by: jcarsey
reviewed-by: darylm503

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11900 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 21:04:22 +00:00
jcarsey 92a5447eda replace protocol presence ASSERTs with error returns.
signed-off-by: jcarsey
reviewed-by: lgrosenb

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11899 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 20:33:13 +00:00
jcarsey ad7782a47e maintain output attributes.
signed-off-by: jcarsey
reviewed-by: lgrosenb

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11898 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 20:29:23 +00:00
jcarsey 35f26e73cc replace assert with error.
signed-off-by: jcarsey
reviewed-by: lgrosenb

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11897 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 20:28:23 +00:00
jcarsey 03131de30e Make sure size is correct.
signed-off-by: jcarsey
reviewed-by: lgrosenb

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11896 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 20:27:29 +00:00
andrewfish f70c2a1234 InOsEmuPkg: Fix Xcode symbol loading with new scheme. Fix bug in dlcose. Move some of the gdb infrastrucuture to the start of main().
signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11895 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 19:56:15 +00:00
jcarsey 8bd282bee9 allow for failure return when called without a shell present.
signed-off-by: jcarsey
reviewed-by: lgrosenb

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11894 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 16:45:41 +00:00
andrewfish febb227679 InOsEmuPkg: Fix minor typo and Xcode build breaks. Seems Xcode is more picky about the types you pass into %x.
signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11893 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 15:42:03 +00:00
ydong10 4ffaadccd3 Adjust the start position of the opcode string before saving it to avoid show menu info error.
Signed-off-by: ydong10
Reviewed-by: lgao4









git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11892 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 09:07:23 +00:00
niruiyu fd99d1a91d Fix UnixGcc build failures.
Signed-off-by: niruiyu

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11891 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-27 06:03:06 +00:00
jljusten 345a0c8fce OvmfPkg: Add support for UEFI shell
When building:
-D BUILD_NEW_SHELL - Build and include UEFI shell in firmware
-D USE_NEW_SHELL - Include UEFI shell binary build in firmware

The default is to use the older EFI shell.

Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11890 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-26 18:58:41 +00:00
jljusten 984d7448fe InOsEmuPkg/Unix: Allow binary UEFI shell to be used
When using InOsEmuPkg/Unix/build64.sh -D USE_NEW_SHELL,
the UEFI shell binary will now be included in the firmware
image.

Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11889 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-26 18:58:23 +00:00
jljusten 0bc9421b14 InOsEmuPkg/Unix: Auto-load symbols files in gdb
Images that can't be loaded with dlopen are
added to SecMain.gdb.

Whenever gdb stops, the hook-stop macro will automatically
load the symbol files.

Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11888 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-26 18:58:10 +00:00
andrewfish 8e4b3d32a8 InOsEmuPkg: Make the Guard MemoryAllocationLib handle EFI allocated pages correctly.
signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11887 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-25 01:39:09 +00:00
andrewfish 1d7ac5a617 InOsEmuPkg: Add an OS malloc/valloc/free based implementation of the MemoryAllocationLib. Requires extra Thunk APIs.
I've got this working. The tricky part was a driver/application can mix malloc forms. If the driver links against this library all the allocations come from the OS service, but if a protocol or EFI boot service return an allocated buffer it will still use the EFI allocation. The gasket code can detect this and do the right thing, as the emulator is passing up the memory map to EFI. 

You can now use the OS based malloc debugging tools in an EFI driver or appliaction. On OS X this is libgmalloc, also called guard malloc. 

Signed-off-by: andrewfish.



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11886 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-24 23:59:51 +00:00
andrewfish 0de7effb73 InOsEmuPkg: Fix issue with struct stat not having the right size. EFI compiler args are not compatible with system include headers for IA32.
This is a fix for XCODE/XCLANG. I'm still seeing an issue, but the stat info for the filesystem is now correct. 

Signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11885 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-24 22:48:34 +00:00
andrewfish c8f62f95a6 [InOsEmuPkg] Fix minor coding style bug.
signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11884 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-24 14:50:06 +00:00
andrewfish c217506815 [InOSEmPkg] Add OS malloc and free to the Thunk.
Added OS malloc and free so we can make MemoryAllocationLib instance that uses OS guard malloc. This will allow all the debug support built into the OS for finding malloc bugs to be used with a driver in the emulator. 

Signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11883 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-24 14:48:38 +00:00
jljusten 54e0b04c74 InOsEmuPkg/Unix: Fix build issues for GCC44 IA32
Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11880 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-23 15:23:39 +00:00
jljusten 27f6b4f869 InOsEmuPkg/Unix: Detect lib directory suffix on Linux
For IA32 builds, if /lib32 and /usr/lib32 exist,
they will be used instead of /lib and /usr/lib.

For X64 builds, if /lib64 and /usr/lib64 exist,
they will be used instead of /lib and /usr/lib.

Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11879 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-23 15:23:20 +00:00
jljusten feceaad588 InOsEmuPkg/Unix/build.sh: Merge changes from build64.sh r11867
Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11878 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-23 15:23:02 +00:00
jljusten fe7e504faa InOsEmuPkg/Unix: Auto-run emulator in gdb
Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11877 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-23 15:22:49 +00:00
niruiyu b68b78e66c Change DUET DxeIpl to use SerialPort instead of manipulating serial port directly.
Signed-off-by: niruiyu
Reviewed-by: jyao1

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11876 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-23 08:31:18 +00:00
ydong10 f6bd06633d Refine code to follow coding style.
Signed-off-by: ydong10



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11875 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-23 01:33:03 +00:00
niruiyu 8b67c4c879 Remove non-ASCII characters.
Signed-off-by: niruiyu

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11874 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-23 01:30:52 +00:00
ydong10 72c8a89a65 Add check code to avoid access violation.
Signed-off-by: ydong10
Reviewed-by: jcarsey


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11873 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-23 01:26:06 +00:00
andrewfish 1ef41207dc InOsEmuPkg: Add TimerLib for PEI, DXE_CORE, and DXE/EFI drivers/applications.
Start using MdeModulePkg MetronomeDxe driver. Add PEI and DXE_CORE TimerLibs that just call back to the emulator. Add a DXE/UEFI TimerLib that also does a gBS->WaitForEvent() if the stall is for a long period of time. Change the Thunk API for Sleep to nanoseconds. 

Signed-off-by: andrewfish


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11872 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-21 23:41:31 +00:00
ydong10 090f3fdbf9 Move the check refresh attribute logical out of the option string check logical.
Signed-off-by: ydong10
Reviewed-by: lgao4



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11871 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-21 02:58:45 +00:00
ydong10 8f766f6eec Add sample code for vfr opcode "guidop"
Signed-off-by: ydong10
Reviewed-by: lgao4



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11870 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-21 02:43:14 +00:00
ydong10 18ad26da31 Initialize data before using it
Signed-off-by: ydong10
Reviewed-by: lgao4


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11869 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-21 02:24:46 +00:00
andrewfish ea203f2215 InOsEmuPkg: Make sure to skip DXE IPL on emulator build, and don't double build every thing IA-32 Xcode.
Signed-off-by: andrewfish


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11868 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 23:05:43 +00:00
jljusten 53a6813fd0 InOsEmuPkg/Unix: Enable single-pass build with Linux
For Linux builds the thunk layer ('SEC') and main platform
firmware image will be built in a single build pass.

Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11867 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 21:58:22 +00:00
jljusten b8800fc547 InOsEmuPkg/Unix/Sec: Add BaseMemoryLib implementation to thunk layer
This implementation only covers a few BaseMemoryLib functions.
The implementation leverates malloc/free in stdlib.

Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11866 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 21:58:05 +00:00
jljusten 7af94c1d0a InOsEmuPkg/Unix/Sec: Fix EFIAPI usage inconsistencies
Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11865 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 21:57:43 +00:00
jljusten d7dd93876b InOsEmuPkg: Remove unreference local variables
GCC44 will flag a warning for these unused variables.

Signed-off-by: jljusten

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11864 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 21:57:27 +00:00
oliviermartin 8513037f2c ArmPkg/CpuDxe: Register a callback for the gIdleLoopEventGuid event
This gIdleLoopEventGuid event signals the Cpu that it should go into
the idle state waiting for any events.
CpuSleep() is used in this implementation to make the Cpu wait for
the next interrupt (WFI instruction).



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11863 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 21:35:50 +00:00
oliviermartin 149daa615f ArmPkg/CpuPei: Declare the CPU HOB
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11862 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 21:33:56 +00:00
oliviermartin fbcd5cea83 ArmPkg/CpuPei: Get the System Memory from the Resource Memory HOB
Declare the system memory provided by the first Resource Memory HOB
as cached memory to the MMU.
All the remaining memory space is declared as Device Memory.


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11861 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 21:32:46 +00:00
oliviermartin d7b6c49b78 ArmPkg/CpuDxe: Change chain of dependency for CpuDxe and PL390Gic
Previously the CPU driver had a dependency on the GIC driver.
But by design is should be the opposite. The CPU driver installs the
CPU protocol that exposes the exception registration function.
And then, the interrupt controller registers its IRQ handler through
this interface.


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11860 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 21:30:51 +00:00
erictian e7c2a83b3b Fix potential null pointer dereference
Signed-off-by: erictian
Reviewed-by: ydong10


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11859 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 09:35:53 +00:00
niruiyu eaaf8693dc Fix EFI Option ROM being loaded twice unconditionally.
Signed-off-by: niruiyu
Reviewed-by: rsun3

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11858 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-20 05:09:40 +00:00
andrewfish 1453e7736e InOsEmuPkg: Fix debug prints from DXE/UEFI drivers.
Turning on serial prints for early drivers, turned off debug prints for DXE/UEFI drivers. Add them back in via report status code.

signed-off-by: andrewfish


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11857 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-19 18:59:00 +00:00
andrewfish ab34fe8b48 InOsEmuPkg: Remove unneeded Framework for XCODE linker flag overrides.
signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11856 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-19 18:57:56 +00:00
andrewfish b02333caa6 InOsEmuPkg: Fix issue with EFI_LBA not being implemented as a UINT64 in the IA-32 Gasket.
Also clean up some missing EFIAPI.

signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11855 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-19 18:56:13 +00:00
andrewfish f2f008b435 InOsEmuPkg: Fix UINT64 bugs in IA-32 gasket.
At this point IA-32 emulator boots the shell with an X11 GOP window. Block IO seems to have an issue that needs to be debugged. 

Signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11854 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-19 02:58:32 +00:00
andrewfish 102d35ba76 InOsEmuPkg: Fix issues with stack alignment in the gasket.
There are still issues with the IA-32 gasket code. Mostly having to do with yank put bugs not accounting for UINT64 returns and arguments. Currently the IA-32 build crashes in the timer callback since it is UINT64, function ptr but the gasket is UINTN UINTN. 

Signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11853 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-19 02:25:37 +00:00
andrewfish aac0fea79f InOsEmuPkg: Fix IA-32 SEC temp ram code.
Now we crash early in DXE Core.

Signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11852 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-18 23:36:36 +00:00
andrewfish e7523e0619 InOsEmuPkg: Make build dir different for IA-32. Fix PCD XIP issues.
Signed-off-by andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11851 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-18 22:23:46 +00:00
andrewfish 417a8020ab InOsEmuPkg: Add an Xcode project file for building and debugging IA-32 Unix emulator.
Signed-off-by: andrewfish



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11850 6f19259b-4bc3-4df7-8a09-765794883524
2011-06-18 18:40:45 +00:00