• Home
  • Raw
  • Download

Lines Matching refs:size

24 	m->count = m->size;  in seq_set_overflow()
27 static void *seq_buf_alloc(unsigned long size) in seq_buf_alloc() argument
32 if (unlikely(size > MAX_RW_COUNT)) in seq_buf_alloc()
41 if (size > PAGE_SIZE) in seq_buf_alloc()
43 buf = kmalloc(size, gfp); in seq_buf_alloc()
44 if (!buf && size > PAGE_SIZE) in seq_buf_alloc()
45 buf = vmalloc(size); in seq_buf_alloc()
119 m->buf = seq_buf_alloc(m->size = PAGE_SIZE); in traverse()
160 m->buf = seq_buf_alloc(m->size <<= 1); in traverse()
173 ssize_t seq_read(struct file *file, char __user *buf, size_t size, loff_t *ppos) in seq_read() argument
215 m->buf = seq_buf_alloc(m->size = PAGE_SIZE); in seq_read()
221 n = min(m->count, size); in seq_read()
227 size -= n; in seq_read()
234 if (!size) in seq_read()
254 if (m->count < m->size) in seq_read()
259 m->buf = seq_buf_alloc(m->size <<= 1); in seq_read()
271 while (m->count < size) { in seq_read()
288 n = min(m->count, size); in seq_read()
394 size_t size = seq_get_buf(m, &buf); in seq_escape() local
397 ret = string_escape_str(s, buf, size, ESCAPE_OCTAL, esc); in seq_escape()
398 seq_commit(m, ret < size ? ret : -1); in seq_escape()
406 if (m->count < m->size) { in seq_vprintf()
407 len = vsnprintf(m->buf + m->count, m->size - m->count, f, args); in seq_vprintf()
408 if (m->count + len < m->size) { in seq_vprintf()
471 size_t size = seq_get_buf(m, &buf); in seq_path() local
474 if (size) { in seq_path()
475 char *p = d_path(path, buf, size); in seq_path()
509 size_t size = seq_get_buf(m, &buf); in seq_path_root() local
512 if (size) { in seq_path_root()
515 p = __d_path(path, root, buf, size); in seq_path_root()
538 size_t size = seq_get_buf(m, &buf); in seq_dentry() local
541 if (size) { in seq_dentry()
542 char *p = dentry_path(dentry, buf, size); in seq_dentry()
592 void *data, size_t size) in single_open_size() argument
594 char *buf = seq_buf_alloc(size); in single_open_size()
604 ((struct seq_file *)file->private_data)->size = size; in single_open_size()
663 if (m->count >= m->size) in seq_putc()
674 if (m->count + len >= m->size) { in seq_puts()
695 if (m->count + 2 >= m->size) /* we'll write 2 bytes at least */ in seq_put_decimal_ull()
706 len = num_to_str(m->buf + m->count, m->size - m->count, num); in seq_put_decimal_ull()
720 if (m->count + 3 >= m->size) { in seq_put_decimal_ll()
743 if (seq->count + len < seq->size) { in seq_write()
760 int size = m->pad_until - m->count; in seq_pad() local
761 if (size > 0) in seq_pad()
762 seq_printf(m, "%*s", size, ""); in seq_pad()
776 size_t size; in seq_hex_dump() local
798 size = seq_get_buf(m, &buffer); in seq_hex_dump()
800 buffer, size, ascii); in seq_hex_dump()
801 seq_commit(m, ret < size ? ret : -1); in seq_hex_dump()