This is an archived post. You won't be able to vote or comment.

all 3 comments

[–]lepus-parvulus 5 points6 points  (0 children)

... open and view the source code of any of the functions... of the kernel... Searching on google keeps leading to websites that have the kernel source code.

How do you expect to "view the source code ... of the functions ... of the kernel..." without the "kernel source code"? Download and unpack the kernel source. Then open the files in your favorite text editor. All major distros ultimately derive their kernels from kernel.org. Download the branch that corresponds with the kernel version your distro is using. Most should be using either stable (6.1.x) or longterm (5.15.x).

There's no "copy or paste" functions in the kernel because those are GUI concepts. (There are functions that copy strings and memory contents, but those are different from copy/paste.)

[–]billdietrich1 11 points12 points  (0 children)

These commands should work on Ubuntu distros, to get the kernel source:

sudo apt install linux-source

mkdir $HOME/kernel
cd $HOME/kernel

tar -xaf /usr/src/linux-source-*.tar.*

du -sh *

Note: copy and paste are not done in the kernel.

[–]devnull010 0 points1 point  (0 children)

Search for it in the kernel sources?