Difference between mainline Linux kernel and beaglebone black Linux kernel [closed]
Closed 4 hours ago.
Custom Linux kernel compilation issue [closed]
Closed 4 days ago.
What is the priority of KERN_EMERG macro?
In my code i wrote two printk statements with KERN_EMERG and KERN_ALERT macros respectively. But when i insmod it only the printk with KERN_ALERT is processed.Then if i rmmod it then it gets processed along with the bye kernel message ?
hooking syscall by modifying sys_call_table
I’m trying to do basic hooking by locating sys_call_table
and modify an entry for sys_read
syscall to a function in my own kernel module. I have tried kprobes I’m just interested to do it with sys_call_table
.
bad address when I use copy_to_user() in Loadable kernel module
When I am programming a loadable kernel module in Linux, I added a system call that traverses processes and stores them in a structure, then uses copy_to_user() to copy the structure from kernel space to user space. However, I encountered an error during the copy_to_user() process.
this is my struct:
Will ip_route_input return EHOSTUNREACH?
Recently I was learning about Linux bridge, and I found that the br_nf_pre_routing_finish
function will call the ip_route_input function and determine whether the return value of ip_route_input
is equal to EHOSTUNREACH
. But I further found that ip_route_input
does not seem to return EHOSTUNREACH
. Can anyone point out whether this is a bug or whether I have missed some points? The linux version is v6.8. https://elixir.bootlin.com/linux/v6.8/source/net/bridge/br_netfilter_hooks.c#L388
Why is /proc/slabinfo readable only by root?
While trying to diagnose a virtual memory issue on a system where I do not have root permission, I came to find that /proc/slabinfo is readable only by root. What is the reason for this. I checked the contents of the file on a system where I do have root privilege and there doesn’t seem to be any information in there that is user related or security related. What would be the harm in having this file world readable?