[edk2-devel] Upcoming Event: TianoCore Design Meeting - APAC/NAMO - Fri, 04/03/2020 9:30am-10:30am #cal-reminder

2020-03-28 Thread devel@edk2.groups.io Calendar
*Reminder:* TianoCore Design Meeting - APAC/NAMO *When:* Friday, 3 April 2020, 9:30am to 10:30am, (GMT+08:00) Asia/Chongqing *Where:* BlueJeans Meeting View Event ( https://edk2.groups.io/g/devel/viewevent?eventid=700770 ) *Organizer:* Ray Ni ray...@intel.com (

Re: [edk2-devel] [PATCH] .azurepipelines: Enable CI for OvmfPkg and EmulatorPkg

2020-03-28 Thread Sean via Groups.Io
Ard, I agree.  How would we do this with AARCH64?  I don't believe azure devops pipelines has a native AARCH64 platform available.  I briefly looked over ArmVirtPkg but not sure where to start. OVMF readme only talks about ia32/x64.  I could also see a scenario for a self hosted agent that is

Re: [edk2-devel] [EXTERNAL] [edk2-devel] Information about the VMs used to do EDK2 CI?

2020-03-28 Thread Andrew Fish via Groups.Io
This works on my MacBook Pro $ getconf _NPROCESSORS_ONLN 8 The macOS centric way is this: $ sysctl -n hw.logicalcpu 8 Thanks, Andrew FIsh > On Mar 23, 2020, at 5:38 AM, Laszlo Ersek wrote: > > On 03/22/20 00:03, Rebecca Cran wrote: >> Thank you. I think we probably do want to detect the

Re: [edk2-devel] [PATCH] .azurepipelines: Enable CI for OvmfPkg and EmulatorPkg

2020-03-28 Thread Ard Biesheuvel
On Sat, 28 Mar 2020 at 20:29, Sean via Groups.Io wrote: > > Added support for EmulatorPkg running to UEFI shell. > Segmentation fault on GCC / Ubuntu x64. Works on Windows. > > Could very easily be user error. > https://bugzilla.tianocore.org/show_bug.cgi?id=2639 > > Laszlo - can you point me to

Re: [edk2-devel] [EXTERNAL] [edk2-devel] Information about the VMs used to do EDK2 CI?

2020-03-28 Thread Sean via Groups.Io
Thanks I opened a bug to get this tracked. https://bugzilla.tianocore.org/show_bug.cgi?id=2640 In that bug i link to a commit which does the above using python.  It saves about 20 seconds for each build on linux in Azure pipelines. Thanks Sean -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You

[edk2-devel] [PATCH v3 11/17] OvmfPkg/PvScsiDxe: Define device interface structures and constants

2020-03-28 Thread Liran Alon
These definitions will be used by the following commits to complete the implementation of PVSCSI device driver. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Acked-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/Include/IndustryStandard/PvScsi.h | 165 ++

[edk2-devel] [PATCH v3 13/17] OvmfPkg/PvScsiDxe: Setup requests and completions rings

2020-03-28 Thread Liran Alon
These rings are shared memory buffers between host and device in which a cyclic buffer is managed to send request descriptors from host to device and receive completion descriptors from device to host. Note that because device may be constrained by IOMMU or guest may be run under AMD SEV, we make

[edk2-devel] [PATCH v3 17/17] OvmfPkg/PvScsiDxe: Enable device 64-bit DMA addresses

2020-03-28 Thread Liran Alon
Enable PCI dual-address cycle attribute to signal device supports 64-bit DMA addresses. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/PvScsiDxe/PvScsi.c | 23 +++ 1 file changed, 23 insertions(+)

[edk2-devel] [PATCH v3 16/17] OvmfPkg/PvScsiDxe: Reset device on ExitBootServices()

2020-03-28 Thread Liran Alon
This causes the device to forget about the request/completion rings. We allocated said rings in EfiBootServicesData type memory, and code executing after ExitBootServices() is permitted to overwrite it. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek

[edk2-devel] [PATCH v3 15/17] OvmfPkg/PvScsiDxe: Support sending SCSI request and receive response

2020-03-28 Thread Liran Alon
Implement EXT_SCSI_PASS_THRU.PassThru(). Machines should be able to boot after this commit. Tested with Ubuntu 16.04 guest. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Signed-off-by: Liran Alon --- OvmfPkg/OvmfPkg.dec | 6 + OvmfPkg/PvScsiDxe/PvScsi.c | 456

[edk2-devel] [PATCH v3 12/17] OvmfPkg/PvScsiDxe: Reset adapter on init

2020-03-28 Thread Liran Alon
The following commits will complete the implementation of device initialization. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/PvScsiDxe/PvScsi.c | 114 + 1 file changed, 114

[edk2-devel] [PATCH v3 14/17] OvmfPkg/PvScsiDxe: Introduce DMA communication buffer

2020-03-28 Thread Liran Alon
In case device is constrained by IOMMU or guest is running under AMD SEV, input/output buffers provided to device (DataBuffer and SenseData) needs to be explicitly mapped to device by PciIo->Map(). To avoid the overhead of mapping/unmapping the DataBuffer and SenseData to the device for every

[edk2-devel] [PATCH v3 02/17] OvmfPkg/PvScsiDxe: Install DriverBinding protocol

2020-03-28 Thread Liran Alon
In order to probe and connect to the PvScsi device we need this protocol. Currently it does nothing. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/PvScsiDxe/PvScsi.c | 66 -

[edk2-devel] [PATCH v3 03/17] OvmfPkg/PvScsiDxe: Report name of driver

2020-03-28 Thread Liran Alon
Install Component Name protocols to have a nice display name for the driver in places such as UEFI shell. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/PvScsiDxe/PvScsi.c | 59 -- 1

[edk2-devel] [PATCH v3 04/17] OvmfPkg/PvScsiDxe: Probe PCI devices and look for PvScsi

2020-03-28 Thread Liran Alon
PvScsiControllerSupported() is called on handles passed in by the ConnectController() boot service and if the handle is the PVSCSI controller, the function would return success. A success return value will attach our driver to the device. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567

[edk2-devel] [PATCH v3 10/17] OvmfPkg/PvScsiDxe: Enable MMIO-Space & Bus-Mastering in PCI attributes

2020-03-28 Thread Liran Alon
Enable MMIO-Space & Bus-Mastering PCI attributes when device is started. Note that original PCI attributes are restored when device is stopped. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/PvScsiDxe/PvScsi.c | 12

[edk2-devel] [PATCH v3 09/17] OvmfPkg/PvScsiDxe: Backup/Restore PCI attributes on Init/UnInit

2020-03-28 Thread Liran Alon
This commit doesn't change semantics. It is done as a preparation for future commits which will modify PCI attributes. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/PvScsiDxe/PvScsi.c | 54

[edk2-devel] [PATCH v3 01/17] OvmfPkg/PvScsiDxe: Create empty driver

2020-03-28 Thread Liran Alon
In preparation for support booting from PvScsi devices, create a basic scaffolding for a driver. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/OvmfPkgIa32.dsc | 8 OvmfPkg/OvmfPkgIa32.fdf | 3

[edk2-devel] [PATCH v3 05/17] OvmfPkg/PvScsiDxe: Install stubbed EXT_SCSI_PASS_THRU

2020-03-28 Thread Liran Alon
Support dynamic insertion and removal of the protocol. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/PvScsiDxe/PvScsi.c | 209 +++- OvmfPkg/PvScsiDxe/PvScsi.h | 29 +

[edk2-devel] [PATCH v3 08/17] OvmfPkg/PvScsiDxe: Open PciIo protocol for later use

2020-03-28 Thread Liran Alon
This will give us an exclusive access to the PciIo of this device after it was started and until it will be stopped. Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/PvScsiDxe/PvScsi.c | 29 -

[edk2-devel] [PATCH v3 00/17] OvmfPkg: Support booting from VMware PVSCSI controller

2020-03-28 Thread Liran Alon
Hi, This series adds driver support for VMware PVSCSI controller. This controller is supported by VMware and QEMU. This work is part of the more general agenda of enhancing OVMF boot device support to have feature parity with SeaBIOS (Which supports booting from VMware PVSCSI). I pushed a copy

[edk2-devel] [PATCH v3 06/17] OvmfPkg/PvScsiDxe: Report the number of targets and LUNs

2020-03-28 Thread Liran Alon
Implement EXT_SCSI_PASS_THRU.GetNextTarget() and EXT_SCSI_PASS_THRU.GetNextTargetLun(). ScsiBusDxe scans all MaxTarget * MaxLun possible devices. This can take unnecessarily long for large number of targets. To deal with this, VirtioScsiDxe has defined PCDs to limit the MaxTarget & MaxLun to

[edk2-devel] [PATCH v3 07/17] OvmfPkg/PvScsiDxe: Translate Target & LUN to/from DevicePath

2020-03-28 Thread Liran Alon
Implement EXT_SCSI_PASS_THRU.BuildDevicePath() and EXT_SCSI_PASS_THRU.GetTargetLun(). Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2567 Reviewed-by: Laszlo Ersek Signed-off-by: Liran Alon --- OvmfPkg/PvScsiDxe/PvScsi.c | 61 -- 1 file changed, 59

Re: [edk2-devel] [PATCH] .azurepipelines: Enable CI for OvmfPkg and EmulatorPkg

2020-03-28 Thread Sean via Groups.Io
Added support for EmulatorPkg running to UEFI shell. Segmentation fault on GCC / Ubuntu x64.  Works on Windows. Could very easily be user error. https://bugzilla.tianocore.org/show_bug.cgi?id=2639 Laszlo - can you point me to any docs, scripts, examples of how i would do the same thing with

Re: [edk2-devel] [PATCH v2 15/17] OvmfPkg/PvScsiDxe: Support sending SCSI request and receive response

2020-03-28 Thread Liran Alon
On 28/03/2020 1:17, Liran Alon wrote: On 28/03/2020 1:04, Liran Alon wrote: On 28/03/2020 0:05, Laszlo Ersek wrote: On 03/27/20 14:04, Liran Alon wrote: On 27/03/2020 14:26, Laszlo Ersek wrote: On 03/25/20 17:10, Liran Alon wrote: + Packet->HostAdapterStatus = +

Re: [edk2-devel] [PATCH 1/1] MdeModulePkg: UART Dynamic clock freq Support

2020-03-28 Thread Pankaj Bansal
Hello Jiang, > -Original Message- > From: Jiang, Guomin > Sent: Thursday, March 26, 2020 7:44 PM > To: devel@edk2.groups.io; Pankaj Bansal ; Leif > Lindholm ; Ni, Ray > Cc: Pankaj Bansal (OSS) ; Wang, Jian J > ; Wu, Hao A ; Ma, Maurice > ; Dong, Guo ; You, Benjamin > ; Meenakshi

[edk2-devel] [PATCH 5/5] ArmPkg/ArmMmuLib: drop unused TT_ATTR_INDX_INVALID CPP symbol

2020-03-28 Thread Ard Biesheuvel
TT_ATTR_INDX_INVALID is #define'd but never used so drop it. Signed-off-by: Ard Biesheuvel --- ArmPkg/Library/ArmMmuLib/AArch64/ArmMmuLibCore.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/ArmPkg/Library/ArmMmuLib/AArch64/ArmMmuLibCore.c

[edk2-devel] [PATCH 2/5] ArmPkg/CpuDxe: move PageAttributeToGcdAttribute() out of ArmMmuLib

2020-03-28 Thread Ard Biesheuvel
The routine PageAttributeToGcdAttribute() is exported by ArmMmuLib but only ever used in the implementation of CpuDxe. So let's move the function there and make it STATIC. Signed-off-by: Ard Biesheuvel --- ArmPkg/Drivers/CpuDxe/AArch64/Mmu.c | 46

[edk2-devel] [PATCH 4/5] ArmPkg/ArmMmuLib: get rid of GetRootTranslationTableInfo()

2020-03-28 Thread Ard Biesheuvel
Only a single call to GetRootTranslationTableInfo() remains, which only provides the root table level. So let's create a new static helper function that returns just this value, and use it instead. Signed-off-by: Ard Biesheuvel --- ArmPkg/Library/ArmMmuLib/AArch64/ArmMmuLibCore.c | 22

[edk2-devel] [PATCH 3/5] ArmPkg/ArmMmuLib: drop pointless LookupAddresstoRootTable() routine

2020-03-28 Thread Ard Biesheuvel
LookupAddresstoRootTable() uses a loop to go over its MaxAddress argument, essentially to do a log2() and determine how many bits are needed to represent it. Since the argument is the result of a shift-left expression, there is some room for improvement here, and we can simply use the bit count

[edk2-devel] [PATCH 0/5] ArmPkg: cosmetic cleanups for ArmMmuLib

2020-03-28 Thread Ard Biesheuvel
Now that the rewritten ArmMmuLib for AARCH64 seems to be functioning as desired, we can apply some more polish and get rid of a couple of warts that were left over from the original version. Patches #1 and #2 move some code out of ArmMmuLib and into CpuDxe which only exists for the benefit of the

[edk2-devel] [PATCH 1/5] ArmPkg/CpuDxe: use private copy of GetRootTranslationTableInfo()

2020-03-28 Thread Ard Biesheuvel
Before getting rid of GetRootTranslationTableInfo() and the related LookupAddresstoRootTable() in AARCH64's version of ArmMmuLib, add a version of the former to CpuDxe, which will be its only remaining user. While at it, simplify it a bit, since in the CpuDxe cases, both OUT arguments are always