Repository navigation
Commit 35cdcbf
checkpatch: ignore warning designated initializers using NR_CPUS
Some max_length wants to hold as large room as possible to ensure enough
size to tackle with the biggest NR_CPUS. An example below:
kernel/cgroup/cpuset.c:
static struct cftype legacy_files[] = {
{
.name = "cpus",
.seq_show = cpuset_common_seq_show,
.write = cpuset_write_resmask,
.max_write_len = (100U + 6 * NR_CPUS),
.private = FILE_CPULIST,
},
...
}
Link: https://lkml.kernel.org/r/5d4998aa8a8ac7efada2c7daffa9e73559f8b186.1609331255.git.rocking@linux.alibaba.com
Signed-off-by: Peng Wang <rocking@linux.alibaba.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 b5e8736 commit 35cdcbf
1 file changed
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7025 | 7025 | | |
7026 | 7026 | | |
7027 | 7027 | | |
| 7028 | + | |
7028 | 7029 | | |
7029 | 7030 | | |
7030 | 7031 | | |
7031 | 7032 | | |
7032 | 7033 | | |
7033 | | - | |
| 7034 | + | |
| 7035 | + | |
7034 | 7036 | | |
7035 | 7037 | | |
7036 | 7038 | | |
| |||
0 commit comments