Displaying 20 results from an estimated 172 matches for "update_stat".
Did you mean:
update_stats
2017 Mar 23
3
[PATCH] virtio_balloon: prevent uninitialized variable use
...vers/virtio/virtio_balloon.c
index 4e1191508228..cd5c54e2003d 100644
--- a/drivers/virtio/virtio_balloon.c
+++ b/drivers/virtio/virtio_balloon.c
@@ -254,12 +254,14 @@ static void update_balloon_stats(struct virtio_balloon *vb)
available = si_mem_available();
+#ifdef CONFIG_VM_EVENT_COUNTERS
update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_IN,
pages_to_bytes(events[PSWPIN]));
update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_OUT,
pages_to_bytes(events[PSWPOUT]));
update_stat(vb, idx++, VIRTIO_BALLOON_S_MAJFLT, events[PGMAJFAULT]);
update_stat(vb, idx++, VIRTIO_BALLOON_S_MINFLT, events[PGFAU...
2017 Mar 23
3
[PATCH] virtio_balloon: prevent uninitialized variable use
...vers/virtio/virtio_balloon.c
index 4e1191508228..cd5c54e2003d 100644
--- a/drivers/virtio/virtio_balloon.c
+++ b/drivers/virtio/virtio_balloon.c
@@ -254,12 +254,14 @@ static void update_balloon_stats(struct virtio_balloon *vb)
available = si_mem_available();
+#ifdef CONFIG_VM_EVENT_COUNTERS
update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_IN,
pages_to_bytes(events[PSWPIN]));
update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_OUT,
pages_to_bytes(events[PSWPOUT]));
update_stat(vb, idx++, VIRTIO_BALLOON_S_MAJFLT, events[PGMAJFAULT]);
update_stat(vb, idx++, VIRTIO_BALLOON_S_MINFLT, events[PGFAU...
2017 Mar 24
2
[PATCH] virtio_balloon: prevent uninitialized variable use
...; --- a/drivers/virtio/virtio_balloon.c
>> +++ b/drivers/virtio/virtio_balloon.c
>> @@ -254,12 +254,14 @@ static void update_balloon_stats(struct virtio_balloon *vb)
>>
>> available = si_mem_available();
>>
>> +#ifdef CONFIG_VM_EVENT_COUNTERS
>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_IN,
>> pages_to_bytes(events[PSWPIN]));
>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_OUT,
>> pages_to_bytes(events[PSWPOUT]));
>> update_stat(vb, idx++, VIRTIO_BALLOON...
2017 Mar 24
2
[PATCH] virtio_balloon: prevent uninitialized variable use
...; --- a/drivers/virtio/virtio_balloon.c
>> +++ b/drivers/virtio/virtio_balloon.c
>> @@ -254,12 +254,14 @@ static void update_balloon_stats(struct virtio_balloon *vb)
>>
>> available = si_mem_available();
>>
>> +#ifdef CONFIG_VM_EVENT_COUNTERS
>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_IN,
>> pages_to_bytes(events[PSWPIN]));
>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_OUT,
>> pages_to_bytes(events[PSWPOUT]));
>> update_stat(vb, idx++, VIRTIO_BALLOON...
2018 Mar 19
2
[PATCH v2] virtio_balloon: export hugetlb page allocation counts
...ivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c
index dfe5684..6b237e3 100644
--- a/drivers/virtio/virtio_balloon.c
+++ b/drivers/virtio/virtio_balloon.c
@@ -272,6 +272,12 @@ static unsigned int update_balloon_stats(struct virtio_balloon *vb)
pages_to_bytes(events[PSWPOUT]));
update_stat(vb, idx++, VIRTIO_BALLOON_S_MAJFLT, events[PGMAJFAULT]);
update_stat(vb, idx++, VIRTIO_BALLOON_S_MINFLT, events[PGFAULT]);
+#ifdef CONFIG_HUGETLB_PAGE
+ update_stat(vb, idx++, VIRTIO_BALLOON_S_HTLB_PGALLOC,
+ events[HTLB_BUDDY_PGALLOC]);
+ update_stat(vb, idx++, VIRTIO_BALLOON_S_HTLB_PGFAIL,...
2018 Mar 19
2
[PATCH v2] virtio_balloon: export hugetlb page allocation counts
...ivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c
index dfe5684..6b237e3 100644
--- a/drivers/virtio/virtio_balloon.c
+++ b/drivers/virtio/virtio_balloon.c
@@ -272,6 +272,12 @@ static unsigned int update_balloon_stats(struct virtio_balloon *vb)
pages_to_bytes(events[PSWPOUT]));
update_stat(vb, idx++, VIRTIO_BALLOON_S_MAJFLT, events[PGMAJFAULT]);
update_stat(vb, idx++, VIRTIO_BALLOON_S_MINFLT, events[PGFAULT]);
+#ifdef CONFIG_HUGETLB_PAGE
+ update_stat(vb, idx++, VIRTIO_BALLOON_S_HTLB_PGALLOC,
+ events[HTLB_BUDDY_PGALLOC]);
+ update_stat(vb, idx++, VIRTIO_BALLOON_S_HTLB_PGFAIL,...
2017 Mar 24
2
[PATCH] virtio_balloon: prevent uninitialized variable use
.../drivers/virtio/virtio_balloon.c
> >>> @@ -254,12 +254,14 @@ static void update_balloon_stats(struct virtio_balloon *vb)
> >>>
> >>> available = si_mem_available();
> >>>
> >>> +#ifdef CONFIG_VM_EVENT_COUNTERS
> >>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_IN,
> >>> pages_to_bytes(events[PSWPIN]));
> >>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_OUT,
> >>> pages_to_bytes(events[PSWPOUT]));
> >>> u...
2017 Mar 24
2
[PATCH] virtio_balloon: prevent uninitialized variable use
.../drivers/virtio/virtio_balloon.c
> >>> @@ -254,12 +254,14 @@ static void update_balloon_stats(struct virtio_balloon *vb)
> >>>
> >>> available = si_mem_available();
> >>>
> >>> +#ifdef CONFIG_VM_EVENT_COUNTERS
> >>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_IN,
> >>> pages_to_bytes(events[PSWPIN]));
> >>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_OUT,
> >>> pages_to_bytes(events[PSWPOUT]));
> >>> u...
2018 Feb 17
2
[PATCH] virtio_balloon: export huge page allocation statistics
...ivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c
index dfe5684..6b237e3 100644
--- a/drivers/virtio/virtio_balloon.c
+++ b/drivers/virtio/virtio_balloon.c
@@ -272,6 +272,12 @@ static unsigned int update_balloon_stats(struct virtio_balloon *vb)
pages_to_bytes(events[PSWPOUT]));
update_stat(vb, idx++, VIRTIO_BALLOON_S_MAJFLT, events[PGMAJFAULT]);
update_stat(vb, idx++, VIRTIO_BALLOON_S_MINFLT, events[PGFAULT]);
+#ifdef CONFIG_HUGETLB_PAGE
+ update_stat(vb, idx++, VIRTIO_BALLOON_S_HTLB_PGALLOC,
+ events[HTLB_BUDDY_PGALLOC]);
+ update_stat(vb, idx++, VIRTIO_BALLOON_S_HTLB_PGFAIL,...
2018 Feb 17
2
[PATCH] virtio_balloon: export huge page allocation statistics
...ivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c
index dfe5684..6b237e3 100644
--- a/drivers/virtio/virtio_balloon.c
+++ b/drivers/virtio/virtio_balloon.c
@@ -272,6 +272,12 @@ static unsigned int update_balloon_stats(struct virtio_balloon *vb)
pages_to_bytes(events[PSWPOUT]));
update_stat(vb, idx++, VIRTIO_BALLOON_S_MAJFLT, events[PGMAJFAULT]);
update_stat(vb, idx++, VIRTIO_BALLOON_S_MINFLT, events[PGFAULT]);
+#ifdef CONFIG_HUGETLB_PAGE
+ update_stat(vb, idx++, VIRTIO_BALLOON_S_HTLB_PGALLOC,
+ events[HTLB_BUDDY_PGALLOC]);
+ update_stat(vb, idx++, VIRTIO_BALLOON_S_HTLB_PGFAIL,...
2018 Mar 20
2
[PATCH v2] virtio_balloon: export hugetlb page allocation counts
...balloon.c
>> index dfe5684..6b237e3 100644
>> --- a/drivers/virtio/virtio_balloon.c
>> +++ b/drivers/virtio/virtio_balloon.c
>> @@ -272,6 +272,12 @@ static unsigned int update_balloon_stats(struct virtio_balloon *vb)
>> pages_to_bytes(events[PSWPOUT]));
>> update_stat(vb, idx++, VIRTIO_BALLOON_S_MAJFLT, events[PGMAJFAULT]);
>> update_stat(vb, idx++, VIRTIO_BALLOON_S_MINFLT, events[PGFAULT]);
>> +#ifdef CONFIG_HUGETLB_PAGE
>> + update_stat(vb, idx++, VIRTIO_BALLOON_S_HTLB_PGALLOC,
>> + events[HTLB_BUDDY_PGALLOC]);
>> + update_...
2017 Mar 28
1
[PATCH] virtio_balloon: prevent uninitialized variable use
...;> @@ -254,12 +254,14 @@ static void update_balloon_stats(struct virtio_balloon *vb)
> >> >>>
> >> >>> available = si_mem_available();
> >> >>>
> >> >>> +#ifdef CONFIG_VM_EVENT_COUNTERS
> >> >>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_IN,
> >> >>> pages_to_bytes(events[PSWPIN]));
> >> >>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_OUT,
> >> >>> pages_to_bytes(events[PSWPOUT]))...
2017 Mar 28
1
[PATCH] virtio_balloon: prevent uninitialized variable use
...;> @@ -254,12 +254,14 @@ static void update_balloon_stats(struct virtio_balloon *vb)
> >> >>>
> >> >>> available = si_mem_available();
> >> >>>
> >> >>> +#ifdef CONFIG_VM_EVENT_COUNTERS
> >> >>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_IN,
> >> >>> pages_to_bytes(events[PSWPIN]));
> >> >>> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_OUT,
> >> >>> pages_to_bytes(events[PSWPOUT]))...
2018 Mar 22
2
[virtio-dev] Re: [PATCH v2] virtio_balloon: export hugetlb page allocation counts
...; > > --- a/drivers/virtio/virtio_balloon.c
> > > > +++ b/drivers/virtio/virtio_balloon.c
> > > > @@ -272,6 +272,12 @@ static unsigned int update_balloon_stats(struct virtio_balloon *vb)
> > > > pages_to_bytes(events[PSWPOUT]));
> > > > update_stat(vb, idx++, VIRTIO_BALLOON_S_MAJFLT, events[PGMAJFAULT]);
> > > > update_stat(vb, idx++, VIRTIO_BALLOON_S_MINFLT, events[PGFAULT]);
> > > > +#ifdef CONFIG_HUGETLB_PAGE
> > > > + update_stat(vb, idx++, VIRTIO_BALLOON_S_HTLB_PGALLOC,
> > > > + ev...
2018 Apr 09
2
[virtio-dev] Re: [PATCH v2] virtio_balloon: export hugetlb page allocation counts
...gt;>> +++ b/drivers/virtio/virtio_balloon.c
>>>>>> @@ -272,6 +272,12 @@ static unsigned int
>>>>>> update_balloon_stats(struct virtio_balloon *vb)
>>>>>> ?????????????????? pages_to_bytes(events[PSWPOUT]));
>>>>>> ?????? update_stat(vb, idx++, VIRTIO_BALLOON_S_MAJFLT,
>>>>>> events[PGMAJFAULT]);
>>>>>> ?????? update_stat(vb, idx++, VIRTIO_BALLOON_S_MINFLT,
>>>>>> events[PGFAULT]);
>>>>>> +#ifdef CONFIG_HUGETLB_PAGE
>>>>>> +??? update_st...
2011 Aug 16
1
[PATCH] virtio-blk: Add stats VQ to collect information about devices
.... */
unsigned int sg_elems;
+ /* Block statistics */
+ int need_stats_update;
+ struct virtio_blk_stat stats[VIRTIO_BLK_S_NR];
+
/* Scatterlist: can be too big for stack. */
struct scatterlist sg[/*sg_elems*/];
};
@@ -48,6 +52,75 @@ struct virtblk_req
u8 status;
};
+static inline void update_stat(struct virtio_blk *vb, int idx,
+ u16 tag, u64 val)
+{
+ BUG_ON(idx >= VIRTIO_BLK_S_NR);
+ vb->stats[idx].tag = tag;
+ vb->stats[idx].val = val;
+}
+
+static void update_blk_stats(struct virtio_blk *vb)
+{
+ struct hd_struct *p = disk_get_part(vb->disk, 0);
+ int cpu;
+ int idx...
2011 Aug 16
1
[PATCH] virtio-blk: Add stats VQ to collect information about devices
.... */
unsigned int sg_elems;
+ /* Block statistics */
+ int need_stats_update;
+ struct virtio_blk_stat stats[VIRTIO_BLK_S_NR];
+
/* Scatterlist: can be too big for stack. */
struct scatterlist sg[/*sg_elems*/];
};
@@ -48,6 +52,75 @@ struct virtblk_req
u8 status;
};
+static inline void update_stat(struct virtio_blk *vb, int idx,
+ u16 tag, u64 val)
+{
+ BUG_ON(idx >= VIRTIO_BLK_S_NR);
+ vb->stats[idx].tag = tag;
+ vb->stats[idx].val = val;
+}
+
+static void update_blk_stats(struct virtio_blk *vb)
+{
+ struct hd_struct *p = disk_get_part(vb->disk, 0);
+ int cpu;
+ int idx...
2018 Apr 12
2
[virtio-dev] Re: [PATCH v2] virtio_balloon: export hugetlb page allocation counts
.../virtio_balloon.c
>>>>>>>> @@ -272,6 +272,12 @@ static unsigned int
>>>>>>>> update_balloon_stats(struct virtio_balloon *vb)
>>>>>>>> ?????????????????? pages_to_bytes(events[PSWPOUT]));
>>>>>>>> ?????? update_stat(vb, idx++, VIRTIO_BALLOON_S_MAJFLT,
>>>>>>>> events[PGMAJFAULT]);
>>>>>>>> ?????? update_stat(vb, idx++, VIRTIO_BALLOON_S_MINFLT,
>>>>>>>> events[PGFAULT]);
>>>>>>>> +#ifdef CONFIG_HUGETLB_PAGE
>>...
2017 Oct 19
2
[PATCH v2 1/1] virtio_balloon: include buffers and cached memory statistics
...s(events);
> si_meminfo(&i);
>
> available = si_mem_available();
>
> + cached = global_node_page_state(NR_FILE_PAGES) -
> + total_swapcache_pages() - i.bufferram;
> + if (cached < 0)
> + cached = 0;
> +
> +
> #ifdef CONFIG_VM_EVENT_COUNTERS
> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_IN,
> pages_to_bytes(events[PSWPIN]));
> @@ -264,6 +271,10 @@ static unsigned int update_balloon_stats(struct virtio_balloon *vb)
> pages_to_bytes(i.totalram));
> update_stat(vb, idx++, VIRTIO_BALLOON_S_AVAIL,
> pages_to_bytes(availab...
2017 Oct 19
2
[PATCH v2 1/1] virtio_balloon: include buffers and cached memory statistics
...s(events);
> si_meminfo(&i);
>
> available = si_mem_available();
>
> + cached = global_node_page_state(NR_FILE_PAGES) -
> + total_swapcache_pages() - i.bufferram;
> + if (cached < 0)
> + cached = 0;
> +
> +
> #ifdef CONFIG_VM_EVENT_COUNTERS
> update_stat(vb, idx++, VIRTIO_BALLOON_S_SWAP_IN,
> pages_to_bytes(events[PSWPIN]));
> @@ -264,6 +271,10 @@ static unsigned int update_balloon_stats(struct virtio_balloon *vb)
> pages_to_bytes(i.totalram));
> update_stat(vb, idx++, VIRTIO_BALLOON_S_AVAIL,
> pages_to_bytes(availab...