Skip to content

Commit bbbe96e

Browse files
Stephen Warrentorvalds
authored andcommitted
get_maintainer: use filename-only regex match for Tegra
Create a new N: entry type in MAINTAINERS which performs a regex match against filenames; either those extracted from patch +++ or --- lines, or those specified on the command-line using the -f option. This provides the same benefits as using a K: regex option to match a set of filenames (see commit eb90d08 "get_maintainer: allow keywords to match filenames"), but without the disadvantage that "random" file content, such as comments, will ever match the regex. Hence, revert most of that commit. Switch the Tegra entry from using K: to N: [akpm@linux-foundation.org: fix typo in docs, per Marcin] Reported-by: Marcin Slusarz <marcin.slusarz@gmail.com> Suggested-by: Joe Perches <joe@perches.com> Signed-off-by: Stephen Warren <swarren@nvidia.com> Acked-by: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 0a28531 commit bbbe96e

2 files changed

Lines changed: 9 additions & 7 deletions

File tree

‎MAINTAINERS‎

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -90,20 +90,22 @@ Descriptions of section entries:
9090
F: drivers/net/* all files in drivers/net, but not below
9191
F: */net/* all files in "any top level directory"/net
9292
One pattern per line. Multiple F: lines acceptable.
93+
N: Files and directories with regex patterns.
94+
N: [^a-z]tegra all files whose path contains the word tegra
95+
One pattern per line. Multiple N: lines acceptable.
9396
X: Files and directories that are NOT maintained, same rules as F:
9497
Files exclusions are tested before file matches.
9598
Can be useful for excluding a specific subdirectory, for instance:
9699
F: net/
97100
X: net/ipv6/
98101
matches all files in and below net excluding net/ipv6/
99102
K: Keyword perl extended regex pattern to match content in a
100-
patch or file, or an affected filename. For instance:
103+
patch or file. For instance:
101104
K: of_get_profile
102-
matches patch or file content, or filenames, that contain
103-
"of_get_profile"
105+
matches patches or files that contain "of_get_profile"
104106
K: \b(printk|pr_(info|err))\b
105-
matches patch or file content, or filenames, that contain one or
106-
more of the words printk, pr_info or pr_err
107+
matches patches or files that contain one or more of the words
108+
printk, pr_info or pr_err
107109
One regex pattern per line. Multiple K: lines acceptable.
108110

109111
Note: For the hard of thinking, this list is meant to remain in alphabetical
@@ -7896,7 +7898,7 @@ L: linux-tegra@vger.kernel.org
78967898
Q: http://patchwork.ozlabs.org/project/linux-tegra/list/
78977899
T: git git://git.kernel.org/pub/scm/linux/kernel/git/swarren/linux-tegra.git
78987900
S: Supported
7899-
K: (?i)[^a-z]tegra
7901+
N: [^a-z]tegra
79007902

79017903
TEHUTI ETHERNET DRIVER
79027904
M: Andy Gospodarek <andy@greyhouse.net>

‎scripts/get_maintainer.pl‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -611,7 +611,7 @@ sub get_maintainers {
611611
$hash{$tvi} = $value_pd;
612612
}
613613
}
614-
} elsif ($type eq 'K') {
614+
} elsif ($type eq 'N') {
615615
if ($file =~ m/$value/x) {
616616
$hash{$tvi} = 0;
617617
}

0 commit comments

Comments
 (0)