From: "K. Y. Srinivasan" <kys@microsoft.com>
To: gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org,
devel@linuxdriverproject.org, olaf@aepfle.de, apw@canonical.com,
jasowang@redhat.com
Cc: "K. Y. Srinivasan" <kys@microsoft.com>
Subject: [PATCH 1/1] Drivers: hv: vmbus: Add additional distro specific Kconfig options
Date: Wed, 10 Apr 2013 09:08:17 -0700 [thread overview]
Message-ID: <1365610097-10955-1-git-send-email-kys@microsoft.com> (raw)
The guest ID captures information about the guest and has room for
distributions to add distro specific information. Add Kconfig options
to support distro specific information to be managed easily.
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
---
drivers/hv/Kconfig | 14 ++++++++++++++
drivers/hv/hv.c | 4 +++-
drivers/hv/hyperv_vmbus.h | 2 +-
3 files changed, 18 insertions(+), 2 deletions(-)
diff --git a/drivers/hv/Kconfig b/drivers/hv/Kconfig
index 0403b51..d2ca9c7 100644
--- a/drivers/hv/Kconfig
+++ b/drivers/hv/Kconfig
@@ -19,4 +19,18 @@ config HYPERV_BALLOON
help
Select this option to enable Hyper-V Balloon driver.
+config HYPERV_GUEST_D1
+ hex "Distro specific information"
+ range 0x00 0xff
+ default 0
+ help
+ This specifies the Distro vendor
+
+config HYPERV_GUEST_D2
+ hex "Additional Distro specific information"
+ range 0x0000 0xffff
+ default 0
+ help
+ Additional Distro specific kernel version information
+
endmenu
diff --git a/drivers/hv/hv.c b/drivers/hv/hv.c
index ae49237..7bd2e88 100644
--- a/drivers/hv/hv.c
+++ b/drivers/hv/hv.c
@@ -148,7 +148,9 @@ int hv_init(void)
/*
* Write our OS ID.
*/
- hv_context.guestid = generate_guest_id(0, LINUX_VERSION_CODE, 0);
+ hv_context.guestid = generate_guest_id(HYPERV_GUEST_D1,
+ LINUX_VERSION_CODE,
+ HYPERV_GUEST_D2);
wrmsrl(HV_X64_MSR_GUEST_OS_ID, hv_context.guestid);
/* See if the hypercall page is already set */
diff --git a/drivers/hv/hyperv_vmbus.h b/drivers/hv/hyperv_vmbus.h
index 12f2f9e..8c9ebd0 100644
--- a/drivers/hv/hyperv_vmbus.h
+++ b/drivers/hv/hyperv_vmbus.h
@@ -410,7 +410,7 @@ enum {
*
* Bit(s)
* 63 - Indicates if the OS is Open Source or not; 1 is Open Source
- * 62:56 - Os Type; Linux is 0x100
+ * 62:56 - Os Type; Linux is 0x1
* 55:48 - Distro specific identification
* 47:16 - Linux kernel version number
* 15:0 - Distro specific identification
--
1.7.4.1
next reply other threads:[~2013-04-10 15:36 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-10 16:08 K. Y. Srinivasan [this message]
2013-04-10 15:49 ` [PATCH 1/1] Drivers: hv: vmbus: Add additional distro specific Kconfig options Greg KH
2013-04-10 16:12 ` KY Srinivasan
2013-04-10 16:33 ` Greg KH
2013-04-10 17:37 ` KY Srinivasan
2013-04-10 17:50 ` Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1365610097-10955-1-git-send-email-kys@microsoft.com \
--to=kys@microsoft.com \
--cc=apw@canonical.com \
--cc=devel@linuxdriverproject.org \
--cc=gregkh@linuxfoundation.org \
--cc=jasowang@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=olaf@aepfle.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox