[edk2] [Patch] BaseTools: Support /WHOLEARCHIVE option in VS2015 tool chain

2017-08-23 Thread Liming Gao
https://bugzilla.tianocore.org/show_bug.cgi?id=582 Don't enable this option in the default setting, because it may cause VS2015 linker crash. Platform can enable this option in PlatformPkg.dsc like below: [BuildOptions] *_*_*_DLINK2_FLAGS = /WHOLEARCHIVE Contributed-under: TianoCore Contribution

Re: [edk2] [Patch v2 1/2] UefiCpuPkg/ArchitecturalMsr.h: Add RTIT TOPA table entry definition.

2017-08-23 Thread Dong, Eric
Mike, I found the attach pic can't show up. Append the content directly from sdm. -Original Message- From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Dong, Eric Sent: Thursday, August 24, 2017 11:22 AM To: Kinney, Michael D ;

[edk2] [Patch] BaseTools: Update tools_def to remove /Gw option in VS NOOPT target

2017-08-23 Thread Liming Gao
To remove /Gw option is to disable size optimization. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao Cc: Yonghong Zhu --- BaseTools/Conf/tools_def.template | 32 1 file changed, 16

[edk2] [PATCH] UefiCpuPkg/PiSmmCpuDxeSmm: Fix memory protection crash

2017-08-23 Thread Star Zeng
https://bugzilla.tianocore.org/show_bug.cgi?id=624 reports memory protection crash in PiSmmCpuDxeSmm, Ia32 build with RAM above 4GB (of which 2GB are placed in 64-bit address). It is because UEFI builds identity mapping page tables, >4G address is not supported at Ia32 build. This patch is to get

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 09/1 BroxtonPlatformPkg: Fix MRC param issue

2017-08-23 Thread Guo, Mang
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../BensonGlacier/BoardInitPreMem/BoardInitMiscs.c | 21 - 1 file changed, 8 insertions(+), 13 deletions(-) diff --git

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 10/1 BroxtonPlatformPkg: Disable NPK based on DciEn

2017-08-23 Thread Guo, Mang
Disable NPK based on DciEn Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../BensonGlacier/BoardInitPreMem/BoardInitMiscs.c | 56 ++ 1 file changed, 37 insertions(+), 19 deletions(-) diff --git

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 11/1 BroxtonPlatformPkg: Remove EFI_ACPI_5_0_SLP_BUTTON

2017-08-23 Thread Guo, Mang
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../BroxtonPlatformPkg/Common/Acpi/AcpiTablesPCAT/AcpiTablePlatform.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 08/1VBT change for TypeC

2017-08-23 Thread Guo, Mang
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../Common/Binaries/Vbt/VbtBxtMipi.bin| Bin 5632 -> 5632 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 07/1 BroxtonPlatformPkg: Add BensonTypeC support

2017-08-23 Thread Guo, Mang
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../BensonGlacier/BoardInitPostMem/BoardInit.c | 8 - .../BensonGlacier/BoardInitPostMem/BoardInit.h | 15 +- .../BoardInitPostMem/BoardInitMiscs.c | 37 ++-

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 06/1BroxtonSiPkg: Add I2CLibPei

2017-08-23 Thread Guo, Mang
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../PlatformDsc/Components.IA32.dsc| 1 + .../SouthCluster/Include/Library/I2CLib.h | 106 +--- .../SouthCluster/Include/ScRegs/RegsI2c.h | 143 +

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 05/1 BroxtonPlatformPkg: Disable ISH

2017-08-23 Thread Guo, Mang
1. Disable ISH 2. Coding style Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../PlatformSettings/PlatformSetupDxe/SouthClusterConfig.vfi | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 04/1 BroxtonPlatformPkg: Change MaxPkgCState default value

2017-08-23 Thread Guo, Mang
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../Common/PlatformSettings/PlatformSetupDxe/CpuPower.vfi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 02/1 BroxtonPlatformPkg: Code cleanup

2017-08-23 Thread Guo, Mang
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../BensonGlacier/BoardInitPreMem/BoardInit.c | 11 +-- .../BensonGlacier/BoardInitPreMem/BoardInit.h | 16 +++-- .../Common/Acpi/AcpiTablesPCAT/AcpiTablePlatform.h | 4 +--

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 03/1 BroxtonPlatformPkg: Change reset type

2017-08-23 Thread Guo, Mang
Change reset type from code reset to warm reset. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../Common/PlatformSettings/PlatformSetupDxe/SystemComponent.vfi| 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git

