search for: resp_buf_size

Displaying 20 results from an estimated 22 matches for "resp_buf_size".

2016 Nov 30
2
[PATCH kernel v5 5/5] virtio-balloon: tell host vm's unused page info
...lking over orders, *then* zones. I *think* you're doing it because you can efficiently fill the bitmaps at a given order for all zones, then move to a new bitmap. But, it would be interesting to document this. > + pos = 0; > + ret = get_unused_pages(vb->resp_data, > + vb->resp_buf_size / sizeof(unsigned long), > + order, &pos); FWIW, get_unsued_pages() is a pretty bad name. "get" usually implies bumping reference counts or consuming something. You're just "recording" or "marking" them. > + if (ret == -ENOSPC) { > + void *ne...
2016 Nov 30
2
[PATCH kernel v5 5/5] virtio-balloon: tell host vm's unused page info
...lking over orders, *then* zones. I *think* you're doing it because you can efficiently fill the bitmaps at a given order for all zones, then move to a new bitmap. But, it would be interesting to document this. > + pos = 0; > + ret = get_unused_pages(vb->resp_data, > + vb->resp_buf_size / sizeof(unsigned long), > + order, &pos); FWIW, get_unsued_pages() is a pretty bad name. "get" usually implies bumping reference counts or consuming something. You're just "recording" or "marking" them. > + if (ret == -ENOSPC) { > + void *ne...
2016 Nov 30
0
[PATCH kernel v5 5/5] virtio-balloon: tell host vm's unused page info
...on servicing is delegated to a freezable workqueue. */ struct work_struct update_balloon_stats_work; @@ -75,6 +75,8 @@ struct virtio_balloon { void *resp_hdr; /* Pointer to the start address of response data. */ unsigned long *resp_data; + /* Size of response data buffer. */ + unsigned long resp_buf_size; /* Pointer offset of the response data. */ unsigned long resp_pos; /* Bitmap and bitmap count used to tell the host the pages */ @@ -83,6 +85,8 @@ struct virtio_balloon { unsigned int nr_page_bmap; /* Used to record the processed pfn range */ unsigned long min_pfn, max_pfn, start_pfn,...
2016 Dec 04
0
[PATCH kernel v5 5/5] virtio-balloon: tell host vm's unused page info
...ove to a new bitmap. But, it > would be interesting to document this. > Yes, use the order is somewhat strange, but it's helpful to keep the API simple. Do you think it's acceptable? > > + pos = 0; > > + ret = get_unused_pages(vb->resp_data, > > + vb->resp_buf_size / sizeof(unsigned long), > > + order, &pos); > > FWIW, get_unsued_pages() is a pretty bad name. "get" usually implies > bumping reference counts or consuming something. You're just "recording" > or "marking" them. > Will change to m...
2016 Dec 05
1
[PATCH kernel v5 5/5] virtio-balloon: tell host vm's unused page info
...r is somewhat strange, but it's helpful to keep the API simple. > Do you think it's acceptable? Yeah, it's fine. Just comment it, please. >>> + if (ret == -ENOSPC) { >>> + void *new_resp_data; >>> + >>> + new_resp_data = kmalloc(2 * vb->resp_buf_size, >>> + GFP_KERNEL); >>> + if (new_resp_data) { >>> + kfree(vb->resp_data); >>> + vb->resp_data = new_resp_data; >>> + vb->resp_buf_size *= 2; >> >> What happens to the data in ->resp_data at this point? Doesn'...
2016 Dec 05
1
[PATCH kernel v5 5/5] virtio-balloon: tell host vm's unused page info
...r is somewhat strange, but it's helpful to keep the API simple. > Do you think it's acceptable? Yeah, it's fine. Just comment it, please. >>> + if (ret == -ENOSPC) { >>> + void *new_resp_data; >>> + >>> + new_resp_data = kmalloc(2 * vb->resp_buf_size, >>> + GFP_KERNEL); >>> + if (new_resp_data) { >>> + kfree(vb->resp_data); >>> + vb->resp_data = new_resp_data; >>> + vb->resp_buf_size *= 2; >> >> What happens to the data in ->resp_data at this point? Doesn'...
2017 Mar 16
0
[PATCH kernel v8 4/4] virtio-balloon: VIRTIO_BALLOON_F_HOST_REQ_VQ
...0; + struct virtqueue *vq = vb->host_req_vq; + int ret, order; + struct zone *zone = NULL; + bool part_fill = false; + + mutex_lock(&vb->balloon_lock); + + for (order = MAX_ORDER - 1; order >= 0; order--) { + ret = record_unused_pages(&zone, order, vb->resp_data, + vb->resp_buf_size / sizeof(__le64), + &pos, part_fill); + if (ret == -ENOSPC) { + if (pos == 0) { + void *new_resp_data; + + new_resp_data = kmalloc(2 * vb->resp_buf_size, + GFP_KERNEL); + if (new_resp_data) { + kfree(vb->resp_data); + vb->resp_data = new_resp_data; +...
2017 Mar 03
0
[PATCH v7 kernel 5/5] This patch contains two parts:
...os = 0; + struct virtqueue *vq = vb->host_req_vq; + int ret, order; + struct zone *zone = NULL; + bool part_fill = false; + + mutex_lock(&vb->balloon_lock); + + for (order = MAX_ORDER - 1; order >= 0; order--) { + ret = mark_unused_pages(&zone, order, vb->resp_data, + vb->resp_buf_size / sizeof(__le64), + &pos, VIRTIO_BALLOON_CHUNK_SIZE_SHIFT, part_fill); + if (ret == -ENOSPC) { + if (pos == 0) { + void *new_resp_data; + + new_resp_data = kmalloc(2 * vb->resp_buf_size, + GFP_KERNEL); + if (new_resp_data) { + kfree(vb->resp_data); + vb->re...
2017 Mar 16
8
[PATCH kernel v8 0/4] Extend virtio-balloon for fast (de)inflating & fast live migration
This patch series implements two optimizations: 1) transfer pages in chuncks between the guest and host; 2) transfer the guest unused pages to the host so that they can be skipped to migrate in live migration. Please read each patch commit log for details. Changes: v7->v8: 1) Use only one chunk format, instead of two. 2) re-write the virtio-balloon implementation patch. 3) commit changes 4)
2017 Mar 16
8
[PATCH kernel v8 0/4] Extend virtio-balloon for fast (de)inflating & fast live migration
This patch series implements two optimizations: 1) transfer pages in chuncks between the guest and host; 2) transfer the guest unused pages to the host so that they can be skipped to migrate in live migration. Please read each patch commit log for details. Changes: v7->v8: 1) Use only one chunk format, instead of two. 2) re-write the virtio-balloon implementation patch. 3) commit changes 4)
2016 Nov 30
8
[PATCH kernel v5 0/5] Extend virtio-balloon for fast (de)inflating & fast live migration
This patch set contains two parts of changes to the virtio-balloon. One is the change for speeding up the inflating & deflating process, the main idea of this optimization is to use bitmap to send the page information to host instead of the PFNs, to reduce the overhead of virtio data transmission, address translation and madvise(). This can help to improve the performance by about 85%.
2016 Nov 30
8
[PATCH kernel v5 0/5] Extend virtio-balloon for fast (de)inflating & fast live migration
This patch set contains two parts of changes to the virtio-balloon. One is the change for speeding up the inflating & deflating process, the main idea of this optimization is to use bitmap to send the page information to host instead of the PFNs, to reduce the overhead of virtio data transmission, address translation and madvise(). This can help to improve the performance by about 85%.
2016 Dec 21
0
[PATCH v6 kernel 3/5] virtio-balloon: speed up inflate/deflate process
...lloon { /* Number of balloon pages we've told the Host we're not using. */ unsigned int num_pages; + /* Pointer to the response header. */ + void *resp_hdr; + /* Pointer to the start address of response data. */ + __le64 *resp_data; + /* Size of response data buffer. */ + unsigned int resp_buf_size; + /* Pointer offset of the response data. */ + unsigned int resp_pos; + /* Bitmap used to save the pfns info */ + unsigned long *page_bitmap[BALLOON_BMAP_COUNT]; + /* Number of split page bitmaps */ + unsigned int nr_page_bmap; + /* Used to record the processed pfn range */ + unsigned long min_pfn...
2017 Mar 03
0
[PATCH v7 kernel 3/5] virtio-balloon: implementation of VIRTIO_BALLOON_F_CHUNK_TRANSFER
...balloon pages we've told the Host we're not using. */ unsigned int num_pages; + /* Pointer to the response header. */ + struct virtio_balloon_resp_hdr resp_hdr; + /* Pointer to the start address of response data. */ + __le64 *resp_data; + /* Size of response data buffer. */ + unsigned int resp_buf_size; + /* Pointer offset of the response data. */ + unsigned int resp_pos; + /* Bitmap used to save the pfns info */ + unsigned long *page_bitmap[PAGE_BMAP_COUNT_MAX]; + /* Number of split page bitmaps */ + unsigned int nr_page_bmap; + /* Used to record the processed pfn range */ + unsigned long min_pf...
2017 Mar 03
10
[PATCH v7 kernel 0/5] Extend virtio-balloon for fast (de)inflating & fast live migration
Take over this work from Liang. This patch series implements two optimizations: 1) transfer pages in chuncks between the guest and host; 1) transfer the guest unused pages to the host so that they can be skipped to migrate in live migration. Please check patch 0003 for more details about optimization 1). For an idle guest with 8GB RAM, optimization 2) can help shorten the total live migration
2017 Mar 03
10
[PATCH v7 kernel 0/5] Extend virtio-balloon for fast (de)inflating & fast live migration
Take over this work from Liang. This patch series implements two optimizations: 1) transfer pages in chuncks between the guest and host; 1) transfer the guest unused pages to the host so that they can be skipped to migrate in live migration. Please check patch 0003 for more details about optimization 1). For an idle guest with 8GB RAM, optimization 2) can help shorten the total live migration
2017 Mar 16
0
[PATCH kernel v8 2/4] virtio-balloon: VIRTIO_BALLOON_F_CHUNK_TRANSFER
...n pages we've told the Host we're not using. */ unsigned int num_pages; + /* Pointer to the response header. */ + struct virtio_balloon_resp_hdr *resp_hdr; + /* Pointer to the start address of response data. */ + resp_data_t *resp_data; + /* Size of response data buffer. */ + unsigned int resp_buf_size; + /* Pointer offset of the response data. */ + unsigned int resp_pos; + /* Bitmap used to record pages */ + unsigned long *page_bmap[PAGE_BMAP_COUNT_MAX]; + /* Number of split page bmaps */ + unsigned int page_bmaps; + + /* + * The allocated page_bmap size may be smaller than the pfn range of +...
2017 Mar 08
3
[PATCH v7 kernel 3/5] virtio-balloon: implementation of VIRTIO_BALLOON_F_CHUNK_TRANSFER
...st we're not using. */ > unsigned int num_pages; > + /* Pointer to the response header. */ > + struct virtio_balloon_resp_hdr resp_hdr; > + /* Pointer to the start address of response data. */ > + __le64 *resp_data; > + /* Size of response data buffer. */ > + unsigned int resp_buf_size; > + /* Pointer offset of the response data. */ > + unsigned int resp_pos; > + /* Bitmap used to save the pfns info */ > + unsigned long *page_bitmap[PAGE_BMAP_COUNT_MAX]; > + /* Number of split page bitmaps */ > + unsigned int nr_page_bmap; > + /* Used to record the processed...
2017 Mar 08
3
[PATCH v7 kernel 3/5] virtio-balloon: implementation of VIRTIO_BALLOON_F_CHUNK_TRANSFER
...st we're not using. */ > unsigned int num_pages; > + /* Pointer to the response header. */ > + struct virtio_balloon_resp_hdr resp_hdr; > + /* Pointer to the start address of response data. */ > + __le64 *resp_data; > + /* Size of response data buffer. */ > + unsigned int resp_buf_size; > + /* Pointer offset of the response data. */ > + unsigned int resp_pos; > + /* Bitmap used to save the pfns info */ > + unsigned long *page_bitmap[PAGE_BMAP_COUNT_MAX]; > + /* Number of split page bitmaps */ > + unsigned int nr_page_bmap; > + /* Used to record the processed...
2017 Mar 10
0
[virtio-dev] Re: [PATCH v7 kernel 3/5] virtio-balloon: implementation of VIRTIO_BALLOON_F_CHUNK_TRANSFER
...t;> unsigned int num_pages; >> + /* Pointer to the response header. */ >> + struct virtio_balloon_resp_hdr resp_hdr; >> + /* Pointer to the start address of response data. */ >> + __le64 *resp_data; >> + /* Size of response data buffer. */ >> + unsigned int resp_buf_size; >> + /* Pointer offset of the response data. */ >> + unsigned int resp_pos; >> + /* Bitmap used to save the pfns info */ >> + unsigned long *page_bitmap[PAGE_BMAP_COUNT_MAX]; >> + /* Number of split page bitmaps */ >> + unsigned int nr_page_bmap; >> + /* U...