lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 17 Oct 2014 08:59:47 +0200
From:	Michal Hocko <mhocko@...e.cz>
To:	Oleg Nesterov <oleg@...hat.com>
Cc:	Cong Wang <xiyou.wangcong@...il.com>,
	David Rientjes <rientjes@...gle.com>,
	"Rafael J. Wysocki" <rjw@...ysocki.net>, Tejun Heo <tj@...nel.org>,
	Andrew Morton <akpm@...ux-foundation.org>,
	linux-kernel@...r.kernel.org
Subject: Re: + freezer-check-oom-kill-while-being-frozen.patch added to -mm
 tree

On Thu 16-10-14 22:39:54, Oleg Nesterov wrote:
> > Fix the issue by checking for TIF_MEMDIE thread flag and get away from the
> > fridge if it is set.  oom_scan_process_thread doesn't have to check for
> > the frozen task anymore because do_send_sig_info will wake up the thread
> > and TIF_MEMDIE is already set by that time.
> 
> I must have missed something... but __refrigerator() sleeps in
> TASK_UNINTERRUPTIBLE and do_send_sig_info() won't wake it up?

Ouch, I have completely missed this part when reviewing Cong's original
patch. I got confused by the retry loop. Anyway you are right and the
patch as is currently doesn't work as intented.

Can we simply make the task sleep interruptible? It retries and rechecks
the freezing conditions after wakeup anyway. It is true this would be a
user visible change because frozen tasks won't be in D state anymore
(this would make a difference for cgroup freezing because nobody would
see this in PM freezer). Does anybody depend on this?

Another possible way would be reintroducing freezer check into OOM path
and kick the task even when it is in UN state.

Thanks!
-- 
Michal Hocko
SUSE Labs
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