I understand that the linux kernel uses a driver to communicate with the hard disk device and that there is firmware code on the device to service the driver’s requests. My questions are: what kind of functionality (i.e. api) does the firmware expose? For example, does it only expose an address space that the kernel manages, or is there some
Tag: driver
Docker container: lsmod not found
How can I get lsmod and modprobe installed in Ubuntu 14 that is running on Docker? I need to install a device driver in the container, but first I need these commands. (The docker image is originally from docker hub, from a tomcat:7 image). Answer Based on comment from @lan-Abbott. Problem is solved.
Linux NIC driver: what’s the UDP packet from 0.0.0.0 to 255.255.255.255?
I am playing with rhel6 and rhel 7 NIC driver. The interesting thing is, when I do “ifup eth0” (eth0 is the NIC associated with my driver), I found Linux will try to send two special UDP packets, with source address of 0.0.0.0 and destination address of 255.255.255.255. Can someone help me to understand what’s the purpose of those UDP
Linux input driver not working properly
I have written a small linux input driver which reads the state of a gpio. The driver registers OK and also the interrupt gets fired, however the events are not always displayed. Driver runs on Beagleboneblack with Android and kernel version 3.8.13 To test it I do either: cat /dev/input/event2 Or run an user space app that I wrote. The
Implementing poll in a Linux kernel module
I have a simple character device driver that allows you to read from a custom hardware device. It uses a DMA to copy data from the device’s memory into kernel space (and then up to the user). The read call is very simple. It starts a DMA write, and then waits on a wait queue. When the DMA completes, the
Accessing memory pointers in hardware registers
I’m working on enhancing the stock ahci driver provided in Linux in order to perform some needed tasks. I’m at the point of attempting to issue commands to the AHCI HBA for the hard drive to process. However, whenever I do so, my system locks up and reboots. Trying to explain the process of issuing a command to an AHCI
How to achieve accurate timer in linux kernel
When i write a infrared remote control driver, I have to control delay accurate time during enabling and disabling PWM. At first i used udelay() function in kernel, but i found it’s not accurate at all as i said in another post AFAIK, other timeout functions provided by kernel can’t provide accurate time because of scheduler, when timeout, kernel still
How to add poll function to the kernel module code?
As I know, to inform the user space from kernel space, one way is to using poll. That means kernel driver should provide poll method first. Below code is found from internet, and it really works! I can do like this to make it work: And then to see the result. But how to add poll method to it? I
linux kernel module: kernel method undefined (kthread_create_on_cpu)
The method is defined in kthread.c file and prototyped in kthread.h. But it is not exported. In my driver I want to start a kthread on a given CPU, so I do: I can compile but I get linkage error on resolving module symbols on MODPOST: How should I proceed? How to import this symbol or what to do instead?
Bulk message transfer USB Linux
I am at the very beginning to write my own Linux Driver for a dds generator. I want to write 2 bulk messgages to the generator when der Kernel call the probe function. But I dont know how to call the usb_bulk_msg function. I hope you could me. hsync Answer Kernel is kinda self-explanatory project, so usually you can find