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

How to manage paging in assembly/C kernel?

My project is to execute my own JVM on a little piece of kernel that i'm trying to code in C and assembly. So, I'm still learning how do the kernels do their main jobs.Now, following some guides, I set...

View Article


Python Kernel reboot without errors

Good Night . I have an algorithm that calls an api from a water quality simulator, and with results from that simulator performs an optimization with PSO. I am using Python3 and IDE Spyder, but over...

View Article


Linux freezes after loading and unloading a kernel module

I am attempting to do a kernel module that is meant to check which USB devices are currently connected, and compare them to a list of allowed USB devices. I've written the following code:#include...

View Article

Locking memory on fault

Starting with kernel 4.4 a new way of locking the memory was introduced according to this link.When a particular shared library resides on a block device we know that the kernel will load into memory...

View Article

Creating virtual USB device in Mac OS X

I tried to add virtual usb device with driver in Mac OS programmatically. IOKit documentations says: Traditionally, drivers of virtual devices match on IOResources because virtual devices do not...

View Article


Various kernel queues

As far as I understand, run queue is per CPU. Wait queue is for processes in sleep waiting to be woken up. But I have seen also wake and work queues being mentioned. What are they for and how do they...

View Article

Kernel Error trying to run python code on Jupyter Notebook

I'm having a kernel error when running python 3 on jupyter notebook which runs using anaconda. here is the error output below:Traceback (most recent call last): File...

View Article

Document classification : computing gram matrix

i'm trying to classify text documents as a part of a school project, i'm using the Reuters-21578 Text Categorization Collection Data Set, after obtaining the X data matrix (n_documents , n_features),...

View Article


Does spin_lock_irqsave() block IPI calls?

I am using kdump functionality to generate the kernel crash core file. I created a small kernel module which creates the kernel watchdog crashstatic int watchdog_crash(void *unused) { unsigned long...

View Article


How do I know a spin lock or other locks like mutex or semaphore is already...

In my project, program flow always hangs at one place. When I debugged it, I found a few complex locking mechanisms are used. Kind of spinlock and mutex.How can I identify that number of spin locks or...

View Article

Permission denied when trying to run python code on Jupyter Notebook

I'm having a kernel error when running python 3 on jupyter notebook which runs using anaconda. here is the error output below:Traceback (most recent call last): File...

View Article

How to simulate a tun device through a file descriptor? Which file to open?

I'm writing an app that uses OpenVPN library, which by default reads and writes to a tun device through a file descriptor. I want to create a file descriptor for my app and pass to OpenVPN so it can...

View Article

In Linux, is it possible that all pages belonged to a user-mode process or a...

I am developing a kernel mode module which reads the whole pages that are available in RAM. I am wondering if I get the list of processes and kernel modules from the RAM image I have created, is it...

View Article


Obtain jupyter notebook-like output from InteractiveShell.run_cell() command

I have an object in my local environment, and I'm trying to run code originating from a jupyter notebook. The code needs to access to this object. Below is a mwe. The output of the #(current) method is...

View Article

setsockopt fails while kernel TLS option enabling

Trying to play with in kernel TLS on kernel 5.3 version (Fedora 30 and 31) but stuck even on enabling ULP:// tls.c #include <stdio.h> #include <stdlib.h> #include <string.h> #include...

View Article


Booting a ppc linux kernel in qemu

i am new at this. I am trying to boot a linux kernel image cross compiled for powerpc inside qemu. I followed guides on the web, but i am stuck and i don;t really know what do to next.qemu-system-ppc...

View Article

How does /dev/net/tun works? Do I get back what I write?

Suppose that I want to send and receive data through a tun device. I found the answer https://stackoverflow.com/a/35735842/6655884 where it opens /dev/net/tun as if it were a file and reads from it....

View Article


insmod: can't insert 'NetlinkRtLKM.ko': Out of memory

I have written a kernel module, compiling and insmod-ing it works perfect on my native linux machine running kernel 5.0.0-36-generic (running as VM). Now, I want to compile and run the same kernel...

View Article

Can a pipe (from pipe syscall) have bi-directional communication?

From https://pubs.opengroup.org/onlinepubs/9699919799/functions/pipe.html:Data can be written to the file descriptor fildes[1] and read from the file descriptor fildes[0]. A read on the file descriptor...

View Article

Does UIO generic PCI support interrupts?

I use uio generic driver with HW composed of PCIe device (FPGA) connected to ATOM cpu.But, on testing, although interrupt is seen in the driver, it is not delivered to userspace.These are the steps I'm...

View Article
Browsing all 6503 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>