Lines Matching refs:nr_pages
458 unsigned long nr_pages; member
782 return buffer->buffers[cpu]->nr_pages; in ring_buffer_nr_pages()
819 size_t nr_pages; in full_hit() local
822 nr_pages = cpu_buffer->nr_pages; in full_hit()
823 if (!nr_pages || !full) in full_hit()
833 return (dirty * 100) >= (full * nr_pages); in full_hit()
1523 long nr_pages, struct list_head *pages) in __rb_allocate_pages() argument
1538 if (i < nr_pages) in __rb_allocate_pages()
1559 for (i = 0; i < nr_pages; i++) { in __rb_allocate_pages()
1597 unsigned long nr_pages) in rb_allocate_pages() argument
1601 WARN_ON(!nr_pages); in rb_allocate_pages()
1603 if (__rb_allocate_pages(cpu_buffer, nr_pages, &pages)) in rb_allocate_pages()
1614 cpu_buffer->nr_pages = nr_pages; in rb_allocate_pages()
1622 rb_allocate_cpu_buffer(struct trace_buffer *buffer, long nr_pages, int cpu) in rb_allocate_cpu_buffer() argument
1662 ret = rb_allocate_pages(cpu_buffer, nr_pages); in rb_allocate_cpu_buffer()
1722 long nr_pages; in __ring_buffer_alloc() local
1736 nr_pages = DIV_ROUND_UP(size, BUF_PAGE_SIZE); in __ring_buffer_alloc()
1745 if (nr_pages < 2) in __ring_buffer_alloc()
1746 nr_pages = 2; in __ring_buffer_alloc()
1758 buffer->buffers[cpu] = rb_allocate_cpu_buffer(buffer, nr_pages, cpu); in __ring_buffer_alloc()
1860 rb_remove_pages(struct ring_buffer_per_cpu *cpu_buffer, unsigned long nr_pages) in rb_remove_pages() argument
1896 for (nr_removed = 0; nr_removed < nr_pages; nr_removed++) { in rb_remove_pages()
2060 cpu_buffer->nr_pages += cpu_buffer->nr_pages_to_update; in rb_update_pages()
2085 unsigned long nr_pages; in ring_buffer_resize() local
2101 nr_pages = DIV_ROUND_UP(size, BUF_PAGE_SIZE); in ring_buffer_resize()
2104 if (nr_pages < 2) in ring_buffer_resize()
2105 nr_pages = 2; in ring_buffer_resize()
2129 cpu_buffer->nr_pages_to_update = nr_pages - in ring_buffer_resize()
2130 cpu_buffer->nr_pages; in ring_buffer_resize()
2187 if (nr_pages == cpu_buffer->nr_pages) in ring_buffer_resize()
2200 cpu_buffer->nr_pages_to_update = nr_pages - in ring_buffer_resize()
2201 cpu_buffer->nr_pages; in ring_buffer_resize()
2985 max_count = cpu_buffer->nr_pages * 100; in rb_set_commit_to_write()
5342 return BUF_PAGE_SIZE * buffer->buffers[cpu]->nr_pages; in ring_buffer_size()
5616 if (cpu_buffer_a->nr_pages != cpu_buffer_b->nr_pages) in ring_buffer_swap_cpu()
5985 unsigned long nr_pages; in trace_rb_cpu_prepare() local
5991 nr_pages = 0; in trace_rb_cpu_prepare()
5996 if (nr_pages == 0) in trace_rb_cpu_prepare()
5997 nr_pages = buffer->buffers[cpu_i]->nr_pages; in trace_rb_cpu_prepare()
5998 if (nr_pages != buffer->buffers[cpu_i]->nr_pages) { in trace_rb_cpu_prepare()
6005 nr_pages = 2; in trace_rb_cpu_prepare()
6007 rb_allocate_cpu_buffer(buffer, nr_pages, cpu); in trace_rb_cpu_prepare()
6028 size += rb->nr_pages * sizeof(unsigned long); in trace_buffer_pack_size()
6051 unsigned long flags, nr_pages; in trace_buffer_pack() local
6066 nr_pages = rb->nr_pages; in trace_buffer_pack()
6068 pack->total_pages += nr_pages + 1; in trace_buffer_pack()
6072 cpu_pack->nr_pages = nr_pages; in trace_buffer_pack()
6074 for (j = 0; j < nr_pages; j++) { in trace_buffer_pack()