Lines Matching refs:nr_pages

1892 	unsigned int nr_pages;  in wdata_alloc_and_fillpages()  local
1910 nr_pages = find_get_pages_tag(mapping, index, in wdata_alloc_and_fillpages()
1913 *found_pages += nr_pages; in wdata_alloc_and_fillpages()
1914 tofind -= nr_pages; in wdata_alloc_and_fillpages()
1915 pages += nr_pages; in wdata_alloc_and_fillpages()
1916 } while (nr_pages && tofind && *index <= end); in wdata_alloc_and_fillpages()
1927 unsigned int nr_pages = 0, i; in wdata_prepare_pages() local
1940 if (nr_pages == 0) in wdata_prepare_pages()
1985 ++nr_pages; in wdata_prepare_pages()
1989 if (nr_pages == 0) in wdata_prepare_pages()
1993 for (i = nr_pages; i < found_pages; i++) { in wdata_prepare_pages()
1998 return nr_pages; in wdata_prepare_pages()
2002 wdata_send_pages(struct cifs_writedata *wdata, unsigned int nr_pages, in wdata_send_pages() argument
2010 wdata->nr_pages = nr_pages; in wdata_send_pages()
2014 page_offset(wdata->pages[nr_pages - 1]), in wdata_send_pages()
2016 wdata->bytes = ((nr_pages - 1) * PAGE_CACHE_SIZE) + wdata->tailsz; in wdata_send_pages()
2030 for (i = 0; i < nr_pages; ++i) in wdata_send_pages()
2066 unsigned int i, nr_pages, found_pages, wsize, credits; in cifs_writepages() local
2090 nr_pages = wdata_prepare_pages(wdata, found_pages, mapping, wbc, in cifs_writepages()
2094 if (nr_pages == 0) { in cifs_writepages()
2102 rc = wdata_send_pages(wdata, nr_pages, mapping, wbc); in cifs_writepages()
2107 for (i = 0; i < nr_pages; ++i) { in cifs_writepages()
2126 wbc->nr_to_write -= nr_pages; in cifs_writepages()
2398 for (i = 0; i < wdata->nr_pages; i++) in cifs_uncached_writedata_release()
2427 unsigned long i, nr_pages = *num_pages; in wdata_fill_from_iovec() local
2430 for (i = 0; i < nr_pages; i++) { in wdata_fill_from_iovec()
2471 unsigned long nr_pages, num_pages, i; in cifs_write_from_iter() local
2494 nr_pages = get_numpages(wsize, len, &cur_len); in cifs_write_from_iter()
2495 wdata = cifs_writedata_alloc(nr_pages, in cifs_write_from_iter()
2503 rc = cifs_write_allocate_pages(wdata->pages, nr_pages); in cifs_write_from_iter()
2510 num_pages = nr_pages; in cifs_write_from_iter()
2513 for (i = 0; i < nr_pages; i++) in cifs_write_from_iter()
2524 for ( ; nr_pages > num_pages; nr_pages--) in cifs_write_from_iter()
2525 put_page(wdata->pages[nr_pages - 1]); in cifs_write_from_iter()
2528 wdata->nr_pages = nr_pages; in cifs_write_from_iter()
2534 wdata->tailsz = cur_len - ((nr_pages - 1) * PAGE_SIZE); in cifs_write_from_iter()
2748 cifs_readdata_alloc(unsigned int nr_pages, work_func_t complete) in cifs_readdata_alloc() argument
2752 rdata = kzalloc(sizeof(*rdata) + (sizeof(struct page *) * nr_pages), in cifs_readdata_alloc()
2777 cifs_read_allocate_pages(struct cifs_readdata *rdata, unsigned int nr_pages) in cifs_read_allocate_pages() argument
2783 for (i = 0; i < nr_pages; i++) { in cifs_read_allocate_pages()
2793 for (i = 0; i < nr_pages; i++) { in cifs_read_allocate_pages()
2808 for (i = 0; i < rdata->nr_pages; i++) { in cifs_uncached_readdata_release()
2830 for (i = 0; i < rdata->nr_pages; i++) { in cifs_readdata_to_iov()
2857 unsigned int nr_pages = rdata->nr_pages; in cifs_uncached_read_into_pages() local
2862 for (i = 0; i < nr_pages; i++) { in cifs_uncached_read_into_pages()
2884 rdata->nr_pages--; in cifs_uncached_read_into_pages()
2942 rdata->nr_pages = npages; in cifs_send_async_read()
3272 for (i = 0; i < rdata->nr_pages; i++) { in cifs_readv_complete()
3305 unsigned int nr_pages = rdata->nr_pages; in cifs_readpages_read_into_pages() local
3315 for (i = 0; i < nr_pages; i++) { in cifs_readpages_read_into_pages()
3351 rdata->nr_pages--; in cifs_readpages_read_into_pages()
3359 rdata->nr_pages--; in cifs_readpages_read_into_pages()
3378 unsigned int *nr_pages, loff_t *offset, unsigned int *bytes) in readpages_get_pages() argument
3406 *nr_pages = 1; in readpages_get_pages()
3429 (*nr_pages)++; in readpages_get_pages()
3479 unsigned int i, nr_pages, bytes, rsize; in cifs_readpages() local
3502 &nr_pages, &offset, &bytes); in cifs_readpages()
3508 rdata = cifs_readdata_alloc(nr_pages, cifs_readv_complete); in cifs_readpages()
3533 rdata->pages[rdata->nr_pages++] = page; in cifs_readpages()
3541 for (i = 0; i < rdata->nr_pages; i++) { in cifs_readpages()