From patchwork Thu Mar 5 10:24:17 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Boaz Harrosh X-Patchwork-Id: 5944551 Return-Path: X-Original-To: patchwork-linux-nvdimm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 58D0ABF440 for ; Thu, 5 Mar 2015 10:24:26 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 8A18820380 for ; Thu, 5 Mar 2015 10:24:25 +0000 (UTC) Received: from ml01.01.org (ml01.01.org [198.145.21.10]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id AAE3B202E5 for ; Thu, 5 Mar 2015 10:24:24 +0000 (UTC) Received: from ml01.vlan14.01.org (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 9C5B181193; Thu, 5 Mar 2015 02:24:24 -0800 (PST) X-Original-To: linux-nvdimm@lists.01.org Delivered-To: linux-nvdimm@lists.01.org Received: from mail-wg0-f42.google.com (mail-wg0-f42.google.com [74.125.82.42]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id C4E8D81193 for ; Thu, 5 Mar 2015 02:24:22 -0800 (PST) Received: by wggx12 with SMTP id x12so52415122wgg.6 for ; Thu, 05 Mar 2015 02:24:21 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :cc:subject:references:in-reply-to:content-type :content-transfer-encoding; bh=wkq9euNMhuwZ91RCzI5hKTdnmbKveC4vH/2U8m/4nZ0=; b=b7ykGuMep47DbIIL2HVySD5q6335Cq5Yr/KJLNSFiixnIw7IfoPd20LEupeWoUKl3O Tt+d3GJgBAYdyV5DilGxxyZoywJ8uaV/iHOKVaAbpjaxKqZXMQyKC/c8WkJUk4DmMgvw 13xe1nLWMDwnwBgsPsXthz9kej1jo6uGv0BwXOjUKf8wceIHwJDkUuEa8PgkmBZgJgqL McYySJtwFXCs/Gy3O7qoOSJCb9OhfBmpYcMzGkKfm9rjA+ATgYsvHw+qFbjRCcEAiD2O DZXFKNwZNWYtrBeK25/Xsw47I+H+BB1BrsX2vdL1Nj0LX785nC0flxjK5bq99+3suPjy eObw== X-Gm-Message-State: ALoCoQm6J4ZhtnTVc+YlQUT+4qda5h6waHof0HzFVYj+tAMgnQvIa5ChXmCRdkIzwwY9qbRn+Ihz X-Received: by 10.194.158.39 with SMTP id wr7mr17423130wjb.118.1425551059389; Thu, 05 Mar 2015 02:24:19 -0800 (PST) Received: from [10.0.0.5] ([207.232.55.62]) by mx.google.com with ESMTPSA id lu13sm10979719wic.10.2015.03.05.02.24.17 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 05 Mar 2015 02:24:18 -0800 (PST) Message-ID: <54F82ED1.8030900@plexistor.com> Date: Thu, 05 Mar 2015 12:24:17 +0200 From: Boaz Harrosh User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 MIME-Version: 1.0 To: Ingo Molnar , x86@kernel.org, linux-kernel , "Roger C. Pao" , Dan Williams , Thomas Gleixner , linux-nvdimm , "H. Peter Anvin" , Matthew Wilcox , Andy Lutomirski , Christoph Hellwig References: <54F82CE0.4040502@plexistor.com> In-Reply-To: <54F82CE0.4040502@plexistor.com> Subject: [Linux-nvdimm] [PATCH 3/3] e820: Add the unknown-12 Memory type (DDR3-NvDIMM) X-BeenThere: linux-nvdimm@lists.01.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Linux-nvdimm developer list." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: linux-nvdimm-bounces@lists.01.org Sender: "Linux-nvdimm" X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP There are multiple vendors of DDR3 NvDIMMs out in the market today. At various stages of development/production. It is estimated that there are already more the 100ds of thousands chips sold to testers and sites. All the BIOS vendors I know of, tagged these chips at e820 table as type-12 memory. Now the ACPI comity, as far as I know, did not yet define a standard type for NvDIMM. Also, as far as I know any NvDIMM standard will only be defined for DDR4. So DDR3 NvDIMM is probably stuck with this none STD type. I Wish and call the ACPI comity to Define that NvDIMM is type-12. Also for DDR4 The motivation of this patch is to be able to differentiate this NvDIMM type from a real future "unknown-reserved" type. In this patch I name type-12 "unknown-12". This is because of ACPI politics that refuse to reserve type-12 as DDR3-NvDIMM and members keep saying: "What if ACPI assigns type-12 for something else in future" [And I say: Then just don't. Please?] Signed-off-by: Boaz Harrosh --- arch/x86/kernel/e820.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/arch/x86/kernel/e820.c b/arch/x86/kernel/e820.c index c2f2da2..4bf574a 100644 --- a/arch/x86/kernel/e820.c +++ b/arch/x86/kernel/e820.c @@ -25,6 +25,11 @@ #include #include +/* These are nonstandard Memory types that we do not want in the exported + * header. + */ +#define E820_UNKNOWN_12 12 /* This is the unofficial DDR3-NVDIMM */ + /* * The e820 map is the map that gets modified e.g. with command line parameters * and that is also registered with modifications in the kernel resource tree @@ -169,6 +174,9 @@ static void __init e820_print_type(u32 type) case E820_UNUSABLE: printk(KERN_CONT "unusable"); break; + case E820_UNKNOWN_12: + printk(KERN_CONT "unknown-12"); + break; default: printk(KERN_CONT "type %u", type); break; @@ -928,6 +936,7 @@ static inline const char *e820_type_to_string(int e820_type) case E820_NVS: return "ACPI Non-volatile Storage"; case E820_UNUSABLE: return "Unusable memory"; case E820_RESERVED: return "reserved"; + case E820_UNKNOWN_12: return "unknown-12"; default: return "reserved-unknown"; } }