Pārlūkot izejas kodu

[intel] Do not enable ASDE on i350 backplane NIC

On most Intel NICs, Auto-Speed Detection Enable (ASDE) can be used to
automatically detect the correct link speed by sampling the link using
the internal PHY.  This feature is automatically inhibited when not
appropriate for the physical link (e.g. when using internal SerDes
mode on the 8254x).

On the i350 datasheet ASDE is a reserved bit, but the relevant
auto-speed detection hardware appears still to be present.  However,
enabling ASDE on the i350 1000BASE-KX backplane NIC seems to cause an
immediate link failure.  It is possible that the auto-speed detection
hardware is still present, is not connected to a physical link, and is
not inhibited from being applied in this mode.

Work around this problem by adding an INTEL_NO_ASDE flag bit
(analogous to INTEL_NO_PHY_RST), and applying this for the i350
backplane NIC.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 7 gadus atpakaļ
vecāks
revīzija
2d79b20f2a
2 mainītis faili ar 6 papildinājumiem un 2 dzēšanām
  1. 4
    2
      src/drivers/net/intel.c
  2. 2
    0
      src/drivers/net/intel.h

+ 4
- 2
src/drivers/net/intel.c Parādīt failu

295
 	mdelay ( INTEL_RESET_DELAY_MS );
295
 	mdelay ( INTEL_RESET_DELAY_MS );
296
 
296
 
297
 	/* Set a sensible default configuration */
297
 	/* Set a sensible default configuration */
298
-	ctrl |= ( INTEL_CTRL_SLU | INTEL_CTRL_ASDE );
298
+	if ( ! ( intel->flags & INTEL_NO_ASDE ) )
299
+		ctrl |= INTEL_CTRL_ASDE;
300
+	ctrl |= INTEL_CTRL_SLU;
299
 	ctrl &= ~( INTEL_CTRL_LRST | INTEL_CTRL_FRCSPD | INTEL_CTRL_FRCDPLX );
301
 	ctrl &= ~( INTEL_CTRL_LRST | INTEL_CTRL_FRCSPD | INTEL_CTRL_FRCDPLX );
300
 	writel ( ctrl, intel->regs + INTEL_CTRL );
302
 	writel ( ctrl, intel->regs + INTEL_CTRL );
301
 	mdelay ( INTEL_RESET_DELAY_MS );
303
 	mdelay ( INTEL_RESET_DELAY_MS );
1110
 	PCI_ROM ( 0x8086, 0x1518, "82576ns", "82576NS SerDes", 0 ),
1112
 	PCI_ROM ( 0x8086, 0x1518, "82576ns", "82576NS SerDes", 0 ),
1111
 	PCI_ROM ( 0x8086, 0x1521, "i350", "I350", 0 ),
1113
 	PCI_ROM ( 0x8086, 0x1521, "i350", "I350", 0 ),
1112
 	PCI_ROM ( 0x8086, 0x1522, "i350-f", "I350 Fiber", 0 ),
1114
 	PCI_ROM ( 0x8086, 0x1522, "i350-f", "I350 Fiber", 0 ),
1113
-	PCI_ROM ( 0x8086, 0x1523, "i350-b", "I350 Backplane", 0 ),
1115
+	PCI_ROM ( 0x8086, 0x1523, "i350-b", "I350 Backplane", INTEL_NO_ASDE ),
1114
 	PCI_ROM ( 0x8086, 0x1524, "i350-2", "I350", 0 ),
1116
 	PCI_ROM ( 0x8086, 0x1524, "i350-2", "I350", 0 ),
1115
 	PCI_ROM ( 0x8086, 0x1525, "82567v-4", "82567V-4", 0 ),
1117
 	PCI_ROM ( 0x8086, 0x1525, "82567v-4", "82567V-4", 0 ),
1116
 	PCI_ROM ( 0x8086, 0x1526, "82576-5", "82576", 0 ),
1118
 	PCI_ROM ( 0x8086, 0x1526, "82576-5", "82576", 0 ),

+ 2
- 0
src/drivers/net/intel.h Parādīt failu

306
 	INTEL_VMWARE = 0x0002,
306
 	INTEL_VMWARE = 0x0002,
307
 	/** PHY reset is broken */
307
 	/** PHY reset is broken */
308
 	INTEL_NO_PHY_RST = 0x0004,
308
 	INTEL_NO_PHY_RST = 0x0004,
309
+	/** ASDE is broken */
310
+	INTEL_NO_ASDE = 0x0008,
309
 };
311
 };
310
 
312
 
311
 /**
313
 /**

Notiek ielāde…
Atcelt
Saglabāt