Kernel Newbies archive on lore.kernel.org
 help / color / Atom feed
* Can't seem to find a maintainer for init/* files
@ 2019-10-18 21:33 Paulo Almeida
  2019-10-18 21:38 ` Paulo Almeida
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Paulo Almeida @ 2019-10-18 21:33 UTC (permalink / raw)
  To: kernelnewbies

[-- Attachment #1.1: Type: text/plain, Size: 994 bytes --]

Hi all,

I was reading the KernelJanitor/Todo webpage and found the printk-related
task that had to be done.

I eventually came across this piece of code that led me to 2 questions that
I couldn't answer myself
https://github.com/torvalds/linux/blame/master/init/do_mounts.c#L434-L455

1 - This specific code block has been around for quite some time and many
additions using the correct printk(KERN_* were made after it was written.
Does that mean that this code block is an exception and should be left
as-is for some technical reason? Or, people have somehow forgotten about it
and I finally found something to do? :)

2 - I took a look at the https://www.kernel.org/doc/linux/MAINTAINERS list
and their respective folders/repos and couldn't find out who would be the
person who I should eventually send the patches to. Is there any
"fallthrough" maintainer when there isn't one specified? (Please put me
straight if I'm not seeing things from the right angle)

Best regards,

Paulo Almeida

[-- Attachment #1.2: Type: text/html, Size: 1355 bytes --]

<div dir="ltr">Hi all,<div><br></div><div>I was reading the KernelJanitor/Todo webpage and found the printk-related task that had to be done.</div><div><br></div><div>I eventually came across this piece of code that led me to 2 questions that I couldn&#39;t answer myself <a href="https://github.com/torvalds/linux/blame/master/init/do_mounts.c#L434-L455">https://github.com/torvalds/linux/blame/master/init/do_mounts.c#L434-L455</a></div><div><br></div><div>1 - This specific code block has been around for quite some time and many additions using the correct printk(KERN_* were made after it was written. Does that mean that this code block is an exception and should be left as-is for some technical reason? Or, people have somehow forgotten about it and I finally found something to do? :)</div><div><br></div><div>2 - I took a look at the <a href="https://www.kernel.org/doc/linux/MAINTAINERS">https://www.kernel.org/doc/linux/MAINTAINERS</a> list and their respective folders/repos and couldn&#39;t find out who would be the person who I  should eventually send the patches to. Is there any &quot;fallthrough&quot; maintainer when there isn&#39;t one specified? (Please put me straight if I&#39;m not seeing things from the right angle)</div><div><br></div><div>Best regards,</div><div><br></div><div>Paulo Almeida</div><div><br></div></div>

[-- Attachment #2: Type: text/plain, Size: 170 bytes --]

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can't seem to find a maintainer for init/* files
  2019-10-18 21:33 Can't seem to find a maintainer for init/* files Paulo Almeida
@ 2019-10-18 21:38 ` Paulo Almeida
  2019-10-18 22:32 ` Greg KH
  2019-10-18 23:25 ` Valdis Klētnieks
  2 siblings, 0 replies; 7+ messages in thread
From: Paulo Almeida @ 2019-10-18 21:38 UTC (permalink / raw)
  To: kernelnewbies

