From: Andrew Morton <akpm@linux-foundation.org>
To: Valdis.Kletnieks@vt.edu
Cc: Michal Hocko <mhocko@suse.cz>,
mm-commits@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-mm@kvack.org, linux-fsdevel@vger.kernel.org,
linux-next@vger.kernel.org, sfr@canb.auug.org.au,
Sasha Levin <sasha.levin@oracle.com>
Subject: Re: [PATCH] mm, debug: mm-introduce-vm_bug_on_mm-fix-fix.patch
Date: Tue, 23 Sep 2014 13:52:58 -0700 [thread overview]
Message-ID: <20140923135258.faf628403a58701da5a981df@linux-foundation.org> (raw)
In-Reply-To: <83907.1411489189@turing-police.cc.vt.edu>
On Tue, 23 Sep 2014 12:19:49 -0400 Valdis.Kletnieks@vt.edu wrote:
> On Tue, 23 Sep 2014 13:28:48 +0200, Michal Hocko said:
> > And there is another one hitting during randconfig. The patch makes my
> > eyes bleed
>
> Amen. But I'm not seeing a better fix either.
>
> > #if defined(CONFIG_NUMA_BALANCING) || defined(CONFIG_COMPACTION)
> > - "tlb_flush_pending %d\n",
> > + "tlb_flush_pending %d\n"
> > #endif
> > - mm, mm->mmap, mm->vmacache_seqnum, mm->task_size,
> > + , mm, mm->mmap, mm->vmacache_seqnum, mm->task_size,
>
> I'm surprised that checkpatch doesn't explode on this. And I'm starting
> a pool on how soon somebody submits a patch to "fix" this. :)
It is all pretty godawful. We can eliminate the tricks with the comma
separators by adding an always-there, does-nothing argument:
--- a/mm/debug.c~mm-debug-mm-introduce-vm_bug_on_mm-fix-fixpatch-fix
+++ a/mm/debug.c
@@ -197,7 +197,9 @@ void dump_mm(const struct mm_struct *mm)
#if defined(CONFIG_NUMA_BALANCING) || defined(CONFIG_COMPACTION)
"tlb_flush_pending %d\n"
#endif
- , mm, mm->mmap, mm->vmacache_seqnum, mm->task_size,
+ "%s", /* This is here to hold the comma */
+
+ mm, mm->mmap, mm->vmacache_seqnum, mm->task_size,
#ifdef CONFIG_MMU
mm->get_unmapped_area,
#endif
@@ -218,16 +220,17 @@ void dump_mm(const struct mm_struct *mm)
#ifdef CONFIG_MEMCG
mm->owner,
#endif
- mm->exe_file
+ mm->exe_file,
#ifdef CONFIG_MMU_NOTIFIER
- , mm->mmu_notifier_mm
+ mm->mmu_notifier_mm,
#endif
#ifdef CONFIG_NUMA_BALANCING
- , mm->numa_next_scan, mm->numa_scan_offset, mm->numa_scan_seq
+ mm->numa_next_scan, mm->numa_scan_offset, mm->numa_scan_seq,
#endif
#if defined(CONFIG_NUMA_BALANCING) || defined(CONFIG_COMPACTION)
- , mm->tlb_flush_pending
+ mm->tlb_flush_pending,
#endif
+ "" /* This is here to not have a comma! */
);
dump_flags(mm->def_flags, vmaflags_names,
_
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2014-09-23 20:53 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-23 0:02 mmotm 2014-09-22-16-57 uploaded akpm
2014-09-23 0:39 ` Stephen Rothwell
2014-09-23 1:12 ` Andrew Morton
2014-09-23 9:24 ` [PATCH] mm, debug: mm-introduce-vm_bug_on_mm-fix.patch Michal Hocko
2014-09-23 11:28 ` [PATCH] mm, debug: mm-introduce-vm_bug_on_mm-fix-fix.patch Michal Hocko
2014-09-23 16:19 ` Valdis.Kletnieks
2014-09-23 20:52 ` Andrew Morton [this message]
2014-09-24 7:09 ` Michal Hocko
2014-09-23 20:12 ` Dave Jones
2014-10-13 18:51 ` Dave Jones
2014-10-13 19:07 ` Joe Perches
2014-10-14 11:55 ` Michal Hocko
2014-10-14 16:50 ` Dave Jones
2014-10-15 9:03 ` Michal Hocko
2014-09-23 19:02 ` mmotm 2014-09-22-16-57 uploaded Guenter Roeck
2014-09-23 20:01 ` Andrew Morton
2014-09-23 20:13 ` Fabio Estevam
2014-09-23 20:20 ` Naoya Horiguchi
2014-09-23 20:38 ` Guenter Roeck
2014-09-23 21:08 ` Anish Bhatt
2014-09-23 20:31 ` Randy Dunlap
2014-09-23 20:57 ` Guenter Roeck
2014-09-23 21:36 ` Randy Dunlap
2014-09-23 21:53 ` Guenter Roeck
2014-09-24 4:34 ` Guenter Roeck
2014-09-24 6:24 ` David Miller
2014-09-24 7:18 ` Geert Uytterhoeven
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140923135258.faf628403a58701da5a981df@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=Valdis.Kletnieks@vt.edu \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-next@vger.kernel.org \
--cc=mhocko@suse.cz \
--cc=mm-commits@vger.kernel.org \
--cc=sasha.levin@oracle.com \
--cc=sfr@canb.auug.org.au \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox