From: Michal Hocko <mhocko@kernel.org>
To: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Cc: Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>,
A K <akaraliou.dev@gmail.com>,
Andrew Morton <akpm@linux-foundation.org>,
Sergey Senozhatsky <sergey.senozhatsky@gmail.com>,
minchan@kernel.org, ngupta@vflare.org, linux-mm@kvack.org
Subject: Re: [PATCH v2] mm/zsmalloc: simplify shrinker init/destroy
Date: Wed, 20 Dec 2017 12:57:51 +0100 [thread overview]
Message-ID: <20171220115751.GP4831@dhcp22.suse.cz> (raw)
In-Reply-To: <20171220113835.GO4831@dhcp22.suse.cz>
On Wed 20-12-17 12:38:35, Michal Hocko wrote:
> On Wed 20-12-17 20:05:35, Tetsuo Handa wrote:
> > On 2017/12/20 18:25, Michal Hocko wrote:
> > > On Wed 20-12-17 18:16:53, Sergey Senozhatsky wrote:
> > >> On (12/20/17 10:08), Michal Hocko wrote:
> > >> [..]
> > >>>> let's keep void zs_register_shrinker() and just suppress the
> > >>>> register_shrinker() must_check warning.
> > >>>
> > >>> I would just hope we simply drop the must_check nonsense.
> > >>
> > >> agreed. given that unregister_shrinker() does not oops anymore,
> > >> enforcing that check does not make that much sense.
> > >
> > > Well, the registration failure is a failure like any others. Ignoring
> > > the failure can have bad influence on the overal system behavior but
> > > that is no different from thousands of other functions. must_check is an
> > > overreaction here IMHO.
> > >
> >
> > I don't think that must_check is an overreaction.
> > As of linux-next-20171218, no patch is available for 10 locations.
> >
> > drivers/staging/android/ion/ion_heap.c:306: register_shrinker(&heap->shrinker);
> > drivers/staging/android/ashmem.c:857: register_shrinker(&ashmem_shrinker);
> > drivers/gpu/drm/ttm/ttm_page_alloc_dma.c:1185: register_shrinker(&manager->mm_shrink);
> > drivers/gpu/drm/ttm/ttm_page_alloc.c:484: register_shrinker(&manager->mm_shrink);
> > drivers/gpu/drm/i915/i915_gem_shrinker.c:508: WARN_ON(register_shrinker(&i915->mm.shrinker));
> > drivers/gpu/drm/msm/msm_gem_shrinker.c:154: WARN_ON(register_shrinker(&priv->shrinker));
> > drivers/md/dm-bufio.c:1756: register_shrinker(&c->shrinker);
> > drivers/android/binder_alloc.c:1012: register_shrinker(&binder_shrinker);
> > arch/x86/kvm/mmu.c:5485: register_shrinker(&mmu_shrinker);
> > fs/xfs/xfs_qm.c:698: register_shrinker(&qinf->qi_shrinker);
>
> And how exactly has the must_check helped for those? Come on, start
> being serious finally. This is a matter of fixing those. You have done
> a good deal of work for some, it just takes to finish the rest. The
> warning doesn't help on its own, it just makes people ignore it after
> some time or make it silent in some way.
Also have a look at how WARN_ON simply papers over the wrong code and
must_check will not help you the slightest.
--
Michal Hocko
SUSE Labs
--
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:[~2017-12-20 11:57 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-19 9:21 [PATCH] " Aliaksei Karaliou
2017-12-19 10:22 ` Sergey Senozhatsky
2017-12-19 10:49 ` [PATCH v2] " Aliaksei Karaliou
2017-12-19 11:04 ` Sergey Senozhatsky
2017-12-19 11:56 ` Sergey Senozhatsky
2017-12-19 15:13 ` Michal Hocko
2017-12-19 15:25 ` Sergey Senozhatsky
2017-12-19 15:41 ` Aliaksei Karaliou
2017-12-19 15:58 ` Michal Hocko
2017-12-19 17:45 ` Aliaksei Karaliou
2017-12-19 23:27 ` Andrew Morton
2017-12-20 1:00 ` Sergey Senozhatsky
2017-12-20 1:00 ` Sergey Senozhatsky
2017-12-20 7:15 ` Sergey Senozhatsky
2017-12-20 8:29 ` A K
2017-12-20 8:34 ` Sergey Senozhatsky
2017-12-20 8:53 ` A K
2017-12-20 9:08 ` Michal Hocko
[not found] ` <20171220091653.GE11774@jagdpanzerIV>
2017-12-20 9:25 ` Michal Hocko
2017-12-20 9:30 ` A K
2017-12-20 10:21 ` [PATCH v3] " Aliaksei Karaliou
2017-12-21 2:29 ` Minchan Kim
2017-12-20 11:05 ` [PATCH v2] " Tetsuo Handa
2017-12-20 11:38 ` Michal Hocko
2017-12-20 11:57 ` Michal Hocko [this message]
2017-12-20 21:20 ` Aliaksei Karaliou
2017-12-21 7:25 ` Michal Hocko
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=20171220115751.GP4831@dhcp22.suse.cz \
--to=mhocko@kernel.org \
--cc=akaraliou.dev@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=linux-mm@kvack.org \
--cc=minchan@kernel.org \
--cc=ngupta@vflare.org \
--cc=penguin-kernel@I-love.SAKURA.ne.jp \
--cc=sergey.senozhatsky.work@gmail.com \
--cc=sergey.senozhatsky@gmail.com \
/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