Patches

Clone kernel

A good rule of thumb is to start by cloning the mainline branch:

git clone https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git

Configure git

Setting up email client

Use git send-email for sending patches. In your ~/.gitconfig add the following information:

[sendemail]
    smtpuser = <your_email>@gmail.com
    smtpserver = smtp.googlemail.com
    smtpencryption = tls
    smtpserver = 587

Make sure to change <your_email> with your actual email. More information on how to configure the application password on the Gmail documentation.

Make fixes to sources

Create commit message

git commit

Create patch

git format-patch HEAD -1

Before sending the patch, you first have to make sure it complies with the kernel development guidelines using:

./scripts/checkpatch.pl <patch_name>

Send patch through email

A more detailed tutorial can be found here.


This site uses Just the Docs, a documentation theme for Jekyll.