Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753289AbbEHXl1 (ORCPT ); Fri, 8 May 2015 19:41:27 -0400 Received: from mail-wi0-f182.google.com ([209.85.212.182]:33456 "EHLO mail-wi0-f182.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751003AbbEHXlZ (ORCPT ); Fri, 8 May 2015 19:41:25 -0400 MIME-Version: 1.0 In-Reply-To: <20150508134901.e3e7585b359b073253788c22@linux-foundation.org> References: <20150508130307.e9bfedcfc66cbe6e6b009f19@linux-foundation.org> <20150508134901.e3e7585b359b073253788c22@linux-foundation.org> Date: Fri, 8 May 2015 16:41:23 -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: 1046 Lines: 21 On Fri, May 8, 2015 at 1:49 PM, Andrew Morton wrote: > What I mean is: allow userspace to consume ZONE_MIRROR memory because > we can snatch it back if it is needed for kernel memory. For suitable interpretations of "snatch it back" ... if there is none free in a GFP_NOWAIT request, then we are doomed. But we could maintain some high/low watermarks to arrange the snatching when mirrored memory is getting low, rather than all the way out. It's worth a look - but perhaps at phase three. It would make life a bit easier for people to get the right amount of mirror. If they guess too high they are still wasting some memory because every mirrored page has two pages in DIMM. But without this sort of trick all the extra mirrored memory would be totally wasted. -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/