0% found this document useful (0 votes)
76 views1 page

Document Udev

Udev is a device manager for the Linux kernel that manages device nodes in /dev. When a device is created or removed, the kernel sends a uevent to udev. Udev then reads sysfs to determine attributes of the device, maintains a database of devices, and creates or deletes the appropriate device file based on the event. Udev relies on kernel hotplug notifications and the global namespace to dynamically handle new devices or removals.

Uploaded by

thenral007
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
76 views1 page

Document Udev

Udev is a device manager for the Linux kernel that manages device nodes in /dev. When a device is created or removed, the kernel sends a uevent to udev. Udev then reads sysfs to determine attributes of the device, maintains a database of devices, and creates or deletes the appropriate device file based on the event. Udev relies on kernel hotplug notifications and the global namespace to dynamically handle new devices or removals.

Uploaded by

thenral007
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 1

Udev:

• Udev is the device manager for the Linux 2.6 kernel series, Primarily, it manages
device nodes in /dev.

• On device creation, udev reads the sysfs directory of the given device to collect
device attributes like label, serial number or bus device number. These attributes
may be used as keys to determine a unique name for the device. udev maintains a
database for devices present on the system.
On device removal, udev queries its database for the name of the device file to be
deleted.

• Udev relies on the kernel hot plug mechanism to create device files in user space.
Udev is a generic kernel device manager. It runs as a daemon on a Linux system
and listens to uevents the kernel sends out (via netlink socket) if a new device is
initialized or a device is removed from the system.

• In response to the interrupt, the kernel ascertains the details of the newly-added
device, either by using a specific protocol to query the hardware controller or by
searching at hard-coded addresses – such as the PCI card configuration area – for
information stored there, more specifically, for the vendor and product IDs.

• The kernel then goes on to create a KObject for each new device; data on the
device type (char or block) and the major and minor numbers are passed to and
stored by the KObject via the global kernel component namespace introduced in
kernel 2.6.

• Udev uses this approach both when devices are added to a running system (hot
plugging) and for initialization during the boot phase (cold plugging). The kernel
searches the buses for devices and creates uevent files based on the results.

• All major and minor numbers are assigned a name that matches up with a type of
Device. This allocation is done by The Linux Assigned Names And Numbers
Authority(LANANA).

By
Thenralarasan M

You might also like