/kernel/events/ |
D | ring_buffer.c | 127 if (unlikely(!rb->nr_pages)) in perf_output_begin() 174 handle->page = (offset >> page_shift) & (rb->nr_pages - 1); in perf_output_begin() 254 if (pgoff > rb->nr_pages) in perf_mmap_to_page() 276 struct ring_buffer *rb_alloc(int nr_pages, long watermark, int cpu, int flags) in rb_alloc() argument 283 size += nr_pages * sizeof(void *); in rb_alloc() 293 for (i = 0; i < nr_pages; i++) { in rb_alloc() 299 rb->nr_pages = nr_pages; in rb_alloc() 331 for (i = 0; i < rb->nr_pages; i++) in rb_free() 339 return rb->nr_pages << page_order(rb); in data_page_nr() 382 struct ring_buffer *rb_alloc(int nr_pages, long watermark, int cpu, int flags) in rb_alloc() argument [all …]
|
D | internal.h | 18 int nr_pages; /* nr of data pages */ member 44 rb_alloc(int nr_pages, long watermark, int cpu, int flags); 81 return rb->nr_pages << (PAGE_SHIFT + page_order(rb)); in perf_data_size() 104 handle->page &= rb->nr_pages - 1; \
|
D | core.c | 4433 unsigned long nr_pages; in perf_mmap() local 4449 nr_pages = (vma_size / PAGE_SIZE) - 1; in perf_mmap() 4455 if (nr_pages != 0 && !is_power_of_2(nr_pages)) in perf_mmap() 4458 if (vma_size != PAGE_SIZE * (1 + nr_pages)) in perf_mmap() 4468 if (event->rb->nr_pages != nr_pages) { in perf_mmap() 4486 user_extra = nr_pages + 1; in perf_mmap() 4515 rb = rb_alloc(nr_pages, in perf_mmap()
|
/kernel/power/ |
D | snapshot.c | 1377 static unsigned long preallocate_image_pages(unsigned long nr_pages, gfp_t mask) in preallocate_image_pages() argument 1381 while (nr_pages > 0) { in preallocate_image_pages() 1392 nr_pages--; in preallocate_image_pages() 1399 static unsigned long preallocate_image_memory(unsigned long nr_pages, in preallocate_image_memory() argument 1408 if (nr_pages < alloc) in preallocate_image_memory() 1409 alloc = nr_pages; in preallocate_image_memory() 1415 static unsigned long preallocate_image_highmem(unsigned long nr_pages) in preallocate_image_highmem() argument 1417 return preallocate_image_pages(nr_pages, GFP_IMAGE | __GFP_HIGHMEM); in preallocate_image_highmem() 1430 static unsigned long preallocate_highmem_fraction(unsigned long nr_pages, in preallocate_highmem_fraction() argument 1434 unsigned long alloc = __fraction(nr_pages, highmem, total); in preallocate_highmem_fraction() [all …]
|
D | swap.c | 445 int nr_pages; in save_image() local 456 nr_pages = 0; in save_image() 466 if (!(nr_pages % m)) in save_image() 468 nr_pages / m * 10); in save_image() 469 nr_pages++; in save_image() 580 int nr_pages; in save_image_lzo() local 675 nr_pages = 0; in save_image_lzo() 691 if (!(nr_pages % m)) in save_image_lzo() 695 nr_pages / m * 10); in save_image_lzo() 696 nr_pages++; in save_image_lzo() [all …]
|
D | hibernate.c | 236 unsigned nr_pages, char *msg) in swsusp_show_speed() argument 252 k = nr_pages * (PAGE_SIZE / 1024); in swsusp_show_speed()
|
/kernel/trace/ |
D | ring_buffer.c | 473 unsigned long nr_pages; member 1173 static int __rb_allocate_pages(long nr_pages, struct list_head *pages, int cpu) in __rb_allocate_pages() argument 1178 for (i = 0; i < nr_pages; i++) { in __rb_allocate_pages() 1213 unsigned long nr_pages) in rb_allocate_pages() argument 1217 WARN_ON(!nr_pages); in rb_allocate_pages() 1219 if (__rb_allocate_pages(nr_pages, &pages, cpu_buffer->cpu)) in rb_allocate_pages() 1230 cpu_buffer->nr_pages = nr_pages; in rb_allocate_pages() 1238 rb_allocate_cpu_buffer(struct ring_buffer *buffer, long nr_pages, int cpu) in rb_allocate_cpu_buffer() argument 1278 ret = rb_allocate_pages(cpu_buffer, nr_pages); in rb_allocate_cpu_buffer() 1338 long nr_pages; in __ring_buffer_alloc() local [all …]
|
D | trace.c | 4772 .nr_pages = 0, /* This gets updated below. */ in tracing_splice_read_pipe() 4839 spd.nr_pages = i; in tracing_splice_read_pipe() 4996 int nr_pages = 1; in tracing_mark_write() local 5031 nr_pages = 2; in tracing_mark_write() 5036 ret = get_user_pages_fast(addr, nr_pages, 0, pages); in tracing_mark_write() 5037 if (ret < nr_pages) { in tracing_mark_write() 5044 for (i = 0; i < nr_pages; i++) in tracing_mark_write() 5061 if (nr_pages == 2) { in tracing_mark_write() 5081 for (i = nr_pages - 1; i >= 0; i--) { in tracing_mark_write() 5725 spd.nr_pages++; in tracing_buffers_splice_read() [all …]
|
/kernel/ |
D | relay.c | 1218 unsigned int pidx, poff, total_len, subbuf_pages, nr_pages; in subbuf_splice_actor() local 1231 .nr_pages = 0, in subbuf_splice_actor() 1254 nr_pages = min_t(unsigned int, subbuf_pages, spd.nr_pages_max); in subbuf_splice_actor() 1256 for (total_len = 0; spd.nr_pages < nr_pages; spd.nr_pages++) { in subbuf_splice_actor() 1266 spd.pages[spd.nr_pages] = rbuf->page_array[pidx]; in subbuf_splice_actor() 1267 spd.partial[spd.nr_pages].offset = poff; in subbuf_splice_actor() 1274 spd.partial[spd.nr_pages].len = this_len; in subbuf_splice_actor() 1275 spd.partial[spd.nr_pages].private = private; in subbuf_splice_actor() 1283 spd.nr_pages++; in subbuf_splice_actor() 1289 if (!spd.nr_pages) in subbuf_splice_actor()
|
D | compat.c | 1085 COMPAT_SYSCALL_DEFINE6(move_pages, pid_t, pid, compat_ulong_t, nr_pages, in COMPAT_SYSCALL_DEFINE6() argument 1094 pages = compat_alloc_user_space(nr_pages * sizeof(void *)); in COMPAT_SYSCALL_DEFINE6() 1095 for (i = 0; i < nr_pages; i++) { in COMPAT_SYSCALL_DEFINE6() 1102 return sys_move_pages(pid, nr_pages, pages, nodes, status, flags); in COMPAT_SYSCALL_DEFINE6()
|
D | resource.c | 452 int walk_system_ram_range(unsigned long start_pfn, unsigned long nr_pages, in walk_system_ram_range() argument 461 res.end = ((u64)(start_pfn + nr_pages) << PAGE_SHIFT) - 1; in walk_system_ram_range() 480 static int __is_ram(unsigned long pfn, unsigned long nr_pages, void *arg) in __is_ram() argument
|