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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170411122016.GK6729@dhcp22.suse.cz>
Date:   Tue, 11 Apr 2017 14:20:16 +0200
From:   Michal Hocko <mhocko@...nel.org>
To:     "Rafael J. Wysocki" <rjw@...ysocki.net>
Cc:     Joey Lee <jlee@...e.com>, Jiri Kosina <jkosina@...e.cz>,
        Kani Toshimitsu <toshi.kani@....com>,
        Len Brown <lenb@...nel.org>,
        LKML <linux-kernel@...r.kernel.org>, linux-acpi@...r.kernel.org,
        linux-api@...r.kernel.org
Subject: Re: [PATCH] acpi: drop support for force_remove

On Tue 11-04-17 00:15:42, Rafael J. Wysocki wrote:
> On Monday, April 10, 2017 07:13:44 PM Michal Hocko wrote:
> > On Mon 03-04-17 09:40:23, Michal Hocko wrote:
> > > From: Michal Hocko <mhocko@...e.com>
> > > 
> > > /sys/firmware/acpi/hotplug/force_remove was presumably added to support
> > > auto offlining in the past. This is, however, inherently dangerous for
> > > some hotplugable resources like memory. The memory offlining fails when
> > > the memory is still in use and cannot be dropped or migrated. If we
> > > ignore the failure we are basically allowing for subtle memory
> > > corruption or a crash.
> > > 
> > > We have actually noticed the later while hitting BUG() during the memory
> > > hotremove (remove_memory):
> > > 	ret = walk_memory_range(PFN_DOWN(start), PFN_UP(start + size - 1), NULL,
> > > 			check_memblock_offlined_cb);
> > > 	if (ret)
> > > 		BUG();
> > > 
> > > it took us quite non-trivial time realize that the customer had
> > > force_remove enabled. Even if the BUG was removed here and we could
> > > propagate the error up the call chain it wouldn't help at all because
> > > then we would hit a crash or a memory corruption later and harder to
> > > debug. So force_remove is unfixable for the memory hotremove. We haven't
> > > checked other hotplugable resources to be prone to a similar problems.
> > > 
> > > Remove the force_remove functionality because it is not fixable currently.
> > > Keep the sysfs file and report an error if somebody tries to enable it.
> > > Encourage users to report about the missing functionality and work with
> > > them with an alternative solution.
> > > 
> > > Reviewed-by: Lee, Chun-Yi <jlee@...e.com>
> > > Signed-off-by: Michal Hocko <mhocko@...e.com>
> > 
> > ping on this?
> 
> /shrug/
> 
> I'll apply it if nobody has any problems with it.

It is definitely your call but how long are we going to wait
(considering that the current behavior is obviously broken wrt memory
hotplug)?
-- 
Michal Hocko
SUSE Labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