Received: by 10.223.185.116 with SMTP id b49csp3071416wrg; Sun, 25 Feb 2018 13:08:07 -0800 (PST) X-Google-Smtp-Source: AH8x224OTrHndHa0KkMR+AQeyvggqlyyLD7ofEK2bNKRmfdq2Hts6j3mZLetbwZM6gHLEs2hUVwT X-Received: by 10.99.3.8 with SMTP id 8mr6673146pgd.5.1519592887703; Sun, 25 Feb 2018 13:08:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519592887; cv=none; d=google.com; s=arc-20160816; b=cOwwDf1P+37sVbYuEFjf3Y24xRGCqmiAz/ec7rcabiDKNAqHOpLTpsevEqCB+RdeDo Nu1kok/nVV/mc3m2w36QS5H4n7OQZNOb/h6NC/SxBqmcNPxPbaTJf4vMzz+iOVK0MJiQ REouwthc7iNrCT/NdamTBe1ni1Ul1yCl3RXHryxY22dM7mtwQlHvsr9cTkGm2f3LgAX4 69W4SOAFGvvg4tIfOGMeWFlxhXXrFp3xAfmxHMzMKk/Tb2ASBh/StT4fbgX8kzB2k5e6 z0bv670eh8352hT+JyvE1L/0DZ7Btl7odMHgf7oLP/9kiidFFryuIfAngYYC77Tq8+Gl shJg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=S55ic6uuHkY5uqnpQ4WF2S+UCsttmh5Sf5+9Cyjx3MM=; b=bjElDbAGOXxswA0Bw8TShi+RgsaKz+FvkEwtAwB7TDp5Lh3yq+Fd3MSn1a4P03m2aJ t59L10HKJDoe2akAdeooaujEgTZ6TOJ5AMuAcH2tarjET46grhFuqv4T//JJAeMnBzN9 sErNMh3EKewe5TfHyUQzkP1X4/6H/u1frT1Qi6SsbAZKGPWCiNUln2VLPyz3dqktxqze FpxFI6xmA3QP/bP9YpVZzmo55Humlanw7velJsTpPeuUVAcVyhHdfxhGaxu5jwRKuQO3 vffiyx+afFKfHwyfbGDjEW8+xB+n7j+5bPSqGNJfiQ1GEaNJmj0NePHzfB8LlwbiYQjr Z/+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=Pl/LzMdI; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o5-v6si5603788plh.135.2018.02.25.13.07.53; Sun, 25 Feb 2018 13:08:07 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=Pl/LzMdI; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751894AbeBYVHS (ORCPT + 99 others); Sun, 25 Feb 2018 16:07:18 -0500 Received: from bombadil.infradead.org ([198.137.202.133]:55432 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751557AbeBYVHP (ORCPT ); Sun, 25 Feb 2018 16:07:15 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=Content-Transfer-Encoding: Content-Type:In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To: Subject:Sender:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=S55ic6uuHkY5uqnpQ4WF2S+UCsttmh5Sf5+9Cyjx3MM=; b=Pl/LzMdIvban/nES/oMFkA5ks 5RCtNYbF7FfpSJtHe6CrljBs2IhS+66VsIvsQR/ocEJJFDPO/UbPBSIoWdiz8XjbvfBV31JN742lL 2u2QwsNArZUGIpKdSabJV8ce0uqLt1MnO2uX7kpdZvrW5duq4KGxW+BZOYHgQtc20iDm2SQNJ2yh1 Vga7XrxlG+Rfmnol13kEG28L9E6bcq9uYuY13tl9LtZqRXwp7dwiYgUnPn2crbVGcOfletJOq8FL7 MVk6CqbsYEQqOH3AM+joIL73e+b8pS+U/6wqsHL4sIJea44iT9/C/J19FW8RTi4K2YvG+JpJfSq3C Oa7f9fpqA==; Received: from static-50-53-52-16.bvtn.or.frontiernet.net ([50.53.52.16] helo=midway.dunlab) by bombadil.infradead.org with esmtpsa (Exim 4.89 #1 (Red Hat Linux)) id 1eq3Vo-0005d9-LC; Sun, 25 Feb 2018 21:07:12 +0000 Subject: Re: [PATCH v3] drivers/virt: vm_gen_counter: initial driver implementation To: Or Idgar , linux-kernel@vger.kernel.org, arnd@arndb.de, gregkh@linuxfoundation.org Cc: oidgar@redhat.com, ghammer@redhat.com, Or Idgar References: <20180225155525.25436-1-idgar@virtualoco.com> From: Randy Dunlap Message-ID: Date: Sun, 25 Feb 2018 13:07:11 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <20180225155525.25436-1-idgar@virtualoco.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 02/25/2018 07:55 AM, Or Idgar wrote: > From: Or Idgar > > This patch is a driver which expose the Virtual Machine Generation ID > via sysfs. The ID is a UUID value used to differentiate between virtual > machines. > > The VM-Generation ID is a feature defined by Microsoft (paper: > http://go.microsoft.com/fwlink/?LinkId=260709) and supported by multiple > hypervisor vendors. > > Signed-off-by: Or Idgar > --- > > Changes in v3 from v1 (v2 lack of patch changelog): > - replaced GPL2 section with SPDX line. > - including linux/kobject.h for hypervisor_kobj. > - using acpi_os_map_memory instead acpi_os_map_iomem. > > Documentation/ABI/testing/sysfs-hypervisor | 13 +++ > drivers/misc/Kconfig | 6 ++ > drivers/misc/Makefile | 1 + > drivers/misc/vmgenid.c | 140 +++++++++++++++++++++++++++++ > 4 files changed, 160 insertions(+) > create mode 100644 Documentation/ABI/testing/sysfs-hypervisor > create mode 100644 drivers/misc/vmgenid.c $Subject says drivers/virt/. Please choose one. > diff --git a/drivers/misc/vmgenid.c b/drivers/misc/vmgenid.c > new file mode 100644 > index 000000000000..6b7ec9bd45e8 > --- /dev/null > +++ b/drivers/misc/vmgenid.c > @@ -0,0 +1,140 @@ > +// SPDX-License-Identifier: GPL-2.0 > +/* > + * Virtual Machine Generation ID driver > + * > + * Copyright (C) 2018 Red Hat, Inc. All rights reserved. > + * Authors: > + * Or Idgar > + * Gal Hammer > + * > + */ > +#include > +#include > +#include > +#include > +#include > +#include > + > +MODULE_LICENSE("GPL"); > +MODULE_AUTHOR("Or Idgar "); > +MODULE_AUTHOR("Gal Hammer "); > +MODULE_DESCRIPTION("Virtual Machine Generation ID"); > +MODULE_VERSION("0.1"); > + > +ACPI_MODULE_NAME("vmgenid"); > + > +static u64 phy_addr; Minor nit: I would prefer phys_addr since we also have PHY devices that have a phy addr. thanks, -- ~Randy