| Summary: | Clearing PME mode kills network performance on NatSemi DP83815 using sis driver | ||
|---|---|---|---|
| Product: | Base System | Reporter: | Daniel Rudy <dcrudy> |
| Component: | kern | Assignee: | freebsd-bugs (Nobody) <bugs> |
| Status: | Closed FIXED | ||
| Severity: | Affects Only Me | ||
| Priority: | Normal | ||
| Version: | 4.4-STABLE | ||
| Hardware: | Any | ||
| OS: | Any | ||
State Changed From-To: open->feedback Is this bug still present in more recent releases? I have found and had been setting the hw.sis_quick sysctl variable to 0 to also correct performance, but now on the later versions, this sysctl variable no longer exists. I have not tested any large file transfers as of late, but I will report back to this PR my results in testing. -- Daniel Rudy Further testing indicates the following results: I built a file called testarchive which is 311,787,520 bytes. Transmission from FreeBSD 4.7 to a WinXP Pro is 30.46 seconds with a network throughput of 10234.96KB/s. Transmission in the opposite direction between the two same computers yeilded 26.84 seconds at 11617.39KB/s. Not bad. I guess the problem has been fixed. -- Daniel Rudy State Changed From-To: feedback->closed Submitter reckons problem is fixed. |
Refer to PR-31737. Network performance under full-duplex is greatly reduced. Symptoms of this failure is with NFS or FTP where file sizes are greater than about 60K. The network slows down to a crawl and then quits. The same problem is experienced with MS Windows machines when communicating to FreeBSD machines. MS Windows based machines do not exhibit the same problem when communicating to other MS Windows based machines. Network cards involved are Netgear FA-312 series. All machines involved have the same network card. 100BaseTX Full Duplex mode has been verified on all machines, both FreeBSD and Windows, and the switch registers full duplex link as well. The hub that is used is a NDC Communications NSH510 10/100 Autosensing 5-port switch. The problem does not show up under half duplex mode. And furthermore, it is not a hardware interaction problem between the switch and the network interface card because this DID work in 4.2 and the only thing that has changed on my end is the FreeBSD load on the machines. By the actions that I have taken, it appears that clearing the PME mode in the chip init code kills network performance when it comes to large file transfers. Fix: static void sis_reset(sc) struct sis_softc *sc; { register int i; SIS_SETBIT(sc, SIS_CSR, SIS_CSR_RESET); for (i = 0; i < SIS_TIMEOUT; i++) { if (!(CSR_READ_4(sc, SIS_CSR) & SIS_CSR_RESET)) break; } if (i == SIS_TIMEOUT) printf("sis%d: reset never completed\n", sc->sis_unit); /* Wait a little while for the chip to get its brains in order. */ DELAY(1000); /* * If this is a NetSemi chip, make sure to clear * PME mode. */ /* if (sc->sis_type == SIS_TYPE_83815) { CSR_WRITE_4(sc, NS_CLKRUN, NS_CLKRUN_PMESTS); CSR_WRITE_4(sc, NS_CLKRUN, 0); } commented out for testing pourposes */ return; } Commenting out the section of code dealing with Power Manegement Event mode fixes the problem, at least for me and my hardware. How-To-Repeat: Netgear FA-312 NICs to full duplex mode using any mainboard. I'm using a FIC, DFI, and DTK boards in my computers.