[edk2] [PATCH] BaseTools/EOT: Change to call a program instead of calling Python API.

2018-10-15 Thread Yonghong Zhu
From: hchen30 Update the EOT tool to call the program itself instead of calling the Python API when parsing FV images. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hess Chen --- BaseTools/Source/Python/Eot/{Eot.py => EotMain.py} | 465 +++--

Re: [edk2] [PATCH 1/1] BaseTools: Fix regression boot hang issue by commit 0e982cf03dd5

2018-10-15 Thread Zhu, Yonghong
I pushed this patch first since it helped to fix the critical bug. Version: SHA-1: 272ecccd793c8fb12f4f356ada18a870c2426603 Best Regards, Zhu Yonghong -Original Message- From: Zhu, Yonghong Sent: Monday, October 15, 2018 6:18 PM To: Feng, YunhuaX ; edk2-devel@lists.01.org Cc: Gao,

Re: [edk2] [PATCH 1/1] BaseTools: Fix regression boot hang issue by commit 0e982cf03dd5

2018-10-15 Thread Zhu, Yonghong
Reviewed-by: Yonghong Zhu Best Regards, Zhu Yonghong -Original Message- From: Feng, YunhuaX Sent: Monday, October 15, 2018 5:04 PM To: edk2-devel@lists.01.org Cc: Zhu, Yonghong ; Gao, Liming Subject: [PATCH 1/1] BaseTools: Fix regression boot hang issue by commit 0e982cf03dd5 Fix

[edk2] [PATCH 1/1] BaseTools: Fix regression boot hang issue by commit 0e982cf03dd5

2018-10-15 Thread Feng, YunhuaX
Fix regression boot hang issue by commit 0e982cf03dd5023b90def60c3656e5e18135ebac Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/GenFds/Fv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

Re: [edk2] [PATCH V3] BaseTools: add ASSERT checker for array buffer value assignment.

2018-10-15 Thread Gao, Liming
Reviewed-by: Liming Gao >-Original Message- >From: Zhao, ZhiqiangX >Sent: Tuesday, September 25, 2018 2:01 PM >To: edk2-devel@lists.01.org >Cc: Zhao, ZhiqiangX ; Gao, Liming >; Zhu, Yonghong ; Feng, >Bob C >Subject: [PATCH V3] BaseTools: add ASSERT checker for array buffer value

Re: [edk2] [PATCH V2] BaseTools: Code should not update the variable that save the raw data.

2018-10-15 Thread Gao, Liming
Zhiqiang: The patch is good to me. Reviewed-by: Liming Gao But, please remember to send patch mail, not attach the patch for review. Thanks Liming >-Original Message- >From: Zhao, ZhiqiangX >Sent: Tuesday, September 25, 2018 3:16 PM >To: Gao, Liming ; edk2-devel@lists.01.org

[edk2] [PATCH 10/11] MdeModulePkg/UsbBus: Deny when the string descriptor length is odd

2018-10-15 Thread Ruiyu Ni
Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni Cc: Jiewen Yao Cc: Star Zeng --- MdeModulePkg/Bus/Usb/UsbBusDxe/UsbDesc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MdeModulePkg/Bus/Usb/UsbBusDxe/UsbDesc.c

[edk2] [PATCH 07/11] MdeModulePkg/UsbKb: Don't access key codes when length is wrong

2018-10-15 Thread Ruiyu Ni
Per USB HID spec, the buffer holding key codes should be 8-byte long. Today's code assumes that the key codes buffer length is 8-byte long and unconditionally accesses the key codes buffer. It's incorrect. The patch fixes the issue by returning Device Error when the length is less than 8-byte.

[edk2] [PATCH 09/11] MdeModulePkg/UsbMouse: Don't access key codes when length is wrong

2018-10-15 Thread Ruiyu Ni
Per USB HID spec, the buffer holding key codes should at least 3-byte long. Today's code assumes that the key codes buffer length is longer than 3-byte and unconditionally accesses the key codes buffer. It's incorrect. The patch fixes the issue by returning Device Error when the length is less

