lkml.org 
[lkml]   [2019]   [Nov]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/2] mm: memcg: switch to css_tryget() in get_mem_cgroup_from_mm()
On Fri, Nov 15, 2019 at 06:47:21PM +0100, Michal Hocko wrote:
> s@online@offline@
>
> And reading after myself it turned out to sound differently than I
> meant. What I wanted to say really is, what is the difference that
> css_tryget_online really guarantee when the css might go offline right
> after the call suceeds so more specifically what is the difference
> between
> if (css_tryget()) {
> if (online)
> DO_SOMETHING
> }
> and
> if (css_tryget_online()) {
> DO_SOMETHING
> }
>
> both of them are racy and do not provide any guarantee wrt. online
> state.

It's about not giving new reference when the object is known to be
delted to the user. Can you please think more about how file
deletions work?

Thanks.

--
tejun

\
 
 \ /
  Last update: 2019-11-15 18:49    [W:0.080 / U:0.916 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site