[-- Attachment #1.1: Type: text/plain, Size: 1447 bytes --]

I believe I just found the answer for point number 2:

THE REST
M: Linus Torvalds <torvalds@linux-foundation.org>
L: linux-kernel@vger.kernel.org
Q: http://patchwork.kernel.org/project/LKML/list/
T: git git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
S: Buried alive in reporters
F: *
F: */


On Sat, Oct 19, 2019 at 10:33 AM Paulo Almeida <
paulo.miguel.almeida.rodenas@gmail.com> wrote:

> Hi all,
>
> I was reading the KernelJanitor/Todo webpage and found the printk-related
> task that had to be done.
>
> I eventually came across this piece of code that led me to 2 questions
> that I couldn't answer myself
> https://github.com/torvalds/linux/blame/master/init/do_mounts.c#L434-L455
>
> 1 - This specific code block has been around for quite some time and many
> additions using the correct printk(KERN_* were made after it was written.
> Does that mean that this code block is an exception and should be left
> as-is for some technical reason? Or, people have somehow forgotten about it
> and I finally found something to do? :)
>
> 2 - I took a look at the https://www.kernel.org/doc/linux/MAINTAINERS list
> and their respective folders/repos and couldn't find out who would be the
> person who I should eventually send the patches to. Is there any
> "fallthrough" maintainer when there isn't one specified? (Please put me
> straight if I'm not seeing things from the right angle)
>
> Best regards,
>
> Paulo Almeida
>
>

[-- Attachment #1.2: Type: text/html, Size: 2402 bytes --]

<div dir="ltr">I believe I just found the answer for point number 2:<div><br></div><div>THE REST<br>M:	Linus Torvalds &lt;<a href="mailto:torvalds@linux-foundation.org">torvalds@linux-foundation.org</a>&gt;<br>L:	<a href="mailto:linux-kernel@vger.kernel.org">linux-kernel@vger.kernel.org</a><br>Q:	<a href="http://patchwork.kernel.org/project/LKML/list/">http://patchwork.kernel.org/project/LKML/list/</a><br>T:	git git://<a href="http://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git">git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git</a><br>S:	Buried alive in reporters<br>F:	*<br>F:	*/<br></div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Oct 19, 2019 at 10:33 AM Paulo Almeida &lt;<a href="mailto:paulo.miguel.almeida.rodenas@gmail.com">paulo.miguel.almeida.rodenas@gmail.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi all,<div><br></div><div>I was reading the KernelJanitor/Todo webpage and found the printk-related task that had to be done.</div><div><br></div><div>I eventually came across this piece of code that led me to 2 questions that I couldn&#39;t answer myself <a href="https://github.com/torvalds/linux/blame/master/init/do_mounts.c#L434-L455" target="_blank">https://github.com/torvalds/linux/blame/master/init/do_mounts.c#L434-L455</a></div><div><br></div><div>1 - This specific code block has been around for quite some time and many additions using the correct printk(KERN_* were made after it was written. Does that mean that this code block is an exception and should be left as-is for some technical reason? Or, people have somehow forgotten about it and I finally found something to do? :)</div><div><br></div><div>2 - I took a look at the <a href="https://www.kernel.org/doc/linux/MAINTAINERS" target="_blank">https://www.kernel.org/doc/linux/MAINTAINERS</a> list and their respective folders/repos and couldn&#39;t find out who would be the person who I  should eventually send the patches to. Is there any &quot;fallthrough&quot; maintainer when there isn&#39;t one specified? (Please put me straight if I&#39;m not seeing things from the right angle)</div><div><br></div><div>Best regards,</div><div><br></div><div>Paulo Almeida</div><div><br></div></div>
</blockquote></div>

[-- Attachment #2: Type: text/plain, Size: 170 bytes --]

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can't seem to find a maintainer for init/* files
  2019-10-18 21:33 Can't seem to find a maintainer for init/* files Paulo Almeida
  2019-10-18 21:38 ` Paulo Almeida
@ 2019-10-18 22:32 ` Greg KH
  2019-10-18 23:53   ` Paulo Almeida
  2019-10-18 23:25 ` Valdis Klētnieks
  2 siblings, 1 reply; 7+ messages in thread
From: Greg KH @ 2019-10-18 22:32 UTC (permalink / raw)
  To: Paulo Almeida; +Cc: kernelnewbies

On Sat, Oct 19, 2019 at 10:33:00AM +1300, Paulo Almeida wrote:
> Hi all,
> 
> I was reading the KernelJanitor/Todo webpage and found the printk-related
> task that had to be done.
> 
> I eventually came across this piece of code that led me to 2 questions that
> I couldn't answer myself
> https://github.com/torvalds/linux/blame/master/init/do_mounts.c#L434-L455
> 
> 1 - This specific code block has been around for quite some time and many
> additions using the correct printk(KERN_* were made after it was written.
> Does that mean that this code block is an exception and should be left
> as-is for some technical reason? Or, people have somehow forgotten about it
> and I finally found something to do? :)
> 
> 2 - I took a look at the https://www.kernel.org/doc/linux/MAINTAINERS list
> and their respective folders/repos and couldn't find out who would be the
> person who I should eventually send the patches to. Is there any
> "fallthrough" maintainer when there isn't one specified? (Please put me
> straight if I'm not seeing things from the right angle)

Run scripts/get_maintainer.pl on any file and it will tell you where to
send changes to:
	$ ./scripts/get_maintainer.pl --file init/do_mounts.c
	Al Viro <viro@zeniv.linux.org.uk> (commit_signer:7/9=78%,authored:5/9=56%,added_lines:7/44=16%,removed_lines:27/32=84%)
	David Howells <dhowells@redhat.com> (commit_signer:3/9=33%,authored:2/9=22%,added_lines:5/44=11%,removed_lines:5/32=16%)
	Andrew Morton <akpm@linux-foundation.org> (commit_signer:2/9=22%)
	Nikolaus Voss <nikolaus.voss@loewensteinmedical.de> (commit_signer:1/9=11%,authored:1/9=11%,added_lines:31/44=70%)
	Thomas Gleixner <tglx@linutronix.de> (commit_signer:1/9=11%,authored:1/9=11%)
	linux-kernel@vger.kernel.org (open list)

But don't do janitorial cleanup on those files as a "first task".  That
is what the drivers/staging/ directory is for, don't mess with core
kernel files unless you have experience doing kernel changes, as the
learning curve needs to be gotten over first.

good luck!

greg k-h

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can't seem to find a maintainer for init/* files
  2019-10-18 21:33 Can't seem to find a maintainer for init/* files Paulo Almeida
  2019-10-18 21:38 ` Paulo Almeida
  2019-10-18 22:32 ` Greg KH
@ 2019-10-18 23:25 ` Valdis Klētnieks
  2019-10-21 12:37   ` Paulo Miguel Almeida
  2 siblings, 1 reply; 7+ messages in thread
From: Valdis Klētnieks @ 2019-10-18 23:25 UTC (permalink / raw)
  To: Paulo Almeida; +Cc: kernelnewbies

[-- Attachment #1.1: Type: text/plain, Size: 1989 bytes --]

On Sat, 19 Oct 2019 10:33:00 +1300, Paulo Almeida said:

> 1 - This specific code block has been around for quite some time and many
> additions using the correct printk(KERN_* were made after it was written.
> Does that mean that this code block is an exception and should be left
> as-is for some technical reason? Or, people have somehow forgotten about it
> and I finally found something to do? :)

There's a meta-consideration or two here to think about.

First, many maintainers are not thrilled with trivial patches to code,
especially checkpatch cleanups.  That's because those patches fall into two
major categories:

The patch is against code that's debugged and rock solid stable.  Most of
do_mounts.c is close to a decade old, and it's only being changed when it's
needed to add an actual feature (such as mounting by partition label in 2018
or mounting a CIFS filesystem this year).  And we *have* had what looked like
"trivial checkpatch cleanup" patches that were buggy and broke stuff.

The other category is "patches against code that's being worked on".  If it's
something that somebody else is working on, it can cause merge conflicts, which
make maintainers grumpy.  So the maintainer only wants to see those cleanups if
they're by the person who's working on the code, at the front of the patch
series, so that (presumably) they don't have merge commits and they've gotten
some compile and run testing.

The other big consideration is git.  Yes, git knows where and when every single
line of code came from.  That doesn't mean it's always easy to get it to cough
up information.

For example:   'git blame init/do_mounts.c'.  That tells you where each line came from.
Now... imagine a commit that did a spaces-to-tabs cleanup on lines 249 to 257.
git blame' now lists the cleanup commit, not the 6 commits that added the original code.

Exercise for the reader:  Determine the easiest way to get 'git blame' to show you
the original 6 commits rather than the cleanup.

[-- Attachment #1.2: Type: application/pgp-signature, Size: 832 bytes --]

[-- Attachment #2: Type: text/plain, Size: 170 bytes --]

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can't seem to find a maintainer for init/* files
  2019-10-18 22:32 ` Greg KH
@ 2019-10-18 23:53   ` Paulo Almeida
  0 siblings, 0 replies; 7+ messages in thread
From: Paulo Almeida @ 2019-10-18 23:53 UTC (permalink / raw)
  To: kernelnewbies

[-- Attachment #1.1: Type: text/plain, Size: 1407 bytes --]


> On 19/10/2019, at 11:32 AM, Greg KH <greg@kroah.com> wrote:
> 
> Run scripts/get_maintainer.pl on any file and it will tell you where to
> send changes to:
> 	$ ./scripts/get_maintainer.pl --file init/do_mounts.c
> 	Al Viro <viro@zeniv.linux.org.uk <mailto:viro@zeniv.linux.org.uk>> (commit_signer:7/9=78%,authored:5/9=56%,added_lines:7/44=16%,removed_lines:27/32=84%)
> 	David Howells <dhowells@redhat.com <mailto:dhowells@redhat.com>> (commit_signer:3/9=33%,authored:2/9=22%,added_lines:5/44=11%,removed_lines:5/32=16%)
> 	Andrew Morton <akpm@linux-foundation.org <mailto:akpm@linux-foundation.org>> (commit_signer:2/9=22%)
> 	Nikolaus Voss <nikolaus.voss@loewensteinmedical.de <mailto:nikolaus.voss@loewensteinmedical.de>> (commit_signer:1/9=11%,authored:1/9=11%,added_lines:31/44=70%)
> 	Thomas Gleixner <tglx@linutronix.de <mailto:tglx@linutronix.de>> (commit_signer:1/9=11%,authored:1/9=11%)
> 	linux-kernel@vger.kernel.org <mailto:linux-kernel@vger.kernel.org> (open list)
> 
> But don't do janitorial cleanup on those files as a "first task".  That
> is what the drivers/staging/ directory is for, don't mess with core
> kernel files unless you have experience doing kernel changes, as the
> learning curve needs to be gotten over first.

Hi Greg,

I appreciate your reply and I will take your piece of advice on what to do as the first task.

Best regards,

Paulo Almeida

[-- Attachment #1.2: Type: text/html, Size: 17901 bytes --]

<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On 19/10/2019, at 11:32 AM, Greg KH &lt;<a href="mailto:greg@kroah.com" class="">greg@kroah.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">Run scripts/get_maintainer.pl on any file and it will tell you where to</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">send changes to:</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span class="Apple-tab-span" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">	</span><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">$ ./scripts/get_maintainer.pl --file init/do_mounts.c</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span class="Apple-tab-span" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">	</span><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">Al Viro &lt;</span><a href="mailto:viro@zeniv.linux.org.uk" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">viro@zeniv.linux.org.uk</a><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">&gt; (commit_signer:7/9=78%,authored:5/9=56%,added_lines:7/44=16%,removed_lines:27/32=84%)</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span class="Apple-tab-span" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">	</span><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">David Howells &lt;</span><a href="mailto:dhowells@redhat.com" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">dhowells@redhat.com</a><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">&gt; (commit_signer:3/9=33%,authored:2/9=22%,added_lines:5/44=11%,removed_lines:5/32=16%)</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span class="Apple-tab-span" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">	</span><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">Andrew Morton &lt;</span><a href="mailto:akpm@linux-foundation.org" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">akpm@linux-foundation.org</a><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">&gt; (commit_signer:2/9=22%)</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span class="Apple-tab-span" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">	</span><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">Nikolaus Voss &lt;</span><a href="mailto:nikolaus.voss@loewensteinmedical.de" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">nikolaus.voss@loewensteinmedical.de</a><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">&gt; (commit_signer:1/9=11%,authored:1/9=11%,added_lines:31/44=70%)</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span class="Apple-tab-span" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">	</span><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">Thomas Gleixner &lt;</span><a href="mailto:tglx@linutronix.de" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">tglx@linutronix.de</a><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">&gt; (commit_signer:1/9=11%,authored:1/9=11%)</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span class="Apple-tab-span" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">	</span><a href="mailto:linux-kernel@vger.kernel.org" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">linux-kernel@vger.kernel.org</a><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class=""><span class="Apple-converted-space">&nbsp;</span>(open list)</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">But don't do janitorial cleanup on those files as a "first task". &nbsp;That</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">is what the drivers/staging/ directory is for, don't mess with core</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">kernel files unless you have experience doing kernel changes, as the</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">learning curve needs to be gotten over first.</span></div></blockquote></div><br class=""><div class="">Hi Greg,</div><div class=""><br class=""></div><div class="">I appreciate your reply and I will take your piece of advice on what to do as the first task.</div><div class=""><br class=""></div><div class="">Best regards,</div><div class=""><br class=""></div><div class="">Paulo Almeida</div></body></html>

[-- Attachment #2: Type: text/plain, Size: 170 bytes --]

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can't seem to find a maintainer for init/* files
  2019-10-18 23:25 ` Valdis Klētnieks
@ 2019-10-21 12:37   ` Paulo Miguel Almeida
  2019-10-21 13:45     ` Valdis Klētnieks
  0 siblings, 1 reply; 7+ messages in thread
From: Paulo Miguel Almeida @ 2019-10-21 12:37 UTC (permalink / raw)
  To: kernelnewbies

On Fri, Oct 18, 2019 at 07:25:12PM -0400, Valdis Klētnieks wrote:
> On Sat, 19 Oct 2019 10:33:00 +1300, Paulo Almeida said:
> 
> > 1 - This specific code block has been around for quite some time and many
> > additions using the correct printk(KERN_* were made after it was written.
> > Does that mean that this code block is an exception and should be left
> > as-is for some technical reason? Or, people have somehow forgotten about it
> > and I finally found something to do? :)
> 
> There's a meta-consideration or two here to think about.
> 
> First, many maintainers are not thrilled with trivial patches to code,
> especially checkpatch cleanups.  That's because those patches fall into two
> major categories:
> 
> The patch is against code that's debugged and rock solid stable.  Most of
> do_mounts.c is close to a decade old, and it's only being changed when it's
> needed to add an actual feature (such as mounting by partition label in 2018
> or mounting a CIFS filesystem this year).  And we *have* had what looked like
> "trivial checkpatch cleanup" patches that were buggy and broke stuff.
> 
> The other category is "patches against code that's being worked on".  If it's
> something that somebody else is working on, it can cause merge conflicts, which
> make maintainers grumpy.  So the maintainer only wants to see those cleanups if
> they're by the person who's working on the code, at the front of the patch
> series, so that (presumably) they don't have merge commits and they've gotten
> some compile and run testing.
> 

That makes perfect sense. 

> The other big consideration is git.  Yes, git knows where and when every single
> line of code came from.  That doesn't mean it's always easy to get it to cough
> up information.

I must confess that prior to this "challenge" of yours, I hadn't realised how tricky
git can become to get it to do certain things.  

> 
> For example:   'git blame init/do_mounts.c'.  That tells you where each line came from.
> Now... imagine a commit that did a spaces-to-tabs cleanup on lines 249 to 257.
> git blame' now lists the cleanup commit, not the 6 commits that added the original code.
> 
> Exercise for the reader:  Determine the easiest way to get 'git blame' to show you
> the original 6 commits rather than the cleanup.

Considering that I'm technically a reader :) I'm gonna start with my solution and
if anyone else wants to add to it (or replace it altogether) feel free to do so.

What I got so far is:

L_START=249
L_FINISH=257
FILE=init/do_mounts.c; 

for commit in $(git log --format='%h' --no-patch -L$L_START,$L_FINISH:$FILE | cat | tail -n +2)
do 	
    echo "Showing commit: $commit of file: $FILE"
    git blame -n -L$L_START,$L_FINISH $commit -- $FILE
done

PS.: (For future readers)  That may take a while.

I feel like this isn't right per se as the "git log -L" doesn't support "--follow" 
argument that would impact our ability to make it cough up the info we wanted in case the
file had been renamed. However, on the other hand, it would (to my understanding) make
its best effort to keep track of those lines in the log history. (Correct me if I'm wrong)

In a second approach:
I tried making "git log" to list all the commits this particular file was involved in
(so I could use --follow) but I ended up with loads of commits that change other sections 
of the file (not the lines we were looking for) and because of that I didn't feel like I 
was meeting the "'git blame' to show you the original 6 commits rather than the 
cleanup" rule.

@Valdis I hope I'm not going off-topic but could you shed some light on this?

Last but not least, I appriciate the meta-consideration points you brought up.

Best Regards,

Paulo Almeida



_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can't seem to find a maintainer for init/* files
  2019-10-21 12:37   ` Paulo Miguel Almeida
@ 2019-10-21 13:45     ` Valdis Klētnieks
  0 siblings, 0 replies; 7+ messages in thread
From: Valdis Klētnieks @ 2019-10-21 13:45 UTC (permalink / raw)
  To: Paulo Miguel Almeida; +Cc: kernelnewbies

[-- Attachment #1.1: Type: text/plain, Size: 775 bytes --]

On Tue, 22 Oct 2019 01:37:33 +1300, Paulo Miguel Almeida said:

> In a second approach:
> I tried making "git log" to list all the commits this particular file was involved in
> (so I could use --follow) but I ended up with loads of commits that change other sections
> of the file (not the lines we were looking for) and because of that I didn't feel like I
> was meeting the "'git blame' to show you the original 6 commits rather than the
> cleanup" rule.

Hint 1:  'git log' supports --no-merges which can simplify things sometimes.

Hint 2:   When specifying a commit, there is a ~ operator that can be used to advantage here.

So once you figure out which commit did the whitespace patching, it's easy to get
git blame to cough up what the tree looked like just before.

[-- Attachment #1.2: Type: application/pgp-signature, Size: 832 bytes --]

[-- Attachment #2: Type: text/plain, Size: 170 bytes --]

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, back to index

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-18 21:33 Can't seem to find a maintainer for init/* files Paulo Almeida
2019-10-18 21:38 ` Paulo Almeida
2019-10-18 22:32 ` Greg KH
2019-10-18 23:53   ` Paulo Almeida
2019-10-18 23:25 ` Valdis Klētnieks
2019-10-21 12:37   ` Paulo Miguel Almeida
2019-10-21 13:45     ` Valdis Klētnieks

Kernel Newbies archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/kernelnewbies/0 kernelnewbies/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 kernelnewbies kernelnewbies/ https://lore.kernel.org/kernelnewbies \
		kernelnewbies@kernelnewbies.org
	public-inbox-index kernelnewbies

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernelnewbies.kernelnewbies


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git