This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
en:developers:documentation:git-guide [2016/09/19 13:31] Robert Copeland [Git guide for Linux wireless users and developers] |
en:developers:documentation:git-guide [2024/02/07 19:11] (current) Alexis Lothoré Update git trees to use for contributors |
||
---|---|---|---|
Line 4: | Line 4: | ||
===== Git guide for Linux wireless users and developers ===== | ===== Git guide for Linux wireless users and developers ===== | ||
- | This is a quick git-guide for Linux users and developers with emphasis on Linux wireless. The latest Linux wireless development happens in two trees: mac80211-next maintained by Johannes Berg, and wireless-drivers-next maintained by Kalle Valo. Both trees are regularly pulled into wireless-testing for integration testing; wireless-testing may therefore also be used as a base for development along with the upstream trees. | + | This is a quick git-guide for Linux users and developers with emphasis on Linux wireless. |
- | ===== Cloning latest wireless-testing ===== | + | ===== Git trees in use for wireless patches integration ===== |
- | First, clone the wireless-testing.git tree | + | The wireless maintainers use different git trees depending on the patches target. Contributors are expected to base their work on the relevant tree: |
+ | * [[https://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless-next.git|wireless-next]] must be used for patches bringing new features, either for mac80211/cfg80211 or device drivers. The patches from this tree will eventually land in Linus' tree during each merge window. | ||
+ | * some devices family have their own git tree which should then be preferred over wireless-next, that's for example the case for [[https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git|ath]] or [[https://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-next.git|iwlwifi]] | ||
+ | * urgent patches/fixes must target the [[https://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless.git|wireless]] tree. Those fixes will be sent for "-rc" releases and/or to stable kernels | ||
+ | * for some specific cases, the [[https://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless-testing.git|wireless-testing tree]] can be used. wireless and wireless-next are frequently merged into it to run automated tests | ||
+ | * device firmwares are handled separately and should target [[https://gitlab.com/kernel-firmware/linux-firmware|linux-firmware]] | ||
- | <code>git clone git://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless-testing.git | + | ===== Cloning a development tree ===== |
- | cd wireless-testing</code> | + | |
+ | First, clone the relevant tree, for example wireless-next.git tree | ||
+ | |||
+ | |||
+ | <code>git clone git://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless-next.git | ||
+ | cd wireless-next</code> | ||
+ | |||
+ | If you need to work on multiple trees, you can either clone needed repositories at different paths, or use a multi-remote repository: | ||
+ | |||
+ | <code>git remote add ath https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git | ||
+ | git fetch ath</code> | ||
===== Get the latest updates ===== | ===== Get the latest updates ===== | ||
- | You will want to update your local git repository to match what John has last committed. You can do this as follows. | + | You will want to update your local git repository to match what maintainers has last committed. You can do this as follows. |
Line 196: | Line 211: | ||
Read git-send-email man page. But here is a quick summary for those who just want to get it to work. Keep in mind git send-email is a perl script and is usually shipped separately from git core. | Read git-send-email man page. But here is a quick summary for those who just want to get it to work. Keep in mind git send-email is a perl script and is usually shipped separately from git core. | ||
- | You can install your favorite mailer, one option is to use ssmtp. | + | You can install your favorite mailer, you can directly contact to your SMTP server or alternivately to use ssmtp. |
+ | |||
+ | To set your name and email in git: | ||
+ | |||
+ | <code> | ||
+ | git config --global user.name "Ed Example" | ||
+ | git config --global user.email "ed@example.com"</code> | ||
+ | |||
+ | ==== Using SMTP server directly ==== | ||
+ | |||
+ | Set SMTP settings to git: | ||
+ | <code> | ||
+ | git config --global sendemail.smtpencryption tls | ||
+ | git config --global sendemail.smtpserver mail.example.com | ||
+ | git config --global sendemail.smtpuser ed@example.com | ||
+ | git config --global sendemail.smtpserverport 587 | ||
+ | git config --global sendemail.smtppass myverysecretpassword</code> | ||
- | ==== Setting up ssmtp ==== | + | ==== Setting up ssmtp (optional) ==== |
Below is an example config that works with an exchange server, in etc/ssmtp/ssmtp.conf: | Below is an example config that works with an exchange server, in etc/ssmtp/ssmtp.conf: | ||
Line 224: | Line 255: | ||
Once you have your mailer setup and patches in a directory, review them so they are correct. Once all done send them out using: | Once you have your mailer setup and patches in a directory, review them so they are correct. Once all done send them out using: | ||
+ | <code> | ||
+ | git send-email --to linux-wireless@vger.kernel.org --cc maintainer-of-driver@example.com some-dir/</code> | ||
- | <code># Note new versions of git use: git send-email | + | Where some-dir is where you stashed your patches. Keep in mind that if you are submitting a series it helps to send an introductory PATCH [0/n] as well, where n is the number of patches you want to send. You can add this to the git-send-email queue easily using ''--cover-letter'' when generating patches using git-format-patch. Be sure to edit the patch 0000-foo then. git-send-email will pick it up when you specify the directory :) |
- | git send-email --no-chain-reply-to --from "Random Developer <hacker@company.com>" --to linville@tuxdriver.com --cc linux-wireless@vger.kernel.org --cc maintainer-of-driver@some-cool.org some-dir/</code> | + | |
- | Where some-dir is where you stashed your patches. Keep in mind that if you are submitting a series it helps to send an introductory PATCH [0/n] as well, where n is the number of patches you want to send. You can add this to the git-send-email queue easily using --cover-letter when generating patches using git-format-patch. Be sure to edit the patch 0000-foo then. git-send-email will pick it up when you specify the directory :) | + | |