aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorAlex Ng <alexng@messages.microsoft.com>2016-11-06 16:14:12 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-11-07 04:01:17 -0500
commit8500096017e3a1baadbdefe8b84a99117472af46 (patch)
treea4974a34951f6127b5038cb59b76384dd3c45ee9 /drivers
parentb357fd3908c1191f2f56e38aa77f2aecdae18bc8 (diff)
Drivers: hv: balloon: Fix info request to show max page count
Balloon driver was only printing the size of the info blob and not the actual content. This fixes it so that the info blob (max page count as configured in Hyper-V) is printed out. Signed-off-by: Alex Ng <alexng@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/hv/hv_balloon.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/hv/hv_balloon.c b/drivers/hv/hv_balloon.c
index 8cac29a24f21..14c3dc4bd23c 100644
--- a/drivers/hv/hv_balloon.c
+++ b/drivers/hv/hv_balloon.c
@@ -1034,8 +1034,13 @@ static void process_info(struct hv_dynmem_device *dm, struct dm_info_msg *msg)
1034 1034
1035 switch (info_hdr->type) { 1035 switch (info_hdr->type) {
1036 case INFO_TYPE_MAX_PAGE_CNT: 1036 case INFO_TYPE_MAX_PAGE_CNT:
1037 pr_info("Received INFO_TYPE_MAX_PAGE_CNT\n"); 1037 if (info_hdr->data_size == sizeof(__u64)) {
1038 pr_info("Data Size is %d\n", info_hdr->data_size); 1038 __u64 *max_page_count = (__u64 *)&info_hdr[1];
1039
1040 pr_info("INFO_TYPE_MAX_PAGE_CNT = %llu\n",
1041 *max_page_count);
1042 }
1043
1039 break; 1044 break;
1040 default: 1045 default:
1041 pr_info("Received Unknown type: %d\n", info_hdr->type); 1046 pr_info("Received Unknown type: %d\n", info_hdr->type);