Questions tagged [drivers]

A device driver or software driver is a computer program allowing higher-level computer programs to interact with a hardware device.

2212 questions
112
votes
3 answers

What is difference between User space and Kernel space?

Is Kernel space used when Kernel is executing on the behalf of the user program i.e. System Call? Or is it the address space for all the Kernel threads (for example scheduler)? If it is the first one, than does it mean that normal user program…
Poojan
  • 1,231
  • 2
  • 9
  • 6
92
votes
6 answers

What is the difference between kernel drivers and kernel modules?

When I do a lspci -k on my Kubuntu with a 3.2.0-29-generic kernel I can see something like this: 01:00.0 VGA compatible controller: NVIDIA Corporation G86 [Quadro NVS 290] (rev a1) Subsystem: NVIDIA Corporation Device 0492 Kernel driver in…
JohnnyFromBF
  • 3,476
  • 10
  • 32
  • 42
73
votes
4 answers

How to find the driver (module) associated with a device on Linux?

On Linux, given: a device, for example /dev/sda, and its major and minor numbers, for example 8, 0, how can I know which module / driver is "driving" it? Can I dig into /sys or /proc to discover that?
Totor
  • 19,302
  • 17
  • 75
  • 102
73
votes
7 answers

Bluetooth won't turn On on Ubuntu 20.04

I recently installed ubuntu 20.04 and bluetooth seemed to work out-of-the-box. Yesterday, it stopped working with no known reason. I can turn it ON but the settings still show it to be OFF. I tried the following: $ sudo -i $ rfkill list 0: phy0:…
Pe Dro
  • 1,399
  • 1
  • 7
  • 14
72
votes
12 answers

What's the philosophy behind delaying writing data to disk?

In Linux, a finished execution of a command such as cp or dd doesn't mean that the data has been written to the device. One has to, for example, call sync, or invoke the "Safely Remove" or "Eject" function on the drive. What's the philosophy behind…
marmistrz
  • 2,732
  • 4
  • 23
  • 30
68
votes
9 answers

How to close X Server, to avoid errors while updating nVidia driver?

I tried to update my nVidia driver but I got an error when I ran the driver installation. See the error: ERROR: You appear to be running an X server; please exit X before installing. For further details, please see the…
Rev3rse
  • 941
  • 2
  • 8
  • 6
59
votes
3 answers

Does the kernel have a main() function?

I am learning device drivers and Kernel programming. According to Jonathan Corbet's book, there is no main() function in device drivers. So I two questions: Why don't we need a main() function in device drivers? Does the kernel itself have a main()…
someone
  • 693
  • 1
  • 7
  • 12
52
votes
4 answers

Find out which modules are associated with a usb device?

Could you recommend a way to figure out which driver is being used for a USB device. Sort of a usb equivalent of lspci -k command.
TheMeaningfulEngineer
  • 5,735
  • 15
  • 64
  • 113
44
votes
2 answers

What is the difference between ioctl(), unlocked_ioctl() and compat_ioctl()?

Going through the linux 2.6.36 source code at lxr.linux.no, I could not find the ioctl() method in file_operations. Instead I found two new calls: unlocked_ioctl() and compat_ioctl(). What is the difference between ioctl(), unlocked_ioctl(), and…
Navaneeth Sen
  • 9,369
  • 17
  • 58
  • 65
34
votes
3 answers

How to find out which Wi-Fi driver is installed?

I know about lsmod, but how do I figure out which driver does what?
apoorv020
  • 1,243
  • 3
  • 13
  • 19
34
votes
1 answer

How to assign USB driver to device

This question is two-fold: First, how do you manually detach a driver from a USB device and attach a different one? For example, I have a device that when connected automatically uses the usb-storage driver. usbview output Vendor Id: xxxx Product…
linsek
  • 450
  • 1
  • 6
  • 12
34
votes
7 answers

Is USB-to-USB data transfer between two Linux OSes possible?

I want to create a USB-to-USB data transfer system in Linux (preferably Ubuntu). For this I want to use no external hardware or switch (except this cable). It's going to be like mounting a USB drive to a system, but in this scenario one of the Linux…
the_Strider
  • 485
  • 1
  • 6
  • 10
33
votes
5 answers

How do character device or character special files work?

I am trying to understand character special files. From wikipedia, I understand that these files "provide an interface" for devices that transmit data one character at a time. My understanding is that the system somehow calls the character device…
bernie2436
  • 6,505
  • 22
  • 58
  • 69
32
votes
2 answers

What’s the difference between a “raw” and a “cooked” device driver?

Does this concept only apply to terminal drivers (which is what most sites cover) or to any driver in general?
soc
  • 430
  • 1
  • 4
  • 9
32
votes
1 answer

How to use Linux kernel driver bind/unbind interface for USB-HID devices?

First background. I am developing a driver for Logitech game-panel devices. It's a keyboard with a screen on it. The driver is working nicely but by default the device is handled by HID. In order to prevent HID taking over the device before my…
ali1234
  • 1,044
  • 2
  • 11
  • 20
1
2 3
99 100