My fault, please ignore this patch.
Thanks,
Nhi
________________________________
From: devel@edk2.groups.io <devel@edk2.groups.io> on behalf of Nhi Pham via groups.io <nhi=os.amperecomputing.com@groups.io>
Sent: Wednesday, May 26, 2021 5:06 PM
To: devel@edk2.groups.io <devel@edk2.groups.io>
Cc: Nhi Pham OS <nhi@os.amperecomputing.com>
Subject: [edk2-devel] [PATCH 1/1] UsbCdcNetDxe: Remove reading connection status in SNP GetStatus
Only read the Ethernet connection status at the initialization of SNP.
Signed-off-by: Nhi Pham <nhi@os.amperecomputing.com>
---
.../Drivers/UsbCdcNetDxe/SimpleNetwork.c | 12 ------------
1 file changed, 12 deletions(-)
diff --git a/Platform/Ampere/AmperePlatformPkg/Drivers/UsbCdcNetDxe/SimpleNetwork.c b/Platform/Ampere/AmperePlatformPkg/Drivers/UsbCdcNetDxe/SimpleNetwork.c
index 05c31f4bad9e..e44898cbda47 100644
--- a/Platform/Ampere/AmperePlatformPkg/Drivers/UsbCdcNetDxe/SimpleNetwork.c
+++ b/Platform/Ampere/AmperePlatformPkg/Drivers/UsbCdcNetDxe/SimpleNetwork.c
@@ -116,8 +116,6 @@ SnpGetStatus (
EFI_STATUS Status;
EFI_TPL OldTpl;
- DEBUG ((DEBUG_ERROR, "%a %d Entry \n", __FUNCTION__, __LINE__));
-
if (SimpleNetwork == NULL || SimpleNetwork->Mode == NULL) {
return EFI_INVALID_PARAMETER;
}
@@ -154,16 +152,6 @@ SnpGetStatus (
*InterruptStatus = 0;
}
- Status = UsbCdcGetLinkStatus (PrivateData);
- if (EFI_ERROR (Status)) {
- Mode->MediaPresent = FALSE;
- } else {
- Mode->MediaPresent = PrivateData->LinkUp;
- DEBUG ((EFI_D_INFO, "%a %d Mode->MediaPresent = %d \n", __FUNCTION__, __LINE__, (UINT8)Mode->MediaPresent));
- }
-
- DEBUG ((DEBUG_ERROR, "%a %d End - %r \n", __FUNCTION__, __LINE__, Status));
-
//
// Restore TPL and return the operation status
//
--
2.17.1
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#75657): https://edk2.groups.io/g/devel/message/75657
Mute This Topic: https://groups.io/mt/83097092/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-