FAQs about Nic settings in Linux (4)

Source: Internet
Author: User
Article title: FAQs about Nic settings in Linux (4 ). Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
The shared memory ISA Nic in the PCI machine does not work (0 xffff)
  
This usually shows that a large number of 0xffff values are read. Unless you have correctly set the pci rom bios/cmos setup configuration, any type of shared memory Nic will not work on the PCI machine. You must set the memory area used by the NIC to allow access to the shared memory from the ISA bus. If you do not know which settings are useful, ask your supplier or your local computer. For the ami bios, there is an "ISA Shared Memory Size" and "ISA Shared Memory Base" setting in the "Plug and Play" section. For NICs similar to wd8013 and SMC Ultra, change the size of the shared memory from the default value to 16 kB, and change the base address to the shared memory address of the NIC.
  
The NIC seems to be sending data, but has not received the data.
  
Run cat/proc/interrupts. The list displays the real-time number of all network interface card interruption events. If it is 0 or is not added when you try to use the NIC, it may be a physical interruption (whether other devices install/provide drivers) that conflicts with other devices installed on the computer ). Change the IRQ of a device to an unused one.
  
Asynchronous transmission mode (ATM) support
  
Werner Almesberger is working on supporting the Linux ATM. He uses Efficient Networks's ENI155p board (Efficient Networks) and Zeitnet's ZN1221 board (Zeitnet ).
  
Werner said that the driver of ENI155p is very stable, and the driver of ZN1221 is not complete yet.
  
Go to the following connection to check the latest progress:
  
Linux ATM Support
  
Support for gibit Ethernet
  
Does Linux support gibit Ethernet?
  
Yes, at least two drivers are available. There is a Packet Engines G-NIC PCI gibit Ethernet adapter driver in the v2.0 and v2.2 kernels. For more details, support, and updates of the driver, visit:
  
Http://cesdis.gsfc.nasa.gov/linux/drivers/yellowfin.html
  
The acenic. c driver provided by the v2.2 kernel can be used for the AceNIC of Alteon and Tigon-based NICs such as 3c985 of 3Com. This driver can also be used for NetGear GA620, but it needs to be confirmed.
  
FDDI support
Does Linux support FDDI?
  
Yes. Larry Stefani compiled Digital's DEFEA (fddi eisa) and DEFPA (fddi pci) Nic drivers for v2.0. It is included in the v2.0.24 kernel. No other NICs are supported currently.
  
Full duplex support
  
Can the full duplex reach 20 Mbps? Is Linux supported?
  
Cameron Spitzer has the following comments on the full-duplex 10Base-T Nic: "If you connect to the full-duplex switch HUB, your system is fast enough and does not do much other work, it keeps your network busy in both directions. There is no full-duplex 10BASE-2 or 10BASE-5 (thin and rough ). Full duplex is achieved by canceling the collision detection of the adapter. This is why full duplex cannot be implemented using coaxial cables; and full duplex LAN cannot be used. 10BASE-T (RJ45 interface) uses different lines for sending and receiving, so the two may be performed simultaneously. Exchange HUB to handle collision issues. The signal speed is 10 Mbps ."
  
Therefore, you can only receive or send data at a rate of 10 Mbps, and you cannot expect a performance improvement of twice. Whether or not it is supported depends on the NIC and possible drivers. Some NICs can be automatically negotiated, some require driver support, and others require you to set options in the NIC's EEPROM configuration. Only serious users will notice the difference between full duplex and half duplex.
  
Linux Ethernet card on SMP machine
  
If you have money to buy a multi-processor (MP) computer, you 'd better buy an Ethernet card. This is not a problem for v2.0 kernel, but it is a problem for v2.2. Most old-fashioned non-intelligent NICs (such as the PIO and shared memory design of the ISA bus) did not consider multi-processor applications at all. Simply put, it is to buy a smart network card of modern design and identify a driver capable of processing multi-processor operations. (Note that here the "modern design"-PCI-NE2000 is an old-fashioned design with over 10 years of history on the modern bus .) Searching for the spin_lock in the driver source code can be a good example of whether the driver can process multi-processor operations. The following explains in detail why you want to purchase a NIC for a multi-processor application (and what will happen if you don't buy it ).
  
In the v2.0 kernel, only one processor is allowed to enter the "kernel state" at any time (that is, to change the kernel data or run the device driver ). Therefore, from the perspective of NICs (and related drivers), this is no different from single-processor operations, so there will be no problems. (This is also the simplest way to get a working Linux multi-processor version-use a large lock to make only one processor in the kernel state at a time. In this way, you will not be able to have two processors simultaneously modifying the same data !)
  
At any time, only one processor is allowed to enter the kernel state. The disadvantage is that only self-control and intensive computing programs can gain the superiority of multi-processor. If the program performs a large number of I/O operations, such as reading/writing data to a disk or network, when the processor in the kernel tries to run all the device drivers to meet I/O requests, other processors must wait until their I/O requests are processed. In this way, the kernel becomes a bottleneck because only one processor runs in the kernel state, the performance of a multi-processor machine quickly degrades to a level close to that of a single processor when I/O tasks are heavy and single locks.
  
Obviously, this is too far from the ideal situation (especially for files/WWW servers, routers, etc ), v2.2 uses a smaller-granularity lock-that is, multiple processors can enter the kernel at the same time. Instead of using a large lock for the entire kernel, it uses many smaller locks to protect key data and prevent being controlled by multiple processors at the same time. for example, a single processor can run the NIC driver, at the same time, another processor can run the Drive program of the disk drive.
  
Okay, so there is a problem: a smaller lock means a processor can try to send data through the Ethernet driver, at the same time, another processor tries to access the same driver/Nic to do other things (for example, get NIC statistics through cat/proc/net/dev ). Alas -- your network adapter is sending data through the network cable, and you need to use it to collect data again. The NIC may be confused when two or more tasks are required at the same time, so the NIC may cause your machine to crash during processing.
  
Therefore, a driver written for a single processor is no longer applicable-it needs to update the control lock for Nic access, this serializes the tasks of receiving, sending, and configuring data of the network adapter to the extent required by the stable operations of the network adapter. A driver without a lock updated to use a stable multi-processor operation may seem to work properly under light network loads, but in two (or more) when the processor tries to execute multiple tasks at the same time, it will cause a crash or at least show strange behavior. this is the problem.
  
After the update, it is realized that the multi-processor Ethernet driver will require a driver-range lock, so that the access entry of the kernel into the driver is limited to one at a time. In this way, the task is serialized, and the hardware processing is the same as that under a single processor, it must be stable. The disadvantage of using a driver-range lock is that it is similar to the impact on the performance of the entire kernel lock (but smaller)-that is, only one processor can process the NIC at a time. [Technical tips: If the added lock is of the irqsave type and is held for a long time, the impact on performance also includes increased interruption Latency.]
  
Two improvements can be made here. You can try to reduce the time used to obtain and release the lock, or implement more detailed locks within the driver (for example, to meet the needs of the NIC, replace the lock of the entire driver with several locks that protect access to several sensitive registers or settings at the same time ).
  
However, for older non-intelligent NICs, the application of excessive processors is not considered during design, and such improvements may not be implemented. Worse, non-intelligent NICs generally require the processor to transmit data between the NIC and the memory. Therefore, in the worst case, the lock is maintained whenever KB data packets are transmitted on the ISA bus.
  
Modern smart NICs can directly transmit network data between NICs and memory without the help of processors. This is a major improvement, because you only need to hold the lock during the short period when the processor notifies the NIC which memory is used to save the next network packet. The design of modern NICs also does not require a large lock for the entire driver.
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.