Quantcast
Channel: Active questions tagged linux-kernel - Stack Overflow
Browsing all 12241 articles
Browse latest View live

How to get list of deprecated kernel functions for different kernel versions?

While compiling an external linux kernel module for a 5.0 kernel version (x64 module on native x64 system) with deprecated function 'timespec_sub' (was compileable at least until kernel version 4.15)...

View Article


userfaultfd seems slow - is it expected?

When I first learned about usefaultfd my initial reaction was - wow, finally! - this is a very useful feature, I can see some interesting applications of it outside of QEMU/KVM kind of scenarios.So, I...

View Article


How does the page table of the page fault handler is loaded into the MMU?

Can someone please explain to me how does the page fault handler's page table is loaded into the MMU ?Lets consider that a process A is being executed which page table has currently been loaded into...

View Article

Permission denied on Nova Server

I am using a Linux based server as portal for my assignments at UMUC called Nova. In order to access this portal, i am prompted to enter my UMUC credentials. After my password is entered, I receive...

View Article

How to write dummy ALSA compliant device driver?

I want to write dummy ALSA compliant driver as a loadable kernel module. When accessing it by aplay/arecord throught the ALSA-lib, let's say, it must behave as normal 7.1 channel audio device providing...

View Article


How to know which core that send the inter-processor interrupt?

I am working on ARM64. I add an inter-processor interrupt (IPI) handler in void handle_IPI(int ipinr, struct pt_regs *regs) in linux/arch/arm64/kernel/smp.c.When I get an IPI, I want to know which core...

View Article

When will getsockname() set ENOBUFS?

When will getsockname() set ENOBUFS?The manual says getsockname() can set errno to ENOBUFS, but I have checked the related source code inside kernel(3.10, 4.9,...

View Article

What are the most common busmaster operations, and how are they better than...

Can someone list the most common operations that use the bus mastering provision of the host bus? I can list a few..1) The GPU transfers the overall framebuffer to the video card using bus-mastering...

View Article


'Bad page state' kernel error appearing randomly on azure vm when SAS is running

Since a few months, we start seeing Bad page state errors appearing in /var/log/message.Here is the exact stack traceSep 27 15:14:11 az-prod-sas1 kernel: BUG: Bad page state in process sas pfn:1a49ff...

View Article


How to know linux scheduler time slice?

I'm looking for the value of the time slice (or quantum) of my Linux kernel. Is there a /proc file which expose such an information ?(Or) Is it well-defined in the Linux header of my distributions...

View Article

Inconsistent values of ARM PMU cycles counter

I'm trying to measure performance of my code in linux kernel with pmu. First of all I want to test pmu therefore created simple loop of couple operations in kernel. I placed it under spin lock with...

View Article

Why can moving the mutex_unlock() after dev_kfree_skb() eliminate the...

Recently, I find a paper named "Effective Static Analysis of Concurrency Use-After-Free Bugs in Linux Device Drivers". It uses a motivating example (it is also a kernel patch:...

View Article

If I do not acquire a spinlock in a softirq, is it then alright to sleep?

If I do not acquire a spinlock in softirq context, is it then alright to sleep?I understand that it is incorrect to sleep after acquiring a spinlock. The process put to sleep might wake up on another...

View Article


Linux kernel thread address space

I read that linux kernel threads don't have their own address space, their mm field is set to NULL. I know that all kernel threads share address space, but still, they have their own stack right? They...

View Article

What is TCP socket status 8A, as shown in /proc/net/tcp?

I'm trying to interpret the status ('st') column of output from /proc/net/tcp, and I'm seeing unexpected values.I've seen previous questions like List of possible internal socket statuses from /proc....

View Article


Which process runs first when a fork() is called

I wrote this programmain() { int pid; pid=fork(); if(pid==0) printf("\nI am child\n"); else printf("\nI am parent\n"); return 0; } Whose output when executed is ./a.out I am parent I am child When I...

View Article

current->mm gives NULL in linux kernel

I would like to walk the page table, so I have accessed the current->mm, but it gives NULL value.I'm working on linux kernel 3.9 and I don't understand how could current->mm is zero.Is there...

View Article


Calling user-space program functions from kernel modules [duplicate]

This question is an exact duplicate of:How can I Execute/Call a user-space defined function from Linux kernel space module? 2 answersFirst of all, I am working on an embedded board which I want to take...

View Article

What is "the kernel address space"?

From Understanding The Linux Kernel, here is some discussion about kernel thread vs user process i.e. regular process:Besides user processes, Unix systems include a few privileged processes called...

View Article

what's the execution order of multiple child processes

use the follwing code to fork four chile processes#define _GNU_SOURCE #include <stdio.h> #include <unistd.h> #include <sys/wait.h> #include <stdlib.h> pid_t pid; int child(int...

View Article
Browsing all 12241 articles
Browse latest View live