Malformed entry 2 in list file/etc/apt/sources.list
I am getting following error whenever i am going to update or do anything on my terminal of Linux mint.malformed entry 2 in list file/etc/apt/sources.list.d/additional-repositories.list(suite) the list...
View Articlehow to test a specific algorithm using tcrypt.ko module in linux kernel
I have noticed that there is a test module(tcrypt.c) in linux kernel crypto subsytem. I am able to use this module for any bench marking scenarios like aes with following command "modprobe tcrypt sec=1...
View Articleasmlinkage defined to nothing in linux code
I was looking into asmlinkage tag.From https://kernelnewbies.org/FAQ/asmlinkageThis is a #define for some gcc magic that tells the compiler that the function should not expect to find any of its...
View Articlepurpose of error injection macro in linux kernel
I have seen a macro ALLOW_ERROR_INJECTION which is used in SYSCALL_DEFINEx#ifdef CONFIG_FUNCTION_ERROR_INJECTION /* * Whitelist ganerating macro. Specify functions which can be * error-injectable using...
View ArticleGetting error when compiling kernel for page table walk
I am doing a page table walk. When I am getting ready to update the kernel I get an error:./arch/x86/include/asm/pgtable.h:988:40: warning: right shift count >= width of type...
View Articlewhat'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 ArticleHow can I access or enumerate available LEDs from kernel code (BeagleBone...
I am trying to write a custom syscall handler that manipulates the LEDs on a BeagleBone Black board. I have gone through the kernel LED API (include/leds.h), but I am unable to find anything that'd...
View ArticleHow does a file transfer over the internet work?
As soon as the network card receives a packet that is a response to file request, is it passed on to the memory, or is it passed onto the hard disk directly? I guess, dma-buf and such provisions in the...
View Articleadding i2c client devices on x86_64
On my x86_64 board, there is i2c-bus coming out of a MFD device. There are devices on to this i2c-bus. I am able to detect these devices using i2cdetect program. # i2cdetect -y 0 0 1 2 3 4 5 6 7 8 9 a...
View ArticleWrong Return Value for I2C_SLAVE and I2C_RDWR on Raspberry pi
I am using Raspberry pi for I2C communication to a chip.The I2C Runs on i2c-1 and the chip I want to communicate is mux0 for which the address is specified. I used a wrong address to see what value I...
View Articleundefined reference to `__kmalloc'
While compiling code that uses the SCTP kernel header <sctp/chunk.h>I got a puzzling compiler error(with blue text instead of read) that was trigged by the calling of the kmalloc function whose...
View ArticleWrong Return Value of I2C_SLAVE on Raspberry pi
My device address is 0x70.If I do ioctl(file, I2C_SLAVE, 0x70)); it returns me 0 which is fine. But if I give a wrong address: ioctl(file, I2C_SLAVE, 0x00)); it still returns me a 0 instead of -1.If I...
View ArticleHow to generate network impairments only on udp packets in linux
I'm trying to generate impairments on my linux ubuntu 18.04 and use it as a hotspot to affect a mobile app with those impairments but I need it to affect only the UDP traffic.I'm trying to test my app...
View ArticleUnexpected IOCTL sent to my uclinux (ARM) driver(s)
Having written my character drivers to use .unlocked_ioctl and a user-space app to test them I am getting an unexpected call to the ioctl function when the devices are opened from user-space.The driver...
View ArticleI am working on one project where i have to read temperature from soc...
I am working on one project where I want to read the temperature from userspace for soc temperature sensors. I have register addresses from where I can read the values.I have the following questions....
View ArticleLinux Module Programming fails and caught in loop
OK, So I am programming this for a HW assignment but could either use some help or insight. I know I've read everywhere that you shouldnt open files in modules but its our assignment...Anyway my module...
View ArticleGuide build kubernetes on custom OS [closed]
Context: I have built my own OS linux based, with specific kernel modifications with docker available. Aim: I would like to use this custom OS like a node in k8s, so i have to install k8s on it.Is...
View ArticleUnderstanding pmap output for Linux 5.0 kernel and pmap version 3.3.12
I have pmap output as follows:$ pmap -X `pidof a.out` 6148: ./a.out Address Perm Offset Device Inode Size Rss Pss Referenced Anonymous LazyFree ShmemPmdMapped Shared_Hugetlb Private_Hugetlb Swap...
View ArticleWriting device driver for embedded boards
I am a newbie to embedded world. I am trying to write device drivers on Embedded Linux Systems which built using Yocto project. I don't exactly know how linux drivers work and how to write a new driver...
View ArticleHow to automatically run 'sudo modprobe -r ftdi_sio' whenever the device is...
I have a USB device that I'm using and I'm developing an application using WebUSB with Google Chrome. The thing is whenever I plug the USB device into my Linux computer, I have to manually run 'sudo...
View Article