linux-kernel

Linux Kernel C code to simulate userland writing / setting a value to /proc filesystem file [closed]

孤街浪徒 提交于 2020-08-10 22:55:05
问题 Closed . This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 5 days ago . Improve this question What's the best way to simulate the same thing as a user doing an "echo a > /proc/file" But doing it from the KERNEL (2.6 in my case) even when the ROOT partition is unreachable. As far as I know the /proc file system is created by the kernel and resides in memory so it should

Linux Kernel C code to simulate userland writing / setting a value to /proc filesystem file [closed]

流过昼夜 提交于 2020-08-10 22:53:45
问题 Closed . This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 5 days ago . Improve this question What's the best way to simulate the same thing as a user doing an "echo a > /proc/file" But doing it from the KERNEL (2.6 in my case) even when the ROOT partition is unreachable. As far as I know the /proc file system is created by the kernel and resides in memory so it should

Linux Kernel C code to simulate userland writing / setting a value to /proc filesystem file [closed]

旧城冷巷雨未停 提交于 2020-08-10 22:50:36
问题 Closed . This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 5 days ago . Improve this question What's the best way to simulate the same thing as a user doing an "echo a > /proc/file" But doing it from the KERNEL (2.6 in my case) even when the ROOT partition is unreachable. As far as I know the /proc file system is created by the kernel and resides in memory so it should

how to make i2c-core as module

久未见 提交于 2020-08-10 19:20:21
问题 Hello I have beagleboneblack board and have kernel source code I want to make my i2c work as a module so for that, I have done some changes in .config file # # I2C support # CONFIG_I2C=m and cross compile kernel make dtbs zImage -j8 CROSS_COMPILE=arm-linux-gnueabihf- But after compile successfully, CONFIG_I2C change from 'm' to 'y' how to solve this problem? 来源: https://stackoverflow.com/questions/62752609/how-to-make-i2c-core-as-module

Android 10: Update kernel modules

最后都变了- 提交于 2020-08-09 08:53:12
问题 This bounty has ended . Answers to this question are eligible for a +50 reputation bounty. Bounty grace period ends in 12 hours . onetyone wants to draw more attention to this question. Background: I am working with a Pixel 4, build QQ2A.200501.001.B2 , which is Android 10. When I build the kernel from the official sources and flash it, the touchscreen, wlan and other features do not work. I tracked this down to the fact that the kernel modules in /vendor/lib/modules do not get updated, thus

Event notification from kernel space to user space

谁都会走 提交于 2020-08-07 20:10:57
问题 How to notify the user space application whenever an event occurs in the kernel space? A hardware generates an interrupt when the data arrives at some GPIO. This data is copied to the kernel buffer. At this point, I want the driver to notify the application that it can call read function to copy the data form kernel buffer to user space buffer. I thought of using epoll method, but epoll indicates whether the device is ready to be read from. What I want is that, epoll to indicate whenever

How to choose between “sys' and ”proc" files in linux kernel

此生再无相见时 提交于 2020-08-02 07:33:20
问题 As per my knowledge, In Linux file system, for information communication between user space and kernel space, two kind of virtual file systems are used. 1) Proc file system http://www.tldp.org/LDP/Linux-Filesystem-Hierarchy/html/proc.html 2) sysfs file system https://en.wikipedia.org/wiki/Sysfs In linux kernel code, i see some sub system has used proc file to perform such userspace-kernelspace communication, and some system has used sysfs files for same concern. So i just want to know, if i

Enlarge Linux Kernel Log Buffer more that 2M

孤街醉人 提交于 2020-07-28 16:53:16
问题 I am in the process of collecting some sort of Linux Kernel activities. I have placed multiple printk statements with in the kernel source code and would like to monitor those during regular kernel activities. Unfortunately, I have realized that the Kernel Log Buffer size ( CONFIG_LOG_BUF_SHIFT ) cannot be more that 2^21 which is essentially equal to 2M entries. Is there any other way to record more than 2M Kernel messages ? 回答1: You can set the kernel log buffer to log_buf_len=4M in your

Enlarge Linux Kernel Log Buffer more that 2M

放肆的年华 提交于 2020-07-28 16:51:57
问题 I am in the process of collecting some sort of Linux Kernel activities. I have placed multiple printk statements with in the kernel source code and would like to monitor those during regular kernel activities. Unfortunately, I have realized that the Kernel Log Buffer size ( CONFIG_LOG_BUF_SHIFT ) cannot be more that 2^21 which is essentially equal to 2M entries. Is there any other way to record more than 2M Kernel messages ? 回答1: You can set the kernel log buffer to log_buf_len=4M in your

what is __clk_of_table symbol in of_clk_init of linux kernel

戏子无情 提交于 2020-07-22 21:36:50
问题 I was going through linux kernel 3.10, which has a function of_clk_init which is as below void __init of_clk_init(const struct of_device_id *matches) { struct device_node *np; if (!matches) matches = __clk_of_table; for_each_matching_node(np, matches) { const struct of_device_id *match = of_match_node(matches, np); of_clk_init_cb_t clk_init_cb = match->data; clk_init_cb(np); } } when i look for the symbol __clk_of_table i did not find any reference but i am very sure that __clk_of_table has