Lines Matching refs:nr_pages
467 unsigned long nr_pages; member
816 return buffer->buffers[cpu]->nr_pages; in ring_buffer_nr_pages()
853 size_t nr_pages; in full_hit() local
856 nr_pages = cpu_buffer->nr_pages; in full_hit()
857 if (!nr_pages || !full) in full_hit()
867 return (dirty * 100) >= (full * nr_pages); in full_hit()
1557 long nr_pages, struct list_head *pages) in __rb_allocate_pages() argument
1572 if (i < nr_pages) in __rb_allocate_pages()
1593 for (i = 0; i < nr_pages; i++) { in __rb_allocate_pages()
1631 unsigned long nr_pages) in rb_allocate_pages() argument
1635 WARN_ON(!nr_pages); in rb_allocate_pages()
1637 if (__rb_allocate_pages(cpu_buffer, nr_pages, &pages)) in rb_allocate_pages()
1648 cpu_buffer->nr_pages = nr_pages; in rb_allocate_pages()
1656 rb_allocate_cpu_buffer(struct trace_buffer *buffer, long nr_pages, int cpu) in rb_allocate_cpu_buffer() argument
1696 ret = rb_allocate_pages(cpu_buffer, nr_pages); in rb_allocate_cpu_buffer()
1756 long nr_pages; in __ring_buffer_alloc() local
1770 nr_pages = DIV_ROUND_UP(size, BUF_PAGE_SIZE); in __ring_buffer_alloc()
1779 if (nr_pages < 2) in __ring_buffer_alloc()
1780 nr_pages = 2; in __ring_buffer_alloc()
1792 buffer->buffers[cpu] = rb_allocate_cpu_buffer(buffer, nr_pages, cpu); in __ring_buffer_alloc()
1894 rb_remove_pages(struct ring_buffer_per_cpu *cpu_buffer, unsigned long nr_pages) in rb_remove_pages() argument
1930 for (nr_removed = 0; nr_removed < nr_pages; nr_removed++) { in rb_remove_pages()
2094 cpu_buffer->nr_pages += cpu_buffer->nr_pages_to_update; in rb_update_pages()
2119 unsigned long nr_pages; in ring_buffer_resize() local
2135 nr_pages = DIV_ROUND_UP(size, BUF_PAGE_SIZE); in ring_buffer_resize()
2138 if (nr_pages < 2) in ring_buffer_resize()
2139 nr_pages = 2; in ring_buffer_resize()
2163 cpu_buffer->nr_pages_to_update = nr_pages - in ring_buffer_resize()
2164 cpu_buffer->nr_pages; in ring_buffer_resize()
2221 if (nr_pages == cpu_buffer->nr_pages) in ring_buffer_resize()
2234 cpu_buffer->nr_pages_to_update = nr_pages - in ring_buffer_resize()
2235 cpu_buffer->nr_pages; in ring_buffer_resize()
3026 max_count = cpu_buffer->nr_pages * 100; in rb_set_commit_to_write()
5387 return BUF_PAGE_SIZE * buffer->buffers[cpu]->nr_pages; in ring_buffer_size()
5661 if (cpu_buffer_a->nr_pages != cpu_buffer_b->nr_pages) in ring_buffer_swap_cpu()
6030 unsigned long nr_pages; in trace_rb_cpu_prepare() local
6036 nr_pages = 0; in trace_rb_cpu_prepare()
6041 if (nr_pages == 0) in trace_rb_cpu_prepare()
6042 nr_pages = buffer->buffers[cpu_i]->nr_pages; in trace_rb_cpu_prepare()
6043 if (nr_pages != buffer->buffers[cpu_i]->nr_pages) { in trace_rb_cpu_prepare()
6050 nr_pages = 2; in trace_rb_cpu_prepare()
6052 rb_allocate_cpu_buffer(buffer, nr_pages, cpu); in trace_rb_cpu_prepare()
6073 size += rb->nr_pages * sizeof(unsigned long); in trace_buffer_pack_size()
6096 unsigned long flags, nr_pages; in trace_buffer_pack() local
6111 nr_pages = rb->nr_pages; in trace_buffer_pack()
6113 pack->total_pages += nr_pages + 1; in trace_buffer_pack()
6117 cpu_pack->nr_pages = nr_pages; in trace_buffer_pack()
6119 for (j = 0; j < nr_pages; j++) { in trace_buffer_pack()