Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964786AbbEHUiz (ORCPT ); Fri, 8 May 2015 16:38:55 -0400 Received: from mail-wg0-f46.google.com ([74.125.82.46]:35343 "EHLO mail-wg0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932079AbbEHUiy (ORCPT ); Fri, 8 May 2015 16:38:54 -0400 MIME-Version: 1.0 In-Reply-To: <20150508130307.e9bfedcfc66cbe6e6b009f19@linux-foundation.org> References: <20150508130307.e9bfedcfc66cbe6e6b009f19@linux-foundation.org> Date: Fri, 8 May 2015 13:38:52 -0700 Message-ID: Subject: Re: [PATCHv2 0/3] Find mirrored memory, use for boot time allocations From: Tony Luck To: Andrew Morton Cc: Linux Kernel Mailing List , "linux-mm@kvack.org" Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2257 Lines: 46 On Fri, May 8, 2015 at 1:03 PM, Andrew Morton wrote: > Looks good to me. What happens to these patches while ZONE_MIRROR is > being worked on? I think these patches can go into the kernel now while I figure out the next phase - there is some value in just this part. We'll have all memory <4GB mirrored to cover the kernel code/data. Adding the boot time allocations mostly means the page structures (in terms of total amount of memory). > I'm wondering about phase II. What does "select kernel allocations" > mean? I assume we can't say "all kernel allocations" because that can > sometimes be "almost all memory". How are you planning on implementing > this? A new __GFP_foo flag, then sprinkle that into selected sites? Some of that is TBD - there are some clear places where we have bounded amounts of memory that we'd like to pull into the mirror area. E.g. loadable modules - on a specific machine an administrator can easily see which modules are loaded, tally up the sizes, and then adjust the amount of mirrored memory. I don't think we necessarily need to get to 100% ... if we can avoid 9/10 errors crashing the machine - that moves the reliability needle enough to make a difference. Phase 2 may turn into phase 2a, 2b, 2c etc. as we pick on certain areas. Oh - they'll be some sysfs or debugfs stats too - so people can check that they have the right amount of mirror memory under application load. Too little and they'll be at risk because kernel allocations will fall back to non-mirrored. Too much, and they are wasting memory. > Will surplus ZONE_MIRROR memory be available for regular old movable > allocations? ZONE_MIRROR and ZONE_MOVABLE are pretty much opposites. We only want kernel allocations in mirror memory, and we can't allow any kernel allocations in movable (cause they'll pin it). > I suggest you run the design ideas by Mel before getting into > implementation. Good idea - when I have something fit to be seen, I'll share with Mel. -Tony -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/