Confused about which branch to patch against

Leon Romanovsky leon at kernel.org
Sun Sep 27 02:27:25 EDT 2020


On Tue, Sep 22, 2020 at 09:39:41PM -0500, Gustavo A. R. Silva wrote:
> Hi,
>
> On 9/22/20 21:08, James Browning wrote:
> > Hi all,
> >
> > After reading through the kernel documentation about submitting pathces,
> > and reading through the kernel newbies guide to submitting patches, I
> > still have some confusion.
> >
> > Should I be doing all of my patching against linux-next as opposed to
> > the mainline tree? I tried submitting a patch to some typos I found on
> > the mainline tree, but they were rejected because they had already been
> > fixed in linux-next.
>
> Yes; bleeding edge development happens in linux-next. Just notice that
> there is a new linux-next everyday. This is, linux-next is merely a daily
> merge of all the individual development '-next' trees.
>
> Don't get discouraged if your patches are not applied because someone
> else already sent a patch to fix the same issue. That certainly happens
> every now and then.
>
> I suggest you to start your journey by addressing issues in staging, first.
> Especially, typos and coding style issues. Also, this is a great resource:
>
> https://kernelnewbies.org/Outreachyfirstpatch
>
> Read it thoroughly. :)
>
> > I guess I dont really understand what patches become part of the next
> > mainline rc-x tree, and which patches become part of linux-next (which
> > from what I understand, doesn't get merged until the next merge window when the current kernel version is finished being stabalized).
>
> I encourage you to enroll in this course:
>
> https://training.linuxfoundation.org/training/a-beginners-guide-to-linux-kernel-development-lfd103/
>
> It's free and there is a section in the beginning that explains all
> about the differences between mainline, -rc, linux-next and stable
> trees and how they relate to each other.
>
> > Also, if I patch something in the linux-next tree, do I need to specify
> > which tree it is when I send the patch the maintainers?
>
> Not necessarily. However, some people explicitly ask you to add 'next' to the
> subject line. The networking people, in particular.
>
> In any case, you'll be safe by adding [next] to the subject line, as follows:
>
> [PATCH][next] subject

IMHO it looks clumsy, why don't [PATCH -next]?

>
> and the maintainers will know that's for their -next tree. Just make sure you
> CC all the file maintainers.
>
> I hope this helps.
>
> --
> Gustavo
>
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies



More information about the Kernelnewbies mailing list