Lines Matching refs:to

2 	How to Get Your Change Into the Linux Kernel
8 For a person or company who wishes to submit a change to the Linux
16 Documentation/SubmitChecklist for a list of items to check before
22 control system; if you use git to prepare your patches, you'll find much
23 of the mechanical work done for you, though you'll still need to prepare
36 git to obtain one. You'll want to start with the mainline repository,
41 Note, however, that you may not want to develop against the mainline tree
42 directly. Most subsystem maintainers run their own trees and want to see
44 in the MAINTAINERS file to find that tree, or simply ask the maintainer if
47 It is still possible to download kernel releases via tarballs (as described
48 in the next section), but that is the hard way to do kernel development.
54 to create patches. Git generates patches in this form by default; if
57 All changes to the Linux kernel occur in the form of patches, as
58 generated by diff(1). When creating your patch, make sure to create it
59 in "unified diff" format, as supplied by the '-u' argument to diff(1).
61 change is in - that makes the resultant diff a lot easier to read.
65 To create a patch for a single file, it is often sufficient to do:
92 belong in a patch submission. Make sure to review your patch -after-
93 generating it with diff(1), to ensure accuracy.
95 If your changes produce a lot of deltas, you need to split them into
111 motivated you to do this work. Convince the reviewer that there is a
112 problem worth fixing and that it makes sense for them to read past the
129 memory, and readability; or, when it comes to heuristics, between
134 about it in technical detail. It's important to describe the change
135 in plain English for the reviewer to verify that the code is behaving
136 as you intend it to.
142 Solve only one problem per patch. If your description starts to get
143 long, that's a sign that you probably need to split up your patch.
149 subsystem maintainer to refer back to earlier patch versions or referenced
150 URLs to find the patch description and put that into the patch.
157 to do frotz", as if you are giving orders to the codebase to change
160 If the patch fixes a logged bug entry, refer to that bug entry by
162 give a URL to the mailing list archive; use the https://lkml.kernel.org/
163 redirector with a Message-Id, to ensure that the links cannot become
166 However, try to make your explanation understandable without external
167 resources. In addition to giving a URL to a mailing list archive or
168 bug, summarize the relevant points of the discussion that led to the
171 If you want to refer to a specific commit, don't just refer to the
173 the commit, to make it easier for reviewers to know what it is about.
181 You should also be sure to use at least the first twelve characters of the
193 The following git-config settings can be used to add a pretty format for
211 On the other hand, if you make a single change to numerous files,
215 The point to remember is that each patch should make an easily understood
219 If one patch depends on another patch in order for a change to be
223 When dividing your change into a series of patches, take special care to
225 series. Developers using "git bisect" to track down a problem can end up
238 found in Documentation/CodingStyle. Failure to do so simply wastes
242 One significant exception is when moving code from one file to
246 actual differences and allows tools to better track the history of
249 Check your patches with the patch style checker prior to submission
255 - ERROR: things that are very likely to be wrong
259 You should be able to justify all violations that remain in your
267 to code that they maintain; look through the MAINTAINERS file and the
268 source code revision history to see who those maintainers are. The
273 You should also normally choose at least one mailing list to receive a copy
276 to tune it out. Look in the MAINTAINERS file for a subsystem-specific
284 Do not send more than 15 patches at once to the vger mailing lists!!!
289 Linus directly, so typically you should do your best to -avoid-
293 to security@kernel.org. For severe bugs, a short embargo may be considered
294 to allow distributors to get the patch out to users; in such cases,
295 obviously, the patch should not be sent to any public lists.
303 should also read Documentation/stable_kernel_rules.txt in addition to this
306 Note, however, that some subsystem maintainers want to come to their own
307 conclusions on which patches should go to the stable trees. The networking
309 adding lines like the above to their patches.
314 into the manual pages. User-space API changes should also be copied to
317 For small patches you may want to CC the Trivial Patch Monkey
338 Linus and other kernel developers need to be able to read and comment
340 developer to be able to "quote" your changes, using standard e-mail
345 if you choose to cut-n-paste your patch.
349 attachment as plain text, making it impossible to comment on your
350 code. A MIME attachment also takes Linus a bit more time to process,
354 you to re-send them using MIME.
365 server, and provide instead a URL (link) pointing to your patch. But note
366 that if your patch exceeds 300 kB, it almost certainly needs to be broken up
369 8) Respond to review comments.
373 which the patch can be improved. You must respond to those comments;
374 ignoring reviewers is a good way to get ignored in return. Review comments
375 or questions that do not lead to a code change should almost certainly
379 Be sure to tell the reviewers what changes you are making and to thank them
389 busy people and may not get to your patch right away.
391 Once upon a time, patches used to disappear into the void without comment,
394 that you have sent your patches to the right place. Wait for a minimum of
402 Due to high e-mail traffic to Linus, and to linux-kernel, it is common
403 convention to prefix your subject line with [PATCH]. This lets Linus
413 percolate to their final resting place in the kernel through several
418 patch, which certifies that you wrote it or otherwise have the right to
424 By making a contribution to this project, I certify that:
427 have the right to submit it under the open source license
430 (b) The contribution is based upon previous work that, to the best
432 license and I have the right under that license to submit that
435 permitted to submit under a different license), as indicated
438 (c) The contribution was provided directly to me by some other
455 now, but you can do this to mark internal company procedures or just
458 If you are a subsystem or branch maintainer, sometimes you need to slightly
459 modify patches you receive in order to merge them, because the code is not
460 exactly the same in your tree and the submitters'. If you stick strictly to
461 rule (c), you should ask the submitter to rediff, but this is a totally
462 counter-productive waste of time and energy. Rule (b) allows you to adjust
463 the code, but then it is very impolite to change one submitter's code and
468 enclosed in square brackets, is noticeable enough to make it obvious that
472 [lucky@maintainer.example.org: struct foo moved from foo.c to foo.h]
476 want at the same time to credit the author, track changes, merge the fix,
481 Special note to back-porters: It seems to be a common and useful practice
482 to insert an indication of the origin of a patch at the top of the commit
483 message (just after the subject line) to facilitate tracking. For instance,
500 Whatever the format, this information provides a valuable help to people
501 tracking your trees, and to people trying to troubleshoot bugs in your
505 12) When to use Acked-by: and Cc:
512 patch but wishes to signify and record their approval of it then they can
513 ask to have an Acked-by: line added to the patch's changelog.
516 maintainer neither contributed to nor forwarded the patch.
520 mergers will sometimes manually convert an acker's "yep, looks good to me"
521 into an Acked-by: (but note that it is usually better to ask for an
528 When in doubt people should refer to the original discussion in the mailing
531 If a person has had the opportunity to comment on a patch, but has not
532 provided such comments, you may optionally add a "Cc:" tag to the patch.
542 The Reported-by tag gives credit to people who find bugs and report them and it
543 hopefully inspires them to help us again in the future. Please note that if
549 some testing has been performed, provides a means to locate testers for
553 acceptable according to the Reviewer's Statement:
559 (a) I have carried out a technical review of this patch to
563 (b) Any problems, concerns, or questions relating to the patch
564 have been communicated back to the submitter. I am satisfied
565 with the submitter's response to my comments.
569 worthwhile modification to the kernel, and (2) free of known
572 (d) While I have reviewed the patch and believe it to be sound, I
580 offer a Reviewed-by tag for a patch. This tag serves to give credit to
581 reviewers and to inform maintainers of the degree of review which has been
582 done on the patch. Reviewed-by: tags, when supplied by reviewers known to
583 understand the subject area and to perform thorough reviews, will normally
587 named and ensures credit to the person for the idea. Please note that this
590 idea reporters, they will, hopefully, be inspired to help us again in the
594 is used to make it easy to determine where a bug originated, which can help
620 be copied to the permanent changelog to describe this patch.
631 The Subject line format makes it very easy to sort the emails
648 developer discussions which refer to the patch. People will want to
649 google for the "summary phrase" to read discussion regarding that
657 as why the patch might be necessary. It is challenging to be both
665 the multiple versions of the patch have been sent out in response to
666 comments (i.e., "v1, v2, v3"), or "RFC" to indicate a request for
685 then the "From:" line from the email header will be used to determine
688 The explanation body will be committed to the permanent source
689 changelog, so should make sense to a competent reader who has long
691 have led to this patch. Including symptoms of the failure which the
695 it may not be necessary to include _all_ of the compile failures; just
697 it. As in the "summary phrase", it is important to be both succinct as
704 a diffstat, to show what files have changed, and the number of
706 on bigger patches. Other comments relevant only to the moment or the
712 If you are going to include a diffstat after the "---" marker, please
724 It can be helpful to manually add In-Reply-To: headers to a patch
725 (e.g., when using "git send email") to associate the patch with
726 previous relevant discussion, e.g. to link a bug fix to the email with
728 best to avoid using In-Reply-To: to link to older versions of the
732 the cover email text) to link to an earlier version of the patch series.
738 If you have a series of patches, it may be most convenient to have the
742 As a result, many subsystem maintainers are reluctant to take pull
755 to get these changes:
760 The easiest way to get all this information together is, of course, to let
763 Some maintainers (including Linus) want to see pull requests from signed
768 The first step toward creating such tags is to make a GNUPG key and get it
771 be a good way to find developers who can sign your key.
773 Once you have prepared a patch series in git that you wish to have somebody
776 created with your private key. You will also have the opportunity to add a
777 changelog-style message to the tag; this is an ideal place to describe the
781 are working from, don't forget to push the signed tag explicitly to the
800 Greg Kroah-Hartman, "How to piss off a kernel subsystem maintainer".
808 NO!!!! No more huge patch bombs to linux-kernel@vger.kernel.org people!
818 Some strategies to get difficult or controversial changes in.