Revert "DebugUsb3: Fix GCC build failures"

This reverts commit ad6040ec9b.

Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Hao Wu <hao.a.wu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
Reviewed-by: Hao Wu <hao.a.wu@intel.com>
This commit is contained in:
Star Zeng
2018-03-14 16:09:10 +08:00
parent abea3bca82
commit 373b1d0ee3
2 changed files with 5 additions and 1 deletions

View File

@ -906,6 +906,7 @@ DebugPortWriteBuffer (
USB3_DEBUG_PORT_HANDLE *UsbDebugPortHandle;
UINTN Sent;
UINTN Total;
UINTN Index;
if (NumberOfBytes == 0 || Buffer == NULL) {
return 0;
@ -933,6 +934,7 @@ DebugPortWriteBuffer (
//
DebugPortPollBuffer (UsbDebugPortHandle);
Index = 0;
while ((Total < NumberOfBytes)) {
if (NumberOfBytes - Total > USB3_DEBUG_PORT_WRITE_MAX_PACKET_SIZE) {
Sent = USB3_DEBUG_PORT_WRITE_MAX_PACKET_SIZE;