Top "Linux-device-driver" questions

Device drivers take on a special role in the Linux kernel.

mmap: mapping in user space a kernel buffer allocated with kmalloc

Which is the correct way to map in an user space process a buffer allocated with kmalloc? Maybe i didn't …

linux linux-kernel linux-device-driver mmap
How to call compat_ioctl or unlocked_ioctl?

I'm trying to implement a driver for RTC (Real Time Clock). I used ioctl function in kernel 2.6.32. It worked fine. …

linux-device-driver ioctl
Linux kernel interrupt handler mutex protection?

Do I need to protect my interrupt handler being called many times for the same interrupt? Given the following code, …

linux linux-kernel linux-device-driver interrupt
Can someone help me replace "lock_kernel" on a block device driver?

Thank you for looking at this post. I am trying to patch up a network block device driver. If you …

linux-kernel linux-device-driver ioctl
How to read extended PCIE configuration space in Linux?

I've tried both reading userspace pci entry under /proc/bus/pci directory and calling kernel space API pci_read_config_…

linux linux-kernel linux-device-driver pci
kernel module cannot find firmware file on Android device; where should it be?

I am having trouble placing firmware properly on an Android device, I keep getting: <3>[ 3590.997375] usb 3-1.4: ath9k_…

android linux-kernel linux-device-driver firmware
Why do we need to call poll_wait in poll?

In LDD3, i saw such codes static unsigned int scull_p_poll(struct file *filp, poll_table *wait) { struct scull_…

linux linux-kernel linux-device-driver system-calls epoll
How to work with reserved CMA memory?

I would like to allocate piece of physically contiguous reserved memory (in predefined physical addresses) for my device with DMA …

memory-management linux-kernel linux-device-driver virtual-memory device-tree
How would one prevent MMAP from caching values?

I've written a linux driver that ioremaps exports PCI BAR0 for a particular device to a sysfs binary attribute allowing …

c linux operating-system linux-device-driver mmap
Accessing a serial port from a linux kernel module

Hello Linux Kernel Driver Gurus! I'm writing a v4l2 driver for a camera that uses a serial interface for …

linux-kernel serial-port linux-device-driver kernel-module