Re: [PATCH v2] checkpatch.pl: warn on invalid commit id

From: Matteo Croce
Date: Thu Jul 25 2019 - 14:04:31 EST


On Thu, Jul 25, 2019 at 5:07 AM Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> wrote:
> What does it do if we're not operating in a git directory? For example,
> I work in /usr/src/25 and my git repo is in ../git26.
>

If .git is not found, the check is disabled

> Also, what happens relatively often is that someone quotes a linux-next
> or long-term-stable hash. If the user has those trees in the git repo,
> I assume they won't be informed of the inappropriate hash?
>

In this case it won't warn, but this should not be a problem, as the
hash doesn't change following a merge.
The problem is just if the other tree gets rebased, or if the other
tree gets never merged, e.g. stable/linux-*

Cheers,


--
Matteo Croce
per aspera ad upstream