I’am currently trying to develop a Linux driver to use a custom module developed in FPGA. For that, I use a Xilinx Zynq SoC with a Linux distribution that runs on the 2 ARM cores and my VHDL modules are implemented on the FPGA part, but this is not really important to understand my problem. My FPGA modu…
Tag: kernel
Which system calls are not interrupted by a signal?
AFAIK, most of the system calls on linux/unix are interrupted when a signal is received. According to the blog post below, there are some system calls that are not interrupted: In general function that return immediately (don’t wait for any I/O operation to complete or sleep) are not interruptible like …
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 …
Does the qstr struct in a kernel dentry hold the filename of a Linux file?
Below is a snippet of the Linux dentry struct from http://lxr.free-electrons.com/source/include/linux/dcache.h#L150. The struct contains a member struct qstr d_name – definition below. I would like to know if this is the name of the particular file that would correspond to this dentry at runtime. What c…
Linux kernel programming: implicit declaration of function ‘vmalloc’
I am adding system call to Linux kernel 6.22. Then when i make the kernel.It shows the warning:implicit declaration of function ‘vmalloc’.So,what am i gonna do now? Answer You should definitely: #include <linux/vmalloc.h> as it will fix your warning.
Linux Kernel – What does it mean to “put” an inode?
I saw the following comment atop the iput function: To me that sounds like it’s not “putting” anything, but “dropping” it. I’m aware of the drop_inode function, which gets called from iput in some cases, so the usage of the term “put” is even more confusing here…
modify the kernel version information in the menuconfig
I downloaded the kernel source and by typing the following command I can see the linux kernel version is 3.02.02 for example. However, due to some reasons, I have to change it to say… 3.01.01-12-generic I found the appending option in the menuconfig but this does not meet my need. Please let me know if …
sys_ functions in syscalls.h are undefined
I’m just making a kernel module. And I meet this warnings: How can I fix this problem? This is my codes: And my workspace is Ubuntu 3.13.0-66-generic. I need to use file descriptor. So, I can’t use filp_ functions(like filp_open). Edit1: My Makefile: obj-m += NAME.o Answer Calling system calls(sys…
How to Obtain Youngest Child’s PID from task_struct
I’m working on a project that involves writing a new system call for Linux 3.18.20. This system call is supposed to store various information about the currently running process in a newly defined struct. One of the fields of the struct is the PID of the process’s youngest child, and I’ve be…
make: Nothing to be done for `all’. when i tried to compile
this is the code of my make file AND I HAVE FEW QUESTIONS we save C language file with extension *.c so for Makefile which extension should we use? When i throw command in terminal “make” it gives me error that make: Nothing to be done for `all’. Answer Probably the file all already exists. …