Relationship between Linux device drivers and the entire hardware system

Source: Internet
Author: User

Relationship between Linux device drivers and the entire hardware system 1. Device Classification and features the hardware of a computer system consists of CPU, memory, and peripherals. With the development of the IC (Integrated circuit) manufacturing process, the integration of chips is getting higher and higher, and memory and peripheral adapters are often Integrated into the CPU. The driver targets memory and peripherals (including memory and peripherals integrated within the CPU), rather than CPU cores. 1.1 device categories and features Linux classifies memory and peripherals into three basic categories: character devices: devices that must be accessed in serial order. Does not pass through the system's quick cache. Block devices: they can be accessed in any order. It is cached quickly by the system. Network Device: it is designed for receiving and sending data packets and does not correspond to nodes in the file system. The communication between the kernel and network devices is completely different from that between the kernel and character devices and Block devices. However, character devices and Block devices do not have obvious boundaries. For example, for Flash devices, they comply with the characteristics of Block devices, but we can still access them as a character device. 2. Relationship between Linux device drivers and the entire software and hardware 1 shows that, except for network devices, character devices and Block devices are mapped to the files and directories of the Linux File System, you can access character devices and Block devices by calling open (), write (), read (), and close () interfaces of the file system. All character devices and Block devices are uniformly presented to users. A block device is more complex than a character device. A disk or Flash file system is first created on it, which defines the organization of files and directories on the storage media ). Applications use the Linux system to call interface programming, but can also use library C functions. C functions are recommended for the purpose of code portability. Figure 1:

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: 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.