Lines Matching refs:count

835 static ssize_t cache_read(struct file *filp, char __user *buf, size_t count,  in cache_read()  argument
843 if (count == 0) in cache_read()
882 if (rp->offset + count > rq->len) in cache_read()
883 count = rq->len - rp->offset; in cache_read()
885 if (copy_to_user(buf, rq->buf + rp->offset, count)) in cache_read()
887 rp->offset += count; in cache_read()
914 return err ? err : count; in cache_read()
918 size_t count, struct cache_detail *cd) in cache_do_downcall() argument
922 if (count == 0) in cache_do_downcall()
924 if (copy_from_user(kaddr, buf, count)) in cache_do_downcall()
926 kaddr[count] = '\0'; in cache_do_downcall()
927 ret = cd->cache_parse(cd, kaddr, count); in cache_do_downcall()
929 ret = count; in cache_do_downcall()
935 size_t count, struct cache_detail *cd) in cache_downcall() argument
940 if (count >= 32768) { /* 32k is max userland buffer, lets check anyway */ in cache_downcall()
945 write_buf = kvmalloc(count + 1, GFP_KERNEL); in cache_downcall()
949 ret = cache_do_downcall(write_buf, buf, count, cd); in cache_downcall()
956 size_t count, loff_t *ppos, in cache_write() argument
967 ret = cache_downcall(mapping, buf, count, cd); in cache_write()
1502 size_t count, loff_t *ppos, in read_flush() argument
1510 return simple_read_from_buffer(buf, count, ppos, tbuf, len); in read_flush()
1514 size_t count, loff_t *ppos, in write_flush() argument
1521 if (*ppos || count > sizeof(tbuf)-1) in write_flush()
1523 if (copy_from_user(tbuf, buf, count)) in write_flush()
1525 tbuf[count] = 0; in write_flush()
1552 *ppos += count; in write_flush()
1553 return count; in write_flush()
1557 size_t count, loff_t *ppos) in cache_read_procfs() argument
1561 return cache_read(filp, buf, count, ppos, cd); in cache_read_procfs()
1565 size_t count, loff_t *ppos) in cache_write_procfs() argument
1569 return cache_write(filp, buf, count, ppos, cd); in cache_write_procfs()
1647 size_t count, loff_t *ppos) in read_flush_procfs() argument
1651 return read_flush(filp, buf, count, ppos, cd); in read_flush_procfs()
1656 size_t count, loff_t *ppos) in write_flush_procfs() argument
1660 return write_flush(filp, buf, count, ppos, cd); in write_flush_procfs()
1769 size_t count, loff_t *ppos) in cache_read_pipefs() argument
1773 return cache_read(filp, buf, count, ppos, cd); in cache_read_pipefs()
1777 size_t count, loff_t *ppos) in cache_write_pipefs() argument
1781 return cache_write(filp, buf, count, ppos, cd); in cache_write_pipefs()
1860 size_t count, loff_t *ppos) in read_flush_pipefs() argument
1864 return read_flush(filp, buf, count, ppos, cd); in read_flush_pipefs()
1869 size_t count, loff_t *ppos) in write_flush_pipefs() argument
1873 return write_flush(filp, buf, count, ppos, cd); in write_flush_pipefs()