Interview Questions

LDD - Char Device Driver

Linux Device Driver - Interview Questions

LDD - Char Device Driver

Linux Char Device Driver Interview Questions

  • How can we Free Device Numbers ?
  • What is use of dev_t type ?
  • What is the disadvantage of dynamic device number assignment ?
  • Where can we write allocation and freeing of device number's code ?
  • How can i use my own major and minor number for a device file ?
  • How to see statically assigned major numbers ?
  • What will happen/can u have printf/printk inside an interrrupt hancler (i think he wanted me to say no.. but I did not know the reason)
  • How can we allocate device number statically , dynamically?
  • What is mknod and it's usage ?
  • How to retrieve major and minor number from dev_t type ?
  • What is use of dev_t type ?
  • What is the functionality of PROBE function
  • How to detect whether a device is not detected?
  • Where your driver will be in kernel
  • Which type of address (virtual or physical) is used in function iowrite32?
  • What is the type of driver char or n/w or block driver you developed?
  • How to register a CHAR driver to kernel?
  • How to load a dynamic driver or static driver?
  • How to develop a device driver for a hard device?
  • IOCTL implementation programs
  • Where will be your driver file will be located
  • What is the entry point of your driver
  • What are the ways in which linux kernel can be compiled ?
  • How will get the driver added into the kernel ? What are Kconfig files ?
  • What is a kernel module ?
  • What is the difference between insmod and modprobe ?
  • How will you list the modules ?
  • How do you get the list of currently available drivers ?
  • How will you Access userspace memory from kernel ? What are the various methods ?
  • What is the use of ioctl(inode,file,cmd,arg) ApI ?
  • What is the use of the poll(file, polltable) API ?
  • What is the use of file->private_data in a device driver structure ?
  • What is a device number ?
  • What are the two types of devices drivers from VFS point of view ?
  • What are character devices ?
  • How does the character device driver adds and remove itself from the kernel ?
  • What is the use of register_chrdev and unregister_chrdev ?


If you have any queries please email us at info@motionzen.com