[edk2] [PATCH 11/11] MdeModulePkg/Bus/Ufs: Ensure device not return more data than expected

2018-10-15 Thread Ruiyu Ni
From: Hao Wu This commit adds checks to make sure the UFS devices do not return more data than the driver expected. Cc: Ruiyu Ni Cc: Jiewen Yao Cc: Star Zeng Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Hao Wu --- MdeModulePkg/Bus/Ufs/UfsBlockIoPei/UfsHci.c

[edk2] [PATCH 08/11] MdeModulePkg/AbsPointer: Don't access key codes when length is wrong

2018-10-15 Thread Ruiyu Ni
Per USB HID spec, the buffer holding key codes should at least 3-byte long. Today's code assumes that the key codes buffer length is longer than 3-byte and unconditionally accesses the key codes buffer. It's incorrect. The patch fixes the issue by returning Device Error when the length is less

[edk2] [PATCH 04/11] MdeModulePkg/UsbBus: Reject descriptor whose length is bad

2018-10-15 Thread Ruiyu Ni
Today's implementation doesn't check whether the length of descriptor is valid before using it. The patch fixes this issue. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni Cc: Star Zeng Cc: Jiewen Yao --- MdeModulePkg/Bus/Usb/UsbBusDxe/UsbDesc.c | 7 +++ 1

[edk2] [PATCH 06/11] SourceLevelDebugPkg/Usb3: Make sure data from HW can fit in buffer

2018-10-15 Thread Ruiyu Ni
Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni Cc: Hao A Wu --- .../DebugCommunicationLibUsb3/DebugCommunicationLibUsb3Transfer.c | 7 +++ 1 file changed, 7 insertions(+) diff --git

[edk2] [PATCH 05/11] MdeModulePkg/Usb: Make sure data from HW is no more than expected

2018-10-15 Thread Ruiyu Ni
Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni Cc: Jiewen Yao Cc: Star Zeng Cc: Hao A Wu --- MdeModulePkg/Bus/Pci/EhciDxe/EhciSched.c | 9 ++--- MdeModulePkg/Bus/Pci/UhciDxe/UhciSched.c | 7 --- MdeModulePkg/Bus/Pci/XhciDxe/XhciSched.c | 9 ++--- 3

[edk2] [PATCH 03/11] MdeModulePkg/UsbBus: Fix out-of-bound read access to descriptors

2018-10-15 Thread Ruiyu Ni
Today's implementation reads the Type/Length field in the USB descriptors data without checking whether the offset to read is beyond the data boundary. The patch fixes this issue. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni Cc: Star Zeng Cc: Jiewen Yao ---

[edk2] [PATCH 00/11] Need to validate data from HW

2018-10-15 Thread Ruiyu Ni
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1250 The patches contain logic to check the data from HW before using. It can avoid corrupted data from HW causes software behave abnormally. Hao Wu (1): MdeModulePkg/Bus/Ufs: Ensure device not return more data than expected Ruiyu Ni (10):

[edk2] [PATCH 01/11] MdeModulePkg/UsbMass: Merge UsbBoot(Read|Write)Blocks(16)

2018-10-15 Thread Ruiyu Ni
The change doesn't have functionality impact. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni Cc: Star Zeng --- .../Bus/Usb/UsbMassStorageDxe/UsbMassBoot.c| 248 + .../Bus/Usb/UsbMassStorageDxe/UsbMassBoot.h| 76 ++-

[edk2] [PATCH 02/11] MdeModulePkg/UsbMass: Fix integer overflow when BlockSize is 1

2018-10-15 Thread Ruiyu Ni
UsbBootReadWriteBlocks() and UsbBootReadWriteBlocks16() use a UINT16 local variable to hold the value of USB_BOOT_MAX_CARRY_SIZE (=0x1) / BlockSize. When BlockSize is 1, the UINT16 local variable is set to 0x1 but the high-16 bits are truncated resulting the final value be 0. It causes

<    1   2