[edk2] [Patch][edk2-platforms/devel-MinnowBoard3-UDK2017 01/1 BroxtonPlatformPkg: Add SueCreek.asl

2017-08-23 Thread Guo, Mang
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Guo Mang --- .../Common/Acpi/AcpiTablesPCAT/Platform.asl| 10 +++--- .../AcpiTablesPCAT/PlatformSsdt/PlatformSsdt.asl | 3 +- .../PlatformSsdt/SueCreek/SueCreek.asl | 42

Re: [edk2] [Patch 1/2] UefiCpuPkg/CpuCommonFeaturesLib: Remove redundant definition.

2017-08-23 Thread Dong, Eric
Mike, The new check for ProcTraceOutputScheme is for the functionality which is missed before. the user selection and hardware capability may not consistent. So I add this new check. I agree to keep the validate check. Please check the new patch. Thanks, Eric -Original Message- From:

Re: [edk2] [Patch] UefiCpuPkg/MpLib: fix potential overflow issue.

2017-08-23 Thread Dong, Eric
Mike, Thanks for the comments, I updated the patch, please help to review the new patch. Thanks, Eric -Original Message- From: Kinney, Michael D Sent: Thursday, August 24, 2017 5:51 AM To: Dong, Eric ; edk2-devel@lists.01.org; Kinney, Michael D

[edk2] [Patch 4/4] UefiCpuPkg: Update default for PcdCpuProcTraceMemSize/PcdCpuProcTraceOutputScheme.

2017-08-23 Thread Eric Dong
These two definitions have redundant definition which can be handle by code. This patch update them to follow new code definitions. V2: Add more comments for the PCDs and keep consistent in .dec and .uni files. Cc: Michael Kinney Cc: Ruiyu Ni

[edk2] [Patch 2/4] UefiCpuPkg/CpuCommonFeaturesLib: Use MSR data structure when change MSR value.

2017-08-23 Thread Eric Dong
When update MSR values, current code use BITxx to modify it. Enhance the code to use corresponding MSR's data structures to make it more user friendly. V2: Move architecturalMsr.h file. definition to architecturalMsr.h file. Use structure members to do value assignment. Cc: Michael Kinney

[edk2] [Patch 0/4] Enhance the implementation for Proc Trace feature.

2017-08-23 Thread Eric Dong
V2: 1. Move RTIT_TOPA_MEMORY_SIZE definition to architecturalMsr.h file. 2. Use strcture menbers to do value assignment. 3. Enhance the comments for PCD PcdCpuProcTraceMemSize and PcdCpuProcTraceOutputScheme. Eric Dong (4): UefiCpuPkg/ArchitecturalMsr.h: Add RTIT TOPA table entry definition.

[edk2] [Patch 3/4] UefiCpuPkg/CpuCommonFeaturesLib: Remove redundant definition.

2017-08-23 Thread Eric Dong
The EnumProcTraceMemDisable/OutputSchemeInvalid are redundant definitions. These definitions can be handled by other code, so remove them. V2: Change enum members name. Cc: Michael Kinney Cc: Ruiyu Ni Contributed-under: TianoCore Contribution

[edk2] [Patch 1/4] UefiCpuPkg/ArchitecturalMsr.h: Add RTIT TOPA table entry definition.

2017-08-23 Thread Eric Dong
Add RTIT TOPA table entry definition to architecturalMsr.h file. V2: Add RTIT_TOPA_MEMORY_SIZE definition to architecturalMsr.h file. Cc: Michael Kinney Cc: Ruiyu Ni Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Eric Dong

[edk2] [Patch] UefiCpuPkg/MpLib: fix potential overflow issue.

2017-08-23 Thread Eric Dong
Current calculate timeout logic may have overflow if the input timeout value too large. This patch fix this potential overflow issue. V2: Use local variable instead of call GetPerformanceCounterProperties twice. Also correct some comments. Cc: Michael Kinney Cc:

Re: [edk2] [PATCH v3 00/21] OvmfPkg/Virtio: introduce IOMMU-like member functions

2017-08-23 Thread Brijesh Singh
On 8/23/17 8:22 PM, Laszlo Ersek wrote:Okay, I will look into it - thanks for the tip. I wanted to actually use >> the Simple array (because we know the maximum number of buffer we can >> queue) but was not sure about your preferences hence I went to with >> list. If you are okay then I can use

Re: [edk2] [PATCH v3 00/21] OvmfPkg/Virtio: introduce IOMMU-like member functions

2017-08-23 Thread Laszlo Ersek
On 08/24/17 02:54, Brijesh Singh wrote: > On 8/23/17 7:26 PM, Laszlo Ersek wrote: >> On 08/23/17 14:22, Brijesh Singh wrote: >>> OvmfPkg/VirtioBlkDxe: map host address to device address >>> OvmfPkg/VirtioScsiDxe: map host address to device address >> (4) I've looked at these patches briefly.

Re: [edk2] Iscsi Specification Document

2017-08-23 Thread Ye, Ting
UEFI iSCSI is RFC3720 compatible. It is not updated yet. Thanks, Ting Ye -Original Message- From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Blibbet Sent: Thursday, August 24, 2017 5:23 AM To: edk2-devel@lists.01.org Subject: Re: [edk2] Iscsi Specification Document

Re: [edk2] [PATCH v3 00/21] OvmfPkg/Virtio: introduce IOMMU-like member functions

2017-08-23 Thread Brijesh Singh
Hi Laszlo, On 8/23/17 7:26 PM, Laszlo Ersek wrote: > Hi Brijesh, > > so here's what I'd like to do with v3: > > On 08/23/17 14:22, Brijesh Singh wrote: >> Brijesh Singh (23): >> OvmfPkg: introduce IOMMU-like member functions to >> VIRTIO_DEVICE_PROTOCOL >> OvmfPkg/Virtio10Dxe: implement

Re: [edk2] [PATCH v3 00/21] OvmfPkg/Virtio: introduce IOMMU-like member functions

2017-08-23 Thread Laszlo Ersek
Hi Brijesh, so here's what I'd like to do with v3: On 08/23/17 14:22, Brijesh Singh wrote: > Brijesh Singh (23): > OvmfPkg: introduce IOMMU-like member functions to > VIRTIO_DEVICE_PROTOCOL > OvmfPkg/Virtio10Dxe: implement IOMMU-like member functions > OvmfPkg/VirtioPciDeviceDxe:

Re: [edk2] [PATCH edk2-platforms] Silicon/Openmoko: add driver for ChaosKey RNG USB device

2017-08-23 Thread Leif Lindholm
On Wed, Aug 23, 2017 at 02:12:06PM +0100, Ard Biesheuvel wrote: > This is a continuation of the work carried out by Leif Lindholm to > implement a driver for the ChaosKey USB device. This driver uses the > UEFI driver model, which is a slightly awkward fit, due to the fact > that a UEFI

Re: [edk2] [Patch v2 1/2] UefiCpuPkg/ArchitecturalMsr.h: Add RTIT TOPA table entry definition.

2017-08-23 Thread Kinney, Michael D
Hi Eric, I see that the legal values for the Size field of RTIT_TOPA_TABLE_ENTRY are documented in the SDM. I think we should add the enum for PROC_TRACE_MEM_SIZE into ArchitecturalMsr.h next to RTIT_TOPA_TABLE_ENTRY. Maybe rename it to RTIT_TOPA_MEMORY_SIZE with enum names that start with

Re: [edk2] [PATCH v3 20/23] OvmfPkg/VirtioRngDxe: negotiate VIRITO_F_IOMMU_PLATFORM

2017-08-23 Thread Brijesh Singh
On 8/23/17 6:21 PM, Laszlo Ersek wrote: > (1) Please replace "VIRITO_F_IOMMU_PLATFORM" with > "VIRTIO_F_IOMMU_PLATFORM" in the subjects of the remaining patches > (including this one). I will fix it in v4. > On 08/23/17 14:22, Brijesh Singh wrote: >> In previous patches, we have implemented

Re: [edk2] [PATCH v3 20/23] OvmfPkg/VirtioRngDxe: negotiate VIRITO_F_IOMMU_PLATFORM

2017-08-23 Thread Laszlo Ersek
(1) Please replace "VIRITO_F_IOMMU_PLATFORM" with "VIRTIO_F_IOMMU_PLATFORM" in the subjects of the remaining patches (including this one). On 08/23/17 14:22, Brijesh Singh wrote: > In previous patches, we have implemented IOMMU-like member functions in > VIRTIO_DEVICE_PROTOCOL to translate the

Re: [edk2] [PATCH v3 19/23] OvmfPkg/Virtio10: define VIRITO_F_IOMMU_PLATFORM feature bit

2017-08-23 Thread Laszlo Ersek
(1) The subject line contains a super-sneaky typo which I missed in my previous review: VIR-I-T-O vs. VIR-T-I-O. vv VIRITO_F_IOMMU_PLATFORM VIRTIO_F_IOMMU_PLATFORM ^^ The code is correct. With the subject fixed (which I plan to do): Reviewed-by: Laszlo Ersek

Re: [edk2] [Patch 1/2] UefiCpuPkg/CpuCommonFeaturesLib: Remove redundant definition.

2017-08-23 Thread Kinney, Michael D
Eric, Comment below. Mike > -Original Message- > From: Dong, Eric > Sent: Tuesday, August 22, 2017 7:31 PM > To: edk2-devel@lists.01.org > Cc: Kinney, Michael D ; Ni, Ruiyu > > Subject: [Patch 1/2] UefiCpuPkg/CpuCommonFeaturesLib: Remove

Re: [edk2] [PATCH v3 12/23] OvmfPkg/VirtioRngDxe: map host address to device address

2017-08-23 Thread Laszlo Ersek
On 08/23/17 14:22, Brijesh Singh wrote: > patch maps the host address to a device address for buffers (including > rings, device specifc request and response pointed by vring descriptor, > and any further memory reference by those request and response). > > Cc: Ard Biesheuvel

Re: [edk2] Questions about Open Compute Project Server BIOS

2017-08-23 Thread Richardson, Brian
At this point, there is not an OCP project in TianoCore. If one is developed in the future, it will be added as a branch of the edk2-platforms repo: https://github.com/tianocore/edk2-platforms Thanks … br --- Brian Richardson, Senior Technical Marketing Engineer, Intel Software

Re: [edk2] [Patch 2/2] UefiCpuPkg: Update default for PcdCpuProcTraceMemSize/PcdCpuProcTraceOutputScheme.

2017-08-23 Thread Kinney, Michael D
Eric, Some Comments embedded below. Please make sure the UNI file is updated to match the DEC file. For the enum PROC_TRACE_MEM_SIZE, I would prefer the enum values have more than just "Enum" in the beginning. It would be better to use names like "ProcTraceMemSize" so the first enum value

Re: [edk2] [Patch] UefiCpuPkg/MpLib: fix potential overflow issue.

2017-08-23 Thread Kinney, Michael D
Hi Eric, With this patch GetPerformanceCounterProperties() is called twice. I think you can use TimestampCounterFreq in the else clause. Also, the comment blocks are no longer correct. The original comment block goes with the else clause, and you need a new comment block for the if statement

Re: [edk2] [PATCH v3 11/23] OvmfPkg/VirtioLib: change the parameter of VirtioAppendDesc() to UINT64

2017-08-23 Thread Laszlo Ersek
On 08/23/17 14:22, Brijesh Singh wrote: > The patch change the "BufferPhysAddr" parameter of VirtioAppendDesc() > from type UINTN to UINT64. > > UINTN is appropriate as long as we pass system memory references. After > the introduction of this feature, that's no longer the case in general. (1)

Re: [edk2] Iscsi Specification Document

2017-08-23 Thread Blibbet
On 08/23/2017 02:04 AM, Karunakar P wrote: > Do we have any specific Document for Iscsi? > Any document that describes the standard iscsi behavior. I'm not aware of any 'design specification', that may be hoping for too much. http://uefi.org/uefi points to 4 [i]SCSI-related URLs: [RFC 3720]

Re: [edk2] [PATCH v3 10/23] OvmfPkg/VirtioLib: alloc VRING buffer with AllocateSharedPages()

2017-08-23 Thread Laszlo Ersek
On 08/23/17 14:22, Brijesh Singh wrote: > The VRING buffer is a communication area between guest and hypervisor. > Allocate it using VIRTIO_DEVICE_PROTOCOL.AllocateSharedPages() so that > it can be mapped later with VirtioRingMap() for bi-directional access. > > Cc: Ard Biesheuvel

Re: [edk2] [PATCH v3 08/23] OvmfPkg/Virtio10Dxe: add the RingBaseShift offset

2017-08-23 Thread Laszlo Ersek
On 08/23/17 14:22, Brijesh Singh wrote: > virtio drivers use VIRTIO_DEVICE_PROTOCOL.MapSharedBuffer() to map the > ring buffer host address to a device address. If an IOMMU is present then > RingBaseShift contains the offset from the host address. > > Suggested-by: Laszlo Ersek

Re: [edk2] [PATCH v3 07/23] OvmfPkg/Virtio: take RingBaseShift in SetQueueAddress()

2017-08-23 Thread Brijesh Singh
On 08/23/2017 03:43 PM, Laszlo Ersek wrote: On 08/23/17 22:41, Laszlo Ersek wrote: On 08/23/17 14:22, Brijesh Singh wrote: For the case when an IOMMU is used for translating system physical addresses to DMA bus master addresses, the transport-independent virtio device drivers will be

Re: [edk2] [PATCH v3 07/23] OvmfPkg/Virtio: take RingBaseShift in SetQueueAddress()

2017-08-23 Thread Laszlo Ersek
On 08/23/17 22:41, Laszlo Ersek wrote: > On 08/23/17 14:22, Brijesh Singh wrote: >> For the case when an IOMMU is used for translating system physical >> addresses to DMA bus master addresses, the transport-independent >> virtio device drivers will be required to map their VRING areas to >> bus

Re: [edk2] [PATCH v3 07/23] OvmfPkg/Virtio: take RingBaseShift in SetQueueAddress()

2017-08-23 Thread Laszlo Ersek
On 08/23/17 14:22, Brijesh Singh wrote: > For the case when an IOMMU is used for translating system physical > addresses to DMA bus master addresses, the transport-independent > virtio device drivers will be required to map their VRING areas to > bus addresses with

Re: [edk2] [PATCH v3 09/23] OvmfPkg/VirtioLib: add function to map VRING

2017-08-23 Thread Laszlo Ersek
There's one trivial omission in this patch, wrt. the previous review comments: On 08/23/17 14:22, Brijesh Singh wrote: > Add functions to map the ring buffer with BusMasterCommonBuffer so that (1) s/functions/a function/ I'll fix it up before I push the initial subsequence. Reviewed-by: Laszlo

Re: [edk2] [PATCH v3 05/23] OvmfPkg/VirtioLib: add VirtioMapAllBytesInSharedBuffer() helper function

2017-08-23 Thread Laszlo Ersek
There are two trivial omissions in this patch: On 08/23/17 14:22, Brijesh Singh wrote: > The function can be used for mapping the system physical address to virtio > device address using VIRTIO_DEVICE_PROTOCOL.MapSharedBuffer (). The > function helps with centralizing error handling, and it

Re: [edk2] [PATCH v3 04/23] OvmfPkg/VirtioMmioDeviceLib: implement IOMMU-like member functions

2017-08-23 Thread Laszlo Ersek
On 08/23/17 14:22, Brijesh Singh wrote: > The patch implements the newly added IOMMU-like member functions by > respectively delegating the job to: > > - VIRTIO_DEVICE_PROTOCOL.AllocateSharedPages () -> > MemoryAllocationLib.AllocatePages() > > - VIRTIO_DEVICE_PROTOCOL.FreeSharedPages () ->

Re: [edk2] [PATCH v3 03/23] OvmfPkg/VirtioPciDeviceDxe: implement IOMMU-like member functions

2017-08-23 Thread Laszlo Ersek
On 08/23/17 14:22, Brijesh Singh wrote: > The patch implements the newly added IOMMU-like member functions by > respectively delegating the job to: > > - VIRTIO_DEVICE_PROTOCOL.AllocateSharedPages () -> > MemoryAllocationLib.AllocatePages() > > - VIRTIO_DEVICE_PROTOCOL.FreeSharedPages () ->

Re: [edk2] [PATCH v3 02/23] OvmfPkg/Virtio10Dxe: implement IOMMU-like member functions

2017-08-23 Thread Laszlo Ersek
On 08/23/17 14:22, Brijesh Singh wrote: > The patch implements the newly added IOMMU-like member functions by > respectively delegating the job to: > > - VIRTIO_DEVICE_PROTOCOL.AllocateSharedPages() -> > EFI_PCI_IO_PROTOCOL.AllocateBuffer() > > - VIRTIO_DEVICE_PROTOCOL.FreeSharedPages() -> >

Re: [edk2] [PATCH v3 01/23] OvmfPkg: introduce IOMMU-like member functions to VIRTIO_DEVICE_PROTOCOL

2017-08-23 Thread Laszlo Ersek
On 08/23/17 14:22, Brijesh Singh wrote: > The patch extends VIRTIO_DEVICE_PROTOCOL to provide the following new > member functions: > > - AllocateSharedPages : allocate a memory region suitable for sharing >between guest and hypervisor (e.g ring buffer). > > - FreeSharedPages: free the

Re: [edk2] [PATCH V2] IntelFsp2Pkg: Fix build error with WHOLEARCHIVE option

2017-08-23 Thread Kinney, Michael D
Liming, Yes. "empty" is a better term to use. Mike > -Original Message- > From: Gao, Liming > Sent: Tuesday, August 22, 2017 7:35 PM > To: Kinney, Michael D ; Song, BinX > ; Yao, Jiewen ; > Kinney, Michael D

Re: [edk2] [PATCH] ArmVirtPkg: remove QemuVideoDxe from ArmVirtQemu and ArmVirtQemuKernel

2017-08-23 Thread Leif Lindholm
On Wed, Aug 23, 2017 at 03:36:37PM +0200, Laszlo Ersek wrote: > On 08/23/17 15:17, Ard Biesheuvel wrote: > (My R-b stands; these are comments for a possible followup patch.) > > Please see: > > - commit 84a75f70e903 ("OvmfPkg/QemuVideoDxe: enable ARM builds", >

Re: [edk2] [Patch] BaseTools: Add the missing -pie link option in GCC tool chain

2017-08-23 Thread Gao, Liming
Laszlo: Thanks for your quick test. I will add Bugzilla in commit log. And, I will let you know once I push this patch. Thanks Liming > -Original Message- > From: Laszlo Ersek [mailto:ler...@redhat.com] > Sent: Wednesday, August 23, 2017 6:27 PM > To: Gao, Liming

Re: [edk2] [PATCH] ArmVirtPkg: remove QemuVideoDxe from ArmVirtQemu and ArmVirtQemuKernel

2017-08-23 Thread Laszlo Ersek
On 08/23/17 15:17, Ard Biesheuvel wrote: > On 23 August 2017 at 14:15, Leif Lindholm wrote: >> On Tue, Aug 22, 2017 at 06:16:56PM +0100, Ard Biesheuvel wrote: >>> On 22 August 2017 at 18:02, Laszlo Ersek wrote: On 08/22/17 18:30, Ard Biesheuvel

Re: [edk2] [PATCH] ArmVirtPkg: remove QemuVideoDxe from ArmVirtQemu and ArmVirtQemuKernel

2017-08-23 Thread Ard Biesheuvel
On 23 August 2017 at 14:15, Leif Lindholm wrote: > On Tue, Aug 22, 2017 at 06:16:56PM +0100, Ard Biesheuvel wrote: >> On 22 August 2017 at 18:02, Laszlo Ersek wrote: >> > On 08/22/17 18:30, Ard Biesheuvel wrote: >> >> One of the reasons for

Re: [edk2] [PATCH] ArmVirtPkg: remove QemuVideoDxe from ArmVirtQemu and ArmVirtQemuKernel

2017-08-23 Thread Leif Lindholm
On Tue, Aug 22, 2017 at 06:16:56PM +0100, Ard Biesheuvel wrote: > On 22 August 2017 at 18:02, Laszlo Ersek wrote: > > On 08/22/17 18:30, Ard Biesheuvel wrote: > >> One of the reasons for introducing virtio-gpu support to OvmfPkg and > >> ArmVirtpkg was the fact that under KVM

[edk2] [PATCH edk2-platforms] Silicon/Openmoko: add driver for ChaosKey RNG USB device

2017-08-23 Thread Ard Biesheuvel
This is a continuation of the work carried out by Leif Lindholm to implement a driver for the ChaosKey USB device. This driver uses the UEFI driver model, which is a slightly awkward fit, due to the fact that a UEFI implementation may legally only instantiate those protocols that are needed to

[edk2] [PATCH v3 22/23] OvmfPkg/VirtioScsiDxe: negotiate VIRITO_F_IOMMU_PLATFORM

2017-08-23 Thread Brijesh Singh
In previous patches, we have implemented IOMMU-like member functions in VIRTIO_DEVICE_PROTOCOL to translate the physical address to bus address and virtio drivers are updated to use those member functions. We do not need to do anything special when VIRTIO_F_IOMMU_PLATFORM bit is present hence

[edk2] [PATCH v3 21/23] OvmfPkg/VirtioBlkDxe: negotiate VIRITO_F_IOMMU_PLATFORM

2017-08-23 Thread Brijesh Singh
In previous patches, we have implemented IOMMU-like member functions in VIRTIO_DEVICE_PROTOCOL to translate the physical address to bus address and virtio drivers are updated to use those member functions. We do not need to do anything special when VIRTIO_F_IOMMU_PLATFORM bit is present hence

[edk2] [PATCH v3 23/23] OvmfPkg/VirtioNetDxe: negotiate VIRITO_F_IOMMU_PLATFORM

2017-08-23 Thread Brijesh Singh
In previous patches, we have implemented IOMMU-like member functions in VIRTIO_DEVICE_PROTOCOL to translate the physical address to bus address and virtio drivers are updated to use those member functions. We do not need to do anything special when VIRTIO_F_IOMMU_PLATFORM bit is present hence

[edk2] [PATCH v3 19/23] OvmfPkg/Virtio10: define VIRITO_F_IOMMU_PLATFORM feature bit

2017-08-23 Thread Brijesh Singh
This feature indicates that the device is behind an IOMMU that translates bus addresses from the device into physical addresses in memory. If this feature bit is set to 0, then the device emits physical addresses which are not translated further, even though an IOMMU may be present. see [1] for

[edk2] [PATCH v3 20/23] OvmfPkg/VirtioRngDxe: negotiate VIRITO_F_IOMMU_PLATFORM

2017-08-23 Thread Brijesh Singh
In previous patches, we have implemented IOMMU-like member functions in VIRTIO_DEVICE_PROTOCOL to translate the physical address to bus address and virtio drivers are updated to use those member functions. We do not need to do anything special when VIRTIO_F_IOMMU_PLATFORM bit is present hence

[edk2] [PATCH v3 16/23] OvmfPkg/VirtioNetDxe: alloc RxBuf using AllocateSharedPages()

2017-08-23 Thread Brijesh Singh
RxBuf is shared between guest and hypervisor, use VIRTIO_DEVICE_PROTOCOL.AllocateSharedPages() to allocate this memory region and map it with BusMasterCommonBuffer operation so that it can be accessed by both guest and hypervisor. Cc: Ard Biesheuvel Cc: Jordan Justen

[edk2] [PATCH v3 14/23] OvmfPkg/VirtioScsiDxe: map host address to device address

2017-08-23 Thread Brijesh Singh
The VirtioScsiPassThru() function, programs the vring descriptor using the host addresses pointed-by virtio-scsi request, response and memory that is referenced inside the request and response header. The patch uses newly introduced VIRTIO_DEVICE_PROTOCOL.MapSharedBuffer() function to map system

[edk2] [PATCH v3 18/23] OvmfPkg/VirtioNetDxe: map transmit buffer host address to device address

2017-08-23 Thread Brijesh Singh
Update VirtioNetTransmit() function, to map the callers transmit buffer host address to a device address. Since the transmit buffers are returned back to caller in VirtioNetGetStatus() hence we maintain a simple list to maintain 1:1 mapping between host address to device address. The list is

[edk2] [PATCH v3 17/23] OvmfPkg/VirtioNetDxe: dynamically alloc transmit header

2017-08-23 Thread Brijesh Singh
A network packets are transmitted by placing them into a transmit queue, each packet is preceded by a VIRTIO_1_0_NET_REQ header. VirtioNetInitTx(), builds the header once and fills the vring descriptors with the system physical address of the VIRTIO_1_0_NET_REQ header. The patch uses

[edk2] [PATCH v3 11/23] OvmfPkg/VirtioLib: change the parameter of VirtioAppendDesc() to UINT64

2017-08-23 Thread Brijesh Singh
The patch change the "BufferPhysAddr" parameter of VirtioAppendDesc() from type UINTN to UINT64. UINTN is appropriate as long as we pass system memory references. After the introduction of this feature, that's no longer the case in general. Should we implement "real" IOMMU support at some point,

[edk2] [PATCH v3 04/23] OvmfPkg/VirtioMmioDeviceLib: implement IOMMU-like member functions

2017-08-23 Thread Brijesh Singh
The patch implements the newly added IOMMU-like member functions by respectively delegating the job to: - VIRTIO_DEVICE_PROTOCOL.AllocateSharedPages () -> MemoryAllocationLib.AllocatePages() - VIRTIO_DEVICE_PROTOCOL.FreeSharedPages () -> MemoryAllocationLib.FreePages () -

[edk2] [PATCH v3 06/23] OvmfPkg/VirtioLib: take VirtIo instance in VirtioRingInit/VirtioRingUninit

2017-08-23 Thread Brijesh Singh
Passing the VirtIo protocol instance will allow the vring to use VIRTIO_DEVICE_PROTOCOL.AllocateSharedPages () to allocate vring buffer. Cc: Ard Biesheuvel Cc: Jordan Justen Cc: Tom Lendacky Cc: Laszlo Ersek

[edk2] [PATCH v3 02/23] OvmfPkg/Virtio10Dxe: implement IOMMU-like member functions

2017-08-23 Thread Brijesh Singh
The patch implements the newly added IOMMU-like member functions by respectively delegating the job to: - VIRTIO_DEVICE_PROTOCOL.AllocateSharedPages() -> EFI_PCI_IO_PROTOCOL.AllocateBuffer() - VIRTIO_DEVICE_PROTOCOL.FreeSharedPages() -> EFI_PCI_IO_PROTOCOL.FreeBuffer() -

[edk2] [PATCH v3 09/23] OvmfPkg/VirtioLib: add function to map VRING

2017-08-23 Thread Brijesh Singh
Add functions to map the ring buffer with BusMasterCommonBuffer so that ring can be accessed by both guest and hypervisor. Cc: Ard Biesheuvel Cc: Jordan Justen Cc: Tom Lendacky Cc: Laszlo Ersek

[edk2] [PATCH v3 15/23] OvmfPkg/VirtioNetDxe: alloc Tx and Rx rings using AllocateSharedPage()

2017-08-23 Thread Brijesh Singh
The Tx and Rx rings are accessed by both guest and hypervisor, allocate the rings using newly added VirtIo->AllocateSharedPages() and map it with BusMasterCommonBuffer so that it can be accessed by both guest and hypervisor. Cc: Ard Biesheuvel Cc: Jordan Justen

[edk2] [PATCH v3 13/23] OvmfPkg/VirtioBlkDxe: map host address to device address

2017-08-23 Thread Brijesh Singh
The SynchronousRequest() function, programs the vring descriptor with the buffers pointed-by virtio-blk requests, status and memory that is referenced inside the request header. The patch uses VIRTIO_DEVICE_PROTOCOL.MapSharedBuffer() function to map host address to device address and programs the

[edk2] [PATCH v3 05/23] OvmfPkg/VirtioLib: add VirtioMapAllBytesInSharedBuffer() helper function

2017-08-23 Thread Brijesh Singh
The function can be used for mapping the system physical address to virtio device address using VIRTIO_DEVICE_PROTOCOL.MapSharedBuffer (). The function helps with centralizing error handling, and it allows the caller to pass in constant or other evaluated expressions for NumberOfBytes. Cc: Ard

[edk2] [PATCH v3 10/23] OvmfPkg/VirtioLib: alloc VRING buffer with AllocateSharedPages()

2017-08-23 Thread Brijesh Singh
The VRING buffer is a communication area between guest and hypervisor. Allocate it using VIRTIO_DEVICE_PROTOCOL.AllocateSharedPages() so that it can be mapped later with VirtioRingMap() for bi-directional access. Cc: Ard Biesheuvel Cc: Jordan Justen

[edk2] [PATCH v3 08/23] OvmfPkg/Virtio10Dxe: add the RingBaseShift offset

2017-08-23 Thread Brijesh Singh
virtio drivers use VIRTIO_DEVICE_PROTOCOL.MapSharedBuffer() to map the ring buffer host address to a device address. If an IOMMU is present then RingBaseShift contains the offset from the host address. Suggested-by: Laszlo Ersek Cc: Ard Biesheuvel

[edk2] [PATCH v3 01/23] OvmfPkg: introduce IOMMU-like member functions to VIRTIO_DEVICE_PROTOCOL

2017-08-23 Thread Brijesh Singh
The patch extends VIRTIO_DEVICE_PROTOCOL to provide the following new member functions: - AllocateSharedPages : allocate a memory region suitable for sharing between guest and hypervisor (e.g ring buffer). - FreeSharedPages: free the memory allocated using AllocateSharedPages (). -

[edk2] [PATCH v3 00/21] OvmfPkg/Virtio: introduce IOMMU-like member functions

2017-08-23 Thread Brijesh Singh
Currently, virtio drivers provides the system physical address to the device. However, some systems may feature an IOMMU that requires the drivers to pass the device addresses to the device - which are then translated by the IOMMU into physical addresses in memory. The patch series introduces new

[edk2] [PATCH v3 03/23] OvmfPkg/VirtioPciDeviceDxe: implement IOMMU-like member functions

2017-08-23 Thread Brijesh Singh
The patch implements the newly added IOMMU-like member functions by respectively delegating the job to: - VIRTIO_DEVICE_PROTOCOL.AllocateSharedPages () -> MemoryAllocationLib.AllocatePages() - VIRTIO_DEVICE_PROTOCOL.FreeSharedPages () -> MemoryAllocationLib.FreePages () -

[edk2] [PATCH v3 07/23] OvmfPkg/Virtio: take RingBaseShift in SetQueueAddress()

2017-08-23 Thread Brijesh Singh
For the case when an IOMMU is used for translating system physical addresses to DMA bus master addresses, the transport-independent virtio device drivers will be required to map their VRING areas to bus addresses with VIRTIO_DEVICE_PROTOCOL.MapSharedBuffer() calls. VirtioRingMap() maps the ring

Re: [edk2] [PATCH edk2-platforms] Maintainers.txt: Add Ard Biesheuvel

2017-08-23 Thread Leif Lindholm
On Tue, Aug 22, 2017 at 10:46:38PM +, Kinney, Michael D wrote: > Reviewed-by: Michael D Kinney Thanks! Puched (together with Contributions.txt update) as b263c30e5..98c7d7520. / Leif > Mike > > > -Original Message- > > From: Leif Lindholm

Re: [edk2] [Patch] BaseTools: Add the missing -pie link option in GCC tool chain

2017-08-23 Thread Laszlo Ersek
Hi Liming, On 08/23/17 10:04, Liming Gao wrote: > GCC tool chain uses -fpie in CC_FLAGS. So, add -pie in DLINK_FLAGS. > > More discussion in > https://lists.01.org/pipermail/edk2-devel/2017-August/013508.html > > 3.13 Options for Linking > > '-pie' > Produce a

Re: [edk2] [PATCH] Maintainers.txt: update OvmfPkg maintainership

2017-08-23 Thread Wei Liu
On Wed, Aug 23, 2017 at 11:04:06AM +0200, Laszlo Ersek wrote: > On 08/23/17 03:30, Konrad Rzeszutek Wilk wrote: > > It should be fairly simple to expand the 0-day OSSTest to build > > TianoCore and launch guests with it as a nice regression test. > > The point is to catch regressions before they

Re: [edk2] Iscsi Specification Document

2017-08-23 Thread Karunakar P
Hello All, Do we have any specific Document for Iscsi? Any document that describes the standard iscsi behavior. Thanks, karunakar ___ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel

Re: [edk2] [PATCH] Maintainers.txt: update OvmfPkg maintainership

2017-08-23 Thread Laszlo Ersek
Hello Konrad, On 08/23/17 03:30, Konrad Rzeszutek Wilk wrote: > On Thu, Aug 17, 2017 at 01:47:59AM +0200, Laszlo Ersek wrote: >> On 08/17/17 00:37, Jordan Justen wrote: >>> On 2017-08-16 12:23:49, Leif Lindholm wrote: >> >> [snip] >> - the value proposition for Linaro is that having

[edk2] [Patch] BaseTools: Add the missing -pie link option in GCC tool chain

2017-08-23 Thread Liming Gao
GCC tool chain uses -fpie in CC_FLAGS. So, add -pie in DLINK_FLAGS. More discussion in https://lists.01.org/pipermail/edk2-devel/2017-August/013508.html 3.13 Options for Linking '-pie' Produce a position independent executable on targets that support it. For

Re: [edk2] [PATCH 0/5] PeiCore: Support pre memory page allocation

2017-08-23 Thread Gao, Liming
Reviewed-by: Star Zeng >-Original Message- >From: Zeng, Star >Sent: Saturday, August 19, 2017 12:01 AM >To: edk2-devel@lists.01.org >Cc: Zeng, Star ; Gao, Liming ; Ni, >Ruiyu >Subject: [PATCH 0/5]

[edk2] [PATCH] BaseTools/Conf: Support LLVM39 and LLVM40 in CLANG38 toolchain

2017-08-23 Thread Shi Steven
From: "Shi, Steven" Add LLVM39 and LLVM40 support in CLANG38 toolchain Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Steven Shi --- BaseTools/Conf/tools_def.template | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)

Re: [edk2] [PATCH edk2-platforms] Maintainers.txt: Add Ard Biesheuvel

2017-08-23 Thread Ard Biesheuvel
On 22 August 2017 at 23:23, Leif Lindholm wrote: > Initial version contained only myself and Mike. While a more granular > structure will be needed long-term, let's have two ARM-maintainers for now. > > Cc: Ard Biesheuvel > Cc: Michael D