I need to determine the stack size of a running Linux kernel inside a kernel module. I know that the THREAD_SIZE macro gives the stack size for this architecture, but I cannot use it. Because compilation and launch machines are different. Is there a way to do this through the proc, kernel api, or exported character interface? Thanks
try it
system("getconf _POSIX_THREAD_ATTR_STACKSIZE");
getconf -a list of system variables may be displayed in the console
getconf -a
I think you can find it in thread_info.h of your architecture. Usually the kernel stack is 2 pages (8 KB), but it depends on your configuration.
Source: https://habr.com/ru/post/1434646/More articles:How to manually execute Spring batch job? - javaRegular expression or library for checking built-in XSD types? - javaPython argparse: create timedelta object from argument? - pythonGetProcessImageFileName not binding - c ++Choosing MySQL with multiple orders - mysqlWhy does lessc encode files as UCS-2 Little Endian? - cssAdding different percentages in boxes in R - rHow to implement a validator in Symfony - dependency-injectionNameError: uninitialized constant :: Nokogiri - ruby ββ| fooobar.comError in xcdatamodel - iosAll Articles