https://git.reactos.org/?p=reactos.git;a=commitdiff;h=382836f08758055948a52…
commit 382836f08758055948a52f3f20c1d33ec00e2a8c
Author: Hervé Poussineau <hpoussin(a)reactos.org>
AuthorDate: Wed Dec 13 19:59:43 2023 +0100
Commit: Hervé Poussineau <hpoussin(a)reactos.org>
CommitDate: Sat Jan 13 15:23:46 2024 +0100
[TCPIP] Remove code duplication to get max link speed, MTU and max packet size
This is already done when link goes up, in ReconfigureAdapter() function.
---
drivers/network/tcpip/datalink/lan.c | 32 --------------------------------
1 file changed, 32 deletions(-)
diff --git a/drivers/network/tcpip/datalink/lan.c b/drivers/network/tcpip/datalink/lan.c
index 1da4e2129d6..e24c8985472 100644
--- a/drivers/network/tcpip/datalink/lan.c
+++ b/drivers/network/tcpip/datalink/lan.c
@@ -1371,38 +1371,6 @@ BOOLEAN BindAdapter(
TI_DbgPrint(DEBUG_DATALINK,("Adapter Description: %wZ\n",
&IF->Description));
- /* Get maximum link speed */
- NdisStatus = NDISCall(Adapter,
- NdisRequestQueryInformation,
- OID_GEN_LINK_SPEED,
- &IF->Speed,
- sizeof(UINT));
-
- if (!NT_SUCCESS(NdisStatus))
- IF->Speed = IP_DEFAULT_LINK_SPEED;
-
- Adapter->Speed = IF->Speed * 100L;
-
- /* Get maximum frame size */
- NdisStatus = NDISCall(Adapter,
- NdisRequestQueryInformation,
- OID_GEN_MAXIMUM_FRAME_SIZE,
- &Adapter->MTU,
- sizeof(UINT));
- if (NdisStatus != NDIS_STATUS_SUCCESS)
- return FALSE;
-
- IF->MTU = Adapter->MTU;
-
- /* Get maximum packet size */
- NdisStatus = NDISCall(Adapter,
- NdisRequestQueryInformation,
- OID_GEN_MAXIMUM_TOTAL_SIZE,
- &Adapter->MaxPacketSize,
- sizeof(UINT));
- if (NdisStatus != NDIS_STATUS_SUCCESS)
- return FALSE;
-
/* Register interface with IP layer */
IPRegisterInterface(IF);