Lines Matching refs:size
464 int __trace_puts(unsigned long ip, const char *str, int size) in __trace_puts() argument
481 alloc = sizeof(*entry) + size + 2; /* possible \n added */ in __trace_puts()
493 memcpy(&entry->buf, str, size); in __trace_puts()
496 if (entry->buf[size - 1] != '\n') { in __trace_puts()
497 entry->buf[size] = '\n'; in __trace_puts()
498 entry->buf[size + 1] = '\0'; in __trace_puts()
500 entry->buf[size] = '\0'; in __trace_puts()
505 return size; in __trace_puts()
520 int size = sizeof(struct bputs_entry); in __trace_bputs() local
533 event = trace_buffer_lock_reserve(buffer, TRACE_BPUTS, size, in __trace_bputs()
838 int trace_parser_get_init(struct trace_parser *parser, int size) in trace_parser_get_init() argument
842 parser->buffer = kmalloc(size, GFP_KERNEL); in trace_parser_get_init()
846 parser->size = size; in trace_parser_get_init()
912 if (parser->idx < parser->size - 1) in trace_get_user()
929 } else if (parser->idx < parser->size - 1) { in trace_get_user()
1800 int size = FTRACE_STACK_ENTRIES; in __ftrace_trace_stack() local
1831 if (trace.nr_entries > size) in __ftrace_trace_stack()
1832 size = trace.nr_entries; in __ftrace_trace_stack()
1837 size *= sizeof(unsigned long); in __ftrace_trace_stack()
1840 sizeof(*entry) + size, flags, pc); in __ftrace_trace_stack()
1845 memset(&entry->caller, 0, size); in __ftrace_trace_stack()
1859 entry->size = trace.nr_entries; in __ftrace_trace_stack()
2135 int len = 0, size, pc; in trace_vbprintk() local
2158 size = sizeof(*entry) + sizeof(u32) * len; in trace_vbprintk()
2160 event = trace_buffer_lock_reserve(buffer, TRACE_BPRINT, size, in trace_vbprintk()
2188 int len = 0, size, pc; in __trace_array_vprintk() local
2214 size = sizeof(*entry) + len + 1; in __trace_array_vprintk()
2215 event = trace_buffer_lock_reserve(buffer, TRACE_PRINT, size, in __trace_array_vprintk()
4116 unsigned long size, int cpu) in __tracing_resize_ring_buffer() argument
4131 ret = ring_buffer_resize(tr->trace_buffer.buffer, size, cpu); in __tracing_resize_ring_buffer()
4140 ret = ring_buffer_resize(tr->max_buffer.buffer, size, cpu); in __tracing_resize_ring_buffer()
4166 set_buffer_entries(&tr->max_buffer, size); in __tracing_resize_ring_buffer()
4168 per_cpu_ptr(tr->max_buffer.data, cpu)->entries = size; in __tracing_resize_ring_buffer()
4174 set_buffer_entries(&tr->trace_buffer, size); in __tracing_resize_ring_buffer()
4176 per_cpu_ptr(tr->trace_buffer.data, cpu)->entries = size; in __tracing_resize_ring_buffer()
4182 unsigned long size, int cpu_id) in tracing_resize_ring_buffer() argument
4184 int ret = size; in tracing_resize_ring_buffer()
4196 ret = __tracing_resize_ring_buffer(tr, size, cpu_id); in tracing_resize_ring_buffer()
4869 unsigned long size; in tracing_entries_read() local
4871 size = 0; in tracing_entries_read()
4876 if (size == 0) in tracing_entries_read()
4877 size = per_cpu_ptr(tr->trace_buffer.data, cpu)->entries; in tracing_entries_read()
4878 if (size != per_cpu_ptr(tr->trace_buffer.data, cpu)->entries) { in tracing_entries_read()
4887 size >> 10, in tracing_entries_read()
4890 r = sprintf(buf, "%lu\n", size >> 10); in tracing_entries_read()
4937 unsigned long size = 0, expanded_size = 0; in tracing_total_entries_read() local
4941 size += per_cpu_ptr(tr->trace_buffer.data, cpu)->entries >> 10; in tracing_total_entries_read()
4946 r = sprintf(buf, "%lu\n", size); in tracing_total_entries_read()
4948 r = sprintf(buf, "%lu (expanded: %lu)\n", size, expanded_size); in tracing_total_entries_read()
4999 int size; in tracing_mark_write() local
5048 size = sizeof(*entry) + cnt + 2; /* possible \n added */ in tracing_mark_write()
5050 event = trace_buffer_lock_reserve(buffer, TRACE_PRINT, size, in tracing_mark_write()
5495 ssize_t size; in tracing_buffers_read() local
5504 size = -EBUSY; in tracing_buffers_read()
5512 size = -ENOMEM; in tracing_buffers_read()
5531 size = -EAGAIN; in tracing_buffers_read()
5538 size = ret; in tracing_buffers_read()
5543 size = 0; in tracing_buffers_read()
5549 size = PAGE_SIZE - info->read; in tracing_buffers_read()
5550 if (size > count) in tracing_buffers_read()
5551 size = count; in tracing_buffers_read()
5553 ret = copy_to_user(ubuf, info->spare + info->read, size); in tracing_buffers_read()
5554 if (ret == size) { in tracing_buffers_read()
5555 size = -EFAULT; in tracing_buffers_read()
5558 size -= ret; in tracing_buffers_read()
5560 *ppos += size; in tracing_buffers_read()
5561 info->read += size; in tracing_buffers_read()
5566 return size; in tracing_buffers_read()
5841 int __weak ftrace_arch_read_dyn_info(char *buf, int size) in ftrace_arch_read_dyn_info() argument
5854 int size = ARRAY_SIZE(ftrace_dyn_info_buffer); in tracing_read_dyn_info() local
5860 r += ftrace_arch_read_dyn_info(buf+r, (size-1)-r); in tracing_read_dyn_info()
6376 allocate_trace_buffer(struct trace_array *tr, struct trace_buffer *buf, int size) in allocate_trace_buffer() argument
6384 buf->buffer = ring_buffer_alloc(size, rb_flags); in allocate_trace_buffer()
6402 static int allocate_trace_buffers(struct trace_array *tr, int size) in allocate_trace_buffers() argument
6406 ret = allocate_trace_buffer(tr, &tr->trace_buffer, size); in allocate_trace_buffers()
6412 allocate_snapshot ? size : 1); in allocate_trace_buffers()