1) Enter the source code website
https://www.kernel.org/
The page is as follows:
2) The GIT address of the main line, when the point mainline behind the "Browse", as follows:
Click on the Penguin to the right of the index:kernel/git/torvalds/linux.git, you can find the main source git address
The following (all three are the same code, the server is different):
- Git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
- Https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
- Https://kernel.googlesource.com/pub/scm/linux/kernel/git/torvalds/linux.git
3) Stable version of the kernel source code, when entering the home page, stable or longterm after the point "browse" can be, specifically ibid.
Stable version of the kernel source git address is as follows:
- Git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git
- Https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git
- Https://kernel.googlesource.com/pub/scm/linux/kernel/git/stable/linux-stable.git
4) After downloading the source code, always update
Go to the source directory and execute the following command to update to the latest kernel
$ git pull
Use git to download Linux source code