Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1457409

RE: [PATCH 2/4] Drivers: hv: balloon: account for gaps in hot add regions

From "Alex Ng (LIS)" <alexng@microsoft.com>
Newsgroups linux.kernel
Subject RE: [PATCH 2/4] Drivers: hv: balloon: account for gaps in hot add regions
Date 2016-08-07 02:20 +0200
Message-ID <s3jYR-4zd-3@gated-at.bofh.it> (permalink)
References <s2KRs-6ky-9@gated-at.bofh.it> <s2KRs-6ky-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


> -----Original Message-----
> From: Vitaly Kuznetsov [mailto:vkuznets@redhat.com]
> Sent: Friday, August 5, 2016 3:49 AM
> To: devel@linuxdriverproject.org
> Cc: linux-kernel@vger.kernel.org; Haiyang Zhang <haiyangz@microsoft.com>;
> KY Srinivasan <kys@microsoft.com>; Alex Ng (LIS) <alexng@microsoft.com>
> Subject: [PATCH 2/4] Drivers: hv: balloon: account for gaps in hot add regions
> 
> I'm observing the following hot add requests from the WS2012 host:
> 
> hot_add_req: start_pfn = 0x108200 count = 330752
> hot_add_req: start_pfn = 0x158e00 count = 193536
> hot_add_req: start_pfn = 0x188400 count = 239616
> 
> As the host doesn't specify hot add regions we're trying to create 128Mb-
> aligned region covering the first request, we create the 0x108000 -
> 0x160000 region and we add 0x108000 - 0x158e00 memory. The second
> request passes the pfn_covered() check, we enlarge the region to 0x108000 -
> 0x190000 and add 0x158e00 - 0x188200 memory. The problem emerges with
> the third request as it starts at 0x188400 so there is a 0x200 gap which is not
> covered. As the end of our region is 0x190000 now it again passes the
> pfn_covered() check were we just adjust the covered_end_pfn and make it
> 0x188400 instead of 0x188200 which means that we'll try to online
> 0x188200-0x188400 pages but these pages were never assigned to us and we
> crash.

The fact that the host sent a request that's non-contiguous with the previous
request is unexpected. Could we check to see the number of pages we returned
in our response, after each request?

I'm wondering if we may have given a wrong response to cause the host to
follow-up with a gapped request.

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 0/4] Drivers: hv: balloon: fix WS2012 memory hotplug issues and do some cleanup Vitaly Kuznetsov <vkuznets@redhat.com> - 2016-08-05 12:50 +0200
  [PATCH 3/4] Drivers: hv: balloon: get rid on ol_waitevent Vitaly Kuznetsov <vkuznets@redhat.com> - 2016-08-05 12:50 +0200
    RE: [PATCH 3/4] Drivers: hv: balloon: get rid on ol_waitevent "Alex Ng (LIS)" <alexng@microsoft.com> - 2016-08-10 22:50 +0200
  [PATCH 2/4] Drivers: hv: balloon: account for gaps in hot add regions Vitaly Kuznetsov <vkuznets@redhat.com> - 2016-08-05 12:50 +0200
    RE: [PATCH 2/4] Drivers: hv: balloon: account for gaps in hot add  regions "Alex Ng (LIS)" <alexng@microsoft.com> - 2016-08-07 02:20 +0200
      Re: [PATCH 2/4] Drivers: hv: balloon: account for gaps in hot add regions Vitaly Kuznetsov <vkuznets@redhat.com> - 2016-08-08 11:40 +0200
  [PATCH 4/4] Drivers: hv: balloon: replace ha_region_mutex with spinlock Vitaly Kuznetsov <vkuznets@redhat.com> - 2016-08-05 12:50 +0200
  [PATCH 1/4] Drivers: hv: balloon: keep track of where ha_region starts Vitaly Kuznetsov <vkuznets@redhat.com> - 2016-08-05 13:00 +0200

csiph-web