Lines Matching defs:pages

34 	PagesDataOutput(vm_page** pages, size_t pageCount)
36 fPages(pages),
172 // check whether there are pages of the cache line and the mark them used
175 vm_page* pages[kPagesPerCacheLine] = {};
184 VMCachePagesTree::Iterator it = fCache->pages.GetIterator(pageOffset, true,
197 // pages are missing
204 pages[pageOffset - firstPageOffset] = NULL;
208 pages[pageOffset++ - firstPageOffset] = page;
218 // TODO: If the missing pages range doesn't intersect with the request, just
220 // There are pages of the cache line missing. We have to allocate fresh
227 _DiscardPages(pages, firstMissing - firstPageOffset, missingPages);
234 // Allocate the missing pages and remove the already existing pages in
240 if (pages[index] == NULL) {
241 pages[index] = vm_page_allocate_page(&reservation,
243 DEBUG_PAGE_ACCESS_END(pages[index]);
246 fCache->RemovePage(pages[index]);
253 // add the pages to the cache
259 fCache->InsertPage(pages[index], (off_t)pageOffset * B_PAGE_SIZE);
264 // read in the missing pages
265 status_t error = _ReadIntoPages(pages, firstMissing - firstPageOffset,
275 _DiscardPages(pages, firstMissing - firstPageOffset, missingPages);
284 status_t error = _WritePages(pages, requestOffset - lineOffset,
286 _CachePages(pages, 0, linePageCount);
291 /*! Frees all pages in given range of the \a pages array.
293 to pages with \c PAGE_STATE_UNUSED. The pages may belong to \c fCache or
298 CachedDataReader::_DiscardPages(vm_page** pages, size_t firstPage,
307 vm_page* page = pages[i];
324 /*! Marks all pages in the given range of the \a pages array cached.
325 There must not be any \c NULL entries in the given array range. All pages
330 CachedDataReader::_CachePages(vm_page** pages, size_t firstPage,
339 vm_page* page = pages[i];
352 /*! Writes the contents of pages in \c pages to \a output.
353 \param pages The pages array.
354 \param pagesRelativeOffset The offset relative to \a pages[0] where to
361 CachedDataReader::_WritePages(vm_page** pages, size_t pagesRelativeOffset,
371 // fallback to copying individual pages
378 pages[i]->physical_page_number * B_PAGE_SIZE, &address,
402 CachedDataReader::_ReadIntoPages(vm_page** pages, size_t firstPage,
405 PagesDataOutput output(pages + firstPage, pageCount);
407 off_t firstPageOffset = (off_t)pages[firstPage]->cache_offset