Lines Matching refs:len
346 int len = (PAGE_SIZE - 1) - s->len; in trace_seq_printf() local
350 if (!len) in trace_seq_printf()
354 ret = vsnprintf(s->buffer + s->len, len, fmt, ap); in trace_seq_printf()
358 if (ret >= len) in trace_seq_printf()
361 s->len += ret; in trace_seq_printf()
363 return len; in trace_seq_printf()
379 int len = strlen(str); in trace_seq_puts() local
381 if (len > ((PAGE_SIZE - 1) - s->len)) in trace_seq_puts()
384 memcpy(s->buffer + s->len, str, len); in trace_seq_puts()
385 s->len += len; in trace_seq_puts()
387 return len; in trace_seq_puts()
393 if (s->len >= (PAGE_SIZE - 1)) in trace_seq_putc()
396 s->buffer[s->len++] = c; in trace_seq_putc()
402 trace_seq_putmem(struct trace_seq *s, void *mem, size_t len) in trace_seq_putmem() argument
404 if (len > ((PAGE_SIZE - 1) - s->len)) in trace_seq_putmem()
407 memcpy(s->buffer + s->len, mem, len); in trace_seq_putmem()
408 s->len += len; in trace_seq_putmem()
410 return len; in trace_seq_putmem()
417 trace_seq_putmem_hex(struct trace_seq *s, void *mem, size_t len) argument
424 for (i = 0, j = 0; i < len; i++) {
426 for (i = len-1, j = 0; i >= 0; i--) {
441 if (s->len >= (PAGE_SIZE - 1))
443 p = d_path(path, s->buffer + s->len, PAGE_SIZE - s->len);
445 p = mangle_path(s->buffer + s->len, p, "\n");
447 s->len = p - s->buffer;
451 s->buffer[s->len++] = '?';
461 s->len = 0;
467 int len; local
470 if (s->len <= s->readpos)
473 len = s->len - s->readpos;
474 if (cnt > len)
475 cnt = len;
480 s->readpos += len;
487 int len = s->len >= PAGE_SIZE ? PAGE_SIZE - 1 : s->len; local
489 s->buffer[len] = 0;
561 int len; local
634 len = strlen(type->name);
635 if (len > max_tracer_type_len)
636 max_tracer_type_len = len;
649 int len; local
666 len = strlen((*t)->name);
667 if (len > max_tracer_type_len)
668 max_tracer_type_len = len;
2667 int len; local
2671 len = cpumask_scnprintf(mask_str, count, tracing_cpumask);
2672 if (count - len < 2) {
2676 len += sprintf(mask_str + len, "\n");
2746 int len = 0; local
2753 len += strlen(trace_options[i]);
2754 len += 3; /* "no" and space */
2762 len += strlen(trace_opts[i].name);
2763 len += 3; /* "no" and space */
2767 buf = kmalloc(len + 2, GFP_KERNEL);
2788 WARN_ON(r >= len + 2);
2803 int len; local
2807 len = strlen(opts->name);
2809 if (strncmp(cmp, opts->name, len) == 0) {
2855 int len = strlen(trace_options[i]); local
2857 if (strncmp(cmp, trace_options[i], len) == 0) {
3262 int len = iter->seq.len; local
3267 iter->seq.len = len;
3273 if (iter->seq.len >= cnt)
3279 if (iter->seq.readpos >= iter->seq.len)
3633 int cpu, len = 0, size, pc; local
3650 len = vsnprintf(trace_buf, TRACE_BUF_SIZE, fmt, args);
3652 len = min(len, TRACE_BUF_SIZE-1);
3653 trace_buf[len] = 0;
3655 size = sizeof(*entry) + len + 1;
3665 memcpy(&entry->buf, trace_buf, len);
3666 entry->buf[len] = 0;
3675 return len;
3745 if (s->len >= 1000)
3746 s->len = 1000;
3749 s->buffer[s->len] = 0;