Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp551755pxa; Fri, 21 Aug 2020 14:18:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzaHDISOgsRXJCusignRXeZl4COowhb5gdgI5thYAm7a8MM7NbuSbSOBamZlP/JcfuPuvI5 X-Received: by 2002:a17:906:fa0a:: with SMTP id lo10mr3208539ejb.172.1598044713688; Fri, 21 Aug 2020 14:18:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598044713; cv=none; d=google.com; s=arc-20160816; b=M3u8FbpuLVPQT+/LhNXRlnETdRcbuT2o8PoJmdTAQV1oJJLyeaIbFg6sNQZ8pVmaAy AZGor7L38aY4B9T94XcgdOEQcHQPb6b2Q66fn7k1ZU3QjCEimMAa9/sQJf54hMl4yZyA d+TG1ZeSSLDYvnxXHhNiiV5CvijFxOdwskgvXshGXmLY4p5ZsGWCDoOY/pbH8FORNXNQ 2RaIjsOb3owoA5uB8sCdrCZw1pvNApJug8p34b02Ry6ZbmHt552ODKTfz03AYt5AJjd2 FojorMBKba79713+04YrrfsCMHZImjRusS03n7KZTJ9NCs73GtHyUoac+w8crjx/6jpt ogsg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=Czkv47Mapytq1xHY+oPYH574MMmQySGYRJkgBW3lM+E=; b=RWuxWV9Ko8iRkStZRHpA1ObR9EfNv3ys+gpqp7PMsVy0oe3mu0r1Nhv7YIqZEb8zTI ASSrsMQMgtmzMzpIQwM0tne6XoJ+vtsI9XtiQtMluB9s741C2FUxWaVqvL2zHxseBeZ0 xhha/rHLE86o9RQg2Bai6b5qpo6E3VPXp/3QF37GwfHKLyAdoKddS4EO2NLkn8bjvQPH 3Hqq2J4ELxq3VzABge00Tx40N/TNz21qyHg6qVn63ThgXqsst2v5cyIN1rvKLTVAcm5l 4N15aAvZzyW9srFDfj9nsibwKTDAqhnwJsynsuoyDkoGNusaUCtAP14F2v+MzSrJT6gt KnCw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=GXn5QvE0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m18si2057492edj.463.2020.08.21.14.18.10; Fri, 21 Aug 2020 14:18:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=GXn5QvE0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726513AbgHUVRe (ORCPT + 99 others); Fri, 21 Aug 2020 17:17:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51286 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726457AbgHUVRb (ORCPT ); Fri, 21 Aug 2020 17:17:31 -0400 Received: from mail-ej1-x642.google.com (mail-ej1-x642.google.com [IPv6:2a00:1450:4864:20::642]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A2D59C061574 for ; Fri, 21 Aug 2020 14:17:30 -0700 (PDT) Received: by mail-ej1-x642.google.com with SMTP id u21so3397927ejz.0 for ; Fri, 21 Aug 2020 14:17:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Czkv47Mapytq1xHY+oPYH574MMmQySGYRJkgBW3lM+E=; b=GXn5QvE0B4fW4XfVmy6nF7VEmR25ramQstv7uYApzkRaODFrVdOXnM1zTZ6Wsmibwy dPfmTNTs899e7OIe+phFR2chos0Ft2tgG9zqM01uVVZPmE29arGNgsIzosvPzhSWUnGe J3wNyPfrnyhgIVWAU45//p0AhY4mBc6FUmzeNpTdQDSCbuWVi6ai4sl/4TKN7Bd6ypw8 5lZeOIWb5H2+OaFKo947ypFBddehhnskfMBHe4gMQN+LdPUupi+433hVBX7NeDX/oBC5 TgSqJ5flLj3v0348Ps+2DpHLbXs1TxDkDp2CaVgcTvVCd7lwN8q+51xsM4whGP0VMhL1 x6yQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Czkv47Mapytq1xHY+oPYH574MMmQySGYRJkgBW3lM+E=; b=WQgltslzy7g3lIRHeAq5FSz4aA5xM+vtLUsR8QKS9wZff7gNQ1VQHYfpKxeQGags4v KHANEGlqkq6A8xn9z9P0f1iZ6fWQ+D3c6x6CeiHhK3l3LXPeYDzqEfsFM2fRKgSAPAOs DYzQq7kW2SzTF/AyaqA4uTJQ1/1WBkw2ox3986NMForZEmV5xanjYo3h6NmrZ5AS0TaP u7QEJLejuP1Mg/YEHUwinV/GAKlPpTTpWta8CTSpNpLbuOweyVHbk+P+WpfrIjPyw47B 7tSBMx8IuQlNmm2ALMYcT2FIG3Pcbppw4NvVcxcdS9YxVPP7nqMajv+2qZQNLAzuNQuU sNkA== X-Gm-Message-State: AOAM53045c6xkc4wVx++rDa0dHJJfsoFOsp+eN3vGSnS1d25DxTwLKQ3 HNXQ7jnsf0lsrLBZfVMYqRjOQbcYxAVHhVsAh1hbSQ== X-Received: by 2002:a17:907:10d9:: with SMTP id rv25mr4570332ejb.264.1598044649266; Fri, 21 Aug 2020 14:17:29 -0700 (PDT) MIME-Version: 1.0 References: <159643094279.4062302.17779410714418721328.stgit@dwillia2-desk3.amr.corp.intel.com> <6af3de0d-ffdc-8942-3922-ebaeef20dd63@redhat.com> <3dfde5e3-e1e2-2097-afa1-303042de5e07@redhat.com> In-Reply-To: <3dfde5e3-e1e2-2097-afa1-303042de5e07@redhat.com> From: Dan Williams Date: Fri, 21 Aug 2020 14:17:18 -0700 Message-ID: Subject: Re: [PATCH v4 00/23] device-dax: Support sub-dividing soft-reserved ranges To: David Hildenbrand Cc: Andrew Morton , Ira Weiny , Ard Biesheuvel , Mike Rapoport , Borislav Petkov , Vishal Verma , David Airlie , Will Deacon , Catalin Marinas , Ard Biesheuvel , Joao Martins , Tom Lendacky , Dave Jiang , "Rafael J. Wysocki" , Jonathan Cameron , Wei Yang , X86 ML , "H. Peter Anvin" , Thomas Gleixner , Greg Kroah-Hartman , Pavel Tatashin , Peter Zijlstra , Ben Skeggs , Benjamin Herrenschmidt , Jason Gunthorpe , Jia He , Ingo Molnar , Dave Hansen , Paul Mackerras , Brice Goglin , Jeff Moyer , Michael Ellerman , "Rafael J. Wysocki" , Daniel Vetter , Andy Lutomirski , "Rafael J. Wysocki" , Linux MM , linux-nvdimm , Linux Kernel Mailing List , Linux ACPI , Maling list - DRI developers Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Aug 21, 2020 at 11:30 AM David Hildenbrand wrote: > > On 21.08.20 20:27, Dan Williams wrote: > > On Fri, Aug 21, 2020 at 3:15 AM David Hildenbrand wrote: > >> > >>>> > >>>> 1. On x86-64, e820 indicates "soft-reserved" memory. This memory is not > >>>> automatically used in the buddy during boot, but remains untouched > >>>> (similar to pmem). But as it involves ACPI as well, it could also be > >>>> used on arm64 (-e820), correct? > >>> > >>> Correct, arm64 also gets the EFI support for enumerating memory this > >>> way. However, I would clarify that whether soft-reserved is given to > >>> the buddy allocator by default or not is the kernel's policy choice, > >>> "buddy-by-default" is ok and is what will happen anyways with older > >>> kernels on platforms that enumerate a memory range this way. > >> > >> Is "soft-reserved" then the right terminology for that? It sounds very > >> x86-64/e820 specific. Maybe a compressed for of "performance > >> differentiated memory" might be a better fit to expose to user space, no? > > > > No. The EFI "Specific Purpose" bit is an attribute independent of > > e820, it's x86-Linux that entangles those together. There is no > > requirement for platform firmware to use that designation even for > > drastic performance differentiation between ranges, and conversely > > there is no requirement that memory *with* that designation has any > > performance difference compared to the default memory pool. So it > > really is a reservation policy about a memory range to keep out of the > > buddy allocator by default. > > Okay, still "soft-reserved" is x86-64 specific, no? There's nothing preventing other EFI archs, or a similar designation in another firmware spec, picking up this policy. > (AFAIK, > "soft-reserved" will be visible in /proc/iomem, or am I confusing > stuff?) No, you're correct. > IOW, it "performance differentiated" is not universally > applicable, maybe "specific purpose memory" is ? Those bikeshed colors don't seem an improvement to me. "Soft-reserved" actually tells you something about the kernel policy for the memory. The criticism of "specific purpose" that led to calling it "soft-reserved" in Linux is the fact that "specific" is undefined as far as the firmware knows, and "specific" may have different applications based on the platform user. "Soft-reserved" like "Reserved" tells you that a driver policy might be in play for that memory. Also note that the current color of the bikeshed has already shipped since v5.5: 262b45ae3ab4 x86/efi: EFI soft reservation to E820 enumeration