Displaying 9 results from an estimated 9 matches for "record_unused_pages".
2017 Mar 16
0
[PATCH kernel v8 3/4] mm: add inerface to offer info about unused pages
.../include/linux/mm.h
+++ b/include/linux/mm.h
@@ -1764,6 +1764,9 @@ extern void free_area_init(unsigned long * zones_size);
extern void free_area_init_node(int nid, unsigned long * zones_size,
unsigned long zone_start_pfn, unsigned long *zholes_size);
extern void free_initmem(void);
+extern int record_unused_pages(struct zone **start_zone, int order,
+ __le64 *pages, unsigned int size,
+ unsigned int *pos, bool part_fill);
/*
* Free reserved pages within range [PAGE_ALIGN(start), end & PAGE_MASK)
diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index f3e0c69..b72a7ac 100644
--- a/mm/...
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)
2017 Mar 16
4
[PATCH kernel v8 3/4] mm: add inerface to offer info about unused pages
...ssible? Perhaps
we can put some *small* helpers into page_alloc.c to prevent things
from becoming too ugly.
> --- a/mm/page_alloc.c
> +++ b/mm/page_alloc.c
> @@ -4498,6 +4498,120 @@ void show_free_areas(unsigned int filter)
> show_swap_cache_info();
> }
>
> +static int __record_unused_pages(struct zone *zone, int order,
> + __le64 *buf, unsigned int size,
> + unsigned int *offset, bool part_fill)
> +{
> + unsigned long pfn, flags;
> + int t, ret = 0;
> + struct list_head *curr;
> + __le64 *chunk;
> +
> + if (zone_is_empty(zone))
> + return 0;
>...
2017 Mar 16
4
[PATCH kernel v8 3/4] mm: add inerface to offer info about unused pages
...ssible? Perhaps
we can put some *small* helpers into page_alloc.c to prevent things
from becoming too ugly.
> --- a/mm/page_alloc.c
> +++ b/mm/page_alloc.c
> @@ -4498,6 +4498,120 @@ void show_free_areas(unsigned int filter)
> show_swap_cache_info();
> }
>
> +static int __record_unused_pages(struct zone *zone, int order,
> + __le64 *buf, unsigned int size,
> + unsigned int *offset, bool part_fill)
> +{
> + unsigned long pfn, flags;
> + int t, ret = 0;
> + struct list_head *curr;
> + __le64 *chunk;
> +
> + if (zone_is_empty(zone))
> + return 0;
>...
2017 Mar 17
0
[PATCH kernel v8 3/4] mm: add inerface to offer info about unused pages
...en it will be the caller's
responsibility to format the pfn if they need.
>> --- a/mm/page_alloc.c
>> +++ b/mm/page_alloc.c
>> @@ -4498,6 +4498,120 @@ void show_free_areas(unsigned int filter)
>> show_swap_cache_info();
>> }
>>
>> +static int __record_unused_pages(struct zone *zone, int order,
>> + __le64 *buf, unsigned int size,
>> + unsigned int *offset, bool part_fill)
>> +{
>> + unsigned long pfn, flags;
>> + int t, ret = 0;
>> + struct list_head *curr;
>> + __le64 *chunk;
>> +
>> + if (zone_i...
2017 Mar 16
0
[PATCH kernel v8 4/4] virtio-balloon: VIRTIO_BALLOON_F_HOST_REQ_VQ
...igned long req_id)
+{
+ struct scatterlist sg_in;
+ unsigned int pos = 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...
2017 Mar 29
2
[PATCH kernel v8 3/4] mm: add inerface to offer info about unused pages
...have to see the implementation
to judge it properly.
> > > --- a/mm/page_alloc.c
> > > +++ b/mm/page_alloc.c
> > > @@ -4498,6 +4498,120 @@ void show_free_areas(unsigned int filter)
> > > show_swap_cache_info();
> > > }
> > > +static int __record_unused_pages(struct zone *zone, int order,
> > > + __le64 *buf, unsigned int size,
> > > + unsigned int *offset, bool part_fill)
> > > +{
> > > + unsigned long pfn, flags;
> > > + int t, ret = 0;
> > > + struct list_head *curr;
> > > + __le6...
2017 Mar 29
2
[PATCH kernel v8 3/4] mm: add inerface to offer info about unused pages
...have to see the implementation
to judge it properly.
> > > --- a/mm/page_alloc.c
> > > +++ b/mm/page_alloc.c
> > > @@ -4498,6 +4498,120 @@ void show_free_areas(unsigned int filter)
> > > show_swap_cache_info();
> > > }
> > > +static int __record_unused_pages(struct zone *zone, int order,
> > > + __le64 *buf, unsigned int size,
> > > + unsigned int *offset, bool part_fill)
> > > +{
> > > + unsigned long pfn, flags;
> > > + int t, ret = 0;
> > > + struct list_head *curr;
> > > + __le6...